Gamestudio Links
Zorro Links
Newest Posts
Data from CSV not parsed correctly
by dr_panther. 05/06/24 18:50
Help with plotting multiple ZigZag
by degenerate_762. 04/30/24 23:23
M1 Oversampling
by 11honza11. 04/30/24 08:16
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
3 registered members (ozgur, degenerate_762, 7th_zorro), 1,081 guests, and 0 spiders.
Key: Admin, Global Mod, Mod
Newest Members
firatv, wandaluciaia, Mega_Rod, EternallyCurious, howardR
19050 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Page 1 of 2 1 2
Correct gravity and Mass ? #52997
08/22/05 07:16
08/22/05 07:16
Joined: Sep 2004
Posts: 260
UB,Mongolia
Olzii Offline OP
Member
Olzii  Offline OP
Member

Joined: Sep 2004
Posts: 260
UB,Mongolia
Hi all,

I am making a car game. My level has scale 1quant = 20 cm.
In manual there is hint to set gravity :

<<<Earth gravity at sea level is ca –9.81 m/s2, 1 quant is usually defined to be 1 inch, which equals 2.54 cm. Therefore to simulate gravity on earth with a standard scale you would set vecGravity.z to (–9.81 * 100 / 2.54) = -386.>>>

By this hint, my gravity is (–9.81 * 100 / 20cm) = - 49.05

And i set my car's mass in kg units. Also i applied torque to car in N.m units.

And my car is acting like SPACE car.

How to set correct gravity and mass ?


The Empire of the Mongols comprised the largest continuous land empire ever, reaching from Korea to Poland
Re: Correct gravity and Mass ? [Re: Olzii] #52998
08/22/05 14:21
08/22/05 14:21
Joined: Mar 2004
Posts: 564
Richmond, BC, Canada
Calined Offline
User
Calined  Offline
User

Joined: Mar 2004
Posts: 564
Richmond, BC, Canada
em.. i thought the gravity is always the same...i mean how fast an object falls down no matter how heavy it is..
so i think -9.81 is right^^
...i dont know how big a quant is @___@

but i think it should move 9.81 m per second, so you have just to calculate it right^^"


take a listen on my Portfolio Site
Re: Correct gravity and Mass ? [Re: Calined] #52999
08/22/05 17:12
08/22/05 17:12
Joined: Mar 2003
Posts: 5,377
USofA
fastlane69 Offline
Senior Expert
fastlane69  Offline
Senior Expert

Joined: Mar 2003
Posts: 5,377
USofA
You are making a classic mistake. REal physics do not corrolate to game physics. You will have to tweak the games gravity and mass so that things look and act like you want them to. In other words, don't focus on making your game gravity 9.8 m/s/s; rather tweak it in gamestudio until it looks and acts like you want it.

Also, remember to make ample use of the "time" variable to take variances in timeslices into account.

Re: Correct gravity and Mass ? [Re: fastlane69] #53000
08/23/05 03:38
08/23/05 03:38
Joined: Jul 2001
Posts: 1,269
Hopewell Jct, NY
Yulor Offline
Senior Developer
Yulor  Offline
Senior Developer

Joined: Jul 2001
Posts: 1,269
Hopewell Jct, NY
What fastlane says is true, the one quant = one inch is just given to you to give people an answer to the question, it does not need to be an inch, if I told you it was one foot it would not make -386 quants/^2 any different. In short the size of a quant does not matter.

However if you were wondering -9.81 m/s^2 is the acceleration due to gravity, which is a constant near the surface of the earth.. (calculation by Gm/r^2)

Re: Correct gravity and Mass ? [Re: Yulor] #53001
08/23/05 04:29
08/23/05 04:29
Joined: Sep 2004
Posts: 260
UB,Mongolia
Olzii Offline OP
Member
Olzii  Offline OP
Member

Joined: Sep 2004
Posts: 260
UB,Mongolia
If fastlane said true , it is very hard to make real car simulation.

I think that it must have some relationships between Gravity->Mass->Torque.

It is very difficult to set everything by random choosing & observing.

How can i make real simulation for over 30 different cars ?


The Empire of the Mongols comprised the largest continuous land empire ever, reaching from Korea to Poland
Re: Correct gravity and Mass ? [Re: Olzii] #53002
08/23/05 04:35
08/23/05 04:35
Joined: Mar 2003
Posts: 5,377
USofA
fastlane69 Offline
Senior Expert
fastlane69  Offline
Senior Expert

Joined: Mar 2003
Posts: 5,377
USofA
Same way you make a good level: with good ratios.

Pick a car with certain gravity and mass stats....tweak it till it looks good...now use this car as the benchmark and modify each car accordingly.

Example: Ford mass = 1000 kg Chevy mass = 2000 kg.

