ai-behavior-trees-util…
Build a production behavior-tree runtime (Blackboard, action/condition leaves, sequence/selector/parallel composites, decorators) and a Utility AI system…
Build a PixiJS v8 render layer: create the async Application, load textures with Assets, compose the scene graph with Container and Sprite, drive the ticker loop, wire pointer events, and group draws with render groups. Use when building or debugging PixiJS v8 — when the user
$ npx -y skills add gamedev-skills/awesome-gamedev-agent-skills --skill pixijs-rendering --agent claude-codeHow it fires
How this skill gets triggered: by you, by Claude, or both.
/pixijs-renderingContext preview
The summary Claude sees to decide when to auto-load this skill.
Build a PixiJS v8 render layer: create the async Application, load textures with Assets, compose the scene graph with Container and Sprite, drive the ticker loop, wire pointer events, and group draws with render groups. Use when building or debugging PixiJS v8 — when the user
name: pixijs-rendering description: > Build a PixiJS v8 render layer: create the async Application, load textures with Assets, compose the scene graph with Container and Sprite, drive the ticker loop, wire pointer events, and group draws with render groups. Use when building or debugging PixiJS v8 — when the user mentions PixiJS, Pixi, Application, app.stage, Container, Sprite, Assets.load, app.ticker, or eventMode. Pins the v8 async init() API.
Set up and structure a PixiJS **8.19** application: the async `Application`, asset loading via `Assets`, the `Container`/`Sprite` scene graph, the ticker loop, pointer events, and render groups. Pins the 8.19 API (async `init`, unified `Assets`, `eventMode`).
display list, loading textures, animating via the ticker, or handling pointer input.
`import { Application } from 'pixi.js'`.
**When *not* to use:** Phaser's scene/loader model → `phaser-core`. 3D scenes → `threejs-scene-setup`. PixiJS v7-and-earlier code (synchronous `new Application({...})`, `Loader`, `interactive = true`) needs the v8 migration first; this skill targets v8 only.
1. **Create and `await` the Application.** In v8, `new Application()` is empty; configuration happens in `await app.init({...})`. Append `app.canvas` (not `app.view`) to the DOM. Wrap top-level `await` in an async function for bundlers. 2. **Load assets with `Assets`.** `await Assets.load(url)` returns a `Texture`. For many assets, register a manifest/bundle and load by name. There is no v7 `Loader`. 3. **Build the scene graph.** Everything descends from `app.stage` (a `Container`). Group related objects in `Container`s; child transforms are relative to the parent. Draw order = insertion order (later = on top). 4. **Animate with the ticker.** `app.ticker.add((ticker) => {...})`. Scale motion by `ticker.deltaTime` (frames, ~1 at 60fps) or `ticker.deltaMS` (milliseconds) so speed is frame-rate independent. 5. **Enable events per object** by setting `eventMode = 'static'` (or `'dynamic'`), then `obj.on('pointerdown', ...)`. Federated pointer events cover mouse/touch/pen. 6. **Promote big static subtrees to render groups** (`isRenderGroup: true`) so the GPU caches their transforms. Profile before and after; confirm pixels on screen.
import { Application, Assets, Sprite } from 'pixi.js';
(async () => {
// v8: construct empty, then await init(). Config does NOT go in the constructor.
const app = new Application();
await app.init({
background: '#1099bb',
resizeTo: window, // track the window size
antialias: true,
// preference: 'webgpu', // opt into WebGPU; default 'webgl'
});
document.body.appendChild(app.canvas); // v8 uses app.canvas, not app.view
const texture = await Assets.load('https://pixijs.com/assets/bunny.png');
const bunny = new Sprite(texture);
bunny.anchor.set(0.5);
bunny.position.set(app.screen.width / 2, app.screen.height / 2);
app.stage.addChild(bunny);
})();import { Container, Sprite } from 'pixi.js';
const world = new Container();
app.stage.addChild(world);
// Children are positioned relative to `world`; move/scale/rotate the whole group
// by transforming the parent.
for (let i = 0; i < 10; i++) {
const coin = new Sprite(coinTexture);
coin.x = i * 40;
world.addChild(coin);
}
world.position.set(100, 100);
world.scale.set(2); // every coin scales with the containerlet elapsed = 0;
app.ticker.add((ticker) => {
// deltaTime ≈ 1 at 60fps; deltaMS is milliseconds since last frame.
elapsed += ticker.deltaMS;
bunny.rotation += 0.05 * ticker.deltaTime; // smooth at any frame rate
bunny.y = app.screen.height / 2 + Math.sin(elapsed / 500) * 50;
});bunny.eventMode = 'static'; // 'static' = interactive, doesn't move on its own
bunny.cursor = 'pointer';
bunny.on('pointerdown', (event) => {
bunny.tint = 0xff0000;
// event.global is the pointer position in stage space.
});
bunny.on('pointerover', () => bunny.scale.set(1.1));
bunny.on('pointerout', () => bunny.scale.set(1.0));import { Assets } from 'pixi.js';
await Assets.init({
manifest: {
bundles: [{
name: 'level-1',
assets: [
{ alias: 'hero', src: 'assets/hero.png' },
{ alias: 'tiles', src: 'assets/tiles.png' },
],
}],
},
});
const bundle = await Assets.loadBundle('level-1'); // { hero: Texture, tiles: Texture }
const hero = new Sprite(bundle.hero);// A big, rarely-changing background subtree: let the GPU cache its transforms.
const background = new Container({ isRenderGroup: true });
app.stage.addChild(background);
// Add hundreds of static tiles to `background`. Moving `background` itself stays
// cheap; constantly re-adding/removing children negates the benefit.configured the constructor. In v8 the constructor is empty; all options go to `init()`.
`loader.add` → `Assets.load`; synchronous `new Application({...})` → async `init`.
`deltaMS`); never assume 60fps.
<img src="docs/assets/banner.png" width="820" alt="awesome-gamedev-agent-skills — game-dev skills for AI coding agents.
Repo: gamedev-skills/awesome-gamedev-agent-skills
Build a production behavior-tree runtime (Blackboard, action/condition leaves, sequence/selector/parallel composites, decorators) and a Utility AI system…
Implement game audio practice — bus/mixer architecture and gain in decibels, ducking (sidechain), adaptive/dynamic music via layering and re-sequencing, SFX…
Build game cameras that feel good — 2D follow with a deadzone, look-ahead, smoothing, and level-bounds clamping; 3D third-person orbit with collision and…
Plan, generate, source, normalize, and validate cohesive visual game assets. Use for art direction, style bibles, sprites, tilesets, backgrounds, UI art,…
Build branching dialogue and narrative — a node/choice graph with conditions, variables, and localization hooks — and choose between authoring tools Ink and…
Design NPC and enemy decision-making with finite state machines, behavior trees, steering behaviors, and A* pathfinding — engine-neutral algorithms that pair…