Skip to main content
Glama
EL4CTEO

Roblox Studio MCP

Breakpoints and runtime inspection

debug

Set conditional breakpoints to capture call stacks and in-scope variables or log Luau expression values. Read snapshots afterward to see exact values at the moment each breakpoint fired.

Instructions

Sets breakpoints that record the stack and variables when they are hit, then reads back what they caught.

These are tracepoints, not a step debugger. A breakpoint fires, captures the call stack and the variables in scope, and lets execution continue; op: "snapshots" returns what was captured. Studio's debugger has to decide whether to resume the instant it stops, and cannot wait for a tool call to come back with an answer, so stepping through code line by line is not possible this way — but 'what was this value when it got here' is, which is usually the actual question.

condition is a Luau expression evaluated where the breakpoint sits, so a breakpoint can fire only on the case that matters — health < 0, player.Name == "someone".

logMessage is ALSO a Luau expression, not a template string: its value is printed when the breakpoint is hit, so write "health=" .. health rather than health={health}. Prose is a syntax error. Read the lines back with console.

Two things about it are measured, not assumed, and both waste your time otherwise. A breakpoint fires ONCE PER RUN, not once per pass: on a five-iteration loop it printed a single line, for the first iteration only. It is not a way to watch a value change inside a loop — to see every pass, have the code itself print and read that with console. And a log expression CANNOT SEE THE LOOP CONTROL VARIABLE: on for index = 1, 5 do, a breakpoint in the body read the body's own locals correctly and index as nil. Wrap values in tostring so a nil prints as "nil" instead of throwing.

A log expression that throws is reported as "Breakpoint ... ignored" in console, NOT here — set still returns Verified, because Studio only compiles the expression once the line is reached.

So the two kinds cost different things: a logMessage breakpoint never stops and gives you one line you composed in advance, while one without it stops briefly and gives you the whole frame — every local and its type, without having to guess beforehand which value would matter. Both give you that for one pass only. Reach for the log when you know what to watch, the capture when you do not.

Only one breakpoint exists per line, so the same line cannot both log and capture.

Put the breakpoint on a line that does something. A return, an end or a bare declaration can verify and then never fire — measured, not guessed: the same breakpoint moved from return squared, tag to the assignment above it went from silent to firing on every pass. If one verifies but catches nothing, suspect the line before suspecting the condition.

Breakpoints belong to the session that holds them. Set them in the editor session BEFORE starting a playtest, since code that already ran cannot be caught retroactively.

Nothing here leaves a thread stopped waiting for you. A capture breakpoint stops for as long as it takes to read the frame and then resumes itself, so a script with one mid-loop still runs to its last line, and the user is never left with a frozen Studio to rescue.

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
opYes'set' adds breakpoints, 'clear' removes one or all, 'snapshots' reads what has been captured, 'exceptions' controls breaking on errors.
lineNoclear only: which line to remove.
modeNoexceptions only: break on every error, only unhandled ones, or never. Defaults to Unhandled.
pathNoclear only: remove breakpoints from this script. Omit to clear everything.
clearNosnapshots only: discard what is returned, so the next read starts fresh.
limitNosnapshots only: how many of the most recent to return.
studioIdNoTarget Studio; omit for the active one.
breakpointsNoset only: breakpoints to add.

Schema Changelog

Changes observed during successful MCP inspections. Dates show when Glama detected each change.

  1. First observedv0.1.8

TDQS

A5/5.0
Behavior5/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

Beyond annotations, the description discloses critical non-obvious behaviors: breakpoints fire once per run, log expressions cannot see loop control variables, log errors surface in console rather than here, set returns Verified even when the expression fails to compile, and breakpoints never leave a thread stopped. This is exactly the kind of behavioral context annotations alone cannot provide.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

The description is long but earns its length: every paragraph addresses a distinct operational risk or decision point, and the first sentence front-loads the core purpose. The structure moves from what it is, to non-obvious limitations, to cost tradeoffs, to practical placement advice, all without filler.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness5/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

For a complex tool with no output schema, the description is remarkably complete. It covers all four operations implicitly through parameter behavior, explains what snapshots return, warns about session scoping, and tells the agent to set breakpoints before playtesting. The only omitted details are the exact snapshot output format and exceptions behavior, both of which are partially covered by the schema and less critical than the behavioral warnings provided.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters5/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Although schema coverage is 100%, the description adds substantial meaning on top: condition must be a Luau expression evaluated in scope, logMessage is also Luau and not a template string, and line placement matters because certain lines can verify but never fire. These are value-add clarifications an agent could not infer from the schema alone.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The opening sentence states a specific action and resource: sets breakpoints that capture stack and variables, then reads back the captures. It goes further and explicitly distinguishes itself from a step debugger, making the tool's purpose crisp and differentiated from siblings like console, inspect, and playtest.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description gives direct selection guidance: use the log form when you know what to watch, and the capture form when you do not. It also tells the agent when this tool is not appropriate (stepping through code) and directs log output to be read through the sibling console.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.

Latest Blog Posts

MCP directory API

We provide all the information about MCP servers via our MCP API.

curl -X GET 'https://glama.ai/api/mcp/v1/servers/EL4CTEO/rbx-studio-mcp'

If you have feedback or need assistance with the MCP directory API, please join our Discord server