Skip to content

πŸͺ Store ​

VORP RSG TPZZoo Store

πŸ›’ Buy on zoo-scripts.com

General stores and gunsmiths for VORP, RSG and TPZ, and stores that players own, stock and price themselves.

Install ​

  1. Put the zoo_store folder in resources/[zoo]/.

  2. Open config/config.lua and set Config.Framework to 'vorp', 'rsg' or 'tpz'.

  3. Add this line to server.cfg after your framework (its core and its inventory) and oxmysql:

    ini
    ensure zoo_store
  4. Do not run the framework's own stores at the same counters (vorp_stores, rsg-shops, tpz_stores). They put shopkeepers, blips and prompts in the same places.

  5. RSG and TPZ only. zoo_store writes its items into your framework's item file, so server.cfg must allow it (anywhere before the server finishes starting). Add the line for your framework:

    ini
    add_filesystem_permission zoo_store write rsg-core
    ini
    add_filesystem_permission zoo_store write tpz_inventory
  6. Start the server. On the first start zoo_store makes its database tables and adds its items (the three permits and the tax ledger) where your framework keeps items. The inventory reads its items only when it starts, so restart the server once more before giving them out. The console says so when it added any.

  7. Copy the pictures in img/items/ (permit_general.png, permit_gunsmith.png, permit_trading.png, tax_ledger.png) into your inventory's picture folder: vorp_inventory/html/img/items/, rsg-inventory/html/images/ or tpz_inventory/html/img/items/.

Creating stores ​

There are three kinds of store.

The server's own stores ​

They are written in the stores file of your framework: config/shops_vorp.lua, config/shops_rsg.lua or config/shops_tpz.lua. To add one, copy a store in that file and change:

  • id: a unique name
  • name
  • type: general or gunsmith
  • coords: where players open it
  • npc: its shopkeeper and map icon
  • goods

Restart zoo_store after editing.

A player's store, with a permit ​

  1. Give the player a permit: permit_general (general store), permit_gunsmith (gunsmith) or permit_trading (trading post, sells everything).
  2. The player uses the permit from the inventory. A ring appears on the ground in front of them.
  3. They walk the ring to the spot and press Enter to place the store (X cancels).
  4. They name the store, and may give their own Discord webhook to get its messages.
  5. The store is theirs: hold G at it to open it, stock it, price it and run it.

A character may own Config.MaxPerCharacter stores (1 out of the box).

A store for sale, placed by an admin ​

  1. An admin types zoostore_sale in game. A ring appears on the ground in front of them.
  2. They walk the ring to the spot and press Enter to place it.
  3. They pick its type (general store, gunsmith, trading post), its price, and its tax in percent (empty: the tax of every store).
  4. It shows on the map as "Store for sale", with its price over its prompt.
  5. A player holds G at it, reads its type, price and tax, names it (and may give a Discord webhook) and buys it with cash. It is then their store, like any other.

An admin who holds G at a store for sale also sees Take off sale, which removes it (a second click confirms).

Who is an admin ​

An admin is a player whose group in the framework is one of Config.AdminGroups in config/config.lua (admin and god out of the box). On VORP that is the account's or the character's group, on RSG a permission rank, and on TPZ the player's group.

Zoo Scripts. Commercial resources, redistribution or resale is not permitted.