mercredi 9 avril 2014

objective c - Animation de plusieurs boules identiques - Stack Overflow


Let's say I want to make an animation of many balls dropping from top of the screen. I get how to drop a single ball by using Core Animation. But, I'm confused of how to code so that several balls drop constantly. One way I thought is making a instance of CALayer and perform animation on it in a loop.


loop 
CALayer *ball = [CALayer layer];

// do animation

go to loop

Does this work?



Let's say I want to make an animation of many balls dropping from top of the screen. I get how to drop a single ball by using Core Animation. But, I'm confused of how to code so that several balls drop constantly. One way I thought is making a instance of CALayer and perform animation on it in a loop.


loop 
CALayer *ball = [CALayer layer];

// do animation

go to loop

Does this work?


0 commentaires:

Enregistrer un commentaire