Configuration
Configuration guide of Fuel Script.
Fuel System Configuration Guide
This guide provides detailed instructions for configuring the STG
fuel system script for FiveM. The script allows players to refuel their vehicles at gas stations with various fuel types. Configuration options include selecting the framework, enabling a fuel consumption system, and customizing notifications.
1. Main Configuration
STG.Framework
Description: This setting determines which framework the script will utilize to function correctly. The options are
"esx"
for ESX framework,"qb"
for QBCore framework, or"auto"
, which automatically detects and uses the framework that is currently active on the server. Using"auto"
is convenient if your server might switch between frameworks or if you're unsure which one is being used.Example:
STG.useLegacyfuel
Description: This option controls whether the script should use a legacy fuel consumption system or the newer integrated system provided by the script. Setting this to
true
will revert to the older, perhaps more familiar fuel system, which might be useful if you have other scripts relying on it. Keeping itfalse
will ensure that the script uses its own optimized fuel management system.Example:
STG.Debugger
Description: This setting enables a debugging mode that provides additional output in the console, which can be very helpful during the development and testing phases. With
STG.Debugger
set totrue
, the script will log various activities and potential issues to help identify and fix problems. If you're setting up the script for the first time or making significant changes, it's recommended to keep this enabled. Once everything is working smoothly, you can set it tofalse
to reduce console clutter.Example:
2. Fuel Pricing and Settings
STG.Settings
fuelPrices: This section allows you to configure the prices for different types of fuel available at gas stations. The pricing can be adjusted based on the server's economy or to reflect real-world fuel prices, enhancing the roleplay experience. Each fuel type has a specific price per liter, and you can set them according to how valuable each type of fuel should be.
Example:
STG.Settings.currency
Description: This defines the currency symbol that will be displayed in the fuel purchase menu. It can be set to any symbol or abbreviation, such as
$
,€
,£
, etc., depending on your server's locale or the in-game economy you wish to simulate.Example:
STG.Settings.unit & STG.Settings.unit2
Description: These settings allow you to specify the unit of measurement for the fuel.
unit
is used for regular display (e.g., in notifications), whileunit2
can be used for emphasis or in specific areas of the UI where uppercase might be preferred. Commonly, this would be"Liter"
or"LITERS"
, but you can customize it based on the measurement system your server uses (e.g.,"Gallon"
for US servers).Example:
3. Locale Settings
STG.Settings.locales
Description: This section defines various text elements that will be displayed to the player in different parts of the fuel system UI. These can be customized to match the language or tone you want for your server. For instance, you can change the prompt that appears when players approach a fuel pump or the labels within the fuel menu.
Example:
Last updated