[Scummvm-cvs-logs] scummvm master -> 6df11b314db7b32720d1754b8e116f7f32c7e462

tramboi bertrand_augereau at yahoo.fr
Sun Dec 4 13:46:20 CET 2011


This automated email contains information about 1 new commit which have been
pushed to the 'scummvm' repo located at https://github.com/scummvm/scummvm .

Summary:
6df11b314d DREAMWEB: Ported 'drunk' to C++


Commit: 6df11b314db7b32720d1754b8e116f7f32c7e462
    https://github.com/scummvm/scummvm/commit/6df11b314db7b32720d1754b8e116f7f32c7e462
Author: Bertrand Augereau (bertrand_augereau at yahoo.fr)
Date: 2011-12-04T06:44:03-08:00

Commit Message:
DREAMWEB: Ported 'drunk' 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 e84c199..3622ba6 100755
--- a/devtools/tasmrecover/tasm-recover
+++ b/devtools/tasmrecover/tasm-recover
@@ -196,6 +196,7 @@ generator = cpp(context, "DreamGen", blacklist = [
 	'doshake',
 	'drawflags',
 	'drawfloor',
+	'drunk',
 	'dumpblink',
 	'dumpeverything',
 	'dumpmap',
diff --git a/engines/dreamweb/dreamgen.cpp b/engines/dreamweb/dreamgen.cpp
index 7a7b34a..39c5d0f 100644
--- a/engines/dreamweb/dreamgen.cpp
+++ b/engines/dreamweb/dreamgen.cpp
@@ -1527,18 +1527,6 @@ void DreamGenContext::priestText() {
 	setupTimedUse();
 }
 
-void DreamGenContext::drunk() {
-	STACK_CHECK;
-	_cmp(data.byte(kGeneraldead), 0);
-	if (!flags.z())
-		return /* (trampgone) */;
-	al = es.byte(bx+7);
-	_and(al, 127);
-	es.byte(bx+7) = al;
-	showGameReel();
-	addToPeopleList();
-}
-
 void DreamGenContext::advisor() {
 	STACK_CHECK;
 	checkSpeed();
diff --git a/engines/dreamweb/dreamgen.h b/engines/dreamweb/dreamgen.h
index e570bae..1264eb8 100644
--- a/engines/dreamweb/dreamgen.h
+++ b/engines/dreamweb/dreamgen.h
@@ -850,7 +850,6 @@ public:
 	void findPathOfPoint();
 	void isSetObOnMap();
 	void getDestInfo();
-	void drunk();
 	void setupTimedUse();
 	void grafittiDoor();
 	void nextDest();
diff --git a/engines/dreamweb/people.cpp b/engines/dreamweb/people.cpp
index 5aef251..4ab30c6 100644
--- a/engines/dreamweb/people.cpp
+++ b/engines/dreamweb/people.cpp
@@ -28,7 +28,7 @@ static void (DreamGenContext::*reelCallbacks[57])() = {
 	NULL, NULL,
 	NULL, &DreamGenContext::edenInBath,
 	NULL, NULL,
-	NULL, &DreamGenContext::drunk,
+	NULL, NULL,
 	&DreamGenContext::receptionist, NULL,
 	NULL, &DreamGenContext::louis,
 	&DreamGenContext::louisChair, &DreamGenContext::soldier1,
@@ -60,7 +60,7 @@ static void (DreamGenContext::*reelCallbacksCPP[57])(ReelRoutine &) = {
 	&DreamGenContext::gamer, &DreamGenContext::sparkyDrip,
 	&DreamGenContext::eden, /*&DreamGenContext::edenInBath*/NULL,
 	&DreamGenContext::sparky, &DreamGenContext::smokeBloke,
-	&DreamGenContext::manAsleep, /*&DreamGenContext::drunk*/NULL,
+	&DreamGenContext::manAsleep, &DreamGenContext::drunk,
 	/*&DreamGenContext::receptionist*/NULL, &DreamGenContext::maleFan,
 	&DreamGenContext::femaleFan, /*&DreamGenContext::louis*/NULL,
 	/*&DreamGenContext::louisChair*/NULL, /*&DreamGenContext::soldier1*/NULL,
@@ -354,5 +354,15 @@ void DreamGenContext::manAsleep(ReelRoutine &routine) {
 	addToPeopleList(&routine);
 }
 
+
+void DreamGenContext::drunk(ReelRoutine &routine) {
+	_cmp(data.byte(kGeneraldead), 0);
+	if (data.byte(kGeneraldead))
+		return;
+	routine.b7 &= 127;
+	showGameReel(&routine);
+	addToPeopleList(&routine);
+}
+
 } /*namespace dreamgen */
 
diff --git a/engines/dreamweb/stubs.h b/engines/dreamweb/stubs.h
index 94339b9..cc168d4 100644
--- a/engines/dreamweb/stubs.h
+++ b/engines/dreamweb/stubs.h
@@ -399,6 +399,7 @@
 	void madmansTelly(ReelRoutine &routine);
 	void smokeBloke(ReelRoutine &routine);
 	void manAsleep(ReelRoutine &routine);
+	void drunk(ReelRoutine &routine);
 	void singleKey(uint8 key, uint16 x, uint16 y);
 	void showKeypad();
 	void showOuterPad();






More information about the Scummvm-git-logs mailing list