mirror of
https://github.com/photonstorm/phaser
synced 2024-11-28 15:41:37 +00:00
Added preDestroy handler
This commit is contained in:
parent
bf65d6b577
commit
5022830c7a
1 changed files with 20 additions and 0 deletions
|
@ -901,6 +901,26 @@ var Rope = new Class({
|
|||
return this;
|
||||
},
|
||||
|
||||
/**
|
||||
* Handles the pre-destroy step for the Rope, which removes the Animation component and typed arrays.
|
||||
*
|
||||
* @method Phaser.GameObjects.Rope#preDestroy
|
||||
* @private
|
||||
* @since 3.23.0
|
||||
*/
|
||||
preDestroy: function ()
|
||||
{
|
||||
this.anims.destroy();
|
||||
|
||||
this.anims = undefined;
|
||||
|
||||
this.points = null;
|
||||
this.vertices = null;
|
||||
this.uv = null;
|
||||
this.colors = null;
|
||||
this.alphas = null;
|
||||
},
|
||||
|
||||
/**
|
||||
* The horizontally flipped state of the Game Object.
|
||||
*
|
||||
|
|
Loading…
Reference in a new issue