Fix #3678
Don't play drive-on sound from materials when the game state is paused.
This commit is contained in:
parent
99868d5897
commit
e9a75f6c52
@ -519,7 +519,7 @@ void SFXManager::toggleSound(const bool on)
|
||||
resume_later = (World::getWorld()->getPhase() == World::IN_GAME_MENU_PHASE);
|
||||
for (int n=0; n<sfx_amount; n++)
|
||||
{
|
||||
// This also pauses sound effects
|
||||
// This also pauses sound effects if they should be resumed later
|
||||
m_all_sfx.getData()[n]->onSoundEnabledBack(resume_later);
|
||||
}
|
||||
m_all_sfx.unlock();
|
||||
|
@ -2003,7 +2003,8 @@ void Kart::handleMaterialSFX()
|
||||
|
||||
bool m_schedule_pause = m_flying ||
|
||||
dynamic_cast<RescueAnimation*>(getKartAnimation()) ||
|
||||
dynamic_cast<ExplosionAnimation*>(getKartAnimation());
|
||||
dynamic_cast<ExplosionAnimation*>(getKartAnimation()) ||
|
||||
World::getWorld()->getPhase() == World::IN_GAME_MENU_PHASE;
|
||||
|
||||
// terrain sound is not necessarily a looping sound so check its status before
|
||||
// setting its speed, to avoid 'ressuscitating' sounds that had already stopped
|
||||
|
Loading…
Reference in New Issue
Block a user