Logo di Phaser Analyze

Phaser Analyze

Organizzazione
Yakoub-ai
phaser-analyze

This skill should be used when the user asks to "analyze my game", "review my Phaser project", "audit project health", "find bottlenecks", "refactor my game", "improve my code", "optimize my project", "what's wrong with my game", "code review Phaser", or "assess architecture".

Panoramica

Pubblicato daYakoub-ai
Repositoryphaser4-gamedev
Nome della skillphaser-analyze
Stelle
29
Fork
3
File inclusi
3
Link
  • Istruzioni in Markdown

    Un file SKILL.md che il modello carica quando serve, consumando token solo quando una richiesta è effettivamente pertinente.

  • Funziona con qualsiasi LLM

    Le skill IA sono in semplice Markdown, non in codice specifico di un fornitore, quindi funzionano con GPT, Claude, Gemini, Grok o un modello locale.

  • File inclusi: 3

    Script, template e riferimenti che il modello può leggere mentre lavora. I file sono di sola lettura e non vengono mai eseguiti.

  • Open source

    Pubblicata da Yakoub-ai su GitHub. Leggi i sorgenti prima di installarla.

Installazione

Installa la skill IA Phaser Analyze in TypingMind per usarla con qualsiasi LLM, oppure copiala in un altro agente in grado di leggere SKILL.md.

1

Installa in TypingMind

TypingMind installa una skill direttamente dalla sua cartella GitHub: legge SKILL.md, raccoglie i file delle risorse e salva il risultato in locale.

  1. Apri l'app e vai su Plugin → Skill.
  2. Scegli "Installa da GitHub".
  3. Incolla l'URL della cartella della skill riportato qui sotto e conferma.
    https://github.com/Yakoub-ai/phaser4-gamedev/tree/main/skills/phaser-analyze
  4. Attiva la skill in ogni chat in cui vuoi averla a disposizione.
Plugin → Skill → Aggiungi skill → Da URL GitHub, poi incolla l'URL della cartella e premi Continua.
2

Installa in un altro agente

Qualsiasi agente che legge il formato Agent Skills può usare questa skill: copia la cartella della skill nella directory delle skill di quell'agente.

Claude Code — .claude/skills
git clone --depth 1 https://github.com/Yakoub-ai/phaser4-gamedev.git /tmp/phaser4-gamedev
mkdir -p .claude/skills
cp -r /tmp/phaser4-gamedev/skills/phaser-analyze .claude/skills/phaser-analyze
Dopo la copia, riavvia Claude Code per caricare la nuova skill.

Usala in TypingMind

Attiva Phaser Analyze in qualsiasi chat di TypingMind e al resto pensa il modello. Il nome e la descrizione della skill sono nel prompt di sistema e, non appena arriva una richiesta pertinente, il modello carica da solo le istruzioni complete: non devi mai richiamarla manualmente e non consuma token finché non viene effettivamente usata.

Il modello carica automaticamente Phaser Analyze non appena riceve una richiesta pertinente.

Funziona con qualsiasi modello IA

Le skill IA sono semplici istruzioni in Markdown, non codice specifico di un fornitore, quindi Phaser Analyze non è vincolata al modello per cui è stata scritta. Installala una sola volta in TypingMind e usala con GPT-5, Claude, Gemini, Grok, DeepSeek, Mistral, Llama o un modello locale che esegui tu, sempre con le tue chiavi API.

  • Caricata solo quando serve

    Il prompt di sistema contiene solo il nome e la descrizione. Le istruzioni vengono recuperate alla prima richiesta pertinente, quindi una skill inutilizzata non costa nulla.

  • Cambia modello durante la chat

    Poiché la skill è composta da istruzioni e non da codice, continua a funzionare anche se cambi modello: il nuovo modello legge lo stesso file SKILL.md.

Istruzioni della skill

Questo è il contenuto di SKILL.md che il modello carica. Leggilo prima dell'installazione: una skill è un insieme di istruzioni che il tuo modello seguirà.

Phaser 4 Brownfield Project Analysis

Perform a comprehensive analysis of an existing Phaser 4 project to assess architecture quality, identify performance risks, flag API correctness issues, and produce a prioritized improvement roadmap.

Analysis Process

Follow all five phases in order. Do not skip phases — each builds on the previous.

Phase 1 — Discovery

