Description
A bank loan mechanic for roleplay servers: a player applies, the server disburses principal to bank, then auto-collects fixed installments with flat interest on a timer and flags missed payments as defaults. Servers sell it because installment debt with default tracking is the financing backbone housing, vehicle and business scripts lean on.
Prompt Template
You are writing a FiveM resource for qb-core (port notes below).
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.
- 60 prompts + syntax-validated reference Lua
- Lifetime access — pay once
- All 510 prompts — the full library
- Per-prompt profit/trend intelligence (CSV + playbook)
- Lifetime free updates — new niches as the market moves
$49 for 60 · $199 for all 510 + intelligence — one-time, no subscription.
Expected Output
The reference Lua at content/expected-outputs/economy/14-bank-loan-installment-interest.lua disburses principal, schedules fixed installments with flat interest, and re-resolves each borrower by…
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.
- 60 prompts + syntax-validated reference Lua
- Lifetime access — pay once
- All 510 prompts — the full library
- Per-prompt profit/trend intelligence (CSV + playbook)
- Lifetime free updates — new niches as the market moves
$49 for 60 · $199 for all 510 + intelligence — one-time, no subscription.
Known Failure Modes & Corrective Prompt
- Client-side interest — letting the client compute the bill understates debt. Keep
total,installmentand collection on the server. - Double loans — no active-loan guard stacks free principal. Reject
loan:applywhenloans[cid]exists. - Stale-src default — holding a src across ticks errors or mis-defaults on disconnect. Re-resolve by
GetPlayerByCitizenIdeach cycle.
Corrective re-prompt: "Guard loan:apply to reject when loans[cid] is already set, compute total = floor(amount*(1+INTEREST)) and installment = floor(total/TERMS) server-side, and in the collector GetPlayerByCitizenId(cid) each cycle before paying or incrementing defaults."
Framework Integration
ESX: getSharedObject(), getAccount('bank').money, addAccountMoney/removeAccountMoney, loans keyed by identifier.
QBCore: as written — GetPlayer, GetPlayerByCitizenId, AddMoney/RemoveMoney, loans by citizenid.
QBox: exports.qbx_core:GetPlayer(src) with the shared money functions; identifiers map 1:1.
Profit Potential
$150–$2000/mo on Tebex (expected ~$500). [INFERRED] Priced inside the $50-389 script band against the signal-scraper corpus (tebex_snapshot n=100, median seller $11.85K/mo); a stable evergreen financing niche.
Trend Signal
→ stable — corpus: Loan scripts are an established economy category the scraper tracks (tebex_topsellers cat:economy); evergreen steady demand.
Sales Angle
Sell it as economy infrastructure — the financing layer housing and vehicle scripts plug into, not a standalone toy. Recommended Tebex price: $129.
Difficulty & Ship Time
intermediate · ships in 2-4h.