# 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\
  \
  **UPDATES:**\
  \&#xNAN;***1.0.4***\ <sub>Added export to fetch in which zone is player client side export GetCurrentElectricityZone,</sub>\
  `exports['nteam_electricity']:GetCurrentElectricityZone()`


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://nteamdev.gitbook.io/nteam-development/power-plant.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
