[Ajuda]bans
#8

tenta mas eu nem testei

pawn Код:
if(strcmp(cmd, "/ban", true) == 0)
    {
      new tmp2[256];
      if(IsPlayerConnected(playerid))
      {
        tmp = strtok(cmdtext, idx);
        tmp2 = strtok(cmdtext, idx);
            if(!strlen(tmp))
            {
                SendClientMessage(playerid, COLOR_GRAD2, "USE: /ban [ID] [razгo]");
                return 1;
            }
            giveplayerid = ReturnUser(tmp);
            if (PlayerInfo[playerid][pAdmin] >= 3)
            {
              if(IsPlayerConnected(giveplayerid))
              {
                if(giveplayerid != INVALID_PLAYER_ID)
                {
                      GetPlayerName(giveplayerid, giveplayer, sizeof(giveplayer));
                        GetPlayerName(playerid, sendername, sizeof(sendername));
                        new year, month,day;
                        getdate(year, month, day);
                        format(string, sizeof(string), "AdmCmd: %s foi banido por %s, Razгo: %s (%d-%d-%d)", giveplayer, sendername, tmp2,month,day,year);
                        BanLog(string);
                        format(string, sizeof(string), "AdmCmd: %s foi banido por %s, Razгo: %s", giveplayer, sendername, tmp2);
                        SendClientMessageToAll(COLOR_LIGHTRED, string);
                        PlayerInfo[giveplayerid][pLocked] = 1;
                        Ban(giveplayerid);
                        return 1;
                    }
                }//not connected
                else
                {
                    format(string, sizeof(string), "  %d nгo й um player ativo.", giveplayerid);
                    SendClientMessage(playerid, COLOR_GRAD1, string);
                }
            }
        }
        return 1;
    }
Reply


Messages In This Thread
[Ajuda]bans - by keller012 - 25.05.2010, 21:52
Re: [Ajuda]bans - by PawninG - 25.05.2010, 21:57
Re: [Ajuda]bans - by ipsBruno - 25.05.2010, 22:01
Re: [Ajuda]bans - by keller012 - 25.05.2010, 22:35
Re: [Ajuda]bans - by zSuYaNw - 26.05.2010, 00:49
Re: [Ajuda]bans - by TiagoPS - 26.05.2010, 01:04
Re: [Ajuda]bans - by zSuYaNw - 26.05.2010, 01:12
Re: [Ajuda]bans - by SlashPT - 26.05.2010, 19:45
Re: [Ajuda]bans - by keller012 - 27.05.2010, 00:56
Re: [Ajuda]bans - by juniorjg - 27.05.2010, 01:57

Forum Jump:


Users browsing this thread: 1 Guest(s)