project_files/HedgewarsMobile/Classes/GameSetup.m
changeset 4540 9b614e420de5
parent 4512 c6aff8ceada0
child 4547 b70004a576a3
equal deleted inserted replaced
4539:bad3411cba49 4540:9b614e420de5
   568         
   568         
   569     NSString *horizontalSize = [[NSString alloc] initWithFormat:@"%d", width];
   569     NSString *horizontalSize = [[NSString alloc] initWithFormat:@"%d", width];
   570     NSString *verticalSize = [[NSString alloc] initWithFormat:@"%d", height];
   570     NSString *verticalSize = [[NSString alloc] initWithFormat:@"%d", height];
   571     const char **gameArgs = (const char**) malloc(sizeof(char *) * 10);
   571     const char **gameArgs = (const char**) malloc(sizeof(char *) * 10);
   572     NSInteger tmpQuality;
   572     NSInteger tmpQuality;
       
   573     BOOL enhanced = [[self.systemSettings objectForKey:@"enhanced"] boolValue];
   573 
   574 
   574     NSString *modelId = modelType();
   575     NSString *modelId = modelType();
   575     if ([modelId hasPrefix:@"iPhone1"] ||                                   // = iPhone or iPhone 3G
   576     if ([modelId hasPrefix:@"iPhone1"] || [modelId hasPrefix:@"iPod1,1"] || [modelId hasPrefix:@"iPod2,1"])     // = iPhone and iPhone 3G or iPod Touch or iPod Touch 2G
   576         [modelId hasPrefix:@"iPod1,1"] || [modelId hasPrefix:@"iPod2,1"])   // = iPod Touch or iPod Touch 2G
   577         tmpQuality = 0x00000001 | 0x00000002 | 0x00000008 | 0x00000040;                 // rqLowRes | rqBlurryLand | rqSimpleRope | rqKillFlakes
   577         tmpQuality = 0x00000001 | 0x00000002 | 0x00000008 | 0x00000040;  // rqLowRes | rqBlurryLand | rqSimpleRope | rqKillFlakes
   578     else if ([modelId hasPrefix:@"iPhone2"] || [modelId hasPrefix:@"iPod3"])                                    // = iPhone 3GS or iPod Touch 3G
   578     else if ([modelId hasPrefix:@"iPhone2"] ||                              // = iPhone 3GS
   579         tmpQuality = 0x00000002 | 0x00000040;                                           // rqBlurryLand | rqKillFlakes
   579              [modelId hasPrefix:@"iPod3"])                                  // = iPod Touch 3G
   580     else if ([modelId hasPrefix:@"iPad1"] || enhanced == NO)                                                    // = iPad 1G or not enhanced mode
   580             tmpQuality = 0x00000002 | 0x00000040;           // rqBlurryLand | rqKillFlakes
   581         tmpQuality = 0x00000002;                                                        // rqBlurryLand
   581         else if ([modelId hasPrefix:@"iPad1"])                              // = iPad
   582     else                                                                                                        // = everything else
   582                 tmpQuality = 0x00000002;                    // rqBlurryLand
   583         tmpQuality = 0;                                                                 // full quality
   583             else                                                            // = everything else
   584 
   584                 tmpQuality = 0;                             // full quality
   585     if (IS_IPAD() == NO)                                                                                        // = disable tooltips on phone
   585     if (IS_IPAD() == NO)             // = disable tooltips on phone
       
   586         tmpQuality = tmpQuality | 0x00000400;
   586         tmpQuality = tmpQuality | 0x00000400;
   587 
   587 
   588     // prevents using an empty nickname
   588     // prevents using an empty nickname
   589     NSString *username;
   589     NSString *username;
   590     NSString *originalUsername = [self.systemSettings objectForKey:@"username"];
   590     NSString *originalUsername = [self.systemSettings objectForKey:@"username"];