GetVehicleNitroLevel

From Multi Theft Auto: Wiki
Revision as of 16:14, 7 February 2013 by Kenix1 (talk | contribs) (Created page with "__NOTOC__ {{Client function}} {{New feature/item|4.0140|1.3.1|4993| This function get the nitro level from the vehicle. }} ==Syntax== <syntaxhighlight lang="lua">float getVehicleNitroLev...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigation Jump to search

ADDED/UPDATED IN VERSION 1.3.1 r4993:

This function get the nitro level from the vehicle.

Syntax

float getVehicleNitroLevel ( vehicle theVehicle )

Required Arguments

  • theVehicle The vehicle which you want to get a nitro level.

Returns

Returns the nitro level from the vehicle.

Example

addEventHandler( 'onClientVehicleEnter', root,
	function( pPlayer )
		if pPlayer == localPlayer then
			local fNitroLevel = getVehicleNitroLevel( source )
			setVehicleNitroLevel( source, fNitroLevel + 0.5 )
		end
	end
)

Requirements

This template will be deleted.

See Also