SA-MP Forums Archive
help - 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: help (/showthread.php?tid=384109)



help - Windrush - 10.10.2012

i will gonna rep you if you fix this
Код:
if(INI_ReadString, "Swat", SaveINI, 30)
Код:
C:\Users\carlo\Desktop\CNRv0.3\gamemodes\RaNSEE.pwn(400) : error 076: syntax error in the expression, or invalid function call



Re: help - Kwarde - 10.10.2012

if(INI_ReadString, "Swat", SaveINI, 30);
Remove the semicolon (The ";"). So:
pawn Код:
if(INI_ReadString, "SWAT", SaveINI, 30)



Re: help - Windrush - 10.10.2012

pawn Код:
C:\Users\carlo\Desktop\CNRv0.3\gamemodes\RaNSEE.pwn(402) : error 076: syntax error in the expression, or invalid function call
C:\Users\carlo\Desktop\CNRv0.3\gamemodes\RaNSEE.pwn(2727) : error 017: undefined symbol "sscanf"
C:\Users\carlo\Desktop\CNRv0.3\gamemodes\RaNSEE.pwn(2727) : error 017: undefined symbol "SendClienteMessage"
C:\Users\carlo\Desktop\CNRv0.3\gamemodes\RaNSEE.pwn(2730) : error 001: expected token: "*then", but found ")"
C:\Users\carlo\Desktop\CNRv0.3\gamemodes\RaNSEE.pwn(2730) : error 029: invalid expression, assumed zero
i create a command
Код:
CMD:setswat(playerid,params[])
{
	if(IsPlayerAdmin(playerid))
	{
		new Target, message[128];
		if(sscanf(params, "i",Target)) return SendClienteMessage(playerid, ERROR, "<!> /setswat <id> <!>");
		if (Target == INVALID_PLAYER_ID ) return SendClientMessage( playerid, ERROR, "<!> Player Is Offline <!>" );

		if INI_Open(SaveINI(playerid)))
		{
			INI_WriteInt("Swat", 1);
			INI_Save();
			INI_Close();

			format(message, sizeof (message), "|- You Are Now Allowed  To use SWAT -|");
			SendClientMessage(Target, 0xFFFF00,message);
		}
	}
	return 1;
}
pawn Код:
stock SaveINI(playerid)
{
  new account[64];
  format(account,30,"LuxAdmin/Account/%s",gPlayerName[playerid]);
  return account;
}



Re: help - Kwarde - 10.10.2012

Quote:

SendClienteMessage

Typo. I assume it should be "SendClientMessage"

Quote:

undefined symbol "sscanf"

It seems like you don't have sscanf already.

For the other ones, could you send these lines please?


Re: help - Windrush - 10.10.2012

All Fix but This is Anoyying
i will gonna rep you if you fix this
Код:
if(INI_ReadString, "Swat", SaveINI, 30)
Код:
C:\Users\carlo\Desktop\CNRv0.3\gamemodes\RaNSEE.pwn(400) : error 076: syntax error in the expression, or invalid function call