I've set up a UISwipeGestureRecognizer
:
UISwipeGestureRecognizer *swipe = [[UISwipeGestureRecognizer alloc] initWithTarget:delegate action:@selector(handleSwipeGesture:)];
swipe.direction = UISwipeGestureRecognizerDirectionUp;
[self addGestureRecognizer:swipe];
[swipe release];
A swipe makes the player move in the direction of the swipe. I need the player to keep moving, though, until the finger that made the swipe is lifted off the screen. I've tried using the touchesEnded: method but it requires that a non-swiping touch be made first. How can I get the touch that made the swipe gesture? How can I detect when that touch is lifted off the screen?