Skip to content
Adrien Givry edited this page Apr 9, 2025 · 5 revisions

Description

Lua script profiling using Tracy.

Variables

This usertype has no variables

Constructors

This usertype has no constructors

Functions

Name Input Output Description
ZoneBegin Starts a profiling zone
ZoneBeginN string: name
Starts a profiling zone with a custom name
ZoneText string: text
Sets a text for the current zone
Message string: text
Sends a message
ZoneName string: text
Sets a zone name on a per-call basis
ZoneEnd Ends the current profiling zone

Operators

This usertype has no operators

Example

local Test = {}

function Test:OnUpdate(deltaTime)
    tracy.ZoneBegin()

    for i = 1, 1000000 do
        local a = math.random(1, 100)
        local b = math.random(1, 100)
        local c = a + b
    end

    tracy.ZoneEnd()
end

return Test
Clone this wiki locally