From eb2bffd185c2d5f58c54bc77f7e974c0f1b92058 Mon Sep 17 00:00:00 2001 From: Torbjörn Andersson Date: Sun, 16 Jan 2005 17:06:40 +0000 Subject: sfPlayMusic() takes two parameters in IHNM. Since our current implementation is only right for ITE, disable it for IHNM for now. svn-id: r16572 --- saga/sfuncs.cpp | 17 ++++++++++++----- 1 file changed, 12 insertions(+), 5 deletions(-) (limited to 'saga') diff --git a/saga/sfuncs.cpp b/saga/sfuncs.cpp index e068156555..d3dc57858f 100644 --- a/saga/sfuncs.cpp +++ b/saga/sfuncs.cpp @@ -1301,12 +1301,19 @@ int Script::SF_eraseDelta(SCRIPTFUNC_PARAMS) { // Script function #63 (0x3F) int Script::sfPlayMusic(SCRIPTFUNC_PARAMS) { - ScriptDataWord param = thread->pop() + 9; + if (_vm->getGameType() == GType_ITE) { + ScriptDataWord param = thread->pop() + 9; - if (param >= 9 && param <= 34) - _vm->_music->play(param); - else - _vm->_music->stop(); + if (param >= 9 && param <= 34) + _vm->_music->play(param); + else + _vm->_music->stop(); + } else { + ScriptDataWord param1 = thread->pop(); + ScriptDataWord param2 = thread->pop(); + + debug(1, "Stub: sfPlayMusic(%d, %d)", param1, param2); + } return SUCCESS; } -- cgit v1.2.3