Detect and cancel a collision

27 views
Skip to first unread message

Michael Miriti

unread,
Jul 4, 2017, 11:48:42 AM7/4/17
to Nape Physics
Hello,

I have an InteractionListener on CbEvent.BEGIN. It works perfectly but I need to prevent any interaction (movement of interactors after a collision) after that collision. I'm removing one of the bodies on this collision event and also doing this:

callback.int1.castBody.velocity.setxy(0, 0);
callback
.int2.castBody.velocity.setxy(0, 0);

But still the body which is not removed is getting an impulse and starting to move.

Is there a way to prevent it?
Reply all
Reply to author
Forward
0 new messages