project_files/HedgewarsMobile/Classes/CGPointUtils.h
changeset 3996 eb549fd864a5
parent 3680 aaf832c6fbd7
child 4476 4bf74e158f44
--- a/project_files/HedgewarsMobile/Classes/CGPointUtils.h	Mon Oct 25 17:39:50 2010 +0200
+++ b/project_files/HedgewarsMobile/Classes/CGPointUtils.h	Mon Oct 25 22:19:00 2010 +0200
@@ -12,9 +12,8 @@
 #define degreesToRadians(x) ( M_PI * x / 180.0)
 #define radiansToDegrees(x) (180.0 * x / M_PI )
 
-// 40 is not a good value for iphone but works for ipad
 #define HWX(x) (int)(x-screen.size.height/2)/HW_zoomFactor()
-#define HWY(x) (int)(screen.size.width-x)/HW_zoomFactor() + 40*HW_zoomLevel()/HW_zoomFactor()
+#define HWY(x) (int)(screen.size.width-x)/HW_zoomFactor() + (IS_IPAD()?40:17.5)*HW_zoomLevel()/HW_zoomFactor()
 
 #define HWXZ(x) (int)(x-screen.size.height/2)
 #define HWYZ(x) (int)(screen.size.width-x)