
pixijs-rendering
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 (examples checked against 8.22).
- Installs
- 5.7K
- Last 24h
- +304
- Trending rank
- #951
- Security
- Pass
Install
Works with every agent the skills CLI supports.
npx skills add https://github.com/gamedev-skills/awesome-gamedev-agent-skills --skill pixijs-rendering- 01
Install
Run the command in your project. The CLI asks which agents to install for.
- 02
Describe the task
Ask your agent for something this skill covers. It loads pixijs-rendering automatically when relevant.
- 03
Review the result
The agent follows the SKILL.md steps, scripts and references bundled with the skill.
Security audits
Independent scans of the skill's instructions and bundled files.
SKILL.md
The instructions your agent reads when the skill is triggered.
PixiJS 8.22 Rendering
Set up and structure a PixiJS 8.22 application: the async Application, asset
loading via Assets, the Container/Sprite scene graph, the ticker loop,
pointer events, and render groups. Pins the 8.22 API (async init, unified
Assets, eventMode).
When to use
- Use when starting a PixiJS v8 project, fixing a blank canvas, structuring the display list, loading textures, animating via the ticker, or handling pointer input.
- Use when
package.jsondepends onpixi.js(v8) and code doesimport { 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, beginFill/endFill) needs the v8 migration first;
this skill targets v8 only. (interactive = true still works in v8 as an alias for
eventMode = 'static', but prefer the explicit eventMode.)
Core workflow
- Create and
awaitthe Application. In v8,new Application()is empty; configuration happens inawait app.init({...}). Appendapp.canvas(notapp.view) to the DOM. Wrap top-levelawaitin an async function for bundlers. - Load assets with
Assets.await Assets.load(url)returns aTexture. For many assets, register a manifest/bundle and load by name. There is no v7Loader. - Build the scene graph. Everything descends from
app.stage(aContainer). Group related objects inContainers; child transforms are relative to the parent. Draw order = insertion order (later = on top). - Animate with the ticker.
app.ticker.add((ticker) => {...}). Scale motion byticker.deltaTime(frames, ~1 at 60fps) orticker.deltaMS(milliseconds) so speed is frame-rate independent. - Enable events per object by setting
eventMode = 'static'(or'dynamic'), thenobj.on('pointerdown', ...). Federated pointer events cover mouse/touch/pen. - Promote big static subtrees to render groups (
isRenderGroup: true) so the GPU caches their transforms. Profile before and after; confirm pixels on screen.
Patterns
1. Async Application boot (the v8 entry point)
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', // hint only; default order tries 'webgl' first.
// // Pixi falls back if the backend is unavailable —
// // branch on app.renderer.name, don't assume it took.
});
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);
})();
2. Containers for a relative-transform scene graph
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 container
3. The ticker loop (frame-rate independent)
let 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;
});
4. Pointer events (federated)
bunny.eventMode = 'static'; // 'static' = interactive, doesn't move on its own
bunny.cursor = 'pointer'; // hover cursor; `buttonMode` was removed in v8
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));
Dragging needs globalpointermove, not pointermove. In v8 pointermove fires
only while the pointer is over the object, so a drag that follows the cursor
past the object's edge stops updating. globalpointermove fires on every move:
let dragging = false;
bunny.on('pointerdown', () => { dragging = true; });
bunny.on('pointerup', () => { dragging = false; });
bunny.on('pointerupoutside', () => { dragging = false; }); // release off the object
bunny.on('globalpointermove', (event) => {
if (dragging) bunny.position.copyFrom(event.global);
});
5. Loading many assets by name (bundles)
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);
6. Render groups for large static layers
// 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.
Pitfalls
- Blank canvas, or
TypeErrorreadingcanvas/screenof undefined → you didn'tawait app.init(), or you configured the constructor. In v8 the constructor is empty; all options go toinit().app.stageexists right away, butapp.rendererisundefineduntil theinit()promise resolves, soapp.canvasandapp.screenthrow before then. app.viewlogs a deprecation warning → v8 renamed it toapp.canvas; the old getter still returns the canvas for now.- Porting v7 code →
Loader/loader.add→Assets.load(theLoaderclass is gone); synchronousnew Application({...})→ empty constructor + asyncinit()(options in the constructor are ignored with a deprecation warning, not an error);beginFill()/endFill()→ shape-first.rect(...).fill(...).interactive = trueandapp.viewstill work as deprecated aliases. - Ticker callback arg is the Ticker, not a delta number →
app.ticker.add((dt) => { obj.rotation += dt; })compiles, butdtis the wholeTickerobject, so the math yieldsNaNand nothing animates. Readticker.deltaTimeoff the argument. - Top-level await build error (Vite ≤6.0.6) → wrap boot in
(async () => { ... })(). - Speed varies with frame rate → multiply movement by
ticker.deltaTime(~1 at 60fps) or scale byticker.deltaMS; never assume 60fps.deltaTimeis a dimensionless multiplier, not milliseconds. - Clicks do nothing → the object's
eventModeis still'passive'(the v8 default: self not interactive, children still are); set it to'static'(or'dynamic'for objects that move under a stationary cursor). - Drag stops at the object's edge →
pointermovefires only while the pointer is over the object in v8; useglobalpointermovefor drag/global tracking. - Right-click opens the browser menu over the game → PixiJS does not block it.
From 8.22, listen for
contextmenuon the object and callevent.preventDefault(); cancellingrightdown/rightclickdoes not stop the menu. On older 8.x, add a nativecontextmenulistener toapp.canvasinstead. addChildon aSprite/Graphics/Textlogs a deprecation warning → in v8 onlyContainers should hold children; put the sprite and its children side by side in aContainer.Texture.from(url)returns a blank/undefined texture → in v8 it only reads the Assets cache;await Assets.load(url)first, then use the returnedTexture.- WebGPU features error out →
preferenceis a hint. If the backend is unavailable Pixi falls back (WebGL, then Canvas); branch onapp.renderer.namebefore using backend-specific code. - Textures look blurry on pixel art → set
texture.source.scaleMode = 'nearest'(or pass it when loading). - Memory grows →
removeChilddoes not free GPU memory; callsprite.destroy()andAssets.unload(url)for assets you're done with. - Flicker/corruption after tearing down and re-creating an app in the same tab →
destroy with
app.destroy({ releaseGlobalResources: true }); otherwise pooled batches/textures from the old app leak into the new one.
References
- For the texture/asset pipeline (sprite sheets/atlases,
Assets.add, background loading, unloading) and Graphics/Text/TilingSprite/ParticleContainerplus filters, readreferences/assets-and-display.md.
Related skills
phaser-core— a batteries-included 2D framework (scenes, physics, input).threejs-scene-setup— 3D in the browser with three.js.prototype-fast— greybox a playable slice quickly (often cites PixiJS).
FAQ
What does the pixijs-rendering skill do?
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 (examples checked against 8.22).
How do I install pixijs-rendering?
Run npx skills add https://github.com/gamedev-skills/awesome-gamedev-agent-skills --skill pixijs-rendering in your project. The skills CLI detects the agents you use and copies the skill into the right folder. For Claude Code you can also place the skill folder at ~/.claude/skills/pixijs-rendering/ (personal) or .claude/skills/pixijs-rendering/ (project).
Which AI agents can use pixijs-rendering?
Any agent that supports the open Agent Skills format (a folder with a SKILL.md file), including Claude Code, Codex, Cursor, GitHub Copilot, Gemini CLI, Windsurf, Cline, OpenCode and more.
Is pixijs-rendering safe to install?
Security partners have reviewed it: Gen Agent Trust Hub passed; Socket passed; Snyk passed. As with any skill, read the SKILL.md and bundled scripts before installing.
Who maintains pixijs-rendering?
It is published by gamedev-skills in gamedev-skills/awesome-gamedev-agent-skills. It has 5,686 recorded installs.
More from gamedev-skills/awesome-gamedev-agent-skills
game-feel
gamedev-skills/awesome-gamedev-agent-skills
Add "juice" and game feel that makes actions satisfying — screen shake, hit-stop/freeze frames, tweened/eased motion, squash & stretch, knockback, and layered audio-visual feedback — as engine-neutral techniques that pair with the detected engine's tween, particle, and camera APIs. Use when the user mentions game feel, juice, "make it feel good/punchy", screen shake, hit stop, screen freeze, easing, squash and stretch, impact frames, or feedback/polish on hits, jumps, pickups, and deaths.
game-ui-ux
gamedev-skills/awesome-gamedev-agent-skills
Design and build game UI/UX — HUDs, menus, and overlays — that survive every screen: anchor- based responsive layout, resolution/aspect scaling and safe areas, keyboard/gamepad focus navigation, a screen/menu state stack, and event-driven (not polled) HUD updates. Engine- neutral patterns that pair with the detected engine's UI skill. Use when the user mentions HUD, health bar, main menu, pause menu, settings screen, UI layout, anchors, UI scaling, aspect ratio, safe area, controller/keyboard menu navigation, or wiring UI to game state.
level-design
gamedev-skills/awesome-gamedev-agent-skills
Design and build playable levels — the blockout/whitebox-to-playable workflow, player metrics and grid layout, pacing and flow (tension/rest curve), gating and the critical path, and encounter design. Engine-neutral practice. Use when the user mentions level design, blockout/whitebox/greybox, level layout, level pacing, encounter design, or the critical path through a level.
performance-optimization
gamedev-skills/awesome-gamedev-agent-skills
Find and fix game performance problems methodically — measure with the engine profiler first, reason about the frame-time budget, locate the CPU-vs-GPU bottleneck, then apply the right fix: object pooling, draw-call batching, fewer allocations/GC spikes, and asset budgets. Engine- neutral method that pairs with each engine's profiler. Use when the user mentions performance, optimize, low/dropping FPS, frame drops, stutter, lag, profiler, frame budget, draw calls, batching, garbage collection/GC spikes, object pooling, or "the game runs slow".
game-ai
gamedev-skills/awesome-gamedev-agent-skills
Design NPC and enemy decision-making with finite state machines, behavior trees, steering behaviors, and A pathfinding — engine-neutral algorithms that pair with the detected engine's navigation API. Use when building enemy AI, an FSM or behavior tree, steering/flocking, or pathfinding, or when the user mentions state machine, behavior tree, blackboard, A, navmesh, seek, or patrol/chase.
audio-design
gamedev-skills/awesome-gamedev-agent-skills
Implement game audio practice — bus/mixer architecture and gain in decibels, ducking (sidechain), adaptive/dynamic music via layering and re-sequencing, SFX variation, and beat synchronization. Engine-neutral. Use when the user mentions audio mixing, audio buses, adaptive/dynamic music, ducking, SFX variation, music layers, or syncing gameplay to the beat.
Popular backend & apis skills
find-skills
vercel-labs/skills
Helps users discover and install agent skills when they ask questions like "how do I do X", "find a skill for X", "is there a skill that can...", or express interest in extending capabilities. This skill should be used when the user is looking for functionality that might exist as an installable skill.
entra-app-registration
microsoft/azure-skills
Guides Microsoft Entra ID app registration, OAuth 2.0 authentication, and MSAL integration. USE FOR: create app registration, register Azure AD app, configure OAuth, set up authentication, add API permissions, generate service principal, MSAL example, console app auth, Entra ID setup, Azure AD authentication. DO NOT USE FOR: Key Vault secrets (use azure-keyvault-expiration-audit), general Azure resource security guidance.
google-agents-cli-adk-code
google/agents-cli
This skill should be used when the user wants to "write agent code", "build an agent with ADK", "add a tool", "create a callback", "define an agent", "use state management" — in a project that needs ADK (Agent Development Kit) API patterns and code examples. It provides a quick reference for agent types, tool definitions, orchestration patterns, callbacks, state management, the graph Workflow API, and reference recipes to study. Do NOT use for scaffolding (use google-agents-cli-scaffold) or deployment (use google-agents-cli-deploy).
embedded-captions
heygen-com/hyperframes
Add captions or subtitles to an existing single-subject talking-head video without editing the footage. Use for plain verbatim captions, cinematic captions embedded behind the subject, VFX captions, “炸/特效/酷炫字幕,” or a named identity from the 35-style catalog. Route by visual identity, not by backend engine. The quiet anchor rail is the default; embed every word only when the user explicitly wants a fully cinematic treatment. The workflow runs locally end to end, including transcription and subject matting; split multi-shot footage before applying it.
entra-agent-id
microsoft/azure-skills
Provision Microsoft Entra Agent Identity Blueprints, BlueprintPrincipals, and per-instance Agent Identities via Microsoft Graph, and configure OAuth 2.0 token exchange (fmipath, OBO, cross-tenant) including the Microsoft Entra SDK for AgentID sidecar. USE FOR: Agent Identity Blueprint, BlueprintPrincipal, agent OAuth, fmipath token exchange, agent OBO, Workload Identity Federation for agents, polyglot agent auth, Microsoft.Identity.Web.AgentIdentities. DO NOT USE FOR: standard Entra app registration (use entra-app-registration), Microsoft Foundry agent authoring (use microsoft-foundry).
neon
neondatabase/agent-skills
Overview of Neon, a complete set of cloud backend primitives around Lakebase Postgres: Auth, Object Storage, Functions, the AI Gateway, and Realtime. Start here to choose Neon for undecided login, files, APIs, and LLM calls, set up the CLI or MCP server, and follow the branch-first workflow. Use when building an app or backend on Neon, or when "Neon" or "Lakebase Postgres" is mentioned. Child skill neon-postgres wins for an existing DATABASEURL, SQL, schema, inspect, or search. Child skill neon-auth wins for login, users, sessions, identity routing, and Managed Better Auth setup. Child skill neon-realtime wins for live queries in reactive apps and agents. Also use for object storage, S3, buckets, serverless functions, function triggers, cron, AI gateway, LLM calls, realtime, logs, Loki, Grafana, observability, postgres, database, backend, Claimable Neon, neon.new, or a no-signup database.