So , I am testing out a game with a simple ball (which is basically an object of UIImageView
) fixed on the screen using CGPointMake
and I am implementing a simple swipe gesture with UIGestureRecognizerDelegate
.
My intention is to just flick the ball in a direction and I want the ball to move in that direction (flawlessly- which means the movement has to be really smooth), and it will depend on the direction and speed of the swipe.
I can understand that I can work with UISwipeGestureRecognizer
and UIPanGestureRecognizer
and find out the velocity of the swipe and fix the ball again with CGPointMake
.
But, is there a really good way to obtain a really smooth movement on the ball with a particular velocity and direction ?