#define TILES_FOR_BUTTJUMP 3
// animation times (in ms):
#define SHOOTING_TIME 320
+#define STOMP_TIME 250
// others stuff:
#define AUTOSCROLL_DEAD_INTERVAL 300
// Do butt jump
if (butt_jump && on_ground() && size == BIG)
{
+ stomp_timer.start(STOMP_TIME);
butt_jump = false;
// Break bricks beneath Tux
else
sprite->grab_left->draw(context, pos, LAYER_OBJECTS + 1);
}
+
+ // Draw stomp clouds when doing a butt jump
+ if (stomp_timer.check())
+ if (duck)
+ sprite->stomp->draw(context, Vector(base.x - 32, base.y), LAYER_OBJECTS + 1);
+ else
+ sprite->stomp->draw(context, Vector(base.x - 32, base.y + 32), LAYER_OBJECTS + 1);
// Draw blinking star overlay
if (invincible_timer.started() &&
smalltux.skid_right = sprite_manager->load("smalltux-skid-right");
smalltux.grab_left = sprite_manager->load("smalltux-grab-left");
smalltux.grab_right = sprite_manager->load("smalltux-grab-right");
+ smalltux.stomp = sprite_manager->load("stomp");
largetux.stand_left = sprite_manager->load("largetux-stand-left");
largetux.stand_right = sprite_manager->load("largetux-stand-right");
largetux.grab_right = sprite_manager->load("largetux-grab-right");
largetux.duck_left = sprite_manager->load("largetux-duck-left");
largetux.duck_right = sprite_manager->load("largetux-duck-right");
+ largetux.stomp = sprite_manager->load("stomp");
firetux.stand_left = sprite_manager->load("firetux-stand-left");
firetux.stand_right = sprite_manager->load("firetux-stand-right");
firetux.grab_right = sprite_manager->load("firetux-grab-right");
firetux.duck_left = sprite_manager->load("firetux-duck-left");
firetux.duck_right = sprite_manager->load("firetux-duck-right");
+ firetux.stomp = sprite_manager->load("stomp");
icetux.stand_left = sprite_manager->load("icetux-stand-left");
icetux.stand_right = sprite_manager->load("icetux-stand-right");
icetux.grab_right = sprite_manager->load("icetux-grab-right");
icetux.duck_left = sprite_manager->load("icetux-duck-left");
icetux.duck_right = sprite_manager->load("icetux-duck-right");
+ icetux.stomp = sprite_manager->load("stomp");
/* Water: */