From: Ricardo Cruz Date: Fri, 28 May 2004 18:32:58 +0000 (+0000) Subject: Fixed the fade func problem. Just a simple mistake. X-Git-Url: https://git.verplant.org/?a=commitdiff_plain;h=66ebf6a6d8d237b98ee6521b73a18e6357585f26;p=supertux.git Fixed the fade func problem. Just a simple mistake. Also applied fade when choosing a slot. SVN-Revision: 1350 --- diff --git a/src/intro.cpp b/src/intro.cpp index c6e6002d2..991c77f7f 100644 --- a/src/intro.cpp +++ b/src/intro.cpp @@ -35,7 +35,6 @@ void draw_intro() { -shrink_fade(Point((screen->w/2),(screen->h/2)), 2000); display_text_file("intro.txt", "/images/background/arctis.jpg", SCROLL_SPEED_MESSAGE); } diff --git a/src/screen.cpp b/src/screen.cpp index 61d51fcf4..8dfe18b70 100644 --- a/src/screen.cpp +++ b/src/screen.cpp @@ -150,8 +150,8 @@ float down_inc = ((float)screen->h - point.y) / ((float)fade_time / LOOP_DELAY) float left_cor = 0, right_cor = 0, up_cor = 0, down_cor = 0; -while(left_cor < screen->w - point.x && right_cor < screen->w - point.x && - up_cor < screen->h - point.y && down_cor < screen->h - point.y) +while(left_cor < point.x && right_cor < screen->w - point.x && + up_cor < point.y && down_cor < screen->h - point.y) { left_cor += left_inc; right_cor += right_inc; diff --git a/src/setup.cpp b/src/setup.cpp index b431d438e..82c34c995 100644 --- a/src/setup.cpp +++ b/src/setup.cpp @@ -505,6 +505,7 @@ bool process_load_game_menu() draw_intro(); } + shrink_fade(Point((screen->w/2),(screen->h/2)), 2000); fadeout(); WorldMapNS::WorldMap worldmap; diff --git a/src/worldmap.cpp b/src/worldmap.cpp index 0de8a82e9..1132edd23 100644 --- a/src/worldmap.cpp +++ b/src/worldmap.cpp @@ -642,7 +642,7 @@ WorldMap::update(float delta) std::cout << "Enter the current level: " << level->name << std::endl; // do a shriking fade to the level - shrink_fade(Point((level->x*32 + 16 + offset.x),(level->y*32 + 16 + offset.y)), 3000); + shrink_fade(Point((level->x*32 + 16 + offset.x),(level->y*32 + 16 + offset.y)), 2000); GameSession session(datadir + "/levels/" + level->name, 1, ST_GL_LOAD_LEVEL_FILE);