mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2026-03-26 22:49:01 +08:00
[unity] Fix SkeletonAnimator autoreset weight.
This commit is contained in:
parent
73f8779efc
commit
c1dce1f476
@ -101,7 +101,7 @@ namespace Spine.Unity {
|
|||||||
previousAnimations.Clear();
|
previousAnimations.Clear();
|
||||||
|
|
||||||
for (int layer = 0, n = animator.layerCount; layer < n; layer++) {
|
for (int layer = 0, n = animator.layerCount; layer < n; layer++) {
|
||||||
float layerWeight = animator.GetLayerWeight(layer);
|
float layerWeight = (layer == 0) ? 1 : animator.GetLayerWeight(layer);
|
||||||
if (layerWeight <= 0) continue;
|
if (layerWeight <= 0) continue;
|
||||||
|
|
||||||
AnimatorStateInfo nextStateInfo = animator.GetNextAnimatorStateInfo(layer);
|
AnimatorStateInfo nextStateInfo = animator.GetNextAnimatorStateInfo(layer);
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user