Y_INI Registration System Issues
#1

I started a new script using Y_INI for the first time and I used this tutorial https://sampforum.blast.hk/showthread.php?tid=273088

Below when I added all that stuff i get the following errors.

Код:
C:\Users\COMPUTER\Desktop\SAMPservProject\gamemodes\deathmatch.pwn(200) : error 001: expected token: "-string end-", but found "-identifier-"
C:\Users\COMPUTER\Desktop\SAMPservProject\gamemodes\deathmatch.pwn(200) : warning 215: expression has no effect
C:\Users\COMPUTER\Desktop\SAMPservProject\gamemodes\deathmatch.pwn(200) : error 001: expected token: ";", but found "-string-"
C:\Users\COMPUTER\Desktop\SAMPservProject\gamemodes\deathmatch.pwn(200) : warning 215: expression has no effect
C:\Users\COMPUTER\Desktop\SAMPservProject\gamemodes\deathmatch.pwn(200) : error 001: expected token: "-string end-", but found "-identifier-"
C:\Users\COMPUTER\Desktop\SAMPservProject\gamemodes\deathmatch.pwn(200) : fatal error 107: too many error messages on one line

Compilation aborted.Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase


4 Errors.
Line 200
Код:
			ShowPlayerDialog(playerid, DIALOG_LOGIN, DIALOG_STYLE_INPUT,""COLOR_WHITE"Login",""COLOR_WHITE"Type your password below to login.","Login","Quit");
Lines around it.

Код:
public OnPlayerConnect(playerid)
{
	SendClientMessage (playerid, COLOR_WHITE, "-----------------------------");
	SendClientMessage (playerid, COLOR_GREY, "Welcome to Deathmatch Script!");
	SendClientMessage (playerid, COLOR_GREY, "IP:127.0.0.1");
	SendClientMessage (playerid, COLOR_GREY, "Teamspeak: 127.0.0.1");
	SendClientMessage (playerid, COLOR_WHITE, "-----------------------------");
	if(fexist(UserPath(playerid)))
    	{
        	INI_ParseFile(UserPath(playerid), "LoadUser_%s", .bExtra = true, .extra = playerid);
			ShowPlayerDialog(playerid, DIALOG_LOGIN, DIALOG_STYLE_INPUT,""COLOR_WHITE"Login",""COLOR_WHITE"Type your password below to login.","Login","Quit");
    	}
   		else
    	{
        	ShowPlayerDialog(playerid, DIALOG_REGISTER, DIALOG_STYLE_INPUT,""COLOR_WHITE"Registering...",""COLOR_WHITE"Type your password below to register a new account.","Register","Quit");
	}
    return 1;
}
Reply
#2

I think that you may have defined COLOR_WHITE wrongly.

Make sure you defined it like this
pawn Код:
#define COLOR_WHITE "{FFFFFF}"
Reply
#3

Thats not it.
Reply
#4

Thats one of the pawno bugs I guess. Do this:
pawn Код:
new String[100], str[20];
format(String,100,"%s%s","COLOR_WHITE","Type your password below to login.");
format(String,100,"%s%s","COLOR_WHITE","Login");
ShowPlayerDialog(playerid, DIALOG_LOGIN, DIALOG_STYLE_INPUT,str,String,"Login","Quit");
this should work;
Reply
#5

pawn Код:
ShowPlayerDialog(playerid, D_LOGIN, DIALOG_STYLE_INPUT,""COLOR_WHITE"""Login",""COLOR_WHITE"""Type your password below to login.","Login","Quit");
I think this might work. I haven't tested it though. It's simpler to use this, than what the poster above said to do.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)