diff options
author | Strangerke | 2011-10-25 16:38:37 +0200 |
---|---|---|
committer | Strangerke | 2011-10-25 16:39:30 +0200 |
commit | 2967e2cd9172b2d2492e46c33968013b2bcbdbc1 (patch) | |
tree | bd7cbd2724cccb6445366fd58036608d831faf1f /engines/tsage | |
parent | 19be349a71ed6c5f4ed2b8d23fe2dc4952e0c796 (diff) | |
download | scummvm-rg350-2967e2cd9172b2d2492e46c33968013b2bcbdbc1.tar.gz scummvm-rg350-2967e2cd9172b2d2492e46c33968013b2bcbdbc1.tar.bz2 scummvm-rg350-2967e2cd9172b2d2492e46c33968013b2bcbdbc1.zip |
TSAGE: Blue Force - Fix logic of item1 and item6 in scene 370 (boat, bedroom)
Diffstat (limited to 'engines/tsage')
-rw-r--r-- | engines/tsage/blue_force/blueforce_scenes3.cpp | 28 |
1 files changed, 14 insertions, 14 deletions
diff --git a/engines/tsage/blue_force/blueforce_scenes3.cpp b/engines/tsage/blue_force/blueforce_scenes3.cpp index e738f68308..0ec2497395 100644 --- a/engines/tsage/blue_force/blueforce_scenes3.cpp +++ b/engines/tsage/blue_force/blueforce_scenes3.cpp @@ -4783,37 +4783,36 @@ bool Scene370::Laura::startAction(CursorType action, Event &event) { bool Scene370::Item1::startAction(CursorType action, Event &event) { Scene370 *scene = (Scene370 *)BF_GLOBALS._sceneManager._scene; - switch (action) { - case CURSOR_LOOK: + if (action == CURSOR_LOOK) { SceneItem::display2(370, 15); return true; - case CURSOR_USE: + } else if (action == CURSOR_USE) { SceneItem::display2(370, 16); return true; - case INV_COLT45: + } else if (action == INV_COLT45) { if (BF_GLOBALS._sceneObjects->contains(&scene->_green) && (BF_INVENTORY.getObjectScene(INV_GREENS_GUN) != 370)) { scene->_green.setAction(NULL); scene->_sceneMode = 3703; scene->setAction(&scene->_sequenceManager, scene, 3703, &BF_GLOBALS._player, &scene->_green, &scene->_harrison, NULL); return true; } - // Deliberate fall-through - default: + return false; + } else if (action < CURSOR_WALK) // If any other inventory item used + return false; + else // If any other action is used return NamedHotspot::startAction(action, event); - } } bool Scene370::Item6::startAction(CursorType action, Event &event) { Scene370 *scene = (Scene370 *)BF_GLOBALS._sceneManager._scene; - switch (action) { - case CURSOR_LOOK: + if (action == CURSOR_LOOK) { SceneItem::display2(370, 14); return true; - case CURSOR_USE: + } else if (action == CURSOR_USE) { SceneItem::display2(370, 29); return true; - case INV_COLT45: + } else if (action == INV_COLT45) { if (BF_GLOBALS._sceneObjects->contains(&scene->_green) && (BF_INVENTORY.getObjectScene(INV_GREENS_GUN) != 370) && (BF_INVENTORY.getObjectScene(INV_HANDCUFFS) == 1)) { BF_GLOBALS._player.disableControl(); @@ -4822,10 +4821,11 @@ bool Scene370::Item6::startAction(CursorType action, Event &event) { scene->setAction(&scene->_sequenceManager, scene, 3703, &BF_GLOBALS._player, &scene->_green, &scene->_harrison, NULL); return true; } - // Deliberate fall-through - default: return SceneHotspot::startAction(action, event); - } + } else if (action < CURSOR_WALK) // If any other inventory item used + return false; + else // If any other action + return SceneHotspot::startAction(action, event); } |