diff options
author | Andrew Kurushin | 2005-01-18 21:13:44 +0000 |
---|---|---|
committer | Andrew Kurushin | 2005-01-18 21:13:44 +0000 |
commit | 0ccf59faee053f4ea6c349d25bf39bb83e537686 (patch) | |
tree | 770d2871d776fb9672fdab5c82d43912485d9145 /saga/sfuncs.cpp | |
parent | b4b2e52df78fd309613d8df73f090b98e834969b (diff) | |
download | scummvm-rg350-0ccf59faee053f4ea6c349d25bf39bb83e537686.tar.gz scummvm-rg350-0ccf59faee053f4ea6c349d25bf39bb83e537686.tar.bz2 scummvm-rg350-0ccf59faee053f4ea6c349d25bf39bb83e537686.zip |
partly implemented game objects
svn-id: r16595
Diffstat (limited to 'saga/sfuncs.cpp')
-rw-r--r-- | saga/sfuncs.cpp | 41 |
1 files changed, 28 insertions, 13 deletions
diff --git a/saga/sfuncs.cpp b/saga/sfuncs.cpp index ec89ab2a5e..31cc2254b6 100644 --- a/saga/sfuncs.cpp +++ b/saga/sfuncs.cpp @@ -153,9 +153,12 @@ int Script::sfWait(SCRIPTFUNC_PARAMS) { // Script function #2 (0x02) int Script::SF_takeObject(SCRIPTFUNC_PARAMS) { - ScriptDataWord param = thread->pop(); + thread->pop(); + warning("Not implemented"); +/* ScriptDataWord param = thread->pop(); int index = param & 0x1FFF; - + + if (index >= ARRAYSIZE(ObjectTable)) { return FAILURE; } @@ -163,7 +166,7 @@ int Script::SF_takeObject(SCRIPTFUNC_PARAMS) { if (ObjectTable[index].sceneIndex != -1) { ObjectTable[index].sceneIndex = -1; _vm->_interface->addToInventory(index); - } + }*/ return SUCCESS; } @@ -171,7 +174,11 @@ int Script::SF_takeObject(SCRIPTFUNC_PARAMS) { // Script function #3 (0x03) // Check if an object is carried. int Script::SF_objectIsCarried(SCRIPTFUNC_PARAMS) { - ScriptDataWord param = thread->pop(); + /*ScriptDataWord param =*/ thread->pop(); + warning("Not implemented"); + thread->retVal = 0; +/* + int index = param & 0x1FFF; if (index >= ARRAYSIZE(ObjectTable)) { @@ -179,7 +186,7 @@ int Script::SF_objectIsCarried(SCRIPTFUNC_PARAMS) { return FAILURE; } - thread->retVal = (ObjectTable[index].sceneIndex == -1) ? 1 : 0; + thread->retVal = (ObjectTable[index].sceneIndex == -1) ? 1 : 0;*/ return SUCCESS; } @@ -435,9 +442,11 @@ int Script::SF_gotoScene(SCRIPTFUNC_PARAMS) { // Script function #17 (0x11) int Script::SF_setObjImage(SCRIPTFUNC_PARAMS) { - int16 obj_param = getSWord(thread->pop()); + error("Not implemented"); +/* int16 obj_param = getSWord(thread->pop()); int16 sprite_param = getSWord(thread->pop()); + int index = obj_param & 0x1FFF; if (index >= ARRAYSIZE(ObjectTable)) { @@ -446,13 +455,15 @@ int Script::SF_setObjImage(SCRIPTFUNC_PARAMS) { ObjectTable[index].spritelistRn = sprite_param + 9; _vm->_interface->draw(); - +*/ return SUCCESS; } // Script function #18 (0x12) int Script::SF_setObjName(SCRIPTFUNC_PARAMS) { - int obj_param = getSWord(thread->pop()); + error("Not implemented"); + +/* int obj_param = getSWord(thread->pop()); int name_param = getSWord(thread->pop()); int index = obj_param & 0x1FFF; @@ -461,13 +472,15 @@ int Script::SF_setObjName(SCRIPTFUNC_PARAMS) { return FAILURE; } - ObjectTable[index].nameIndex = name_param; + ObjectTable[index].nameIndex = name_param;*/ return SUCCESS; } // Script function #19 (0x13) int Script::SF_getObjImage(SCRIPTFUNC_PARAMS) { - int param = getSWord(thread->pop()); + error("Not implemented"); + +/* int param = getSWord(thread->pop()); int index = param & 0x1FFF; if (index >= ARRAYSIZE(ObjectTable)) { @@ -475,7 +488,7 @@ int Script::SF_getObjImage(SCRIPTFUNC_PARAMS) { return FAILURE; } - thread->retVal = ObjectTable[index].spritelistRn; + thread->retVal = ObjectTable[index].spritelistRn;*/ return SUCCESS; } @@ -647,7 +660,9 @@ int Script::SF_sceneEq(SCRIPTFUNC_PARAMS) { // Script function #32 (0x20) int Script::SF_dropObject(SCRIPTFUNC_PARAMS) { - ScriptDataWord obj_param = thread->pop(); + error("Not implemented"); + +/* ScriptDataWord obj_param = thread->pop(); ScriptDataWord sprite_param = thread->pop(); ScriptDataWord x_param = thread->pop(); ScriptDataWord y_param = thread->pop(); @@ -666,7 +681,7 @@ int Script::SF_dropObject(SCRIPTFUNC_PARAMS) { ObjectTable[index].spritelistRn = 9 + sprite_param; ObjectTable[index].x = x_param; ObjectTable[index].y = y_param; - +*/ return SUCCESS; } |