29.07.2009, 23:31
Hello there,
It doesn't happen often that I ask for help but here I need some.
I have set a timer to ban a player after 1 second that he is connected. The ban works perfectly and all. But any client message that I send to the player within the function is not sent. If I try to paste what's inside the function to the place and remove the timer, it still bans but doesn't send the client messages to the player. I also have put some print so it would echo them to the console, but nothing. Only the print shows, not the client messages.
Here is my function:
Also note that the print works, but the SendClientMessage doesn't. Everything else is fine.
Thank you.
It doesn't happen often that I ask for help but here I need some.
I have set a timer to ban a player after 1 second that he is connected. The ban works perfectly and all. But any client message that I send to the player within the function is not sent. If I try to paste what's inside the function to the place and remove the timer, it still bans but doesn't send the client messages to the player. I also have put some print so it would echo them to the console, but nothing. Only the print shows, not the client messages.
Here is my function:
pawn Код:
public GLine_Entry(playerid)
{
SetAccountInfo(Player[playerid][Nickname], "banned", "1");
new str[256];
format(str, 256, "Closing Link: %s[%s] (User has been permanently banned from *** (%s))", Player[playerid][Nickname], Player[playerid][IP], Player[playerid][BanReason]);
SendClientMessage(playerid, GREEN, str);
print(str);
BanEx(playerid, Player[playerid][BanReason]);
return 1;
}
Thank you.