2019-06-26 16:43:43 +00:00
|
|
|
/**
|
|
|
|
* @author Richard Davey <rich@photonstorm.com>
|
2022-02-28 14:29:51 +00:00
|
|
|
* @copyright 2022 Photon Storm Ltd.
|
2019-06-26 16:43:43 +00:00
|
|
|
* @license {@link https://opensource.org/licenses/MIT|MIT License}
|
|
|
|
*/
|
|
|
|
|
|
|
|
/**
|
|
|
|
* The Tween Start Event.
|
2022-02-28 14:29:51 +00:00
|
|
|
*
|
2019-06-27 00:00:37 +00:00
|
|
|
* This event is dispatched by a Tween when it starts tweening its first property.
|
2022-02-28 14:29:51 +00:00
|
|
|
*
|
2019-06-27 00:00:37 +00:00
|
|
|
* A Tween will only emit this event once, as it can only start once.
|
2022-02-28 14:29:51 +00:00
|
|
|
*
|
2019-06-27 00:00:37 +00:00
|
|
|
* If a Tween has a `delay` set, this event will fire after that delay expires.
|
2022-02-28 14:29:51 +00:00
|
|
|
*
|
2019-06-26 16:43:43 +00:00
|
|
|
* Listen to it from a Tween instance using `Tween.on('start', listener)`, i.e.:
|
2022-02-28 14:29:51 +00:00
|
|
|
*
|
2019-06-26 16:43:43 +00:00
|
|
|
* ```javascript
|
|
|
|
* var tween = this.tweens.add({
|
|
|
|
* targets: image,
|
2019-06-27 00:00:37 +00:00
|
|
|
* x: 500,
|
2019-06-26 16:43:43 +00:00
|
|
|
* ease: 'Power1',
|
2019-06-27 00:00:37 +00:00
|
|
|
* duration: 3000
|
2019-06-26 16:43:43 +00:00
|
|
|
* });
|
|
|
|
* tween.on('start', listener);
|
|
|
|
* ```
|
|
|
|
*
|
|
|
|
* @event Phaser.Tweens.Events#TWEEN_START
|
2022-09-21 21:01:03 +00:00
|
|
|
* @type {string}
|
2019-06-26 16:43:43 +00:00
|
|
|
* @since 3.19.0
|
2022-02-28 14:29:51 +00:00
|
|
|
*
|
2019-06-26 16:43:43 +00:00
|
|
|
* @param {Phaser.Tweens.Tween} tween - A reference to the Tween instance that emitted the event.
|
2022-08-19 15:44:41 +00:00
|
|
|
* @param {(any|any[])} targets - The targets of the Tween. If this Tween has multiple targets this will be an array of the targets.
|
2019-06-26 16:43:43 +00:00
|
|
|
*/
|
|
|
|
module.exports = 'start';
|