phaser v4.0.0

v4.0.0

Phaser v4.0.0

Added 4
  • Add Filter system with Blur, Glow, Shadow, Pixelate, ColorMatrix, Bloom, Vignette, Wipe, ImageLight, GradientMap, Quantize, and Blend filters
  • Add SpriteGPULayer to render millions of sprites in a single draw call with GPU-driven animations on position, rotation, scale, alpha, tint, and frame
  • Add TilemapGPULayer to render entire tilemap layers as a single quad with support for up to 4096 x 4096 tiles
  • Add new game objects: Gradient, Noise (Cell 2D/3D/4D, Simplex 2D/3D), CaptureFrame, and Stamp
Changed 6
  • Replace v3 pipeline system with a new node-based renderer where each render node handles a single task with fully managed WebGL state and built-in context restoration
  • Unify FX and Masks from v3 into a single powerful Filter system applicable to any game object or camera
  • Overhaul tint system with six tint modes: MULTIPLY, FILL, ADD, SCREEN, OVERLAY, HARD_LIGHT, separating color and mode as distinct concerns
  • Improve lighting system to be activated with sprite.setLighting(true) with self-shadows and explicit light height support across most game objects
  • Implement cleaner config-based Shader API with #pragma GLSL directive support
  • Enhance TileSprite to support atlas frames and tile rotation

From phaser

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

View original

Upgraded? How did it go?

Discussion