Uibon Posted March 18, 2014 Share Posted March 18, 2014 I am still pretty new to game development so I don't know if this is a bug or intended. I created a group of enemies which are randomly placed and then tweened to move to a random location. It works fine if the code is like this: enemies1 = game.add.group(); enemies1.createMultiple(10, 'enemy_red'); enemies1.setAll('checkWorldBounds', true); enemies1.setAll('outOfBoundsKill', true);But suddenly stops working the moment I add a physics system to the group. enemies1 = game.add.group(); enemies1.enableBody = true; enemies1.physicsBodyType = Phaser.Physics.ARCADE; enemies1.createMultiple(10, 'red'); enemies1.setAll('checkWorldBounds', true); enemies1.setAll('outOfBoundsKill', true);Any solutions? I need the collision detection so I can check if the enemy collides with the player. Link to comment Share on other sites More sharing options...
Uibon Posted March 18, 2014 Author Share Posted March 18, 2014 nevermind using enemy.body worked.. Link to comment Share on other sites More sharing options...
Recommended Posts