Phaser AE

Snow roll

Pro packv3.0.0-12DArcade

Snow that turns enemies into snowballs, and snowballs that roll: thrown snow covers an enemy until it is trapped, the player pushes or kicks the ball, and it rolls down the level crushing everything in its path in a chain. It works in any platform game built on the platform packs, not only a single-screen arcade one.

This is a Pro pack. Upgrade to Phaser Pro to use it in your games.See Phaser Pro →

Released October 19, 2026 · updated October 20, 2026

Snow roll: 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

snowRoll

function snowRoll(): Pack<{ snowRoll: typeof api }>

Install the snow-roll API (game.snowRoll).

Helpers

createSnow

function createSnow(o: SnowOptions): SnowField

Create a snow field over a walker world and an enemy director.

snowSettings

function snowSettings(o: Partial<SnowSettings> = {}): SnowSettings

Defaults: Snow Bros on 16 px tiles (estimates from play; see the docs).

Types

SnowBall

interface SnowBall

A snowball's motion state.

  • state: "rest" | "rolling" — 'rest' (pushable, kickable, standable) or 'rolling'.
  • dir: -1 | 1 — Rolling or pushed direction.
  • bounces: number — Wall rebounds so far.
  • chain: number — Chain id (0 at rest before any kick).
  • rolled: number — Seconds rolling.
  • rest: number — Seconds at rest (toward hold).
  • carried: string[] — Player bodies carried inside.

SnowChain

interface SnowChain

A kick chain: one kicked snowball and everything it set rolling.

  • id: number — Chain id.
  • by: string — Kicker body id.
  • kills: number — Enemies killed so far.
  • alive: number — Enemies alive (not waiting) when it was kicked.

SnowCover

interface SnowCover

Snow on one enemy.

  • enemy: string — Enemy (walker body) id.
  • kind: string — Enemy kind.
  • units: number — Snow units (1 .. cover).
  • timer: number — Seconds since the last hit (melting clock).
  • ball: SnowBall | null — Present when fully covered.
  • profile: WalkerProfile — The enemy's own profile, restored when the ball melts.

SnowEvent

type SnowEvent = | { kind: "thrown"; id: string; owner: string; x: number; y: number } | { kind: "hit"; id: string; enemy: string; enemyKind: string; units: number; full: boolean; by: string; x: number; y: number } | { kind: "snowball"; enemy: string; enemyKind: string; x: number; y: number } | { kind: "melted"; enemy: string; units: number } | { kind: "freed"; enemy: string; enemyKind: string } | { kind: "kicked"; enemy: string; by: string; dir: -1 | 1; chain: number } | { kind: "pushed"; enemy: string; by: string; dir: -1 | 1 } | { kind: "rebound"; enemy: string; bounces: number } | { kind: "chained"; enemy: string; chain: number } | { kind: "crushed"; enemy: string; enemyKind: string; chain: number; index: number; by: string; x: number; y: number } | { kind: "struck"; enemy: string; ball: string; chain: number; by: string; x: number; y: number } | { kind: "shattered"; enemy: string; enemyKind: string; chain: number; index: number; by: string; x: number; y: number } | { kind: "carried"; player: string; ball: string } | { kind: "released"; player: string; x: number; feet: number } | { kind: "chain-end"; chain: number; by: string; kills: number; alive: number }

Snow events from drain().

SnowField

interface SnowField extends WalkerController

