> For the complete documentation index, see [llms.txt](https://sbscripts.gitbook.io/sb-scripts/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://sbscripts.gitbook.io/sb-scripts/sb-jobs/registers.md).

# Registers

Each register has its own position and its own list of items. You can have one register for drinks and another for food.

```lua
registers = {
    {
        id     = 'reg1',
        label  = 'Register 1',
        coords = vector3(0.0, 0.0, 0.0),
        items  = { 'bs_bigmeal', 'bs_fizz_small', 'bs_softserve' },
    },
},
```

* `id` must be unique within the job.
* The names in `items` are inventory item names. The same names are used as keys in the price list.

### Working a register

1. Go to a register, target it or press the interact key in key mode.
2. Click items to build the order.
3. Set a discount if you want to give one.
4. Pick cash or card.
5. Charge the customer. The nearest player within `Config.ChargeRadius` gets the payment prompt.
6. When they accept, the money goes to the business balance and they receive a receipt. If they decline, you're told.

A register won't sell an item the business has no stock of.

Prices, stock and discounts are all checked on the server, so an edited client can't buy cheap food.
