Master Spline Editor
Main editor tool for the Master Spline system - a parametric road/spline editor with multi-layer linking (mesh, assembly, decal, road splines), auto banking, terrain conforming, road design homologati
Main editor tool for the Master Spline system - a parametric road/spline editor with multi-layer linking (mesh, assembly, decal, road splines), auto banking, terrain conforming, road design homologation, auto road generation, and bitmap mask import/export.
Public API
| Function | Signature | Description |
|---|---|---|
M.setSelectedSplineIdx | (idx) | Sets the selected spline index (for cross-tool selection) |
M.setSelectedNodeIdx | (idx) | Sets the selected node index (for cross-tool selection) |
M.onSerialize | () | Serializes all master splines for scene save |
M.onDeserialized | (data) | Deserializes master splines from scene data |
M.onEditorGui | () | Main per-frame editor GUI and rendering callback |
M.onEditorInitialized | () | Registers the edit mode and tool window |
M.onClientEndMission | () | Cleans up all master splines when leaving a map |
Dependencies Field
M.dependencies = {
'editor_assemblySpline',
'editor_decalSpline',
'editor_meshSpline',
'editor_roadSpline',
}Key Features
- Layer System: Each master spline contains layers, each linkable to mesh/assembly/decal/road splines
- Auto Banking: Configurable banking strength and falloff per spline
- Terrain Conforming: Nodes snap to terrain height with terrain normals
- Homologation: Real-time analysis of slope, corner radius, banking, and width gradient against road design presets
- Auto Road Generation: A* pathfinding on terrain grid to generate roads between waypoints
- Bitmap Import/Export: Import splines from PNG masks, export spline masks
Usage Example
-- Activate via editor toolbar: "Master Spline" tool
-- Add a master spline, place nodes, then create linked layers:
-- - Road Spline layer (for decal roads)
-- - Mesh Spline layer (for barriers/fences)
-- - Assembly/Decal Spline layers
-- Cross-tool API:
extensions.editor_masterSpline.setSelectedSplineIdx(2)Module Dependencies
editor/masterSpline/splineMgr- Spline data managementeditor/masterSpline/layerMgr- Layer operationseditor/masterSpline/autoRoadGen- A* road generationeditor/masterSpline/jumpTables- Cross-tool dispatch tableseditor/masterSpline/homologation- Road design analysis/optimizationeditor/toolUtilities/*- Rendering, geometry, input, RDP simplification
See Also
- Editor AI Tests - Related reference
- Editor AI Visualization - Related reference
- Editor – Assembly Spline Tool - Related reference
- World Editor Guide - Guide
Map Sensor Editor
Editor tool for placing and configuring map-attached sensors (Camera, LiDAR, Ultrasonic, RADAR). Requires `Research` build flag. Provides full ImGui UI for sensor management, live/edit mode toggling,
Material Editor
Full-featured material editor for inspecting and modifying Torque3D `Material` objects. Supports PBR workflows, texture issue scanning, cubemap editing, material preview, layer management, copy/paste,