3D GPS Route Renderer for FiveM - Prototype

gps3d

Prototype 3D GPS Route Renderer for FiveM (1.4)

Hi everyone,

I’m sharing a small prototype I built for FiveM: a 3D GPS route renderer.

The idea is simple: it reads the active GTA route, samples positions along it using GetPosAlongGpsTypeRoute, and renders a lightweight 3D ribbon trail with directional chevrons above the road.

It’s still a prototype / visual experiment, but it is already functional and may be useful as a base for other routing or navigation ideas.

:eyes: The idea of the script is to shift the focal point from the bottom-left corner of the map to the center, giving the player better control and awareness of important nearby elements. :eyes:

Features

  • You have option to enable/disable 90% of features in client.script
  • Reads active in-game GPS routes without taking control of them
  • Supports both USER routes (manual waypoint) and MISSION routes (active blip routes)
  • Samples route positions using GTA/FiveM natives
  • Draws a 3D ribbon trail above the road
  • Draws directional chevrons using textured route presets
  • Includes curve smoothing and junction handling controls
  • Supports optional junction filtering to reduce visual clutter
  • Uses ground probing and caching to keep the ribbon closer to the road
  • Uses speed-based route sampling and update timing for better performance at high speed
  • Includes near-car fade for a smoother visual start of the ribbon
  • Supports color switching for USER and MISSION route styles
  • Supports multiple texture presets for the 3D ribbon
  • Includes in-game shortcuts for route switching, color cycling, preset cycling, GPS toggle, and FX toggle
  • Includes bundled GPS activation/deactivation visual effects and sounds
  • Shows an in-world mode hint above the vehicle when switching GPS mode
  • Provides exports for enabling, disabling, changing route source, setting tracked blips, changing presets, and changing colors
  • Does not delete, refresh, or rebuild external routes from other scripts; it only reads routes that are already active

Non-Intrusive Route Behavior

l2k_gps3d does not take ownership of external route systems.

  • It only reads routes that are already available.
  • It does not create or control another script’s mission logic.
  • It does not clear external routed blips.
  • It does not refresh or rebuild another script’s GPS route.
  • Commands and shortcuts only affect the 3D ribbon, its style, colors, and bundled visual effects.

This means resources such as delivery, farming, mission, or postal scripts can keep their own route logic while l2k_gps3d only adds the 3D visual layer.

Commands

  • /gps3d — Toggle the 3D GPS on or off
  • /gps3d_route manual — Force USER mode
  • /gps3d_route blip — Force MISSION mode if a routed blip exists
  • /gps3d_route toggle — Switch between USER and MISSION
  • /gps3d_route status — Show current source, preset, and route state
  • /gpspreset index|next|prev|status — Change or inspect the current ribbon preset
  • /gpscolordefault r g b [a] — Set the USER route color
  • /gpscolormission r g b [a] — Set the MISSION route color

Geo Animation Commands (try create new ones)

  • /geoanim
  • /geoanim on
  • /geoanim off
  • /geoanim status

These control the bundled AR animation module manually when needed.

Shortcuts

All shortcuts require an allowed vehicle and can be disabled in the config.

  • SHIFT + UP — Switch between USER and MISSION if another route is available
  • SHIFT + Y — Cycle the color of the current route source
  • SHIFT + LEFT / RIGHT — Cycle the ribbon preset
  • SHIFT + DOWN — Toggle the 3D GPS with cooldown protection when re-enabling
  • SHIFT + U — Toggle extra geo animations used by GPS mode changes and reset the one-shot intro animation

Adding New Chevron Presets and Colors

  1. Add the new texture inside stream/chevrons.ytd - use openiv/codewalker explorer
  2. Add a new preset entry in client.lua

Example:

[11] = {
    name = 'chevron_line_03',
    textureDict = 'chevrons',
    textureName = 'chevron_line_03',
},

1. Change the index number 11+
1. Use Unique name
1. textureDict = ytd file name. dont need change here.
1. textureName = 'chevron_line_03',  the name of texture inside chevrons.ytd. dont use .dds

## routeColorPalette:

1. Add new preset Colors

        { name = 'BLACK', color = { r = 0 g = 0, b = 0, a = 205 } },

:fire: GitHub Download :fire:

GitHub Repository

Installation new 1.4

  1. Place l2k_gps3d in your resources folder
  2. Add ensure l2k_gps3d to your server.cfg
  3. Start the server
  4. Set a normal waypoint on the map/ or mission waypoint
  • Backup - we keep 1.2 as zip file if you want

Video update 1.4 better 50% performance

Notes

  • This is a visual prototype, not a replacement for the default minimap GPS
  • It uses the route already calculated by GTA/FiveM
  • It does not take ownership of external route logic

GAME DESIGN TIPS:

  • AR Processing Unit: I suggest server owners require a “virtual part” (like an Augmented Reality Processing Unit) to be installed in the vehicle. Players could buy this at mod shops or from specialized groups to keep the UI/UX immersive and part of the world.
  • Customization & Economy: Since this is a base framework, I didn’t force a specific interface. If you’re using the rect version, you can add new chevron shapes, different colors, and unique rendering formats.
  • Monetization: You can use these visual variations to create different tiers of GPS units with different price points, enriching the server’s economy and overall game design.

