Configuration

Every group in config.lua, plus the customer menu, supplier catalog, and recipes.

Configuration lives in three files: config/config.lua for everything structural, config/items.lua for the customer menu and supplier catalog, and config/recipes.lua for what each station consumes and produces. Edit, save, restart the resource.

Framework and dependencies

OptionDefaultDescription
Config.Framework'auto''auto', 'qb', 'qbx', or 'esx'. Force it if detection picks the wrong one.
Config.Banking'auto'Auto order is Renewed-Banking, qb-banking, qb-management, esx_addonaccount. Force with any of those or 'bablo-banking'.
Config.Target'auto'Picks ox_target if started, otherwise qb-target.
Config.WaveShieldfalseSet true if you run WaveShield or any anti-cheat that blocks os.*.
Config.Locale'en'Language file in locales/.
Config.DebugfalsePrints debug lines and draws the target boxes. Turn it on while placing coords.

Job and permissions

OptionDefaultDescription
Config.JobName'burgershot'The job every employee check uses.
Config.SocietyAccount'burgershot'The account name your banking resource knows.
Config.Permissions.manager2Grade at or above this sees the Stats tab and can void orders.
Config.Permissions.owner3Grade at or above this gets Roster and Funds.
Config.JobDefinitionnilOverride the auto-registered job. Leave nil for the built-in Trainee, Crew, Manager, Owner grades.

Stash

OptionDefaultDescription
Config.StashId'burgershot_stash'ox_inventory stash id.
Config.StashLabel'BurgerShot Kitchen'Label shown on the stash.
Config.StashSlots60Slot count.
Config.StashWeight500000Weight in grams, so 500 kg.
Config.StartingStash30 of each ingredientSeeded on boot when stock is low, so the kitchen is never empty on a fresh start.

Stations

Config.Stations defines the 5 cooking stations. Each entry takes:

FieldDescription
coords and sizeThe target box.
target.label and target.iconWhat the player sees on the prompt.
recipeThe key in Config.Recipes this station makes.
durationMsHow long the cook animation and timing bar run.
emoteScenario played while cooking.
soundSound effect, or false for silence.
qualityfalse skips the mini-game for that station and always produces a normal result.

Out of the box: fries (7s), cook_meat (12s), burger (4s, no mini-game), drink (3s, no mini-game), murder_meal (5s).

Cooking quality mini-game

Config.Quality drives the timing bar. When a cook clicks a station with quality enabled, a bar fills over durationMs and they press Config.Quality.StopKey to stop it. Where they stopped, as a fraction of the duration, maps to a zone.

ZoneWindowTip multiplierXP bonusResult
Raw0 to 30%00Item destroyed, ingredients wasted
Undercooked30 to 60%0.5x0Item produced
Cooked60 to 75%1.0x0Item produced
PERFECT75 to 85%1.3x15Item produced
Overcooked85 to 95%0.8x0Item produced
BURNT95 to 100%00Item destroyed, ingredients wasted

Config.Quality.StopKey defaults to 22, which is SPACE. Use 38 for E. Set Config.Quality.Enabled = false to turn the mini-game off entirely.

The two failure zones are what give the mini-game teeth. If your players find it punishing, widen the Cooked window rather than deleting the fail zones. A mini-game with no downside is just an extra keypress.

XP and levels

Config.XP.Grants sets where XP comes from. Set any to 0 to disable that source.

GrantDefaultWhen
cookFinish5Per successful cook
servedLine8Per item served
orderPaid25Per fully paid order, to the assigned cook
tipBonus2Per $1 of tip received
tipBonusMax30Cap on the tip bonus per order

Config.XP.Levels is the cumulative XP needed for each level, plus the title shown in the tablet header: Trainee, Line Cook, Grill Master, Shift Lead, Veteran, Star Cook, Head Chef, Master Chef, Iron Chef, Legendary, at 0, 100, 300, 600, 1000, 1500, 2500, 4000, 6000, and 10000 XP.

Payment and tips

OptionDefaultDescription
Config.PaymentMethodscash and bank both trueTurn either off to force the other.
Config.MaxTipPercent0.50Hard server-side cap, so a modified UI cannot send a 9999% tip.
Config.TipPresetsPct{ 0, 10, 15, 20 }Preset buttons. A custom amount is always available.

The customer is charged subtotal + tip. The society receives the subtotal, the assigned cook receives 100% of the tip, whether they are online or not.

Order lifecycle and cook claims

OptionDefaultDescription
Config.AutoVoidAfterMs10 minCounter orders left unpaid this long auto-void.
Config.OrderTickIntervalMs60sHow often the lifecycle watcher runs.
Config.MaxClaimsPerCook5Stops one cook hoarding the whole queue.
Config.AutoReleaseAfterMs5 minA claimed order with no station progress returns to the New queue.
Config.ClaimWatcherMs30sHow often the auto-release watcher runs.

Anti-abuse

OptionDefaultDescription
Config.MaxStationDist3.0Metres. A cook request from further than this is rejected.
Config.MaxCounterDist3.5The same check for serve and pay requests.
Config.CookCooldownMs500Minimum gap between cook starts per player.
Config.ServeCooldownMs1500Minimum gap between serve calls.
Config.AutoClockOutMs15 minIdle employees are forced off duty. 0 disables it.
Config.AutoClockOutWarningMs60sWarning sent this long before the auto clock-out.

The idle auto clock-out exists because clocking in and going AFK is the most common way restaurant jobs get farmed. Leave it on unless your server pays no hourly wage at all.

Discord

Set Config.Webhook to a webhook URL to log every order, void, payment, and supply purchase. Leave it empty to disable logging.

Notifications

Config.Notify(src, message, type) is a plain Lua function at the bottom of the config. It calls ox_lib:notify by default. Rewrite the body to route notifications through your own resource instead, every notification in the script goes through it.

config/items.lua holds two catalogs.

Config.Menu is what customers can order, with the price charged per unit. It ships with Fries $8, Cola $6, Hamburger $25, and Murder Meal $60. Config.MenuOrder controls display order. Note that cooked_meat is deliberately not on the menu, it is an intermediate the kitchen makes on the way to a hamburger.

Config.SupplierStock is the raw ingredient catalog employees buy from, paid out of society funds: Potato $1, Raw Meat $2, Burger Bun $2, Cheese $2, Tomato $1, Lettuce $1. Config.MaxSupplierQtyPerBuy caps a single purchase at 50 units so society drains stay visible in the audit log.

config/recipes.lua maps each recipe to its inputs and output. Inputs are consumed atomically, server-side, and only after the server has verified the cook actually holds them.

RecipeInputsOutput
fries1 potato1 fries
cooked_meat1 raw_meat1 cooked_meat
hamburgerbun, cooked_meat, cheese, tomato, lettuce1 hamburger
colanone, the fountain is free1 cola
murder_mealhamburger, cola, fries1 murder_meal

Adding your own product means three edits here: a row in Config.Menu, a recipe in Config.Recipes, and a station in Config.Stations pointing at that recipe. Plus the ox_inventory item itself and its icon.