mirror of
https://github.com/photonstorm/phaser
synced 2024-11-16 17:58:23 +00:00
Added rootBone support and removed runtime property, no longer needed
This commit is contained in:
parent
4db503a4be
commit
9fc7d741f1
1 changed files with 8 additions and 3 deletions
|
@ -49,8 +49,7 @@ var SpineGameObject = new Class({
|
|||
|
||||
this.plugin = plugin;
|
||||
|
||||
this.runtime = plugin.getRuntime();
|
||||
|
||||
this.root = null;
|
||||
this.skeleton = null;
|
||||
this.skeletonData = null;
|
||||
|
||||
|
@ -135,6 +134,8 @@ var SpineGameObject = new Class({
|
|||
this.setAnimation(0, animationName, loop);
|
||||
}
|
||||
|
||||
this.root = this.getRootBone();
|
||||
|
||||
return this;
|
||||
},
|
||||
|
||||
|
@ -227,6 +228,11 @@ var SpineGameObject = new Class({
|
|||
return this;
|
||||
},
|
||||
|
||||
getRootBone: function ()
|
||||
{
|
||||
return this.skeleton.getRootBone();
|
||||
},
|
||||
|
||||
findBone: function (boneName)
|
||||
{
|
||||
return this.skeleton.findBone(boneName);
|
||||
|
@ -284,7 +290,6 @@ var SpineGameObject = new Class({
|
|||
}
|
||||
|
||||
this.plugin = null;
|
||||
this.runtime = null;
|
||||
|
||||
this.skeleton = null;
|
||||
this.skeletonData = null;
|
||||
|
|
Loading…
Reference in a new issue