My results of first step for creating advanced car physics!

Blitz3D Forums/Blitz3D Programming/My results of first step for creating advanced car physics!

ChrML(Posted 2003) [#1]
Ok, my first step for advanced car physic is done. I've made a calculator based on an equation which returns the total horsepowers needed to overcome the total air resistance at given speed, frontal car area, drag coefficient, and air density. What it returns is number of horsepowers needed to overcome the air resistance. The speed must be given in meters/s, and frontal car area in meters2. In an ordinary day, the air density is about 1013.25. Let's say we have the following information:
We drive in an ordinary day (air density: 1013.25), in 100 km/h, which is 27.777 m/s. We drive in a Jeep Cherokee, which has a drag coefficient on 0.45, and a frontal area on 2.4 m2 (see http://www.teknett.com/pwp/drmayf/tbls.htm ) for more info about that). Then we will have the following info:
Air Density: 1013.25
Velocity: 27.777
Frontal Area: 2.4
Drag Coefficient: 0.45

The program will the return that you need 154.214 horsepowers to overcome the air resistance in a Jeep Cherokee in 100 km/h. This is the program I created: http://www.thps3cu.com/carphysics.zip . I'll post the formula it uses later if anyone wants it.


semar(Posted 2003) [#2]
Are you going to make an application for the N.A.S.A., or would you use it for a game ?

See, you can put in your code all the math theory, and have the most perfect phisic simulation system that the world even seen. Guess what, the player will never notice it.

;-)

Sergio.


Ross C(Posted 2003) [#3]
The verlet example in the 3d advanced forum is pretty cool, with the car and racetrack :) You should check it out!


ChrML(Posted 2003) [#4]
The player will definitly notice the air resistance, because almost (depends on the speed) 90% of the cars horsepowers are used to overcome the air resistance. So, to be able to calculate accelleration, and stuff, out of horsepowers, the air resistance is a very important part of the car's physics.


Orca(Posted 2003) [#5]
Just to be nit pickity, but if you want advanced car physics your also going to need to delve into traction,weight transfer, suspension geometry,the engines powerband & gearing, etc

Like I said, just being nitpicking :)

I have to disagree on people not noticing car physics though. I think GT3 has done an absolutely *awesome* job of modeling realistic car physics. Its almost ruined all the ridge racer type games for me. So yes, people do notice.

Interesting little sidenote, but I read an article (forgot where, some car mag I believe) about how the laptimes of a real NSX and the digital GT3 version were roughly the same, maybe tenths of a second apart.


ChrML(Posted 2003) [#6]
Yeah, ofcourse all from weighttransfer to gearing and skidding distance have to be calculated, but as said in the title, this is the first step ;). I agree to that GTA3 has done an awesome job, but just as awesome job has also Need for Speed, and tons of other games.


Koriolis(Posted 2003) [#7]
I agree with POedBoy on that. If you aim at doing a GTA3 type game, then of course you're going in the right direction trying to get as close as possible to real physics.
Most of the time the player will indeed not notice all the math involved, but will notice how realistic (or not...) the driving is.
As always the trick is even better if everything seems natural and you don't notice it in the end :)


Vorderman(Posted 2003) [#8]
The physics in GT3 are spot on - not necessarily 100% realistic, but seing as you lack all the physical feedback such as g-forces, steering feel etc... it doesn't matter.

I believe the laptimes for GT4 have been shown to be within a second or so of the real car, which bodes well for the game. In a game like GT, purely about the car and the track, the feel of the car is the most important thing. Of course, GT looks great also, which certainly helps.

I suggest you should all look at NetKar to see how a real driving sim is made - it blows away Racer and Live For Speed, which until I saw NetKar was my favourite race game. Netkar has the fun/realism ratio spot on, with what feels like realistic levels of grip, whereas NFS is way too slippy.


Vorderman(Posted 2003) [#9]
hyperblitzer: best of luck with your car sim by the way - I know from experience how difficult they are to code.


podperson(Posted 2003) [#10]
The suggestion that most players won't realise your car physics are inaccurate is highly dubious. Most players drive cars and have a pretty good idea of how they should handle, if not at high speed at moderate speed. Plenty of effort goes into making flight sims satisfy the relatively small number of players who can fly planes (and even I know enough about aerodynamics to realise that your wings don't help you gain altitude when they're vertical...).

A friend of mine drives rally cars for fun. The first thing he does when he plays a car game (and he likes car games) is try to do the stuff that you actually need to do in a fast moving car to take hard corners on dirt tracks (it involves using the clutch, brake, and accelerator at the same time) etc. and most car sims don't cut the mustard (GTurismo may, but GTheftAuto certainly doesn't).


Al Mackey(Posted 2003) [#11]
The player will definitly notice the air resistance, because almost (depends on the speed) 90% of the cars horsepowers are used to overcome the air resistance.


This fact must have come from the people who designed the Scion xB.


Ross C(Posted 2003) [#12]
LOL!


WolRon(Posted 2003) [#13]
Umm, isn't GT3, Gran Turismo 3, and GTA3, Grand Theft Auto 3? These are two entirely different games.

The physics in GT3 are spot on - not necessarily 100% realistic, but seing as you lack all the physical feedback such as g-forces, steering feel etc... it doesn't matter


The physics are as realistic as they can be in a game (of course there are a lot of things missing from reality such as crash ups and cars flipping over and oil slicks, etc.). But GT3 does provide you with steering feel if you own a Logitech force-feedback wheel. In fact, I was having MUCH difficulty defeating the harder tracks with the PS2 controller. When I bought the wheel I was able to turn in such smaller increments and I could actually feel when the tires would begin to slip so I would know when to let up a bit on the gas (which is also an improvement over the standard controller) and avoid a spinout or loss of traction.
If only they could simulate G-forces...


StOrM3(Posted 2003) [#14]
Yes a G-Force simulator would rock, I can think of alot of games that would be great for, flight sims, racing games, bike racing games, everything even a 3d platformer would feel awesome jumping etc.. and running with a power-up full speed.

heheh
Ken


ChrML(Posted 2003) [#15]
Yeah, I agree to Ken (storm3). WolRon, GT is Gran Turismo which is a racing game, and GTA, Grand Theft Auto, is a brutal crime game, with cars (kinda real-gang-life game).


Vorderman(Posted 2003) [#16]
"But GT3 does provide you with steering feel if you own a Logitech force-feedback wheel"

I do have one of those, but it wasn't as great as I'd hoped it would be. I still prefer to play GT with the PS2 pad for some reason, despite the fact that I only play PC sims with an MS FF wheel. GT just seems perfectly honed to work with the pad, whereas the car wanders slightly with the wheel - it's very hard to get it to go in a straight line. Maybe there is some controller setting that I missed?