
Documentation
Learn how the script works, explore its main features, and discover how to configure and use everything with ease.
Machine Settings | Name, prop, payment account, and a template button that fills the product list from |
For sale | Lets a player buy and manage the machine. Sets the price |
Can be robbed | Allows break-ins on this machine |
Placement | Puts you in placement mode |
Products | Item, display label and price for each slot |
Blip / Access Control | Optional map blip and job restrictions |
Press Select to enter placement mode:
Control | Action |
|---|---|
Aim | Move the machine |
Mouse wheel / | Rotate |
Left click | Place |
Backspace | Cancel |
If a placement is ever left running, opening the creator again cancels it automatically.
A machine flagged For sale shows a prompt to any nearby player:
[E] - Buy machine ($price)The buyer becomes its owner and gains a management panel where they can restock from their own inventory, change prices, collect earnings and sell the machine back.
Every sale pays the owner Config.Ownable.ownerShare% of the price. The rest is removed from the economy as tax.
Config.Ownable = {
enabled = true,
purchaseAccount = 'bank', -- account charged when buying a machine
payoutAccount = 'bank', -- account credited when collecting earnings
ownerShare = 80, -- % of each sale the owner keeps
maxStockPerItem = 200,
defaultPrice = 5000,
resaleRatio = 0.5, -- refund when selling back, 0 disables it
}Owned machines hold real stock — the owner pays for what they put in, which is what makes them worth robbing.
Machines flagged Can be robbed show a prompt to anyone carrying Config.Robbery.item:
[G] - Force machineThe thief forces the lock (progress bar) and then solves an ox_lib skill check.
Machine | Loot |
|---|---|
Owned | Steals part of the stock the owner paid for — and the owner is notified |
Unowned | Has no real stock, so it hands out a few units of its own product list |
Config.Robbery = {
enabled = true,
item = 'lockpick', -- no item, no prompt
key = 47, -- G
useItem = false, -- also start it by using the item itself
allowSelfRobbery = false, -- testing only: rob your own machine
duration = 6, -- seconds forcing the lock
skillCheck = { difficulty = { 'easy', 'medium', 'medium' }, inputs = { 'w', 'a', 's', 'd' } },
breakChance = 15, -- % the lockpick breaks after succeeding
breakChanceFail = 50, -- ...and after failing
stealPercent = 50, -- % of each stocked product taken
maxPerItem = 10,
unownedLoot = { min = 1, max = 4 },
cooldown = 1800, -- seconds locked after a successful robbery
cooldownFailed = 60, -- ...after a failed attempt
alert = { enabled = true, chance = 70, jobs = { 'police', 'sheriff' }, blipTime = 60 },
}Leave
useItem = falseif another resource already registers your lockpick as a usable item — vehicle lockpicking scripts usually do, and the last one to register it wins.
The alert lives in custom/server.lua (AlertPolice), outside escrow, so you can replace it with your own dispatch system.
Everything under these paths is outside escrow and safe to edit:
Path | What it holds |
|---|---|
| All settings |
| 40 languages — missing keys fall back to English |
| Framework bridge (money, items, jobs) |
| Inventory bridge and image paths |
| Notifications and the |
| Discord webhooks |
Config.Debug = falseEnable it to get detailed output in the F8 console. Turn it off in production.