(y-hotspot 1)
(images "shared/largetux-grab-right-0.png"))
+ (sprite (name "largetux-star")
+ (x-hotspot 8)
+ (y-hotspot 8)
+ (images "shared/largetux-star-0.png"
+ "shared/largetux-star-1.png"
+ "shared/largetux-star-2.png"
+ ))
+
+ (sprite (name "smalltux-star")
+ (x-hotspot 5)
+ (y-hotspot 15)
+ (images "shared/smalltux-star-0.png"
+ "shared/smalltux-star-1.png"
+ "shared/smalltux-star-2.png"
+ ))
+
)
;; EOF ;;
Sprite* smalltux_grab_left;
Sprite* smalltux_grab_right;
+Sprite* smalltux_star;
+Sprite* largetux_star;
+
Sprite* largetux_kick_left;
Sprite* largetux_kick_right;
Sprite* largetux_grab_left;
Surface* skidfiretux_left;
Surface* cape_right[2];
Surface* cape_left[2];
-Surface* bigcape_right[2];
-Surface* bigcape_left[2];
PlayerKeymap keymap;
{
if (size == SMALL)
{
- if (invincible_timer.started())
- {
- if (dir == RIGHT)
- cape_right[global_frame_counter % 2]->draw(base.x- scroll_x, base.y);
- else
- cape_left[global_frame_counter % 2]->draw(base.x- scroll_x, base.y);
- }
-
if (!skidding_timer.started())
{
if (physic.get_velocity_y() != 0)
else
smalltux_grab_left->draw(base.x - scroll_x, base.y);
}
+
+ if (invincible_timer.started())
+ smalltux_star->draw(base.x - scroll_x, base.y);
}
else // Large Tux
{
- if (invincible_timer.started())
- {
- float capex = base.x + (base.width - bigcape_right[0]->w) / 2;
- capex -= scroll_x;
- float capey = base.y + (base.height - bigcape_right[0]->h) / 2;
-
- /* Draw cape (just not in ducked mode since that looks silly): */
- if (dir == RIGHT)
- bigcape_right[global_frame_counter % 2]->draw(capex, capey);
- else
- bigcape_left[global_frame_counter % 2]->draw(capex, capey);
- }
-
if (!got_coffee)
{
if (!duck)
else
largetux_grab_left->draw(base.x - scroll_x, base.y);
}
+
+ if (invincible_timer.started())
+ largetux_star->draw(base.x - scroll_x, base.y);
}
}
}
extern Sprite* smalltux_kick_right;
extern Sprite* smalltux_grab_left;
extern Sprite* smalltux_grab_right;
+extern Sprite* smalltux_star;
+extern Sprite* largetux_star;
extern Sprite* largetux_kick_left;
extern Sprite* largetux_kick_right;
sprite_manager = new SpriteManager(datadir + "/supertux.strf");
/* Tuxes: */
+ smalltux_star = sprite_manager->load("smalltux-star");
+ largetux_star = sprite_manager->load("largetux-star");
+
smalltux_kick_left = sprite_manager->load("smalltux-kick-left");
smalltux_kick_right = sprite_manager->load("smalltux-kick-right");
smalltux_grab_left = sprite_manager->load("smalltux-grab-left");
bigtux_left_jump = sprite_manager->load("largetux-jump-left");
bigtux_right_jump = sprite_manager->load("largetux-jump-right");
- bigcape_right[0] = new Surface(datadir + "/images/shared/bigcape-right-0.png",
- USE_ALPHA);
-
- bigcape_right[1] = new Surface(datadir + "/images/shared/bigcape-right-1.png",
- USE_ALPHA);
-
- bigcape_left[0] = new Surface(datadir + "/images/shared/bigcape-left-0.png",
- USE_ALPHA);
-
- bigcape_left[1] = new Surface(datadir + "/images/shared/bigcape-left-1.png",
- USE_ALPHA);
-
bigfiretux_right[0] = new Surface(datadir + "/images/shared/bigfiretux-right-0.png",
USE_ALPHA);
bigfiretux_left_jump = new Surface(datadir + "/images/shared/bigfiretux-left-jump.png", USE_ALPHA);
- bigcape_right[0] = new Surface(datadir + "/images/shared/bigcape-right-0.png",
- USE_ALPHA);
-
- bigcape_right[1] = new Surface(datadir + "/images/shared/bigcape-right-1.png",
- USE_ALPHA);
-
- bigcape_left[0] = new Surface(datadir + "/images/shared/bigcape-left-0.png",
- USE_ALPHA);
-
- bigcape_left[1] = new Surface(datadir + "/images/shared/bigcape-left-1.png",
- USE_ALPHA);
-
-
ducktux_left = sprite_manager->load("largetux-duck-left");
ducktux_right = sprite_manager->load("largetux-duck-right");
{
delete cape_right[i];
delete cape_left[i];
- delete bigcape_right[i];
- delete bigcape_left[i];
}
delete ducktux_left;