Gather raw facts about the project before making any judgments.

  • Read package.json for dependencies and Phaser version
  • Glob for all .ts/.js files in src/
  • Read main.ts for GameConfig
  • Identify all scenes: grep "extends Phaser.Scene" across src/
  • Map scene graph: grep for this.scene.start, this.scene.launch, this.scene.stop
  • Identify all custom game objects: grep "extends Phaser.Physics" or grep "extends Phaser.GameObjects"
  • Count total source files and lines of code

Phase 2 — Architecture Assessment

Evaluate the structural quality of the codebase.

  • Scene count and organization — Are scenes in src/scenes/? Are there too many or too few for the game's complexity?
  • State management pattern — Registry vs globals vs module state. Search for window., module-level let/var declarations.
  • Asset loading strategy — Centralized PreloaderScene vs scattered preload() methods across scenes.
  • Code organization — Does the project follow scenes/, objects/, managers/ conventions?
  • Cross-scene coupling analysis — Direct references vs event bus vs Registry. Search for this.registry, this.events.emit, this.scene.get.

Rate the architecture A through F based on findings:

  • A — Clean separation, centralized loading, event-driven communication
  • B — Minor organizational gaps, mostly well-structured
  • C — Some coupling issues, mixed patterns, functional but messy
  • D — Significant structural problems, globals, scattered loading
  • F — No discernible architecture, everything in one file or deeply entangled

Phase 3 — Performance Audit

Identify runtime performance risks.

  • Object pooling: Search for classType/maxSize in group declarations. Flag physics groups created with this.physics.add.group() that lack maxSize — these leak objects.
  • Particle emitter caps: Search for particle emitters missing maxParticles. Uncapped emitters can spike frame time.
  • Static vs dynamic groups: Check if platforms, walls, and other immovable bodies use staticGroup() (correct) vs group() (wastes physics cycles).
  • Update loop weight: Read each scene's update() method. Flag complex logic, object allocations (new), or heavy iteration inside update().
  • Texture atlas usage: Count individual this.load.image() calls vs this.load.atlas() calls. More than 15 individual image loads is a red flag — should be packed into atlases.
  • Physics body count: Estimate total active physics bodies from group declarations and individual this.physics.add.* calls.

Phase 4 — API Correctness

Check for deprecated, removed, or misused APIs.

  • v3 API scan: Search for removed APIs — Geom.Point, Math.PI2, Phaser.Structs, Camera3D, Layer3D, FacebookInstant, Create.GenerateTexture, TileSprite.setCrop.
  • TypeScript strictness: Grep for as any, @ts-ignore, untyped function parameters. These hide real bugs.
  • Asset key consistency: Cross-reference this.load.* keys with this.add.*/this.physics.add.* keys. Mismatched keys cause silent texture-missing errors.
  • Scene key registration: Verify all scene classes appear in the GameConfig scene array in main.ts.
  • Physics body creation: Flag this.add.sprite() calls that should be this.physics.add.sprite() (sprites expected to have physics but created without a body).
  • DynamicTexture/RenderTexture: Check for missing .render() calls after drawing operations.

Phase 5 — Best Practice Check

Verify the project follows Phaser 4 best practices.

  • Lifecycle discipline: preload() should only load assets, create() should only build the scene, update() should be lean (no asset loading, no object creation).
  • Cleanup on shutdown: Scenes should clean up — look for this.events.off, this.sound.stopAll(), timer destruction, this.events.on('shutdown', ...).
  • Camera bounds: Camera bounds should match world or tilemap bounds. Search for this.cameras.main.setBounds and compare with world/map dimensions.
  • Input keyboard null assertions: this.input.keyboard can be null in Phaser 4. Check for this.input.keyboard! or proper null guards.
  • Physics debug flag: debug: true in physics config should be false for production. Flag if present.
  • Console statements: Count console.log/console.warn/console.error calls. These should be gated behind import.meta.env.DEV or removed for production.

Output Format

Produce a structured report with these sections:

  1. Project Summary — File count, scene count, lines of code, estimated complexity (small/medium/large).
  2. Architecture Score — Letter grade (A/B/C/D/F) with rationale for the rating.
  3. Performance Risks — Ordered by severity (critical/high/medium/low) with a concrete fix suggestion for each.
  4. Code Quality Issues — With file:line references where possible.
  5. Improvement Roadmap — Prioritized refactoring steps, ordered by impact vs effort.
  6. Quick Wins — 3-5 changes that can be made immediately for noticeable improvement.

