project_files/HedgewarsMobile/Classes/TeamSettingsViewController.m
changeset 6103 55ecfbf834e3
parent 6074 047eaed35cbb
child 6700 e04da46ee43c
equal deleted inserted replaced
6102:97565ab4afe9 6103:55ecfbf834e3
    82 
    82 
    83 // add a team file with default values and updates the table
    83 // add a team file with default values and updates the table
    84 -(void) addTeam:(id) sender {
    84 -(void) addTeam:(id) sender {
    85     NSString *fileName = [[NSString alloc] initWithFormat:@"Default Team %u.plist", [self.listOfTeams count]];
    85     NSString *fileName = [[NSString alloc] initWithFormat:@"Default Team %u.plist", [self.listOfTeams count]];
    86 
    86 
    87     createTeamNamed([fileName stringByDeletingPathExtension]);
    87     [CreationChamber createTeamNamed:[fileName stringByDeletingPathExtension]];
    88 
    88 
    89     [self.listOfTeams addObject:fileName];
    89     [self.listOfTeams addObject:fileName];
    90 
    90 
    91     // order the array alphabetically, so teams will keep their position
    91     // order the array alphabetically, so teams will keep their position
    92     [self.listOfTeams sortUsingSelector:@selector(compare:)];
    92     [self.listOfTeams sortUsingSelector:@selector(compare:)];