Skip to content

notque/vexjoy-agent / skills/game/game-dev

game-dev

Flagged

Game development: design, asset pipelines, Phaser, Unity CLI and builds, vanilla JS frontend, GM mode, match booking.

FileKindSize
SKILL.mdskill md14.7 KB
references/anchor-alignment.mdmarkdown16.0 KB
references/animate-scaffolds.mdmarkdown2.0 KB
references/arcade-physics.mdmarkdown7.4 KB
references/artifacts-and-prototyping.mdmarkdown1.5 KB
references/asset-sources.mdmarkdown7.9 KB
references/audit-and-red-team.mdmarkdown795 B
references/autonomous-improvement.mdmarkdown10.3 KB
references/backend-chain.mdmarkdown10.4 KB
references/bg-removal-local.mdmarkdown22.7 KB
references/build-scaffolds.mdmarkdown2.0 KB
references/capabilities/01-design-red-team-audit.mdmarkdown3.9 KB
references/capabilities/02-emotional-canvas-moodboard.mdmarkdown3.7 KB
references/capabilities/03-game-design-attribution-audit.mdmarkdown3.6 KB
references/capabilities/04-game-design-bartle-archetype-audit.mdmarkdown3.7 KB
references/capabilities/05-game-design-big-five-personality-audit.mdmarkdown3.6 KB
references/capabilities/06-game-design-brainstorm-methods.mdmarkdown3.9 KB
references/capabilities/07-game-design-core-loop-extractor.mdmarkdown3.7 KB
references/capabilities/08-game-design-craft-critique.mdmarkdown3.5 KB
references/capabilities/09-game-design-creative-unblocker.mdmarkdown3.5 KB
references/capabilities/10-game-design-design-pillars-extractor.mdmarkdown3.5 KB
references/capabilities/11-game-design-emotional-canvas.mdmarkdown3.6 KB
references/capabilities/12-game-design-failure-loop-audit.mdmarkdown3.8 KB
references/capabilities/13-game-design-fairness-frustration-audit.mdmarkdown3.6 KB
references/capabilities/14-game-design-fantasy-extractor.mdmarkdown3.6 KB
references/capabilities/15-game-design-feature-prioritization.mdmarkdown3.6 KB
references/capabilities/16-game-design-five-options.mdmarkdown3.5 KB
references/capabilities/17-game-design-flow-audit.mdmarkdown3.6 KB
references/capabilities/18-game-design-fogg-behavior-audit.mdmarkdown3.6 KB
references/capabilities/19-game-design-friction-journey-audit.mdmarkdown3.8 KB
references/capabilities/20-game-design-ftue-hero-journey-audit.mdmarkdown3.7 KB
references/capabilities/21-game-design-goal-density-and-immediacy-audit.mdmarkdown3.5 KB
references/capabilities/22-game-design-goal-framing.mdmarkdown3.5 KB
references/capabilities/23-game-design-granular-player-motivation-audit.mdmarkdown4.0 KB
references/capabilities/24-game-design-grow-design.mdmarkdown3.5 KB
references/capabilities/25-game-design-ideal-outcome-backcasting.mdmarkdown3.4 KB
references/capabilities/26-game-design-kpi-coverage-audit.mdmarkdown3.8 KB
references/capabilities/27-game-design-leaderboard-audit.mdmarkdown3.9 KB
references/capabilities/28-game-design-leaderboard-builder.mdmarkdown3.8 KB
references/capabilities/29-game-design-molyneux-lens.mdmarkdown3.5 KB
references/capabilities/30-game-design-multiplayer-feature-audit.mdmarkdown3.8 KB
references/capabilities/31-game-design-novelty-spectrum-audit.mdmarkdown3.6 KB
references/capabilities/32-game-design-one-page-design-doc.mdmarkdown3.8 KB
references/capabilities/33-game-design-one-thing-to-remove.mdmarkdown3.6 KB
references/capabilities/34-game-design-option-generation.mdmarkdown3.5 KB
references/capabilities/35-game-design-peak-end-audit.mdmarkdown3.6 KB
references/capabilities/36-game-design-perceived-randomness-audit.mdmarkdown3.7 KB
references/capabilities/37-game-design-pitch-deck-audit.mdmarkdown3.8 KB
references/capabilities/38-game-design-player-motivation-audit.mdmarkdown3.5 KB
references/capabilities/39-game-design-player-need-satisfaction-audit.mdmarkdown3.6 KB
references/capabilities/40-game-design-player-persona-extractor.mdmarkdown4.2 KB
references/capabilities/41-game-design-player-perspective-reframe.mdmarkdown3.7 KB
references/capabilities/42-game-design-player-segment-perception-audit.mdmarkdown3.6 KB
references/capabilities/43-game-design-player-values-mapper.mdmarkdown3.8 KB
references/capabilities/44-game-design-premium-pass-audit.mdmarkdown3.8 KB
references/capabilities/45-game-design-prosocial-session-chapters.mdmarkdown3.7 KB
references/capabilities/46-game-design-prototype-intent-audit.mdmarkdown3.7 KB
references/capabilities/47-game-design-prototyping-companion.mdmarkdown3.6 KB
references/capabilities/48-game-design-roadblock-reframing.mdmarkdown3.5 KB
references/capabilities/49-game-design-smart-goal-audit.mdmarkdown3.6 KB
references/capabilities/50-game-design-social-satisfaction-matrix.mdmarkdown3.7 KB
references/capabilities/51-game-design-systematizing-empathizing-audit.mdmarkdown3.6 KB
references/capabilities/52-game-design-thinking-fast-and-slow-audit.mdmarkdown3.6 KB
references/capabilities/53-game-design-transformative-reuse.mdmarkdown3.6 KB
references/capabilities/54-game-design-unknown-unknowns-prototyping.mdmarkdown3.6 KB
references/capabilities/55-game-design-zeigarnik-effect-audit.mdmarkdown3.6 KB
references/capabilities/56-game-dev-budget-estimator.mdmarkdown3.8 KB
references/capabilities/57-game-dev-first-steps.mdmarkdown3.6 KB
references/capabilities/58-game-dev-team-gap.mdmarkdown3.6 KB
references/capabilities/59-game-dev-time-estimator.mdmarkdown3.8 KB
references/capabilities/60-moodboard-generator.mdmarkdown4.0 KB
references/capabilities/61-software-team-conflict-patterns.mdmarkdown3.8 KB
references/capability-catalog.mdmarkdown18.4 KB
references/capability-map.mdmarkdown1.7 KB
references/capability-matrix.mdmarkdown12.5 KB
references/capacitor-ios.mdmarkdown7.3 KB
references/cognition-and-choice.mdmarkdown1.2 KB
references/cognitive-and-behavioral-lenses.mdmarkdown1.2 KB
references/combat-effects-upgrade.mdmarkdown13.3 KB
references/combat-effects-upgrade/css-3d-card-transforms.mdmarkdown10.1 KB
references/combat-effects-upgrade/css-particle-migration.mdmarkdown13.3 KB
references/combat-effects-upgrade/framer-motion-combat-juice.mdmarkdown11.9 KB
references/concept-and-loop.mdmarkdown1.5 KB
references/core-loop-and-pillars.mdmarkdown835 B
references/core-patterns.mdmarkdown8.2 KB
references/cpu-systems-harmony.mdmarkdown3.4 KB
references/creative-and-options.mdmarkdown2.0 KB
references/creative-direction.mdmarkdown1.3 KB
references/deploy.mdmarkdown5.3 KB
references/design-artifacts.mdmarkdown1.0 KB
references/emotion-and-presentation.mdmarkdown1.1 KB
references/error-catalog.mdmarkdown22.6 KB
references/fairness-and-failure.mdmarkdown1.2 KB
references/fairness-and-learning.mdmarkdown1.3 KB
references/fal-ai-image.mdmarkdown7.1 KB
references/frame-detection.mdmarkdown20.0 KB
references/full-diagnostic.mdmarkdown4.2 KB
references/game-asset-generator.mdmarkdown9.5 KB
references/game-audio.mdmarkdown7.5 KB
references/game-feel-patterns.mdmarkdown12.2 KB
references/game-pipeline.mdmarkdown11.5 KB
references/game-qa.mdmarkdown6.7 KB
references/game-sprite-pipeline.mdmarkdown33.4 KB
references/gm-brilliant-implementation.mdmarkdown13.4 KB
references/grid-shapes.mdmarkdown8.0 KB
references/meshyai.mdmarkdown7.3 KB
references/motion-pipeline.mdmarkdown7.6 KB
references/output-formats.mdmarkdown9.4 KB
references/pacing-and-return.mdmarkdown1.6 KB
references/performance.mdmarkdown7.8 KB
references/phaser-gamedev.mdmarkdown7.5 KB
references/pipeline-spec.jsonconfig23.5 KB
references/pixel-art-sprites.mdmarkdown8.7 KB
references/pixijs-combat-renderer.mdmarkdown12.1 KB
references/pixijs-combat-renderer/combat-visual-effects.mdmarkdown7.8 KB
references/pixijs-combat-renderer/pixi-2d-lighting.mdmarkdown6.6 KB
references/pixijs-combat-renderer/pixi-particle-systems.mdmarkdown9.2 KB
references/pixijs-combat-renderer/pixi-performance.mdmarkdown4.8 KB
references/pixijs-combat-renderer/pixi-post-processing.mdmarkdown6.3 KB
references/pixijs-combat-renderer/pixi-react-integration.mdmarkdown5.2 KB
references/planning-and-communication.mdmarkdown1.6 KB
references/planning-and-production.mdmarkdown1.8 KB
references/player-and-social.mdmarkdown2.3 KB
references/polish-scaffolds.mdmarkdown1.9 KB
references/progression-and-economy.mdmarkdown1.0 KB
references/promo-video.mdmarkdown6.6 KB
references/prompt-rules.mdmarkdown15.2 KB
references/quality-gates.mdmarkdown6.4 KB
references/rive-skeletal-animator.mdmarkdown7.6 KB
references/rive-skeletal-animator/rive-animation-library.mdmarkdown8.1 KB
references/rive-skeletal-animator/rive-async-patterns.mdmarkdown5.6 KB
references/rive-skeletal-animator/rive-character-pipeline.mdmarkdown5.6 KB
references/rive-skeletal-animator/rive-performance.mdmarkdown5.4 KB
references/rive-skeletal-animator/rive-react-setup.mdmarkdown9.9 KB
references/rive-skeletal-animator/rive-vs-spine-decision.mdmarkdown6.0 KB
references/road-to-aew-integration.mdmarkdown7.8 KB
references/social-and-competitive-design.mdmarkdown1.1 KB
references/social-and-competitive.mdmarkdown1.5 KB
references/spritesheets.mdmarkdown6.2 KB
references/stage-contracts.mdmarkdown11.1 KB
references/style-presets.mdmarkdown5.1 KB
references/subagent-delegation.mdmarkdown2.2 KB
references/tilemaps-and-physics.mdmarkdown13.6 KB
references/tilemaps.mdmarkdown7.0 KB
references/unity-batchmode-builds.mdmarkdown9.2 KB
references/unity-cli.mdmarkdown10.9 KB
references/unity-licensing.mdmarkdown5.0 KB
references/vfx-containment.mdmarkdown3.1 KB
references/workflow-dag.mdmarkdown4.1 KB
references/worldlabs.mdmarkdown7.9 KB
references/wrestler-archetypes.mdmarkdown7.2 KB
scripts/deterministic_idle.pyscript7.8 KB
scripts/fal_queue_image_run.pyscript9.4 KB
scripts/imgdiff.pyscript5.0 KB
scripts/meshy-generate.mjsscript11.1 KB
scripts/optimize-glb.mjsscript3.8 KB
scripts/portrait_pipeline.pyscript31.2 KB
scripts/qa_artifacts.pyscript14.4 KB
scripts/road_to_aew_integration.pyscript6.6 KB
scripts/row_job_status.pyscript8.6 KB
scripts/sprite_anchor.pyscript30.1 KB
scripts/sprite_assemble.pyscript16.0 KB
scripts/sprite_bg.pyscript28.5 KB
scripts/sprite_canvas.pyscript11.9 KB
scripts/sprite_generate.pyscript13.9 KB
scripts/sprite_pipeline.pyscript54.9 KB
scripts/sprite_process.pyscript13.5 KB
scripts/sprite_prompt.pyscript41.8 KB
scripts/sprite_slicing.pyscript38.7 KB
scripts/sprite_verify.pyscript58.5 KB
scripts/test_content_aware_extraction.pyscript13.4 KB
scripts/test_no_status_laundering.pyscript6.9 KB
scripts/test_phases_4_5_7_8.pyscript16.4 KB
scripts/test_pipeline_glue.pyscript20.9 KB
scripts/test_pipeline_patterns.pyscript10.9 KB
scripts/test_rc3_frames_distinct_threshold.pyscript14.2 KB
scripts/test_rc4_mass_centroid_default.pyscript8.3 KB
scripts/test_rc5_despill_pre_upscale.pyscript7.9 KB
scripts/test_slice_grid_cells.pyscript6.4 KB
scripts/test_slicer_strict_pitch_default.pyscript11.6 KB
scripts/test_verifier_cell_parity.pyscript9.0 KB
scripts/test_verify_gates.pyscript23.2 KB
scripts/tests/test_fal_queue_image_run.pyscript908 B
scripts/video_extract_frames.pyscript4.3 KB
scripts/video_process_frames.pyscript7.6 KB
scripts/video_select_frames.pyscript6.4 KB
scripts/with_server.pyscript5.8 KB

