aboutsummaryrefslogtreecommitdiff
path: root/engines/lure
diff options
context:
space:
mode:
authorPaul Gilbert2007-11-12 09:53:10 +0000
committerPaul Gilbert2007-11-12 09:53:10 +0000
commit705cf3cc87e6a6ef30a686d5aa65fad1510da61d (patch)
tree950d8a73cc58d962bef836dfd84bd155c585a0e6 /engines/lure
parent6ccbfcf611e98e688ceae6947f9c4c06ca6336c9 (diff)
downloadscummvm-rg350-705cf3cc87e6a6ef30a686d5aa65fad1510da61d.tar.gz
scummvm-rg350-705cf3cc87e6a6ef30a686d5aa65fad1510da61d.tar.bz2
scummvm-rg350-705cf3cc87e6a6ef30a686d5aa65fad1510da61d.zip
Adjustments to the talk state machine so information dialogs (if any) correctly occur at the end of a conversation (such as giving the bar to Ewan)
svn-id: r29481
Diffstat (limited to 'engines/lure')
-rw-r--r--engines/lure/hotspots.cpp9
1 files changed, 8 insertions, 1 deletions
diff --git a/engines/lure/hotspots.cpp b/engines/lure/hotspots.cpp
index 8f86edbab4..fd2344772e 100644
--- a/engines/lure/hotspots.cpp
+++ b/engines/lure/hotspots.cpp
@@ -3333,6 +3333,12 @@ void HotspotTickHandlers::talkAnimHandler(Hotspot &h) {
case TALK_RESPOND:
// Handle initial response to show the question in a talk dialog if needed
+ if (h.resource()->talkCountdown != 0) {
+ // Current talk dialog already pending needs to finish
+ h.handleTalkDialog();
+ return;
+ }
+
// Get the original question for display
selectedLine = res.getTalkSelection();
entry = talkSelections[selectedLine-1];
@@ -3400,10 +3406,11 @@ void HotspotTickHandlers::talkAnimHandler(Hotspot &h) {
case TALK_RESPONSE_WAIT:
// Wait until the character's response has finished being displayed
charHotspot = res.getActiveHotspot(talkDestCharacter);
+ assert(charHotspot);
debugC(ERROR_DETAILED, kLureDebugAnimations, "Player talk dialog countdown %d",
(charHotspot) ? charHotspot->resource()->talkCountdown : 0);
- if (res.getTalkingCharacter() != 0)
+ if ((charHotspot->resource()->talkCountdown > 0) || (res.getTalkingCharacter() != 0))
return;
result = _talkResponse->postSequenceId;