error 022: must be lvalue (non-constant) - 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 022: must be lvalue (non-constant) (
/showthread.php?tid=523256)
error 022: must be lvalue (non-constant) -
ilay65 - 01.07.2014
stock AdminRank(playerid)
{
new file[64];
GetPlayerName(playerid,pname,MAX_PLAYER_NAME);
format(file, 64, "Admin/Users/%s.ini", pname);
return DOF2_GetInt(file, "AdminRank");
}
The error line: AdminRank(playerid) = DOF2_GetInt(GetFile(playerid), "AdminRank");
pliz helpp!!
Re: error 022: must be lvalue (non-constant) -
Rittik - 01.07.2014
Код:
stock AdminRank(playerid)
{
new file[64],temp;
GetPlayerName(playerid,pname,MAX_PLAYER_NAME);
format(file, 64, "Admin/Users/%s.ini", pname);
temp=DOF2_GetInt(file, "AdminRank");
return temp;
}
Re: error 022: must be lvalue (non-constant) -
ilay65 - 01.07.2014
still error about this line:
AdminRank(playerid) = DOF2_GetInt(GetFile(playerid), "AdminRank");
error:
error 022: must be lvalue (non-constant)
Re: error 022: must be lvalue (non-constant) -
Vince - 01.07.2014
What the hell are you even doing. Assigning a value to a function? This makes no sense. At all.
Re: error 022: must be lvalue (non-constant) -
ilay65 - 01.07.2014
So how do I define the value of AdminLevel?
Re: error 022: must be lvalue (non-constant) -
ilay65 - 01.07.2014
Help Pliz!!