Reputation: 11
I want to be able to animate the letters of SKLabelNode
s individually, move them, change color, etc. Using SpriteKit how should I best achieve this? Should I just resort to creating the letters on individual SKLabelNode
s? WIll that be scalable, eg. if I have thousands of words for example would this begin to slow? I guess I should just test this myself but I was wondering before I do that is there a better approach that's completely different or should I just give up on trying to animate the letters individually? Perhaps it doesn't work in different languages or whatnot.
edit For the record I won't be animating them all at once, just plan on having them all in the same SKNode
maybe I will only animate 50 at a time but it could vary.
Upvotes: 1
Views: 840
Reputation: 2038
If you are hoping to animate thousands of letters individually by having them each be a separate SKLabelNode
, then yes, you will certainly run into frame rate issues. However, using many SKLabelNode
s is probably the best way to do it. It's more lightweight than SKSpriteNode
and can do everything you need it to (i.e. move, change color, and possibly rotate). When it comes to SpriteKit development, you can only think about scalability of animations to a certain extent--once you have enough individual sprites, the frame rate will inevitably drop.
But basically, yes, separate SKLabelNode
is probably the best way.
Upvotes: 2