gta6/prompts
ui
Vaultbeginnerui

Compass Heading Strip HUD

A native-draw top-screen compass strip showing cardinal direction, heading degrees and the current street name, with correct counter-clockwise heading conversion.

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

Description

A top-screen compass strip drawn with native DrawText / DrawRect: it shows the cardinal direction (N/NE/E…), the heading in degrees and the current street name. It is a staple of every roleplay HUD pack — low differentiation, but reliable baseline demand as a clean standalone or pack component.

Prompt Template

You are writing a FiveM CLIENT compass HUD. No framework money/state is involved,…

🔒 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/14-compass-heading-hud.lua.

🔒 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

  • Raw heading as bearingGetEntityHeading is counter-clockwise; N/S and E/W flip without the (360 - heading) % 360 conversion.
  • Draw outside the loopDrawText/DrawRect must run every frame.
  • Off-by-one cardinal — the +22.5 offset must wrap with % 360 before the /45 bucket so 350° rounds to N, not NW.

Corrective re-prompt: "The compass shows E when I face west — convert the heading with compass = (360.0 - GetEntityHeading(ped)) % 360.0 before bucketing, and confirm the +22.5/%360 offset so 350 degrees reads N."

Framework Integration

  • ESX: no money/state needed; drop into an existing ESX HUD resource as an extra client_script and toggle it off the same HUD settings event.
  • QBCore: pair with LocalPlayer.state HUD-visibility flags so it hides when the QBCore HUD is toggled.
  • QBox: identical client-only code; wire visibility to your qbx HUD toggle.

Profit Potential

$120–$1700/mo on Tebex (expected ~$450). [INFERRED] priced in the $50-389 script band against the signal-scraper tebex_snapshot corpus (n=100, median seller $11.85K/mo); low differentiation pins it to the band floor.

Trend Signal

stable — inferred: compass strips ship in nearly every roleplay HUD pack; steady baseline demand, low differentiation.

Sales Angle

Position as a clean, standalone compass that drops into any HUD pack with zero dependencies. Recommended Tebex price $59.

Difficulty & Ship Time

beginner · ships in 2-4h.