project_files/HedgewarsMobile/Classes/CommodityFunctions.m
changeset 3940 cc29628976cc
parent 3930 8b00b4f93242
child 3941 017b2b31e1c6
equal deleted inserted replaced
3939:e6fddcb04dc2 3940:cc29628976cc
   181     [theScheme writeToFile:schemeFile atomically:YES];
   181     [theScheme writeToFile:schemeFile atomically:YES];
   182     [schemeFile release];
   182     [schemeFile release];
   183     [theScheme release];
   183     [theScheme release];
   184 }
   184 }
   185 
   185 
   186 BOOL rotationManager (UIInterfaceOrientation interfaceOrientation) {
   186 BOOL inline rotationManager (UIInterfaceOrientation interfaceOrientation) {
   187     return (interfaceOrientation == UIInterfaceOrientationLandscapeRight) ||
   187     return (interfaceOrientation == UIInterfaceOrientationLandscapeRight) ||
   188            (interfaceOrientation == UIInterfaceOrientationLandscapeLeft);
   188            (interfaceOrientation == UIInterfaceOrientationLandscapeLeft);
   189 }
   189 }
   190 
   190 
   191 NSInteger randomPort () {
   191 NSInteger inline randomPort () {
   192     srandom(time(NULL));
   192     srandom(time(NULL));
   193     return (random() % 64511) + 1024;
   193     return (random() % 64511) + 1024;
   194 }
   194 }
   195 
   195 
   196 void popError (const char *title, const char *message) {
   196 void popError (const char *title, const char *message) {