OnPlayerSpawn Kick Error/
#1

I got an error when I compiled this, it says that the code isn't recognized.... anyone know whats wrong?
Код:
public OnPlayerSpawn(playerid)
{
 	if(!udb_Exists(PlayerName(playerid)))
	{
		SendClientMessage(playerid, COLOR_RED, "You have been kicked due to not registering! Please reconnect to the server and use");
		SendClientMessage(playerid, COLOR_RED, "/register <password> to create an account.");
		Kick(playerid); // this isn't reconized
		return true;
	}
  if(udb_Exists(PlayerName(playerid)))
	{
		SendClientMessage(playerid, COLOR_RED, "You have been kicked due to not registering! Your account was created/ existed but");
		SendClientMessage(playerid, COLOR_RED, "You failed to use /login <password> If this was a mistake, please reconnect to the");
		SendClientMessage(playerid, COLOR_RED, "server and use /login <password> or if you have NEVER registered on this server, reconnect");
		SendClientMessage(playerid, COLOR_RED, "To the sevrer with a different name and use /register <password>");
		Kick(playerid); // this isn't reconized
		return true;
	}
	PlayerData[playerid][Logged] = 0;
	PlayerData[playerid][Muted] = 0;
	PlayerData[playerid][AdminLevel] = 0;
	PlayerData[playerid][Kicks] = 0;
	PlayerData[playerid][Bans] = 0;
	return true;
}
(Kicks a player if they fail to login or register )
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)