Try my physics demo?

Started by
9 comments, last by NeXius 20 years, 3 months ago
Hi I saw the great character physics in UT 2K3 and tried to implement it myself, to limited success... Getting the physics to work didn''t take very long, but positioning the model according to the physics skeleton is downright impossible! I''ve tried everything.... If nobody can help me than I plan to give up, since I''ve spent too much time on this already... Anyway, this is what I have at the moment. I''m confident I can fix the bugs with the physics, but if I can''t figure out how to draw the model over the skeleton then there''s no point... Right now this is how I''m trying to do it: I calculate the directional vector from the root joint in the physics skeleton to a child joint and then calculate the rotation required to go from the initial directional vector to this current one... and then apply the rotation to vertices that are attached to the bone corresponding to this joint on the model. (the model uses skeletal animation) But this looks terrible! I have no idea what else to do... Any suggestions would be very appreciated. Thanks
MSN: stupidbackup@hotmail.com (not actual e-mail)ICQ: 26469254(my site)
Advertisement
A pretty decent start. Its not "flashy" but at the core its a good demo. Keep up the good work.

[Mercury Software] [Google!] [ Look I DONT Follow Trends ]
Sorry if this is a double post but i love the whole hit CTRL and Mario dies. That is a great effect!

[Mercury Software] [Google!] [ Look I DONT Follow Trends ]
Ya it is, but it''s pretty useless if there isn''t a mesh
MSN: stupidbackup@hotmail.com (not actual e-mail)ICQ: 26469254(my site)
It doesn''t work... I get 404.

---
shurcooL`
turn off your firewall

worked for me when I turned off my firewall. It''s a cool demo, it looks like stairs dismount I always enjoy looking at demos with the ragdoll effect
Why don't alcoholics make good calculus teachers?Because they don't know their limits!Oh come on, Newton wasn't THAT smart...
A firewall can''t stop an HTTP file download from working. It works fine for me now as well; I guess there was something temporary wrong with the server.

Trying the demo now...

---
shurcooL`
It looks like your joints are simple, single, point-to-point constraints - i.e. one point on the head is constrained to be colocated with one point on the torso. Anyway, this isn''t enough to stop the joints spinning around, which will mess things up.

You can easily construct "hinge" joints from pairs of the point-point constraints - this will stop the limbs from rotating around unwanted directions. However, your ragdoll will then look rather wooden, because hinges don''t represent the shoulder/hips/neck very well. Two ways of getting around this are:

1. make universal joints out of two hinge joints. These will work OK, allowing you to specify the joint limits independantly in the two hinges. However, every extra hinge introduces its own problems...

2. Make a "sloppy" hinge by using 3 point-point constraints:
        1BODY_A  2  BODY_B        3 

Each number represents a point-point constraint between bodies A and B. constraint 2 is enforced strongly, so that the two bodies stay connected at all times. However, allow some sloppiness when enforcing the constraints 1 and 3 - controlling the amount of sloppiness will allow a bit of rotation around the non-hinge axes.

You also need to work out how to apply limits on the joints (can be done with a constraint on the max distance between two points on pairs of bodies), and also do self-collision between the limbs.

Might be able to help more/better if you gave some details about how you''re implementing this (e.g. put the source code in your zip file...)

Thanks for your reply.

OK well I've updated the demo to show my attempt at applying the mesh to the physics model...

It looks terrible at the moment, because it can spin around the direction it points into.

(hit 1 and 2 to see the physics skeleton again)

I've also added the source into the zip file, so hopefully it's readable enough for you to understand what's going on

I know what you mean about adding more constraints, but right now I'm just concentrating on getting it to not look like crap when I apply the model to it. If I can't figure that out than it's not much good, for my purposes at least

[edited by - nexius on January 18, 2004 5:13:00 PM]
MSN: stupidbackup@hotmail.com (not actual e-mail)ICQ: 26469254(my site)
I like fall out ... hum sry
!o)

This topic is closed to new replies.

Advertisement