Game particle effects in Claude Code
Connect Claude Code to the ParticleFX MCP server with one command, then have it build, check and export a looping fireball as a Godot 4 SpriteFrames into your project.
Claude Code already has your game open: it reads the scenes, writes the scripts and runs the build. With the ParticleFX MCP server it can make the effects as well. It starts from one of the library effects or a blank canvas, edits it, looks at real renders of its own work, and exports a spritesheet with the data file your engine reads, then moves the files into place itself.
Connect Claude Code
- Sign in at particlefx.studio and make an API key on your billing page. Any account can, the free one included. The key starts with
pfx_live_, is shown once, and can be revoked there at any time. - Add the server from a terminal in your project. Without
--scopeit is added for you, in this project only;--scope usermakes it available in every project. - Run
claude mcp list, or/mcpinside a session: particlefx should show as connected, with its tools.
export PFX_API_KEY=pfx_live_your_key
claude mcp add --transport http particlefx https://mcp.particlefx.studio/mcp \
--header "Authorization: Bearer $PFX_API_KEY"To share the setup with your team without sharing a key, add it with --scope project. That writes .mcp.json in the project root, which you can commit; Claude Code fills in ${PFX_API_KEY} from each person's environment, and each person approves the server once.
{
"mcpServers": {
"particlefx": {
"type": "http",
"url": "https://mcp.particlefx.studio/mcp",
"headers": { "Authorization": "Bearer ${PFX_API_KEY}" }
}
}
}You can also skip the key: add the server without the --header line, then run /mcp in a session (or claude mcp login particlefx in a terminal) and authenticate. Claude Code opens particlefx.studio, you sign in and allow the connection, and calls are billed to that account. Use one or the other: with a header set, a rejected key shows as a failed connection rather than offering sign-in.
Claude Code asks before it runs a tool it has no permission rule for. To stop it asking for each ParticleFX tool, answer "Yes, don't ask again", or add the permission rule mcp__particlefx, which covers every tool of the server.
Example: a looping fireball for Godot 4
Ask in your own words. This prompt names the effect and the folder, so the files land where your scenes expect them:
Use the particlefx MCP server. Start from the Pixel Fireball library effect and name it
fireball. Make the trail a bit longer, check the render, then export it as a spritesheet
with Godot 4 SpriteFrames data, transparent background, 30 fps. Put fireball.png and
fireball.tres in res://fx/ and fix the texture path in the .tres.What happens, tool by tool:
list_presetsfinds Pixel Fireball (pixel-arcade/fireball) in the library.create_effectcopies it into your account asfireball. From here on it is your effect: it shows up on My effects andopen_in_studiogives a link to it.edit_effectapplies the change you asked for as edit ops, the same edit language the studio and its own agent use.render_previewreturns a labelled contact sheet of moments across the loop. Claude Code looks at it, and edits again if something reads badly.analyze_effectchecks that the loop closes and counts particles over it.export_effectwithformat: "sheet",sheet_meta: "godot",transparent: trueandfps: 30renders the real thing at full size and returns a download link that works for 1 hour.- Claude Code downloads the zip and unpacks it with
curlandunzip, intofx/. The zip holdsfireball.pngandfireball.tres.
The .tres is a SpriteFrames resource with one animation named fireball, looping at the exported 30 fps. It points at res://fireball.png, which is why the prompt asks for the path fix; after it, the texture line reads:
[ext_resource type="Texture2D" path="res://fx/fireball.png" id="1_tex"]Playing it is a few lines. Claude Code can write this part too:
extends Node2D
const FIREBALL := preload("res://fx/fireball.tres")
func spawn_fireball(at: Vector2) -> AnimatedSprite2D:
var fx := AnimatedSprite2D.new()
fx.sprite_frames = FIREBALL
fx.position = at
add_child(fx)
fx.play("fireball")
return fx- Pixel art: set Texture Filter to Nearest on the node, or project-wide under Rendering, Textures.
- One-shot effects (a hit, an explosion): call
FIREBALL.set_animation_loop("fireball", false)once and connectanimation_finishedtoqueue_free. - More on the resource and the free route without it: Godot 4 engine guide.
What it costs
Connecting costs nothing, and neither do searching the library, reading the reference, analysing an effect, or any edit after the first. Paid steps use builds, the same builds as on the website:
- Create the effect from a library preset (
create_effect): 1 build. - Edits and the loop check (
edit_effect,analyze_effect): free. - Previews (
render_preview): the first 20 of each UTC day free, then 1 build per 4, at most 200 a day. - Export (
export_effect, Godot SpriteFrames): 1 build, and the Godot data file needs a paid plan.
So this example takes 2 builds of work if the previews stay inside the free ones: 1 for the new effect and 1 for the export. The free sign-up and daily builds are for the website and never pay for MCP calls. On a free account and on Starter, MCP calls are paid from pack builds, from $4.99 for 150 that never expire. Creator at +50%, Studio at +25%, Studio Max one for one can spend plan builds instead, and fall back to pack builds when those run out. Work that fails on our side is refunded.
The Godot data file is a plan feature, as in the studio: any plan, from $7.99 a month (Starter), unlocks it. Without a plan the same build exports a GIF, WebP, APNG, PNG frames, or the sheet as an image only (sheet_meta: "none").
If you would rather our own effects agent did the creative work, build_effect takes a description and costs 1 build (Basic) or 10 (Pro). Full price list: MCP tools and keys, limits and billing.
Next
Every tool and its parameters are in the tools reference. Setup for the other clients is on Coding agents, and any of the free effects can be the starting point for Claude Code.
Questions
How do I add the ParticleFX MCP server to Claude Code?
Run claude mcp add --transport http particlefx https://mcp.particlefx.studio/mcp --header "Authorization: Bearer pfx_live_your_key" with a key from your billing page, or leave out the header and authenticate with your ParticleFX account from /mcp inside Claude Code.
Can Claude Code put the exported files straight into my project?
Yes. The hosted server returns each export as a download link that works for 1 hour, and Claude Code downloads and unpacks it with its own shell into whatever folder you name.
Does Claude Code see the effect before it exports?
Yes. render_preview returns an image of moments across the loop, rendered by the same renderer as the studio, and analyze_effect reports whether the loop closes. Claude Code looks at both before it calls the effect done.
Can I use the effects in a commercial game?
Yes. Exported effects, including ones started from the library or changed by your agent, may be used in any project, commercial games included, with no credit required. Reselling the library itself as an effect pack is not allowed.
