From ec30fcde64c0e6caa6cc19976138a4c3994dff28 Mon Sep 17 00:00:00 2001 From: Shadooow Date: Wed, 12 Jan 2022 03:33:27 +0000 Subject: [PATCH] Fixed helicopter sound playing in loop indefinitely when quick-loading during helidrop animation. git-svn-id: https://ja2svn.mooo.com/source/ja2/trunk/GameSource/ja2_v1.13/Build@9252 3b4a5df2-a311-0410-b5c6-a8a6f20db521 --- SaveLoadScreen.cpp | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/SaveLoadScreen.cpp b/SaveLoadScreen.cpp index a03699e3..90e1ee54 100644 --- a/SaveLoadScreen.cpp +++ b/SaveLoadScreen.cpp @@ -245,6 +245,7 @@ extern BOOLEAN ValidateSoldierInitLinks( UINT8 ubCode ); #endif extern BOOLEAN fFirstTimeInGameScreen; // added by Flugente +extern UINT32 uiSoundSample; ////////////////////////////////////////////////////// // @@ -2751,6 +2752,12 @@ BOOLEAN DoQuickLoad() PauseTime( FALSE ); } + // Remove sound + if (uiSoundSample != NO_SAMPLE) + { + SoundStop(uiSoundSample); + } + //Do a fade out before we load the game gFadeOutDoneCallback = DoneFadeOutForSaveLoadScreen;