cpu_sam Posted May 23, 2018 Share Posted May 23, 2018 Reading this topic above, I've found that Sprite.update it's not called, however: how can I call the update in the main.update? I've tried the code in the topic but it doesn't works for me, that without the directly reference to player object. But I would like to call the Player.Sprite.update without the player reference explicitly declared in the source. Can anyone help me? Link to comment Share on other sites More sharing options...
samme Posted May 23, 2018 Share Posted May 23, 2018 Do you mean you can't do function update () { player.update(); } ? In that case you can try function create () { // ... this.events.on('update', player.update, player); } cpu_sam 1 Link to comment Share on other sites More sharing options...
cpu_sam Posted May 23, 2018 Author Share Posted May 23, 2018 I was thinking that Sprite.update was called every frame update automatically. Like I've searched for some human example and not found any, so I cannot to learn the "right"way. And once time again @samme thanks a lot! Link to comment Share on other sites More sharing options...
samme Posted May 23, 2018 Share Posted May 23, 2018 phaser/issues/3378 Link to comment Share on other sites More sharing options...
cpu_sam Posted May 23, 2018 Author Share Posted May 23, 2018 Thanks, I'll follow this issue. Link to comment Share on other sites More sharing options...
Recommended Posts