Advertisement
Guest User

Untitled

a guest
Apr 16th, 2019
77
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 0.35 KB | None | 0 0
  1. stock Float:GetVehicleSpeedFromVelocity(Float:x, Float:y, Float:z)
  2. {
  3.     return floatmul(VectorSize(x, y, z), (type == EI_MATH_SPEED_KMPH
  4.         ? 180.0
  5.         : 111.846814));
  6. }
  7.  
  8. stock Float:GetVehicleSpeed(vehicleid)
  9. {
  10.     static
  11.         Float:x,
  12.         Float:y,
  13.         Float:z
  14.     ;
  15.  
  16.     GetVehicleVelocity(vehicleid, x, y, z);
  17.  
  18.     return GetVehicleSpeedFromVelocity(x, y, z);
  19. }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement