omerabbas01 Posted October 22, 2014 Share Posted October 22, 2014 Hello Guys, I have today started working on a small task using HTML5 and Pixi JS. I have done my tasks by looking at examples of Pixi.JS but stuck with the Character Jump. I have loaded Json sprite sheet using AssetLoader and then i have used MovieClip to play running animation frames but now i don't know how i can make character jump here is my source code var framesRide = [];for (var i = 1; i < 7; i++) {framesRide.push(PIXI.Texture.fromFrame("hero_ride_loop_0" + i + ".png"));};heroRide = new PIXI.MovieClip(framesRide);heroRide.position.x = 300;heroRide.position.y = 286;heroRide.anchor.x = heroRide.anchor.y = 0.5;heroRide.play();heroRide.animationSpeed = 0.5;stage.addChild(heroRide);heroRide.interactive = true;heroRide.click = function(d) {console.log("clicked"); Here i want this character to Jump also change the animation. Which is loaded already in the assets.};Please help me with that Quote Link to comment Share on other sites More sharing options...
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.