aboutsummaryrefslogtreecommitdiff
path: root/engines/parallaction/parallaction_ns.cpp
diff options
context:
space:
mode:
authorNicola Mettifogo2008-07-11 13:06:28 +0000
committerNicola Mettifogo2008-07-11 13:06:28 +0000
commit8ed023142a9ce0ee825eb3d6c33759281d68357b (patch)
treefe01c86cc8d04a88fb82a29e79279c25c4e8e922 /engines/parallaction/parallaction_ns.cpp
parentfe655836575214c33c82120e9dd714b95a96e475 (diff)
downloadscummvm-rg350-8ed023142a9ce0ee825eb3d6c33759281d68357b.tar.gz
scummvm-rg350-8ed023142a9ce0ee825eb3d6c33759281d68357b.tar.bz2
scummvm-rg350-8ed023142a9ce0ee825eb3d6c33759281d68357b.zip
Moved program and command execution code out of the engine, into their own brand new
classes. svn-id: r33003
Diffstat (limited to 'engines/parallaction/parallaction_ns.cpp')
-rw-r--r--engines/parallaction/parallaction_ns.cpp10
1 files changed, 7 insertions, 3 deletions
diff --git a/engines/parallaction/parallaction_ns.cpp b/engines/parallaction/parallaction_ns.cpp
index a2217e4a73..850123de97 100644
--- a/engines/parallaction/parallaction_ns.cpp
+++ b/engines/parallaction/parallaction_ns.cpp
@@ -135,12 +135,16 @@ int Parallaction_ns::init() {
initResources();
initFonts();
initCursors();
- initOpcodes();
_locationParser = new LocationParser_ns(this);
_locationParser->init();
_programParser = new ProgramParser_ns(this);
_programParser->init();
+ _cmdExec = new CommandExec_ns(this);
+ _cmdExec->init();
+ _programExec = new ProgramExec_ns(this);
+ _programExec->init();
+
_introSarcData1 = 0;
_introSarcData2 = 1;
_introSarcData3 = 200;
@@ -353,11 +357,11 @@ void Parallaction_ns::changeLocation(char *location) {
// and acommands are executed, so that it can be set again if needed.
_engineFlags &= ~kEngineChangeLocation;
- runCommands(_location._commands);
+ _cmdExec->run(_location._commands);
doLocationEnterTransition();
- runCommands(_location._aCommands);
+ _cmdExec->run(_location._aCommands);
if (_location._hasSound)
_soundMan->playSfx(_location._soundFile, 0, true);