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

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 Extensionseditor

Editor Windows Manager

Provides a utility window that lists all registered editor windows and allows resetting their positions. Useful when a window is dragged off-screen or lost.

Provides a utility window that lists all registered editor windows and allows resetting their positions. Useful when a window is dragged off-screen or lost.


Public Interface

Editor Hooks

HookDescription
onEditorGuiDraws the "Windows" panel with a searchable list of all editor windows. Each entry has a button to reset that window's position to (0,0). Also performs boundary checking to keep the Windows panel itself on-screen.
onEditorInitializedRegisters the "Windows" window (800×500) and adds the "Window Position Reset..." menu item. Also registers the assetBrowserEditMode edit mode stub.

Internal Functions

FunctionPurpose
windowPosCheck()Ensures the Windows panel stays within the main viewport bounds. Moves it to (40,40) relative to the viewport if it drifts off-screen.
onWindowMenuItem()Callback that shows the window when its menu item is clicked.

Window Layout

The window displays a two-column table:

  1. Window Name - The title of each registered editor window
  2. Action Button - "Set position to 0,0" to reset that window's location

A text filter at the top allows searching by window name.


Usage Example

-- The window is accessed from the editor menu bar:
-- Editor Menu > Window Position Reset...

-- Internally, the window list comes from:
local windowsData = editor.getWindowsState()
-- Returns a table of { [name] = { title = "...", ... }, ... }

-- Each window can be repositioned via ImGui:
im.SetWindowPos2(windowName, im.ImVec2(0, 0))

Boundary Check Logic

-- Keeps the Windows panel visible on the main viewport
local function windowPosCheck()
  local mainViewport = im.GetMainViewport()
  local mVPos = mainViewport.Pos
  local mVSize = mainViewport.Size
  -- If window is out of bounds in any direction, snap to (40,40)
  if windowPos.x + windowSize.x - 40 < mVPos.x
     or windowPos.y < mVPos.y
     or windowPos.x > mVPos.x + mVSize.x
     or windowPos.y > mVPos.y + mVSize.y then
    im.SetWindowPos2("Windows", im.ImVec2(mVPos.x + 40, mVPos.y + 40))
  end
end

Additional Exports

  • M.onEditorGui
  • M.onEditorInitialized

See Also

  • Editor AI Tests - Related reference
  • Editor AI Visualization - Related reference
  • Editor – Assembly Spline Tool - Related reference
  • World Editor Guide - Guide

Editor Water Object Helper

Automatically reloads textures on WaterObject instances when texture-related inspector fields are changed in the editor.

Editor API - AI Path

Stub module for the editor AI path API. Currently only provides an initialization function.

On this page

Public InterfaceEditor HooksInternal FunctionsWindow LayoutUsage ExampleBoundary Check LogicAdditional ExportsSee Also