diff options
author | Sergeanur <s.anureev@yandex.ua> | 2020-06-08 15:22:49 +0200 |
---|---|---|
committer | Sergeanur <s.anureev@yandex.ua> | 2020-06-08 15:22:49 +0200 |
commit | 95e9fe76937e082df5336f79384ad6dc15883a40 (patch) | |
tree | 66c3f236d59f5c96974d07cd03db6f0e687e38e3 /src | |
parent | miamification of some audio structs (diff) | |
download | re3-95e9fe76937e082df5336f79384ad6dc15883a40.tar re3-95e9fe76937e082df5336f79384ad6dc15883a40.tar.gz re3-95e9fe76937e082df5336f79384ad6dc15883a40.tar.bz2 re3-95e9fe76937e082df5336f79384ad6dc15883a40.tar.lz re3-95e9fe76937e082df5336f79384ad6dc15883a40.tar.xz re3-95e9fe76937e082df5336f79384ad6dc15883a40.tar.zst re3-95e9fe76937e082df5336f79384ad6dc15883a40.zip |
Diffstat (limited to 'src')
-rw-r--r-- | src/audio/AudioLogic.cpp | 4 | ||||
-rw-r--r-- | src/control/GameLogic.cpp | 8 | ||||
-rw-r--r-- | src/control/Script.cpp | 1 |
3 files changed, 6 insertions, 7 deletions
diff --git a/src/audio/AudioLogic.cpp b/src/audio/AudioLogic.cpp index a7d16dc4..68f597bc 100644 --- a/src/audio/AudioLogic.cpp +++ b/src/audio/AudioLogic.cpp @@ -5700,7 +5700,7 @@ cAudioManager::IsMissionAudioSamplePlaying(uint8 slot) const } else { static int32 cPretendFrame[MISSION_AUDIO_SLOTS] = { 1, 1 }; - return (cPretendFrame[MISSION_AUDIO_SLOTS]++ % 64) != 0; + return (cPretendFrame[slot]++ % 64) != 0; } } @@ -5716,7 +5716,7 @@ cAudioManager::IsMissionAudioSampleFinished(uint8 slot) static int32 cPretendFrame[MISSION_AUDIO_SLOTS] = { 1, 1 }; - return (cPretendFrame[MISSION_AUDIO_SLOTS]++ % 64) == 0; + return (cPretendFrame[slot]++ % 64) == 0; } void diff --git a/src/control/GameLogic.cpp b/src/control/GameLogic.cpp index 5ec976d1..50e5584d 100644 --- a/src/control/GameLogic.cpp +++ b/src/control/GameLogic.cpp @@ -193,15 +193,15 @@ CGameLogic::Update() pPlayerInfo.m_nBustedAudioStatus = BUSTEDAUDIO_LOADING; char name[12]; sprintf(name, pPlayerInfo.m_nCurrentBustedAudio >= 10 ? "bust_%d" : "bust_0%d", pPlayerInfo.m_nCurrentBustedAudio); - DMAudio.ClearMissionAudio(0); // TODO(MIAMI): argument is 0 - DMAudio.PreloadMissionAudio(0, name); // TODO(MIAMI): argument is 0 + DMAudio.ClearMissionAudio(0); + DMAudio.PreloadMissionAudio(0, name); pPlayerInfo.m_nCurrentBustedAudio = pPlayerInfo.m_nCurrentBustedAudio % 28 + 1; // enum? const? TODO } } if (CTimer::GetTimeInMilliseconds() - pPlayerInfo.m_nWBTime > 4000 && pPlayerInfo.m_nBustedAudioStatus == BUSTEDAUDIO_LOADING && - DMAudio.GetMissionAudioLoadingStatus(0) == 1) { // TODO: argument is 0 - DMAudio.PlayLoadedMissionAudio(0); // TODO: argument is 0 + DMAudio.GetMissionAudioLoadingStatus(0) == 1) { + DMAudio.PlayLoadedMissionAudio(0); pPlayerInfo.m_nBustedAudioStatus = BUSTEDAUDIO_DONE; } diff --git a/src/control/Script.cpp b/src/control/Script.cpp index ef25417c..d25fb173 100644 --- a/src/control/Script.cpp +++ b/src/control/Script.cpp @@ -8662,7 +8662,6 @@ int8 CRunningScript::ProcessCommands900To999(int32 command) strncpy(str, (char*)&CTheScripts::ScriptSpace[m_nIp], KEY_LENGTH_IN_SCRIPT); for (int i = 0; i < KEY_LENGTH_IN_SCRIPT; i++) str[i] = tolower(str[i]); - static bool bShowed = false; m_nIp += KEY_LENGTH_IN_SCRIPT; DMAudio.PreloadMissionAudio(ScriptParams[0] - 1, str); return 0; |