aboutsummaryrefslogtreecommitdiff
path: root/engines/parallaction/objects.h
diff options
context:
space:
mode:
authorNicola Mettifogo2009-03-23 11:38:09 +0000
committerNicola Mettifogo2009-03-23 11:38:09 +0000
commitd18274d0ee2bf8effcb36b726fc833503f7924aa (patch)
tree33eb6cd429e8d86e0f923370661765f30086f55d /engines/parallaction/objects.h
parentca993d8b00e54c8523b5b9e708c94d3fc871e6db (diff)
downloadscummvm-rg350-d18274d0ee2bf8effcb36b726fc833503f7924aa.tar.gz
scummvm-rg350-d18274d0ee2bf8effcb36b726fc833503f7924aa.tar.bz2
scummvm-rg350-d18274d0ee2bf8effcb36b726fc833503f7924aa.zip
Implemented all variants of IF script instruction. Program class has been changed to store an Array of instruction instead of a List, so that references to instructions are integers.
svn-id: r39631
Diffstat (limited to 'engines/parallaction/objects.h')
-rw-r--r--engines/parallaction/objects.h16
1 files changed, 7 insertions, 9 deletions
diff --git a/engines/parallaction/objects.h b/engines/parallaction/objects.h
index 37ebc54659..89ed1350bd 100644
--- a/engines/parallaction/objects.h
+++ b/engines/parallaction/objects.h
@@ -49,7 +49,7 @@ typedef Common::SharedPtr<Animation> AnimationPtr;
typedef Common::List<AnimationPtr> AnimationList;
typedef Common::SharedPtr<Instruction> InstructionPtr;
-typedef Common::List<InstructionPtr> InstructionList;
+typedef Common::Array<InstructionPtr> InstructionList;
typedef Common::List<Common::Point> PointList;
@@ -468,7 +468,7 @@ struct Instruction {
char *_text;
char *_text2;
int _y;
- InstructionList::iterator _endif;
+ uint32 _endif;
Instruction();
~Instruction();
@@ -483,16 +483,14 @@ enum {
struct Program {
AnimationPtr _anim;
-
LocalVariable *_locals;
- uint16 _loopCounter;
-
- uint16 _numLocals;
+ uint16 _loopCounter;
+ uint16 _numLocals;
- InstructionList::iterator _ip;
- InstructionList::iterator _loopStart;
- InstructionList _instructions;
+ uint32 _ip;
+ uint32 _loopStart;
+ InstructionList _instructions;
uint32 _status;