[Scummvm-cvs-logs] SF.net SVN: scummvm: [25299] scummvm/trunk/engines/lure

dreammaster at users.sourceforge.net dreammaster at users.sourceforge.net
Wed Jan 31 03:28:04 CET 2007


Revision: 25299
          http://scummvm.svn.sourceforge.net/scummvm/?rev=25299&view=rev
Author:   dreammaster
Date:     2007-01-30 18:28:04 -0800 (Tue, 30 Jan 2007)

Log Message:
-----------
Changed the coveredFlag to have an initial state distinct from true or false

Modified Paths:
--------------
    scummvm/trunk/engines/lure/res_struct.cpp
    scummvm/trunk/engines/lure/res_struct.h

Modified: scummvm/trunk/engines/lure/res_struct.cpp
===================================================================
--- scummvm/trunk/engines/lure/res_struct.cpp	2007-01-31 02:26:16 UTC (rev 25298)
+++ scummvm/trunk/engines/lure/res_struct.cpp	2007-01-31 02:28:04 UTC (rev 25299)
@@ -303,7 +303,7 @@
 	// Initialise runtime fields
 	actionCtr = 0;
 	blockedState = BS_NONE;
-	coveredFlag = false;
+	coveredFlag = VB_INITIAL;
 	talkMessageId = 0;
 	talkDestCharacterId = 0;
 	talkCountdown = 0;
@@ -340,7 +340,7 @@
 	// Write out the runtime fields
 	stream->writeUint16LE(actionCtr);
 	stream->writeUint16LE(blockedState);
-	stream->writeByte(coveredFlag);
+	stream->writeByte((byte)coveredFlag);
 	stream->writeUint16LE(talkMessageId);
 	stream->writeUint16LE(talkDestCharacterId);
 	stream->writeUint16LE(talkCountdown);
@@ -378,7 +378,7 @@
 	// Read in the runtime fields
 	actionCtr = stream->readUint16LE();
 	blockedState = (BlockedState)stream->readUint16LE();
-	coveredFlag = stream->readByte() != 0;
+	coveredFlag = (VariantBool)stream->readByte();
 	talkMessageId = stream->readUint16LE();
 	talkDestCharacterId = stream->readUint16LE();
 	talkCountdown = stream->readUint16LE();

Modified: scummvm/trunk/engines/lure/res_struct.h
===================================================================
--- scummvm/trunk/engines/lure/res_struct.h	2007-01-31 02:26:16 UTC (rev 25298)
+++ scummvm/trunk/engines/lure/res_struct.h	2007-01-31 02:28:04 UTC (rev 25299)
@@ -385,6 +385,8 @@
 
 enum BlockedState {BS_NONE, BS_INITIAL, BS_FINAL};
 
+enum VariantBool {VB_INITIAL, VB_FALSE, VB_TRUE};
+
 class HotspotData {
 public:
 	HotspotData(HotspotResource *rec);
@@ -426,7 +428,7 @@
 	// Runtime fields
 	uint16 actionCtr;
 	BlockedState blockedState;
-	bool coveredFlag;
+	VariantBool coveredFlag;
 	uint16 talkMessageId;
 	uint16 talkDestCharacterId;
 	uint16 talkCountdown;
@@ -696,7 +698,7 @@
 	BOTTLE_FILLED = 18,
 	TALK_INDEX = 19,
 	SACK_CUT = 20,
-	ROOM_EXIT_ANIMATION = 82
+	ROOM_EXIT_ANIMATION = 76
 };
 
 enum GameFlags {


This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.




More information about the Scummvm-git-logs mailing list