darkxdll

my onplayertext

Aug 6th, 2013
166
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
Pawn 1.16 KB | None | 0 0
  1. public OnPlayerText(playerid, text[])
  2. {
  3.     new string[200];
  4.     if(PlayerInfo[playerid][Admin] <= 5)
  5.     {
  6.         format(string,sizeof(string),"[{FFFF00}»» %s{FFFFFF}] %s : %s .««",PlayerInfo[playerid][Patente],nome(playerid),text);
  7.     }else if(PlayerInfo[playerid][Admin] == 5 && !strcmp(nome(playerid),"Brunno_Vinicius"))
  8.     {
  9.         format(string,sizeof(string),"[{80FF80}»» %s{FFFFFF}] %s : %s .««",PlayerInfo[playerid][Patente],nome(playerid),text);
  10.     }
  11.     if(PlayerInfo[playerid][Logado] == 0) return SendClientMessage(playerid,-1,"[ERRO]: Você não está logado !");
  12.     static BadWords[][] =
  13.     {
  14.         " fdm "," fdp "," viado "," caralho "," porra "," buceta "," xana "," chana "," capeta "," inferno "," diabo ",
  15.         " penis "," pinto "," f.d.p "," f.dp "," fd.p "," f_d_p "," cu "," anus "," filho da puta "," desgraça "," biscate ",
  16.         " xota "," xoxota "," xxt "," x.x.t "," /q "," rola "
  17.     };
  18.     for(new Z; Z < sizeof(BadWords); Z++)
  19.     {
  20.         if(strfind(text, BadWords[Z], true) != -1)
  21.         {
  22.             strdel(text,0,200);
  23.             SendClientMessage(playerid,Vermelho,"[ERRO]: Não diga palavrões !");
  24.             return false;
  25.         }
  26.     }
  27.     SendClientMessageToAll(-1,string);
  28.     return 0;
  29. }
Advertisement
Add Comment
Please, Sign In to add comment