aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--engines/parallaction/dialogue.cpp5
1 files changed, 2 insertions, 3 deletions
diff --git a/engines/parallaction/dialogue.cpp b/engines/parallaction/dialogue.cpp
index 4dbedc8dbe..ee92eee439 100644
--- a/engines/parallaction/dialogue.cpp
+++ b/engines/parallaction/dialogue.cpp
@@ -253,15 +253,14 @@ int16 DialogueManager::selectAnswerN() {
_selection = _balloonMan->hitTestDialogueBalloon(_mousePos.x, _mousePos.y);
- VisibleAnswer *oldAnswer = (_oldSelection == NO_ANSWER_SELECTED) ? NULL : &_visAnswers[_oldSelection];
- VisibleAnswer *answer = &_visAnswers[_selection];
-
if (_selection != _oldSelection) {
if (_oldSelection != NO_ANSWER_SELECTED) {
+ VisibleAnswer *oldAnswer = &_visAnswers[_oldSelection];
_balloonMan->setBalloonText(oldAnswer->_balloon, oldAnswer->_a->_text, BalloonManager::kUnselectedColor);
}
if (_selection != NO_ANSWER_SELECTED) {
+ VisibleAnswer *answer = &_visAnswers[_selection];
_balloonMan->setBalloonText(answer->_balloon, answer->_a->_text, BalloonManager::kSelectedColor);
_gfx->setItemFrame(_faceId, answer->_a->speakerMood());
}