mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2025-12-20 17:26:01 +08:00
Clear method for animation state.
This commit is contained in:
parent
d3bd35a0e3
commit
4568d7ebfd
@ -59,6 +59,11 @@ namespace Spine {
|
||||
Time = 0;
|
||||
}
|
||||
|
||||
public void Clear () {
|
||||
previous = null;
|
||||
Animation = null;
|
||||
}
|
||||
|
||||
override public String ToString () {
|
||||
return (Animation != null && Animation.Name != null) ? Animation.Name : base.ToString();
|
||||
}
|
||||
|
||||
@ -60,6 +60,11 @@ public class AnimationState {
|
||||
current.apply(skeleton, currentTime, currentLoop);
|
||||
}
|
||||
|
||||
public void clear () {
|
||||
previous = null;
|
||||
current = null;
|
||||
}
|
||||
|
||||
/** @see #setAnimation(Animation, boolean) */
|
||||
public void setAnimation (String animationName, boolean loop) {
|
||||
Animation animation = data.getSkeletonData().findAnimation(animationName);
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user