aroth Posted September 30, 2015 Share Posted September 30, 2015 Hello. I stumbled across Phaser last night and created a quick demo that extends a sprite to use a state machine. State and transitional animations are handled automatically. In the past I've used this system for an ImpactJS game where the playable character had 15 states. In the demo I've included 4: - sitting- walking- laying- sleeping Press the RIGHT key to cycle through the states. The cat will automatically lay and then sleep after a couple seconds if there is no input. Perhaps someone will find this useful. Demo:http://www.adamjroth.com/phaser-extend-sprite-statemachine-example/ GitHub Repo:https://github.com/aroth/phaser-extend-sprite-statemachine-example Screenshot: Skeptron, chongdashu, BrunoHautenfaust and 1 other 4 Link to comment Share on other sites More sharing options...
jmp909 Posted November 10, 2015 Share Posted November 10, 2015 really useful. thanks for sharing Link to comment Share on other sites More sharing options...
drhayes Posted November 11, 2015 Share Posted November 11, 2015 Hello Mr. Adam Roth! Good to see you again, man. You should get in the Slack channel. Link to comment Share on other sites More sharing options...
Recommended Posts