Retrodiffusionのロゴ

Retrodiffusion

組織
PlayableIntelligence
retrodiffusion

Retro Diffusion APIを使って、本格的なピクセルアートのスプライト、タイルセット、アニメーションを生成します。専用のピクセルアートモデルとして最適です。ユーザーが「ピクセルアートを生成して」「AIでスプライトを作って」「Retro Diffusionを使って」「rdpk」と言った場合や、コードでスプライト配列を手作業で作るよりも高品質なピクセルアートをすばやく作りたい場合に使います。Retro DiffusionアカウントとRETRODIFFUSION_API_KEY(有料クレジット)が必要です。Phaserを使った2Dゲームの素早いプロトタイプ作成に最適です。

Add to TypingMind

概要

公開者PlayableIntelligence
リポジトリgame-creator
スキル名retrodiffusion
スター
331
フォーク
41
同梱ファイル
1
ライセンスMIT
リンク
  • Markdown形式の指示

    モデルが必要に応じて読み込むSKILL.mdファイルです。関連するリクエストがあったときだけトークンを消費します。

  • どのLLMでも利用可能

    AIスキルはプロバイダー固有のコードではなく、通常のMarkdownなので、GPT、Claude、Gemini、Grok、ローカルモデルで利用できます。

  • 1個の同梱ファイル

    モデルが作業中に読み取れるスクリプト、テンプレート、参考資料です。ファイルは読み取り専用で、実行されることはありません。

  • オープンソース

    PlayableIntelligenceがGitHubで公開しています。インストールする前にソースを確認してください。

インストール

AIスキル「Retrodiffusion」をTypingMindにインストールすれば、どのLLMでも利用できます。SKILL.mdを読み取れる別のAIエージェントに追加することもできます。

1

TypingMindにインストール

TypingMindはGitHubフォルダから直接スキルをインストールします。SKILL.mdを読み取り、リソースファイルをまとめてローカルに保存します。

  1. アプリを開き、「プラグイン」→「スキル」に移動します。
  2. 「GitHubからインストール」を選択します。
  3. 以下のスキルフォルダのURLを貼り付けて確定します。
    https://github.com/PlayableIntelligence/game-creator/tree/main/skills/retrodiffusion
  4. スキルを利用したいチャットごとに、そのスキルを有効にしてください。
「プラグイン」→「スキル」→「スキルを追加」→「GitHubのURLから」を選択し、フォルダのURLを貼り付けて「続行」を押します。
2

別のAIエージェントにインストール

Agent Skills形式を読み取れるAIエージェントなら、このスキルを利用できます。フォルダをそのAIエージェントのスキルディレクトリにコピーしてください。

Claude Code — .claude/skills
git clone --depth 1 https://github.com/PlayableIntelligence/game-creator.git /tmp/game-creator
mkdir -p .claude/skills
cp -r /tmp/game-creator/skills/retrodiffusion .claude/skills/retrodiffusion
コピー後、新しいスキルを読み込むためにClaude Codeを再起動してください。

TypingMindで使用

TypingMindのチャットでRetrodiffusionを有効にするだけで、あとはモデルが対応します。名前と説明がシステムプロンプトに含まれ、関連するリクエストがあると、モデルが指示の全文を自動で読み込みます。手動で呼び出す必要はなく、実際に使用されるまでトークンを消費しません。

関連するリクエストがあるとすぐに、モデルが自動的にRetrodiffusionを読み込みます。

どのAIモデルでも利用可能

AIスキルはプロバイダー固有のコードではなく、通常のMarkdownで書かれた指示です。そのため、Retrodiffusionは作成時に想定されたモデルに縛られません。TypingMindに一度インストールすれば、ご自身のAPIキーを使って、GPT-5、Claude、Gemini、Grok、DeepSeek、Mistral、Llama、またはご自身で実行するローカルモデルで利用できます。

  • 必要なときだけ読み込み

    システムプロンプトには名前と説明だけが含まれます。関連するリクエストが初めてあったときに指示を取得するため、スキルを使わない間は指示の読み込みにトークンを消費しません。

  • チャットの途中でモデルを切り替え

    スキルはコードではなく指示なので、モデルを切り替えてもそのまま使えます。次のモデルも同じSKILL.mdを読み込みます。

