[pomoc] Ban

Započeo [PAL]Emir, Decembar 11, 2011, 19:07:40 POSLE PODNE

prethodna tema - sledeća tema

0 članova i 1 gost pregledaju ovu temu.

Skripta koju koristim:Balkan country
Problem:kada banujem sam sebe i kada ponovo udjem na server nisam banovan
Dio skriptedcmd_bannick(playerid,params[])
{
if(AOvlast(playerid,1337))
{
new id;
new PName[MAX_PLAYER_NAME];
new AName[MAX_PLAYER_NAME];
new razlog[256];
new ip[15];
new string[256];
GetPlayerName(playerid,AName,sizeof(AName));
if(sscanf(params,"us",id,razlog)) SendClientMessage(playerid,COLOR_NICERED,"{FF0000}BC Pomoc|{FFFFFF} /bannick [ID Igraca] [Razlog]");
else
{
if(!ADoz(playerid,id))
{
return 1;
}
else
{
GetPlayerName(id,PName,sizeof(PName));
GetPlayerIp(id,ip,15);
new year,month,day;
getdate(year,month,day);
new File:nickban = fopen("BalkanCountryFiles/Server/NBanovi.ini", io_append);
format(string, sizeof string, "%s|%s\n",ip,PName);
fwrite(nickban, string);
fclose(nickban);
OnPlayerUpdateEx(id);
SendClientMessage(id,COLOR_GREY,"{FFFFFF}______________________________________________________________________________");
format(string,sizeof(string),"{FF0000}[BC]:{FFFFFF} Igrac {FF0000}%s {FFFFFF}je banovan od admina:{FF0000}%s.",PName,AName);
SendClientMessage(id,COLOR_GREY,string);
format(string,sizeof(string),"{FF0000}[BC]:{FFFFFF} Razlog:{FF0000} %s",razlog);
SendClientMessage(id,COLOR_GREY,string);
SendClientMessage(id,COLOR_GREY,"{FF0000}[BC]:{FFFFFF} Ukoliko smatrate da ste bez razloga dobili ban slikajte sa f8 i obratite se na forum");
SendClientMessage(id,COLOR_GREY,"{FF0000}[BC]:{FFFFFF} Takodje mozete zatraziti skidanje bana na nasem forumu");
format(string,sizeof(string),"{D2691E}Server:{FFFFFF}Balkan Country RolePlay{D2691E}   Danas je:{FFFFFF}%d.%d.%d.god.",day,month,year);
SendClientMessage(id,COLOR_GREY,string);
SendClientMessage(id,COLOR_GREY,"{FFFFFF}______________________________________________________________________________");
Kick(id);
format(string,sizeof(string),"{FF0000}[BC] Adm|{FFFFFF} Banovali ste igraca %s.",PName);
SendClientMessage(playerid,COLOR_GREY,string);
format(string,sizeof(string),"{FF0000}[BAN]:{FFFFFF} %s{FF0000} Razlog:{FFFFFF} %s ",PName,razlog);
SendClientMessageToAll(COLOR_NICERED,string);
KomObv(playerid,PName,"/bannick");
}
}
}
return 1;
}


Zna li ovdje iko ista
Poslednja Izmena: Decembar 11, 2011, 20:20:01 POSLE PODNE od Emir_Odobasic

Woo

*

dcmd_bannick(playerid,params[])
{
   if(AOvlast(playerid,1337))
   {
      new id;
      new PName[MAX_PLAYER_NAME];
      new AName[MAX_PLAYER_NAME];
      new razlog[256];
      new ip[15];
      new string[256];
      GetPlayerName(playerid,AName,sizeof(AName));
      if(sscanf(params,"us",id,razlog)) SendClientMessage(playerid,COLOR_NICERED,"{FF0000}BC Pomoc|{FFFFFF} /bannick [ID Igraca] [Razlog]");
      else
      {
         if(!ADoz(playerid,id))
         {
            return 1;
         }
         else
         {
            GetPlayerName(id,PName,sizeof(PName));
            GetPlayerIp(id,ip,15);
            new year,month,day;
            getdate(year,month,day);
            new File:nickban = fopen("BalkanCountryFiles/Server/NBanovi.ini", io_append);
            format(string, sizeof string, "%s|%s\n",ip,PName);
            fwrite(nickban, string);
            fclose(nickban);
            OnPlayerUpdateEx(id);
            SendClientMessage(id,COLOR_GREY,"{FFFFFF}______________________________________________________________________________");
            format(string,sizeof(string),"{FF0000}[BC]:{FFFFFF} Igrac {FF0000}%s {FFFFFF}je banovan od admina:{FF0000}%s.",PName,AName);
            SendClientMessage(id,COLOR_GREY,string);
            format(string,sizeof(string),"{FF0000}[BC]:{FFFFFF} Razlog:{FF0000} %s",razlog);
            SendClientMessage(id,COLOR_GREY,string);
            SendClientMessage(id,COLOR_GREY,"{FF0000}[BC]:{FFFFFF} Ukoliko smatrate da ste bez razloga dobili ban slikajte sa f8 i obratite se na forum");
            SendClientMessage(id,COLOR_GREY,"{FF0000}[BC]:{FFFFFF} Takodje mozete zatraziti skidanje bana na nasem forumu");
            format(string,sizeof(string),"{D2691E}Server:{FFFFFF}Balkan Country RolePlay{D2691E}   Danas je:{FFFFFF}%d.%d.%d.god.",day,month,year);
            SendClientMessage(id,COLOR_GREY,string);
            SendClientMessage(id,COLOR_GREY,"{FFFFFF}______________________________________________________________________________");
            Ban(id);
            format(string,sizeof(string),"{FF0000}[BC] Adm|{FFFFFF} Banovali ste igraca %s.",PName);
            SendClientMessage(playerid,COLOR_GREY,string);
            format(string,sizeof(string),"{FF0000}[BAN]:{FFFFFF} %s{FF0000} Razlog:{FFFFFF} %s ",PName,razlog);
            SendClientMessageToAll(COLOR_NICERED,string);
            KomObv(playerid,PName,"/bannick");
         }
      }
   }
   return 1;
}