Power Plant
DEPENDECIES :
"es_extended" or "qb-core" can also be any framework you use
"ox_lib"
INSTALLATION :
Download dependencies and make sure they are properly installed
Download nteam_electricity from your keymaster , extract it to the resource folder and ensure inside server.cfg after all the dependencies.
We prepared items for install ( for ox_inventory ) inside INSTALL folder ( with prepared images for items )
Configure the script to your liking
Restart server and enjoy our script.
CONFIG :
maxEnergy = Maximum amount of city energy
energyDrainRate = Energy depletion rate per player
energyGainRate = "auto" Energy gained per active generator ( change to any number you want or set it to auto )
shutdownInterval = Default: 1 hour in milliseconds ( time when 1 random generator will fail ) ( DONT CHANGE THIS IF YOU DONT KNOW WHAT YOU ARE DOING )
Config.Zones = You can add as many zones you want with all data you have in examples ( There are gta5 map devided to 4 zones, you can edit it to as many as you want, with same parameters like in examples from config file)
Config.Generators = We prepared 4 generators but you can add as many as you want on any location you want
GeneratorFailChance = change that 1 of generators will fail after Config.shutdownInterval ( if you dont want generators to fail randomly set it to 0)
GeneratorFuelConsumption = how much fuel will each generation consumpt every 5 minutes
Camera = If you want to disable camera changing when doing animation set it to false ( cinematic is still on if you disable camera )
ControlRoom = location where laptop will be spawned to see generators status
Reward = 0 -- If you want to use reward system when mechanic or your specific job reparis some part of generator just change it from 0 to any other number you want reward type is in cash or you can change function inside server-editable.lua
Last updated