Hello Guest

Author Topic: Possible to change the animation library of a tk2dAnimatedSprite during runtime?  (Read 4755 times)

fsadeq

  • 2D Toolkit
  • Sr. Member
  • *
  • Posts: 353
    • View Profile
Was wondering if this is possible? I haven't been able to figure out a way.

fsadeq

  • 2D Toolkit
  • Sr. Member
  • *
  • Posts: 353
    • View Profile
Nevermind, not sure how I missed the anim property on tk2dAnimatedSprite.

unikronsoftware

  • Administrator
  • Hero Member
  • *****
  • Posts: 9709
    • View Profile
I'm trying to move away from using libraries - rather play animation clips directly instead. You can already get a clip from a library and call

Play(clip)
instead of
spr.anim = library; Play("something");

Future versions will emphasise on this a lot more, as its much easier to do stuff like this:
Play(clip.reverse);
or
Play(clip.ScaleFPS(5.0f));