Jump to content

Enabeling Arcade physics causes sprites to disappear


Recommended Posts


I've used both individual sprites and a group (from a set of arrays). Either way once I enable Arcade physics the sprites dissapear.

full code is here : https://github.com/EMC23/JiGS/blob/master/components/com_battle/views/phaser/tmpl/playstate01.js


I've used same method elsewhere without issues, so I'm completely stumped.


Any help appreciated.


////////////////////////place players//////players_group = game.add.group();if (typeof players_list != 'undefined') {for (var index = 0; index < players_list.length; index++) {var key = players_list[index].id//add_players[index] = game.add.sprite(players_list[index].posx, players_list[index].posy, key);players_group.create(players_list[index].posx, players_list[index].posy, key);}game.physics.enable( players_group, Phaser.Physics.ARCADE);} 
Link to comment
Share on other sites


  • Recently Browsing   0 members

    • No registered users viewing this page.
  • Create New...