aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorFilippos Karapetis2007-07-05 03:37:23 +0000
committerFilippos Karapetis2007-07-05 03:37:23 +0000
commit8d81d720d3728987a026f13abe4e2aca0e678a23 (patch)
tree7c7c34b220cac5394e5c31e012e3341c8e4b3344
parent91125a15ea6dc871ed3bffe0ff366ae5d0cb373d (diff)
downloadscummvm-rg350-8d81d720d3728987a026f13abe4e2aca0e678a23.tar.gz
scummvm-rg350-8d81d720d3728987a026f13abe4e2aca0e678a23.tar.bz2
scummvm-rg350-8d81d720d3728987a026f13abe4e2aca0e678a23.zip
Implemented the rest of the differences of the sfScriptGotoScene opcode in IHNM
svn-id: r27916
-rw-r--r--engines/saga/sfuncs.cpp31
1 files changed, 21 insertions, 10 deletions
diff --git a/engines/saga/sfuncs.cpp b/engines/saga/sfuncs.cpp
index e713326661..945d66f328 100644
--- a/engines/saga/sfuncs.cpp
+++ b/engines/saga/sfuncs.cpp
@@ -548,19 +548,20 @@ void Script::sfScriptGotoScene(SCRIPTFUNC_PARAMS) {
sceneNumber = thread->pop();
entrance = thread->pop();
- if (_vm->getGameType() == GType_IHNM)
+ if (_vm->getGameType() == GType_IHNM) {
transition = thread->pop();
- if (sceneNumber < 0) {
- if (_vm->getGameType() == GType_ITE) {
- _vm->shutDown();
- return;
- }
+ _vm->_gfx->setCursor(kCursorBusy);
}
- if (_vm->getGameType() == GType_IHNM) {
- warning("FIXME: implement sfScriptGotoScene differences for IHNM");
+ if ((_vm->getGameType() == GType_ITE && sceneNumber < 0) ||
+ (_vm->getGameType() == GType_IHNM && sceneNumber == 0)) {
+ // TODO: set creditsFlag to true for IHNM
+ _vm->shutDown();
+ return;
+ }
+ if (_vm->getGameType() == GType_IHNM) {
// Since it doesn't look like the IHNM scripts remove the
// cutaway after the intro, this is probably the best place to
// to it.
@@ -574,6 +575,7 @@ void Script::sfScriptGotoScene(SCRIPTFUNC_PARAMS) {
_vm->_interface->setMode(kPanelMain);
}
+ // changeScene calls loadScene which calls setVerb. setVerb resets all pending objects and object flags
if (sceneNumber == -1 && _vm->getGameType() == GType_IHNM) {
// TODO: This is used to return back to the character selection screen in IHNM.
// However, it seems more than this is needed, AM's speech is wrong and no actors
@@ -583,10 +585,19 @@ void Script::sfScriptGotoScene(SCRIPTFUNC_PARAMS) {
_vm->_scene->changeScene(sceneNumber, entrance, (sceneNumber == ITE_SCENE_ENDCREDIT1) ? kTransitionFade : kTransitionNoFade);
}
- //TODO: placard stuff
+ if (_vm->_interface->getMode() == kPanelPlacard ||
+ _vm->_interface->getMode() == kPanelCutaway ||
+ _vm->_interface->getMode() == kPanelVideo) {
+ _vm->_gfx->showCursor(true);
+ _vm->_interface->setMode(kPanelMain);
+ }
+
_pendingVerb = _vm->_script->getVerbType(kVerbNone);
_currentObject[0] = _currentObject[1] = ID_NOTHING;
- showVerb();
+ showVerb(); // calls setStatusText("")
+
+ if (_vm->getGameType() == GType_IHNM)
+ _vm->_gfx->setCursor(kCursorNormal);
}
// Script function #17 (0x11)