From 62ea7be0cfa462b5aab6a1c63fce67e4499c62a6 Mon Sep 17 00:00:00 2001 From: Vladimir Menshakov Date: Tue, 15 Sep 2009 20:58:30 +0000 Subject: fixed animation pausing/restarting when only one of animations present svn-id: r44111 --- engines/teenagent/dialog.cpp | 13 +++++++------ 1 file changed, 7 insertions(+), 6 deletions(-) (limited to 'engines/teenagent/dialog.cpp') diff --git a/engines/teenagent/dialog.cpp b/engines/teenagent/dialog.cpp index 2b5efd7092..a968d0e298 100644 --- a/engines/teenagent/dialog.cpp +++ b/engines/teenagent/dialog.cpp @@ -66,27 +66,28 @@ void Dialog::show(Scene *scene, uint16 addr, uint16 animation1, uint16 animation case 2: //debug(0, "displaymessage\n"); - if (color == color2 && animation2 != 0) { + if (color == color2) { + //pause animation in other slot - { + if (animation1 != 0) { SceneEvent e(SceneEvent::kPauseAnimation); e.lan = 0x80 | slot1; scene->push(e); } - { + if (animation2 != 0) { SceneEvent e(SceneEvent::kPlayAnimation); e.animation = animation2; e.lan = 0x80 | slot2; scene->push(e); } - } else if (color == color1 && animation1 != 0) { + } else if (color == color1) { //pause animation in other slot - { + if (animation2 != 0) { SceneEvent e(SceneEvent::kPauseAnimation); e.lan = 0x80 | slot2; scene->push(e); } - { + if (animation1 != 0) { SceneEvent e(SceneEvent::kPlayAnimation); e.animation = animation1; e.lan = 0x80 | slot1; -- cgit v1.2.3