スキルの指示

モデルが読み込むSKILL.mdの内容です。スキルはモデルが従う指示なので、インストールする前に確認してください。

Retro Diffusion — True Pixel Art Generation

Generate authentic pixel art sprites, tilesets, and animations from text prompts or reference images using the Retro Diffusion API. Output is true pixel art (clean integer-pixel grids, limited palettes), not blurry diffusion-model output downscaled into pixels — making it the best AI option for shippable 2D game art and fast prototyping.

Paid service. Retro Diffusion requires an account at https://www.retrodiffusion.ai and an API key with credits. Always tell the user this requires a paid Retro Diffusion account before generating anything, and confirm they understand each call deducts from their balance.

Reference Files

FileDescription
api-reference.mdFull API endpoints, models, prompt_style values, response shape, pricing, and error codes

When to Use

  • Quick prototypes — generate dozens of unique sprites in a minute instead of hand-coding 16×16 arrays
  • Polish pass on a working game — replace placeholder shapes with cohesive pixel art that already matches a chosen style
  • Tilesets — wang-style ground/wall sets without manually drawing every transition tile
  • Sprite animations — walk cycles, idle bobs, attacks delivered as transparent GIFs or spritesheets

Choose this over add-assets (code-only pixel art) when: the user wants AI-generated art, has a Retro Diffusion key, or the game needs more visual variety than hand-coded matrices can deliver in a reasonable time. The two skills compose well — Retro Diffusion for hero sprites/tilesets, code-only matrices as a free fallback for quick filler.

Do NOT use this for: 3D models (use meshyai), 3D worlds (use worldlabs), audio (use game-audio), or when the user explicitly wants the all-code procedural pixel art approach (use add-assets).

Authentication

Before prompting the user, check if the key already exists:

bash
test -f .env && grep -q '^RETRODIFFUSION_API_KEY=.' .env && echo "found"

If found, export it with set -a; . .env; set +a and skip the prompt.

If the key is not set, ask the user immediately and explain the cost model:

I'll generate true pixel art with Retro Diffusion — the best dedicated pixel art model for shippable game sprites.

Heads up: this is a paid service. You'll need a Retro Diffusion account with credits. Each image typically costs between $0.015 (RD_FAST) and $0.18 (RD_PRO). Get a key in 60 seconds:

  1. Sign up at https://www.retrodiffusion.ai
  2. Buy credits (smallest pack is fine for prototyping)
  3. Account → API → Generate API key

Paste your key like: RETRODIFFUSION_API_KEY=rdpk-... (It will be saved to .env and redacted from this conversation.)

Or type "skip" to fall back to free hand-coded pixel art via /add-assets.

If the user provides a key, save it to .env and use it via set -a; . .env; set +a && node scripts/retrodiffusion-generate.mjs ....

If the user skips, stop and hand off to /add-assets — do not silently degrade to a different art style without telling them.

CLI Script — scripts/retrodiffusion-generate.mjs

Zero-dependency Node.js script. Handles all six modes: generate, img2img, animate, tileset, edit, and balance.

Generate (text-to-pixel-art)

bash
# Single 64×64 sprite, RD_FAST (cheapest)
RETRODIFFUSION_API_KEY=<key> node scripts/retrodiffusion-generate.mjs \
  --mode generate \
  --prompt "a cute green slime with big eyes" \
  --model RD_FAST --style retro \
  --width 64 --height 64 \
  --output public/assets/sprites/ --slug slime

# Higher quality with RD_PRO (flat $0.18, supports up to 256×256)
RETRODIFFUSION_API_KEY=<key> node scripts/retrodiffusion-generate.mjs \
  --mode generate \
  --prompt "a heroic knight, full body, side view" \
  --model RD_PRO --style fantasy \
  --width 128 --height 128 \
  --output public/assets/sprites/ --slug knight

# Transparent background for game sprites
RETRODIFFUSION_API_KEY=<key> node scripts/retrodiffusion-generate.mjs \
  --mode generate --prompt "a treasure chest, closed" \
  --model RD_FAST --style game-asset \
  --width 64 --height 64 --remove-bg \
  --output public/assets/sprites/ --slug chest

