[GameplayAssist] Don't play sounds if the player is dead. Fixes issue 621.
This commit is contained in:
@@ -14,6 +14,7 @@ StepMania 5.0 $next | 2011xxxx
|
||||
refresh the NS data for the present game, not all games. [Wolfman2000]
|
||||
* [ScreenSelectMusic] Fixed Rave difficulties not being synced on late join.
|
||||
Fixes issue 577. [AJ]
|
||||
* [GameplayAssist] Don't play sounds if the player is dead. Fixes issue 621. [AJ]
|
||||
|
||||
2011/11/04
|
||||
* [ScoreKeeperRave] Revert fix from 2011/10/28. [AJ]
|
||||
|
||||
@@ -21,14 +21,17 @@ void GameplayAssist::PlayTicks( const NoteData &nd, const PlayerState *ps )
|
||||
if( !bClap && !bMetronome )
|
||||
return;
|
||||
|
||||
// don't play sounds for dead players
|
||||
if( ps->m_HealthState == HealthState_Dead )
|
||||
return;
|
||||
|
||||
/* Sound cards have a latency between when a sample is Play()ed and when the sound
|
||||
* will start coming out the speaker. Compensate for this by boosting fPositionSeconds
|
||||
* ahead. This is just to make sure that we request the sound early enough for it to
|
||||
* come out on time; the actual precise timing is handled by SetStartTime. */
|
||||
|
||||
SongPosition &position = GAMESTATE->m_pPlayerState[ps->m_PlayerNumber]->m_Position;
|
||||
float fPositionSeconds = position.m_fMusicSeconds;
|
||||
|
||||
|
||||
//float fPositionSeconds = GAMESTATE->m_Position.m_fMusicSeconds;
|
||||
fPositionSeconds += SOUNDMAN->GetPlayLatency() + (float)CommonMetrics::TICK_EARLY_SECONDS + 0.250f;
|
||||
const TimingData &timing = GAMESTATE->m_pCurSteps[ps->m_PlayerNumber]->m_Timing;
|
||||
|
||||
Reference in New Issue
Block a user