SA-MP Forums Archive
error 001: expected token: ")", but found "[" - 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: error 001: expected token: ")", but found "[" (/showthread.php?tid=664223)



error 001: expected token: ")", but found "[" - mmlinaric - 22.02.2019

Hello!
So, I got this error:
PHP код:
error 001expected token")"but found "[" 
This is my code:
PHP код:
forward LoadUser_data(playerid,name[],value[]);
public 
LoadUser_data(playerid,name[],value[])
{
    
INI_String("Password",PlayerInfo[playerid][pPass]); // Error line
    
INI_Int("Cash",PlayerInfo[playerid][pCash]);
    
INI_Int("Email",PlayerInfo[playerid][pEmail]);
    
INI_Int("Godine",PlayerInfo[playerid][pGodine]);
    
INI_Int("Admin",PlayerInfo[playerid][pAdmin]);
    
INI_Int("Kills",PlayerInfo[playerid][pKills]);
    
INI_Int("Deaths",PlayerInfo[playerid][pDeaths]);
    return 
1;

Thank you guys!


Re: error 001: expected token: ")", but found "[" - GRiMMREAPER - 22.02.2019

INI_String(name[], variable , length );


That's the correct syntax.