X-Git-Url: https://git.artsoft.org/?a=blobdiff_plain;f=src%2Flibgame%2Fsdl.c;h=d271951eb5dc84cdab120c47ce9d30510012f7c9;hb=0da04ce4eb698f9177d0ab32022e30e967fa5e6d;hp=04cfc0e739fbafa9ca8df4b92d94609e601ec28c;hpb=e227a361d63ac92e9ed1ceb276f739fa3edc45be;p=rocksndiamonds.git diff --git a/src/libgame/sdl.c b/src/libgame/sdl.c index 04cfc0e7..d271951e 100644 --- a/src/libgame/sdl.c +++ b/src/libgame/sdl.c @@ -1033,6 +1033,17 @@ void SDLFadeRectangle(int x, int y, int width, int height, time_current = SDL_GetTicks(); + if (fade_delay <= 0) + { + // immediately draw final target frame without delay + fade_mode &= (FADE_MODE_FADE | FADE_MODE_TRANSFORM); + fade_delay = 1; + time_current -= 1; + + // when fading without delay, also skip post delay + post_delay = 0; + } + if (fade_mode == FADE_MODE_MELT) { boolean done = FALSE;