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
Automatic GearboxCentrifugal ClutchCombustion EngineCombustion Engine ThermalsCompressorCVT GearboxDCT GearboxDifferentialElectric MotorElectric ServoElectric WinchPowertrain Components OverviewFriction ClutchGeneric Torque ProviderHydraulic AccumulatorHydraulic CylinderHydraulic PumpHydraulic WinchLinear ActuatorManual GearboxMulti-ShaftNitrous Oxide InjectionPowertrain Base DeviceRange BoxSequential GearboxShaftSplit ShaftSuperchargerTorque ConverterTorsion ReactorTurbochargerViscous Clutch

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 Referencevepowertrain

Combustion Engine Thermals

Advanced thermal simulation for combustion engines. Models coolant, oil, cylinder wall, and exhaust temperatures with realistic heat transfer, overheat damage, and component failure mechanics.

Advanced thermal simulation for combustion engines. Models coolant, oil, cylinder wall, engine block, and exhaust temperatures with realistic heat transfer between components. Simulates overheat damage progression including head gasket failure, piston ring damage, connecting rod bearing wear, and catastrophic engine block melting.


State Fields

M.engineBlockTemperature       -- Engine block temperature (°C)
M.cylinderWallTemperature      -- Cylinder wall temperature (°C)
M.coolantTemperature           -- Coolant temperature (°C)
M.oilTemperature               -- Oil temperature (°C)
M.exhaustTemperature           -- Exhaust gas temperature (°C)
M.radiatorFanSpin              -- Radiator fan spin speed (for audio/visual)
M.exhaustEndNodes              -- Exhaust pipe endpoint node IDs (for visual effects)

-- Damage state
M.engineBlockOverheatDamage    -- Cumulative engine block overheat damage (0.0+)
M.oilOverheatDamage            -- Cumulative oil overheat damage (0.0+)
M.cylinderWallOverheatDamage   -- Cumulative cylinder wall overheat damage (0.0+)
M.headGasketBlown              -- Boolean: head gasket failure state
M.pistonRingsDamaged           -- Boolean: piston ring damage state
M.connectingRodBearingsDamaged -- Boolean: connecting rod bearing damage state
M.engineBlockMelted            -- Boolean: catastrophic engine block failure
M.cylinderWallsMelted          -- Boolean: catastrophic cylinder wall failure

M.debugData                    -- Table of debug values for thermal visualization

Implementation Recipes

Manual Cooling / Heating

Subtract from or add to temperature values in updateFixedStep to simulate external thermal effects (like methanol injection or extreme weather).

local engine = powertrain.getDevice("mainEngine")
if engine and engine.thermals then
  -- Cool the engine by 5 degrees per second
  engine.thermals.coolantTemperature = engine.thermals.coolantTemperature - (5 * dt)
end

Monitoring Overheat

Check damage values to trigger "Check Engine" lights or limp modes.

if (engine.thermals.engineBlockOverheatDamage or 0) > 0 then
  electrics.values.checkengine = 1
end

See Also

  • Combustion Engine — Parent engine device
  • Turbocharger — Exhaust-driven compressor (heat source)
  • Supercharger — Engine-driven compressor

Combustion Engine

Internal combustion engine device with torque curves, starter motor, ignition control, and rev limiters. The primary power source for most vehicles in BeamNG.

Compressor

Generic air compressor powertrain device. Provides compressed air for pneumatic systems such as air brakes, air suspension, and horn systems.

On this page

State FieldsImplementation RecipesManual Cooling / HeatingMonitoring OverheatSee Also