[Scummvm-cvs-logs] CVS: scummvm/scumm help.cpp,1.11,1.12 imuse_digi.cpp,1.54,1.55 resource.cpp,1.172,1.173 script_v6.cpp,1.209,1.210 scumm.h,1.321,1.322 scummvm.cpp,2.476,2.477 sound.cpp,1.271,1.272 string.cpp,1.165,1.166

Travis Howell kirben at users.sourceforge.net
Thu Nov 13 02:52:03 CET 2003


Update of /cvsroot/scummvm/scummvm/scumm
In directory sc8-pr-cvs1:/tmp/cvs-serv17218/scumm

Modified Files:
	help.cpp imuse_digi.cpp resource.cpp script_v6.cpp scumm.h 
	scummvm.cpp sound.cpp string.cpp 
Log Message:



Index: help.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/help.cpp,v
retrieving revision 1.11
retrieving revision 1.12
diff -u -d -r1.11 -r1.12
--- help.cpp	5 Nov 2003 20:47:32 -0000	1.11
+++ help.cpp	13 Nov 2003 10:51:01 -0000	1.12
@@ -47,6 +47,7 @@
 	case GID_DIG:
 	case GID_FT:
 	case GID_CMI:
+	case GID_FTDEMO:
 		return 3;
 		break;  
 /*	TODO - I don't know the controls for these games
@@ -215,6 +216,7 @@
 			ADD_BIND("b", "Black and White / Color");
 			break;
 		case GID_FT:
+		case GID_FTDEMO:
 			ADD_BIND("e", "Eyes");
 			ADD_BIND("t", "Tongue");
 			ADD_BIND("i", "Inventory");

Index: imuse_digi.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/imuse_digi.cpp,v
retrieving revision 1.54
retrieving revision 1.55
diff -u -d -r1.54 -r1.55
--- imuse_digi.cpp	8 Nov 2003 21:59:32 -0000	1.54
+++ imuse_digi.cpp	13 Nov 2003 10:51:01 -0000	1.55
@@ -1066,7 +1066,7 @@
 					return 0;
 				}
 			}
-		} else if (_scumm->_gameId == GID_FT) {
+		} else if (_scumm->_gameId == GID_FT || _scumm->_gameId == GID_FTDEMO) {
 			for (l = 0;; l++) {
 				if (_ftStateMusicTable[l].index == -1) {
 					return 1;
@@ -1113,7 +1113,7 @@
 					return 0;
 				}
 			}
-		} else if (_scumm->_gameId == GID_FT) {
+		} else if (_scumm->_gameId == GID_FT || _scumm->_gameId == GID_FTDEMO) {
 			for (l = 0;; l++) {
 				if (_ftSeqMusicTable[l].index == -1) {
 					return 1;

Index: resource.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/resource.cpp,v
retrieving revision 1.172
retrieving revision 1.173
diff -u -d -r1.172 -r1.173
--- resource.cpp	8 Nov 2003 21:59:32 -0000	1.172
+++ resource.cpp	13 Nov 2003 10:51:02 -0000	1.173
@@ -87,7 +87,13 @@
 				if (room > 0 && (_version == 8))
 					VAR(VAR_CURRENTDISK) = res.roomno[rtRoom][room];
 				sprintf(buf, "%s.la%d", _gameName.c_str(), room == 0 ? 0 : res.roomno[rtRoom][room]);
-				sprintf(buf2, "%s.%.3d", _gameName.c_str(), room == 0 ? 0 : res.roomno[rtRoom][room]);
+
+				// FIXME: Now it is not possible to have target file and
+				// main resource file named differently
+				if (_gameId == GID_FTDEMO)
+					sprintf(buf2, "ft.%.3d", room == 0 ? 0 : res.roomno[rtRoom][room]);
+				else
+					sprintf(buf2, "%s.%.3d", _gameName.c_str(), room == 0 ? 0 : res.roomno[rtRoom][room]);
 			} else if (_features & GF_HUMONGOUS)
 				sprintf(buf, "%s.he%.1d", _gameName.c_str(), room == 0 ? 0 : res.roomno[rtRoom][room]);
 			else {
@@ -2069,7 +2075,11 @@
 		_numCostumes = _fileHandle.readUint16LE();
 
 		_objectRoomTable = (byte *)calloc(_numGlobalObjects, 1);
-		_numGlobalScripts = 2000;
+
+		if (_gameId == GID_FTDEMO)
+			_numGlobalScripts = 300;
+		else
+			_numGlobalScripts = 2000;
 
 		_shadowPaletteSize = NUM_SHADOW_PALETTE * 256;
 	// FIXME better check for the more recent windows based humongous games...

Index: script_v6.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/script_v6.cpp,v
retrieving revision 1.209
retrieving revision 1.210
diff -u -d -r1.209 -r1.210
--- script_v6.cpp	11 Nov 2003 13:47:53 -0000	1.209
+++ script_v6.cpp	13 Nov 2003 10:51:02 -0000	1.210
@@ -1814,7 +1814,7 @@
 	// Full Throttle implements conversation by creating new verbs, one
 	// for each option, but it never tells when to actually draw them.
 
-	if (_gameId == GID_FT)
+	if (_gameId == GID_FT || _gameId == GID_FTDEMO)
 		_verbRedraw = true;
 
 	op = fetchScriptByte();
@@ -2411,8 +2411,18 @@
 				// INSANE mode 0: SMUSH movie playback
 				if (args[1] == 0) {
 					sp->play((char *)getStringAddressVar(VAR_VIDEONAME), getGameDataPath());
-				} else if (_gameId == GID_FT) {
-					int insaneMode = readArray(233,0,0);
+				} else if (_gameId == GID_FT || _gameId == GID_FTDEMO) {
+					int insaneVarNum;
+					int insaneMode;
+
+					if (_gameId == GID_FTDEMO)
+						insaneVarNum = 232;
+					else
+						insaneVarNum = 233;
+
+					insaneMode = readArray(insaneVarNum,0,0);
+
+					// FIXME: FT Demo has different Insane
 					debug(1, "FT_INSANE Mode: %d", insaneMode);
 						switch (insaneMode) {
 						case 0:
@@ -2425,19 +2435,19 @@
 							sp->play("tovista1.san", getGameDataPath());
 							break;
 						case 3:
-							if (readArray(233,0,50) == 0) {
+							if (readArray(insaneVarNum,0,50) == 0) {
 								InfoDialog info(this, "Set MineRoad - You can now jump the gorge.");
 								runDialog(info);
 
-								writeArray(233, 0, 50, 1); // INSANE callback: Chain
-								writeArray(233, 0, 51, 1); // INSANE callback: Chainsaw
-								writeArray(233, 0, 52, 1); // INSANE callback: Mace
-								writeArray(233, 0, 53, 1); // INSANE callback: 2x4
-								writeArray(233, 0, 54, 1); // INSANE callback: Wrench
-								writeArray(233, 0, 55, 1); // INSANE callback: Dust
+								writeArray(insaneVarNum, 0, 50, 1); // INSANE callback: Chain
+								writeArray(insaneVarNum, 0, 51, 1); // INSANE callback: Chainsaw
+								writeArray(insaneVarNum, 0, 52, 1); // INSANE callback: Mace
+								writeArray(insaneVarNum, 0, 53, 1); // INSANE callback: 2x4
+								writeArray(insaneVarNum, 0, 54, 1); // INSANE callback: Wrench
+								writeArray(insaneVarNum, 0, 55, 1); // INSANE callback: Dust
 
-								writeArray(233, 0, 8, 1);  // INSANE callback: Give Googles
-								writeArray(233, 0, 7, 1);  // INSANE callback: Give nitro fuel
+								writeArray(insaneVarNum, 0, 8, 1);  // INSANE callback: Give Googles
+								writeArray(insaneVarNum, 0, 7, 1);  // INSANE callback: Give nitro fuel
 
 								putState(235, 1);	   // Cheat and activate Ramp
 								writeVar(142 | 0x8000, 1); // Cheat and activate auto-booster (fan)

Index: scumm.h
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/scumm.h,v
retrieving revision 1.321
retrieving revision 1.322
diff -u -d -r1.321 -r1.322
--- scumm.h	10 Nov 2003 23:40:48 -0000	1.321
+++ scumm.h	13 Nov 2003 10:51:02 -0000	1.322
@@ -189,7 +189,8 @@
 	GID_PUTTDEMO,
 	GID_PUTTPUTT,
 	GID_PJSDEMO,
-	GID_MONKEY_SEGA
+	GID_MONKEY_SEGA,
+	GID_FTDEMO
 };
 
 #define _maxRooms res.num[rtRoom]

Index: scummvm.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/scummvm.cpp,v
retrieving revision 2.476
retrieving revision 2.477
diff -u -d -r2.476 -r2.477
--- scummvm.cpp	11 Nov 2003 00:40:35 -0000	2.476
+++ scummvm.cpp	13 Nov 2003 10:51:02 -0000	2.477
@@ -188,6 +188,8 @@
 	 GF_NEW_OPCODES | GF_NEW_COSTUMES | GF_NEW_CAMERA | GF_DIGI_IMUSE},
 	{"ftdemo", "Full Throttle (Mac Demo)", GID_FT, 7, MDT_NONE,
 	 GF_NEW_OPCODES | GF_NEW_COSTUMES | GF_NEW_CAMERA | GF_DIGI_IMUSE},
+	{"ftpcdemo", "Full Throttle (Demo)", GID_FTDEMO, 7, MDT_NONE,
+	 GF_NEW_OPCODES | GF_NEW_COSTUMES | GF_NEW_CAMERA | GF_DIGI_IMUSE},
 
 	{"dig", "The Dig", GID_DIG, 7, MDT_NONE,
 	 GF_NEW_OPCODES | GF_NEW_COSTUMES | GF_NEW_CAMERA | GF_DIGI_IMUSE},
@@ -1482,7 +1484,7 @@
 		// texts have to be drawn before the blast objects. Unless
 		// someone can think of a better way to achieve this effect.
 
-		if (_gameId == GID_FT) {
+		if (_gameId == GID_FT || _gameId == GID_FTDEMO) {
 			drawBlastTexts();
 			drawBlastObjects();
 		} else {
@@ -2769,6 +2771,10 @@
 			strcpy(detectName2, g->gameName);
 			if (g->features & GF_HUMONGOUS) {
 				strcat(detectName2, ".he0");
+			} else if (g->id == GID_FTDEMO) {
+				// FIXME: Now it is not possible to have target file and
+				// main resource file named differently
+				strcpy(detectName, "ft.000");
 			} else if (g->version >= 7) {
 				strcat(detectName2, ".la0");
 			} else

Index: sound.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/sound.cpp,v
retrieving revision 1.271
retrieving revision 1.272
diff -u -d -r1.271 -r1.272
--- sound.cpp	12 Nov 2003 07:05:52 -0000	1.271
+++ sound.cpp	13 Nov 2003 10:51:02 -0000	1.272
@@ -120,7 +120,7 @@
 		_scumm->ensureResourceLoaded(rtSound, sound);
 		addSoundToQueue2(sound);
 	} else {
-		// WARNING ! This may break something, maybe this sould be put inside if (_gameID == GID_FT) ? 
+		// WARNING ! This may break something, maybe this sould be put inside if (_gameID == GID_FT || _gameID == GID_FTDEMO) ? 
 		// But why addSoundToQueue should not queue sound ?
 		_scumm->ensureResourceLoaded(rtSound, sound);
 		addSoundToQueue2(sound);

Index: string.cpp
===================================================================
RCS file: /cvsroot/scummvm/scummvm/scumm/string.cpp,v
retrieving revision 1.165
retrieving revision 1.166
diff -u -d -r1.165 -r1.166
--- string.cpp	8 Nov 2003 21:59:32 -0000	1.165
+++ string.cpp	13 Nov 2003 10:51:02 -0000	1.166
@@ -401,7 +401,7 @@
 	// and never time out. We can't do it blindly for all games, because
 	// it causes problem with the FOA intro.
 
-	if (_gameId == GID_FT && a == 4)
+	if ((_gameId == GID_FT || _gameId == GID_FTDEMO) && a == 4)
 		_talkDelay = -1;
 
 	if (!buf[0]) {





More information about the Scummvm-git-logs mailing list