RLS Studios
ProjectsPatreonCommunityDocsAbout
Join Patreon
BeamNG Modding Docs

Guides

Reference

Server CommandsGE UtilitiesGame Engine MainNavigation GraphScreenshot CaptureServerServer ConnectionSpawnpoint ManagerSimulation TimeVehicle SpawningSuspension Frequency Tester
Flowgraph Base ModuleFlowgraph Base NodeFlowgraph Base State NodeFlowgraph Node BuilderFlowgraph GraphFlowgraph Group HelperFlowgraph LinkFlowgraph ManagerNew Node TemplateFlowgraph PinFlowgraph States ManagerFlowgraph UtilsFlowgraph Variable Storage
ARunForLife (Flowgraph Node)Clear Lights Drag Race (Flowgraph Node)Countdown Lights Controller (Flowgraph Node)Get Custom Vehicle Data (Flowgraph Node)Get Mission Setup Data (Flowgraph Node)Check Players Position / Go To Start Line (Flowgraph Node)KnockAway Check (Flowgraph Node)Lights Controller (Flowgraph Node)Mission Post Clean (Flowgraph Node)Mission Cleanup / Pre Clean (Flowgraph Node)Prepare Vehicle (Flowgraph Node)Remove Stashed Player Vehicle (Flowgraph Node)Select Garage Vehicle (Flowgraph Node)Select Garage Sites / Zones (Flowgraph Node)Select Garage Spots (Flowgraph Node)Select Heist Spots (Flowgraph Node)Set Stage Lights (Flowgraph Node)Update Display Drag Race (Flowgraph Node)

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 Extensionsflowgraphnodesmission

Countdown Lights Controller (Flowgraph Node)

- **Node Name:** `Countdown Lights Controller`

Overview

  • Node Name: Countdown Lights Controller
  • Category: repeat_instant
  • File: extensions/flowgraph/nodes/mission/countdownLightsController.lua

Controls the countdown light tree for drag race missions. Supports both "Pro Tree" (all ambers at once) and "Sportsman Tree" (sequential ambers) modes, with jump start (disqualification) detection.

Pin Schema

Input Pins

PinTypeDescription
flowflowInflow for this node
resetflow (impulse)Resets the countdown state and hides all lights
proTreeboolIf true, uses pro tree (all ambers flash simultaneously). Default: true
distancenumberDistance of the player's vehicle from the start line

Output Pins

PinTypeDescription
flowflowOutflow for this node
disqualifiedflowFires if the player jumped the start
startedflowFires when the green light comes on (race begins)

Internals

FieldPurpose
self.starttimerElapsed time since countdown began
self.startedWhether the race has officially started
self.jumpStartedWhether the player moved before green
self.timerOnWhether the countdown timer is active

How It Works

Pro Tree Mode

  1. At 2.0s: All 3 amber lights on both sides illuminate simultaneously.
  2. At 2.4s: Ambers turn off, green lights turn on → race started.
  3. Total countdown: ~2.4 seconds.

Sportsman Tree Mode

  1. At 1.0s: First amber lights on.
  2. At 1.5s: Second amber lights on (first off).
  3. At 2.0s: Third amber lights on (second off).
  4. At 2.5s: Green lights on → race started.
  5. Total countdown: ~2.5 seconds.

Jump Start Detection

  • If distance > 0.2 before the green light, the player is disqualified.
  • Red lights illuminate on both sides, ambers and greens are hidden.
  • The disqualified output fires.

Key Dependencies

  • scenetree.findObject() - locates Amberlight, Greenlight, Redlight scene objects
  • _flowgraph_createNode() - standard flowgraph node registration

Additional Methods

C:_executionStarted()

Called when graph execution starts. Used for initialization/reset.

C:init()

Initializes the node, setting up pins and default properties.

C:initLights()

Node method.

C:work()

Main work function called each frame/tick when the node is active.


See Also

  • ARunForLife (Flowgraph Node) - Related reference
  • Update Display Drag Race (Flowgraph Node) - Related reference
  • Clear Lights Drag Race (Flowgraph Node) - Related reference
  • FlowGraph Guide - Guide

Clear Lights Drag Race (Flowgraph Node)

- **Node Name:** `Clear Lights Dragrace`

Get Custom Vehicle Data (Flowgraph Node)

- **Node Name:** `Get Custom Vehicle Data`

On this page

OverviewPin SchemaInput PinsOutput PinsInternalsHow It WorksPro Tree ModeSportsman Tree ModeJump Start DetectionKey DependenciesAdditional MethodsC:_executionStarted()C:init()C:initLights()C:work()See Also