Hello Guest

Author Topic: how do I access a different animation?  (Read 3039 times)


  • Newbie
  • *
  • Posts: 1
    • View Profile
how do I access a different animation?
« on: December 01, 2015, 04:26:40 am »
from unity 3d
tk2dSpriteAnimator anim;

   void Start () {
      animator = GetComponent<tk2dSpriteAnimator>();

public void Jump(){

currently I can access all there animation in this spriteAnimaiotn but how do i access a different spriteCollectionAnimation.
what i did is I added a new clip of animation and change the collection to different and I can access the animation clip but when the animation play, the sprite is too big. I  guess  the question is how can play a different animation in a different animation clip? I cannot just put all the sprite in one spriteCollection since it too big. any help is appreciated


  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
Re: how do I access a different animation?
« Reply #1 on: December 06, 2015, 12:20:01 pm »
[SerializeField] tk2dSpriteAnimation newAnimation;

animator.Library = newAnimation;

You can also load it in using Resources.Load.