# stands

Lightweight, stable **player-owned street stands**. Players can **buy a stand**, **stock it with their items**, and **sell to others** via a clean NUI.

Data persists to a JSON file (no SQL).

## Features

* **ESX** (tested on ESX 1.12+).
* World props: each stand is a placed `prop_hotdogstand_01` with heading.
* Buy / sell stands (prices configurable).
* Add items to stand stock, set **price** and **quantity**.
* Players purchase items from the **Shop** tab.
* Owner can **withdraw** earned cash.
* **Blacklist** + optional **weapon blocking**.
* Interaction via **ox\_target**.
* JSON persistence: `standovi/standovi.json`.
* EN & HR locales, notify bridge (`okokNotify` or ESX).

## Requirements

* `es_extended`
* `ox_inventory`
* `ox_target` (or compatible target wrapper)
* (Optional) `okokNotify`

## Installation

{% stepper %}
{% step %}

### Put the resource in resources/

Place the folder named `standovi` inside your `resources/` directory.
{% endstep %}

{% step %}

### Ensure dependencies are started

Make sure required resources (`es_extended`, `ox_inventory`, `ox_target`, etc.) are started.
{% endstep %}

{% step %}

### Add to server.cfg

Add the following line to your `server.cfg`:

```cfg
ensure standovi
```

{% endstep %}

{% step %}

### Configure

Edit `standovi/config.lua` — see the configuration documentation for available options.
{% endstep %}

{% step %}

### Restart

Restart your server.
{% endstep %}
{% endstepper %}

## Quick Start

{% stepper %}
{% step %}

### Open a stand

Approach any stand and interact (Open Stand).
{% endstep %}

{% step %}

### Purchase an unowned stand

If unowned, purchase it (requires enough cash).
{% endstep %}

{% step %}

### Manage your stand

As owner, open Manage → add items from inventory, set **price** and **qty**.
{% endstep %}

{% step %}

### Shop

Anyone can buy from the Shop tab.
{% endstep %}

{% step %}

### Withdraw or sell

Owner can withdraw accumulated cash or sell the stand back to the city.
{% endstep %}
{% endstepper %}

## Persistence

State is saved in `standovi/standovi.json` (owners, stock, balances).

{% hint style="warning" %}
Back up `standovi/standovi.json` periodically.
{% endhint %}

## Performance

Very low client CPU usage (prop + small target zone).

## Support

* Configurable through `config.lua` and `locale.lua`.
* UI files are editable in `html/`.