The snow field: a walker controller plus throwing, kicking and queries.

  • readonly settings: Readonly<SnowSettings> — Settings in force.
  • readonly shots: SnowShot[] — Copies of the shots.
  • readonly covers: SnowCover[] — Copies of the covers (partly covered enemies and snowballs).
  • cover(enemyId: string): SnowCover | null — The cover on one enemy, or null.
  • configure(o: Partial<SnowSettings>): void — Change settings.
  • throw(bodyId: string, o?: { range?: number; power?: number; speed?: number }): string | null — Throw snow from a body in its facing direction. Returns the shot id or null when full.
  • kick(bodyId: string): string | null — Kick the resting snowball next to a body (in front of it). Returns the snowball's enemy id or null.
  • fire(bodyId: string, o?: { range?: number; power?: number; speed?: number }): { kicked: string } | { shot: string } | null — Kick if a snowball is in front, otherwise throw.
  • pushing(bodyId: string): boolean — Whether a body pushed a snowball during the last step.
  • addSnow(enemyId: string, units: number, by?: string): void — Add snow to an enemy directly (power-ups, tests).
  • clear(): void — Remove every shot and melt every cover (enemies resume).
  • drain(): SnowEvent[] — Events since the last drain.
  • snapshot(): SnowSnapshot — Serialisable state.
  • restore(s: SnowSnapshot): void — Restore a snapshot (restore the world and director too).

SnowOptions

interface SnowOptions

Options for createSnow.

  • world: WalkerWorld — The walker world.
  • enemies: EnemyDirector — The enemy director.
  • settings?: Partial<SnowSettings> — Rules (partial; defaults are Snow Bros').
  • canCover?: (enemyId: string, kind: string) => boolean — Which enemies snow can cover (default any active enemy).
  • isTough?: (enemyId: string, kind: string) => boolean — Enemies a rolling snowball strikes without killing (bosses): the ball shatters and a 'struck' event fires.
  • id?: string — Controller id. Default 'snow'.
  • attach?: boolean — Add itself to the world as a controller. Default true.

SnowSettings

interface SnowSettings

Snow rules. Distances in world units, times in seconds.

  • shotSpeed: number — Snow shot speed, units per second. Default 210.
  • shotRange: number — Distance a shot flies level before it drops. Default 48.
  • shotGravity: number — Gravity on a dropping shot, units/s². Default 700.
  • shotSize: number — Shot hit size (half extent). Default 4.
  • shotLife: number — Seconds a shot lives. Default 1.2.
  • cover: number — Snow units that make a full snowball. Default 4.
  • power: number — Units a shot adds (a power potion doubles it). Default 1.
  • melt: number — Seconds without a hit before a partly covered enemy sheds one unit. Default 1.4.
  • hold: number — Seconds a full snowball holds before the enemy starts to break out. Default 6.
  • ballSize: number — Snowball size (width and height). Default 22.
  • kickSpeed: number — Rolling speed after a kick, units per second. Default 240.
  • pushSpeed: number — Speed of a pushed snowball, units per second. Default 40.
  • ballGravity: number — Gravity on a snowball, units/s². Default 700.
  • maxBounces: number — Wall rebounds before a rolling snowball shatters. Default 8.
  • breakRow: number | null — A rolling snowball shatters when it hits a wall while on this map row (default: the bottom row, -1). null: never.
  • rollLife: number — Seconds a snowball may roll before it shatters. Default 12.
  • carryPlayers: boolean — Rolling snowballs sweep up players and carry them (invulnerable) until they shatter. Default true.
  • carryImmune: number — Seconds a released player cannot be swept up again. Default 1.5.
  • playerTag: string — Tag of player bodies (pushers, kickers, riders). Default 'player'.
  • maxShots: number — Most shots at once (resource bound). Default 64.

SnowShot

interface SnowShot

A snow shot in flight.

  • id: string — Stable id.
  • owner: string — Thrower body id.
  • x: number — Centre x.
  • y: number — Centre y.
  • vx: number — Velocity x.
  • vy: number — Velocity y.
  • age: number — Seconds alive.
  • travelled: number — Distance flown.
  • range: number — Level flight distance.
  • power: number — Snow units it adds.

SnowSnapshot

interface SnowSnapshot

Serialisable state.

  • shots: SnowShot[] — Shots.
  • covers: SnowCover[] — Covers.
  • chains: SnowChain[] — Chains still rolling.
  • seq: number — Counters.
  • chainSeq: number — Chain counter.
  • immune: [string, number][] — Released players' immunity (body id, seconds).
  • pushers: string[] — Pushers this step.
  • settings: SnowSettings — Settings.
  • events: SnowEvent[] — Undrained events.