public void Play(string animName) { ClipAnim animToPlay = Clip.AnimSet[animName]; System.Diagnostics.Debug.Assert(animToPlay != null); Play(animToPlay); }
public void Play(ClipAnim anim) { currentAnim = anim; for (int i = 0; i < currentAnim.JointAnims.Count; ++i) { JointAnimStates[i] = currentAnim.JointAnims[i].CreateState(); } }
public void Play(string animName, bool loop, bool forwards, float speedMod = 1f) { ClipAnim animToPlay = Clip.AnimSet[animName]; System.Diagnostics.Debug.Assert(animToPlay != null); Play(animToPlay, loop, forwards, speedMod); }
public override void Init(ContentManager content, ClipAnim clipAnim) { base.Init(content, clipAnim); for (int i = 0; i < Frames.Length; ++i) { Frames[i].Init(content); } }
public override void Init(ContentManager content, ClipAnim clipAnim) { base.Init(content, clipAnim); for (int i = 0; i < Frames.Length; ++i) { Frames[i].Init(); } }
public void Play(ClipAnim anim, bool loop, bool forwards) { Anim = anim; AnimPos = 0.0f; Loop = loop; durationInSeconds = (float)Anim.Duration / Anim.Framerate; playingState = forwards ? AnimPlayingState.Playing : AnimPlayingState.PlayingInReverse; for (int i = 0; i < Anim.JointAnims.Count; ++i) { JointAnimStates[i] = Anim.JointAnims[i].CreateState(); } }
public virtual void Init(ContentManager content, ClipAnim clipAnim) { parentClipAnim = clipAnim; for (int i = 0; i < parentClipAnim.ParentClip.Joints.Length; ++i) { Joint j = parentClipAnim.ParentClip.Joints[i]; if (j.Name == JointName) { joint = j; JointId = i; break; } } }
public void Play(ClipAnim anim, bool loop, bool forwards, float speedMod = 1f) { System.Diagnostics.Debug.Assert(anim != null); System.Diagnostics.Debug.Assert(speedMod > 0.0f); Anim = anim; AnimPos = 0.0f; Loop = loop; speedModifier = speedMod; durationInSeconds = (1f / speedModifier) * ((float)Anim.Duration / Anim.Framerate); playingState = forwards ? AnimPlayingState.Playing : AnimPlayingState.PlayingInReverse; for (int i = 0; i < Anim.JointAnims.Count; ++i) { JointAnimStates[i] = Anim.JointAnims[i].CreateState(); } }
public void Play(ClipAnim anim, bool loop, bool forwards, float speedMod = 1f) { currentAnim.Play(anim, loop, forwards, speedMod); }
public void Play(ClipAnim anim, bool loop, float speedMod = 1f) { Play(anim, loop, true, speedMod); }
public void Play(ClipAnim anim) { Play(anim, true); }
public void Play(ClipAnim anim, bool loop, float speedMod = 1f) { currentAnim.Play(anim, loop, speedMod); }
public void Play(ClipAnim anim, bool loop, float speedMod=1f) { Play(anim, loop, true, speedMod); }
public void Play(ClipAnim anim, bool loop, bool forwards, float speedMod=1f) { System.Diagnostics.Debug.Assert(anim != null); System.Diagnostics.Debug.Assert(speedMod > 0.0f); Anim = anim; AnimPos = 0.0f; Loop = loop; speedModifier = speedMod; durationInSeconds = (1f / speedModifier) * ((float)Anim.Duration / Anim.Framerate); playingState = forwards ? AnimPlayingState.Playing : AnimPlayingState.PlayingInReverse; for (int i = 0; i < Anim.JointAnims.Count; ++i) { JointAnimStates[i] = Anim.JointAnims[i].CreateState(); } }
public void Play(ClipAnim anim, bool loop) { currentAnim.Play(anim, loop); }
public void Play(ClipAnim anim, bool loop) { Play(anim, loop, true); }