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
Rally Audio ManagerRally Camera Path PlayerRally ClientRally Cut CaptureRally EnumsRally Extension HelperRally GeometryRally ManagerRecce ManagerRecce AppRecce SettingsRally Settings ManagerSnap-to-RoadTraffic Exclusion ZonesRally UtilityRally Vehicle CaptureRally Vehicle Tracker
Rally Utility ColorsRally JSONL UtilitiesRally Utility Normalizer

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 Extensionsgameplayrallyutil

Rally Utility Normalizer

Simple text normalization module that applies word-replacement mappings to pacenote strings.

Simple text normalization module that applies word-replacement mappings to pacenote strings.


Public API

FunctionSignatureReturnsDescription
replaceWords(word_map, note)stringApply all word replacements from mapping table to note text
M.replaceWords(word_map, note)-replaceWords handler

How It Works

Takes a word map (array of {from, to} pairs) and applies each replacement sequentially using Lua's string.gsub:

local normalizer = require('gameplay/rally/util/normalizer')

local word_map = {
  {"(%d+) left",  "%1L"},
  {"(%d+) right", "%1R"},
  {"straight",    "flat"},
}

local result = normalizer.replaceWords(word_map, "3 left into straight")
-- result = "3L into flat"

Notes

  • Replacements are applied sequentially, so earlier replacements can affect later ones
  • Returns the input unchanged if note is nil
  • The from patterns support Lua pattern syntax (e.g., %d+ for digits)
  • Used to normalize speech-to-text output into standardized pacenote notation

See Also

  • Rally Utility Colors - Related reference
  • Rally JSONL Utilities - Related reference
  • Gameplay Systems Guide - Guide

Rally JSONL Utilities

Utility module for reading JSON Lines (JSONL) files - line-delimited JSON format used for recce recordings (driveline, cuts, transcripts).

Gameplay Race Route

Extended version of `route.lua` designed for racing. Adds metadata support, callbacks for route events, original position tracking for re-routing, and merge-priority handling for close waypoints.

On this page

Public APIHow It WorksNotesSee Also