Advertisement
Shiny_

POMUSZ

Sep 25th, 2013
180
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 0.69 KB | None | 0 0
  1.     public OnPlayerCommandPerformed(playerid, cmdtext[], success) {
  2.         if(!success) {
  3.             for(new i; i < sizeof(gVehicleNames); i++) {
  4.                 if(strlen(cmdtext) > 2 && !strcmp(cmdtext[1], gVehicleNames[i], true)) {
  5.                     delete_free_space(cmdtext);
  6.                     CreatePlayerVehicle(playerid, i + 400);
  7.                     format(text_, sizeof(text_), "Pojazd o nazwie {FF0000}%s{FFFFFF} zostaje utworzony.", gVehicleNames[i]);
  8.                     SendClientMessage(playerid, -1, text_);
  9.                     return true;
  10.                 }
  11.             }
  12.             format(text_, sizeof(text_), "Na serwerze nie ma takiej komendy jak %s!", cmdtext);
  13.             SendClientMessage(playerid, -1, text_);
  14.             printf("%s wpisuje komendę: %s", PlayerName(playerid), cmdtext);
  15.         }
  16.         return true;
  17.     }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement