I got some errors, if you're willing to help me!
#1

So i got this

C:\Users\Alex\Desktop\New folder\gamemodes\WGRP.pwn(102) : error 017: undefined symbol "PlayerInfo"
C:\Users\Alex\Desktop\New folder\gamemodes\WGRP.pwn(102) : warning 215: expression has no effect
C:\Users\Alex\Desktop\New folder\gamemodes\WGRP.pwn(102) : error 001: expected token: ";", but found "]"
C:\Users\Alex\Desktop\New folder\gamemodes\WGRP.pwn(102) : error 029: invalid expression, assumed zero
C:\Users\Alex\Desktop\New folder\gamemodes\WGRP.pwn(102) : fatal error 107: too many error messages on one line

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


4 Errors.



On this



}

forward LoadUser_data(playerid,name[],value[]);
public LoadUser_data(playerid,name[],value[])
{
INI_Int("Password",PlayerInfo[playerid][pPass]);
INI_Int("Level",PlayerInfo[playerid][pLevel]);
INI_Int("Cash",PlayerInfo[playerid][pCash]);
INI_Int("Admin",PlayerInfo[playerid][pAdmin]);
INI_Int("Age",PlayerInfo[playerid][pAge]);
INI_Int("Origin",PlayerInfo[playerid][pOrigin]);
INI_Int("Sex",PlayerInfo[playerid][pSex]);
INI_Int("Model",PlayerInfo[playerid][pModel]);
INI_Int("DriveLic",PlayerInfo[playerid][pDriveLic]);
INI_Int("Place",PlayerInfo[playerid][pPlace]);
INI_Int("Exp",PlayerInfo[playerid][pExp]);
INI_Int("Admin",PlayerInfo[playerid][pAdmin]);
INI_Int("Number",PlayerInfo[playerid][pNumber]);
INI_Int("Tester",PlayerInfo[playerid][pTester]);
INI_Int("Warns",PlayerInfo[playerid][pWarns]);
INI_Int("Selected",PlayerInfo[playerid][pSelected]);
INI_Int("Muted",PlayerInfo[playerid][pMuted]);
INI_Int("MuteTime",PlayerInfo[playerid][pMuteTime]);
INI_Int("FirstJoined",PlayerInfo[playerid][pFirstJoined]);
INI_Int("Vip",PlayerInfo[playerid][pVip]);
INI_Int("Spawn",PlayerInfo[playerid][pSpawn]);
INI_Int("Locked",PlayerInfo[playerid][pLocked]);
return 1;
};

public OnPlayerConnect(playerid)
Reply
#2

Can u saw me Line 102?
Reply
#3

INI_Int("Password",PlayerInfo[playerid][pPass]);


This is line 102
Reply
#4

Код:
INI_Int("Password",PlayerInfo[playerid][pPass]);
Can you put it as This?

