NewtonBodyCalculateInverseDynamicsForce

A place to discuss everything related to Newton Dynamics.

Moderators: Sascha Willems, walaber

NewtonBodyCalculateInverseDynamicsForce

Postby carli2 » Sat Feb 16, 2013 9:37 am

Hi,

since NewtonBodyCalculateInverseDynamicsForce is not implemented
Code: Select all
     _ASSERTE (0);
        return dgVector();

I wrote my own force calculation function like this:
Code: Select all
    // F = m*a
    // v = a*t
    // a = v/t
    // => F = m*v/t
    // t = ticks/framerate
    // => F = m*v*framerate/ticks
    NewtonBodyGetMassMatrix(o.newton, @mass, @ixx, @iyy, @izz);
    forceout[0]:=mass*tspeed[0]*framerate/ticks;
    forceout[1]:=mass*tspeed[1]*framerate/ticks;
    forceout[2]:=mass*tspeed[2]*framerate/ticks;


When the character now pushes a object, one would need more force to move both objects. Is there a function to get the total ammount of foce needed to also push away what is lying in front of my character?
carli2
 
Posts: 157
Joined: Thu Nov 10, 2011 1:53 pm

Re: NewtonBodyCalculateInverseDynamicsForce

Postby Julio Jerez » Tue Apr 09, 2013 9:44 am

I need to work on this, there is more work to do on eh player controller still. I will cover pushing other bodies when I get there, I was fix some other bugs now I want to complete the vehicle before I move to finish the player.
Julio Jerez
Moderator
Moderator
 
Posts: 12426
Joined: Sun Sep 14, 2003 2:18 pm
Location: Los Angeles


Return to General Discussion

Who is online

Users browsing this forum: No registered users and 0 guests

cron