SetVehicleOilLevel

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

See also: GetVehicleOilLevel

Sets the oil level of the vehicle

The oil level is displayed at the dashboard.

2.50f = Full
2.49f = Empty

Syntax

In C#
Server-Side Function

void API.setVehicleOilLevel(NetHandle vehicle, float oilLevel);

Required Arguments

  • vehicle: parameter input should be in NetHandle type.
  • oilLevel: parameter input should be in float type.

In Javascript
Client-Side Function

void API.setVehicleOilLevel(LocalHandle vehicle, float oilLevel);

Required Arguments

  • vehicle: parameter input should be in LocalHandle type.
  • oilLevel: parameter input should be in float type.

Usage example(s)

API.setVehicleOilLevel(LocalHandle vehicle, float oilLevel);


References