references/game-feel-patterns.md

View on GitHub
---
description: Screen shake, particle bursts, hit pause, scale punch, tween chaining, sound timing — techniques that make Phaser 3 games feel polished and responsive
agent: phaser-gamedev
category: visual-techniques
version_range: "Phaser 3.60+"
---

# Game Feel Patterns Reference

> **Scope**: "Juice" — the collection of micro-feedback effects that make a game feel satisfying. Camera shake, particles, time dilation, hit stop, scale punch, tween chains, and audio timing. Does NOT cover physics setup or tilemap config.
> **Version range**: Phaser 3.60+
> **Generated**: 2026-04-08

---

## Screen Shake

Camera shake is the most visceral hit-feedback tool. Phaser 3.60+ has `camera.shake()` built in.

```typescript
// Basic shake on hit — parameters: duration (ms), intensity (0-1)
this.cameras.main.shake(150, 0.008);

// Directional shake via camera.pan() + tween
// Use for knockback-directional feedback (e.g., hit from left = camera moves left then returns)
hitFromLeft(): void {
  this.tweens.add({
    targets: this.cameras.main,
    scrollX: this.cameras.main.scrollX - 12, // push camera left
    duration: 60,
    ease: 'Power2',
    yoyo: true,   // return to original position
    repeat: 2,    // 2 oscillations
  });
}

// Strong boss hit: combined shake + flash
onBossHit(): void {
  this.cameras.main.shake(300, 0.02);
  this.cameras.main.flash(100, 255, 200, 0, false); // flash: duration, r, g, b, force
}
```