# Seamless tiling texture (e.g., grass, water)
RETRODIFFUSION_API_KEY=<key> node scripts/retrodiffusion-generate.mjs \
  --mode generate --prompt "lush grass texture, top down" \
  --model RD_PLUS --style top-down \
  --width 64 --height 64 --tile-x --tile-y \
  --output public/assets/tiles/ --slug grass

# Estimate cost before paying for it
RETRODIFFUSION_API_KEY=<key> node scripts/retrodiffusion-generate.mjs \
  --mode generate --prompt "..." --check-cost

Image-to-Image (refine a reference)

bash
RETRODIFFUSION_API_KEY=<key> node scripts/retrodiffusion-generate.mjs \
  --mode img2img \
  --image ./concept-art/hero-sketch.png \
  --prompt "a heroic knight in shining armor" \
  --model RD_FAST --style retro \
  --width 64 --height 64 --strength 0.75 \
  --output public/assets/sprites/ --slug hero

--strength controls how much the AI deviates from the input (0 = identical, 1 = ignore input). 0.5–0.8 is the useful range.

Animations (walk cycles, idles, attacks)

bash
# Walk cycle — returns spritesheet PNG or transparent GIF (style-dependent)
RETRODIFFUSION_API_KEY=<key> node scripts/retrodiffusion-generate.mjs \
  --mode animate \
  --prompt "a knight walking" \
  --model RD_PRO --style walk-cycle \
  --width 64 --height 64 \
  --output public/assets/sprites/ --slug knight-walk

# Idle bob from an existing character
RETRODIFFUSION_API_KEY=<key> node scripts/retrodiffusion-generate.mjs \
  --mode animate --image public/assets/sprites/knight.png \
  --prompt "knight idle breathing" --style idle \
  --output public/assets/sprites/ --slug knight-idle

Animation styles cost $0.07–$0.25 depending on type. See api-reference.md for the full style list.

Tilesets

bash
# Wang-style tileset (auto-tiling ground/wall sets)
RETRODIFFUSION_API_KEY=<key> node scripts/retrodiffusion-generate.mjs \
  --mode tileset \
  --prompt "stone dungeon floor, mossy" \
  --model RD_PLUS --style wang-tile \
  --width 96 --height 96 \
  --output public/assets/tiles/ --slug dungeon-floor

# Single detailed tile
RETRODIFFUSION_API_KEY=<key> node scripts/retrodiffusion-generate.mjs \
  --mode tileset --prompt "wooden bridge plank" --style single-tile \
  --width 64 --height 64 --output public/assets/tiles/ --slug bridge

Edit (progressive refinement)

Flat $0.06 per edit. Use to tweak a generated sprite without re-rolling from scratch.

bash
RETRODIFFUSION_API_KEY=<key> node scripts/retrodiffusion-generate.mjs \
  --mode edit --image public/assets/sprites/knight.png \
  --prompt "give the knight a red cape" \
  --output public/assets/sprites/ --slug knight-red

Balance check

bash
RETRODIFFUSION_API_KEY=<key> node scripts/retrodiffusion-generate.mjs --mode balance

Model Selection Guide

ModelCostSizesBest for
RD_FAST$0.015–0.0464×64 to 384×384Bulk prototyping, simple sprites, items
RD_PLUS$0.025–0.0816×16 to 192×192Tilesets, top-down, watercolor, Minecraft-style
RD_PRO$0.18 flat64×64 to 256×256Hero sprites, isometric scenes, polish pass (17+ styles, supports up to 9 reference images)
RD_MINIvariesvery smallRoutes to PLUS/FAST for tiny pickups

Default to RD_FAST for prototyping. Upgrade individual hero sprites to RD_PRO when the prototype is shipping.

See api-reference.md for the complete per-model prompt_style list.

Prompt Engineering for Pixel Art

Good prompts are short, specific about silhouette and palette, and call out the perspective:

GoalPromptWhy
Game character"a cute green slime, big eyes, side view"Single subject, perspective named
Item"a glowing red potion bottle"Specific shape + color
Tile"lush grass texture, top down, seamless"Perspective + tiling intent
Enemy"a skeleton warrior, hunched, side view"Silhouette cue ("hunched")

Avoid:

  • Multiple subjects in one prompt — generate separately and composite in-game
  • Abstract concepts ("the feeling of dread") — describe the visual instead
  • Mismatched perspective ("top-down knight, side view") — pick one

