gta6/prompts
ui
Vaultintermediateui

First-Spawn Location Selector

A framework-agnostic on-join NUI list of spawn points with an orbiting preview camera and a server-validated teleport into the chosen location.

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

Description

A first-spawn location selector that opens on join, lists configured spawn points in an NUI panel, and orbits a preview camera over each one before committing. The chosen spawn id is validated server-side against a whitelist, then the server tells the client where to teleport — so players can't inject arbitrary coordinates. It slots in front of any multichar/apartment flow as the polished entry point.

Prompt Template

You are writing a FiveM resource: an on-join spawn-location selector via NUI.

🔒 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 lives at content/expected-outputs/ui/19-spawn-location-selector.lua. It drives an orbiting preview camera per spawn, sends only the chosen id to the server, and teleports the ped…

🔒 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-supplied coords — accept only a spawn id and resolve coordinates from the server whitelist.
  • Stuck camera — always RenderScriptCams(false,...) and DestroyCam on approval.
  • Fall-through spawn — fade in only after teleport so collision can stream under the ped.

Corrective re-prompt: "Send only the spawn id to the server; the server looks it up in a VALID whitelist and returns coords+heading via spawnsel:approved, rejecting unknown ids to a default. On the client, tear down the preview cam (RenderScriptCams(false,...) + DestroyCam) and DoScreenFadeIn only after SetEntityCoords so the world streams in first."

Framework Integration

  • ESX: Trigger after esx:playerLoaded instead of onClientMapStart, and pass the player's last apartment as a dynamic spawn.
  • QBCore: Call it from qb-multicharacter after character select; resolve job-based spawns server-side via QBCore.Functions.GetPlayer.
  • QBox: Use exports.qbx_core:GetPlayer(src) in the choose handler to gate certain spawns to specific jobs/gangs.

Profit Potential

$150–$2000/mo on Tebex (expected ~$500). [INFERRED] priced within the $50-389 script band against the signal-scraper tebex_snapshot corpus (n=100, median seller $11.85K/mo) for a stable RP niche.

Trend Signal

stable — inferred: Spawn selectors pair with apartment/multichar systems; consistent demand across RP frameworks.

Sales Angle

Position as the cinematic on-join moment that upsells alongside a multichar or housing system — the orbiting preview is the demo-video hook. Recommended Tebex price $139.

Difficulty & Ship Time

intermediate · ships in 1 day.