1 | From 6ce35697d7c94ed36615de718f434d358bd7941e Mon Sep 17 00:00:00 2001
|
---|
2 | From: Alyssa Milburn <fuzzie@fuzzie.org>
|
---|
3 | Date: Mon, 24 May 2010 16:47:24 +0200
|
---|
4 | Subject: [PATCH 4/5] always execute next dialog state immediately if previous string was null
|
---|
5 |
|
---|
6 | ---
|
---|
7 | engines/parallaction/dialogue.cpp | 10 ++++++++++
|
---|
8 | 1 files changed, 10 insertions(+), 0 deletions(-)
|
---|
9 |
|
---|
10 | diff --git a/engines/parallaction/dialogue.cpp b/engines/parallaction/dialogue.cpp
|
---|
11 | index df4f040..858be87 100644
|
---|
12 | --- a/engines/parallaction/dialogue.cpp
|
---|
13 | +++ b/engines/parallaction/dialogue.cpp
|
---|
14 | @@ -135,6 +135,10 @@ void DialogueManager::start() {
|
---|
15 | assert(_dialogue);
|
---|
16 | _q = _dialogue->_questions[0];
|
---|
17 | _state = displayQuestion() ? RUN_QUESTION : NEXT_ANSWER;
|
---|
18 | + if (_state == NEXT_ANSWER) {
|
---|
19 | + // was "null", continue onward immediately
|
---|
20 | + nextAnswer();
|
---|
21 | + }
|
---|
22 | }
|
---|
23 |
|
---|
24 |
|
---|
25 | @@ -256,6 +260,8 @@ void DialogueManager::nextAnswer() {
|
---|
26 | if (_numVisAnswers) {
|
---|
27 | _answerId = _visAnswers[0]._index;
|
---|
28 | _state = NEXT_QUESTION;
|
---|
29 | + // was "null", continue onward immediately
|
---|
30 | + nextQuestion();
|
---|
31 | } else {
|
---|
32 | _state = DIALOGUE_OVER;
|
---|
33 | }
|
---|
34 | @@ -284,6 +290,10 @@ void DialogueManager::nextQuestion() {
|
---|
35 | _state = DIALOGUE_OVER;
|
---|
36 | } else {
|
---|
37 | _state = displayQuestion() ? RUN_QUESTION : NEXT_ANSWER;
|
---|
38 | + if (_state == NEXT_ANSWER) {
|
---|
39 | + // was "null", continue onward immediately
|
---|
40 | + nextAnswer();
|
---|
41 | + }
|
---|
42 | }
|
---|
43 | }
|
---|
44 |
|
---|
45 | --
|
---|
46 | 1.6.3.3
|
---|
47 |
|
---|