Racing Loop?
by David Tiernan · in Torque Game Engine · 07/05/2005 (11:02 am) · 13 replies
Trying to figure out if the base racer setup (modified with the downforce mod) can do a loop for racing. So far it doesn't seem as the physics feel centrifugal so I don't think this is possible. I was wondering if anyone else has done this as of yet and if so could you share some tips?
Thanks,
Dave
Thanks,
Dave
About the author
#2
07/08/2005 (6:15 pm)
Yeah, I'd monkey around with engine power a bit, see how that effects things.
#3
runSurfaceAngle = 70;
in the player.cs that can be added to the vehicle block?
08/04/2005 (8:30 am)
I have tried several things and still cannot seem to get the car to want to loop however I was wondering if there is a command similar to the runSurfaceAngle = 70;
in the player.cs that can be added to the vehicle block?
#4
10/19/2006 (1:33 pm)
I'm looking at this issue myself now. Anyone have any luck either hacking it in via downforce and tire mods or thru true simulation of centrifugal force?
#5
bodyFriction - this slows the velocity of the vehicle when it hits a surface.
bodyRestution - makes the vehicle jump back when it hits something
contactTol & collisionTol - has something to do with the angles for collisions
10/20/2006 (7:55 am)
I dont know what the downward force mod is but you might try some of these:bodyFriction - this slows the velocity of the vehicle when it hits a surface.
bodyRestution - makes the vehicle jump back when it hits something
contactTol & collisionTol - has something to do with the angles for collisions
#6
http://www.garagegames.com/index.php?sec=mg&mod=resource&page=view&qid=8786
That sets your gravity directly under the vehicle so you can drive upside down and I was able to drive a full loop with it. The modification I was working on was trying to hack it to only kick at a certain speed say 60mph so if you hit a loop slow enough you would still fall but I wound up really messing it up.
10/20/2006 (8:37 am)
Well I was working with a resource before but never did get a chance to finish.http://www.garagegames.com/index.php?sec=mg&mod=resource&page=view&qid=8786
That sets your gravity directly under the vehicle so you can drive upside down and I was able to drive a full loop with it. The modification I was working on was trying to hack it to only kick at a certain speed say 60mph so if you hit a loop slow enough you would still fall but I wound up really messing it up.
#7
Still this isn't too far from a better centrifugal force calculation. From my initial research the force is based on the radius of the loop and the velocity of the vehicle. So you would calculate the radius of the loop by looking at the previous N up vectors. A larger radius needs more speed than a smaller radius. Still looking for the final formula for calculating the velocity a vehicle with mass X would need to travel a loop with Y radius.
10/20/2006 (8:54 am)
@David - That's an interesting solution. If i took this route i would interpolate between normal Z gravity and full "surface gravity" based on the vehicle velocity. This sort of works and as long as you build realistic looking loops for your vehicle.Still this isn't too far from a better centrifugal force calculation. From my initial research the force is based on the radius of the loop and the velocity of the vehicle. So you would calculate the radius of the loop by looking at the previous N up vectors. A larger radius needs more speed than a smaller radius. Still looking for the final formula for calculating the velocity a vehicle with mass X would need to travel a loop with Y radius.
#8
in real life anyways... "The speed required does not vary with the mass of the car".
10/20/2006 (9:42 am)
From reading this: http://www.newscientist.com/backpage.ns?id=lw574in real life anyways... "The speed required does not vary with the mass of the car".
#9
But it is a start in the right direction, you could always just use it for a temp fix right now while the ageia physics are still being implemented as that will completly change the physics for torque but I have seen no timeframe or version info giving even a glance of info as to when it would be implemented.
10/20/2006 (9:42 am)
The biggest issue I had with the current force calcs was by default even with a 32 sided tube the angular changes caused the car to "jump" on each tube section which I could get to around 90 degree's or so before I bounced off.But it is a start in the right direction, you could always just use it for a temp fix right now while the ageia physics are still being implemented as that will completly change the physics for torque but I have seen no timeframe or version info giving even a glance of info as to when it would be implemented.
#10
10/20/2006 (11:00 am)
The jumping sounds like either the suspension (force & damping fields) in WheeledVehicleSpring or the bodyRestitution. from what i've read the bodyRestution makes the vehicle jump back after it hits something (this might be more for running into walls now that I think about it).
#11
10/20/2006 (11:18 am)
What about the 'sticky walls' resource? Not sure where it is but I remember someone implemented a feature that caused tires to stick to a surface so players could drive up walls.
#12
That's the link I posted up a few posts back and what we were actually discussing. Guess I should of given the name of the resource with the link.
10/20/2006 (12:01 pm)
N R,That's the link I posted up a few posts back and what we were actually discussing. Guess I should of given the name of the resource with the link.
#13
10/20/2006 (12:47 pm)
Sticky walls works as well, but of course you need to gradually "unstick" from a wall else you can stop while upside down in a loop. David's resource is a good starting point, but as he said is isn't finished.
Torque Owner David Tiernan