Maya PhysX object crashes game.exe
by 840LABS · in Torque 3D Professional · 12/10/2009 (1:55 pm) · 1 replies
Hello,
Im new to Torque 3d and Im trying to add a Maya PhysX object to my Torque scene. The game crashes when I add the object. The PhysX object is simple cube tagged as a dynamic rigid body. I'm not sure if my crash is a bug, if I'm setting up my Maya scene incorrectly, or perhaps adding PhysX objects from Maya is not possible.
I exported a PhysX .xml and Collada file using openCollada from of Maya.
I added my PhysX object to the PhysX.cs file and when I place the object in my Torque scene, the Game.exe crashes.
Console.log prints the following error:
f:p4physxexperimentalPhysX_2.8.1_GPUnovodexSDKsPhysicssrcNpScene.cpp(894) : Supplied NxActorDesc is not valid. createActor returns NULL.
The XML file's "NxActorDesc" has a null name:
<NxActorDesc id="Actor_0" userProperties="" hasBody="false" name="">
Is this a user error or is PhysX data from Maya not compatible with Torque3d?
Thanks!
Mike
Im new to Torque 3d and Im trying to add a Maya PhysX object to my Torque scene. The game crashes when I add the object. The PhysX object is simple cube tagged as a dynamic rigid body. I'm not sure if my crash is a bug, if I'm setting up my Maya scene incorrectly, or perhaps adding PhysX objects from Maya is not possible.
I exported a PhysX .xml and Collada file using openCollada from of Maya.
I added my PhysX object to the PhysX.cs file and when I place the object in my Torque scene, the Game.exe crashes.
Console.log prints the following error:
f:p4physxexperimentalPhysX_2.8.1_GPUnovodexSDKsPhysicssrcNpScene.cpp(894) : Supplied NxActorDesc is not valid. createActor returns NULL.
The XML file's "NxActorDesc" has a null name:
<NxActorDesc id="Actor_0" userProperties="" hasBody="false" name="">
Is this a user error or is PhysX data from Maya not compatible with Torque3d?
Thanks!
Mike
Torque Owner TheGasMan
G.A.S. [+others]
#2. take the name of the object that the actor is used for..and then append that name with "_pxactor"
Thus, if your shape was named "cardboardbox" then name the actor "cardboardbox_pxactor".
I am not sure if the user properties are exported from maya/physx..so you may need to add this to the user properties by hand:
userProperties="PhysicsType = 1%0D%0AMass = 1.0%0D%0AGeometryType = 1%0D%0AMaterialType = 2%0D%0AFriction = 0.3%0D%0AStaticFriction = 0.3%0D%0ARestitution = 0.0%0D%0AInitialVelocityX = 0.0%0D%0AInitialVelocityY = 0.0%0D%0AInitialVelocityZ = 0.0%0D%0AInitialSpinX = 0.0%0D%0AInitialSpinY = 0.0%0D%0AInitialSpinZ = 0.0%0D%0APutToSleep = false%0D%0AEnableCCD = false%0D%0A"
Basically, settings for the shape with "%0D%0A" separating the items within the property list.
I hope this makes sense to you...and as I said in another thread, I am looking into Maya and PhysX over the next few days...so any info you can share will be helpful to both of us on this topic as I will return the favor.