Skip to content

Esegovic/esegovic_fuel_system

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

no-alt

FiveM Fuel System

Lua & React (Typescript)

license Discord

Usage

  • There is no exports for get and set fuel, you can get fuel calling this:
local vehicle = GetPlayersLastVehicle()
local fuel = Entity(vehicle).state.fuel or GetVehicleFuelLevel(vehicle)
  • If you want to set fuel for a car call this:
Entity(vehicle).state.fuel = fuelAmount

Requirements

Installation

Add items in ox_inventory\data\items.lua

['jerrycan_petrol'] = {
		label = 'Petrol Can',
		weight = 2500,
		stack = false,
		close = true,
		client = {
			export = 'esegovic_fuel_system.jerrycan_petrol'
		}
	},

	['jerrycan_diesel'] = {
		label = 'Diesel Can',
		weight = 2500,
		stack = false,
		close = true,
		client = {
			export = 'esegovic_fuel_system.jerrycan_diesel'
		}
	}

Download the latest releases and put them in your resources folder.

Additional Notes

This script is based on:

Need further support? Join our Discord!