How does speedometers / Fuel meters work?
#5

velocity is measured on a global x/y/z plane.

Imagine that the entire GTA-SA 3D worldspace was one large 3D grid.
Moving UP the grid (skyward) will increase your Z position, moving DOWN it will DECREASE your Z position.
Heading North via the minimap I'm pretty sure is +Y, South is -Y, east is +X, west is -X (please correct me if I am wrong.)

So Velocity is simply a value that indicates how many squares you move per player update (client) and in what direction.

GetPlayerVelocity will return 3 values, X, Y, Z.

if you are headed north along the road at 1 gridsquare per update, your velocity SHOULD be (again if I am right with my definition of relativity) X=0, Y=1, Z=0

Having two values as 1, say X=1 Y=1, Z=0 would indicate that you are heading North-East at a rate of 1 gridsquare per update.
Reply


Messages In This Thread
How does speedometers / Fuel meters work? - by Dokins - 11.12.2011, 16:20
Re: How does speedometers / Fuel meters work? - by THE_KNOWN - 11.12.2011, 16:25
Re: How does speedometers / Fuel meters work? - by Dokins - 11.12.2011, 17:16
Re: How does speedometers / Fuel meters work? - by §с†¶e®РµРe - 12.12.2011, 09:04
Re: How does speedometers / Fuel meters work? - by Rob_Maate - 12.12.2011, 10:39
Re: How does speedometers / Fuel meters work? - by THE_KNOWN - 12.12.2011, 11:55

Forum Jump:


Users browsing this thread: 1 Guest(s)