diff options
author | richiesams | 2013-08-10 17:32:57 -0500 |
---|---|---|
committer | richiesams | 2013-08-10 17:32:57 -0500 |
commit | 327d4a1ccff41af28b010679a29168b7e839de29 (patch) | |
tree | 51b44a6bdc05168868658b5f8701fe5a6f1a4f43 | |
parent | 2565f96c55b39f5155d10625def873f2c07207e8 (diff) | |
download | scummvm-rg350-327d4a1ccff41af28b010679a29168b7e839de29.tar.gz scummvm-rg350-327d4a1ccff41af28b010679a29168b7e839de29.tar.bz2 scummvm-rg350-327d4a1ccff41af28b010679a29168b7e839de29.zip |
ZVISION: Implement ActionChangeLocation::execute()
-rw-r--r-- | engines/zvision/actions.cpp | 6 | ||||
-rw-r--r-- | engines/zvision/scr_file_handling.cpp | 3 |
2 files changed, 5 insertions, 4 deletions
diff --git a/engines/zvision/actions.cpp b/engines/zvision/actions.cpp index 8c10837a1f..4fe77c19ce 100644 --- a/engines/zvision/actions.cpp +++ b/engines/zvision/actions.cpp @@ -87,8 +87,10 @@ ActionChangeLocation::ActionChangeLocation(const Common::String &line) { } bool ActionChangeLocation::execute(ZVision *engine) { - // TODO: Implement - return true; + // We can't directly call ScriptManager::ChangeLocationIntern() because doing so clears all the Puzzles, and thus would corrupt the current puzzle checking + engine->getScriptManager()->changeLocation(_world, _room, _node, _view, _x); + // Tell the puzzle system to stop checking any more puzzles + return false; } diff --git a/engines/zvision/scr_file_handling.cpp b/engines/zvision/scr_file_handling.cpp index efd122994d..a47bf0fc0c 100644 --- a/engines/zvision/scr_file_handling.cpp +++ b/engines/zvision/scr_file_handling.cpp @@ -162,8 +162,7 @@ void ScriptManager::parseResults(Common::SeekableReadStream &stream, Common::Lis } else if (line.matchString("*:change_location*", true)) { - - + actionList.push_back(Common::SharedPtr<ResultAction>(new ActionChangeLocation(line))); } else if (line.matchString("*:crossfade*", true)) { |