- small_tux = sprite_manager->load("small-tux");
- big_tux = sprite_manager->load("big-tux");
- ice_tux = sprite_manager->load("ice-tux");
- fire_tux = sprite_manager->load("fire-tux");
-
- tux_arm = sprite_manager->load("tux-arm");
-
- /* Water: */
- img_water = new Surface(datadir + "/images/shared/water.png", false);
-
- img_waves[0] = new Surface(datadir + "/images/shared/waves-0.png",
- true);
-
- img_waves[1] = new Surface(datadir + "/images/shared/waves-1.png",
- true);
-
-
- img_waves[2] = new Surface(datadir + "/images/shared/waves-2.png",
- true);
-
-
- /* Pole: */
-
- img_pole = new Surface(datadir + "/images/shared/pole.png", true);
- img_poletop = new Surface(datadir + "/images/shared/poletop.png",
- true);
-
-
- /* Flag: */
-
- img_flag[0] = new Surface(datadir + "/images/shared/flag-0.png",
- true);
- img_flag[1] = new Surface(datadir + "/images/shared/flag-1.png",
- true);
-
-
- /* Cloud: */
-
- img_cloud[0][0] = new Surface(datadir + "/images/shared/cloud-00.png",
- true);
-
- img_cloud[0][1] = new Surface(datadir + "/images/shared/cloud-01.png",
- true);
-
- img_cloud[0][2] = new Surface(datadir + "/images/shared/cloud-02.png",
- true);
-
- img_cloud[0][3] = new Surface(datadir + "/images/shared/cloud-03.png",
- true);
-
-
- img_cloud[1][0] = new Surface(datadir + "/images/shared/cloud-10.png",
- true);
-
- img_cloud[1][1] = new Surface(datadir + "/images/shared/cloud-11.png",
- true);
-
- img_cloud[1][2] = new Surface(datadir + "/images/shared/cloud-12.png",
- true);
-
- img_cloud[1][3] = new Surface(datadir + "/images/shared/cloud-13.png",
- true);
-
-
- /* Bad guys: */
- load_badguy_gfx();
-
- /* Upgrades: */
- load_special_gfx();
-
- /* Objects */
- load_object_gfx();
-
- // load the door object graphics:
- door = sprite_manager->load("door");
- for (int i = 0; i < DOOR_OPENING_FRAMES; i++)
- {
- sprintf(img_name, "%s/images/shared/door-%i.png", datadir.c_str(), i+1);
- door_opening[i] = new Surface(img_name, true);
- }
-
- /* Distros: */
- img_distro[0] = new Surface(datadir + "/images/tilesets/coin1.png",
- true);
-
- img_distro[1] = new Surface(datadir + "/images/tilesets/coin2.png",
- true);
-
- img_distro[2] = new Surface(datadir + "/images/tilesets/coin3.png",
- true);
-
- img_distro[3] = new Surface(datadir + "/images/tilesets/coin2.png",
- true);
-
-
- /* Tux life: */
-
- tux_life = new Surface(datadir + "/images/shared/tux-life.png",
- true);
-
- /* Sound effects: */
-
- /* if (use_sound) // this will introduce SERIOUS bugs here ! because "load_sound"
- // initialize sounds[i] with the correct pointer's value:
- // NULL or something else. And it will be dangerous to
- // play with not-initialized pointers.
- // This is also true with if (use_music)
- Send a mail to me: neoneurone@users.sf.net, if you have another opinion. :)
- */
- for (i = 0; i < NUM_SOUNDS; i++)
- SoundManager::get
- ()->add_sound(SoundManager::get
- ()->load_sound(datadir + soundfilenames[i]),i);
-
- /* Herring song */
- herring_song = SoundManager::get
- ()->load_music(datadir + "/music/SALCON.MOD");
- level_end_song = SoundManager::get
- ()->load_music(datadir + "/music/leveldone.mod");
+ small_tux = new TuxBodyParts();
+ small_tux->head = 0;
+ small_tux->body = sprite_manager->create("images/creatures/tux_small/small-tux-body.sprite");
+ small_tux->arms = sprite_manager->create("images/creatures/tux_small/small-tux-arms.sprite");
+ small_tux->feet = 0;
+
+ big_tux = new TuxBodyParts();
+ big_tux->head = sprite_manager->create("images/creatures/tux_big/big-tux-head.sprite");
+ big_tux->body = sprite_manager->create("images/creatures/tux_big/big-tux-body.sprite");
+ big_tux->arms = sprite_manager->create("images/creatures/tux_big/big-tux-arms.sprite");
+ big_tux->feet = sprite_manager->create("images/creatures/tux_big/big-tux-feet.sprite");
+
+ fire_tux = new TuxBodyParts();
+ fire_tux->head = sprite_manager->create("images/creatures/tux_big/big-fire-tux-head.sprite");
+ fire_tux->body = sprite_manager->create("images/creatures/tux_big/big-tux-body.sprite");
+ fire_tux->arms = sprite_manager->create("images/creatures/tux_big/big-tux-arms.sprite");
+ fire_tux->feet = sprite_manager->create("images/creatures/tux_big/big-tux-feet.sprite");
+
+ ice_tux = new TuxBodyParts();
+ ice_tux->head = sprite_manager->create("images/creatures/tux_big/big-tux-head.sprite");
+ ice_tux->body = sprite_manager->create("images/creatures/tux_big/big-tux-body.sprite");
+ ice_tux->arms = sprite_manager->create("images/creatures/tux_big/big-tux-arms.sprite");
+ ice_tux->feet = sprite_manager->create("images/creatures/tux_big/big-tux-feet.sprite");
+
+ player_status = new PlayerStatus();