リビジョン | 58ea7b4323b650978ac6d688add43ce223c870db (tree) |
---|---|
日時 | 2021-12-01 02:08:12 |
作者 | Adam Kaminski <kaminskiadam9@gmai...> |
コミッター | Adam Kaminski |
Fixed survival being stuck in the "mission failed" state indefinitely if it was interrupted by the intermission screen.
@@ -4680,6 +4680,16 @@ | ||
4680 | 4680 | // [BB] We have to reset the state though when this is a new game. |
4681 | 4681 | if ( ( SURVIVAL_GetState( ) == SURVS_COUNTDOWN ) || ( gameaction == ga_newgame ) ) |
4682 | 4682 | SURVIVAL_SetState( SURVS_WAITINGFORPLAYERS ); |
4683 | + | |
4684 | + // [AK] If we still advanced to the next map when the mission failed, then either the countdown | |
4685 | + // if there's still people playing, or reset the state entirely. | |
4686 | + if ( SURVIVAL_GetState( ) == SURVS_MISSIONFAILED ) | |
4687 | + { | |
4688 | + if ( SERVER_CalcNumNonSpectatingPlayers( MAXPLAYERS ) < 1 ) | |
4689 | + SURVIVAL_SetState( SURVS_WAITINGFORPLAYERS ); | |
4690 | + else | |
4691 | + SURVIVAL_StartCountdown(( sv_survivalcountdowntime > 0 ? sv_survivalcountdowntime : 20 ) * TICRATE - 1 ); | |
4692 | + } | |
4683 | 4693 | } |
4684 | 4694 | |
4685 | 4695 | if ( NETWORK_InClientMode() == false ) |