Collision

Discuss any questions about BEPUphysics or problems encountered.
Post Reply
pesant19
Posts: 4
Joined: Thu Mar 19, 2015 7:03 pm

Collision

Post by pesant19 »

I have difficulty to understand the collision documentation. I made a golf game and I try to set the collision between an the hole. The hole is a static entity and the ball is a dynamics entity. I want to know when the ball hit the cylinder. I had a golf course and the collision functional, but I want to set a different reaction when she hit the hole, like disappears.
Norbo
Site Admin
Posts: 4929
Joined: Tue Jul 04, 2006 4:45 am

Re: Collision

Post by Norbo »

It sounds like collision events would be useful. Check out the FishInABarrelDemo in the BEPUphysicsDemos for an example of their use. If you haven't seen it already, also check out the collision events documentation. You'll probably want to use one of the 'deferred' events (those with past-tense names, like InitialCollisionDetected) to do your removal logic.
Post Reply