RLS Studios
ProjectsPatreonCommunityDocsAbout
Join Patreon
BeamNG Modding Docs

Guides

Reference

Server CommandsGE UtilitiesGame Engine MainNavigation GraphScreenshot CaptureServerServer ConnectionSpawnpoint ManagerSimulation TimeVehicle SpawningSuspension Frequency Tester
Editor AI TestsEditor AI VisualizationEditor – Assembly Spline ToolAsset BrowserAsset DeduplicatorAsset Management ToolSFX Previewer (Audio Events List)Audio Ribbon EditorAutoSaveBarriers EditorBiome ToolBuilding EditorBulk RenameCamera BookmarksCamera TransformCamera Path EditorCEF HelperCo-Simulation Signal EditorCrawl Data EditorCreate Object ToolDataBlock EditorDecal EditorDecal Spline EditorDocumentation HelperDrag Race EditorDrift Data EditorDrive Path EditorDynamic Decals Tool (Vehicle Livery Creator)Engine Audio DebugExtensions DebugExtensions EditorFFI Pointer Leak TestFile DialogFlowgraph EditorForest EditorForest ViewEditor Gizmo HelperEditor Ground Model Debug HelperEditor Headless Editor TestEditor Icon OverviewEditor ImGui C DemoEditor InspectorEditor Layout ManagerEditor Level SettingsEditor Level ValidatorEditor LoggerEditor Log HelperEditor MainEditor Main MenuEditor Main ToolbarEditor Main UpdateMap Sensor EditorMaster Spline EditorMaterial EditorMeasures Inspector HeaderMesh Editor (Base)Mesh Road EditorMesh Spline EditorMission EditorMission PlaybookMission Start Position EditorMulti Spawn Manager (Vehicle Groups)Navigation Mesh EditorEditor News MessageObject Tool (Object Select Edit Mode)Object To Spline EditorParticle EditorPerformance Profiler / Camera RecorderPhysics ReloaderPrefab Instance EditorEditor PreferencesRace / Path EditorRally EditorRaycast Test Editor ToolRenderer Components Editor ToolRender Test Editor ToolResource Checker Editor ToolRiver EditorRoad Architect EditorRoad DecorationsRoad Editor (Decal Road)Road Network ExporterRoad River Cache HandlerRoad River GUIRoad Spline EditorRoad Template EditorRoad UtilitiesScene TreeScene ViewScreenshot Creator BootstrapScript AI EditorScript AI ManagerSensor Configuration EditorSensor DebuggerShape EditorShortcut LegendSidewalk Spline EditorSites EditorSlot Traffic EditorSuspension Audio DebugTech Server ManagerTerraform ToolTerrain And Road ImporterTerrain EditorTerrain Materials EditorText EditorTool ManagerTool ShortcutsTraffic DebugTraffic ManagerTraffic Signals EditorUndo History ViewerVehicle Bridge TestVehicle Detail ViewerVehicle Editor MainEditor - VisualizationEditor Viz HelperEditor Water Object HelperEditor Windows Manager
Dynamic Decals - BrowserDynamic Decals - BrushesDynamic Decals - CameraDynamic Decals - Color HistoryDynamic Decals - Color PresetsDynamic Decals - Debug SectionDynamic Decals - Debug TexturesDynamic Decals - Documentation SystemDynamic Decals - ExportDynamic Decals - FontsDynamic Decals - GizmoDynamic Decals - HelperDynamic Decals HistoryDynamic Decals InspectorDynamic Decals Layer StackDynamic Decals Load/SaveDynamic Decals MeshesDynamic Decals NewsDynamic Decals NotificationDynamic Decals SelectionDynamic Decals SettingsDynamic Decals TexturesDynamic Decals Vehicle Color PaletteDynamic Decals Widgets

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 ExtensionseditordynamicDecals

Dynamic Decals - Gizmo

3D transform gizmo controller for the dynamic decals tool. Manages translate/rotate/scale modes, axis gizmo lifecycle (begin/drag/end), bounding box visualization, and per-mode callback dispatch. The

3D transform gizmo controller for the dynamic decals tool. Manages translate/rotate/scale modes, axis gizmo lifecycle (begin/drag/end), bounding box visualization, and per-mode callback dispatch. The gizmo operates on the selected decal layer's world transform.


Public API

FunctionSignatureDescription
M.getTransformMode() → numberReturns current transform mode (0=none, 1=translate, 2=rotate, 3=scale)
M.setTransformMode(value)Sets transform mode
M.resetTransformFn()Clears translate/rotate/scale callback functions
M.getDragCount() → numberReturns drag frame count (0 if not dragging)
M.gizmoBeginDrag()Called when gizmo drag starts (reset counter)
M.gizmoEndDrag()Called when gizmo drag ends
M.gizmoDragging()Per-frame drag handler: dispatches to translateFn/rotateFn/scaleFn
M.registerEditorPreferences(prefsRegistry)Registers bounding box display/color preferences
M.editorPreferenceValueChanged(path, value)Preference change callback (stub)
M.editModeUpdate(dtReal, dtSim, dtRaw)Per-frame update: draws gizmo + bounding box
M.setup(tool_in)Stores API reference

Public Fields

FieldTypeDescription
M.datatableCurrent gizmo context: uid, type, objectType, dataPointIndex, objectDataCopy
M.transformMatrixFCurrent gizmo transform matrix
M.translateFnfunctionCallback for translate mode dragging
M.rotateFnfunctionCallback for rotate mode dragging
M.scaleFnfunctionCallback for scale mode dragging
M.transformModestableEnum: {none=0, translate=1, rotate=2, scale=3}

Gizmo Flow

setTransformMode(M.transformModes.translate)
M.translateFn = function(gizmoTransform) ... end

-- Each frame (in editModeUpdate):
editor.updateAxisGizmo(gizmoBeginDrag, gizmoEndDrag, gizmoDragging)
editor.drawAxisGizmo()

-- During drag (gizmoDragging):
-- Skips first frame (dragCount == 1)
-- Dispatches to M.translateFn / M.rotateFn / M.scaleFn

Bounding Box Rendering

When enabled and a decal layer is selected:

local transform = api.getDecalWorldTransform(layer)
editor.drawSelectionBBox(transform, ColorF(r, g, b, a))

Preferences

KeyTypeDefaultDescription
gizmo.displayBoundingBoxbooltrueShow bounding box for selected decal
gizmo.boundingBoxColortable{1,0,0,0.75}RGBA color for bounding box
gizmo.displayDebugObjWhileMovingControlPointsbooltrueShow debug sphere while dragging control points

Dependencies

ModulePurpose
editor_api_dynamicDecalsgetLayerByUid(), getDecalWorldTransform()

See Also

  • Dynamic Decals - Browser - Related reference
  • Dynamic Decals - Brushes - Related reference
  • Dynamic Decals - Camera - Related reference
  • World Editor Guide - Guide

Dynamic Decals - Fonts

Font atlas generation and management for the dynamic decals tool. Rasterizes TTF fonts into atlas textures (with optional SDF), provides glyph browser, preview window, and integrates with the decal sy

Dynamic Decals - Helper

Shared utility functions for the dynamic decals tool. Provides centered text rendering, image widgets with tooltips, icon tooltips, and string formatting helpers used across all dynamic decal modules.

On this page

Public APIPublic FieldsGizmo FlowBounding Box RenderingPreferencesDependenciesSee Also