[unity] Fix some OnValidate behavior.

This commit is contained in:
John 2017-11-20 08:26:27 +08:00 committed by GitHub
parent 08451f2a8d
commit 017b65198f
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -80,14 +80,16 @@ namespace Spine.Unity {
}
// Only provide visual feedback to inspector changes in Unity Editor Edit mode.
if (!Application.isPlaying) {
skeleton.flipX = this.initialFlipX;
skeleton.flipY = this.initialFlipY;
skeleton.SetToSetupPose();
if (!string.IsNullOrEmpty(startingAnimation))
skeleton.PoseWithAnimation(startingAnimation, 0f, false);
}
skeleton.SetToSetupPose();
if (!string.IsNullOrEmpty(startingAnimation))
skeleton.PoseWithAnimation(startingAnimation, 0f, false);
}
} else {
if (skeletonDataAsset != null)