RLS Studios
ProjectsPatreonCommunityDocsAbout
Join Patreon
BeamNG Modding Docs

Guides

Reference

Server CommandsGE UtilitiesGame Engine MainNavigation GraphScreenshot CaptureServerServer ConnectionSpawnpoint ManagerSimulation TimeVehicle SpawningSuspension Frequency Tester
Gameplay AchievementGameplay CityDiscoverForce FieldGarage ModeMarker InteractionParking SystemGameplay Playmode MarkersGameplay PoliceGameplay RallyGameplay Rally LoopGameplay Raw POIsGameplay Skidpad TestSpeed Trap LeaderboardsSpeed Traps and CamerasGameplay StatisticsTaxi Ride SystemTraffic SystemVehicle PerformanceWalking
Drift Zone BoundsDrift Race PathDrift UI DisplayDrift Detection EngineDrift SystemDrift Quick MessagesDrift Save/LoadDrift ScoreboardDrift Scoring SystemDrift AudioDrift StallingDrift StatisticsDrift Stunt Zones
Donut ZoneDrift Through ZoneHit Pole ZoneNear Pole Zone

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 ExtensionsgameplaydriftstuntZones

Near Pole Zone

Reference for the near-pole stunt zone class, loaded via `require("gameplay/drift/stuntZones/nearPole")`.

Reference for the near-pole stunt zone class, loaded via require("gameplay/drift/stuntZones/nearPole").


Overview

Spawns a delineator pole (striped config) that scores based on how close the player's vehicle corners pass to it while drifting, without actually hitting it. Returns a class factory function.


Factory

return function(data) → nearPoleInstance

Class Methods

MethodSignatureDescription
init(data)Stores data, resets, spawns delineator (stripes.pc config), creates marker
reset()Resets pole physics, clears/recreates marker
resetData()Resets activeData: available=true, minCornerDist=∞, lastFramePlDist=∞
clear()Deletes pole vehicle and clears marker
clearMarker()Removes overhead race marker
createMarker()Creates overhead marker at pole position
accomplish()Clears marker, sets unavailable, fires onAnyStuntZoneAccomplished → onNearPoleAccomplished with closeness factor
detectStunt()Checks vehicle corners within maxDist (4m); scores when player starts moving away
isAvailable()Returns self.activeData.available
onUpdate(dtReal, dtSim)Updates marker, detects physical collision (which nullifies the near-miss)
onVehicleDestroyed(vehId)If pole destroyed, removes this stunt zone

Key Behaviors

  • maxDist = 4 meters - corners must be within this range
  • Closeness is calculated as 1 - (minCornerDist / maxDist) - closer = higher score
  • Scores when plDist > lastFramePlDist (player moving away) and pole wasn't hit
  • If the pole IS hit (objectCollisions), hitPole flag prevents scoring
  • Uses gameplay_drift_drift.getVehCorners() for precise corner distance checks
  • One-shot: unavailable after scoring until reset()

See Also

  • drift/stuntZones/donut - Donut Stunt Zone - Related reference
  • drift/stuntZones/driftThrough - Drift-Through Stunt Zone - Related reference
  • drift/stuntZones/hitPole - Hit Pole Stunt Zone - Related reference
  • Gameplay Systems Guide - Guide

Hit Pole Zone

Reference for the hit-pole stunt zone class, loaded via `require("gameplay/drift/stuntZones/hitPole")`.

Big Map Marker

Marker class for the big map view. Renders a floating icon with a column below it, using `BeamNGWorldIconsRenderer`. Handles alpha smoothing, selection/hover states, and multi-POI clustering.

On this page

OverviewFactoryClass MethodsKey BehaviorsSee Also