RLS Studios
ProjectsPatreonCommunityDocsAbout
Join Patreon
BeamNG Modding Docs

Guides

Reference

Server CommandsGE UtilitiesGame Engine MainNavigation GraphScreenshot CaptureServerServer ConnectionSpawnpoint ManagerSimulation TimeVehicle SpawningSuspension Frequency Tester
Bus DriverDamage GoalDemolition DerbyDistance GoalDrift GoalFinish Race GoalNo-Move GoalPosition GoalQuick RaceQuick Race LoaderRace MarkersRace DebugRace Goals ManagerRace UIScenario HelperScenario EngineScenarios LoaderSpeed GoalTime Limit GoalWaypoint ActionScenario Waypoints
Attention MarkerCrawl MarkerCylinder MarkerNone MarkerOverhead MarkerRing Marker - 3D Ring Checkpoint MarkerSide Column MarkerSide Hologram MarkerSide MarkerSingle Hologram Marker

UI

Resources

BeamNG Game Engine Lua Cheat SheetGE Developer RecipesMCP Server Setup

// RLS.STUDIOS=true

Premium Mods for BeamNG.drive. Career systems, custom vehicles, and immersive gameplay experiences.

Index

HomeProjectsPatreon

Socials

DiscordPatreon (RLS)Patreon (Vehicles)

© 2026 RLS Studios. All rights reserved.

Modding since 2024

API ReferenceGE ExtensionsscenarioraceMarkers

Overhead Marker

A race checkpoint marker that displays a single floating arrow shape above the waypoint position. The arrow faces the camera, bobs up and down, and color-lerps between modes.

A race checkpoint marker that displays a single floating arrow shape above the waypoint position. The arrow faces the camera, bobs up and down, and color-lerps between modes.


Class API (OOP via metatable)

MethodSignatureDescription
C:init(id)Initializes state: position, radius, color, fade distances, mode
C:update(dt, dtSim)Per-frame: color lerp, distance fade, arrow rotation/position
C:setToCheckpoint(wp)Sets position/radius from waypoint, repositions arrow
C:setMode(mode)Transitions to new mode, triggers show/hide
C:setVisibility(v)Shows/hides the arrow TSStatic
C:hide / C:show()Shorthand for setVisibility
C:createObject(shapeName, objectName)Creates a TSStatic with instance render data
C:createMarkers()Spawns the arrow TSStatic
C:clearMarkers()Deletes all spawned objects

Mode Colors

ModeColor (RGB)Description
default{1, 0.333, 0}Orange - normal checkpoint
next{0, 0, 0}Black - next-after-current
start{0.4, 1, 0.2}Green - start/rolling start
lap{0.4, 1, 0.2}Green - lap boundary
final{0.1, 0.3, 1}Blue - final checkpoint
branch{1, 0.6, 0.07}Yellow - branch point
hidden{0, 0, 0}Black - hidden (auto-hides)

How It Works

  1. Arrow shape: Uses s_mm_arrow_ribbon_down.dae mesh
  2. Camera facing: Each frame, computes direction from marker to camera and rotates arrow via quatFromDir(fwd:z0())
  3. Distance fade: Alpha fades from fadeNear (5) to fadeFar (25) using inverse lerp
  4. Bobbing: Arrow position oscillates vertically with math.sin(os.clock() * 1.9) * 0.4
  5. Color transition: Lerps between old and new mode colors over colorLerpDuration (0.3s)
  6. instanceColor1: Set to white with matching alpha for secondary material channel
  7. Auto-hide: When mode is hidden and color timer expires, calls hide()

Usage Example

local createMarker = require("scenario/raceMarkers/overhead")
local marker = createMarker(1)
marker:createMarkers()
marker:setToCheckpoint({pos = vec3(100, 200, 50), radius = 5})
marker:setMode('default')

-- Per frame:
marker:update(dt, dtSim)

Key Notes

  • Arrow scales to vec3(2,2,2) during updates
  • Objects are registered in ScenarioObjectsGroup for automatic cleanup
  • Uses canSave = false so markers don't persist in level saves

See Also

  • Race Marker: Attention - Floating Arrow Checkpoint Marker - Related reference
  • Race Marker: Crawl Marker - Arrow + Flag + Column Checkpoint - Related reference
  • Race Marker: Cylinder - Base + Cylinder Checkpoint Marker - Related reference
  • Scenario System Guide - Guide

None Marker

A no-op race marker implementation. All methods exist but do nothing, making checkpoints completely invisible. Used when no visual marker is desired.

Ring Marker - 3D Ring Checkpoint Marker

A race checkpoint marker that renders a 3D ring (hoop) at the waypoint position. Supports normal/up orientation, scales to waypoint radius, and swaps between regular and finish ring shapes based on mo

On this page

Class API (OOP via metatable)Mode ColorsHow It WorksUsage ExampleKey NotesSee Also