From: Holger Schemel Date: Wed, 14 Dec 2022 10:43:55 +0000 (+0100) Subject: fixed several problems when displaying info sub-screens from main menu X-Git-Tag: 4.3.4.0~20 X-Git-Url: https://git.artsoft.org/?a=commitdiff_plain;h=de580a24cb58b43281f0b2af3d4d6079d78fcb5d;p=rocksndiamonds.git fixed several problems when displaying info sub-screens from main menu --- diff --git a/src/screens.c b/src/screens.c index 05b5fb67..021dfcdc 100644 --- a/src/screens.c +++ b/src/screens.c @@ -3865,6 +3865,8 @@ static void DrawInfoScreen(void) void DrawInfoScreen_FromMainMenu(int nr) { + int fade_mask = REDRAW_FIELD; + if (nr < INFO_MODE_MAIN || nr >= MAX_INFO_MODES) return; @@ -3875,8 +3877,26 @@ void DrawInfoScreen_FromMainMenu(int nr) info_mode = nr; info_screens_from_main = TRUE; + if (redraw_mask & REDRAW_ALL) + fade_mask = REDRAW_ALL; + + if (CheckFadeAll()) + fade_mask = REDRAW_ALL; + + UnmapAllGadgets(); + FadeMenuSoundsAndMusic(); + FadeSetEnterScreen(); + FadeOut(fade_mask); + + FadeSkipNextFadeOut(); + + // needed if different viewport properties defined for info screen + ChangeViewportPropertiesIfNeeded(); + + SetMainBackgroundImage(IMG_BACKGROUND_INFO); + DrawInfoScreen(); }