Configuration
Config = {}
Config.Main = {
AntiSpam = 1000, -- 1000ms, 0 = off
AntiSpamMessage = "You are doing that too fast!",
HotkeyKey = "vehicle:engine",
HotkeyLabel = "(Vehicle) Engine On / Off",
HotkeyInput = "N",
StateBag = "engine",
EnableCommand = true,
Command = "engine",
CommandNeedGroup = "user",
CommandHelp = "Turn on / off the engine of the vehicle",
EnableAdminCommand = true,
AdminCommand = "engineadmin",
AdminCommandNeedGroup = "admin",
AdminCommandHelp = "Turn on / off the engine of the vehicle for another player",
Client = {
NotifyFunction = function(message, time, type)
ESX.ShowNotification(message)
end,
HasFuel = function(vehicle)
-- With this function you can get the fuel of the vehicle.
-- return true will allow the player to start the engine.
-- return false will block the player from starting the engine.
return true
end,
HasKey = function(vehicle)
-- With this function you can check if the player has the key.
-- return true will allow the player to start the engine.
-- return false will block the player from starting the engine.
return true
end,
},
Server = {
NotifyFunction = function(source, message, time, type)
TriggerClientEvent('esx:showNotification', source, message)
end
},
Texts = {
EngineOff = "The engine has been ~r~stopped",
EngineOn = "The engine has been ~g~started",
NoFuel = "The vehicle has no ~y~gasoline",
NoKey = "You don't have keys for this vehicle",
NotInVehicle = "You are not in a vehicle",
NoTarget = "Player not found",
AdminToggleSuccess = "The engine has been ~g~started",
},
}
Last updated