UPDATE

1.1 - ADD NEW RENDER: DRAW RECT + UVMAP (WITH PNG CHEVRON .ytd)

UPDATE LOG: 1.2

New

  • Added improved route persistence while staying on the current GPS path.
  • Added route trim logic for passed points.
  • Added route extend logic near the end of the visible path.
  • Added per-point ground check support during route calculation.
  • Improved off-route rebuild handling.
  • Added speed-aware route update tuning.
  • Added native Z debug helper for development/testing.

Visual

  • Improved overall route stability.
  • Reduced route jumping/moving while driving.
  • Improved curve and junction behavior.
  • Better control over what remains visible behind the vehicle.

Removed / Changed

  • Cleaned up internal structure for easier testing and future tuning.
UPDATE LOG: 1.4

PATCH NOTES

1.4.0

Core

  • Reworked the 3D GPS into a cleaner USER and MISSION flow.

  • USER follows the player’s waypoint.

  • MISSION follows an active routed blip from another script.

  • multi support stays disabled by default for a simpler and safer release path.

Visual

  • Ribbon rendering is now the default mode.

  • Added preset switching for different chevron ribbon looks.

  • Added independent USER and MISSION colors.

  • Added near-car ribbon fade for a cleaner visual finish.

  • Bundled AR-style geo animation profiles - TURN ON FIRST BOOT, TURN OFF/ON fast

Shortcuts

All shortcuts require an allowed vehicle and can be disabled in the config.

  • SHIFT + UP
    Switch between USER and MISSION.

  • SHIFT + Y
    Cycle the color of the current route source.

  • SHIFT + LEFT / RIGHT
    Cycle the ribbon preset.

  • SHIFT + DOWN
    Toggle the 3D GPS with cooldown protection when re-enabling.

  • SHIFT + K
    Toggle extra geo animations used by GPS mode changes. This also resets the one-shot intro animation so it can be shown again later.

Controls

  • Added shortcut-based route switching, color cycling, preset cycling and GPS toggling.

  • Added optional extra animation toggle with intro reset behavior.

  • Shortcuts only work inside allowed vehicle classes.

Performance

  • Added speed-based route sampling and speed-based route distance limits.

  • Reduced idle cost when the player is on foot or not in an allowed vehicle.

  • Ground probe cache cleanup was tightened to reduce unnecessary allocations.

Non-Intrusive Route Behavior

l2k_gps3d does not take ownership of external route systems.

  • It only reads routes that are already available.

  • It does not create or control another script’s mission logic.

  • It does not clear external routed blips.

  • It does not refresh or rebuild another script’s GPS route.

  • Commands and shortcuts only affect the 3D ribbon, its style, colors, and bundled visual effects.

This means resources such as delivery, farming, mission, or postal scripts can keep their own route logic while l2k_gps3d only adds the 3D visual layer.

LICENSE

  • This project is licensed under the MIT License.

Attribution

  • If you use this resource as a base for your own project, please provide visible credit to the original project and author. It would be greatly appreciated.

:gem_stone: Special thanks :gem_stone:

Killernight: for the route logic contribution used in this update 1.2

Code is accessible Yes
Subscription-based No
Lines (approximately) 500 start - 3000 now
Requirements None
Support No
32 Likes

Heyyy this is clean. Great for racing/driving servers!

1 Like

Forza Type Shiii! Love it!

1 Like

Simple and well done.

1 Like

Add a feature to clients (players) for that can change their color with a menu or with / without a color picker in game

1 Like

looks great! thanks for sharing the source! <3

1 Like

looks nice :mascot:

1 Like

Lafa2k aka the goat

1 Like

love the base script <3.
I adjusted the look of the waypoints to be a bit more moddern usinge fivem’s implemented marker system.
I still want to make some changes but greate base script <3

2 Likes

This is awesome. Can’t wait to see what you do to it.

2 Likes

“Exactly! That was the goal. I’m glad it’s serving as a good base for your improvements. Thanks for the support! <3”

Maybe share it ?

1 Like

Fantastic!

2 Likes

add new render. check update

1 Like


did some adjustments see dm for code please maybe you want that changed
what I did: calculating once and using that calculation to “show” them stable on the same spot so no “moving” or “jumping” on the floor
and a ground Z check when extending / generating the route to place the points as close to the ground as needed so its not as floaty through the car <3
love the idea and the work sofar
ground-probe off:

GroundProbe on:

did share some code with the author maybe he implements it <3

Nice , I will be making a UI where you can change the color , shape and share with others to make this more awesome :heart:

1 Like

nice I implemented that with your custom “settings” menu already but that script is not for the public so i cant share that.
but i guess this script could get awesome with some more stuff from different parts and maybe even a must have for most server?

1 Like

A sneak peak of your system would be cool :eyes:

1 Like


it is a dynamic settings menü wich allows you to register from a resource, and change settings, with preview drag and drop for different elements and and and.
but jea its in an “early” ish state ?

2 Likes