SA-MP Forums Archive
[HELP] Register system Error - Printable Version

+- SA-MP Forums Archive (https://sampforum.blast.hk)
+-- Forum: SA-MP Server (https://sampforum.blast.hk/forumdisplay.php?fid=6)
+--- Forum: Server Support (https://sampforum.blast.hk/forumdisplay.php?fid=19)
+--- Thread: [HELP] Register system Error (/showthread.php?tid=302103)



[HELP] Register system Error - olabv - 07.12.2011

Hello i am currently trying to create this dialog base register/login system but i get this error:

Код:
\filterscripts\register.pwn(100) : warning 202: number of arguments does not match definition
\filterscripts\register.pwn(101) : error 001: expected token: ")", but found "{"
Код:
stock Login(playerid,key[])
{
	new data[64];
	new name[MAX_PLAYER_NAME];
	GetPlayerName(playerid, name, sizeof(name));
	format(data, sizeof(data), "/Accounts/#s.txt", name);
	
line 100	if(!strcmp(key,dini_Get(data,"Password",false))
line 101	{
	     SetPlayerScore(playerid,dini_Int(data,"Score"));
	     SendClientMessage(playerid,0xFFFFFFFF, "Login Successful!");
	     return 1;
	}
	else
	{
		SendClientMessage(playerid,0xFF0000FF, "Wrong Password!");
		ShowPlayerDialog(playerid, DIALOG_LOGIN, DIALOG_STYLE_INPUT, "Login", "Please login by typing you password below.", "Login", "Cancel");
	     return 1;
	}
}



Re: [HELP] Register system Error - Thresholdold - 07.12.2011

Which line is 100 and which one is 101?


Re: [HELP] Register system Error - olabv - 07.12.2011

edited


Re: [HELP] Register system Error - Thresholdold - 07.12.2011

Try
pawn Код:
line 100    if(!strcmp(key,dini_Get(data,"Password",false)))
??


Re: [HELP] Register system Error - olabv - 07.12.2011

xD i feel so dumb right now xD THX MAN


Re: [HELP] Register system Error - Thresholdold - 07.12.2011

lol np. Congrats on your 100th post xD


Re: [HELP] Register system Error - olabv - 07.12.2011

Thx