project_files/HedgewarsMobile/Classes/EngineProtocolNetwork.m
branchios-revival
changeset 11231 bb3e57426a07
parent 11148 064a53861759
child 11240 57891137ffef
equal deleted inserted replaced
11230:4499aa8570fb 11231:bb3e57426a07
   345                 switch (buffer[1]) {
   345                 switch (buffer[1]) {
   346                     case 'r':           // winning team
   346                     case 'r':           // winning team
   347                         [statsArray insertObject:[NSString stringWithUTF8String:&buffer[2]] atIndex:1];
   347                         [statsArray insertObject:[NSString stringWithUTF8String:&buffer[2]] atIndex:1];
   348                         break;
   348                         break;
   349                     case 'D':           // best shot
   349                     case 'D':           // best shot
   350                         [statsArray addObject:[NSString stringWithFormat:@"The best shot award won by %s (with %@ points)", &buffer[index], arg]];
   350                         [statsArray addObject:[NSString stringWithFormat:NSLocalizedString(@"The best shot award won by %s (with %@ points)", nil), &buffer[index], arg]];
   351                         break;
   351                         break;
   352                     case 'k':           // best hedgehog
   352                     case 'k':           // best hedgehog
   353                         [statsArray addObject:[NSString stringWithFormat:@"The best killer is %s with %@ kill(s) in a turn", &buffer[index], arg]];
   353                         [statsArray addObject:[NSString stringWithFormat:NSLocalizedString(@"The best killer is %s with %@ kill(s) in a turn", nil), &buffer[index], arg]];
   354                         break;
   354                         break;
   355                     case 'K':           // number of hogs killed
   355                     case 'K':           // number of hogs killed
   356                         [statsArray addObject:[NSString stringWithFormat:@"%@ hedgehog(s) were killed during this round", arg]];
   356                         [statsArray addObject:[NSString stringWithFormat:NSLocalizedString(@"%@ hedgehog(s) were killed during this round", nil), arg]];
   357                         break;
   357                         break;
   358                     case 'H':           // team health/graph
   358                     case 'H':           // team health/graph
   359                         break;
   359                         break;
   360                     case 'T':           // local team stats
   360                     case 'T':           // local team stats
   361                         // still WIP in statsPage.cpp
   361                         // still WIP in statsPage.cpp
   362                         break;
   362                         break;
   363                     case 'P':           // teams ranking
   363                     case 'P':           // teams ranking
   364                         [[statsArray objectAtIndex:0] addObject:tempStr];
   364                         [[statsArray objectAtIndex:0] addObject:tempStr];
   365                         break;
   365                         break;
   366                     case 's':           // self damage
   366                     case 's':           // self damage
   367                         [statsArray addObject:[NSString stringWithFormat:@"%s thought it's good to shoot his own hedgehogs with %@ points", &buffer[index], arg]];
   367                         [statsArray addObject:[NSString stringWithFormat:NSLocalizedString(@"%s thought it's good to shoot his own hedgehogs with %@ points", nil), &buffer[index], arg]];
   368                         break;
   368                         break;
   369                     case 'S':           // friendly fire
   369                     case 'S':           // friendly fire
   370                         [statsArray addObject:[NSString stringWithFormat:@"%s killed %@ of his own hedgehogs", &buffer[index], arg]];
   370                         [statsArray addObject:[NSString stringWithFormat:NSLocalizedString(@"%s killed %@ of his own hedgehogs", nil), &buffer[index], arg]];
   371                         break;
   371                         break;
   372                     case 'B':           // turn skipped
   372                     case 'B':           // turn skipped
   373                         [statsArray addObject:[NSString stringWithFormat:@"%s was scared and skipped turn %@ times", &buffer[index], arg]];
   373                         [statsArray addObject:[NSString stringWithFormat:NSLocalizedString(@"%s was scared and skipped turn %@ times", nil), &buffer[index], arg]];
   374                         break;
   374                         break;
   375                     default:
   375                     default:
   376                         DLog(@"Unhandled stat message, see statsPage.cpp");
   376                         DLog(@"Unhandled stat message, see statsPage.cpp");
   377                         break;
   377                         break;
   378                 }
   378                 }