aboutsummaryrefslogtreecommitdiff
path: root/engines/parallaction/animation.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'engines/parallaction/animation.cpp')
-rw-r--r--engines/parallaction/animation.cpp6
1 files changed, 5 insertions, 1 deletions
diff --git a/engines/parallaction/animation.cpp b/engines/parallaction/animation.cpp
index 790d9b7ade..7e51cb9826 100644
--- a/engines/parallaction/animation.cpp
+++ b/engines/parallaction/animation.cpp
@@ -574,6 +574,10 @@ DECLARE_INSTRUCTION_OPCODE(null) {
}
+DECLARE_INSTRUCTION_OPCODE(invalid) {
+ error("Can't execute invalid opcode %i", (*_instRunCtxt.inst)->_index);
+}
+
DECLARE_INSTRUCTION_OPCODE(call) {
callFunction((*_instRunCtxt.inst)->_opBase._index, 0);
}
@@ -637,7 +641,7 @@ void jobRunScripts(void *parm, Job *j) {
_vm->_instRunCtxt.modCounter = modCounter;
_vm->_instRunCtxt.suspend = false;
- (_vm->*(_vm->_instructionOpcodes)[(*inst)->_index - 1])();
+ (_vm->*(_vm->_instructionOpcodes)[(*inst)->_index])();
inst = _vm->_instRunCtxt.inst; // handles endloop correctly