Agent skill

Pixi Vn Minigames

by DRincs-Productions in DRincs-Productions/pixi-vn

A skill your agent uses when adding a minigame (snake, quiz, puzzle, timing/reaction game, ...) to a Pixi'VN visual novel — the useMinigame lifecycle hook pattern, using PixiJS directly on its own…

LGPL-2.1Auto-check passedEducation

Install Pixi Vn Minigames

skills CLI
$ npx skills add DRincs-Productions/pixi-vn --skill pixi-vn-minigames -a claude-code

Project install by default; add -g for ~/.claude/skills/.

GitHub CLI
$ gh skill install DRincs-Productions/pixi-vn pixi-vn-minigames --agent claude-code

Project scope by default; add --scope user for a personal install. Needs GitHub CLI 2.90.0 or later (public preview).

Manual copy
$ git clone --depth 1 https://github.com/DRincs-Productions/pixi-vn.git skills-src && mkdir -p .claude/skills && cp -r skills-src/skills/minigames .claude/skills/pixi-vn-minigames && rm -rf skills-src

Use ~/.claude/skills/ instead of .claude/skills for a personal install. The folder must contain SKILL.md.

Claude Code skills documentation · loads skills from .claude/skills/

Facts

Skill name
pixi-vn-minigames
GitHub stars
149
Token cost
~2.9k tokens
SKILL.md length
1,089 words
Files
1
Skills in repo
13
Repo updated
First seen
Licence
LGPL-2.1

At a glance

