[Scummvm-cvs-logs] scummvm master -> 7843073c0eba240e5270be90c87bb708cce2d2cc

tramboi bertrand_augereau at yahoo.fr
Wed Nov 23 15:26:44 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:
7843073c0e DREAMWEB: 'autolook' ported to C++


Commit: 7843073c0eba240e5270be90c87bb708cce2d2cc
    https://github.com/scummvm/scummvm/commit/7843073c0eba240e5270be90c87bb708cce2d2cc
Author: Bertrand Augereau (bertrand_augereau at yahoo.fr)
Date: 2011-11-23T06:25:52-08:00

Commit Message:
DREAMWEB: 'autolook' ported to C++

Changed paths:
    devtools/tasmrecover/tasm-recover
    engines/dreamweb/dreamgen.cpp
    engines/dreamweb/dreamgen.h
    engines/dreamweb/stubs.cpp
    engines/dreamweb/stubs.h



diff --git a/devtools/tasmrecover/tasm-recover b/devtools/tasmrecover/tasm-recover
index fab0941..1d5264f 100755
--- a/devtools/tasmrecover/tasm-recover
+++ b/devtools/tasmrecover/tasm-recover
@@ -272,6 +272,7 @@ generator = cpp(context, "DreamGen", blacklist = [
 	'createpanel',
 	'createpanel2',
 	'findroominloc',
+	'autolook',
 	'reelsonscreen',
 	'reconstruct',
 	], skip_output = [
diff --git a/engines/dreamweb/dreamgen.cpp b/engines/dreamweb/dreamgen.cpp
index 8e5a784..34fa14c 100644
--- a/engines/dreamweb/dreamgen.cpp
+++ b/engines/dreamweb/dreamgen.cpp
@@ -4894,29 +4894,6 @@ void DreamGenContext::drawfloor() {
 	es = pop();
 }
 
-void DreamGenContext::autolook() {
-	STACK_CHECK;
-	ax = data.word(kMousex);
-	_cmp(ax, data.word(kOldx));
-	if (!flags.z())
-		goto diffmouse;
-	ax = data.word(kMousey);
-	_cmp(ax, data.word(kOldy));
-	if (!flags.z())
-		goto diffmouse;
-	_dec(data.word(kLookcounter));
-	_cmp(data.word(kLookcounter), 0);
-	if (!flags.z())
-		return /* (noautolook) */;
-	_cmp(data.word(kWatchingtime), 0);
-	if (!flags.z())
-		return /* (noautolook) */;
-	dolook();
-	return;
-diffmouse:
-	data.word(kLookcounter) = 1000;
-}
-
 void DreamGenContext::look() {
 	STACK_CHECK;
 	_cmp(data.word(kWatchingtime), 0);
diff --git a/engines/dreamweb/dreamgen.h b/engines/dreamweb/dreamgen.h
index 6bed222..606961c 100644
--- a/engines/dreamweb/dreamgen.h
+++ b/engines/dreamweb/dreamgen.h
@@ -378,7 +378,6 @@ public:
 	static const uint16 addr_redrawmainscrn = 0xc478;
 	static const uint16 addr_dolook = 0xc474;
 	static const uint16 addr_look = 0xc470;
-	static const uint16 addr_autolook = 0xc46c;
 	static const uint16 addr_drawfloor = 0xc428;
 	static const uint16 addr_deleteextext = 0xc420;
 	static const uint16 addr_deleteexframe = 0xc41c;
@@ -1586,7 +1585,7 @@ public:
 	void dosreturn();
 	void wheelsound();
 	void actualsave();
-	void autolook();
+	//void autolook();
 	void playguitar();
 	//void showreelframe();
 	void searchforsame();
diff --git a/engines/dreamweb/stubs.cpp b/engines/dreamweb/stubs.cpp
index 73b7b27..bd3439a 100644
--- a/engines/dreamweb/stubs.cpp
+++ b/engines/dreamweb/stubs.cpp
@@ -2260,5 +2260,19 @@ void DreamGenContext::findroominloc() {
 	data.byte(kRoomnum) = roomNum;
 }
 
+void DreamGenContext::autolook() {
+	if ((data.word(kMousex) != data.word(kOldx)) || (data.word(kMousey) != data.word(kOldy))) {
+		data.word(kLookcounter) = 1000;
+		return;
+	}
+
+	--data.word(kLookcounter);
+	if (data.word(kLookcounter))
+		return;
+	if (data.word(kWatchingtime))
+		return;
+	dolook();
+}
+
 } /*namespace dreamgen */
 
diff --git a/engines/dreamweb/stubs.h b/engines/dreamweb/stubs.h
index 2a9a068..39d1758 100644
--- a/engines/dreamweb/stubs.h
+++ b/engines/dreamweb/stubs.h
@@ -332,4 +332,5 @@
 	void findroominloc();
 	void reelsonscreen();
 	void reconstruct();
+	void autolook();
 






More information about the Scummvm-git-logs mailing list