RLS Studios
ProjectsPatreonCommunityDocsAbout
Join Patreon
BeamNG Modding Docs

Guides

Reference

server/commands - Camera & Input Commandsge_utils - Game Engine Utility Functionsmain.lua - GE Lua Entry Point & Game Loopmap.lua - Navigation Graph (AI Road Map)screenshot.lua - Screenshot Systemserver/server - Level Loading & Game ServerserverConnection - Client-Server Connection Manager`setSpawnpoint` - Default Spawn Point Persistence`simTimeAuthority` - Simulation Time & Bullet Time Control`spawn` - Vehicle Spawning & Safe Placement`suspensionFrequencyTester` - Suspension Natural Frequency Analysis
Auto AnnotationBoosterCalibrate ESCCompile ImpostersCompile MeshesConfig List GeneratorDecal Roads EditorDependency TreeDoc CreatorExport (glTF)Follow The White RabbitForest GeneratorGround Model DebugInput System UtilsInstanced Line Render DemoJBeam StatsLog StreamsMap TilesNode Beam ExportNode StreamPhotomodePrecompile ShadersPrecompile VehiclesProcedural Track (Gymkhana Generator)Rectangle GeneratorRender Components APIResave MaterialsRich PresenceSave Dynamic DataScreenshot Creator (Vehicle Thumbnails)ShowroomSort LinesStep HandlerTerrain GeneratorTest Extension ProxiesTest JSON Files Syntaxutil/vehicleRopeDebug - Rope Physics Debug UIutil/worker - Batch Job Workerutil/wsTest - WebSocket Test Server

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 Extensionsutil

Dependency Tree

Analyzes level asset dependencies by walking scene objects and building a dependency graph of files, textures, materials, shapes, and SimObjects.

Analyzes level asset dependencies by walking scene objects and building a dependency graph of files, textures, materials, shapes, and SimObjects.


Overview

util_dependencyTree scans .level.json, .material.json, and .datablock.json files for a target level folder, then recursively inspects each SimObject for its dependencies (textures, materials, shapes, files) and what it provides (named objects, materials). Outputs the tree as dependencytree.json.

Extension path: lua/ge/extensions/util/dependencyTree.lua


Exports (M)

FunctionSignatureDescription
test()Runs the dependency analysis on the configured folder.

Internals

Target Folder

Hardcoded to levels/gridmap. Change folder local variable to analyze other levels.

Dependency Categories

Each entity tracks:

  • deps: What it depends on - categories: file, tex, material, shape, simobject
  • provides: What it makes available - categories: simobject, material, shape

Supported Object Classes

ClassDependencies Extracted
TSStaticshapeName
BeamNGVehicleJBeam, partConfig
DecalRoadmaterial
MeshRoadtopMaterial, bottomMaterial, sideMaterial
River / WaterPlanetextures (ripple, foam, depthGradient), soundAmbience
ScatterSkygradient textures, moonMat, nightCubemap
Forestforest data file items
ForestItemDatashapeFile
MaterialAll stage textures (diffuse, normal, specular, etc.), cubemap
GroundCovermaterial, shapeFilename
ParticleData/Emittertextures, particles
ConvexShape / GroundPlanematerial
LevelInfoglobalEnviromentMap

Shape Info Processing

After scene objects, .meshes.json files are also scanned. Each shape's materials become dependencies, and the shape file itself is registered as a provides.

Path Normalization

File paths in dependencies are normalized relative to the source file's directory. Shape and texture extensions are stripped for consistent matching.


How It Works

  1. Call test() to run the analysis.
  2. All .level.json, .material.json, and .datablock.json files in the folder are parsed.
  3. Each SimObject is recursively inspected for dependencies.
  4. Shape info files (.meshes.json) add material dependencies.
  5. Results are written to dependencytree.json.

Lua Examples

-- Run dependency analysis on the default folder (gridmap)
extensions.util_dependencyTree.test()

-- Output: dependencytree.json containing entities with deps/provides

Additional Exports

  • M.test - (undocumented)

Decal Roads Editor

Debug visualization for AIPath objects in the world editor. Renders lane markings, widths, and directions using dynamic decals and debug drawing.

Doc Creator

Generates JSON data files and resources for the BeamNG documentation / Hugo system. Exports levels, vehicles, materials, JBeam defaults, controller info, and more across all available languages.

On this page

OverviewExports (M)InternalsTarget FolderDependency CategoriesSupported Object ClassesShape Info ProcessingPath NormalizationHow It WorksLua ExamplesAdditional Exports