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 / Problem created rigid body mesh

Author
Message
Chiblue
15
Years of Service
User Offline
Joined: 6th Nov 2009
Location: NE PA, USA
Posted: 10th Aug 2010 14:34
I am using Dark GDK and Dark Physics in my project, I am trying to build ejecting cartridges into the firing sequence...

The problem is the model gets created and positioned correctly but the rigid body is not getting created correclty and I don't know why, I checked my code, and if I do a dbPhyGetRigidBodyExist on the object number I get a 0 meaning does not exists...

Any Ideas?

HowDo
21
Years of Service
User Offline
Joined: 28th Nov 2002
Location: United Kingdom
Posted: 10th Aug 2010 16:08
this might help.

take
dbPhyMakeRigidBodyDynamicMesh(tempcart->getID());

and replace with

dbPhyLoadRigidBodyDynamicMesh(tempcart->getID());

in basic it works the opposite, load to do make and make to do load.

Dark Physics makes any hot drink go cold.
Chiblue
15
Years of Service
User Offline
Joined: 6th Nov 2009
Location: NE PA, USA
Posted: 10th Aug 2010 18:01 Edited at: 10th Aug 2010 18:06
Well that makes a lot of sense....lol

I tried this and get the compile error...

"error C2661: 'dbPhyLoadRigidBodyDynamicMesh' : no overloaded function takes 1 arguments"
HowDo
21
Years of Service
User Offline
Joined: 28th Nov 2002
Location: United Kingdom
Posted: 10th Aug 2010 18:09
in basic we do this

phy load rigid body dynamic mesh id,"file.x",0

needs three values on the end.

Dark Physics makes any hot drink go cold.
Chiblue
15
Years of Service
User Offline
Joined: 6th Nov 2009
Location: NE PA, USA
Posted: 10th Aug 2010 18:21 Edited at: 10th Aug 2010 18:23
Actually I did get it working, I used dbPhyMakeRigidBodyDynamicBox, this solved my problem, I should have remembered becuase I have seen this before where something in the mesh causes the mesh body to fail, I had a similar issue with using static terrain, instead I used a static mesh and everything was wonderful...

Thanks for the help..

I have included the changed code, also does anyone know the exact reason why box will work but mesh will not, just out of curiosity?

HowDo
21
Years of Service
User Offline
Joined: 28th Nov 2002
Location: United Kingdom
Posted: 10th Aug 2010 18:38
I think was going to be command that would be drop.

Remember you my still be able to do it using the direct physx code eg actors, like you would if gdk had not been around.

Dark Physics makes any hot drink go cold.
Chiblue
15
Years of Service
User Offline
Joined: 6th Nov 2009
Location: NE PA, USA
Posted: 10th Aug 2010 19:44
Thanks, I tried that with Leadwerks and ended up building all my own opengl functions, ended up rewriting most of the engines 2d opengl management functions... don't want to have to learn Physx also, would rather use the DP commands if possible...

Login to post a reply

Server time is: 2024-11-24 13:08:21
Your offset time is: 2024-11-24 13:08:21