Skip to content

API

Action

Methods

.new

DebugTools.Action.new(name: string, description: string?, action: (any...) -> ()), arguments: { Type: "string" | "number" | "boolean" | "Player", Name: string?, Default: any?, Options: { any }? })

Defines a new action, for more information check out Overview.

Example Usage
DebugTools.Action.new("Test Action", nil, function(player: Player)
    print(`Player '{player.DisplayName}' executed an action!`)
end, {
    {
        Type = "Player",
        Name = "Player",
    },
})

Authorization

Properties

PlayerAuthorized

DebugTools.Authorization.PlayerAuthorized: Signal<Player>

Fires whenever player gets authorized and is allowed to use DebugTools.

This is a server only property.


PlayerAuthorizationLost

DebugTools.Authorization.PlayerAuthorizationLost: Signal<Player>

Fires whenever player looses the rights to use DebugTools.

This is a server only property.

Methods

:IsPlayerAuthorizedAsync

DebugTools.Authorization:IsPlayerAuthorizedAsync(player: Player): boolean

Returns true if player is authorized to use DebugTools, this function can yield if player is in the process of being authorized.

Danger

This function can yield.

This is a server only method.


:SetAuthorizationCallback

DebugTools.Authorization:SetAuthorizationCallback(callback: ((player: Player) -> boolean)?): ()

Defines a new authorization callback, if callback is missing the default authorization method is used.

When changing the authorization callback all of the players in the server will be reauthorized again.

This is a server only method.

Console

Methods

:AddMessage

DebugTools.Console:AddMessage(text: string, textType: Enum.MessageType, serverSided: boolean): ()

Adds a message to internal DebugTools console which won't print anything to Robloxes output, the messages will appear only within GetOutputLog and Output widget.

This is a client only method.


:GetOutputLog

DebugTools.Console:GetOutputLog(): string

Returns a string with last 400 messages logged to the internal DebugTools console.

This is a client only method.

Widget

Methods

.new

DebugTools.Widget.new(widgetName: string, widgetCreateFunction: (parent: ScreenGui) -> () -> ())): ()

Defines a new widget, for more information check out Overview.

This is a client only method.


:GetAll

DebugTools.Widget:GetAll(): { [string]: { Mounted: boolean, ScreenGui: ScreenGui? } }

Returns all of the defined widgets.

This is a client only method.


:Hide

DebugTools.Widget:Hide(widgetName: string): ()

Hides a widget.

This is a client only method.


:Show

DebugTools.Widget:Show(widgetName: string): ()

Shows a widget.

This is a client only method.


:IsVisible

DebugTools.Widget:IsVisible(widgetName: string): boolean

Returns true if widget is visible.

This is a client only method.


:SwitchVisibility

DebugTools.Widget:SwitchVisibility(widgetName: string): ()

Switches between the current visibility state of a widget, if it's hidden then the widget will be shown and vice versa.

This is a client only method.

Networking

Methods

:SendMessage

DebugTools.Networking:SendMessage(topic: string, ...): ()

If used from client side, it will send a message to the server.

If used from server side, it will send a message to all of the authorized players in the server.


:SendMessageToPlayer

DebugTools.Networking:SendMessageToPlayer(player: Player, topic: string, ...): ()

Works similarly to SendMessage but the message will be only sent to just one player.

This is a server only method.


:SubscribeToTopic

DebugTools.Networking:SubscribeToTopic(topic: string, callback: (...any) -> ...any): ()

Subscribes to a message with a given topic, will trigger a callback with whatever parameters were passed when the message was sent.

Tab

Methods

.new

DebugTools.Tab.new(name: string, constructorFunction: (parent: Frame) -> () -> ())

Defines a new tab, for more information check out Overview.

This is a client only method.

IMGui

Methods

.applyFrameStyle

DebugTools.IMGui.applyFrameStyle(instance: Frame | TextButton): ()

Applies IMGui styling to a given Instance.

This is a client only method.


.applyTextStyle

DebugTools.IMGui.applyTextStyle(instance: TextLabel | TextButton): ()

Applies IMGui styling to a given Instance.

This is a client only method.


:Connect

DebugTools.IMGui:Connect(parent: GuiBase, tickLoop: () -> ()): () -> ()

Mounts IMGui under the specified parent instance. The parent and all created instances are fully managed by the IMGui system, so modifying them outside of IMGui’s internal logic is not recommended. All UI logic should be implemented inside the tickLoop function.

Returns a destructor function that unmounts the interface from the parent and performs cleanup.

This is a client only method.


:NewWidgetDefinition

DebugTools.IMGui:NewWidgetDefinition(identifier: string, definition: WidgetDefinition): ()

Defines a new IMGui widget that can be accessed by IMGui:identifier.

Example Usage
IMGui:NewWidgetDefinition("Label", {
    Construct = function(self: ImguiLabel, parent: GuiObject, text: string)
        local textInstance: TextLabel = Instance.new("TextLabel")
        textInstance.Name = `Label ({self.ID})`
        textInstance.AutomaticSize = Enum.AutomaticSize.XY
        textInstance.Text = text
        textInstance.RichText = true
        textInstance.BackgroundTransparency = 1
        textInstance.BorderSizePixel = 0

        IMGui.applyTextStyle(textInstance)

        textInstance.Parent = parent

        return textInstance
    end,

    Update = function(self: ImguiLabel, text: string)
        self.TopInstance.Text = text
    end,
})

This is a client only method.


:GetTick

DebugTools.IMGui:GetTick(): number

Returns the current tick of the active tick loop. The value is monotonically increasing.

This is a client only method.


:GetConfig

DebugTools.IMGui:GetConfig(): any

Returns a table with current IMGui config.

This is a client only method.