**Shake intensity guide**:
| Event | Duration (ms) | Intensity |
|-------|--------------|-----------|
| Player takes damage | 120 | 0.006 |
| Enemy dies | 200 | 0.012 |
| Explosion | 350 | 0.025 |
| Boss attack | 400 | 0.035 |

---

## Particle Burst Effects (Phaser 3.60+ API)

Phaser 3.60 rewrote the particle system. The old `ParticleEmitterManager` API is removed.

```typescript
// Coin collect burst — Phaser 3.60+ API
onCoinCollect(x: number, y: number): void {
  const emitter = this.add.particles(x, y, 'spark', {
    speed: { min: 80, max: 200 },
    angle: { min: 0, max: 360 },
    scale: { start: 0.6, end: 0 },
    alpha: { start: 1, end: 0 },
    lifespan: 500,
    quantity: 12,
    tint: [0xffdd00, 0xffaa00, 0xffffff],
    gravityY: 300,
    emitting: false, // don't emit continuously
  });

  emitter.explode(12, x, y); // fire burst, then auto-destroy after all particles die
  // Emitter auto-destroys when all particles expire (Phaser 3.60+ default)
}

// Hit sparks (directional)
onHit(x: number, y: number, directionX: number): void {
  const emitter = this.add.particles(x, y, 'spark', {
    speed: { min: 100, max: 250 },
    angle: { min: -30, max: 30 },          // narrow cone forward
    rotate: { min: 0, max: 360 },
    scale: { start: 0.4, end: 0 },
    lifespan: 300,
    quantity: 6,
    gravityY: 500,
    emitting: false,
  });

  emitter.setParticleRotation(directionX > 0 ? 0 : 180); // face hit direction
  emitter.explode(6, x, y);
}

// Continuous trail effect (stops when assigned sprite is recycled)
attachTrail(sprite: Phaser.GameObjects.Sprite): Phaser.GameObjects.Particles.ParticleEmitter {
  return this.add.particles(0, 0, 'trail', {
    follow: sprite,           // emitter follows sprite
    followOffset: { x: -sprite.width / 2, y: 0 },
    speed: 20,
    lifespan: 200,
    scale: { start: 0.3, end: 0 },
    alpha: { start: 0.6, end: 0 },
    frequency: 16,            // emit every 16ms (~60fps)
  });
}
```

