Vice City: Multiplayer

Server Development => Scripting and Server Management => Topic started by: 2b2ttianxiu on Jul 19, 2023, 06:09 PM

Title: How can i calc really speed km/h of vehicle?
Post by: 2b2ttianxiu on Jul 19, 2023, 06:09 PM
How can i calc really speed km/h of vehicle?
i try 'sqrt(a.X * a.X + a.Y + a.Y * a.Z * a.Z) * x'
x: 180, 252, 200, 3.6, i couldnt find muiltply number.
Title: Re: How can i calc really speed km/h of vehicle?
Post by: habi on Jul 20, 2023, 01:25 AM
result=sqrt( pow( Vehicle.Speed.X, 2 ) + pow( Vehicle.Speed.Y, 2 ) + pow( Vehicle.Speed.Z, 2 ) )To convert m/s to km/h, result * 3.6