gta6/prompts
crafting
Vaultintermediatecrafting

Equipment Durability & Repair Benches

Generic-framework item-durability system: tools drain a server-owned durability metadata bar with use and are restored by a repair kit or a distance-gated repair bench.

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
~90 loc
Claude
Claude Opus 4.x / Sonnet 4.x
Validation
syntax-validated
Updated
2026-06-25

Description

An item-durability system for roleplay servers where every tool carries a durability bar in its inventory metadata, drains with use, and is restored either by consuming a repair kit or at a material-gated repair bench. Servers buy it because it adds a recurring maintenance sink at the item level, distinct from the common vehicle-repair scripts.

Prompt Template

You are writing a FiveM resource for a generic roleplay framework accessed via…

🔒 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/crafting/22-equipment-durability-repair.lua implements client use/repair requests and server getDura/setDura helpers that clamp 0..100, drain on use,…

🔒 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-stored durability — durability on the client is trivially spoofed; keep it in server-owned slot metadata.
  • Unclamped metadata — without a 0..100 clamp a tool can wrap to a negative or absurd value.
  • Free bench repair — a bench with no server proximity or material check lets any client repair from anywhere for nothing.

Corrective re-prompt: "Store durability only in server-owned slot metadata, clamped 0..100 in setDura; the client only requests useTool, repairKit and repairBench. Consume a repair_kit (kit) or materials (bench) on the server before restoring, and broadcast the new value back to the owner."

Framework Integration

ESX: swap to exports['es_extended']:getSharedObject() and store durability in the item's metadata via xPlayer inventory helpers. QBCore: use exports['qb-core']:GetCoreObject() with Player.Functions.SetItemData(slot, 'info', info) to hold the durability field. QBox: durability is native — read/write the durability metadata directly through ox_inventory exports.ox_inventory:SetDurability / GetSlot.

Profit Potential

$250–$3200/mo on Tebex (expected ~$850). [INFERRED] priced inside the $50-389 standalone-script band against the signal-scraper corpus (tebex_snapshot n=100, median seller $11.85K/mo) for a rising item-durability niche.

Trend Signal

rising — corpus: signal-scraper corpus: ox_inventory durability metadata is native; repair-bench/kit loops are a recurring tebex_topsellers seller (item-level, not vehicle repair).

Sales Angle

Differentiate from vehicle-repair scripts: this is per-item durability that adds a maintenance sink to every tool in the economy. Recommended Tebex price: $79.

Difficulty & Ship Time

intermediate · ships in 4-6h.