There is a 2 to 1 ratio in chevy to ford mass.

Now you tweak everything and find that in 3DGS, a Ford moves juuuussssstttt the way you want it, but you had to set ford.mass=25764;. Now, what is the chevy mass? Since it's a 2-1 ratio, mulitply that by 2 and set chevy.mass=51528.

This will give you the correct scale just about every time. If it doesn't, then you can perturb around these first order values to find the correct "feel" to your motion.

(PS: Even if what I said was untrue, a "real" car simulation is still a very hard thing to do )

Re: Correct gravity and Mass ? [Re: fastlane69] #53003
08/23/05 04:45
08/23/05 04:45
Joined: Sep 2004
Posts: 260
UB,Mongolia
Olzii Offline OP
Member
Olzii  Offline OP
Member

Joined: Sep 2004
Posts: 260
UB,Mongolia
I think it is very hard. Even Marco did not make good car simulation in his car tutorial. His car has VERY BAD BRAKING /not like as cars in other games/.

For example, GTA's car has very good acceleration, realistic braking and hand braking.

Did somebody make some expirements on a6 car configuration ?

Is it possible to make cars like GTA using a6 physics ?


The Empire of the Mongols comprised the largest continuous land empire ever, reaching from Korea to Poland
Re: Correct gravity and Mass ? [Re: Olzii] #53004
08/23/05 07:05
08/23/05 07:05
Joined: Jan 2004
Posts: 3,023
The Netherlands
Helghast Offline
Expert
Helghast  Offline
Expert

Joined: Jan 2004
Posts: 3,023
The Netherlands
yes, you ARE able to make gta cars... thing is, i did it EXACTLY the way fastlane told you to, take the time, and tweak...
you think GTA was made in a week?? you really gotta sit down in front of it and take the time, this is how i got around doing good cars in A6PE.
Now also, you should see where you hinge the wheels, this can cause problems as well, if you make your wheels too low on your car, it feels like it bounces everywhere, make your wheels too low poly and it hops up and down when moving.

all sort of small tricks that you gotta look out for, now... what i did, take a look in the manual, and looked up every physics keyword. then read what they do, and think how any other car game would have that

like for instance, wheel bounciness, it is 100% rubber, but if you fill that in, it wont bounce at all, now you think further, a wheel has air, hey, cool that's about 40% of air, that leaves us 60% of rubber... hhmm... air bounces, rubber doesnt *filled in a car wheel *, because the rubber overrules in quantity here, make a small value for bounciness.. here comes the tweaking... you allready know you dont need a high value, so you start at maybe 15, then look if it bounces realistic enough for your feeling, keep adding/substracting numbers untill it feels good.
this was a small example on how you should think about these kinda things.
i know it takes up a lot of time, but in the end.. it's worth it

hope it was of some kinda use.

regards and good luck,


Formerly known as dennis_fantasy
Portfolio - http://www.designorhea.com/
Project - http://randomchance.cherrygames.org/
Re: Correct gravity and Mass ? [Re: Helghast] #53005
08/23/05 07:50
08/23/05 07:50
Joined: Sep 2004
Posts: 260
UB,Mongolia
Olzii Offline OP
Member
Olzii  Offline OP
Member

Joined: Sep 2004
Posts: 260
UB,Mongolia
Hi Dennis,

Please show me your results. I want to see good a6 physics car.

Please show me your demo or just EXE.


The Empire of the Mongols comprised the largest continuous land empire ever, reaching from Korea to Poland
Re: Correct gravity and Mass ? [Re: fastlane69] #53006
08/23/05 21:00
08/23/05 21:00
Joined: Jul 2000
Posts: 8,973
Bay Area
Doug Offline
Senior Expert
Doug  Offline
Senior Expert

Joined: Jul 2000
Posts: 8,973
Bay Area
Quote:

...a "real" car simulation is still a very hard thing to do )




Having wasted a lot of time in a previous job trying to make a “real” car simulation, I can agree with this 100% (and GTA cars are fun but very unrealistic ).

If you are shooting for the niche market that wants ultra-real car simulations, I can suggest some books. But I will warn you that it isn't at all easy. Even the most realistic simulations fake it in some areas. You can spend months researching how the rubber on the tires react to different forces and still not have enough data to simulate a weekend drive.


Conitec's Free Resources:
User Magazine || Docs and Tutorials || WIKI
Page 1 of 2 1 2

Moderated by  HeelX, Spirit 

Gamestudio download | chip programmers | Zorro platform | shop | Data Protection Policy

oP group Germany GmbH | Birkenstr. 25-27 | 63549 Ronneburg / Germany | info (at) opgroup.de

Powered by UBB.threads™ PHP Forum Software 7.7.1