PhysX RagDoll fro AUM92 Problem

Posted By: Ch40zzC0d3r

PhysX RagDoll fro AUM92 Problem - 11/09/11 05:21

Hey guys laugh
Its me again smirk
I downloaded the AUM92 to get a view of basic ragdoll physics.
I opened all the code files and saw it was made with A7 (old ODE physics). So I converted to physX. Now my player falls down but the body isnt join correctly. All body-pieces fall on the floor without any ragdoll. I believe this code is the bad code. (Im coding just lite-c btw):

Code:
void RD_setHinge(ENTITY* constr_1, ENTITY* constr_2) {
	var tempHinge;
	
	// make constraint
	tempHinge = pXcon_add(PH_HINGE, constr_1, constr_2, 0); // attach to bodypart
	pXcon_setparams1(tempHinge, constr_1.x, RD_Hinge1, nullvector); // set hinge limits
	pXcon_setparams2(tempHinge, RD_Hinge2, nullvector, nullvector);    // same
}



And the original code:
Code:
void RD_setHinge(ENTITY* constr_1, ENTITY* constr_2) {
	var tempHinge;
	
	// make constraint
	tempHinge = phcon_add(PH_HINGE, constr_1, constr_2); // attach to bodypart
	phcon_setparams1(tempHinge, constr_1.x, RD_Hinge1, nullvector); // set hinge limits
	phcon_setparams2(tempHinge, RD_Hinge2, nullvector, nullvector);    // same
}



Please help me frown
Posted By: painkiller

Re: PhysX RagDoll fro AUM92 Problem - 11/09/11 10:09

In AUM 100 there is an example of radgolls using PhysX
Posted By: Ch40zzC0d3r

Re: PhysX RagDoll fro AUM92 Problem - 11/09/11 11:54

Thank you this one works laugh
Posted By: Ch40zzC0d3r

Re: PhysX RagDoll fro AUM92 Problem - 11/09/11 12:54

Ive got a problem when I try to use a new model.
I created all the bones needed but its not moving shocked
Its just stucking at vec 0,0,0.
Why this is so?
Posted By: painkiller

Re: PhysX RagDoll fro AUM92 Problem - 11/09/11 12:55

you need yo use also the same names from the other model for every bone
Posted By: Ch40zzC0d3r

Re: PhysX RagDoll fro AUM92 Problem - 11/09/11 13:49

I know ive done this!
I really dont know why frown
I uploaded my model for you, please look over it if you have time.

DL: http://www.mediafire.com/?ete983qru1qbsp2
Posted By: Ch40zzC0d3r

Re: PhysX RagDoll fro AUM92 Problem - 11/10/11 05:30

Please if anyone know how to fix the model bug plz help me frown
I fixed it!
My bones where f**** up by MED xD
Posted By: HeelX

Re: PhysX RagDoll fro AUM92 Problem - 11/11/11 15:58

I have downloaded your file and had a look at it.

1.) I don't know the code from the AUM nor the model which was used there - but in your model you have unconnected bones. I think you have to make an articulated bone skeleton.

2.) The bones are not connected with the vertices. You have to rig the model before you can see any movement, if a ragdoll systems drives the animation.

Small advice: Just print small dots with draw_point3d at all bone positions to see if the bones are transformed or not. This helps most often very much to debug such things.
Posted By: Ch40zzC0d3r

Re: PhysX RagDoll fro AUM92 Problem - 11/11/11 22:08

Yes you where right with the vertex thing. But as i see it i dont need to connect the bones.
I got problems with adjusting bones to vertexes. Now the model is standing half at middle, half is ragdolling...
There is an easy way to connect bones and vertexes right?
© 2024 lite-C Forums