RLS Studios
ProjectsPatreonCommunityDocsAbout
Join Patreon
BeamNG Modding Docs

Guides

Reference

server/commands - Camera & Input Commandsge_utils - Game Engine Utility Functionsmain.lua - GE Lua Entry Point & Game Loopmap.lua - Navigation Graph (AI Road Map)screenshot.lua - Screenshot Systemserver/server - Level Loading & Game ServerserverConnection - Client-Server Connection Manager`setSpawnpoint` - Default Spawn Point Persistence`simTimeAuthority` - Simulation Time & Bullet Time Control`spawn` - Vehicle Spawning & Safe Placement`suspensionFrequencyTester` - Suspension Natural Frequency Analysis
`adasUltrasonic.lua``cameraPreview.lua``capturePlayer.lua``license.lua``lidarTest.lua``multiscreen.lua``openDriveExporter.lua``openStreetMapExporter.lua``partAnnotations.lua``platoonFunctions.lua``pythonExport.lua``rawLidar.lua``rawLidarEmpty.lua``sensors.lua``sumoExporter.lua``techCore.lua``terrainImporter.lua``ultrasonicTest.lua``utils.lua`

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 Extensionstech

`cameraPreview.lua`

> This Source Code Form is subject to the terms of the bCDDL, v. 1.1.

This Source Code Form is subject to the terms of the bCDDL, v. 1.1. If a copy of the bCDDL was not distributed with this file, You can obtain one at http://beamng.com/bCDDL-1.1.txt

Module variable: M

Hooks

  • onExtensionLoaded
  • onSensorCreated
  • onSensorRemoved

Exported Functions

M.onExtensionLoaded()

Line 59

M.onSensorCreated(sensorType, sensorId)

Line 151

M.onSensorRemoved(sensorType, sensorId)

Line 158

Returns: M

M.getCamData()

Line 147

Returns: camData

M.changeCamDebugState(cam)

Line 68

M.visualizeCameraById(sensorId)

Line 122

M.stopVisualizeCameraById(sensorId)

Line 135

Exported Variables

M.dependencies

Line 7 - {"tech_sensors"}

Internal Functions

Show internal functions
  • unloadCamera(sensorId) (line 20)
  • getDisplaySize(size) (line 24)
  • loadCamera(sensorId) (line 34)
  • loadCameras() (line 51)
  • onExtensionLoaded() (line 59)
  • changeCamDebugState(cam) (line 68)
  • boolToNum(x) (line 78)
  • visualizeCamera(cam) (line 82)
  • visualizeCameraById(sensorId) (line 122)
  • stopVisualizeCameraById(sensorId) (line 135)
  • getCamData() (line 147)
  • onSensorCreated(sensorType, sensorId) (line 151)
  • onSensorRemoved(sensorType, sensorId) (line 158)

`adasUltrasonic.lua`

> This Source Code Form is subject to the terms of the bCDDL, v. 1.1.

`capturePlayer.lua`

> This Source Code Form is subject to the terms of the bCDDL, v. 1.1.

On this page

HooksExported FunctionsM.onExtensionLoaded()M.onSensorCreated(sensorType, sensorId)M.onSensorRemoved(sensorType, sensorId)M.getCamData()M.changeCamDebugState(cam)M.visualizeCameraById(sensorId)M.stopVisualizeCameraById(sensorId)Exported VariablesM.dependenciesInternal Functions