diff options
author | Filippos Karapetis | 2008-04-24 05:17:51 +0000 |
---|---|---|
committer | Filippos Karapetis | 2008-04-24 05:17:51 +0000 |
commit | e14746db3c7d5ad3749af4aa2449f4eef966646a (patch) | |
tree | 3958666a4ab86683c9a3f2ad6ac2976cf31c237b /engines/made | |
parent | 27d4ecb12f3addda17797a8eba0598b90d9d454b (diff) | |
download | scummvm-rg350-e14746db3c7d5ad3749af4aa2449f4eef966646a.tar.gz scummvm-rg350-e14746db3c7d5ad3749af4aa2449f4eef966646a.tar.bz2 scummvm-rg350-e14746db3c7d5ad3749af4aa2449f4eef966646a.zip |
Slight cleanup to o1_PLAYSND
svn-id: r31684
Diffstat (limited to 'engines/made')
-rw-r--r-- | engines/made/scriptfuncs.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/engines/made/scriptfuncs.cpp b/engines/made/scriptfuncs.cpp index cd3d3daf1a..5dd64b6ded 100644 --- a/engines/made/scriptfuncs.cpp +++ b/engines/made/scriptfuncs.cpp @@ -272,13 +272,15 @@ int16 ScriptFunctionsRtz::o1_VISUALFX(int16 argc, int16 *argv) { } int16 ScriptFunctionsRtz::o1_PLAYSND(int16 argc, int16 *argv) { - int soundId = (argc == 1) ? argv[0] : argv[1]; + int soundId = argv[0]; bool loop = false; + if (argc > 1) { + soundId = argv[1]; loop = (argv[0] == 1); } - if (argv[0] > 0) { + if (soundId > 0) { if (!_vm->_mixer->isSoundHandleActive(_audioStreamHandle)) { _vm->_mixer->playInputStream(Audio::Mixer::kPlainSoundType, &_audioStreamHandle, _vm->_res->getSound(soundId)->getAudioStream(_vm->_soundRate, loop)); |