Skip to content
Browse files

Fixed up some player animations

  • Loading branch information...
1 parent 970a727 commit f022a646f324d3d2ef609610139729165856ea27 @vad710 vad710 committed Apr 21, 2012
Showing with 9 additions and 1 deletion.
  1. +9 −1 src/Player.as
View
10 src/Player.as
@@ -54,10 +54,13 @@ package
this.loadGraphic(player_Sprite, true, true, 150, 150);
this.addAnimation('jump', [1, 2, 3], 6, false);
this.addAnimation('stand', [0], 6, false);
- this.addAnimation('crawl', [4, 5, 6, 7, 8, 0], 6, false);
+ this.addAnimation('crawl', [4, 5, 6, 7, 8], 6, false);
this.addAnimation('die', [9, 10, 11, 12, 13, 14], 6, false);
this.addAnimation('splash', [15, 16, 17, 18, 19, 20, 21, 22, 23], 6, false);
+ this.addAnimation('idle', [0, 1, 2, 1], 6, true);
firstPlanet.PlaceOnPlanet(this);
+
+ this.play("idle");
}
override public function update():void
@@ -164,6 +167,11 @@ package
this._currentPlanet.PlaceOnPlanet(this);
}
}
+
+ if (FlxG.keys.justReleased("LEFT") || FlxG.keys.justReleased("RIGHT"))
+ {
+ this.play("idle");
+ }
}
private function jump():void

0 comments on commit f022a64

Please sign in to comment.
Something went wrong with that request. Please try again.