# Installation

<figure><img src="https://2134242036-files.gitbook.io/~/files/v0/b/gitbook-x-prod.appspot.com/o/spaces%2F9QbcpHOPz9QGhghryntp%2Fuploads%2Fxx6sdVXVPL35GnLFSQBy%2Fmazeheist.png?alt=media&#x26;token=89ce0042-918e-449d-abf6-72eaeda45217" alt=""><figcaption></figcaption></figure>

## Dependencies :

<details>

<summary>ES EXTENDED</summary>

You will need the latest version of [esx\_core](https://github.com/esx-framework/esx_core).

* Extract the contents of the archive to your resources folder.
* Start the resource near the top of your resources in your server.cfg.

</details>

<details>

<summary>INTERACT OR TARGET</summary>

You will need the latest version of [Interact](https://github.com/darktrovx/interact) or [qb-target](https://github.com/qbcore-framework/qb-target)

* Extract the contents of the archive to your resources folder.
* Start the resource near the top of your resources in your server.cfg.

</details>

<details>

<summary>XSOUND</summary>

You will need the latest version of [xsound](https://github.com/Xogy/xsound)

* Extract the contents of the archive to your resources folder.
* Start the resource near the top of your resources in your server.cfg.

</details>

<details>

<summary>INTERACT-SOUND</summary>

You will need the latest version of [interact-sound](https://github.com/plunkettscott/interact-sound).

* Extract the contents of the archive to your resources folder.
* Start the resource near the top of your resources in your server.cfg.

</details>

<details>

<summary>POLYZONE</summary>

You will need the latest version of [Polyzone](https://github.com/mkafrin/PolyZone).

* Extract the contents of the archive to your resources folder.
* Start the resource near the top of your resources in your server.cfg.

</details>

<details>

<summary>MKA-LASERS</summary>

You will need the latest version of [mka-lasers](https://github.com/mkafrin/mka-lasers).

* Extract the contents of the archive to your resources folder.
* Start the resource near the top of your resources in your server.cfg.

</details>

***

## Inventories :

<details>

<summary>QB INVENTORY</summary>

Add the items below to the qb-core/shared/items.lua:&#x20;

```lua
    -- maze heist
    rccar                   = { name = 'rccar',                         label = 'ESP Rc Car',                               weight = 100,       type = 'item',      image = 'rccar.png',                                                unique = true, useable = true,     shouldClose = true,    combinable = nil,   description = 'ESP RC CAR' },    
    rccontroller            = { name = 'rccontroller',                  label = 'ESP Rc Car Controller',                    weight = 100,       type = 'item',      image = 'rccontroller.png',                                         unique = true, useable = true,     shouldClose = true,    combinable = nil,   description = 'ESP Rc Car Controller' },    
    rfid_cloner             = { name = 'rfid_cloner',                  label = 'RFID Cloner',                            weight = 100,       type = 'item',      image = 'rfid_cloner.png',                                          unique = true, useable = true,     shouldClose = true,    combinable = nil,   description = 'RFID Cloner' },    
    painting1               = { name = 'painting1',                    label = 'Mark Ashkenazi Painting',                weight = 100,       type = 'item',      image = 'painting1.png',                                          unique = true, useable = true,     shouldClose = true,    combinable = nil,   description = 'Mark Ashkenazi Painting' },    
    painting2               = { name = 'painting2',                    label = 'Jean Delvin Painting',                   weight = 100,       type = 'item',      image = 'painting2.png',                                          unique = true, useable = true,     shouldClose = true,    combinable = nil,   description = 'Jean Delvin Painting' },   
```

Add this into your qb-inventory js file:&#x20;

```javascript
        case "rfid_cloner":
            if (itemData.info.uses == undefined) {
                return `<p>Uses: 5</p>`;  
            }else{
                return `<p>Uses: ${itemData.info.uses}</p>`;  
            }
```

</details>

<details>

<summary>QS INVENTORY</summary>

Add the items below into your qs-inventory/shared/items.lua

```lua
   ['rccar']                  = {
        ['name'] = 'rccar',
        ['label'] = 'RC Car',
        ['weight'] = 0,
        ['type'] = 'item',
        ['image'] = 'rccar.png',
        ['unique'] = true,
        ['useable'] = true,
        ['shouldClose'] = true,
        ['combinable'] = nil,
        ['description'] = 'RC Car...'
    },
    ['rccontroller']                  = {
        ['name'] = 'rccontroller',
        ['label'] = 'RC Controller',
        ['weight'] = 0,
        ['type'] = 'item',
        ['image'] = 'rccar.png',
        ['unique'] = true,
        ['useable'] = true,
        ['shouldClose'] = true,
        ['combinable'] = nil,
        ['description'] = 'RC Controller...'
    },
   ['rfid_cloner']                  = {
        ['name'] = 'rfid_cloner',
        ['label'] = 'RFID cloner',
        ['weight'] = 0,
        ['type'] = 'item',
        ['image'] = 'rfid_cloner.png',
        ['unique'] = true,
        ['useable'] = true,
        ['shouldClose'] = true,
        ['combinable'] = nil,
        ['description'] = 'RFID cloner...'
    },
      ['painting1']                  = {
        ['name'] = 'painting1',
        ['label'] = 'Mark Ashkenazi Painting',
        ['weight'] = 0,
        ['type'] = 'item',
        ['image'] = 'painting1.png',
        ['unique'] = true,
        ['useable'] = true,
        ['shouldClose'] = true,
        ['combinable'] = nil,
        ['description'] = 'Mark Ashkenazi Painting'
    },
      ['painting2']                  = {
        ['name'] = 'painting2',
        ['label'] = 'Jean Delvin Painting',
        ['weight'] = 0,
        ['type'] = 'item',
        ['image'] = 'painting2.png',
        ['unique'] = true,
        ['useable'] = true,
        ['shouldClose'] = true,
        ['combinable'] = nil,
        ['description'] = 'Jean Delvin Painting'
    },
```

Add this into qs-inventory/server/custom/misc/CreateUseableItem.lua

```lua
CreateUsableItem('rccar', function(source, item)
    local src = source
    TriggerClientEvent("zat-mazebankheist:client:UseRCCar", src)
end)

CreateUsableItem('rccontroller', function(source, item)
    local src = source
    TriggerClientEvent("zat-mazebankheist:client:UseRCController", src)
end)
```

Add this into qs-inventory/config/metadata.js

```javascript
} else if (itemData.name == "rfid_cloner") {
            $(".item-info-title").html("<p>" + `${itemData.info.label || label}` + "</p>");
            $(".item-info-description").html("<p>Uses: " + itemData.info.uses + "</p>");
```

</details>

<details>

<summary>OX INVENTORY</summary>

Add the items below into your ox-inventory/data/items.lua

```lua
	["rccar"] = {
		label = "RC Car",
		weight = 100,
		stack = false,
		close = true,
		description = "RC Car",
		client = {
			image = "rccar.png",
		}
	},
	["rccontroller"] = {
		label = "RC Controller",
		weight = 100,
		stack = false,
		close = true,
		description = "RC Controller",
		client = {
			image = "rccontroller.png",
		}
	},
	["rfid_cloner"] = {
		label = "RFID Cloner",
		weight = 100,
		stack = false,
		close = true,
		description = "RFID Cloner",
		client = {
			image = "rfid_cloner.png",
		}
	},

	["painting2"] = {
		label = "Jean Delvin Painting",
		weight = 100,
		stack = false,
		close = true,
		description = "Jean Delvin Painting",
		client = {
			image = "painting2.png",
		}
	},

	["painting1"] = {
		label = "Mark Ashkenazi Painting",
		weight = 100,
		stack = false,
		close = true,
		description = "Mark Ashkenazi Painting",
		client = {
			image = "painting1.png",
		}
	},
```

Add this into ox\_inventory/modules/items/client.lua

```lua
Item('rccar', function(data, slot)
    ox_inventory:useItem(data, function(data)
        if data then
            TriggerEvent("zat-mazebankheist:client:UseRCCar", src)
        end
    end)
end)

Item('rccontroller', function(data, slot)
    ox_inventory:useItem(data, function(data)
        if data then
            TriggerEvent("zat-mazebankheist:client:UseRCController")
        end
    end)
end)
```

</details>

***

## Dialog :

<details>

<summary>ZAT DIALOG</summary>

Add the code below to zat-dialog/shared/config.lua

```lua
        -- mazebank
        {
            ped         = 'a_m_m_ktown_01',
            anim        = 'CODE_HUMAN_MEDIC_TIME_OF_DEATH',
            coords      =  vector4(-1254.59, -671.23, 24.99, 304.43),
            job         = "all", -- { ["police"] = 0, ["ambulance"] = 0}  if you are using target
            gang        = "all", -- { ["ballas"] = 2, ["thelostmc"] = 0}  if you are using target
            groups      = "all", -- { ["police"] = 2, ["ambulance"] = 0}  if you are using intearaction
            firstname   = 'BARK',
            lastname    = 'MOORE',
            rep         = 0,
            mission     = 'mazebank',
            text        = 'Hey there, always on the lookout for a side gig, huh? I have got this idea that is a bit out there, but trust me, it pays off. Imagine sneaking with your group into the maze bank and grap every single cent in there?',
            buttons     = {
                {
                    text= 'I want to work',
                    rep = 0,
                    answer ='Ready for a day of hard work?',
                    buttons={{
                            text = 'yes',
                            shop =false,
                            rep = 0,
                            action= {
                                isServer= false,
                                event= 'zat-mazebankheist:client:StartWorking',
                                data= {}
                            },
                            canInteract = CanToggleSignIn(),
                        },
                        {
                            text = 'Leave Conversation',
                            shop =false,
                            rep = 0,
                            action= {
                                isServer= false,
                                event= 'zat-dialog:client:HideUi',
                                data= {}
                            },
                            canInteract = true
                        }
                    },
                    canInteract = true
                },
                {
                    text = 'Abandon Mission',
                    rep = 0,
                    shop =false,
                    action= {
                        isServer= false,
                        event= 'zat-mazebankheist:client:StopWorking',
                        data= {}
                    },
                    canInteract = true
                },
                {
                    text = 'Join/Create Group',
                    rep = 0,
                    shop =false,
                    action= {
                        isServer= false,
                        event= 'zat-groups:client:OpenUi',
                        data= {}
                    },
                    canInteract = true
                },
                {
                    text    = 'Open Shop',
                    rep = 0,
                    shop    = true,
                    answer  = null,
                    canInteract = true
                },
            },
            items={
                {
                    name   = 'rfid_cloner',
                    label  = 'RFID Cloner',
                    image  = 'nui://'..Config.Img..'rfid_cloner.png',
                    type   = 'Equipement',
                    price  = 1000,
                    rep    = 0,
                    amount = 0, -- keep it 0
                    info   = {},
                    canInteract = true
                },     
                {
                    name   = 'rccar',
                    label  = 'RC CAR',
                    image  = 'nui://'..Config.Img..'rccar.png',
                    type   = 'Equipement',
                    price  = 9520,
                    rep    = 0,
                    amount = 0, -- keep it 0
                    info   = {},
                    canInteract = true
                }, 
                {
                    name   = 'rccontroller',
                    label  = 'RC CAR CONTROLLER',
                    image  = 'nui://'..Config.Img..'rccontroller.png',
                    type   = 'Equipement',
                    price  = 530,
                    rep    = 0,
                    amount = 0, -- keep it 0
                    info   = {},
                    canInteract = true
                },    
            }
        }, 
```

</details>

## Doorlock:

<details>

<summary>QB DOORLOCK</summary>

copy <mark style="color:green;">mazebank.lua</mark> doorlock file and paste it in qb-doorlock/configs

</details>

<details>

<summary>OX DOORLOCK</summary>

Just import the <mark style="color:green;">ox\_doorlock.sql</mark> into your Database.

</details>

## ENSURE RESOURCES

* [ ] ensure zat-ui
* [ ] ensure zat-groups
* [ ] ensure zat-minigames
* [ ] ensure zat-minigames\_2
* [ ] ensure zat-minigames\_3
* [ ] ensure xsound
* [ ] ensure interact-sound
* [ ] ensure zat-mazebank


---

# 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://zat-scripts.gitbook.io/zat-scripts/esx/maze-bank-heist/installation.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.
