diff options
author | Thanasis Antoniou | 2019-09-09 21:08:41 +0300 |
---|---|---|
committer | Thanasis Antoniou | 2019-09-09 21:09:36 +0300 |
commit | f5b79a4cdfc2e481c275eb8fb9b3b833648479c5 (patch) | |
tree | fc03bb891713ac0cc02df6864b4b85444e668a18 /engines/bladerunner/ui | |
parent | 79fcee786a29d765b0530ec63ad0a7b8a140df8a (diff) | |
download | scummvm-rg350-f5b79a4cdfc2e481c275eb8fb9b3b833648479c5.tar.gz scummvm-rg350-f5b79a4cdfc2e481c275eb8fb9b3b833648479c5.tar.bz2 scummvm-rg350-f5b79a4cdfc2e481c275eb8fb9b3b833648479c5.zip |
BLADERUNNER: Play full exit KIA sound before quit via KIA
Diffstat (limited to 'engines/bladerunner/ui')
-rw-r--r-- | engines/bladerunner/ui/kia.cpp | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/engines/bladerunner/ui/kia.cpp b/engines/bladerunner/ui/kia.cpp index 9ec9d686c0..32704fc7d2 100644 --- a/engines/bladerunner/ui/kia.cpp +++ b/engines/bladerunner/ui/kia.cpp @@ -663,7 +663,13 @@ void KIA::mouseDownCallback(int buttonId, void *callbackData) { case 14: self->_vm->_audioPlayer->playAud(self->_vm->_gameInfo->getSfxTrack(kSfxBUTN5P), 70, 0, 0, 50, 0); if (buttonId == 12) { - self->_vm->_audioPlayer->playAud(self->_vm->_gameInfo->getSfxTrack(kSfxSHUTDOWN), 70, 0, 0, 50, 0); + int endTrackId = self->_vm->_audioPlayer->playAud(self->_vm->_gameInfo->getSfxTrack(kSfxSHUTDOWN), 70, 0, 0, 50, 0); + if (endTrackId != -1) { + // wait until the full clip has played (similar to the original) + while (self->_vm->_audioPlayer->isActive(endTrackId)) { + self->_vm->_system->delayMillis(16); + } + } } break; case 15: |