samme Posted September 8, 2016 Share Posted September 8, 2016 GitHub / NPM You could use it to animate, start emitters, update health bars, … var sprite = game.add.sprite(); sprite.onDamaged.add(function (amount, health, maxHealth){ // sprite was damaged by {amount} // now has {health}/{maxHealth} }, sprite); drhayes 1 Link to comment Share on other sites More sharing options...
Recommended Posts