Integration with Phaser Games

Retro Diffusion outputs are normal PNGs — they slot directly into Phaser's loader.

js
// In a preload scene:
this.load.image('slime', 'assets/sprites/slime.png');
this.load.spritesheet('knight-walk', 'assets/sprites/knight-walk.png', {
  frameWidth: 64,
  frameHeight: 64,
});

// In create():
const slime = this.physics.add.sprite(100, 100, 'slime');
this.anims.create({
  key: 'knight-walk',
  frames: this.anims.generateFrameNumbers('knight-walk', { start: 0, end: 7 }),
  frameRate: 12,
  repeat: -1,
});

Pixel-perfect rendering — when using AI pixel art, configure the Phaser game with crisp scaling so sprites stay sharp:

js
// In main.js, Phaser config:
const config = {
  type: Phaser.AUTO,
  pixelArt: true,           // disables antialiasing, preserves hard pixel edges
  roundPixels: true,        // snaps sprite positions to integers
  scale: { mode: Phaser.Scale.FIT, autoCenter: Phaser.Scale.CENTER_BOTH },
  // ...
};

Without pixelArt: true, the browser will smooth-scale the PNGs and the pixel-art look is lost.

Spritesheet Slicing

Animation styles return either a transparent GIF or a horizontal spritesheet (style-dependent — check the output PNG dimensions). For spritesheets, infer frameWidth = imageWidth / frameCount and load with this.load.spritesheet(). The .meta.json file written next to each output records the requested width/height so frame count is recoverable.

Cost Discipline

Every call costs real money from the user's balance. Apply these defaults to avoid waste:

  1. Use --check-cost first when generating at unfamiliar sizes or with RD_PRO.
  2. Default to RD_FAST + 64×64 for prototypes. Only upgrade specific hero sprites.
  3. Use --seed when iterating on a prompt — same seed + same prompt = same image, so you can A/B test prompt edits without re-rolling random variations.
  4. Cache outputs — generated PNGs are committed to public/assets/sprites/. Never regenerate an asset that already exists unless the user asked for a new variant.
  5. Run --mode balance before a big batch so the user sees their remaining credits.

Output Convention

public/assets/sprites/
  slime.png            # generated image
  slime.meta.json      # prompt, model, style, cost, balance, timestamps
  knight-walk.png      # animation spritesheet or GIF
  knight-walk.meta.json
public/assets/tiles/
  grass.png            # tiling texture
  grass.meta.json

Always write a .meta.json next to each PNG so the prompt and seed are recoverable for later regeneration.

Troubleshooting

