From 8b77194545721f4b8e3f80b59da8423ab2d90dae Mon Sep 17 00:00:00 2001 From: Holger Schemel Date: Fri, 31 May 2019 16:10:24 +0200 Subject: [PATCH] fixed handling global animation click events (again) Before, only global animations exactly defined for the current game mode were correctly handled. (Example: ".MAIN") Now, also global animations defined for several game modes are correctly handled. (Example: ".MENU") --- src/anim.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/anim.c b/src/anim.c index 1e155f9e..14dccc69 100644 --- a/src/anim.c +++ b/src/anim.c @@ -1764,6 +1764,7 @@ static boolean InitGlobalAnim_Clicked(int mx, int my, int clicked_event) boolean any_part_clicked = FALSE; boolean any_event_action = FALSE; int mode_nr; + int i; // check game modes in reverse draw order (to stop when clicked) for (mode_nr = NUM_GAME_MODES - 1; mode_nr >= 0; mode_nr--) @@ -1863,7 +1864,8 @@ static boolean InitGlobalAnim_Clicked(int mx, int my, int clicked_event) { handle_click = TRUE; - HandleGlobalAnim(ANIM_CONTINUE, game_status); + for (i = 0; i < NUM_GAME_MODES; i++) + HandleGlobalAnim(ANIM_CONTINUE, i); handle_click = FALSE; -- 2.34.1