📃How to Install

This page will give you a brief overlook on how to install this resource

Make sure to follow all steps, step by step, if you encounter errors please recheck that you've completed step 1-3 correctly.

Step 1

  • Remove LegacyFuel or any other Fuel Script you used prior

  • Insert VT-Fuel into your server

  • Remember to Ensure VT-Fuel in your server.cfg

Step 2

  • Run the resource before all resources in server.cfg

# These resources will start by default.
ensure mapmanager
ensure chat
ensure spawnmanager
ensure sessionmanager
ensure basic-gamemode
ensure hardcap
ensure baseevents

# QBCore & Extra stuff
ensure qb-core
ensure vt-fuel

Step 3

  • Open your Entire server in Visual Studio Code

  • Now do a folder search for LegacyFuel (Or any other fuel script you used prior)

  • Now Replace it with vt-fuel

An example

exports['LegacyFuel']:SetFuel(veh, vehicle.fuel)

You do it this way

exports['vt-fuel']:SetFuel(veh, vehicle.fuel

Step 4 (Optional)

This is not working properly yet but will be added in the next update!

  • Head over to your qb-core folder inside your resources

  • Here headover to the shared folder and find items.lua

  • Paste following code whereever you like within the QBCore.Shared table

--#vt-fuel Jerrycan
["jerrycan"]				 	 = {["name"] = "jerrycan", 						["label"] = "Jerry Can", 				["weight"] = 15000, 	["type"] = "item", 		["image"] = "jerrycan.png", 			["unique"] = true, 		["useable"] = true, 	["shouldClose"] = true,   ["combinable"] = nil,   ["description"] = "Petrol can to fill your car"},

Step 5 (Optional)

  • Find your inventory in case of qb-inventory

  • Open up folder html/js and find app.js

  • This can be done in lj/ps/qb or whatever you use in this case

} else if (itemData.name == "harness") {
 } else if (itemData.name == "jerrycan") {
            $(".item-info-title").html("<p>" + itemData.label + "</p>");
            $(".item-info-description").html(
                "<p>" + "Petrol can to fill your car <br><br>" + itemData.info.gasamount + " Liters Inside.</p>" +
                "</span></p><p style=\"padding-top: .8vh;font-size:11px\"><b>Weight: </b>" + ((itemData.weight * itemData.amount) / 1000).toFixed(1) + " | <b>Amount: </b> " + itemData.amount
            );
        } else if (itemData.name == "harness") {

Step 6 (Optional)

  • You only need to do this if you want to do the /giveitem command or put the item in qb-shops NOT NECESSARILY.

  • Find your inventory in case of qb-inventory

  • Open up folder server and find mail.lua

  • Find

elseif itemData["name"] == "harness" then
			   info.uses = 20
  • Replace it with this

elseif itemData["name"] == "harness" then
					info.uses = 20
elseif itemData["name"] == "jerrycan" then
					info.gasamount = 0

Special thanks to Law♆#4585 for the jerrycan help, he also used some new ps inspired animations in the code. I am grateful to him for helping me and canceling me in fixing some problems and improvements with the resource because I didn't have enough time!

Last updated