NIKHIL
NIKHIL

Reputation: 2719

I Want Remove Continuous collision detection in Box2D at some specific stage how can i over come?

==> I am developing game like carom board Where i am facing few issue due to continuous collision detection.

  1. As shown in the image due to collision detection striker hanging around with gray puck and game can not get continue after that and playing sound continuously over there

  2. and i want play sound only first time when striker or puck hit each other or frame (wall ) but in my case if i put striker near wall sound is playing continuously

Screen Shot Thank you very much in advance Help is greatly appreciated

Upvotes: 2

Views: 515

Answers (1)

Ravi shankar
Ravi shankar

Reputation: 2460

In my view best way would be to maintain some minimum distance between both the sprites after collision detection this should be done in update function. This will resolve your first problem. For second problem just check frame of both the sprites and try to decrease the frame size.

Upvotes: 5

Related Questions