---

## Hit Pause / Time Dilation

Briefly stopping time on a heavy hit makes the impact feel weighty. Phaser uses `this.physics.world.timeScale` and scene's `this.time.timeScale`.

```typescript
// Hit stop: freeze game time for N ms then resume
hitStop(duration: number = 80): void {
  if (this.hitStopActive) return; // prevent stacking
  this.hitStopActive = true;

  this.physics.world.timeScale = 0.0001; // near-zero (can't be exactly 0)
  this.tweens.timeScale = 0.0001;
  this.time.timeScale = 0.0001;

  this.time.delayedCall(duration, () => {
    this.physics.world.timeScale = 1;
    this.tweens.timeScale = 1;
    this.time.timeScale = 1;
    this.hitStopActive = false;
  });
}

// Slow-motion mode (bullet time)
enterSlowMo(duration: number = 2000): void {
  this.physics.world.timeScale = 0.25;
  this.tweens.timeScale = 0.25;
  this.time.timeScale = 0.25;
  this.sound.setRate(0.8); // Phaser 3.60+: slow audio pitch

  this.time.delayedCall(duration, () => {
    this.physics.world.timeScale = 1;
    this.tweens.timeScale = 1;
    this.time.timeScale = 1;
    this.sound.setRate(1.0);
  });
}
```

