santosh.a Posted January 8, 2014 Share Posted January 8, 2014 Hi, I was trying to simulate bullet(has body) collision with a custom AI class that has a PlayerActor instance. How do I detect if the bullet has hit the PlayerActor capsule shape? Currently, from the bullet's contact callback function, I am receiving a contact with a body (of AI). I presume this body is PlayerActor class's body (playerActor.getBody()). Now that I have found this body, how do I find it's PlayerActor? Link to comment
sebastianbah Posted January 10, 2014 Share Posted January 10, 2014 Hello,You can use setVariable()/getVariable() functions to identify the node.Moreover, you can try to use engine.world.getIntersection() function to improve collision detection of the bullet on the high velocities. Link to comment
Recommended Posts