Skip to content

Items

Create and manage items directly in vorp_inventory's database.

Item form

FieldWhat it is
NameInternal identifier (lowercase, no spaces). What other resources use. Immutable.
LabelWhat players see.
WeightPer-unit weight.
LimitMax stack size per inventory.
Typeitem_standard, item_weapon, etc.
Can removePlayers can drop it.
UsablePlayers can use it from the inventory.
ConsumableIf on, one is removed per use. If off, the item triggers an action without disappearing (lockpicks, notepads).
ImageDrag-and-drop a PNG. Saved to vorp_inventory/html/img/items/.

After saving new items, restart vorp_inventory so it reloads its cache. The panel shows a banner each time this is needed.

Usable effects

If the item is usable, you can stack one or more effects. Each one has its own sub-form:

EffectNotes
Hunger / Thirst / StressDelta value (positive or negative). Routed through your HUD via OnUsableHunger / OnUsableThirst / OnUsableStress.
Player core (health / stamina)Delta. Routed via OnUsablePlayerCore.
Horse coreSame idea, for the player's current mount, via OnUsableHorseCore.
AnimationDictionary + name + duration. Plays while the item is being used.
Drunk gaitDuration + strength. The player wobbles.
Camera shakeIntensity + duration.
Screen FXA built-in postFX preset or a named preset from Config.UsablePresets.

All effects fire together when the item is consumed.

Non-consumable items

Items marked Usable but not Consumable trigger the OnUsableItemTrigger hook on the client with the item name, the stack id, and the item data. Wire this in modules/editable/client.lua to react (open a UI, start a mini-game, send a radio message, etc.).

Catalog images

The panel comes with a built-in image library (common item icons). If you don't have your own PNG, pick one from the catalog.

Deletion

Removing an item deletes its row in vorp_inventory.items AND its usable config in lo_item_usables. Existing copies in player inventories become unusable on the next inventory open; restart vorp_inventory to clean them out.

Released under a commercial license. Documentation released under MIT.