Engineering
phaser-gamedev avatar

phaser-gamedev

Expert-level Phaser 3 game development agent. Handles scene architecture, Arcade/Matter physics, asset pipelines, sprite animations, and performance optimization for 2D web games.

Introduction

This skill acts as a specialized game architecture and implementation partner for building 2D browser games with Phaser 3. It is designed for game developers and software engineers who need to translate high-level design requirements into robust, performance-optimized code. It focuses on the 'Living Systems' philosophy, where games are treated as dynamic, stateful entities requiring careful scene lifecycle management, structured asset pipelines, and efficient physics integration.

  • Expert support for Phaser 3 scene architecture: Boot, Menu, Game, UI, and GameOver scene management, including data transitions and registry usage.

  • Comprehensive physics guidance: Choosing between Arcade physics for performance-sensitive platformers/shooters and Matter.js for realistic collision constraints.

  • Asset pipeline discipline: Best practices for preload() queues, spritesheet loading, nine-slice UI scaling, texture atlas management, and handling asset metadata JSON files.

  • Performance optimization: Implementing object pooling, frame-rate independent delta-time logic, camera culling, and batching strategies to prevent stuttering and memory leaks.

  • Entity component logic: Implementing composition over inheritance patterns to create scalable game units like warriors, projectiles, and hazards.

  • Tooling integration: Utilizing debug toggles, visual regression testing hooks, and Tiled tilemap workflows for professional game construction.

  • Input/Output: Use this skill by providing requirements such as specific game genres, technical constraints, or problematic UI behaviors (e.g., nine-slice stretching issues). It outputs clean, modular JS/TS code, architectural patterns, and debugging advice.

  • Constraints: Avoid global state variables; always prefer dedicated scene state management or registries. Ensure assets are loaded via a Boot scene to prevent timing-related silent failures.

  • Best Practices: Always verify spritesheet frame dimensions and spacing before implementation to prevent visual artifacts. Use delta-time scaling for all movement and timers to ensure consistent behavior across different monitor refresh rates.

  • Use for tasks like setting up the game spine, resolving collision layering issues, architecting state-driven UI overlays, or optimizing a game loop with thousands of sprites.

Repository Stats

Stars
35
Forks
7
Open Issues
0
Language
HTML
Default Branch
main
Sync Status
Idle
Last Synced
May 3, 2026, 06:20 PM
View on GitHub