Minimal support for climbing graphics
authorLMH <lmh.0013@gmail.com>
Thu, 22 Mar 2012 01:41:15 +0000 (15:41 -1000)
committerLMH <lmh.0013@gmail.com>
Thu, 22 Mar 2012 01:41:15 +0000 (15:41 -1000)
data/images/creatures/tux/tux.sprite
src/object/player.cpp

index 0487a0d..3ca2135 100644 (file)
          (mirror-action "small-idle-right"))
 
        (action
+         (name "small-climbing-right")
+         (hitbox 8 16 32 32)
+         (images "small/ladder-0.png"
+                 "small/ladder-1.png"
+                 "small/ladder-2.png"
+                 "small/ladder-3.png"
+                 "small/ladder-2.png"
+                 "small/ladder-1.png"))
+
+       (action
+         (name "small-climbing-left")
+         (hitbox 8 16 32 32)
+         (mirror-action "small-climbing-right"))
+
+       (action
          (name "grow-right")
          (fps 15.0)
          (hitbox 16 13 32 64)
          (mirror-action "big-idle-right"))
 
        (action
+         (name "big-climbing-right")
+         (hitbox 16 14 32 64)
+         (images "big/ladder-0.png"
+                 "big/ladder-1.png"
+                 "big/ladder-2.png"
+                 "big/ladder-3.png"
+                 "big/ladder-2.png"
+                 "big/ladder-1.png"))
+
+       (action
+         (name "big-climbing-left")
+         (hitbox 16 14 32 64)
+         (mirror-action "big-climbing-right"))
+
+       (action
          (name "big-duck-right")
          (hitbox 16 45 32 32)
          (images "big/duck-0.png"))
          (mirror-action "fire-idle-right"))
 
        (action
+         (name "fire-climbing-right")
+         (hitbox 16 14 32 64)
+         (images "fire/ladder-0.png"
+                 "fire/ladder-1.png"
+                 "fire/ladder-2.png"
+                 "fire/ladder-3.png"
+                 "fire/ladder-2.png"
+                 "fire/ladder-1.png"))
+
+       (action
+         (name "fire-climbing-left")
+         (hitbox 16 14 32 64)
+         (mirror-action "fire-climbing-right"))
+
+       (action
          (name "fire-duck-right")
          (hitbox 16 45 32 32)
          (images "fire/duck-0.png"))
          (mirror-action "ice-idle-right"))
 
        (action
+         (name "ice-climbing-right")
+         (hitbox 16 14 32 64)
+         (images "ice/ladder-0.png"
+                 "ice/ladder-1.png"
+                 "ice/ladder-2.png"
+                 "ice/ladder-3.png"
+                 "ice/ladder-2.png"
+                 "ice/ladder-1.png"))
+
+       (action
+         (name "ice-climbing-left")
+         (hitbox 16 14 32 64)
+         (mirror-action "ice-climbing-right"))
+
+       (action
          (name "ice-duck-right")
          (hitbox 16 45 32 32)
          (images "ice/duck-0.png"))
index 22b2b4f..89984f5 100644 (file)
@@ -1073,7 +1073,7 @@ Player::draw(DrawingContext& context)
     // update() will take care of cancelling when growing completed
   }
   else if (climbing) {
-    sprite->set_action(sa_prefix+"-skid"+sa_postfix);
+    sprite->set_action(sa_prefix+"-climbing"+sa_postfix);
   }
   else if (backflipping) {
     sprite->set_action(sa_prefix+"-backflip"+sa_postfix);