A skill your agent uses when adding a minigame (snake, quiz, puzzle, timing/reaction game, ...) to a Pixi'VN visual novel — the useMinigame lifecycle hook pattern, using PixiJS directly on its own…

  • Adding a minigame (snake
  • SKILL.md covers When to use this skill, Core mental model, Routing structure: one route… and The useMinigame lifecycle hook, plus 3 more sections
  • Instructions only: no scripts, shell commands, URLs or credentials in SKILL.md
  • Timing/reaction game

What it does

Pixi Vn Minigames is an agent skill from DRincs-Productions/pixi-vn. Use when adding a minigame (snake, quiz, puzzle, timing/reaction game, ...) to a Pixi'VN visual novel — the useMinigame lifecycle hook pattern, using PixiJS directly on its own layer instead of gameLayer, hotkeys for controls, linking the minigame to a route, and why saving/restoring minigame state is the developer's own responsibility.

Its SKILL.md is about 2.9k tokens, which your agent loads only when the skill is triggered. It is a single SKILL.md file with no bundled scripts.

It sits in Education, covering Creative writing and fiction. It works with React. The repository describes itself as: Create visual novels with a modern 2D rendering engine and your favorite JavaScript framework.

When your agent uses it

  • Adding a minigame (snake
  • Timing/reaction game
  • ...) to a PixiVN visual novel — the useMinigame lifecycle hook pattern
  • Using PixiJS directly on its own layer instead of gameLayer

Example prompts

  • “/pixi-vn-minigames”

What it can do on your machine

Read from SKILL.md and the folder at commit 01c19cb. It shows what the files ask for, not the result of running them.

  • Tool permissions

    Pre-approves nothing: there is no allowed-tools line, so your agent's usual permission prompts apply.

    From allowed-tools in the SKILL.md frontmatter.

  • Runs code

    No scripts in the folder and no shell commands in SKILL.md (its code samples are typescript).

    From the folder's file list and the shell code blocks in SKILL.md.

  • Network

    Links to these hosts (documentation or services it may open):

    • pixi-vn.com
    • tanstack.com

    From URLs in SKILL.md, links to its own repository left out.

  • Credentials

    Names no API keys, tokens, secrets or passwords.

    From names ending in _API_KEY, _TOKEN, _SECRET, _KEY or _PASSWORD in SKILL.md.

Context cost

Pixi Vn Minigames loads about 2.9k tokens when it runs. Until then it costs about 90 tokens; SKILL.md has 1,089 words of instructions outside code blocks.

Always · name and description, kept in context so the agent knows when to use it
~90
When it runs · the whole SKILL.md, loaded when a task matches
~2.9k

Estimates: characters ÷ 4, the usual rule of thumb; real counts depend on the model's tokenizer. Scripts and assets cost tokens only if the agent reads them.

Safety

Auto-check passed

The automated check found no risky patterns in SKILL.md.

Automated static check — not a guarantee. Review scripts before installing. It scans the text of SKILL.md for risky patterns (piping downloads into a shell, reading credential files, hidden Unicode, destructive commands); files beside SKILL.md are not scanned.

SKILL.md

The full file from DRincs-Productions/pixi-vn at commit 01c19cb, republished under its LGPL-2.1 licence (© DRincs-Productions). 1,089 words, ~2,915 tokens.

Download SKILL.mdSave it as .claude/skills/pixi-vn-minigames/SKILL.md (or your agent's skills folder).
name
pixi-vn-minigames
description
Use when adding a minigame (snake, quiz, puzzle, timing/reaction game, ...) to a Pixi'VN visual novel — the `useMinigame` lifecycle hook pattern, using PixiJS directly on its own layer instead of `gameLayer`, hotkeys for controls, linking the minigame to a route, and why saving/restoring minigame state is the developer's own responsibility.

Pixi'VN Minigames

Official docs: pixi-vn.com/start/minigames.

Pixi'VN has no dedicated minigame API — a minigame is just PixiJS code (and, for its HUD/UI, a regular framework UI) wired into the game through the same primitives used elsewhere: canvas layers, hotkeys, and navigation. This skill is about how those pieces fit together for a minigame specifically, not about introducing new APIs.

When to use this skill

Load this skill whenever a task involves building or wiring in a minigame: a snake/arcade-style game, a timing/reaction challenge, a puzzle, a quiz mini-mode, or anything else the player breaks away from the main narration to play. Not for the narrative canvas itself (pixi-vn-canvas) or for general app UI screens unrelated to a minigame (pixi-vn-ui).

Core mental model

  • A minigame renders on its own PixiJS layer, not on canvas.gameLayer. gameLayer is the save-able narrative scene graph (backgrounds, characters — see pixi-vn-canvas); a minigame's moving pieces (snake segments, falling blocks, ...) are transient and don't belong there. Use canvas.layers.add(name, new Container()) to get a separate, non-save-able layer for the minigame, exactly like a PixiJS UI layer (pixi-vn-ui) — the official template even reserves a constant for it, CANVAS_MINIGAME_LAYER_NAME.
  • The minigame's HUD/menus (score, game-over overlay, control buttons) should be regular UI, not PixiJS — built with React/Vue/whatever the project's UI already uses (pixi-vn-ui), positioned over the canvas the same way any other UI is.
  • A minigame is launched from the narrative, then the player returns to it. The recommended approach is to link the minigame to its own route (e.g. /minigame/snake) and navigate to it from a step, then navigate back when it ends — see pixi-vn-ui's "Navigating between UI screens" section and interface-navigate. Every minigame example below is written as a route file for this reason, not a bare component.
  • Saving and restoring the minigame's current state (score, board, position, ...) is entirely the developer's responsibility. Game.exportGameState() does not know about a minigame in progress — see pixi-vn-saves. If a minigame's progress must survive a save/reload, persist it yourself (e.g. via game storage, see pixi-vn-storage).

Routing structure: one route per minigame, plus a shared layout route

With file-based routing (e.g. TanStack Router, used by the official templates), each minigame gets its own file under src/routes/minigame/, so a project with several minigames ends up with /minigame/snake, /minigame/quiz, etc.:

tsx
import { createFileRoute } from "@tanstack/react-router";
import SnakeGame from "@/screens/minigames/SnakeGame";

export const Route = createFileRoute("/minigame/snake")({
  component: SnakeGame,
});

Anything shared by every minigame (pausing narration/audio while one is open, common hotkeys, a shared HUD wrapper) doesn't belong copy-pasted into each of those files. Factor it into a single pathless layout route, src/routes/minigame.tsx, that renders an <Outlet /> for whichever minigame route is active — the same pattern the official React template already uses for /game (src/routes/game.tsx wraps every /game/* screen with usePauseGameWhenMenuIsOpen + useGameHotkeys + <Outlet />):

tsx
import { createFileRoute, Outlet } from "@tanstack/react-router";

export const Route = createFileRoute("/minigame")({
  component: MinigameLayout,
});

function MinigameLayout() {
  // hooks/providers shared by every minigame go here
  return <Outlet />;
}

What actually goes in src/routes/minigame.tsx is a judgment call to make while building the first minigame, not a file to scaffold reflexively — work through these questions before adding anything to it:

  • Is there actually anything shared across minigames? If the game's settings menu, pause menu, or quick-actions wheel aren't reachable while a minigame is open, and there's no common hotkey/HUD/provider every minigame needs, src/routes/minigame.tsx has nothing to do — leave it empty (just the <Outlet />) or skip creating it at all and let each minigame route stand alone.
  • Are there menus specific to minigames only (a minigame pause menu, a "quit minigame and return to story" confirmation, a minigame-specific settings panel)? If so, that's exactly what belongs in the shared layout, the same way src/routes/game.tsx centralizes usePauseGameWhenMenuIsOpen and useGameHotkeys for every /game/* screen.
  • Should the same menus as src/routes/game.tsx (settings, save/load, quick actions) be reachable from inside a minigame? If yes, don't assume they behave identically — check case by case whether each one still makes sense mid-minigame. Saving is the clearest example: Game.exportGameState() knows nothing about in-progress minigame state (see the Gotchas section below), so a save triggered from inside a minigame either needs to be disabled/hidden there, or the minigame needs to persist its own state first (pixi-vn-storage) so the save is still meaningful. Don't wire in the game's menus unchanged and assume they "just work" inside a minigame.
Show full SKILL.md (424 more words)Show less

The useMinigame lifecycle hook

Every official template ships a useMinigame hook (e.g. src/lib/hooks/minigame-hooks.ts) that handles the repetitive part of wiring a minigame into a layer: creating the layer once, running an optional async onStart before the game begins, calling back into your game(layer) function, and cleaning the layer up (plus your onExit) when the screen unmounts.

ts
import { CANVAS_MINIGAME_LAYER_NAME } from "@/constants";
import { canvas, type Layer } from "@drincs/pixi-vn";
import { Container } from "pixi.js";
import { useEffect, useRef } from "react";

export function useMinigame(
  game: (layer: Layer) => void,
  props?: {
    onStart?: () => Promise<void>;
    onExit?: (layer: Layer) => void;
  },
) {
  const loading = useRef(false);

  useEffect(() => {
    loading.current = true;
    const layer = canvas.layers.add(CANVAS_MINIGAME_LAYER_NAME, new Container());
    if (!layer) {
      console.error("Failed to create UI layer for minigame");
      return;
    }

    let cancelled = false;
    (props?.onStart ?? (async () => {}))().then(() => {
      if (cancelled) return;
      loading.current = false;
      game(layer);
    });

    return () => {
      cancelled = true;
      canvas.layers.remove(CANVAS_MINIGAME_LAYER_NAME);
      props?.onExit?.(layer);
    };
  }, [game]);

  return { loading };
}

Usage inside the minigame's own route file:

tsx
import { Layer } from "@drincs/pixi-vn";
import { Graphics, Ticker } from "@drincs/pixi-vn/pixi.js";
import { createFileRoute } from "@tanstack/react-router";
import { useCallback, useMemo, useState } from "react";
import { useHotkey } from "@tanstack/react-hotkeys";
import useMinigame from "@/lib/hooks/minigame-hooks";

export const Route = createFileRoute("/minigame/example")({
  component: MiniGame,
});

function MiniGame() {
  const [score, setScore] = useState(0);
  const [gameOver, setGameOver] = useState(false);

  const ticker = useMemo(() => {
    const ticker = new Ticker();
    ticker.add(({ deltaMS }) => {
      // update game logic; call setGameOver(true) + ticker.stop() to end
    });
    return ticker;
  }, []);

  useHotkey(
    "ArrowUp",
    () => {
      /* handle input */
    },
    { enabled: !gameOver },
  );

  const game = useCallback(
    (layer: Layer) => {
      ticker.start();
    },
    [ticker], // must NOT change during the game or it restarts
  );

  const options = useMemo(
    () => ({
      onExit() {
        ticker.stop();
        ticker.destroy();
      },
    }),
    [ticker], // must NOT change during the game or it restarts
  );

  useMinigame(game, options);

  return (
    <>{/* score HUD, game-over overlay, control buttons — regular UI */}</>
  );
}
  • game(layer) is where you build the actual PixiJS content (Graphics, Sprite, Text, a Ticker) and add it to the given layer. It runs once, after onStart resolves.
  • onExit(layer) is where you tear down anything game started — stop and destroy() any Ticker, remove event listeners. useMinigame already removes the layer itself.
  • game and the options object (specifically its onExit) must keep a stable identity across re-renders (useCallback/useMemo with the right deps) — since they're the effect's dependency, changing identity mid-game tears down and restarts the whole minigame.

Controls and rendering

  • Use hotkeys for keyboard input (see pixi-vn-ui/hotkeys) rather than raw window.addEventListener("keydown", ...), and gate them with enabled: !gameOver so input stops mounting a listener that outlives the round.
  • Build the actual gameplay visuals with PixiJS directly — either the pixi.js package or the @drincs/pixi-vn/pixi.js re-export — using Graphics/Sprite/Text and a Ticker for the game loop, same primitives as pixi-vn-canvas but on the dedicated minigame layer instead of gameLayer.
  • On-screen touch controls, score displays, and game-over messages should still be plain UI components (buttons, divs) layered over the canvas with pointerEvents: "auto" where they need to be clickable — see pixi-vn-ui's "Enabling interaction" section.

Gotchas

  • Adding game content to canvas.gameLayer instead of a dedicated layer makes it save-able and mixes it with narrative elements — use canvas.layers.add for the minigame instead (pixi-vn-canvas has the full gameLayer vs. layer distinction).
  • An unstable game/onExit reference restarts the minigame on every render — see the useCallback/useMemo note above; this is the single most common bug when porting the pattern.
  • Nothing about minigame progress is captured by Game.exportGameState() — a mid-round save/ reload will silently drop it unless you persist state yourself through game storage (pixi-vn-storage/pixi-vn-saves).
  • Forgetting to stop/destroy the Ticker in onExit leaves the game loop running (and potentially erroring against removed objects) after the player navigates away.
  • pixi-vn-canvas: the PixiJS rendering primitives (Graphics, Sprite, Text, tickers, canvas.animate) a minigame is built from, and the gameLayer/layer distinction.
  • pixi-vn-ui: canvas.layers.add/htmlLayers.add, hotkeys, and navigating between UI screens/routes — how the minigame's HUD and route linkage actually work.
  • pixi-vn-storage: persisting minigame progress (score, board state) in game storage if it needs to survive a save/reload.
  • pixi-vn-saves: confirms Game.exportGameState() has no built-in notion of in-progress minigame state.

© DRincs-Productions, LGPL-2.1. Rendered from Markdown: HTML in the file is shown as text, images as links, and headings moved down two levels. Raw file

Files

Just SKILL.md in skills/minigames of DRincs-Productions/pixi-vn.

Open the folder on GitHubat commit 01c19cb

Compare with similar skills

Pixi Vn Minigames next to the 5 skills that share the most tags, products or categories with it. Stars are the repository's; “used in” counts other GitHub owners with a copy.

Pixi Vn Minigames compared with similar skills
SkillStarsUsed inTokensAuto-checkLicenceRepo updated
Pixi Vn Minigames this skillDRincs-Productions/pixi-vn149—~2.9kAutomated safety check: PassLGPL-2.1
Reader Paneldanjdewhurst/story-skills2861 repos~3.5kAutomated safety check: NotesMIT
Sw Genre Anatomyjtydhr88/screenwriting-skills1.6k—~5.6kAutomated safety check: PassMIT
Ylj Preemption Checkbrycewang-stanford/Awesome-Journal-Skills1.2k—~1.4kAutomated safety check: PassMIT
I18nhuoshen80/ReinaManager697—~177Automated safety check: PassAGPL-3.0
Frontend Testhuoshen80/ReinaManager697—~180Automated safety check: PassAGPL-3.0

Similar skills

  • Reader Panel

    danjdewhurst/story-skills

    This skill should be used when the user asks for a "simulated beta read", "reader panel", "persona read", "first read before my beta readers", "how would a genre reader react", "would a reader keep…

    286 GitHub starsUsed in 1 repo~3.5k tokens
    Writing & ContentAuto-check: notes
  • Sw Genre Anatomy

    jtydhr88/screenwriting-skills

    Genre anatomy from John Truby's The Anatomy of Genres (类型解剖 / 类型节拍 / 混合类型 / 超越类型) — genres as beat systems with a life philosophy underneath; three rules (hit every beat of your genre, mix three or…

    1.6k GitHub stars~5.6k tokensUpdated 8 days ago
    EducationAuto-check passed
  • Ylj Preemption Check

    brycewang-stanford/Awesome-Journal-Skills

    A skill your agent uses when verifying that a The Yale Law Journal (YLJ) claim is genuinely novel and not preempted by prior scholarship.

    1.2k GitHub stars~1.4k tokensUpdated 14 days ago
    EducationAuto-check passed
  • I18n

    huoshen80/ReinaManager

    使用 i18next-cli 检查、同步和整理本项目的国际化资源。涉及新增、修改、删除翻译键或国际化字符串,以及修复缺失翻译时使用。

    697 GitHub stars~177 tokensUpdated yesterday
    Frontend & DesignAuto-check passed
  • Frontend Test

    huoshen80/ReinaManager

    在 ReinaManager 项目内进行隔离前端验证,复用测试目录并回收测试资源。需要模拟批量数据、延迟、失败或交互回归时使用。

    697 GitHub stars~180 tokensUpdated yesterday
    Frontend & DesignAuto-check passed
  • Cdp

    huoshen80/ReinaManager

    通过 CDP 连接 ReinaManager WebView2,复现、诊断并验证真实应用的前端问题。仅在用户显式调用 /cdp 或 $cdp 进行前端调试时使用。

    697 GitHub stars~178 tokensUpdated yesterday
    DatabasesAuto-check passed

More from DRincs-Productions/pixi-vn

All 13 skills in this repo
  • Pixi Vn Assets

    DRincs-Productions/pixi-vn

    A skill your agent uses when adding, organizing, registering, or loading non-code files (images, audio, video) in a Pixi'VN project — local assets processed by PixiJS AssetPack vs.

    149 GitHub stars~2.9k tokensUpdated 10 days ago
    Auto-check passed
  • Pixi Vn Characters

    DRincs-Productions/pixi-vn

    A skill your agent uses when defining visual novel characters for a @drincs/pixi-vn game — creating a character with a name, color, icon and other props, registering it so it can be looked up by id…

    149 GitHub stars~3.1k tokensUpdated 10 days ago
    Auto-check passed
  • Pixi Vn History

    DRincs-Productions/pixi-vn

    A skill your agent uses when implementing "go back" / "rewind" / step-navigation features in a Pixi'VN game, or when you need to read the player-facing dialogue/choice history (e.g.

    149 GitHub stars~2.6k tokensUpdated 10 days ago
    Auto-check passed
  • Pixi Vn Narration

    DRincs-Productions/pixi-vn

    A skill your agent uses when writing or editing Pixi'VN story content — defining labels (scenes) with newLabel, writing dialogue steps, adding player choices with…

    149 GitHub stars~4.9k tokensUpdated 10 days ago
    Auto-check passed
  • Pixi Vn Saves

    DRincs-Productions/pixi-vn

    A skill your agent uses when implementing save/load in a Pixi'VN game — Game.exportGameState()/restoreGameState()/jsonToGameState(), what the exported GameState contains, and how to persist it (save…

    149 GitHub stars~1.5k tokensUpdated 10 days ago
    Auto-check passed
  • Pixi Vn Sound

    DRincs-Productions/pixi-vn

    A skill your agent uses when playing or stopping background music, sound effects, or voice lines; creating/organizing audio channels; controlling volume, mute, or pan; or wiring Tone.js audio…

    149 GitHub stars~3.3k tokensUpdated 10 days ago
    Auto-check passed

Works with

Questions about Pixi Vn Minigames

What does Pixi Vn Minigames do?

A skill your agent uses when adding a minigame (snake, quiz, puzzle, timing/reaction game, ...) to a Pixi'VN visual novel — the useMinigame lifecycle hook pattern, using PixiJS directly on its own…. Pixi Vn Minigames is an agent skill from DRincs-Productions/pixi-vn.) to a Pixi'VN visual novel — the useMinigame lifecycle hook pattern, using PixiJS directly on its own layer instead of gameLayer, hotkeys for controls, linking the minigame to a route, and why saving/restoring minigame state is the developer's own responsibility.

When should I use Pixi Vn Minigames?

Pixi Vn Minigames fits situations like: adding a minigame (snake; timing/reaction game; ...) to a PixiVN visual novel — the useMinigame lifecycle hook pattern; using PixiJS directly on its own layer instead of gameLayer.

How do I install Pixi Vn Minigames in Claude Code?

Run `npx skills add DRincs-Productions/pixi-vn --skill pixi-vn-minigames -a claude-code`. Or copy the skill folder (skills/minigames in DRincs-Productions/pixi-vn) into .claude/skills/pixi-vn-minigames in your project. Claude Code loads it when a task matches its description.

How do I install Pixi Vn Minigames in Codex?

Run `npx skills add DRincs-Productions/pixi-vn --skill pixi-vn-minigames -a codex`. Or copy the skill folder (skills/minigames in DRincs-Productions/pixi-vn) into .agents/skills/pixi-vn-minigames in your project. Codex loads it when a task matches its description.

Can I use Pixi Vn Minigames in Cursor, Gemini CLI or GitHub Copilot?

Cursor, Gemini CLI, GitHub Copilot and OpenCode also load SKILL.md folders. With the skills CLI, run `npx skills add DRincs-Productions/pixi-vn --skill pixi-vn-minigames -a cursor` (or -a gemini-cli, github-copilot or opencode for the others). To copy it by hand, put the folder in .cursor/skills/pixi-vn-minigames, .gemini/skills/pixi-vn-minigames, .github/skills/pixi-vn-minigames and .opencode/skills/pixi-vn-minigames in your project.

What does Pixi Vn Minigames need to run?

SKILL.md names no scripts, command-line tools or credentials: Pixi Vn Minigames is instructions for the agent only.

Does Pixi Vn Minigames access the network?

SKILL.md names 2 domains. As links in the text: pixi-vn.com and tanstack.com. This is read from the text; nothing was executed.

Is Pixi Vn Minigames safe to install?

Our automated static check of SKILL.md found no risky patterns, such as piping downloads into a shell, reading credential files or hidden Unicode. It is not a guarantee. Review the folder before installing.

What licence does Pixi Vn Minigames use?

Pixi Vn Minigames is published under the LGPL-2.1 licence (the repository's licence). It allows redistribution, so the full SKILL.md is shown on this page.

How many tokens does Pixi Vn Minigames use?

About 2.9k tokens (SKILL.md is roughly 12k characters). Agents keep only the skill's name and description in context until a task matches; then they load SKILL.md in full.

What are the alternatives to Pixi Vn Minigames?

Skills that share tags, products or a category with Pixi Vn Minigames: Reader Panel (danjdewhurst/story-skills, 286 stars), Sw Genre Anatomy (jtydhr88/screenwriting-skills, 1.6k stars), Ylj Preemption Check (brycewang-stanford/Awesome-Journal-Skills, 1.2k stars) and I18n (huoshen80/ReinaManager, 697 stars). The comparison table on this page puts their stars, adoption, token cost, safety result and licence side by side.

Who maintains Pixi Vn Minigames?

DRincs-Productions (a GitHub organization) maintains it in DRincs-Productions/pixi-vn, which has 149 GitHub stars. The repository holds 13 skills in this directory. The repository was last updated on October 1, 2026.

Source: DRincs-Productions/pixi-vn on GitHub. Facts on this page come from the repository at the commit we read; the author's words are quoted as theirs.