You can accomplish this using NSTimer or CADisplayLink to reuse the coordinates of an object in its movement path (for example, 6 times per second) and display a small dot in that coordinate. The timer will begin, for example, in angry birds, when the bird is first launched, and then stops when the bird hits something.
- a bird starts (a timer is created and the method is called 6 times per second)
- Every 1/6 second a point draws along the coordinate of the bird at that moment
- The timer stops when the bird gets there, so no more dots are drawn
Jeff w ..
source share