MCP // ROBLOX STUDIO

Roblox Studio MCP for fire, smoke and explosion effects

Connect your agent to Spatial Compiler's hosted MCP server to compile 1024 px fire, smoke, explosion and dust flipbooks for Roblox Studio. Upload the image and set a ParticleEmitter to an 8 x 8 grid by hand.

  • Godot 4 Available
  • Unity Manual setup
  • Unreal Engine Manual setup
  • Roblox Studio Manual setup
  • three.js Available

A draft compile is from $0.05, and new accounts start with $5 of usage.

FIREFINAL
First frame of the fire bake
Fire, 4.1 x 7.0 m, compiled with Spatial Compiler. Spec →

01 // WHAT YOU GET

A flipbook sized for Roblox

MCP is the protocol your agent uses to call tools. Spatial Compiler's server runs hosted, outside Roblox Studio, and your agent calls it from your MCP client.

Roblox limits uploaded images to 1024 x 1024 px, and the default compile is 2048 px. Ask your agent to compile with export.tile_px = 128, which keeps the 8 x 8 grid of 64 frames on one 1024 px image.

A ParticleEmitter takes one texture and no custom shader, so also ask for export.pack to write the light from above into RGB and opacity into alpha. You get one RGBA image with the smoke shaded from above. Flame goes on a second emitter, from an image on black of the flame color (main_colour.png) times its brightness (the squared alpha of main_neg.png). That image is normalized to the clip's peak, so its emitter's Brightness goes to scales.emit_max_hdr from layout.json.

02 // HOW TO

Set up the emitter in Roblox Studio

  1. Add the hosted server, https://spatialcompiler.dev/mcp, to your MCP client, sign in, and ask your agent for the effect at export.tile_px = 128, packed into one RGBA image.
  2. Upload the PNG as an image asset in Roblox Studio and copy its asset id.
  3. Insert an Attachment in a Part and a ParticleEmitter in the Attachment, then set Texture to the asset id and FlipbookLayout to Grid8x8.
  4. For the fire loop, set FlipbookMode to Loop and FlipbookFramerate to 30, the Roblox maximum, which plays the 64 frames in 2.13 s. For an explosion, set it to OneShot so the frames play once, evenly spaced over Lifetime, and ask for the compile with export.pacing = "even" to match.
  5. For flame glow, put the flame image on its own emitter on the same Attachment, with LightEmission 1, LightInfluence 0 and Brightness at scales.emit_max_hdr. For smoke, keep LightEmission at 0 and LightInfluence at 1 so the scene's light darkens it.
  6. For a one-shot, set Rate to 0 on each emitter and call Emit(1) on both from the same script call. The shared call lines up their first frames, and identical fixed settings keep each flame on its smoke: Speed 0, SpreadAngle 0, the same Lifetime, Size, Orientation and Rotation, one fixed FlipbookFramerate and FlipbookStartRandom off.
mcp.json · hosted server
{
  "mcpServers": {
    "spatial-compiler": {
      "type": "http",
      "url": "https://spatialcompiler.dev/mcp"
    }
  }
}
Explode (Script)
-- Script inside the Part; the smoke and flame ParticleEmitters share its Attachment
local part = script.Parent
local attachment = part:FindFirstChildOfClass("Attachment")

local function explode()
	for _, emitter in attachment:GetChildren() do
		if emitter:IsA("ParticleEmitter") then
			emitter:Emit(1) -- one call, so both start on frame 0
		end
	end
end

-- call explode() from your own event, here the first touch
part.Touched:Once(explode)

03 // REAL OUTPUT

Real compiles at full size

The fire loops every 2 s and the impact plays once in 2.0 s. At export.tile_px = 128 each frame is 128 px across.

IMPACTFINAL
First frame of the impact bake
Impact, 3.5 x 2.8 m, compiled with Spatial Compiler. Spec →

05 // FAQ

Roblox Studio MCP questions

All questions →

README.ROBLOX_STUDIO
Does Roblox Studio have an MCP server for effects?

Roblox offers an MCP server for Studio and Spatial Compiler runs as a separate hosted server in your MCP client to compile flipbooks.

How do I set up a Roblox MCP for fire and explosion effects?

Add the hosted Spatial Compiler URL to your MCP client, sign in and ask for export tile size 128 to fit 1024 px.

How do I set the rows and columns of a Roblox particle flipbook?

Set FlipbookLayout to Grid8x8 on the ParticleEmitter to match a default 64 frame compile or use Grid2x2, Grid4x4 or Custom.

How do I play a Roblox explosion flipbook only once?

Compile with even pacing, set FlipbookMode to OneShot, set Rate to 0 and call Emit with 1 when the explosion triggers.

Why is my Roblox MCP connection not working?

Restart your MCP client after adding the server and finishing browser login. Check for 401 invalid key or 429 hourly limit errors.

Compile your first effect

You pay per compile and see the price before it runs. New accounts start with $5 of usage.

All effects, guides and explainers →