Phaser AE

Lens Flare

Free packv3.0.0-33DPost

The sun's signature on the camera: a core glow, an anamorphic streak and a halo ring at the sun, and a chain of ghost discs along the line from the sun through the centre of the screen. It needs no textures, and anything crossing the sun fades it smoothly.

This is a Free pack. Every phaser.io account can use it in their games.

Released October 14, 2026 · updated October 19, 2026

Lens Flare: a screenshot of its demo
A note about these graphics

Expansion packs don't come with graphics. This screenshot is one way of drawing what the pack does, made for its demo: none of the sprites, tiles or backgrounds in it are in the pack.

That's by design. A pack is a game's logic, mechanics and effects, and it works with whatever art you give it. Some packs draw effects, backdrops or 3D scenes of their own, but none carries a game's sprites.

So the look is yours. Make the art on phaser.io, bring your own, or let your agent draw it in code: the same pack can look like anything.

The pack

flare3d

function flare3d(opts: Flare3dOptions = {}): Pack<{ flare: Flare3dApi }>

The flare-3d pack: a procedural lens flare on the sun, depth-occluded, drawn last because a flare lives ON the lens rather than in the world. Requires a 3D world and render-3d.

Types

Flare3dApi

interface Flare3dApi

game.flare.

  • strength: number — Overall brightness, live.
  • enabled: boolean — Turn it off entirely.
  • readonly visible: boolean — Whether the sun is on screen and unoccluded enough to be drawing.

Flare3dOptions

interface Flare3dOptions

How the flare looks. Every field is live.

  • strength?: number — Overall brightness. Default 1.
  • enabled?: boolean — Whether the pass runs at all. Default true.