---

## Scale Punch (Squash and Stretch)

Scale punch on hit makes sprites feel physical. Classic squash-and-stretch on impact:

```typescript
// Scale punch: fast enlarge → squash → return to normal
scalePunch(target: Phaser.GameObjects.Sprite, punchX = 1.4, punchY = 0.7): void {
  this.tweens.add({
    targets: target,
    scaleX: punchX,
    scaleY: punchY,
    duration: 60,
    ease: 'Back.easeOut',
    yoyo: true,                           // auto-return to original scale
    onComplete: () => {
      target.setScale(1);                 // ensure perfect reset
    },
  });
}

// Wobble: oscillating scale for collecting items
wobble(target: Phaser.GameObjects.Sprite): void {
  this.tweens.add({
    targets: target,
    scaleX: { from: 1, to: 1.2 },
    scaleY: { from: 1, to: 0.85 },
    duration: 80,
    ease: 'Sine.easeInOut',
    yoyo: true,
    repeat: 2,
    onComplete: () => target.setScale(1),
  });
}

// Death spin: rotation + scale fade for enemies
dieEffect(target: Phaser.GameObjects.Sprite): void {
  this.tweens.add({
    targets: target,
    angle: 720,               // two full rotations
    scaleX: 0,
    scaleY: 0,
    alpha: 0,
    duration: 400,
    ease: 'Power2.easeIn',
    onComplete: () => target.destroy(),
  });
}
```

---

## Tween Chaining

Tween chains let you sequence effects without manual timers:

