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
Align For CouplingApply Velocity to VehicleBoost VehicleSet Vehicle ColorsCustom Parts Config ProviderEnter VehicleFlip UprightFreeze VehicleGenerate License PlateGet Vehicle ActiveGet Electrics ValueGet GearboxmodeGet Powertrain DataGravity ForceDistance From GroundHas Coupler TagIs CoupledIs Player UsableKeep VehicleMove Vehicle ToOn Cannon FiredOn Vehicle DestroyedOn Vehicle ResetOn Vehicle SpawnedOn Vehicle SwitchedPlayer UsableRandom Config ProviderRecover In PlaceRemove VehicleTimeline ReplaySet Vehicle ActiveSet Gearbox ModeSet IgnitionSet License PlateSet LightbarSet LightsShift to Gear IndexSpawn VehicleVehicle StatesTeleport To Last RoadToggle Vehicle ControlsMove To ShowroomVehicle TouchProps TouchStatic Object TouchTrack VehicleTrailer Respawn ControlVehicle Config ProviderGet Vehicle DataGet Vehicle DataGet Vehicle BoundsVehicle PingGet Vehicle Wheel Center

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 Extensionsflowgraphnodesvehicle

Get Vehicle Wheel Center

- **Node Name:** `Get Vehicle Wheel Center`

Overview

  • Node Name: Get Vehicle Wheel Center
  • Category: repeat_instant
  • File: extensions/flowgraph/nodes/vehicle/vehicleWheels.lua

Computes and outputs the average world-space position of all wheel axis nodes on a vehicle.

Pin Schema

Input Pins

PinTypeDescription
vehIdnumberVehicle ID. Falls back to player vehicle.

Output Pins

PinTypeDescription
wheelCentervec3Average position of all wheel axis nodes in world space.

Internals

Key Methods

MethodDescription
init()No-op.
work()Iterates over all wheels, averages their positions, and adds the vehicle's ref-node offset.

How It Works

  1. Resolves the vehicle by ID or falls back to the player vehicle.
  2. Iterates veh:getWheelCount() wheels, reading each wheel's first axis node position via veh:getNodePosition(axisNodes[1]).
  3. Accumulates all positions, then divides by count to get the average.
  4. Adds the vehicle's world position (veh:getPosition()) since node positions are in local space.
  5. Outputs the result as a table-format vec3.

Note: Node positions from getNodePosition() are relative to the vehicle's ref node. The vehicle world position is added to convert to world space.

Usage Example

-- Flowgraph:
-- [Vehicle ID] → vehId → [Get Vehicle Wheel Center]
--                              ↓ wheelCenter → [Ground Level Check]

-- Equivalent GE Lua:
local veh = getPlayerVehicle(0)
local center = vec3(0, 0, 0)
local count = veh:getWheelCount()
for i = 0, count - 1 do
  local axisNodes = veh:getWheelAxisNodes(i)
  center:setAdd(vec3(veh:getNodePosition(axisNodes[1])))
end
center:setScaled(1 / count)
center:setAdd(vec3(veh:getPosition()))

Key Dependencies

  • veh:getWheelCount() / veh:getWheelAxisNodes() - wheel axis node access
  • veh:getNodePosition() - beam node local positions
  • veh:getPosition() - vehicle ref-node world position

See Also

  • Align for Coupling (Flowgraph Node) - Related reference
  • Apply Velocity to Vehicle (Flowgraph Node) - Related reference
  • Boost Vehicle (Flowgraph Node) - Related reference
  • FlowGraph Guide - Guide

Vehicle Ping

- **Node Name:** `Vehicle Ping`

AI Parameters

- **Node Name:** `AI Parameters`

On this page

OverviewPin SchemaInput PinsOutput PinsInternalsKey MethodsHow It WorksUsage ExampleKey DependenciesSee Also