RLS Studios
ProjectsPatreonCommunityDocsAbout
Join Patreon
BeamNG Modding Docs

Guides

Reference

cdefDebugDraw ReferencecdefGpuMesh ReferencecdefImgui ReferencecdefMath Referencecdefs ReferencecontrolSystems Referencecsvlib ReferencedelayLine Referencedequeue ReferencedevUtils ReferenceEvent Referenceextensions Referencefilters Referencegraphpath Referenceguihooks ReferenceinputFilters ReferenceinterpolatedMap Referenceintrospection ReferencejbeamWriter Referencejson-ast Referencejson ReferencejsonDebug ReferencejsonPrettyEncoderCustom Referencekdtreebox2d Referencekdtreebox3d Referencekdtreepoint3d Referencelpack ReferenceluaBinding ReferenceluaCore ReferenceluaProfiler Referencemathlib Referenceparticles Referencequadtree Referencesettings ReferencetcpServer ReferencetimeEvents Referenceutils Reference
calltracer ReferencedateUtils ReferencedebugDraw Referencefilterchain Referenceutils/ - Utility Modulesheatmap ReferencehttpJsonServer ReferenceinteractiveShell ReferencelanguageMap Referenceperf Referencepixellib ReferencesimpleHttpServer ReferencetorqueScriptParser ReferencewsUtils Reference

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 Referencecommonutils

calltracer Reference

Module defined in `lua/common/utils/calltracer.lua`. Records function call graphs using Lua's debug hook, exports to TGF format for visualization in yEd.

Module defined in lua/common/utils/calltracer.lua. Records function call graphs using Lua's debug hook, exports to TGF format for visualization in yEd.


Exports

Functions

M.start()

Start recording function calls via debug.sethook.

M.stop()

Stop recording function calls.

M.save(filename)

Export the recorded call graph as a TGF (Trivial Graph Format) file.

  • Parameters:
    • filename - string - Output file path (.tgf)

M.reset()

Clear all recorded call data.

Internal Notes

  • Uses debug.sethook with "c" (call) events
  • Tracks caller→callee edges (presence only, no call counts)
  • debug.getinfo extracts source/line/name for each stack frame
  • TGF output compatible with yEd graph editor

TestManager Reference

Module defined in `lua/common/testFramework/TestManager.lua`. Unit test manager for BeamNG - collects test functions, executes them, logs results, and outputs JUnit XML reports.

dateUtils Reference

Module defined in `lua/common/utils/dateUtils.lua`. ISO 8601 date parsing and time difference calculations.

On this page

ExportsFunctionsM.start()M.stop()M.save(filename)M.reset()Internal Notes