ProblemCauseFix
RETRODIFFUSION_API_KEY not setKey missingAsk the user for their key (https://www.retrodiffusion.ai → Account → API). Save to .env.
HTTP 401 UnauthorizedWrong header or invalid keyHeader must be X-RD-Token: <key>, NOT Authorization: Bearer. Verify the key on the dashboard.
HTTP 400 "insufficient credits"Account balance is emptyTell the user to top up at the dashboard before retrying. Run --mode balance to confirm.
Sprite looks blurry in PhaserBrowser is smooth-scaling the PNGSet pixelArt: true and roundPixels: true in the Phaser config.
Output ignores prompt detailsPrompt is being auto-expanded into something differentTry --bypass-prompt-expansion to send the prompt verbatim.
Tileset edges don't matchStyle isn't a wang/tile styleUse --style wang-tile for auto-tiling sets, or --tile-x --tile-y for seamless single textures.
img2img output ignores referenceStrength too highLower --strength to 0.4–0.6. Strength 0 keeps the input; strength 1 ignores it.
Inconsistent style across batchDifferent seeds and slight prompt variationPin --seed and reuse the exact same prompt structure for sibling sprites (same character family).

Checklist

  • User informed this is a paid service — Retro Diffusion account + credits required
  • RETRODIFFUSION_API_KEY checked in .env or env, prompted if missing
  • Model + style chosen for the budget (RD_FAST for prototyping, RD_PRO for hero sprites)
  • --check-cost used for the first call at any new size
  • Prompt is specific about subject, perspective, and silhouette
  • --seed pinned when generating siblings (e.g., walk + idle of the same character)
  • --remove-bg used for game sprites (transparent PNG)
  • --tile-x/--tile-y used for textures, --style wang-tile for auto-tiling
  • PNG written to public/assets/sprites/ (or tiles/) with .meta.json alongside
  • Phaser config has pixelArt: true and roundPixels: true
  • Spritesheet frameWidth/frameHeight matches the requested width/height
  • User shown remaining balance after the batch

同梱ファイル

スキルが読み込まれている間、モデルは必要に応じてこれらを読み取ります。読み取り可能なファイルとして提供され、実行されることはありません。

よくある質問

AIスキル「Retrodiffusion」では何ができますか?

Retro Diffusion APIを使って、本格的なピクセルアートのスプライト、タイルセット、アニメーションを生成します。専用のピクセルアートモデルとして最適です。ユーザーが「ピクセルアートを生成して」「AIでスプライトを作って」「Retro Diffusionを使って」「rdpk」と言った場合や、コードでスプライト配列を手作業で作るよりも高品質なピクセルアートをすばやく作りたい場合に使います。Retro DiffusionアカウントとRETRODIFFUSION_API_KEY(有料クレジット)が必要です。Phaserを使った2Dゲームの素早いプロトタイプ作成に最適です。

TypingMindでRetrodiffusionを使うメリットは何ですか?

一度インストールすれば、どのモデルでも使えるからです。Retrodiffusionはプロバイダー固有のコードではなく、通常のMarkdownで記述されているため、同じスキルをGPT-5、Claude、Gemini、Grok、ローカルモデルで利用できます。チャットの途中でモデルを切り替えても、そのまま使い続けられます。TypingMindは自分のAPIキーで動作するため、シート単位のサブスクリプションではなく、プロバイダーに直接料金を支払います。スキルとチャットは自分のストレージに保持されます。

TypingMindにRetrodiffusionをインストールするにはどうすればよいですか?

TypingMindで「プラグイン」→「スキル」→「GitHubからインストール」を開き、https://github.com/PlayableIntelligence/game-creator/tree/main/skills/retrodiffusionを貼り付けてください。TypingMindがSKILL.mdを読み込み、関連ファイルをまとめて、チャットごとに有効にできるスキルとしてインストールします。

Retrodiffusionを使えるAIモデルはどれですか?

TypingMindに接続したどのモデルでも利用できます。AIスキルはプロバイダー固有のコードではなく、通常のMarkdownで書かれた指示です。そのため、GPT、Claude、Gemini、Grok、ローカルモデルのいずれも、リクエストの内容がこのスキルの用途に合ったときに、このスキルを読み込めます。

Retrodiffusionで使えるAIモデルの数に制限はありますか?

数に制限はありません。スキルに対応したモデルであれば、GPT、Claude、Gemini、Grok、DeepSeek、Mistral、Llamaなど、どのモデルでもRetrodiffusionを利用できます。すべてTypingMind上で、自分のAPIキーを使って利用できます。

AIスキル「Retrodiffusion」は無料ですか?

はい。PlayableIntelligenceがMITライセンスのもとでGitHubに公開しています。ご利用のAIプロバイダーに支払うのは、使用したトークンの料金だけです。

AIスキルとは何ですか?

AIスキルは、特定のタスクの実行方法をAIモデルに教える、再利用可能な指示のセットです。オープンなAgent Skills形式に従い、名前と説明を含むSKILL.mdファイルに加え、モデルが必要とするスクリプト、テンプレート、参照ファイルで構成されます。モデルはリクエストがスキルに合致したときだけ指示を読み込むため、インストール済みのスキルも、使うまでは費用がかかりません。

AIスキルは、プラグインやMCPサーバーとどう違いますか?

プラグインやMCPサーバーは、モデルが呼び出せる新しいツールを提供します。ツールとは、どこかで実行され、結果を返すコードです。一方、AIスキルは、タスクへの取り組み方、従うべき手順、望ましい出力の例といった知識や進め方をモデルに伝えます。スキルは通常のMarkdownで記述されているため、サーバー、APIキー、実行環境は不要で、どのモデルでも利用できます。

すべて見る

今すぐ自分専用のAIワークスペースを作成

ニュースレターに登録すると、新機能や今後のプレゼント企画のお知らせが届きます👇