[Scummvm-cvs-logs] scummvm master -> e731d9b8132d0c64dbd115173a600eb977aa50fa
bluegr
md5 at scummvm.org
Thu Dec 8 19:48:46 CET 2011
This automated email contains information about 2 new commits which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .
Summary:
fcb2060445 DREAMWEB: Port 'intromonks1' to C++
e731d9b813 DREAMWEB: Fix warnings
Commit: fcb206044524963e17523bd8f6b1825357459d42
https://github.com/scummvm/scummvm/commit/fcb206044524963e17523bd8f6b1825357459d42
Author: Filippos Karapetis (md5 at scummvm.org)
Date: 2011-12-08T10:43:35-08:00
Commit Message:
DREAMWEB: Port 'intromonks1' to C++
Changed paths:
devtools/tasmrecover/tasm-recover
engines/dreamweb/dreamgen.cpp
engines/dreamweb/dreamgen.h
engines/dreamweb/people.cpp
engines/dreamweb/stubs.h
diff --git a/devtools/tasmrecover/tasm-recover b/devtools/tasmrecover/tasm-recover
index 9a319b9..cba8aa9 100755
--- a/devtools/tasmrecover/tasm-recover
+++ b/devtools/tasmrecover/tasm-recover
@@ -383,6 +383,7 @@ generator = cpp(context, "DreamGen", blacklist = [
'intromagic1',
'intromagic2',
'intromagic3',
+ 'intromonks1',
'intromusic',
'inventory',
'isitdescribed',
diff --git a/engines/dreamweb/dreamgen.cpp b/engines/dreamweb/dreamgen.cpp
index 9c1db94..3a9fb57 100644
--- a/engines/dreamweb/dreamgen.cpp
+++ b/engines/dreamweb/dreamgen.cpp
@@ -523,58 +523,6 @@ gotheavyframe:
addToPeopleList();
}
-void DreamGenContext::introMonks1() {
- STACK_CHECK;
- checkSpeed();
- if (!flags.z())
- goto intromonk1fin;
- ax = es.word(bx+3);
- _inc(ax);
- _cmp(ax, 80);
- if (!flags.z())
- goto notendmonk1;
- _add(data.byte(kMapy), 10);
- data.byte(kNowinnewroom) = 1;
- showGameReel();
- return;
-notendmonk1:
- _cmp(ax, 30);
- if (!flags.z())
- goto gotintromonk1;
- _sub(data.byte(kMapy), 10);
- data.byte(kNowinnewroom) = 1;
- ax = 51;
-gotintromonk1:
- es.word(bx+3) = ax;
- _cmp(ax, 5);
- if (flags.z())
- goto waitstep;
- _cmp(ax, 15);
- if (flags.z())
- goto waitstep;
- _cmp(ax, 25);
- if (flags.z())
- goto waitstep;
- _cmp(ax, 61);
- if (flags.z())
- goto waitstep;
- _cmp(ax, 71);
- if (flags.z())
- goto waitstep;
- goto intromonk1fin;
-waitstep:
- push(es);
- push(bx);
- intro2Text();
- bx = pop();
- es = pop();
- es.byte(bx+6) = -20;
-intromonk1fin:
- showGameReel();
- al = data.byte(kMapy);
- es.byte(bx+2) = al;
-}
-
void DreamGenContext::introMonks2() {
STACK_CHECK;
checkSpeed();
diff --git a/engines/dreamweb/dreamgen.h b/engines/dreamweb/dreamgen.h
index 0fb1452..0fb155b 100644
--- a/engines/dreamweb/dreamgen.h
+++ b/engines/dreamweb/dreamgen.h
@@ -557,7 +557,6 @@ public:
void useCashCard();
void moneyPoke();
void doSomeTalk();
- void introMonks1();
void resetLocation();
void introMonks2();
void greyscaleSum();
diff --git a/engines/dreamweb/people.cpp b/engines/dreamweb/people.cpp
index cd1f2d4..cebe872 100644
--- a/engines/dreamweb/people.cpp
+++ b/engines/dreamweb/people.cpp
@@ -46,7 +46,7 @@ static void (DreamGenContext::*reelCallbacks[57])() = {
NULL, NULL,
NULL, NULL,
NULL, NULL,
- &DreamGenContext::introMonks1, NULL,
+ NULL, NULL,
&DreamGenContext::introMonks2, NULL,
NULL, &DreamGenContext::endGameSeq,
NULL, NULL,
@@ -78,8 +78,8 @@ static void (DreamGenContext::*reelCallbacksCPP[57])(ReelRoutine &) = {
&DreamGenContext::introMagic1, &DreamGenContext::introMusic,
&DreamGenContext::introMagic2, &DreamGenContext::candles2,
&DreamGenContext::gates, &DreamGenContext::introMagic3,
- /*&DreamGenContext::intromonks1*/NULL, &DreamGenContext::candles,
- /*&DreamGenContext::intromonks2*/NULL, &DreamGenContext::handClap,
+ &DreamGenContext::introMonks1, &DreamGenContext::candles,
+ /*&DreamGenContext::introMonks2*/NULL, &DreamGenContext::handClap,
&DreamGenContext::monkAndRyan, /*&DreamGenContext::endGameSeq*/NULL,
&DreamGenContext::priest, &DreamGenContext::madman,
&DreamGenContext::madmansTelly, &DreamGenContext::alleyBarkSound,
@@ -688,4 +688,39 @@ void DreamGenContext::copper(ReelRoutine &routine) {
addToPeopleList(&routine);
}
+void DreamGenContext::introMonks1(ReelRoutine &routine) {
+ if (checkSpeed(routine)) {
+ uint16 nextReelPointer = routine.reelPointer() + 1;
+
+ if (nextReelPointer == 80) {
+ data.byte(kMapy) += 10;
+ data.byte(kNowinnewroom) = 1;
+ showGameReel(&routine);
+ return;
+ } else if (nextReelPointer == 30) {
+ data.byte(kMapy) -= 10;
+ data.byte(kNowinnewroom) = 1;
+ nextReelPointer = 51;
+ }
+
+ routine.setReelPointer(nextReelPointer);
+
+ if (nextReelPointer == 5 || nextReelPointer == 15 ||
+ nextReelPointer == 25 || nextReelPointer == 61 ||
+ nextReelPointer == 71) {
+ // Wait step
+ push(es);
+ push(bx);
+ intro2Text();
+ bx = pop();
+ es = pop();
+ routine.counter = -20;
+ }
+ }
+
+intromonk1fin:
+ showGameReel(&routine);
+ routine.mapY = data.byte(kMapy);
+}
+
} // End of namespace DreamGen
diff --git a/engines/dreamweb/stubs.h b/engines/dreamweb/stubs.h
index f1dd998..27268bb 100644
--- a/engines/dreamweb/stubs.h
+++ b/engines/dreamweb/stubs.h
@@ -424,6 +424,7 @@
void priestText(ReelRoutine &routine);
void monkAndRyan(ReelRoutine &routine);
void copper(ReelRoutine &routine);
+ void introMonks1(ReelRoutine &routine);
void singleKey(uint8 key, uint16 x, uint16 y);
void loadSaveBox();
void loadKeypad();
Commit: e731d9b8132d0c64dbd115173a600eb977aa50fa
https://github.com/scummvm/scummvm/commit/e731d9b8132d0c64dbd115173a600eb977aa50fa
Author: Filippos Karapetis (md5 at scummvm.org)
Date: 2011-12-08T10:47:55-08:00
Commit Message:
DREAMWEB: Fix warnings
Changed paths:
engines/dreamweb/people.cpp
engines/dreamweb/stubs.cpp
diff --git a/engines/dreamweb/people.cpp b/engines/dreamweb/people.cpp
index cebe872..d87a5e3 100644
--- a/engines/dreamweb/people.cpp
+++ b/engines/dreamweb/people.cpp
@@ -714,11 +714,10 @@ void DreamGenContext::introMonks1(ReelRoutine &routine) {
intro2Text();
bx = pop();
es = pop();
- routine.counter = -20;
+ routine.counter = (uint8)-20;
}
}
-intromonk1fin:
showGameReel(&routine);
routine.mapY = data.byte(kMapy);
}
diff --git a/engines/dreamweb/stubs.cpp b/engines/dreamweb/stubs.cpp
index 48cf3d8..465cb68 100644
--- a/engines/dreamweb/stubs.cpp
+++ b/engines/dreamweb/stubs.cpp
@@ -3852,8 +3852,8 @@ void DreamGenContext::watchReel() {
++data.word(kReeltohold);
}
if (data.word(kReeltohold) == data.word(kEndofholdreel)) {
- data.word(kReeltohold) = -1;
- data.byte(kWatchmode) = -1;
+ data.word(kReeltohold) = 0xFFFF;
+ data.byte(kWatchmode) = 0xFF;
data.byte(kDestination) = data.byte(kDestafterhold);
data.byte(kFinaldest) = data.byte(kDestafterhold);
autoSetWalk();
More information about the Scummvm-git-logs
mailing list