Related Skills

  • Use /phaser-migrate to fix any Phaser v3 API issues found in Phase 4.
  • Use /phaser-physics for implementing object pooling and fixing physics group issues from Phase 3.
  • Use the phaser-debugger agent for investigating runtime performance issues flagged in Phase 3.

Reference Files

  • references/analysis-checklist.md — Complete checklist with grep patterns, severity ratings, and fix references for all checks.
  • references/performance-playbook.md — Nine-phase Phaser 4 performance playbook for mid-range mobile targets: measurement-first prompting, per-frame allocation elimination, registry throttling, audio lazy-load, VFX pooling, spatial grid, atlas packing, event throttling, AI tick-skip with real delta, tween cleanup. Read when FPS is below target or memory grows during gameplay.

Automated Pre-scan

Before starting the manual deep review, run the automated analysis script:

bash
bash "${CLAUDE_PLUGIN_ROOT}/skills/phaser-analyze/scripts/analyze-project.sh"

This provides baseline metrics and flags obvious issues. Use the script output as a starting point, then perform the full 5-phase analysis by reading actual source files.

File inclusi

Il modello legge questi file quando servono, mentre la skill è caricata. Sono accessibili in sola lettura e non vengono mai eseguiti.

Domande frequenti

Cosa fa la skill IA Phaser Analyze?

This skill should be used when the user asks to "analyze my game", "review my Phaser project", "audit project health", "find bottlenecks", "refactor my game", "improve my code", "optimize my project", "what's wrong with my game", "code review Phaser", or "assess architecture".

Perché usare Phaser Analyze su TypingMind?

Perché la installi una volta e la usi con qualsiasi modello. Phaser Analyze è scritta in semplice Markdown anziché in codice specifico di un fornitore, quindi la stessa skill funziona con GPT-5, Claude, Gemini, Grok o un modello locale, e puoi cambiare modello durante la chat senza che la skill smetta di funzionare. TypingMind usa le tue chiavi API, quindi paghi direttamente i fornitori anziché un abbonamento per posto utente, e le tue skill e chat restano nel tuo spazio di archiviazione.

Come installo Phaser Analyze in TypingMind?

Apri Plugin → Skill → Installa da GitHub in TypingMind e incolla https://github.com/Yakoub-ai/phaser4-gamedev/tree/main/skills/phaser-analyze. TypingMind legge il file SKILL.md, include i file associati e installa la skill, che puoi abilitare per ogni singola chat.

Quali modelli IA possono usare Phaser Analyze?

Qualsiasi modello che colleghi a TypingMind. Le skill IA sono semplici istruzioni in Markdown anziché codice specifico di un fornitore, quindi GPT, Claude, Gemini, Grok e i modelli locali possono tutti caricare questa skill quando una richiesta corrisponde al suo scopo.

Quanti modelli IA posso usare con Phaser Analyze?

Quanti ne vuoi. Se un modello supporta le skill, puoi usarlo con Phaser Analyze: GPT, Claude, Gemini, Grok, DeepSeek, Mistral, Llama e molti altri, tutti su TypingMind con le tue chiavi API.

La skill IA Phaser Analyze è gratuita?

È pubblicata su GitHub da Yakoub-ai. Consulta il repository per i termini di licenza. Paghi solo il tuo fornitore IA per i token che usi.

Cosa sono le skill IA?

Una skill IA è un pacchetto di istruzioni riutilizzabili che insegna a un modello IA come svolgere un'attività specifica. Segue il formato aperto Agent Skills: un file SKILL.md con un nome e una descrizione, più eventuali script, template o file di riferimento di cui il modello potrebbe aver bisogno. Il modello legge le istruzioni solo quando la tua richiesta corrisponde alla skill, quindi una skill installata non comporta costi finché non viene usata.

In cosa si differenziano le skill IA dai plugin o dai server MCP?

Un plugin o un server MCP fornisce a un modello nuovi strumenti da richiamare: codice che viene eseguito da qualche parte e restituisce un risultato. Una skill IA, invece, fornisce al modello conoscenze e procedure: come affrontare un'attività, quali passaggi seguire e quali caratteristiche deve avere un buon output. Le skill sono semplici istruzioni in Markdown, quindi non richiedono server, chiavi API né ambienti di esecuzione e funzionano con qualsiasi modello.

Elenco completo

Crea subito il tuo spazio di lavoro AI

Iscriviti alla nostra newsletter per ricevere aggiornamenti sulle nuove funzionalità e sulle prossime iniziative a premi 👇