Center of gravity
Posted: Sun Sep 02, 2012 12:16 pm
Hi again,
I want to see center of gravity, but I only know how to see center of mass. I attach screenshot where green ball is my center of mass and red ball is world matrix of object( this ball isn't collision model, I swapped car's convex hull with red ball in a draw call in order to see postion of green ball).
I can't get my car to behave properly(or should I say, as I want it to) so I want to see CoG to give me some idea if I set certain values wrong or right (my car becomes either extremely oversteered or understeered at higher speeds with almost no acceleration).

I want to see center of gravity, but I only know how to see center of mass. I attach screenshot where green ball is my center of mass and red ball is world matrix of object( this ball isn't collision model, I swapped car's convex hull with red ball in a draw call in order to see postion of green ball).
Code: Select all
ball.setColor(Color.Green.ToVector3());
ball.draw(Matrix.CreateTranslation( car.Body.Position));
ball.setColor(Color.Red.ToVector3());
ball.draw(car.Body.CollisionInformation.WorldTransform.Matrix);
