GetVehicleFuelLevel

From GT-MP
Jump to: navigation, search
GetVehicleFuelLevel
Shared Function
Utilities-terminal.png Server-Side System-users.png Client-Side
Csharp.png C# Javascript.png JavaScript


See also: SetVehicleFuelLevel


Returns the current fuel level of the vehicle.

Syntax

In C#
Server-Side Function

float API.getVehicleFuelLevel(NetHandle vehicle);

Required Arguments

  • vehicle: parameter input should be in NetHandle type.

In Javascript
Client-Side Function

float API.getVehicleFuelLevel(LocalHandle vehicle);

Required Arguments

  • vehicle: parameter input should be in LocalHandle type.


NOTE: This function returns data in float type.

Usage example(s)

API.getVehicleFuelLevel(LocalHandle vehicle);


References