From c2d53f1e3b49b258708ad84213c69d4a594d05f3 Mon Sep 17 00:00:00 2001 From: Christoph Sommer Date: Fri, 7 Apr 2006 11:51:14 +0000 Subject: [PATCH] Restored old growup code SVN-Revision: 3259 --- src/object/player.cpp | 28 ++++++---------------------- 1 file changed, 6 insertions(+), 22 deletions(-) diff --git a/src/object/player.cpp b/src/object/player.cpp index e2df3682d..7e540c8f7 100644 --- a/src/object/player.cpp +++ b/src/object/player.cpp @@ -660,28 +660,12 @@ Player::draw(DrawingContext& context) if(dying) { smalltux_gameover->draw(context, get_pos(), layer); } else if(growing_timer.get_timeleft() > 0) { - if(!is_big()) - { - if (dir == RIGHT) - context.draw_surface(growingtux_right[GROWING_FRAMES-1 - - int((growing_timer.get_timegone() * - GROWING_FRAMES) / GROWING_TIME)], get_pos(), layer); - else - context.draw_surface(growingtux_left[GROWING_FRAMES-1 - - int((growing_timer.get_timegone() * - GROWING_FRAMES) / GROWING_TIME)], get_pos(), layer); - } - else - { - if (dir == RIGHT) - context.draw_surface(growingtux_right[ - int((growing_timer.get_timegone() * - GROWING_FRAMES) / GROWING_TIME)], get_pos(), layer); - else - context.draw_surface(growingtux_left[ - int((growing_timer.get_timegone() * - GROWING_FRAMES) / GROWING_TIME)], - get_pos(), layer); + if (dir == RIGHT) { + context.draw_surface(growingtux_right[int((growing_timer.get_timegone() * + GROWING_FRAMES) / GROWING_TIME)], get_pos() - Vector(0, 32), layer); + } else { + context.draw_surface(growingtux_left[int((growing_timer.get_timegone() * + GROWING_FRAMES) / GROWING_TIME)], get_pos() - Vector(0, 32), layer); } } else if (safe_timer.started() && size_t(game_time*40)%2) -- 2.11.0