aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBertrand Augereau2011-08-11 12:33:33 +0200
committerBertrand Augereau2011-08-11 12:33:33 +0200
commita8c619d7ad3d78cd218c2f1af5ec13a58a02e0be (patch)
tree79686bc3e0d9069160c0eb61a18454f4c70a8c82
parentb6a8e2e98cb59f4edc3c6e9441b894dd1237a745 (diff)
downloadscummvm-rg350-a8c619d7ad3d78cd218c2f1af5ec13a58a02e0be.tar.gz
scummvm-rg350-a8c619d7ad3d78cd218c2f1af5ec13a58a02e0be.tar.bz2
scummvm-rg350-a8c619d7ad3d78cd218c2f1af5ec13a58a02e0be.zip
DREAMWEB: 'dealwithspecial' has a better signature
-rw-r--r--engines/dreamweb/stubs.cpp26
-rw-r--r--engines/dreamweb/stubs.h2
2 files changed, 13 insertions, 15 deletions
diff --git a/engines/dreamweb/stubs.cpp b/engines/dreamweb/stubs.cpp
index 41f834b3d5..688fd936a6 100644
--- a/engines/dreamweb/stubs.cpp
+++ b/engines/dreamweb/stubs.cpp
@@ -800,32 +800,32 @@ void DreamGenContext::fillspace() {
memset(ds.ptr(dx, cx), al, cx);
}
-void DreamGenContext::dealwithspecial() {
- uint8 type = al - 220;
+void DreamGenContext::dealwithspecial(uint8 firstParam, uint8 secondParam) {
+ uint8 type = firstParam - 220;
if (type == 0) {
- al = ah;
+ al = secondParam;
placesetobject();
data.byte(kHavedoneobs) = 1;
} else if (type == 1) {
- al = ah;
+ al = secondParam;
removesetobject();
data.byte(kHavedoneobs) = 1;
} else if (type == 2) {
- al = ah;
+ al = secondParam;
placefreeobject();
data.byte(kHavedoneobs) = 1;
} else if (type == 3) {
- al = ah;
+ al = secondParam;
removefreeobject();
data.byte(kHavedoneobs) = 1;
} else if (type == 4) {
switchryanoff();
} else if (type == 5) {
- data.byte(kTurntoface) = ah;
- data.byte(kFacing) = ah;
+ data.byte(kTurntoface) = secondParam;
+ data.byte(kFacing) = secondParam;
switchryanon();
} else if (type == 6) {
- data.byte(kNewlocation) = ah;
+ data.byte(kNewlocation) = secondParam;
} else {
movemap();
}
@@ -835,13 +835,11 @@ void DreamGenContext::plotreel() {
getreelstart();
Reel *reel = (Reel *)es.ptr(si, sizeof(Reel));
while (true) {
- al = reel->x;
- ah = reel->y;
- if (al < 220)
+ if (reel->x < 220)
break;
- if (al == 255)
+ if (reel->x == 255)
break;
- dealwithspecial();
+ dealwithspecial(reel->x, reel->y);
++data.word(kReelpointer);
reel += 8;
}
diff --git a/engines/dreamweb/stubs.h b/engines/dreamweb/stubs.h
index edaded67df..7485f095c2 100644
--- a/engines/dreamweb/stubs.h
+++ b/engines/dreamweb/stubs.h
@@ -107,7 +107,7 @@
void cancelch0();
void cancelch1();
void plotreel();
- void dealwithspecial();
+ void dealwithspecial(uint8 firstParam, uint8 secondParam);
void zoom();
void crosshair();
void showrain();