mirror of
https://github.com/photonstorm/phaser
synced 2024-11-22 04:33:31 +00:00
New Spine Plugin build
This commit is contained in:
parent
ce2918d66b
commit
215c310341
12 changed files with 94674 additions and 2102 deletions
1549
plugins/spine/dist/SpineCanvasPlugin.js
vendored
1549
plugins/spine/dist/SpineCanvasPlugin.js
vendored
File diff suppressed because it is too large
Load diff
2
plugins/spine/dist/SpineCanvasPlugin.min.js
vendored
2
plugins/spine/dist/SpineCanvasPlugin.min.js
vendored
File diff suppressed because one or more lines are too long
44735
plugins/spine/dist/SpineCanvasPluginDebug.js
vendored
Normal file
44735
plugins/spine/dist/SpineCanvasPluginDebug.js
vendored
Normal file
File diff suppressed because it is too large
Load diff
1
plugins/spine/dist/SpineCanvasPluginDebug.js.map
vendored
Normal file
1
plugins/spine/dist/SpineCanvasPluginDebug.js.map
vendored
Normal file
File diff suppressed because one or more lines are too long
1573
plugins/spine/dist/SpinePlugin.js
vendored
1573
plugins/spine/dist/SpinePlugin.js
vendored
File diff suppressed because it is too large
Load diff
2
plugins/spine/dist/SpinePlugin.min.js
vendored
2
plugins/spine/dist/SpinePlugin.min.js
vendored
File diff suppressed because one or more lines are too long
180
plugins/spine/dist/SpinePluginDebug.js
vendored
180
plugins/spine/dist/SpinePluginDebug.js
vendored
|
@ -2642,6 +2642,7 @@ var ComponentsToJSON = __webpack_require__(/*! ./components/ToJSON */ "../../../
|
||||||
var DataManager = __webpack_require__(/*! ../data/DataManager */ "../../../src/data/DataManager.js");
|
var DataManager = __webpack_require__(/*! ../data/DataManager */ "../../../src/data/DataManager.js");
|
||||||
var EventEmitter = __webpack_require__(/*! eventemitter3 */ "../../../node_modules/eventemitter3/index.js");
|
var EventEmitter = __webpack_require__(/*! eventemitter3 */ "../../../node_modules/eventemitter3/index.js");
|
||||||
var Events = __webpack_require__(/*! ./events */ "../../../src/gameobjects/events/index.js");
|
var Events = __webpack_require__(/*! ./events */ "../../../src/gameobjects/events/index.js");
|
||||||
|
var SceneEvents = __webpack_require__(/*! ../scene/events */ "../../../src/scene/events/index.js");
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @classdesc
|
* @classdesc
|
||||||
|
@ -3298,6 +3299,145 @@ var GameObject = new Class({
|
||||||
return indexes;
|
return indexes;
|
||||||
},
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Adds this Game Object to the given Display List.
|
||||||
|
*
|
||||||
|
* If no Display List is specified, it will default to the Display List owned by the Scene to which
|
||||||
|
* this Game Object belongs.
|
||||||
|
*
|
||||||
|
* A Game Object can only exist on one Display List at any given time, but may move freely between them.
|
||||||
|
*
|
||||||
|
* If this Game Object is already on another Display List when this method is called, it will first
|
||||||
|
* be removed from it, before being added to the new list.
|
||||||
|
*
|
||||||
|
* You can query which list it is on by looking at the `Phaser.GameObjects.GameObject#displayList` property.
|
||||||
|
*
|
||||||
|
* If a Game Object isn't on any display list, it will not be rendered. If you just wish to temporarly
|
||||||
|
* disable it from rendering, consider using the `setVisible` method, instead.
|
||||||
|
*
|
||||||
|
* @method Phaser.GameObjects.GameObject#addToDisplayList
|
||||||
|
* @fires Phaser.Scenes.Events#ADDED_TO_SCENE
|
||||||
|
* @fires Phaser.GameObjects.Events#ADDED_TO_SCENE
|
||||||
|
* @since 3.53.0
|
||||||
|
*
|
||||||
|
* @param {(Phaser.GameObjects.DisplayList|Phaser.GameObjects.Layer)} [displayList] - The Display List to add to. Defaults to the Scene Display List.
|
||||||
|
*
|
||||||
|
* @return {this} This Game Object.
|
||||||
|
*/
|
||||||
|
addToDisplayList: function (displayList)
|
||||||
|
{
|
||||||
|
if (displayList === undefined) { displayList = this.scene.sys.displayList; }
|
||||||
|
|
||||||
|
if (this.displayList && this.displayList !== displayList)
|
||||||
|
{
|
||||||
|
this.removeFromDisplayList();
|
||||||
|
}
|
||||||
|
|
||||||
|
// Don't repeat if it's already on this list
|
||||||
|
if (!displayList.exists(this))
|
||||||
|
{
|
||||||
|
this.displayList = displayList;
|
||||||
|
|
||||||
|
displayList.add(this, true);
|
||||||
|
|
||||||
|
displayList.queueDepthSort();
|
||||||
|
|
||||||
|
this.emit(Events.ADDED_TO_SCENE, this, this.scene);
|
||||||
|
|
||||||
|
displayList.events.emit(SceneEvents.ADDED_TO_SCENE, this, this.scene);
|
||||||
|
}
|
||||||
|
|
||||||
|
return this;
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Adds this Game Object to the Update List belonging to the Scene.
|
||||||
|
*
|
||||||
|
* When a Game Object is added to the Update List it will have its `preUpdate` method called
|
||||||
|
* every game frame. This method is passed two parameters: `delta` and `time`.
|
||||||
|
*
|
||||||
|
* If you wish to run your own logic within `preUpdate` then you should always call
|
||||||
|
* `preUpdate.super(delta, time)` within it, or it may fail to process required operations,
|
||||||
|
* such as Sprite animations.
|
||||||
|
*
|
||||||
|
* @method Phaser.GameObjects.GameObject#addToUpdateList
|
||||||
|
* @since 3.53.0
|
||||||
|
*
|
||||||
|
* @return {this} This Game Object.
|
||||||
|
*/
|
||||||
|
addToUpdateList: function ()
|
||||||
|
{
|
||||||
|
if (this.scene && this.preUpdate)
|
||||||
|
{
|
||||||
|
this.scene.sys.updateList.add(this);
|
||||||
|
}
|
||||||
|
|
||||||
|
return this;
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Removes this Game Object from the Display List it is currently on.
|
||||||
|
*
|
||||||
|
* A Game Object can only exist on one Display List at any given time, but may move freely removed
|
||||||
|
* and added back at a later stage.
|
||||||
|
*
|
||||||
|
* You can query which list it is on by looking at the `Phaser.GameObjects.GameObject#displayList` property.
|
||||||
|
*
|
||||||
|
* If a Game Object isn't on any Display List, it will not be rendered. If you just wish to temporarly
|
||||||
|
* disable it from rendering, consider using the `setVisible` method, instead.
|
||||||
|
*
|
||||||
|
* @method Phaser.GameObjects.GameObject#removeFromDisplayList
|
||||||
|
* @fires Phaser.Scenes.Events#REMOVED_FROM_SCENE
|
||||||
|
* @fires Phaser.GameObjects.Events#REMOVED_FROM_SCENE
|
||||||
|
* @since 3.53.0
|
||||||
|
*
|
||||||
|
* @return {this} This Game Object.
|
||||||
|
*/
|
||||||
|
removeFromDisplayList: function ()
|
||||||
|
{
|
||||||
|
var displayList = this.displayList || this.scene.sys.displayList;
|
||||||
|
|
||||||
|
if (displayList.exists(this))
|
||||||
|
{
|
||||||
|
displayList.remove(this, true);
|
||||||
|
|
||||||
|
displayList.queueDepthSort();
|
||||||
|
|
||||||
|
this.displayList = null;
|
||||||
|
|
||||||
|
this.emit(Events.REMOVED_FROM_SCENE, this, this.scene);
|
||||||
|
|
||||||
|
displayList.events.emit(SceneEvents.REMOVED_FROM_SCENE, this, this.scene);
|
||||||
|
}
|
||||||
|
|
||||||
|
return this;
|
||||||
|
},
|
||||||
|
|
||||||
|
/**
|
||||||
|
* Removes this Game Object from the Scene's Update List.
|
||||||
|
*
|
||||||
|
* When a Game Object is on the Update List, it will have its `preUpdate` method called
|
||||||
|
* every game frame. Calling this method will remove it from the list, preventing this.
|
||||||
|
*
|
||||||
|
* Removing a Game Object from the Update List will stop most internal functions working.
|
||||||
|
* For example, removing a Sprite from the Update List will prevent it from being able to
|
||||||
|
* run animations.
|
||||||
|
*
|
||||||
|
* @method Phaser.GameObjects.GameObject#removeFromUpdateList
|
||||||
|
* @since 3.53.0
|
||||||
|
*
|
||||||
|
* @return {this} This Game Object.
|
||||||
|
*/
|
||||||
|
removeFromUpdateList: function ()
|
||||||
|
{
|
||||||
|
if (this.scene && this.preUpdate)
|
||||||
|
{
|
||||||
|
this.scene.sys.updateList.remove(this);
|
||||||
|
}
|
||||||
|
|
||||||
|
return this;
|
||||||
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* Destroys this Game Object removing it from the Display List and Update List and
|
* Destroys this Game Object removing it from the Display List and Update List and
|
||||||
* severing all ties to parent resources.
|
* severing all ties to parent resources.
|
||||||
|
@ -3337,11 +3477,8 @@ var GameObject = new Class({
|
||||||
this.resetPostPipeline(true);
|
this.resetPostPipeline(true);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (this.displayList)
|
this.removeFromDisplayList();
|
||||||
{
|
this.removeFromUpdateList();
|
||||||
this.displayList.queueDepthSort();
|
|
||||||
this.displayList.remove(this);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (this.input)
|
if (this.input)
|
||||||
{
|
{
|
||||||
|
@ -3368,7 +3505,6 @@ var GameObject = new Class({
|
||||||
this.visible = false;
|
this.visible = false;
|
||||||
|
|
||||||
this.scene = undefined;
|
this.scene = undefined;
|
||||||
this.displayList = undefined;
|
|
||||||
this.parentContainer = undefined;
|
this.parentContainer = undefined;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -9341,33 +9477,19 @@ var Container = new Class({
|
||||||
|
|
||||||
if (this.exclusive)
|
if (this.exclusive)
|
||||||
{
|
{
|
||||||
if (gameObject.displayList)
|
gameObject.removeFromDisplayList();
|
||||||
{
|
|
||||||
gameObject.displayList.remove(gameObject);
|
|
||||||
}
|
|
||||||
|
|
||||||
if (gameObject.parentContainer)
|
if (gameObject.parentContainer)
|
||||||
{
|
{
|
||||||
gameObject.parentContainer.remove(gameObject);
|
gameObject.parentContainer.remove(gameObject);
|
||||||
}
|
}
|
||||||
|
|
||||||
if (this.displayList)
|
var displayList = this.displayList || this.scene.sys.displayList;
|
||||||
{
|
|
||||||
gameObject.displayList = this.displayList;
|
gameObject.addToDisplayList(displayList);
|
||||||
}
|
|
||||||
else
|
|
||||||
{
|
|
||||||
gameObject.displayList = this.scene.sys.displayList;
|
|
||||||
}
|
|
||||||
|
|
||||||
gameObject.parentContainer = this;
|
gameObject.parentContainer = this;
|
||||||
}
|
}
|
||||||
|
|
||||||
// Is only on the Display List via this Container
|
|
||||||
if (!this.scene.sys.displayList.exists(gameObject))
|
|
||||||
{
|
|
||||||
gameObject.emit(Events.ADDED_TO_SCENE, gameObject, this.scene);
|
|
||||||
}
|
|
||||||
},
|
},
|
||||||
|
|
||||||
/**
|
/**
|
||||||
|
@ -9385,13 +9507,11 @@ var Container = new Class({
|
||||||
|
|
||||||
if (this.exclusive)
|
if (this.exclusive)
|
||||||
{
|
{
|
||||||
gameObject.parentContainer = null;
|
gameObject.removeFromDisplayList();
|
||||||
}
|
|
||||||
|
|
||||||
// Is only on the Display List via this Container
|
gameObject.parentContainer = null;
|
||||||
if (!this.scene.sys.displayList.exists(gameObject))
|
|
||||||
{
|
gameObject.addToDisplayList();
|
||||||
gameObject.emit(Events.REMOVED_FROM_SCENE, gameObject, this.scene);
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|
2
plugins/spine/dist/SpinePluginDebug.js.map
vendored
2
plugins/spine/dist/SpinePluginDebug.js.map
vendored
File diff suppressed because one or more lines are too long
1555
plugins/spine/dist/SpineWebGLPlugin.js
vendored
1555
plugins/spine/dist/SpineWebGLPlugin.js
vendored
File diff suppressed because it is too large
Load diff
2
plugins/spine/dist/SpineWebGLPlugin.min.js
vendored
2
plugins/spine/dist/SpineWebGLPlugin.min.js
vendored
File diff suppressed because one or more lines are too long
47114
plugins/spine/dist/SpineWebGLPluginDebug.js
vendored
Normal file
47114
plugins/spine/dist/SpineWebGLPluginDebug.js
vendored
Normal file
File diff suppressed because it is too large
Load diff
1
plugins/spine/dist/SpineWebGLPluginDebug.js.map
vendored
Normal file
1
plugins/spine/dist/SpineWebGLPluginDebug.js.map
vendored
Normal file
File diff suppressed because one or more lines are too long
Loading…
Reference in a new issue