From 92ef7a74dcc1ac22078fc5ece11523fa0559506a Mon Sep 17 00:00:00 2001 From: hackgrid Date: Sat, 11 Nov 2023 11:29:52 +0100 Subject: [PATCH] translation mapping for all sounds (fix #405) --- src/levels/cutscene_runner.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/src/levels/cutscene_runner.c b/src/levels/cutscene_runner.c index 7d902de..c7f0f55 100644 --- a/src/levels/cutscene_runner.c +++ b/src/levels/cutscene_runner.c @@ -198,7 +198,6 @@ void cutsceneRunnerStartStep(struct CutsceneRunner* runner) { break; case CutsceneStepTypeQueueSound: { - step->queueSound.soundId = mapLocaleSound(step->queueSound.soundId); cutsceneQueueSoundInChannel(step->queueSound.soundId, step->queueSound.volume * (1.0f / 255.0f), step->queueSound.channel, step->queueSound.subtitleId); break; } @@ -709,6 +708,8 @@ void cutsceneSerializeRead(struct Serializer* serializer) { } void cutsceneQueueSoundInChannel(int soundId, float volume, int channel, int subtitleId) { + soundId = mapLocaleSound(soundId); + if (!gCutsceneSoundQueues[channel] && !soundPlayerIsPlaying(gCutsceneCurrentSound[channel]) && channel == CH_GLADOS) { cutsceneQueueSound(soundsIntercom[0], volume, channel, subtitleId); } @@ -725,4 +726,4 @@ int cutsceneIsSoundQueued(){ } } return soundQueued; -} \ No newline at end of file +}