[Ajuda] OnPlayerConnect
#6

Quote:
Originally Posted by .FuneraL.
Посмотреть сообщение
Creio eu que seja isso que vocк quer:

pawn Код:
public OnPlayerConnect(playerid) {
    new Nome[24];
    GetPlayerName(playerid, Nome, 24);
    if(!strfind(Nome, "_", true)) {
          SendClientMessage(playerid, -1, "Vocк Nгo Tem Underline no Nome...");
          Kick(playerid);
    }
    return 1;
}
O kick pode ser ineficiente

Kalkor explicou que o kick em seguida de mensagens pode ser ineficiente

Quote:
Originally Posted by Kalcor
Посмотреть сообщение
That never worked reliably.

pawn Код:
forward KickPublic(playerid);
public KickPublic(playerid) { Kick(playerid); }

KickWithMessage(playerid, message[])
{
    SendClientMessage(playerid, 0xFF4444FF, message);
    SetTimerEx("KickPublic", 1000, 0, "d", playerid);
}
Put that in your script. Now use KickWithMessage(playerid, "Bye!"); instead of SendClientMessage, Kick.
Reply


Messages In This Thread
OnPlayerConnect - by NuTShoT - 06.02.2013, 10:57
Re: OnPlayerConnect - by MegalodoN - 06.02.2013, 11:32
Re: OnPlayerConnect - by .FuneraL. - 06.02.2013, 11:37
Re: OnPlayerConnect - by Sky™ - 06.02.2013, 11:38
Re: OnPlayerConnect - by DanDRT - 06.02.2013, 11:38
Re: OnPlayerConnect - by Dwayne-Pheonix - 06.02.2013, 11:42

Forum Jump:


Users browsing this thread: 5 Guest(s)