Код:
INI_Int("Password",PlayerInfo[playerid][pPass]");
And Test it if its work
Reply
#5

C:\Users\Alex\Desktop\New folder\gamemodes\WGRP.pwn(100) : error 017: undefined symbol "INI_Int"
C:\Users\Alex\Desktop\New folder\gamemodes\WGRP.pwn(100) : warning 215: expression has no effect
C:\Users\Alex\Desktop\New folder\gamemodes\WGRP.pwn(100) : error 001: expected token: ";", but found "]"
C:\Users\Alex\Desktop\New folder\gamemodes\WGRP.pwn(100) : error 029: invalid expression, assumed zero
C:\Users\Alex\Desktop\New folder\gamemodes\WGRP.pwn(100) : fatal error 107: too many error messages on one line



(its line 100 now as i deleted some unused comments)
Reply
#6

Your PlayerInfo thingy isn't defined, probably you just copied this scrips... here how you can define it sir

PHP код:
enum info {
   
pPass,
   
pLevel,
   
pCash,
   
pAdmin,
   
pAge,
   
pOrigin,
   
pSex,
   
pModel,
   
pDriveLic,
   
pPlace,
   
pExp,
   
pNumber,
   
pTester,
   
pWarns,
   
pSelected,
   
pMuted,
   
pMutetTime,
   
pFirstJoined,
   
pVip,
   
pSpawn,
   
pLocked.
}
new 
PlayerInfo[MAX_PLAYERS][info];

forward LoadUser_data(playerid,name[],value[]);
public 
LoadUser_data(playerid,name[],value[])
{
INI_Int("Password",PlayerInfo[playerid][pPass]);
INI_Int("Level",PlayerInfo[playerid][pLevel]);
INI_Int("Cash",PlayerInfo[playerid][pCash]);
INI_Int("Admin",PlayerInfo[playerid][pAdmin]);
INI_Int("Age",PlayerInfo[playerid][pAge]);
INI_Int("Origin",PlayerInfo[playerid][pOrigin]);
INI_Int("Sex",PlayerInfo[playerid][pSex]);
INI_Int("Model",PlayerInfo[playerid][pModel]);
INI_Int("DriveLic",PlayerInfo[playerid][pDriveLic]);
INI_Int("Place",PlayerInfo[playerid][pPlace]);
INI_Int("Exp",PlayerInfo[playerid][pExp]);
INI_Int("Admin",PlayerInfo[playerid][pAdmin]);
INI_Int("Number",PlayerInfo[playerid][pNumber]);
INI_Int("Tester",PlayerInfo[playerid][pTester]);
INI_Int("Warns",PlayerInfo[playerid][pWarns]);
INI_Int("Selected",PlayerInfo[playerid][pSelected]);
INI_Int("Muted",PlayerInfo[playerid][pMuted]);
INI_Int("MuteTime",PlayerInfo[playerid][pMuteTime]);
INI_Int("FirstJoined",PlayerInfo[playerid][pFirstJoined]);
INI_Int("Vip",PlayerInfo[playerid][pVip]);
INI_Int("Spawn",PlayerInfo[playerid][pSpawn]);
INI_Int("Locked",PlayerInfo[playerid][pLocked]);
return 
1;
}; 
Reply
#7

It was a tutorial but not that good. i will check it now. Thanks for help!
Reply
#8

That got fixed but i have another errors now, i think i'll quit scripting haha.
Reply
#9

I still get these

C:\Users\Alex\Desktop\New folder\gamemodes\WGRP.pwn(139) : error 001: expected token: ",", but found ";"
C:\Users\Alex\Desktop\New folder\gamemodes\WGRP.pwn(139) : error 036: empty statement
C:\Users\Alex\Desktop\New folder\gamemodes\WGRP.pwn(139) : warning 215: expression has no effect
C:\Users\Alex\Desktop\New folder\gamemodes\WGRP.pwn(139) : error 001: expected token: ";", but found ")"
C:\Users\Alex\Desktop\New folder\gamemodes\WGRP.pwn(139) : fatal error 107: too many error messages on one line

public OnPlayerConnect(playerid)
{
if(fexist(UserPath(playerid))) //this is line 139
{
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...",""C OL_WHITE"Type your password below to register a new account.","Register","Quit");
}
return 1;


As i said, i try to learn and this is just a tutorial i followed but seem to be a problem on line 139 everytime.
Reply
#10

Change
PHP код:
public OnPlayerConnect(playerid)
{
if(
fexist(UserPath(playerid))) //this is line 139
{
INI_ParseFile(UserPath(playerid), "LoadUser_%s", .bExtra true, .extra playerid);
ShowPlayerDialog(playeridDIALOG_LOGINDIALOG_STYLE_INPUT,""COL_WHITE"Login",""COL_WHITE" Type your password below to login.","Login","Quit");
}
else
{
ShowPlayerDialog(playeridDIALOG_REGISTERDIALOG_STYLE_INPUT,""COL_WHITE"Registering...",""C OL_WHITE"Type your password below to register a new account.","Register","Quit");
}
return 
1
To:

PHP код:
public OnPlayerConnect(playerid)
{
if(
fexist(UserPath(playerid)));
{
INI_ParseFile(UserPath(playerid), "LoadUser_%s", .bExtra true, .extra playerid);
ShowPlayerDialog(playeridDIALOG_LOGINDIALOG_STYLE_INPUT,""COL_WHITE"Login",""COL_WHITE" Type your password below to login.","Login","Quit");
}
else
{
ShowPlayerDialog(playeridDIALOG_REGISTERDIALOG_STYLE_INPUT,""COL_WHITE"Registering...",""C OL_WHITE"Type your password below to register a new account.","Register","Quit");
}
return 
1
Reply


Forum Jump:


Users browsing this thread: 3 Guest(s)