SA-MP Forums Archive
invalid expression, assumed zero - 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: invalid expression, assumed zero (/showthread.php?tid=522682)



invalid expression, assumed zero - mehdi171996 - 28.06.2014

hello guys i have little probleme plz help me
errors
(1366) : error 035: argument type mismatch (argument 2)
(1366) : error 029: invalid expression, assumed zero
(1366) : error 029: invalid expression, assumed zero
(1366) : fatal error 107: too many error messages on one line







this is the script
SCM id defined by SendClientMessage

pawn Код:
YCMD:ahelp(playerid, params[], help)
{
        #pragma unused help
        #pragma unused params
        if(P_Data[playerid][pAdmin] < 1) return SCM(playerid,COLOR_RED, "You have no permission to use this command!");//line 1366
        SCM(playerid,COL_ORA,"Operator Command's":);
        SCM(playerid,COL_YELLOW," /duty /count /kick /mute /unmute /freeze /unfreeze /getip /slap  /a /spec /specoff /explode /setweather");
        SCM(playerid,COL_ORA,"Helper Command's":);
        SCM(playerid,COL_YELLOW,"/rtc /announce /eject /heal /asmg /clearchat");
        SCM(playerid,COL_ORA,"Admin Command's":);
        SCM(playerid,COL_YELLOW,"/setcarcolor /kill /setwtime /amoney");
        SCM(playerid,COL_ORA,"Senior Admin Command's":);
        SCM(playerid,COL_YELLOW,"/fixcar /giveweapon /disarm /rac /muted");
        SCM(playerid,COL_ORA,"Head Admin Command's":)
        SCM(playerid,COL_YELLOW,"/setskin /get /ban /goto /allips /frozenp");
        SCM(playerid,COL_ORA,"Developer Command's":)
        SCM(playerid,COL_YELLOW,"/warn /armourall /healall /tpall");
        SCM(playerid,COL_ORA,"Co-Owner Command's":);
        SCM(playerid,COL_YELLOW,"/setscore /kickall /gotopos /jetpack");
        SCM(playerid,COL_ORA,"Owner Command's":);
        SCM(playerid,COL_YELLOW,"?":);

        return 1;
};
plz help me hx


Re: invalid expression, assumed zero - kamiliuxliuxliux - 28.06.2014

Mark 1366 line.

EDIT: And put whole piece of script into [.pawn][/.pawn] (without dot)



Re: invalid expression, assumed zero - Jimmy0wns - 28.06.2014

pawn Код:
YCMD:ahelp(playerid, params[], help)
{
        #pragma unused help
        #pragma unused params
        if(P_Data[playerid][pAdmin] < 1) return SCM(playerid,COLOR_RED, "You have no permission to use this command!");
        SCM(playerid,COL_ORA,"Operator Command's:");
        SCM(playerid,COL_YELLOW," /duty /count /kick /mute /unmute /freeze /unfreeze /getip /slap  /a /spec /specoff /explode /setweather");
        SCM(playerid,COL_ORA,"Helper Command's:");
        SCM(playerid,COL_YELLOW,"/rtc /announce /eject /heal /asmg /clearchat");
        SCM(playerid,COL_ORA,"Admin Command's:");
        SCM(playerid,COL_YELLOW,"/setcarcolor /kill /setwtime /amoney");
        SCM(playerid,COL_ORA,"Senior Admin Command's:");
        SCM(playerid,COL_YELLOW,"/fixcar /giveweapon /disarm /rac /muted");
        SCM(playerid,COL_ORA,"Head Admin Command's:");
        SCM(playerid,COL_YELLOW,"/setskin /get /ban /goto /allips /frozenp");
        SCM(playerid,COL_ORA,"Developer Command's:");
        SCM(playerid,COL_YELLOW,"/warn /armourall /healall /tpall");
        SCM(playerid,COL_ORA,"Co-Owner Command's:");
        SCM(playerid,COL_YELLOW,"/setscore /kickall /gotopos /jetpack");
        SCM(playerid,COL_ORA,"Owner Command's:");
        SCM(playerid,COL_YELLOW,"?:");

        return 1;
};



