SA-MP Forums Archive
Admin filterscript warning and errors - 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: Admin filterscript warning and errors (/showthread.php?tid=612010)



Admin filterscript warning and errors - Ryox175 - 13.07.2016

As now I tried to make aSystem with zcmd, now i get those errors:
PHP код:
C:\Users\kuldar\Documents\samp\filterscripts\kAdmin.pwn(141) : warning 217loose indentation
C
:\Users\kuldar\Documents\samp\filterscripts\kAdmin.pwn(143) : error 001expected token")"but found "return"
C:\Users\kuldar\Documents\samp\filterscripts\kAdmin.pwn(143) : error 037invalid string (possibly non-terminated string)
C:\Users\kuldar\Documents\samp\filterscripts\kAdmin.pwn(143) : error 029invalid expressionassumed zero
C
:\Users\kuldar\Documents\samp\filterscripts\kAdmin.pwn(143) : fatal error 107too many error messages on one line 
Line 141 and 143:
pawn Код:
Line 141:   if(IsPlayerAdmin(playerid))

Line 143:       if(sscanf(params,"ud",id,level) return SendClientMessage(playerid, 0xFFFFFF, "{00CED1}KTW: {FFFFFF}Usage: /promote name/id level);



Re: Admin filterscript warning and errors - JuzDoiT - 13.07.2016

try this

Quote:

if(IsPlayerAdmin(playerid))
{
if(sscanf(params,"ud",id,level) return SendClientMessage(playerid, 0xFFFFFF, "{00CED1}KTW: {FFFFFF}Usage: /promote name/id level);


Use this at end of command "}"



Re: Admin filterscript warning and errors - TaiRinsuru - 13.07.2016

You are missing one parenthesis

Quote:

if(sscanf(params,"ud",id,level) return SendClientMessage(playerid, 0xFFFFFF, "{00CED1}KTW: {FFFFFF}Usage: /promote name/id level);

Use this:
pawn Код:
if(sscanf(params,"ud",id,level)) return SendClientMessage(playerid, 0xFFFFFF, "{00CED1}KTW: {FFFFFF}Usage: /promote name/id level);

It should work.


Re: Admin filterscript warning and errors - Ryox175 - 13.07.2016

both didint work good, still gives me errors:
pawn Код:
C:\Users\kuldar\Documents\samp\filterscripts\kAdmin.pwn(143) : error 037: invalid string (possibly non-terminated string)
C:\Users\kuldar\Documents\samp\filterscripts\kAdmin.pwn(143) : error 029: invalid expression, assumed zero
C:\Users\kuldar\Documents\samp\filterscripts\kAdmin.pwn(143) : error 029: invalid expression, assumed zero
C:\Users\kuldar\Documents\samp\filterscripts\kAdmin.pwn(143) : fatal error 107: too many error messages on one line