UNPKG

phaser

Version:

A fast, free and fun HTML5 Game Framework for Desktop and Mobile web browsers from the team at Phaser Studio Inc.

31 lines (29 loc) 811 B
/** * @author Richard Davey <rich@phaser.io> * @copyright 2013-2025 Phaser Studio Inc. * @license {@link https://opensource.org/licenses/MIT|MIT License} */ /** * The Destroy Camera Event. * * This event is dispatched by a Camera instance when it is destroyed by the Camera Manager. * * Listen for it via either of the following: * * ```js * this.cameras.main.on('cameradestroy', () => {}); * ``` * * or use the constant, to avoid having to remember the correct event string: * * ```js * this.cameras.main.on(Phaser.Cameras.Scene2D.Events.DESTROY, () => {}); * ``` * * @event Phaser.Cameras.Scene2D.Events#DESTROY * @type {string} * @since 3.0.0 * * @param {Phaser.Cameras.Scene2D.BaseCamera} camera - The camera that was destroyed. */ module.exports = 'cameradestroy';