Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

implement Mantis 1947, treat ship comm systems the same as player comm systems #2342

Merged
merged 7 commits into from May 10, 2020

Conversation

Goober5000
Copy link
Contributor

This adds an ai_profiles flag that checks comm systems for non-player ships. If their comm system is damaged, they will not send messages and you will not be able to issue squadmsg orders.

See also:
http://scp.indiegames.us/mantis/view.php?id=1947

Also, this PR fixes a few bugs:

  1. message scramble status incorrectly took priority over subsystem health status
  2. synthesized speech could be stopped when only the head animation needed to be stopped
  3. don't allow messages that are never played to delay messages that are played

This adds an ai_profiles flag that checks comm systems for non-player ships.  If their comm system is damaged, they will not send messages and you will not be able to issue squadmsg orders.

See also:
http://scp.indiegames.us/mantis/view.php?id=1947
From the comments:

	// Do some checks to see if we are actually going to play this message at all.  These checks have been moved above the
	// "if ( Num_messages_playing )" block because we don't want to cancel an existing message if we have nothing to replace it with.

Additionally, by not incrementing `Num_playing_messages` if the code skips to `all_done`, this prevents messages that aren't playing from delaying messages in the queue that are actually valid and should play.
…add some flag checks to allow death messages to play (and be scrambled appropriately) if we have the ai_profiles flag active
…elect them when looking for unsilenced ships either
@Goober5000 Goober5000 added fix A fix for bugs, not-a-bugs, and/or regressions. enhancement A new feature or upgrade of an existing feature to add additional functionality. mantis A feature or issue imported from MANTIS, the old issue tracker labels Apr 27, 2020
Copy link
Member

@wookieejedi wookieejedi left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Definitely a good idea updating the older style to bool types, and overall everything looks good to me.

@Goober5000 Goober5000 merged commit 1d471e2 into scp-fs2open:master May 10, 2020
@Goober5000 Goober5000 deleted the mantis_1947 branch May 10, 2020 19:36
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement A new feature or upgrade of an existing feature to add additional functionality. fix A fix for bugs, not-a-bugs, and/or regressions. mantis A feature or issue imported from MANTIS, the old issue tracker
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants