Sorry your browser is not supported!

You are using an outdated browser that does not support modern web technologies, in order to use this site please update to a new browser.

Browsers supported include Chrome, FireFox, Safari, Opera, Internet Explorer 10+ or Microsoft Edge.

Dark Physics & Dark A.I. & Dark Dynamix / Temporarily remove an object from collisions in DarkPhysics

Author
Message
monotonic
18
Years of Service
User Offline
Joined: 24th Mar 2006
Location: Nottinghamshire, England
Posted: 7th Apr 2008 19:17 Edited at: 7th Apr 2008 20:33
Hi All,

What I am wanting to do is temporarily remove a static object from the physics system so that other objects can pass through it.

For instance, in my engine I'm setting up a door as a static rigid body box, then when the user opens the door I want to temporarily remove the door from the system. I don't want to delete the rigid body and re-create it when the door is closed, because this is very inefficient.

I have tried phy sleep rigid body, calling it every frame so it doesn't get woken up by DP, but this doesn't work.

Any ideas would be appreciated.

Much good work is lost for the lack of a little more.
david w
18
Years of Service
User Offline
Joined: 18th Dec 2005
Location: U.S.A. Michigan
Posted: 7th Apr 2008 21:18 Edited at: 7th Apr 2008 21:18
try to position it at some far reach in space and then bring it back to current world space. this way your just moving it around and not actually doing anything harmful.
monotonic
18
Years of Service
User Offline
Joined: 24th Mar 2006
Location: Nottinghamshire, England
Posted: 7th Apr 2008 21:45
Ok, yeah I could just create a hidden box around the door using this as the collision object, then position it at the far reaches of the galaxy.

Good idea, but I was hoping that this obvious requirement had been implemented into DarkPhysics, I'm sure there is functionality in PhysX to disable an objects' collisions.

I have been trying to find a way of creating a kinematic object around the moving part of the door, then position/rotate this to the position/rotation of the animated door limb. But, because I use an offset pivot point for the doors that swing open I have been having a bit of trouble.

Much good work is lost for the lack of a little more.

Login to post a reply

Server time is: 2024-05-19 21:52:04
Your offset time is: 2024-05-19 21:52:04