diff options
-rwxr-xr-x | devtools/tasmrecover/tasm-recover | 1 | ||||
-rw-r--r-- | engines/dreamweb/dreamgen.cpp | 31 | ||||
-rw-r--r-- | engines/dreamweb/dreamgen.h | 5 | ||||
-rw-r--r-- | engines/dreamweb/people.cpp | 26 | ||||
-rw-r--r-- | engines/dreamweb/stubs.h | 1 |
5 files changed, 28 insertions, 36 deletions
diff --git a/devtools/tasmrecover/tasm-recover b/devtools/tasmrecover/tasm-recover index 2cd8dd9d16..f253f232fb 100755 --- a/devtools/tasmrecover/tasm-recover +++ b/devtools/tasmrecover/tasm-recover @@ -309,6 +309,7 @@ generator = cpp(context, "DreamGen", blacklist = [ 'initrain', 'input', 'intro', + 'intromagic1', 'inventory', 'isitdescribed', 'isitright', diff --git a/engines/dreamweb/dreamgen.cpp b/engines/dreamweb/dreamgen.cpp index 565034047f..995cd8f001 100644 --- a/engines/dreamweb/dreamgen.cpp +++ b/engines/dreamweb/dreamgen.cpp @@ -789,37 +789,6 @@ smallcandlef: showGameReel(); } -void DreamGenContext::introMagic1() { - STACK_CHECK; - checkSpeed(); - if (!flags.z()) - goto introm1fin; - ax = es.word(bx+3); - _inc(ax); - _cmp(ax, 145); - if (!flags.z()) - goto gotintrom1; - ax = 121; -gotintrom1: - es.word(bx+3) = ax; - _cmp(ax, 121); - if (!flags.z()) - goto introm1fin; - _inc(data.byte(kIntrocount)); - push(es); - push(bx); - intro1Text(); - bx = pop(); - es = pop(); - _cmp(data.byte(kIntrocount), 8); - if (!flags.z()) - goto introm1fin; - _add(data.byte(kMapy), 10); - data.byte(kNowinnewroom) = 1; -introm1fin: - showGameReel(); -} - void DreamGenContext::candles() { STACK_CHECK; checkSpeed(); diff --git a/engines/dreamweb/dreamgen.h b/engines/dreamweb/dreamgen.h index d67c2ad1e6..4bd1e85fb3 100644 --- a/engines/dreamweb/dreamgen.h +++ b/engines/dreamweb/dreamgen.h @@ -577,6 +577,7 @@ public: void introMonks1(); void resetLocation(); void introMonks2(); + void advisor(); void additionalText(); void useElevator5(); void greyscaleSum(); @@ -654,7 +655,7 @@ public: void lockLightOff(); void wearWatch(); void runIntroSeq(); - void advisor(); + void nextColon(); void attendant(); void monks2text(); void clearPalette(); @@ -663,7 +664,6 @@ public: void openHotelDoor(); void blank(); void drinker(); - void nextColon(); void placeFreeObject(); void allPalette(); void adjustRight(); @@ -691,7 +691,6 @@ public: void introMagic2(); void introMagic3(); void edenInBath(); - void introMagic1(); void showDiaryPage(); void useShield(); void getBackToOps(); diff --git a/engines/dreamweb/people.cpp b/engines/dreamweb/people.cpp index ef443380da..508228a786 100644 --- a/engines/dreamweb/people.cpp +++ b/engines/dreamweb/people.cpp @@ -43,7 +43,7 @@ static void (DreamGenContext::*reelCallbacks[57])() = { NULL, &DreamGenContext::businessMan, &DreamGenContext::train, NULL, &DreamGenContext::mugger, &DreamGenContext::helicopter, - &DreamGenContext::introMagic1, &DreamGenContext::introMusic, + NULL, &DreamGenContext::introMusic, &DreamGenContext::introMagic2, &DreamGenContext::candles2, &DreamGenContext::gates, &DreamGenContext::introMagic3, &DreamGenContext::introMonks1, &DreamGenContext::candles, @@ -75,7 +75,7 @@ static void (DreamGenContext::*reelCallbacksCPP[57])(ReelRoutine &) = { &DreamGenContext::rockstar, /*&DreamGenContext::businessMan*/NULL, /*&DreamGenContext::train*/NULL, &DreamGenContext::genericPerson /*aide*/, /*&DreamGenContext::mugger*/NULL, /*&DreamGenContext::helicopter*/NULL, - /*&DreamGenContext::introMagic1*/NULL, /*&DreamGenContext::introMusic*/NULL, + &DreamGenContext::introMagic1, /*&DreamGenContext::introMusic*/NULL, /*&DreamGenContext::introMagic2*/NULL, /*&DreamGenContext::candles2*/NULL, /*&DreamGenContext::gates*/NULL, /*&DreamGenContext::introMagic3*/NULL, /*&DreamGenContext::intromonks1*/NULL, /*&DreamGenContext::candles*/NULL, @@ -353,6 +353,28 @@ void DreamGenContext::drunk(ReelRoutine &routine) { addToPeopleList(&routine); } +void DreamGenContext::introMagic1(ReelRoutine &routine) { + if (checkSpeed(routine)) { + uint16 nextReelPointer = routine.reelPointer() + 1; + if (nextReelPointer == 145) + nextReelPointer = 121; + routine.setReelPointer(nextReelPointer); + if (nextReelPointer == 121) { + ++data.byte(kIntrocount); + push(es); + push(bx); + intro1Text(); + bx = pop(); + es = pop(); + if (data.byte(kIntrocount) == 8) { + data.byte(kMapy) += 10; + data.byte(kNowinnewroom) = 1; + } + } + } + showGameReel(&routine); +} + void DreamGenContext::security(ReelRoutine &routine) { if (routine.reelPointer() == 32) { if (data.byte(kLastweapon) == 1) { diff --git a/engines/dreamweb/stubs.h b/engines/dreamweb/stubs.h index a258424ceb..29a6460d3d 100644 --- a/engines/dreamweb/stubs.h +++ b/engines/dreamweb/stubs.h @@ -410,6 +410,7 @@ void smokeBloke(ReelRoutine &routine); void manAsleep(ReelRoutine &routine); void drunk(ReelRoutine &routine); + void introMagic1(ReelRoutine &routine); void security(ReelRoutine &routine); void singleKey(uint8 key, uint16 x, uint16 y); void loadSaveBox(); |