RLS Studios
ProjectsPatreonCommunityDocsAbout
Join Patreon
BeamNG Modding Docs

Guides

Reference

AI Module ReferenceBackwards Compatibility Module ReferenceBdebug Module ReferenceBdebugImpl Module ReferenceBeamstate Module ReferenceBullettime Module ReferenceController Module ReferenceDamageTracker Module ReferenceDrivetrain Module ReferenceElectrics Module ReferenceElectrics Custom Value ParserEnergyStorage Module ReferenceExtensions Module ReferenceFire Module ReferenceVehicle Engine True GlobalsGuihooks Module ReferenceGUI Streams Module ReferenceHTML Texture Module ReferenceHydros Module ReferenceInput Module ReferenceJBeam-Lua Integration GuideMapmgr Module ReferenceMaterial Module ReferenceBeamNG Math & Unit Conversions Referenceobj (Vehicle C++ Object)PartCondition Module ReferenceParticlefilter Module ReferenceParticles Module ReferencePowertrain Module ReferenceVehicle Property & Module TreeProps Module ReferenceProtocols Module ReferenceRecovery Module ReferenceScriptAI Module ReferenceSensors Module ReferenceSounds Module ReferenceStreams Module ReferenceThrusters Module Reference`v` (Vehicle Data & JBeam)Wheels Module Reference
4WD / Transfer Case ControllerAdvanced Coupler ControlAirplane Control SurfacesAxle Lift ControllerBeacon Spin ControllerBeam NavigatorBypass Dampers ControllerController TemplateControl ModesDrag TimerDrive ModesDummy ControllerElectronic Stability Control (ESC)ETK Gauges ControllerVehicle Controllers OverviewHydraulic Suspension ControllerInput/Output Demo ControllerJATO (Jet Assisted Take-Off)Lightbar ControllerLine LockLogger TemplateNitrous Oxide InjectionPlayer ControllerPneumatics System ControllerPower Steering ControllerPyrotechnic Charge ControllerSBR Gauges ControllerShift Lights ControllerTire Pressure ControlTrailer Landing Feet ControllerTwo-Step Launch ControlVivace Gauges ControllerWendover Gauges Controller

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 Referencevecontroller

Player Controller

The main controller for the walking/unicycle character mode. Manages movement physics using PID-based stabilization on a ball, handles jumping, crouching, and camera-relative directional input. Provides compatibility variables for dashboard UI elements.

The main controller for the walking/unicycle character mode. Manages movement physics using PID-based stabilization on a ball, handles jumping, crouching, and camera-relative directional input. Provides compatibility variables for dashboard UI elements.


State Fields

FieldTypeDescription
fireEngineTemperaturenumberDummy value for compatibility with dashboard clusters.
throttle, brake, clutchRationumberProcessed control inputs.
engineInfotableStandard telemetry buffer for UI clusters.
ignitionbooleanInternal status flag.
isEngineRunningnumberMovement status (1 if moving or ready).

Public API

FunctionDescription
walkLeftRight(value)Manages movement direction based on camera rotation.
jump(value)Triggers a high-force impulse to launch the player into the air.
crouch(value)Manages height reduction by adjusting internal beam lengths and pressures.
setFreeze(mode)Disables all movement inputs.
module.setCameraControlData(controlData)Sets the camera control data.

Hooks

HookDescription
init(jbeamData)Identifies stabilization nodes and beams, and sets up ball physics parameters.
updateFixedStep(dt)primary stabilization and propulsion loop. Calculates PID-based forces to keep the player upright and applies torque to the ball for movement.
updateGFX(dt)Handles state transitions like crouching and updates UI electrics.
module.initLastStage()Final-stage initialization after all controllers and powertrains are ready.
module.reset()Resets the controller to its initial state.
module.settingsChanged()Called when vehicle settings change.
module.onDeserialize(data)Restores state from serialized data.
module.onSerialize()Serializes state for saving.
module.nodeCollision(p)take a look at physics particles and use the node and slip velocities to estimate a ball center velocity that is local to the unicycle

Usage Example

-- Movement is handled via input actions (WASD)
-- Jump
controller.getController("playerController").jump(1)

-- Toggle crouch
controller.getController("playerController").toggleCrouch()

-- Freeze movement
controller.getController("playerController").setFreeze(1)

See Also

  • Vehicle Controller — Main vehicle controller
  • Dummy Controller — Minimal controller alternative

Nitrous Oxide Injection

Controls nitrous oxide (NOS/N2O) injection systems that provide temporary power boosts by enriching the combustion mixture with additional oxygen. Manages bottle pressure, solenoid activation, fuel enrichment, and injection timing.

Pneumatics System Controller

Top-level controller for vehicle pneumatic (air pressure) systems. Manages air compressors, pressure tanks, valves, and pneumatic actuators. Provides the foundation for air brakes, air suspension, and other pneumatic subsystems.

On this page

State FieldsPublic APIHooksUsage ExampleSee Also