errors
#1

Hello mates Im getting some errors that are kind of weird I was hoping someone would be able to help me out on this.
(2286) : error 012: invalid function call, not a valid address
(2286) : warning 215: expression has no effect
(2286) : error 001: expected token: ";", but found ")"
(2286) : error 029: invalid expression, assumed zero
(2286) : fatal error 107: too many error messages on one line

and these are the lines

Код:
if(udb_Exists(PlayerName(playerid)))
	{
		SendClientMessage(playerid,COLOR_ERROR,"This player name has already been registered. Please login before you spawn.");
		ShowLoginScreen(playerid);
	}
	else if(!udb_Exists(PlayerName(playerid)))
	{
		SendClientMessage(playerid,COLOR_ERROR,"This player name has not been registered. You must register before playing.");
		ShowRegisterScreen(playerid);
	}

	for(new i = 0; i < sizeof(Objects); i++) Player[playerid][view][i] = false; 
	
	return 1;
}
all the way to 2300
Can someone please help me out on this?
Reply
#2

Show us udb_Exists function.
Reply
#3

Where exactly can I find that in my script lol Im new on this script and I have no idea where it is.
Reply
#4

CTRL+F > enter 'udb_Exists' > go to lines.
Reply
#5

Код:
	if(udb_Exists(PlayerName(playerid)))
	{
		SendClientMessage(playerid,COLOR_ERROR,"This player name has already been registered. Please login before you spawn.");
		ShowLoginScreen(playerid);
	}
	else if(!udb_Exists(PlayerName(playerid)))
	{
		SendClientMessage(playerid,COLOR_ERROR,"This player name has not been registered. You must register before playing.");
		ShowRegisterScreen(playerid);
	}

	for(new i = 0; i < sizeof(Objects); i++) Player[playerid][view][i] = false; /////////xobj
	
	return 1;
}
Код:
public OnPlayerRequestSpawn(playerid)
{
    if(IsPlayerNPC(playerid)) return 1;
    if (!udb_Exists(PlayerName(playerid)))
	{
        ShowRegisterScreen(playerid);
		return 0;
	}
	if (!PLAYERLIST_authed[playerid]) {
		ShowLoginScreen(playerid);
		return 0;
	}
	if(gTeam[playerid] < 9 && SavedWantedLevel[playerid] != 0)
	{
	    SendClientMessage(playerid,COLOR_ERROR,"You cannot use this class as you were wanted last time you left the server.");
	    return 0;
	}
	if(gTeam[playerid] < 9 && SavedJailTime[playerid] != 0)
	{
	    SendClientMessage(playerid,COLOR_ERROR,"You cannot use this class as you were in jail last time you left the server.");
	    return 0;
	}
	if(gTeam[playerid] == TEAM_ARMY && CanUseArmy[playerid] != 6)
	{
	    SendClientMessage(playerid,COLOR_ERROR,"You do not have permission to use this class. You can apply for it on our forums.");
		return 0;
	}
	if(gTeam[playerid] == TEAM_CIA && CanUseCIA[playerid] != 6)
	{
	    SendClientMessage(playerid,COLOR_ERROR,"You do not have permission to use this class. You can apply for it on our forums.");
		return 0;
	}
	if(GetPlayerSkin(playerid) == 286 && GetPlayerScore(playerid) <= 499)
	{
	    SendClientMessage(playerid,COLOR_ERROR,"You do not have permission to use this class. You must gain 500 score before using this class.");
		return 0;
	}
	if(gTeam[playerid] == TEAM_COP && GetPlayerScore(playerid) <= 49)
	{
	    SendClientMessage(playerid,COLOR_ERROR,"You do not have permission to use this class. You must gain 50 score before using this class.");
		return 0;
	}
	return 1;
}
Reply
#6

Ok, I still need to see the function udb_Exists itself, not its usage.
should start with 'public udb_Exists' or 'stock udb_Exists' or just udb_Exists itself.
Reply
#7

I cant find public udb_Exists or stock udb_Exists
when I search up just udb_Exists
I get this
Код:
//Check to see if they are registered or logged in
	if(udb_Exists(PlayerName(playerid)))
	{
		SendClientMessage(playerid,COLOR_ERROR,"This player name has already been registered. Please login before you spawn.");
		ShowLoginScreen(playerid);
	}
	else if(!udb_Exists(PlayerName(playerid)))
	{
		SendClientMessage(playerid,COLOR_ERROR,"This player name has not been registered. You must register before playing.");
		ShowRegisterScreen(playerid);
	}

	for(new i = 0; i < sizeof(Objects); i++) Player[playerid][view][i] = false; /////////xobj
	
	return 1;
}
Reply
#8

*BUMP*
Reply
#9

Show some of the lines which are before line 2286.
Reply
#10

The map icons are before the line 2286
Reply


Forum Jump:


Users browsing this thread: 3 Guest(s)