Finish out stone form with some quick-and-dirty graphics
authorLMH <lmh.0013@gmail.com>
Wed, 17 Dec 2014 01:11:04 +0000 (15:11 -1000)
committerLMH <lmh.0013@gmail.com>
Wed, 17 Dec 2014 01:20:32 +0000 (15:20 -1000)
13 files changed:
data/images/creatures/tux/earth/backflip.png [new file with mode: 0644]
data/images/creatures/tux/earth/buttjump.png [new file with mode: 0644]
data/images/creatures/tux/earth/duck.png [new file with mode: 0644]
data/images/creatures/tux/earth/hardhat/duck.png [new file with mode: 0644]
data/images/creatures/tux/earth/head.png [new file with mode: 0644]
data/images/creatures/tux/earth/jump.png [new file with mode: 0644]
data/images/creatures/tux/earth/kick.png [new file with mode: 0644]
data/images/creatures/tux/earth/ladder.png [new file with mode: 0755]
data/images/creatures/tux/earth/skid.png [new file with mode: 0644]
data/images/creatures/tux/earth/walk.png [new file with mode: 0644]
data/images/creatures/tux/powerups.sprite
data/images/creatures/tux/tux.sprite
src/object/player.cpp

diff --git a/data/images/creatures/tux/earth/backflip.png b/data/images/creatures/tux/earth/backflip.png
new file mode 100644 (file)
index 0000000..95e332d
Binary files /dev/null and b/data/images/creatures/tux/earth/backflip.png differ
diff --git a/data/images/creatures/tux/earth/buttjump.png b/data/images/creatures/tux/earth/buttjump.png
new file mode 100644 (file)
index 0000000..4375185
Binary files /dev/null and b/data/images/creatures/tux/earth/buttjump.png differ
diff --git a/data/images/creatures/tux/earth/duck.png b/data/images/creatures/tux/earth/duck.png
new file mode 100644 (file)
index 0000000..c7ceff8
Binary files /dev/null and b/data/images/creatures/tux/earth/duck.png differ
diff --git a/data/images/creatures/tux/earth/hardhat/duck.png b/data/images/creatures/tux/earth/hardhat/duck.png
new file mode 100644 (file)
index 0000000..b43f898
Binary files /dev/null and b/data/images/creatures/tux/earth/hardhat/duck.png differ
diff --git a/data/images/creatures/tux/earth/head.png b/data/images/creatures/tux/earth/head.png
new file mode 100644 (file)
index 0000000..10a819b
Binary files /dev/null and b/data/images/creatures/tux/earth/head.png differ
diff --git a/data/images/creatures/tux/earth/jump.png b/data/images/creatures/tux/earth/jump.png
new file mode 100644 (file)
index 0000000..4336ddc
Binary files /dev/null and b/data/images/creatures/tux/earth/jump.png differ
diff --git a/data/images/creatures/tux/earth/kick.png b/data/images/creatures/tux/earth/kick.png
new file mode 100644 (file)
index 0000000..670c60e
Binary files /dev/null and b/data/images/creatures/tux/earth/kick.png differ
diff --git a/data/images/creatures/tux/earth/ladder.png b/data/images/creatures/tux/earth/ladder.png
new file mode 100755 (executable)
index 0000000..2bd09c6
Binary files /dev/null and b/data/images/creatures/tux/earth/ladder.png differ
diff --git a/data/images/creatures/tux/earth/skid.png b/data/images/creatures/tux/earth/skid.png
new file mode 100644 (file)
index 0000000..0b02506
Binary files /dev/null and b/data/images/creatures/tux/earth/skid.png differ
diff --git a/data/images/creatures/tux/earth/walk.png b/data/images/creatures/tux/earth/walk.png
new file mode 100644 (file)
index 0000000..c56dfd7
Binary files /dev/null and b/data/images/creatures/tux/earth/walk.png differ
index b510712..3d01fd5 100644 (file)
 
        (action
          (name "earth-duck-right")
-         (hitbox 16 14 32 64)
-         (images "earth/hardhat/stand.png"))
+         (hitbox 16 45 32 32)
+         (images "earth/hardhat/duck.png"))
 
        (action
          (name "earth-duck-left")
-         (hitbox 16 14 32 64)
+         (hitbox 16 45 32 32)
          (mirror-action "earth-duck-right"))
 
        (action
index 3360664..e231e5e 100644 (file)
          (name "earth-walk-right-stone")
          (fps 15.0)
          (hitbox 16 14 32 64)
-         (images "earth/stand.png"))
+         (images "earth/walk.png"))
 
        (action
          (name "earth-walk-left-stone")
          (name "earth-jump-right-stone")
          (fps 15.0)
          (hitbox 16 14 32 64)
-         (images "earth/stand.png"))
+         (images "earth/jump.png"))
 
        (action
          (name "earth-jump-left-stone")
        (action
          (name "earth-skid-right-stone")
          (hitbox 16 14 32 64)
-         (images "earth/stand.png"))
+         (images "earth/skid.png"))
 
        (action
          (name "earth-skid-left-stone")
        (action
          (name "earth-kick-right-stone")
          (hitbox 16 14 32 64)
-         (images "earth/stand.png"))
+         (images "earth/kick.png"))
 
        (action
          (name "earth-kick-left-stone")
          (name "earth-idle-right-stone")
          (fps 5.0)
          (hitbox 16 14 32 64)
-         (images "earth/stand.png"))
+         (images "earth/head.png"))
 
        (action
          (name "earth-idle-left-stone")
        (action
          (name "earth-climbing-right-stone")
          (hitbox 16 14 32 64)
-         (images "earth/stand.png"))
+         (images "earth/ladder.png"))
 
        (action
          (name "earth-climbing-left-stone")
        (action
          (name "earth-duck-right-stone")
          (hitbox 16 45 32 32)
-         (images "earth/stand.png"))
+         (images "earth/duck.png"))
 
        (action
          (name "earth-duck-left-stone")
        (action
          (name "earth-backflip-right-stone")
          (hitbox 16 37 32 32)
-         (images "earth/stand.png"))
+         (images "earth/backflip.png"))
 
        (action
          (name "earth-backflip-left-stone")
        (action
          (name "earth-buttjump-right-stone")
          (hitbox 16 14 32 64)
-         (images "earth/stand.png"))
+         (images "earth/buttjump.png"))
 
        (action
          (name "earth-buttjump-left-stone")
index fafe2fc..a891b80 100644 (file)
@@ -416,9 +416,11 @@ Player::update(float elapsed_time)
     if (backflipping && (backflip_timer.get_timegone() > 0.15f)) {
       backflipping = false;
       backflip_direction = 0;
-      sprite->set_angle(0.0f);
-      powersprite->set_angle(0.0f);
-      lightsprite->set_angle(0.0f);
+      if (!stone) {
+        sprite->set_angle(0.0f);
+        powersprite->set_angle(0.0f);
+        lightsprite->set_angle(0.0f);
+      }
 
       // if controls are currently deactivated, we take care of standing up ourselves
       if (deactivated)
@@ -644,6 +646,8 @@ Player::do_standup() {
     return;
   if (backflipping)
     return;
+  if (stone)
+    return;
 
   if (adjust_height(BIG_TUX_HEIGHT)) {
     duck = false;
@@ -860,6 +864,7 @@ Player::handle_input()
   if (controller->pressed(Controller::DOWN) && player_status->bonus == EARTH_BONUS && !cooldown_timer.started()) {
     if (controller->hold(Controller::ACTION) && !ability_timer.started()) {
       ability_timer.start(player_status->max_earth_time * STONE_TIME_PER_FLOWER);
+      powersprite->stop_animation();
       stone = true;
       physic.set_gravity_modifier(1.0f); // Undo jump_early_apex
     }
@@ -872,6 +877,9 @@ Player::handle_input()
   if (stone && (!controller->hold(Controller::ACTION) || ability_timer.get_timeleft() <= 0.5f)) {
     cooldown_timer.start(ability_timer.get_timegone()/2.0f); //The longer stone form is used, the longer until it can be used again
     ability_timer.stop();
+    sprite->set_angle(0.0f);
+    powersprite->set_angle(0.0f);
+    lightsprite->set_angle(0.0f);
     stone = false;
     for (int i = 0; i < 8; i++)
     {