aboutsummaryrefslogtreecommitdiff
path: root/engines/lure/hotspots.cpp
diff options
context:
space:
mode:
authorPaul Gilbert2007-10-25 10:37:23 +0000
committerPaul Gilbert2007-10-25 10:37:23 +0000
commitc0f285693c72a4e1fbfb75720ee5ff76e4db15a1 (patch)
tree8a7d8d41218f5af24349aa7b1f9fee84d200e677 /engines/lure/hotspots.cpp
parentc9d06136bc8ca7d6f80f0db49cf3743de7b7a422 (diff)
downloadscummvm-rg350-c0f285693c72a4e1fbfb75720ee5ff76e4db15a1.tar.gz
scummvm-rg350-c0f285693c72a4e1fbfb75720ee5ff76e4db15a1.tar.bz2
scummvm-rg350-c0f285693c72a4e1fbfb75720ee5ff76e4db15a1.zip
Added saving of NPC direction, and bugfix for closing talk dialogs
svn-id: r29256
Diffstat (limited to 'engines/lure/hotspots.cpp')
-rw-r--r--engines/lure/hotspots.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/engines/lure/hotspots.cpp b/engines/lure/hotspots.cpp
index f32de092c8..3a1ae5e9e2 100644
--- a/engines/lure/hotspots.cpp
+++ b/engines/lure/hotspots.cpp
@@ -863,7 +863,7 @@ void Hotspot::handleTalkDialog() {
debugC(ERROR_DETAILED, kLureDebugAnimations, "Talk dialog close");
room.setTalkDialog(0, 0, 0, 0);
- if (_data->talkDestCharacterId != 0) {
+ if ((_data->talkDestCharacterId != 0) && (_data->talkDestCharacterId != NOONE_ID)) {
HotspotData *destChar = res.getHotspot(_data->talkDestCharacterId);
destChar->talkerId = 0;
}
@@ -2155,6 +2155,7 @@ void Hotspot::saveToStream(Common::WriteStream *stream) {
stream->writeUint16LE(_hotspotScriptOffset);
stream->writeUint16LE(_tickCtr);
stream->writeByte(_colourOffset);
+ stream->writeByte((byte)_direction);
stream->writeUint16LE(_animId);
stream->writeUint16LE(_frameNumber);
@@ -2195,6 +2196,7 @@ void Hotspot::loadFromStream(Common::ReadStream *stream) {
_hotspotScriptOffset = stream->readUint16LE();
_tickCtr = stream->readUint16LE();
_colourOffset = stream->readByte();
+ _direction = (Direction)stream->readByte();
setAnimation(stream->readUint16LE());
setFrameNumber(stream->readUint16LE());