Skip to content
baenvPublic

About

Pixel-art effects drawn as code: a Claude Code plugin that designs VFX from words or a reference image and exports sprite sheets, Aseprite JSON and gifs.

Topics

Resources

Contributing

Stars

80 stars

Watchers

0 watching

Forks

Repository files navigation

beanfx

Pixel-art effects drawn as code. Describe an effect, and the /beanfx skill for Claude Code draws it in Rust and exports a sprite sheet with JSON that any engine plays.

Heavenly tribulation cast by the staff caster Ten-slash combo on the sword caster The sword caster cuts a space rift, runs into it and steps out of a second rift ahead

Live demo and gallery

Install

/plugin marketplace add baenv/beanfx
/plugin install beanfx@beanfx

Needs Rust (cargo, from https://rustup.rs). The first run builds the beanfx binary into .beanfx/bin/ in your project. Each draft is a small Rust crate that links the skill's kit (drawing, sheet export and checks, sound, preview page).

Use

/beanfx a fire burst, 64x64, side view, one-shot, strong glow
/beanfx path/to/reference.png make this a looping aura

The skill asks about anything the prompt leaves open, then writes the effect to drafts/<name>/:

  • src/main.rs: the effect as code; edit it and run cargo run --release again
  • out/sheets/<name>.png and .json: the sprite sheet and its JSON, the files a game loads
  • out/<name>.html: a preview page that opens with a double click

Two game characters ship with the plugin (a sword caster and a staff caster, side and top-down), so an effect can be drawn on a real sprite: pick "Game character" when the skill asks about a caster.

Play it in a game

import { loadFx, createFx } from "./beanfx.js";   // runtime/beanfx.js in the skill
const fx = createFx(await loadFx("fx/fire_burst.json"), { x: 160, y: 140 });
// each frame: fx.update(dt); fx.draw(ctx);

Phaser reads the JSON with load.aseprite. More: the JSON fields · engines and porting

More

Contributing · Changelog · MIT, see LICENSE

The light layer learns from pixelfx (MIT, Patch); beanfx reimplements it in Rust and ships no pixelfx code.

About

Pixel-art effects drawn as code: a Claude Code plugin that designs VFX from words or a reference image and exports sprite sheets, Aseprite JSON and gifs.

Topics

Resources

Contributing

Stars

80 stars

Watchers

0 watching

Forks

Used by

Contributors

Languages