Registration. - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: Registration. (
/showthread.php?tid=542403)
Registration. -
mkmk - 19.10.2014
My registration is bugged, everything is okay other than this... As when I remove it I get no errors.
pawn Код:
public OnPlayerConnect(playerid)
{
if(fexist(UserPath(playerid)))
{
INI_ParseFile(UserPath(playerid), "LoadUser_%s", .bExtra = true, .extra = playerid);
ShowPlayerDialog(playerid, DIALOG_LOGIN, DIALOG_STYLE_INPUT,""COL_WHITE"Login",""COL_WHITE"Type your password below to login.","Login","Quit");
}
else
{
ShowPlayerDialog(playerid, DIALOG_REGISTER, DIALOG_STYLE_INPUT,""COL_WHITE"Registering...",""COL_WHITE"Type your password below to register a new account.","Register","Quit");
}
return 1;
}
Here are my errors.
error 017: undefined symbol "UserPath"
error 017: undefined symbol "UserPath"
error 017: undefined symbol "DIALOG_LOGIN"
error 001: expected token: "-string end-", but found "-identifier-"
fatal error 107: too many error messages on one line
Re: Registration. -
ThePhenix - 19.10.2014
Quote:
Originally Posted by mkmk
My registration is bugged, everything is okay other than this... As when I remove it I get no
error 017: undefined symbol "UserPath"
error 017: undefined symbol "UserPath"
error 017: undefined symbol "DIALOG_LOGIN"
error 001: expected token: "-string end-", but found "-identifier-"
fatal error 107: too many error messages on one line
|
No, it's not bugged.
The compiler clearly states that your script doesn't have a UserPath function defined, also it doesn't have DIALOG_LOGIN defined.
Respuesta: Registration. -
aoEXE - 19.10.2014
No is defined 'UserPath' and 'DIALOG_LOGIN' can't be clearer
Re: Registration. -
Quickie - 19.10.2014
add this function above ur mode
pawn Код:
stock UserPath(playerid)
{
new string_path[ 128 ],player_name[ MAX_PLAYER_NAME ];
GetPlayerName( playerid, player_name, MAX_PLAYER_NAME );
format( string_path, sizeof ( string_path ), "%s.ini ", player_name);
//you can change it to your account directory ex:"Accounts\%s.ini"
return string_path;
}
EDIT:forgot to close the statement "[/pawn]"