0
votes

I am making an iphone app that uses two fingers to place and scale a platform. I need to find the x & y coordinates of BOTH of these touches. How would I go about this. thanks you

2

2 Answers

2
votes

check touchesBegan, touchesMoved and touchesEnded in your UIView subclass. This is explained in the Apple docs.

1
votes

You should go through Gesture Recognizers. Gesture Recognizers are a better approach to touchesBegan: and its siblings if you are developing for iOS 3.2 and later. For the purpose of scaling, you can look at UIPinchGestureRecognizer. Also, remember to enable multitouch by setting the view's multipleTouchEnabled to YES.