2D Toolkit Forum
2D Toolkit => Support => Topic started by: fabrejean on February 08, 2013, 08:14:23 am
-
Hello,
following a request on a playmaker User, I'd like to know how to select a different collection on a animated sprite. Currently I can select the clip fine, but I can't find a convenient runtime api to select a collection by its name.
Is it possible?
bye,
Jean
-
I don't know much about Playmaker, don't use it or have a license, but a bit of googling has brought me to this page:
https://hutonggames.fogbugz.com/default.asp?W104
So similarly to that, can't you simply store a reference to an tk2dSpriteAnimation, and a string name? Then you can pull the clip from that name. You can do the same with sprites from differrent sprite collections (store a tk2dSpriteCollectionData, and a name).
Wouldn't that work for you?