npm phaser 4.0.0
Phaser v4.0.0

15 hours ago

After years of development, Phaser 4 is here. This is the biggest release in Phaser's history - a ground-up rebuild of the WebGL renderer with a completely new architecture, while keeping the API you know and love.

Highlights

  • New Render Node Architecture - The v3 pipeline system has been replaced with a clean, node-based renderer. Each render node handles a single task, WebGL state is fully managed, and context restoration is built in. Faster, more reliable, and much easier to extend.
  • Unified Filter System - FX and Masks from v3 are now a single, powerful Filter system. Apply filters to any game object or camera with no restrictions. Ships with Blur, Glow, Shadow, Pixelate, ColorMatrix, Bloom, Vignette, Wipe, ImageLight, GradientMap, Quantize, Blend, and many more.
  • SpriteGPULayer - Render a million sprites in a single draw call, up to 100x faster than standard rendering. GPU-driven animations on position, rotation, scale, alpha, tint, and frame.
  • TilemapGPULayer - Render an entire tilemap layer as a single quad. Per-pixel shader cost means up to 4096 x 4096 tiles with no performance penalty. Perfect texture filtering with no seams.
  • Overhauled Tint System - Six tint modes: MULTIPLY, FILL, ADD, SCREEN, OVERLAY, HARD_LIGHT. Color and mode are now separate concerns.
  • New Game Objects - Gradient, Noise (Cell 2D/3D/4D, Simplex 2D/3D), CaptureFrame, and Stamp.
  • Improved Lighting - As simple as sprite.setLighting(true). Self-shadows, explicit light height, works across most game objects.
  • Shader and TileSprite Improvements - Cleaner config-based Shader API, #pragma GLSL directives, TileSprite now supports atlas frames and tile rotation.
  • AI Agent Skills - 28 comprehensive skill files included in the repository covering every major Phaser subsystem, plus a dedicated v3 to v4 migration skill. Point your AI coding agent at the skills/ folder for deep Phaser 4 knowledge.

Install

npm install phaser

Links

Thank You

Phaser wouldn't have been possible without the fantastic support of the community. Thank you to everyone who supports our work, who shares our belief in the future of HTML5 gaming, and Phaser's role in that.

Happy coding everyone!

Rich and the whole team at Phaser Studio

Don't miss a new phaser release

NewReleases is sending notifications on new releases.