Re : Re: invalid expression, assumed zero - mehdi171996 - 29.06.2014

Quote:
Originally Posted by Jimmy0wns
Посмотреть сообщение
pawn Код:
YCMD:ahelp(playerid, params[], help)
{
        #pragma unused help
        #pragma unused params
        if(P_Data[playerid][pAdmin] < 1) return SCM(playerid,COLOR_RED, "You have no permission to use this command!");
        SCM(playerid,COL_ORA,"Operator Command's:");
        SCM(playerid,COL_YELLOW," /duty /count /kick /mute /unmute /freeze /unfreeze /getip /slap  /a /spec /specoff /explode /setweather");
        SCM(playerid,COL_ORA,"Helper Command's:");
        SCM(playerid,COL_YELLOW,"/rtc /announce /eject /heal /asmg /clearchat");
        SCM(playerid,COL_ORA,"Admin Command's:");
        SCM(playerid,COL_YELLOW,"/setcarcolor /kill /setwtime /amoney");
        SCM(playerid,COL_ORA,"Senior Admin Command's:");
        SCM(playerid,COL_YELLOW,"/fixcar /giveweapon /disarm /rac /muted");
        SCM(playerid,COL_ORA,"Head Admin Command's:");
        SCM(playerid,COL_YELLOW,"/setskin /get /ban /goto /allips /frozenp");
        SCM(playerid,COL_ORA,"Developer Command's:");
        SCM(playerid,COL_YELLOW,"/warn /armourall /healall /tpall");
        SCM(playerid,COL_ORA,"Co-Owner Command's:");
        SCM(playerid,COL_YELLOW,"/setscore /kickall /gotopos /jetpack");
        SCM(playerid,COL_ORA,"Owner Command's:");
        SCM(playerid,COL_YELLOW,"?:");

        return 1;
};
pawn Код:
C:\Users\PC\Downloads\LSAdminfault.pwn(1275) : warning 202: number of arguments does not match definition
C:\Users\PC\Downloads\LSAdminfault.pwn(1367) : error 035: argument type mismatch (argument 2)
C:\Users\PC\Downloads\LSAdminfault.pwn(1368) : error 035: argument type mismatch (argument 2)
C:\Users\PC\Downloads\LSAdminfault.pwn(1369) : error 035: argument type mismatch (argument 2)
C:\Users\PC\Downloads\LSAdminfault.pwn(1370) : error 035: argument type mismatch (argument 2)
C:\Users\PC\Downloads\LSAdminfault.pwn(1371) : error 035: argument type mismatch (argument 2)
C:\Users\PC\Downloads\LSAdminfault.pwn(1372) : error 035: argument type mismatch (argument 2)
C:\Users\PC\Downloads\LSAdminfault.pwn(1373) : error 035: argument type mismatch (argument 2)
C:\Users\PC\Downloads\LSAdminfault.pwn(1374) : error 035: argument type mismatch (argument 2)
C:\Users\PC\Downloads\LSAdminfault.pwn(1375) : error 035: argument type mismatch (argument 2)
C:\Users\PC\Downloads\LSAdminfault.pwn(1376) : error 035: argument type mismatch (argument 2)
C:\Users\PC\Downloads\LSAdminfault.pwn(1377) : error 035: argument type mismatch (argument 2)
C:\Users\PC\Downloads\LSAdminfault.pwn(1378) : error 035: argument type mismatch (argument 2)
C:\Users\PC\Downloads\LSAdminfault.pwn(1379) : error 035: argument type mismatch (argument 2)
C:\Users\PC\Downloads\LSAdminfault.pwn(1380) : error 035: argument type mismatch (argument 2)
C:\Users\PC\Downloads\LSAdminfault.pwn(1381) : error 035: argument type mismatch (argument 2)
C:\Users\PC\Downloads\LSAdminfault.pwn(1382) : error 035: argument type mismatch (argument 2)
C:\Users\PC\Downloads\LSAdminfault.pwn(1385) : error 010: invalid function or declaration



