> For the complete documentation index, see [llms.txt](https://l2s.gitbook.io/l2s-dev-documentations/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://l2s.gitbook.io/l2s-dev-documentations/qbcore/gangs-turf/installation.md).

# Installation

## Asset download

1\. Download your resource from FiveM's Keymaster.

2\. Unzip zip folder and place it into your resource folder.

3\. Add ensure l2s-gangsturf to your server start config. Make sure to place anywhere below the framework and dependencies resources.

## installation

1\. Put l2s-gangsturg inside resource.

2\. Start this script.

3\. Run SQL

4\. Customize Your setting in config.lua

5\. Add this item on qb-core/shared/items.lua || and add images in inventory \[its in this script]

```lua
["turfspray"] = {
    ["name"] = "turfspray",
    ["label"] = "Gang Spray",
    ["weight"] = 1000,
    ["type"] = "item",
    ["image"] = "spray.png",
    ["unique"] = true,
    ["useable"] = true,
    ["shouldClose"] = false,
    ["combinable"] = nil,
    ["description"] = "Gang Spray"
},
["spray_remover"] = {
    ["name"] = "spray_remover",
    ["label"] = "Spray Remover",
    ["weight"] = 1000,
    ["type"] = "item",
    ["image"] = "spray_remover.png",
    ["unique"] = true,
    ["useable"] = true,
    ["shouldClose"] = false,
    ["combinable"] = nil,
    ["description"] = "Gang Spray"
},
```

## Some Useful Exports :

### Client :

```lua
exports['l2s-gangsturf']:PlayerInHisGang() --  To know if the player is now inside his gang territory or outside it  |  Return : true / false
exports['l2s-gangsturf']:CheckCoords(x, y) -- To know if this raduis to any gang from coords  | Return : gang name
```

### server :

```lua
exports['l2s-gangsturf']:PlayerInHisGang(PlayerId) -- To know if the player is now inside his gang territory or outside it  |  Return : true / false
exports['l2s-gangsturf']:AddGangLevel(gang, amount) -- To Add Gang level
exports['l2s-gangsturf']:RemoveGangLevel(gang, amount) -- To Remove Gang level
exports['l2s-gangsturf']:GetGangLevel(gang) -- To Know gang level / Return: Level amount
```
