aboutsummaryrefslogtreecommitdiff
path: root/engines/access/scripts.cpp
diff options
context:
space:
mode:
authorPaul Gilbert2014-08-13 22:23:08 -0400
committerPaul Gilbert2014-08-13 22:23:08 -0400
commit28bfe7374930cd78f722451b8754822a11dd500d (patch)
tree0fd59d1e54f096dbcfd89aeb4b146c6d27f82e48 /engines/access/scripts.cpp
parented645e435a641cc3be95bfe946d2c08d2ab3836b (diff)
downloadscummvm-rg350-28bfe7374930cd78f722451b8754822a11dd500d.tar.gz
scummvm-rg350-28bfe7374930cd78f722451b8754822a11dd500d.tar.bz2
scummvm-rg350-28bfe7374930cd78f722451b8754822a11dd500d.zip
ACCESS: Implemented cmdSpecial script opcode
Diffstat (limited to 'engines/access/scripts.cpp')
-rw-r--r--engines/access/scripts.cpp21
1 files changed, 20 insertions, 1 deletions
diff --git a/engines/access/scripts.cpp b/engines/access/scripts.cpp
index 19633544f4..0e1d421c34 100644
--- a/engines/access/scripts.cpp
+++ b/engines/access/scripts.cpp
@@ -326,7 +326,26 @@ void Scripts::cmdRemoveLast() {
--_vm->_numAnimTimers;
}
-void Scripts::CMDSPECIAL() { error("TODO"); }
+void Scripts::CMDSPECIAL() {
+ _specialFunction = _data->readUint16LE();
+ int p1 = _data->readUint16LE();
+ int p2 = _data->readUint16LE();
+
+ if (_specialFunction == 1) {
+ if (_vm->_establishTable[p2] == 1)
+ return;
+
+ _vm->_screen->savePalette();
+ }
+
+ executeSpecial(_specialFunction, p1, p2);
+
+ if (_specialFunction == 1) {
+ _vm->_screen->restorePalette();
+ _vm->_room->_function = 3;
+ }
+}
+
void Scripts::CMDSETCYCLE() { error("TODO"); }
void Scripts::CMDCYCLE() { error("TODO"); }
void Scripts::CMDCHARSPEAK() { error("TODO"); }