Re: invalid expression, assumed zero - AiRaLoKa - 29.06.2014

try to use default SendClientMessage

pawn Код:
YCMD:ahelp(playerid, params[], help)
{
        #pragma unused help
        #pragma unused params
        if(P_Data[playerid][pAdmin] < 1) return SendClientMessage(playerid,COLOR_RED, "You have no permission to use this command!");
        SendClientMessage(playerid,COL_ORA,"Operator Command's:");
        SendClientMessage(playerid,COL_YELLOW," /duty /count /kick /mute /unmute /freeze /unfreeze /getip /slap  /a /spec /specoff /explode /setweather");
        SendClientMessage(playerid,COL_ORA,"Helper Command's:");
        SendClientMessage(playerid,COL_YELLOW,"/rtc /announce /eject /heal /asmg /clearchat");
        SendClientMessage(playerid,COL_ORA,"Admin Command's:");
        SendClientMessage(playerid,COL_YELLOW,"/setcarcolor /kill /setwtime /amoney");
        SendClientMessage(playerid,COL_ORA,"Senior Admin Command's:");
        SendClientMessage(playerid,COL_YELLOW,"/fixcar /giveweapon /disarm /rac /muted");
        SendClientMessage(playerid,COL_ORA,"Head Admin Command's:");
        SendClientMessage(playerid,COL_YELLOW,"/setskin /get /ban /goto /allips /frozenp");
        SendClientMessage(playerid,COL_ORA,"Developer Command's:");
        SendClientMessage(playerid,COL_YELLOW,"/warn /armourall /healall /tpall");
        SendClientMessage(playerid,COL_ORA,"Co-Owner Command's:");
        SendClientMessage(playerid,COL_YELLOW,"/setscore /kickall /gotopos /jetpack");
        SendClientMessage(playerid,COL_ORA,"Owner Command's:");
        SendClientMessage(playerid,COL_YELLOW,"?:");

        return 1;
};



Re : Re: invalid expression, assumed zero - mehdi171996 - 29.06.2014

Quote:
Originally Posted by AiRaLoKa
Посмотреть сообщение
try to use default SendClientMessage

pawn Код:
YCMD:ahelp(playerid, params[], help)
{
        #pragma unused help
        #pragma unused params
        if(P_Data[playerid][pAdmin] < 1) return SendClientMessage(playerid,COLOR_RED, "You have no permission to use this command!");
        SendClientMessage(playerid,COL_ORA,"Operator Command's:");
        SendClientMessage(playerid,COL_YELLOW," /duty /count /kick /mute /unmute /freeze /unfreeze /getip /slap  /a /spec /specoff /explode /setweather");
        SendClientMessage(playerid,COL_ORA,"Helper Command's:");
        SendClientMessage(playerid,COL_YELLOW,"/rtc /announce /eject /heal /asmg /clearchat");
        SendClientMessage(playerid,COL_ORA,"Admin Command's:");
        SendClientMessage(playerid,COL_YELLOW,"/setcarcolor /kill /setwtime /amoney");
        SendClientMessage(playerid,COL_ORA,"Senior Admin Command's:");
        SendClientMessage(playerid,COL_YELLOW,"/fixcar /giveweapon /disarm /rac /muted");
        SendClientMessage(playerid,COL_ORA,"Head Admin Command's:");
        SendClientMessage(playerid,COL_YELLOW,"/setskin /get /ban /goto /allips /frozenp");
        SendClientMessage(playerid,COL_ORA,"Developer Command's:");
        SendClientMessage(playerid,COL_YELLOW,"/warn /armourall /healall /tpall");
        SendClientMessage(playerid,COL_ORA,"Co-Owner Command's:");
        SendClientMessage(playerid,COL_YELLOW,"/setscore /kickall /gotopos /jetpack");
        SendClientMessage(playerid,COL_ORA,"Owner Command's:");
        SendClientMessage(playerid,COL_YELLOW,"?:");

        return 1;
};
same errors