miaoda-game-status-phaser
v0.3.0
Published
Phaser Scene status-effect host for miaoda-game-status-core.
Readme
miaoda-game-status-phaser
Use this Phaser 4 adapter to advance a StatusSet from Scene update events. It converts Phaser milliseconds to the core's chosen time unit (seconds by default in a real-time game) and cleans up on shutdown.
Install and use
pnpm add miaoda-game-status-core miaoda-game-status-phaser phaserRegister StatusPlugin and create one status set per target:
const status = this.statusSets.create(player);
status.core.apply(poisonDefinition);
status.core.apply({ id: 'stun', duration: 0.5, flags: ['stun'] });For manual ordering, create StatusController with { autoUpdate: false } and call update(deltaMs) at the desired point. setTicking(false) pauses timers without clearing effects. Destruction is terminal and releases Scene event ownership; the underlying core remains available for final observation.
