# Installation

## Dependencies

<details>

<summary>ES EXTENDED</summary>

You will need the latest version of [es\_extended](https://github.com/ESX-Official/es_extended).

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

</details>

### Installing the resource

* Make sure you have the [dependencies](#dependencies) listed above installed.
* Extract the contents of the archive to your resources folder.
* Ensure zat-washmoney on the server.cfg.
* If You are using For ox\_inventory :&#x20;
  * under ox\_inventory\modules\items\client.lua:&#x20;

```
Item('washmachine', function(data, slot)
	local model = "bkr_prop_prtmachine_dryer_op"
	local id = "WashMachine_"..math.random(111111,999999)
	TriggerEvent("zat-washmoney:client:PlaceTable", id, model)
end)
```

* If you are using qs-inventory :&#x20;
  * under qs-inventory/server/custom/misc/createuseableitems.lua :<br>

    ```lua
    CreateUsableItem('washmachine', function(source, item)
        local playerPed = GetPlayerPed(source)
        local playerCoords = GetEntityCoords(playerPed)
        local players = FrameworkGetPlayers()
        local model = "bkr_prop_prtmachine_dryer_op"
        local id = "WashMachine_"..math.random(111111,999999)
        TriggerClientEvent("zat-washmoney:client:PlaceTable", source, id, model)
    end)
    ```

* If You are using QS inventory :\
  Add this under qs-inventory/shared/items.lua :<br>

  ```lua
      ['washmachine']                  = {
          ['name'] = 'washmachine',
          ['label'] = 'Washmachine',
          ['weight'] = 0,
          ['type'] = 'item',
          ['image'] = 'Washmachine.png',
          ['unique'] = true,
          ['useable'] = true,
          ['shouldClose'] = false,
          ['combinable'] = nil,
          ['description'] = '...'
      },
      ['rollcash']                  = {
          ['name'] = 'rollcash',
          ['label'] = 'Rolled Money',
          ['weight'] = 0,
          ['type'] = 'item',
          ['image'] = 'rollcash.png',
          ['unique'] = true,
          ['useable'] = true,
          ['shouldClose'] = false,
          ['combinable'] = nil,
          ['description'] = '...'
      }, 
  ```

  * add this aswell under qs-invetory/server/custom/misc/CreateUseableItem.lua:<br>

    ```lua
    CreateUsableItem('washmachine', function(source, item)
        local playerPed = GetPlayerPed(source)
        local playerCoords = GetEntityCoords(playerPed)
        local players = FrameworkGetPlayers()
        local model = "bkr_prop_prtmachine_dryer_op"
        local id = "WashMachine_"..math.random(111111,999999)
        TriggerClientEvent("zat-washmoney:client:PlaceTable", source, id, model)
    end)
    ```
  * add this under qs-inventory/config/metadata.js: (line 280)

    ```javascript
    }else if (itemData.name == "rollcash") {
        $(".item-info-title").html("<p>" + `${itemData.info.label || label}` + "</p>");
        $(".item-info-description").html(
            "<p><strong>Worth: </strong><span>$" +
            itemData.info.worth +
            "</span></p>"
    );
    ```

* Add washmahine.sql into the database.


---

# 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/wash-money/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.
