UIScreen* screen = [UIScreen mainScreen];
const int width = screen.currentMode.size.width;
const int height = screen.currentMode.size.height;
NSLog(@"%dx%d", width, height);
touchesBegan/Ended/Moved/Cancelled: withEvent:
. В таком духе:- (void)touchesBegan:(NSSet *)touches withEvent:(UIEvent *)event{
UITouch* touch = [touches anyObject];
CGPoint point = [touch locationInView: self.view];
[PyromanLib actionDown:(float)point.x*scale :(float)point.y*scale];
}
if([[UIScreen mainScreen] respondsToSelector:@selector(displayLinkWithTarget:selector:)]){
scale = [[UIScreen mainScreen] scale];
}else{
scale = 1.0f;
}
Подробнее, почему так, на stackoverflow