mirror of
https://github.com/EsotericSoftware/spine-runtimes.git
synced 2026-02-10 00:58:43 +08:00
Don't serialize computed fields.
This commit is contained in:
parent
57b5f3a35f
commit
197614ecb2
@ -38,7 +38,9 @@ using Spine;
|
||||
[ExecuteInEditMode]
|
||||
[AddComponentMenu("Spine/BoneComponent")]
|
||||
public class BoneComponent : MonoBehaviour {
|
||||
[System.NonSerialized]
|
||||
public bool valid;
|
||||
|
||||
public SkeletonRenderer skeletonRenderer;
|
||||
public Bone bone;
|
||||
|
||||
|
||||
@ -37,7 +37,9 @@ using Spine;
|
||||
/// <summary>Renders a skeleton.</summary>
|
||||
[ExecuteInEditMode, RequireComponent(typeof(MeshFilter), typeof(MeshRenderer))]
|
||||
public class SkeletonRenderer : MonoBehaviour {
|
||||
[System.NonSerialized]
|
||||
public bool valid;
|
||||
[System.NonSerialized]
|
||||
public Skeleton skeleton;
|
||||
|
||||
public SkeletonDataAsset skeletonDataAsset;
|
||||
|
||||
@ -41,8 +41,8 @@ public class Spineboy : MonoBehaviour {
|
||||
skeletonAnimation = GetComponent<SkeletonAnimation>();
|
||||
// Call our method any time an animation fires an event.
|
||||
skeletonAnimation.state.Event += Event;
|
||||
// Queue jump to be played on track 0 three seconds after the starting animation.
|
||||
skeletonAnimation.state.AddAnimation(0, "jump", false, 3);
|
||||
// Queue jump to be played on track 0 two seconds after the starting animation.
|
||||
skeletonAnimation.state.AddAnimation(0, "jump", false, 2);
|
||||
// Queue walk to be looped on track 0 after the jump animation.
|
||||
skeletonAnimation.state.AddAnimation(0, "run", true, 0);
|
||||
}
|
||||
|
||||
@ -38,7 +38,9 @@ using Spine;
|
||||
[ExecuteInEditMode]
|
||||
[AddComponentMenu("Spine/BoneComponent")]
|
||||
public class BoneComponent : MonoBehaviour {
|
||||
[System.NonSerialized]
|
||||
public bool valid;
|
||||
|
||||
public SkeletonRenderer skeletonRenderer;
|
||||
public Bone bone;
|
||||
|
||||
|
||||
@ -37,9 +37,11 @@ using Spine;
|
||||
/// <summary>Renders a skeleton.</summary>
|
||||
[ExecuteInEditMode, RequireComponent(typeof(MeshFilter), typeof(MeshRenderer))]
|
||||
public class SkeletonRenderer : MonoBehaviour {
|
||||
[System.NonSerialized]
|
||||
public bool valid;
|
||||
[System.NonSerialized]
|
||||
public Skeleton skeleton;
|
||||
|
||||
|
||||
public SkeletonDataAsset skeletonDataAsset;
|
||||
public String initialSkinName;
|
||||
public bool calculateNormals;
|
||||
|
||||
@ -41,8 +41,8 @@ public class Spineboy : MonoBehaviour {
|
||||
skeletonAnimation = GetComponent<SkeletonAnimation>();
|
||||
// Call our method any time an animation fires an event.
|
||||
skeletonAnimation.state.Event += Event;
|
||||
// Queue jump to be played on track 0 tree seconds after the starting animation.
|
||||
skeletonAnimation.state.AddAnimation(0, "jump", false, 3);
|
||||
// Queue jump to be played on track 0 two seconds after the starting animation.
|
||||
skeletonAnimation.state.AddAnimation(0, "jump", false, 2);
|
||||
// Queue walk to be looped on track 0 after the jump animation.
|
||||
skeletonAnimation.state.AddAnimation(0, "run", true, 0);
|
||||
}
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user