game-setup-and-config

Configures Phaser 4 game instances with GameConfig options for renderer, scaling, and FPS.

Updated Sep 20, 2026
One-click install
npx skills add https://github.com/AmirOssanloo/helix-game --skill game-setup-and-config-amirossanloo
Or copy as Structured Prompt for Agent▼
Please help me install this Agent Skill.
Skill: game-setup-and-config
Source: https://github.com/AmirOssanloo/helix-game/tree/main/.claude/skills/game-setup-and-config
Command: npx skills add https://github.com/AmirOssanloo/helix-game --skill game-setup-and-config-amirossanloo

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve? Setting up a Phaser 4 game requires navigating dozens of GameConfig options across renderer selection, canvas placement, scaling modes, pixel art rendering, and FPS limits, where misconfiguration causes silent failures or unexpected behavior. ## Core Features & Use Cases - Renderer and Boot Configuration: Choose between AUTO, CANVAS, WEBGL, and HEADLESS renderers and understand the full boot sequence from config parsing to the game loop. - Scaling and Pixel Art Patterns: Apply ready-made patterns for pixel art games, full-window responsive layouts, fixed aspect ratios with FIT, and transparent canvases. - Lifecycle Management: Handle pause, resume, visibility events, and asynchronous game destruction correctly. - Use Case: You are building a retro pixel art browser game and need a 320x240 canvas scaled 2x with crisp pixels and centered placement; this Skill provides the exact config with pixelArt, Scale.FIT, and CENTER_BOTH settings. ## Quick Start Ask the AI to create a new Phaser 4 game config for a pixel art game with a 320x240 resolution, 2x zoom, and centered scaling.

Frequently Asked Questions about game-setup-and-config

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I create a new Phaser 4 game instance?▼

Create a Phaser.Game by passing a config object with type, dimensions, and a scene class. The constructor parses the config, creates managers, waits for DOMContentLoaded, creates the renderer, and starts the game loop automatically.

How to configure pixel art rendering in Phaser?▼

Set pixelArt: true in the config, which automatically disables antialias and enables roundPixels for crisp pixels. For WebGL-only smooth edges between blocky pixels, use smoothPixelArt: true instead.

What is the difference between Phaser.AUTO and Phaser.WEBGL?▼

Phaser.AUTO uses WebGL when supported and falls back to Canvas otherwise. Phaser.WEBGL forces WebGL with no fallback, so the game fails silently if WebGL is unavailable.

Does Phaser Scale.FIT maintain aspect ratio?▼

Yes, Scale.FIT fits the canvas inside its parent while preserving aspect ratio, producing letterboxing. You can combine it with autoCenter and min/max dimension constraints for controlled responsive behavior.

Why does fps.target not limit my frame rate?▼

fps.target is advisory only and does not enforce anything. Use fps.limit to actually cap the frame rate, though the browser's display refresh rate remains the upper bound.

Why is game.destroy() not removing the canvas immediately?▼

Game.destroy() is asynchronous; it flags the game for destruction on the next frame. Listen for the Phaser.Core.Events.DESTROY event to react when cleanup completes.