wasvendel_storesupply
wasvendel scripts
wasvendel_storesupply
wasvendel scripts
wasvendel_storesupply.wasvendel_storesupply folder into your server's resources directory.server.cfg after your framework core and inventory.Optional soft-link (register → faction treasury):
Tables are created automatically on first start. No manual SQL import is required.
| Table | Description |
|---|---|
wasvendel_storesupply_settings | Global settings and schema version. |
wasvendel_storesupply_catalog | Shared item catalog (prices, limits, categories). |
wasvendel_storesupply_stores | Store locations, NPC, stock, access, and register. |
Legacy wasvendel_ss_* tables are migrated automatically when detected.
Edit config.lua to configure admin groups, prompts, NPC presets, catalog import, logging, and placement controls.
Server-only secrets should be configured in sv_config.lua.
Notification texts can be edited in config_notifications.lua.
UI / prompt language strings are in lang.lua (Config.Locale: en | es | fr | ru | hu).
| Setting | Description |
|---|---|
Config.Locale | UI language (en, es, fr, ru, hu). |
Config.AdminGroups | Framework groups allowed to use /storeadmin. |
Config.SteamPermission | Optional Steam ID whitelist instead of groups. |
Config.Permissions | Optional ACE-based granular admin actions. |
Config.Prompt | Open / manage keys and distances. |
Config.Defaults | Default cash/gold, list mode, price multipliers, item limit, and hours. |
Config.CatalogImport | Auto-import items from VORP items table or RSG Shared.Items on startup. |
Config.Boss | Soft-link to wasvendel_boss faction treasuries. |
Config.Logging | Discord log toggles (webhook URL is in sv_config.lua). |
| Command | Usage | Description |
|---|---|---|
/storeadmin | /storeadmin | Opens the central admin tablet (stores, catalog, globals). |
Admin command access is controlled by Config.AdminGroups in config.lua.
Example groups: admin, superadmin, god.
Set Config.SteamPermission.enabled = true and list Steam identifiers in adminSteamIds. When enabled, group checks are replaced by the Steam list.
Players must still be admin (Config.AdminGroups or Steam whitelist). Then set Config.Permissions.useAce = true and add ACE rules in server.cfg:
Granular actions (instead of .admin):
ACE action names: create, edit, delete, manage_items, manage_hours, manage_lists, manage_limits, view_logs, place_npc.
Per-store restock / manage access is configured in the admin UI or manage panel (jobs, character IDs, and in-game access entries with restock / withdraw / register / manage flags).
wasvendel_boss faction treasury.All server exports listed below are safe to call from other resources.
| Export | Signature | Description |
|---|---|---|
GetStore | (id) -> table | nil | Returns the in-memory store data for the given store ID. |
GetStock | (id, item) -> number | Returns the current stock amount for an item in a store. |
Reload | () | Reloads globals, catalog, and stores from the database and syncs clients. |
| Parameter | Description |
|---|---|
id | Store ID (integer from the database). |
item | Item name (catalog key). |
| Event | Payload | Description |
|---|---|---|
wasvendel_storesupply:sync | payload | Syncs store list / world data to the client. |
wasvendel_storesupply:openShopUI | data | Opens the customer shop UI. |
wasvendel_storesupply:openRestockUI | data | Opens the restock UI. |
wasvendel_storesupply:openManageUI | data | Opens the store manage UI. |
wasvendel_storesupply:openAdmin | payload | Opens the admin tablet. |
wasvendel_storesupply:adminData | payload | Refreshes admin tablet data. |
wasvendel_storesupply:adminDenied | None | Closes admin UI when permission is denied. |
wasvendel_storesupply:closeShop | None | Closes the shop UI. |
wasvendel_storesupply:resetShop | None | Resets / cancels an open shop session. |
wasvendel_storesupply:manageAccess | map | Sends which stores the player can manage. |
wasvendel_storesupply:notify | msg, ms, ntype | Shows a framework notification. |
wasvendel_storesupply:styledNotify | msg, ms, styleDef | Shows a styled notification. |
wasvendel_storesupply:centerTip | msg, ms | Shows a center tip. |
| Event | Description |
|---|---|
wasvendel_storesupply:requestSync | Requests a store sync for the player. |
wasvendel_storesupply:requestAdmin | Requests admin tablet data. |
wasvendel_storesupply:saveGlobals | Saves global settings. |
wasvendel_storesupply:saveCatalogItem | Creates or updates a catalog item. |
wasvendel_storesupply:deleteCatalogItem | Deletes a catalog item. |
wasvendel_storesupply:saveStore | Creates or updates a store. |
wasvendel_storesupply:deleteStore | Deletes a store. |
wasvendel_storesupply:openShop | Opens a shop session for the player. |
wasvendel_storesupply:purchase | Handles a shop purchase. |
wasvendel_storesupply:releaseSession | Releases the player's shop session. |
wasvendel_storesupply:requestManageAccess | Requests the player's manage-access map. |
wasvendel_storesupply:openRestock | Opens restock for a store. |
wasvendel_storesupply:openManage | Opens manage for a store. |
wasvendel_storesupply:restock | Adds stock from the player's inventory. |
wasvendel_storesupply:withdrawStock | Withdraws stock to the player's inventory. |
wasvendel_storesupply:registerWithdraw | Withdraws money from the store register. |
wasvendel_storesupply:setItemPrice | Sets an item price for a store. |
wasvendel_storesupply:setPurchaseTax | Sets the store purchase tax. |
wasvendel_storesupply:saveAccess | Saves a store access entry. |
wasvendel_storesupply:removeAccess | Removes a store access entry. |
Configure the webhook in sv_config.lua:
Toggle categories in config.lua → Config.Logging.categories:
| Category | Description |
|---|---|
manage | Restock, withdraw, price changes. |
purchases | Shop purchases. |
admin | Admin tablet actions. |
Leave the webhook empty to disable Discord logs.