|
What I am wondering is how will you make your character move ? By
applying forces directly on the body ? Is it possible to get smooth
moves with this system as if the character was walking ? I guess it is
possible if you set a very little mass for your body to avoid inertia
side effect. This is interesting. I hope you will complete the amotor implementation and make a test program for your system. I want to see this :) Souvarine. Zoltán Döme wrote: Well, maintaining an upright orientation for an object in ODE is *very* easy with an angular motor (BTW the AngularMotor wrapper class is incomplete, as it misses parameter setting functions, and has a negated condition in nb_axes.__set__).Basically this should make a body maintain a constant orientation without strange side-effects: motor = soya.AngularMotor( body ) # euler mode motor.mode = 1 # this is buggy in codebase motor.nb_axes = 3 motor.setAxis( 0, Vector(body, 1,0,0) ) motor.setAxis( 1, Vector(body, 0,1,0) ) motor.setAxis( 2, Vector(body, 0,0,1) ) motor.setAngle(0, 0.0) motor.setAngle(1, 0.0) motor.setAngle(2, 0.0) motor.lo_stop = motor.hi_stop = 0.0 # these are missing from AngularMotor, but are trivial to implement motor.lo_stop2 = motor.hi_stop2 = 0.0 motor.lo_stop3 = motor.hi_stop3 = 0.0 The second problem is rather tricky, but it can be solved pretty well, by using a ray for feet, which also acts as a dampened spring -- the ODE list has some ideas/examples for this. Sure, this is not very easy, but it has the advantage of having correct collision/force response throughout the world, including controlled avatars too. And the CPU-cost part can be greatly reduced by enabling auto-disabling of bodies, and having them enabled when the position is invalidated, or when something collides with them. By the way this makes simulations a lot more stable too. Well, this can all be done outside the engine, except for the broken AngularMotor class, which has to be finished. -- Zoltan Dome On 9/22/07, Souvarine <[EMAIL PROTECTED]> wrote: |
_______________________________________________ Soya-user mailing list [email protected] https://mail.gna.org/listinfo/soya-user