```typescript
// Chain: damage flash → shake → return to normal
onPlayerHit(player: Phaser.GameObjects.Sprite): void {
  // Prevent multiple chains running simultaneously
  if (player.getData('invincible')) return;
  player.setData('invincible', true);

  this.tweens.chain({
    targets: player,
    tweens: [
      {
        alpha: 0.2,
        duration: 60,
        ease: 'Linear',
        yoyo: true,
        repeat: 5, // 6 flashes total = 720ms invincibility
      },
      {
        alpha: 1,
        duration: 1,
        onComplete: () => player.setData('invincible', false),
      },
    ],
  });

  this.cameras.main.shake(100, 0.005);
}

// Score popup: rise + fade
showScorePopup(x: number, y: number, points: number): void {
  const text = this.add.text(x, y, `+${points}`, {
    fontSize: '20px',
    color: '#ffdd00',
    stroke: '#000',
    strokeThickness: 3,
  }).setOrigin(0.5).setDepth(100);

  this.tweens.chain({
    targets: text,
    tweens: [
      { y: y - 40, scaleX: 1.2, scaleY: 1.2, duration: 200, ease: 'Back.easeOut' },
      { y: y - 80, scaleX: 1, scaleY: 1, alpha: 0, duration: 400, ease: 'Power2.easeIn' },
    ],
    onComplete: () => text.destroy(),
  });
}
```

---

## Sound Cue Timing Patterns

Sound timing is critical for feeling responsive. Phaser 3.60+ Web Audio has predictable latency.

```typescript
// Play sound with attack on physics contact (not on timer)
setupSoundCues(): void {
  // Preload in BootScene.preload():
  // this.load.audio('hit', ['assets/sounds/hit.ogg', 'assets/sounds/hit.mp3']);
  // this.load.audio('pickup', ['assets/sounds/pickup.ogg']);

  this.hitSound = this.sound.add('hit', { volume: 0.7 });
  this.pickupSound = this.sound.add('pickup', { volume: 0.5 });

  // Multiple hit sounds avoid "machine gun" repetition
  this.hitSounds = [
    this.sound.add('hit_1', { volume: 0.7 }),
    this.sound.add('hit_2', { volume: 0.6 }),
    this.sound.add('hit_3', { volume: 0.8 }),
  ];
}

playHit(): void {
  // Randomize pitch to avoid identical sounds feeling robotic
  const sound = Phaser.Utils.Array.GetRandom(this.hitSounds) as Phaser.Sound.WebAudioSound;
  sound.setRate(Phaser.Math.FloatBetween(0.9, 1.1));
  sound.play();
}

// Sound with camera shake: start at same frame for synchronized feel
onEnemyDeath(x: number, y: number): void {
  this.sound.play('explosion', { volume: 0.9 });
  this.cameras.main.shake(200, 0.015);    // same frame — synchronized impact
  this.createDeathParticles(x, y);         // same frame
}
```

---

## Pattern Catalog

### Use Particle Bursts as Primary Hit Feedback

**Detection**:
```bash
grep -rn "tween.*alpha\|alpha.*tween" --include="*.ts" --include="*.js"
rg "alpha.*0\b" --type ts -B 2 | grep "onHit\|takeDamage\|damage\|hit"
```

**Signal**:
```typescript
// BAD: alpha blink communicates "invisible" not "impact"
onHit(): void {
  this.tweens.add({
    targets: this.player,
    alpha: { from: 0, to: 1 },
    repeat: 5,
    duration: 80,
  });
}
```

**Why this matters**: Alpha blink is invisible feedback — it removes the visual, it doesn't add one. Players learn to "feel" hits through additive signals: particles appear, camera moves, sound plays. Removing the player sprite subtracts the signal.

**Preferred action**: Use alpha blink for invincibility indication (secondary) and add a particle burst (primary hit feedback):
```typescript
onHit(): void {
  // Primary: add particles at hit position
  this.add.particles(this.player.x, this.player.y, 'spark', {
    speed: { min: 60, max: 150 }, quantity: 8, lifespan: 250, emitting: false,
  }).explode(8);
  // Secondary: blink for invincibility window
  this.tweens.add({ targets: this.player, alpha: { from: 0.3, to: 1 }, repeat: 4, duration: 80 });
}
```

---

### Pool Physics Bodies in create(), Recycle in update()

**Detection**:
```bash
grep -rn "physics\.add\.\(sprite\|image\|existing\)\|add\.group" --include="*.ts" --include="*.js"
rg "update\(.*delta\)" --type ts -A 30 | grep "physics\.add"
```

**Signal**:
```typescript
update(_time: number, _delta: number): void {
  if (this.fireButton.isDown) {
    // BAD: new physics sprite every frame the button is held
    const bullet = this.physics.add.image(this.player.x, this.player.y, 'bullet');
    bullet.setVelocityX(400);
  }
}
```

