Vehicle handling problems

blinkassassin

29-02-2008 02:10:27

Hi there, I have a question about vehicle physics values for a game my team is working on. At the moment the car is not handling very well. The car is rolling over when turning even though the center of mass is low ( -2). Ive pasted the car handeling .lua file below, if you notice anything strange or wrong please let me know, thanks.


Image showing car rolling when turning

function Cobey.Initialise(this)
car_scene = "Cobey.osm"
car_collision_mesh = "cobey_hull.mesh"
--all meters per second e.g. value below is 10km/s
foward_acceleration = 25000
max_foward_velocity = 100000
reverse_acceleration = 10000
max_reverse_velocity = 25000

--defined in local coordinate space.
--defined here instead of using another reference point because this is an option that
--could possibly need continous tweaking per vehicle, without the hassle of re-exporting
--the .mesh file after every change
car_center_of_mass_x = 0
car_center_of_mass_y = -2
car_center_of_mass_z = 0


--kilograms
car_mass = 5000
--meters
tire_radius = 2
--kilograms
tire_mass = 50
--how far the suspension can expand maybe? - meters
max_suspension_travel = 1
--force coefficient for when suspension is depressed maybe? documentation is unclear
suspension_damper = 0.25
--force coefficient for when suspension is expanding maybe? documentation is unclear
suspension_spring = 0.25
--resting length of supsension as a percentage of the max_suspension_travel - must be between 0 and 1.0
suspension_target = 0.5




Thanks.