gta6/prompts
economy
Vaultadvancedeconomy

Dynamic Economy — Supply & Demand Pricing

QBCore server-wide pricing engine that floats shop buy/sell prices on recent trade volume, with baseline drift to fight inflation.

NON-TESTÉ — the reference Lua is syntax-validated, not run in a live FiveM server. Adapt and test on your own dev server before shipping.
Est. Lua
~100 loc
Claude
Claude Opus 4.x / Sonnet 4.x
Validation
syntax-validated
Updated
2026-06-25

Description

A server-wide pricing engine that floats every shop's buy and sell price on recent trade volume: heavy buying lifts a good's price, heavy selling sinks it, and idle items drift back toward baseline. Servers sell it because it turns a static, inflation-prone economy into a living market that rewards scarcity and self-corrects over time.

Prompt Template

You are writing a FiveM resource for qb-core.

🔒 Eyes-only — locked prompt body

The full prompt template and its reference Lua are part of a one-time pack. Pick your depth — both are lifetime access, no subscription, ever.

Core$49one-time
  • 60 prompts + syntax-validated reference Lua
  • Lifetime access — pay once
Most Popular · Best Value
Vault$199one-time
  • All 510 prompts — the full library
  • Per-prompt profit/trend intelligence (CSV + playbook)
  • Lifetime free updates — new niches as the market moves
Get the Vault — $199

$49 for 60 · $199 for all 510 + intelligence — one-time, no subscription.

Expected Output

The reference Lua at content/expected-outputs/economy/17-dynamic-supply-demand-pricing.lua implements a server-side catalog with per-item multipliers that buy/sell events nudge within clamped bands,…

🔒 Eyes-only — locked prompt body

The full prompt template and its reference Lua are part of a one-time pack. Pick your depth — both are lifetime access, no subscription, ever.

Core$49one-time
  • 60 prompts + syntax-validated reference Lua
  • Lifetime access — pay once
Most Popular · Best Value
Vault$199one-time
  • All 510 prompts — the full library
  • Per-prompt profit/trend intelligence (CSV + playbook)
  • Lifetime free updates — new niches as the market moves
Get the Vault — $199

$49 for 60 · $199 for all 510 + intelligence — one-time, no subscription.

Known Failure Modes & Corrective Prompt

  • Client-side pricing — a cheater buys at a stale price; compute priceOf on the server only.
  • Unclamped multiplier — prices spiral; clamp with math.min(CEIL, ...) / math.max(FLOOR, ...).
  • Single-target update — other clients desync; broadcast with TriggerClientEvent("pricing:update", -1, ...).

Corrective re-prompt: "Move all price computation to the server, clamp the multiplier between FLOOR and CEIL on every change, and broadcast each new price to -1 so all clients stay in sync."

Framework Integration

ESX: swap to ESX.GetPlayerFromId, xPlayer.getMoney(), removeMoney/addMoney, and xPlayer.addInventoryItem. QBCore: as written — QBCore.Functions.GetPlayer, RemoveMoney/AddMoney, AddItem/RemoveItem. QBox: use exports.qbx_core:GetPlayer and the ox_inventory exports for item add/remove while keeping the same money calls.

Profit Potential

$250–$3500/mo on Tebex (expected ~$900). [INFERRED] priced in the $50-389 script band against the signal-scraper tebex_snapshot corpus (median seller $11.85K/mo, n=100), scaled to a rising-niche unit estimate.

Trend Signal

rising — inferred: Few polished supply/demand engines exist on Tebex; reasoned demand from owners fighting runaway economy inflation.

Sales Angle

The anti-inflation backbone for serious economy servers — a living market rather than fixed price lists. Recommended Tebex price: $329.

Difficulty & Ship Time

advanced · ships in 1 day.