12.07.2011, 16:32
Hi,
Here's my code:
But for some reason it kicks player before sending those messages.. Why?
If I comment the "Kick" part, it sends the messages and everything seems to be ok..
Here's my code:
pawn Код:
mysql_query(queryStr);
mysql_store_result();
if(mysql_num_rows() > 0)
{
new tmpData[24];
while(mysql_retrieve_row())
{
mysql_fetch_field_row(tmpData,"BannedBy");
new msg[64];
format(msg,64,"You are banned from this server by %s!",tmpData);
SendClientMessage(playerid,cError,msg);
mysql_fetch_field_row(tmpData,"BanEnds");
format(msg,64,"Ban ends at %s",tmpData);
SendClientMessage(playerid,cError,msg);
}
SendClientMessage(playerid,cError,"Bye!");
mysql_free_result();
Kick(playerid);
}
If I comment the "Kick" part, it sends the messages and everything seems to be ok..