aboutsummaryrefslogtreecommitdiff
path: root/engines/lure
diff options
context:
space:
mode:
authorPaul Gilbert2007-01-31 02:28:04 +0000
committerPaul Gilbert2007-01-31 02:28:04 +0000
commit19960461216a245da32708099b7bd8cee74ad654 (patch)
treee5e78ab7717d4a66fa1520e28e655d9ec5594ada /engines/lure
parent9d474d62582c152c0d9b47e86b1880dca3b0da51 (diff)
downloadscummvm-rg350-19960461216a245da32708099b7bd8cee74ad654.tar.gz
scummvm-rg350-19960461216a245da32708099b7bd8cee74ad654.tar.bz2
scummvm-rg350-19960461216a245da32708099b7bd8cee74ad654.zip
Changed the coveredFlag to have an initial state distinct from true or false
svn-id: r25299
Diffstat (limited to 'engines/lure')
-rw-r--r--engines/lure/res_struct.cpp6
-rw-r--r--engines/lure/res_struct.h6
2 files changed, 7 insertions, 5 deletions
diff --git a/engines/lure/res_struct.cpp b/engines/lure/res_struct.cpp
index a5c4bc45e0..b9d994b798 100644
--- a/engines/lure/res_struct.cpp
+++ b/engines/lure/res_struct.cpp
@@ -303,7 +303,7 @@ HotspotData::HotspotData(HotspotResource *rec) {
// Initialise runtime fields
actionCtr = 0;
blockedState = BS_NONE;
- coveredFlag = false;
+ coveredFlag = VB_INITIAL;
talkMessageId = 0;
talkDestCharacterId = 0;
talkCountdown = 0;
@@ -340,7 +340,7 @@ void HotspotData::saveToStream(WriteStream *stream) {
// 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 @@ void HotspotData::loadFromStream(ReadStream *stream) {
// 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();
diff --git a/engines/lure/res_struct.h b/engines/lure/res_struct.h
index 3efb361407..a2d8296b46 100644
--- a/engines/lure/res_struct.h
+++ b/engines/lure/res_struct.h
@@ -385,6 +385,8 @@ enum CharacterMode {CHARMODE_NONE, CHARMODE_HESITATE, CHARMODE_IDLE, CHARMODE_PA
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 @@ public:
// Runtime fields
uint16 actionCtr;
BlockedState blockedState;
- bool coveredFlag;
+ VariantBool coveredFlag;
uint16 talkMessageId;
uint16 talkDestCharacterId;
uint16 talkCountdown;
@@ -696,7 +698,7 @@ enum FieldName {
BOTTLE_FILLED = 18,
TALK_INDEX = 19,
SACK_CUT = 20,
- ROOM_EXIT_ANIMATION = 82
+ ROOM_EXIT_ANIMATION = 76
};
enum GameFlags {