**Why this matters**: Creating physics bodies in `update()` allocates Box2D/Arcade body objects and THREE.js objects every frame. GC pressure causes visible stuttering at sustained fire rates. Frame rate drops from 60 to 30 after ~5 seconds of firing.

**Preferred action**: Pool bullets in `create()`, recycle in `update()`:
```typescript
create(): void {
  this.bullets = this.physics.add.group({
    classType: Phaser.Physics.Arcade.Image,
    maxSize: 20,
    runChildUpdate: false,
  });
}

fireBullet(): void {
  const bullet = this.bullets.get(this.player.x, this.player.y, 'bullet');
  if (!bullet) return;
  bullet.setActive(true).setVisible(true);
  bullet.body.setVelocityX(400);
}
```

---

### Set Camera Bounds Before Shake Calls

**Detection**:
```bash
grep -rn "camera\.shake\|cameras\.main\.shake" --include="*.ts" --include="*.js"
rg "cameras\.main" --type ts | grep -v "bounds\|follow\|setZoom"
```

**Signal**:
```typescript
// BAD: camera shakes past world edge, revealing void outside the map
this.cameras.main.shake(300, 0.05); // no world bounds set
```

**Why this matters**: Camera shake pans the camera. Without bounds, the camera reveals empty space outside the tilemap, breaking immersion.

**Preferred action**:
```typescript
// Set bounds before any shake call
this.cameras.main.setBounds(0, 0, map.widthInPixels, map.heightInPixels);
this.cameras.main.shake(300, 0.02); // now shake is clamped to world edge
```

---

## Detection Commands Reference

```bash
# Find all shake calls — verify intensity is appropriate
grep -rn "cameras\.main\.shake" --include="*.ts" --include="*.js"

# Find particle emitters — verify using Phaser 3.60+ API (not old ParticleEmitterManager)
grep -rn "ParticleEmitterManager\|createEmitter" --include="*.ts"

# Find tween.add calls — check for yoyo/repeat patterns for polish
grep -rn "tweens\.add\|tweens\.chain" --include="*.ts" --include="*.js"

# Find timeScale usage — verify hit-stop cleanup resets all time scales
grep -rn "timeScale" --include="*.ts" --include="*.js"
```

---

## See Also

- `references/tilemaps-and-physics.md` — Tilemap collision, Matter.js categories, slope terrain
- `references/core-patterns.md` — Scene lifecycle, state machines, input
- `references/performance.md` — Object pooling, GC avoidance
writing-skillsobra/superpowersUse when creating new skills, editing existing skills, or verifying skills work before deploymentStars: 322kUpdated Claude CodeCodexVerifiedInstall
xlsxanthropics/skillsUse this skill any time a spreadsheet file is the primary input or output. This means any task where the user wants to: open, read, edit, or fix an existing .xlsx, .xlsm, .xltx, .csv, or .tsv file (e.g., adding columns, computing formulas, formatting, charting, cleaning messy data); create a new spreadsheet from scratch or from other data sources; or convert between tabular file formats. Trigger especially when the user references a spreadsheet file by name or path — even casually (like "the xlsx in my downloads") — and wants something done to it or produced from it. Also trigger for cleaning or restructuring messy tabular data files (malformed rows, misplaced headers, junk data) into proper spreadsheets. The deliverable must be a spreadsheet file. Do NOT trigger when the primary deliverable is a Word document, HTML report, standalone Python script, database pipeline, or Google Sheets API integration, even if tabular data is involved.Stars: 198kUpdated Claude CodeCodexVerifiedInstall
shipping-and-launchaddyosmani/agent-skillsPrepares production launches. Use when preparing to deploy to production, or when asking what needs to be in place before shipping. Use when you need a pre-launch checklist, when setting up monitoring, when planning a staged rollout, or when you need a rollback strategy.Stars: 119kUpdated Claude CodeCodexVerifiedInstall
childhoodthedotmack/claude-memBabysit a shipped release after merge, publication, or deployment. Verify published packages, production behavior, installed plugins, and late CI or user reports until the observation window is clean; use babysit for PR readiness before release.Stars: 118kUpdated Claude CodeCodexVerifiedInstall