I'm making a speedometer app and I want arrow to behave the correct way - if I launch from zero to 200 km in one second, I want it to go around the bar, but if I set my rotation angle big enough, it goes the short way, from the bottom.
How do I make it go almost full circle and not via short path?
Here is the (trivial) code I use for rotation:
[UIView animateWithDuration:0.3 animations:^(){
self.arrow.transform = CGAffineTransformRotate(CGAffineTransformIdentity, -4.4);
}];
I figure I can rotate it in small chunks, but sometimes it may be needed to rotate it fast from zero to maximum (for example if we had no reading on speed and got it already at high speed so we need to rotate the arrow most of the screen).
As a side question - how do I queue animations, so that I can apply them one by one?