20.06.2010, 01:10
scroll down ~]~
if(strcmp(cmd, "/tk", true) == 0) { if(gTeam[playerid] == TEAM_COPS) { new id; tmp = strtok(cmdtext, idx); if(strlen(tmp)) { id = strval(tmp); if(IsPlayerConnected(id)) { if(Jailed[id] == false) { if(GetPlayerWantedLevel(id) >= 1 && GetPlayerWantedLevel(id) <= 3) { if(GetDistanceBetweenPlayers(playerid,id) < 15) { if(playerspawned[playerid] == true) { GetPlayerName(id,sName, MAX_PLAYER_NAME); GetPlayerName(playerid,fName, MAX_PLAYER_NAME); format(string, sizeof(string), "You Have Gave a Ticket To Suspect %s [%i]",sName,id); SendClientMessage(playerid, 0xE4BC1BFF,string); format(string, sizeof(string), "Officer %s [%i] Has Fined You $3000. You Have Paid The Ticket.",fName,playerid); SendClientMessage(id, 0xE4BC1BFF,string); format(string, sizeof(string), "Suspect %s [%i] has been fined by %s [%i].",sName,id,fName,playerid); SendClientMessageToAll(0x80FF00FF,string); SetPlayerWantedLevel(id, 0); GivePlayerMoney(id, -3000); GivePlayerMoney(playerid, 3000); SetPlayerScore(playerid, GetPlayerScore(playerid)+1); } else { SendClientMessage(playerid, 0xFF0000AA, "Your DEAD IDIOT You Cannot Arrest Anyone"); } } else { SendClientMessage(playerid, 0xFF0000AA, "Player Is Not Close Enough To Ticket!"); } } else { SendClientMessage(playerid, 0xFF0000AA, "Player Isn't Ticketable You Fucktard!"); } } else { SendClientMessage(playerid, 0xFF0000AA, "This Player Is In Jail You Cannot Ticket Him Are You Fucking Retarded."); } } else { SendClientMessage(playerid, RED, "Player Not Found."); } } else { SendClientMessage(playerid, 0xFF0000AA, "USAGE: /tk [id]"); } } else { SendClientMessage(playerid, 0xFF0000AA, "Only Law Enforcement Agents Can Use This Command!"); } return 1; }