[Scummvm-cvs-logs] scummvm master -> 9d93065b0353bef287778ffaf88ad984feca2826

bluegr md5 at scummvm.org
Tue Dec 6 23:32:17 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:
9d93065b03 DREAMWEB: 'moretalk' and 'redes' ported to C++


Commit: 9d93065b0353bef287778ffaf88ad984feca2826
    https://github.com/scummvm/scummvm/commit/9d93065b0353bef287778ffaf88ad984feca2826
Author: Filippos Karapetis (md5 at scummvm.org)
Date: 2011-12-06T14:31:00-08:00

Commit Message:
DREAMWEB: 'moretalk' and 'redes' 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 a270a7f..6b1257c 100755
--- a/devtools/tasmrecover/tasm-recover
+++ b/devtools/tasmrecover/tasm-recover
@@ -407,6 +407,7 @@ generator = cpp(context, "DreamGen", blacklist = [
 	'monmessage',
 	'monprint',
 	'monks2text',
+	'moretalk',
 	'movemap',
 	'multidump',
 	'multiget',
@@ -489,6 +490,7 @@ generator = cpp(context, "DreamGen", blacklist = [
 	'readsetdata',
 	'realcredits',
 	'reconstruct',
+	'redes',
 	'redrawmainscrn',
 	'reelsonscreen',
 	'reexfromopen',
diff --git a/engines/dreamweb/dreamgen.cpp b/engines/dreamweb/dreamgen.cpp
index 28d4634..9d85a47 100644
--- a/engines/dreamweb/dreamgen.cpp
+++ b/engines/dreamweb/dreamgen.cpp
@@ -3716,40 +3716,6 @@ void DreamGenContext::getPersonText() {
 	si = ax;
 }
 
-void DreamGenContext::moreTalk() {
-	STACK_CHECK;
-	_cmp(data.byte(kTalkmode), 0);
-	if (flags.z())
-		goto canmore;
-	redes();
-	return;
-canmore:
-	_cmp(data.byte(kCommandtype), 215);
-	if (flags.z())
-		goto alreadymore;
-	data.byte(kCommandtype) = 215;
-	al = 49;
-	commandOnly();
-alreadymore:
-	ax = data.word(kMousebutton);
-	_cmp(ax, data.word(kOldbutton));
-	if (flags.z())
-		return /* (nomore) */;
-	_and(ax, 1);
-	if (!flags.z())
-		goto domoretalk;
-	return;
-domoretalk:
-	data.byte(kTalkmode) = 2;
-	data.byte(kTalkpos) = 4;
-	_cmp(data.byte(kCharacter), 100);
-	if (flags.c())
-		goto notsecondpart;
-	data.byte(kTalkpos) = 48;
-notsecondpart:
-	doSomeTalk();
-}
-
 void DreamGenContext::doSomeTalk() {
 	STACK_CHECK;
 dospeech:
@@ -3943,44 +3909,6 @@ quitconv:
 	flags._c = true;
  }
 
-void DreamGenContext::redes() {
-	STACK_CHECK;
-	_cmp(data.byte(kCh1playing), 255);
-	if (!flags.z())
-		goto cantredes;
-	_cmp(data.byte(kTalkmode), 2);
-	if (flags.z())
-		goto canredes;
-cantredes:
-	blank();
-	return;
-canredes:
-	_cmp(data.byte(kCommandtype), 217);
-	if (flags.z())
-		goto alreadyreds;
-	data.byte(kCommandtype) = 217;
-	al = 50;
-	commandOnly();
-alreadyreds:
-	ax = data.word(kMousebutton);
-	_and(ax, 1);
-	if (!flags.z())
-		goto doredes;
-	return;
-doredes:
-	delPointer();
-	createPanel();
-	showPanel();
-	showMan();
-	showExit();
-	convIcons();
-	startTalk();
-	readMouse();
-	showPointer();
-	workToScreen();
-	delPointer();
-}
-
 void DreamGenContext::newPlace() {
 	STACK_CHECK;
 	_cmp(data.byte(kNeedtotravel), 1);
diff --git a/engines/dreamweb/dreamgen.h b/engines/dreamweb/dreamgen.h
index 6b0fc9e..878af2e 100644
--- a/engines/dreamweb/dreamgen.h
+++ b/engines/dreamweb/dreamgen.h
@@ -587,7 +587,6 @@ public:
 	void findFirstPath();
 	void useSLab();
 	void useAltar();
-	void moreTalk();
 	void startTalk();
 	void getAnyAd();
 	void endGame();
@@ -643,7 +642,6 @@ public:
 	void selectSlot();
 	void fadeUpMon();
 	void soundEnd();
-	void redes();
 	void manAsleep2();
 	void introMagic2();
 	void introMagic3();
diff --git a/engines/dreamweb/stubs.cpp b/engines/dreamweb/stubs.cpp
index 0598230..e00ebcd 100644
--- a/engines/dreamweb/stubs.cpp
+++ b/engines/dreamweb/stubs.cpp
@@ -3769,4 +3769,57 @@ void DreamGenContext::putBackObStuff() {
 	delPointer();
 }
 
+void DreamGenContext::redes() {
+	if (data.byte(kCh1playing) != 255 || data.byte(kTalkmode) != 2) {
+		blank();
+		return;
+	}
+
+	if (data.byte(kCommandtype) != 217) {
+		data.byte(kCommandtype) = 217;
+		commandOnly(50);
+	}
+
+	if (!(data.word(kMousebutton) & 1))
+		return;
+
+	delPointer();
+	createPanel();
+	showPanel();
+	showMan();
+	showExit();
+	convIcons();
+	startTalk();
+	readMouse();
+	showPointer();
+	workToScreen();
+	delPointer();
+}
+
+void DreamGenContext::moreTalk() {
+	if (data.byte(kTalkmode) != 0) {
+		redes();
+		return;
+	}
+
+	if (data.byte(kCommandtype) != 215) {
+		data.byte(kCommandtype) = 215;
+		commandOnly(49);
+	}
+	
+	if (data.word(kMousebutton) == data.word(kOldbutton))
+		return;	// nomore
+
+	if (!(data.word(kMousebutton) & 1))
+		return;
+
+	data.byte(kTalkmode) = 2;
+	data.byte(kTalkpos) = 4;
+	
+	if (data.byte(kCharacter) < 100)
+		doSomeTalk();	// not second part
+	else
+		data.byte(kTalkpos) = 48;
+}
+
 } // End of namespace DreamGen
diff --git a/engines/dreamweb/stubs.h b/engines/dreamweb/stubs.h
index e96fde3..8b4ede2 100644
--- a/engines/dreamweb/stubs.h
+++ b/engines/dreamweb/stubs.h
@@ -570,5 +570,7 @@
 	void lastDest();
 	void destSelect();
 	void putBackObStuff();
+	void moreTalk();
+	void redes();
 
 #endif






More information about the Scummvm-git-logs mailing list