Raised This Month: $32 Target: $400
 8% 

Solved What is the unit of sv_gravity?


Post New Thread Reply   
 
Thread Tools Display Modes
Natsheh
Veteran Member
Join Date: Sep 2012
Old 07-05-2019 , 09:16   Re: What is the unit of sv_gravity?
Reply With Quote #11

I think there is 2 type of meters in game, 1 game unit = 0.0254 FakeMeter = 0.0122625 RealMeter


FakeMeter is the meters that got extracted from player length I suppose. Player length should be 72 units = 1.8288 FakeMeters

RealMeter depending on the meters in the reality extracted from game default gravity 800 / 9.8 earth gravity.

Now we need just to transfer from real meters to game meters.

I think problem is solved.
__________________
@Jailbreak Main Mod v2.7.0 100%
@User Tag Prefix 100% done !
@Mystery Box 100% done !
@VIP System 100% done !


Last edited by Natsheh; 07-05-2019 at 09:19.
Natsheh is offline
Send a message via MSN to Natsheh Send a message via Skype™ to Natsheh
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 07-05-2019 , 16:22   Re: What is the unit of sv_gravity?
Reply With Quote #12

Quote:
Originally Posted by Natsheh View Post
I think there is 2 type of meters in game, 1 game unit = 0.0254 FakeMeter = 0.0122625 RealMeter


FakeMeter is the meters that got extracted from player length I suppose. Player length should be 72 units = 1.8288 FakeMeters

RealMeter depending on the meters in the reality extracted from game default gravity 800 / 9.8 earth gravity.

Now we need just to transfer from real meters to game meters.

I think problem is solved.
No. Everything you just said is wrong.

Gravity is NOT a unit of length, it is an acceleration which is length per time squared. Also, 0.0254 is the conversion factor go to from inches to meters. If 800 is considered "normal" gravity then 9.81/800 is the conversion factor to go from the sv_gravity value to acceleration in units of meters per second squared.

This thread so far makes no sense without context. Like I said before, the units for sv_gravity are mostly irrelevant. What are you trying to do?
__________________
fysiks is offline
Natsheh
Veteran Member
Join Date: Sep 2012
Old 07-07-2019 , 17:17   Re: What is the unit of sv_gravity?
Reply With Quote #13

Quote:
Originally Posted by fysiks View Post
No. Everything you just said is wrong.

Gravity is NOT a unit of length, it is an acceleration which is length per time squared. Also, 0.0254 is the conversion factor go to from inches to meters. If 800 is considered "normal" gravity then 9.81/800 is the conversion factor to go from the sv_gravity value to acceleration in units of meters per second squared.

This thread so far makes no sense without context. Like I said before, the units for sv_gravity are mostly irrelevant. What are you trying to do?

0.0254 is the factor to convert from units to meters
Which does make sense because, 72 units ( player tall in units ) x 0.0254 = 1.82 meters (human average tall length)

You are wrong if you divided Acceleration by Acceleration the seconds squared units gets cancelled out, which leave us only with Length units (800 units/s2 = 9.8m/s2) ==> 800÷9.8 units = 1 meter.


Also I never said gravity is length.
__________________
@Jailbreak Main Mod v2.7.0 100%
@User Tag Prefix 100% done !
@Mystery Box 100% done !
@VIP System 100% done !


Last edited by Natsheh; 07-07-2019 at 17:32.
Natsheh is offline
Send a message via MSN to Natsheh Send a message via Skype™ to Natsheh
CrazY.
Veteran Member
Join Date: May 2015
Location: SP, Brazil
Old 07-07-2019 , 21:41   Re: What is the unit of sv_gravity?
Reply With Quote #14

__________________









Last edited by CrazY.; 07-07-2019 at 21:42.
CrazY. is offline
fysiks
Veteran Member
Join Date: Sep 2007
Location: Flatland, USA
Old 07-08-2019 , 01:37   Re: What is the unit of sv_gravity?
Reply With Quote #15

Quote:
Originally Posted by Natsheh View Post
0.0254 is the factor to convert from units to meters
Which does make sense because, 72 units ( player tall in units ) x 0.0254 = 1.82 meters (human average tall length)
If that is true then that means that the base unit for length in the game is inches.

Quote:
Originally Posted by Natsheh View Post
You are wrong if you divided Acceleration by Acceleration the seconds squared units gets cancelled out, which leave us only with Length units (800 units/s2 = 9.8m/s2) ==> 800÷9.8 units = 1 meter.
No. If you divide acceleration by acceleration you get no units at all, you get a simple ratio (when you properly process the units of the input values; when you're dividing by earth gravity, you get what is considered the "g-force"). The 800 doesn't have units of "units/s^2".

If you assume that sv_gravity of 800 is normal earth gravity of 9.81 m/s^2 then the units for sv_gravity are (9.81 m/s^2)/800 which is 0.0122625 m/s^2 which is also 0.483 in/s^2 (also known as the conversion factor for sv_gravity to get real-world units).


Quote:
Originally Posted by Natsheh View Post
Also I never said gravity is length.
Well, from some of your posts, it seemed like that was what you assumed.
__________________

Last edited by fysiks; 07-08-2019 at 01:39.
fysiks is offline
klippy
AlliedModders Donor
Join Date: May 2013
Location: Serbia
Old 07-09-2019 , 09:03   Re: What is the unit of sv_gravity?
Reply With Quote #16

https://github.com/alliedmodders/hls...ed.c#L739-L741
The gravity cvar is cut in half in this equation, so you could consider default player gravity 400 which is close to the Earth gravity if you use your formula to convet units to meters.

Anyway, it doesn't matter at all because it's just a made-up in-game unit, and 800 is used just because it probably seemed the most natural for the gameplay, not because it relates to real-world gravity in some way.
__________________
klippy is offline
Reply



Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off

Forum Jump


All times are GMT -4. The time now is 08:11.


Powered by vBulletin®
Copyright ©2000 - 2024, vBulletin Solutions, Inc.
Theme made by Freecode