[SOLVED] Sscanf Errors ;S Please Help!
#1

Hi,

When I use sscanf I the following errors...
Код:
C:\Users\Alex\Desktop\Mini-Wars\filterscripts\System.pwn(424) : warning 219: local variable "name" shadows a variable at a preceding level
C:\Users\Alex\Desktop\Mini-Wars\filterscripts\System.pwn(428) : error 035: argument type mismatch (argument 2)
C:\Users\Alex\Desktop\Mini-Wars\filterscripts\System.pwn(428) : error 035: argument type mismatch (argument 2)
C:\Users\Alex\Desktop\Mini-Wars\filterscripts\System.pwn(429) : error 035: argument type mismatch (argument 1)
C:\Users\Alex\Desktop\Mini-Wars\filterscripts\System.pwn(424) : warning 204: symbol is assigned a value that is never used: "name"
Pawn compiler 3.2.3664	 	 	Copyright © 1997-2006, ITB CompuPhase
Please help me with this
Thanks.

EDIT:
Here's my code;
Код:
dcmd_kick(playerid, params[])
{
	if(pInfo[playerid][level] >= 1) {
		if(!strlen(params))
		{
			SendClientMessage(playerid, COLOR_LIGHTBLUE, "USAGE: /kick [playerid/name] [reason]");
			return 1;
		}
		new kickid;
		new reason[128];
		new string[128];
		new kickname[48];
		new adminname[48];
		sscanf(params, "uz", kickid, reason);
		GetPlayerName(kickid,kickname,sizeof(kickname));
		GetPlayerName(playerid,adminname,sizeof(adminname));
		
		if(!IsPlayerConnected(kickid) || kickid == INVALID_PLAYER_ID || (pInfo[kickid][level] == 5))
		{
			SendClientMessage(playerid,COLOR_RED,"ERROR: Player is not connected or is the highest admin level");
			return 1;
		}
		
		format(string,256,"KICK: %s has been kicked by %s [reason: %s] ",kickname,adminname,reason);
		SendClientMessageToAll(COLOR_WHITE,string);
	}
	else
	{
 		SendClientMessage(playerid,COLOR_RED,"ERROR: You aren't a Perfect Member / level 1+ admin");
 	}
	return 1;

}
Reply


Messages In This Thread
[SOLVED] Sscanf Errors ;S Please Help! - by Nameless303 - 18.11.2009, 21:57
Re: Sscanf Errors ;S - by bigcomfycouch - 18.11.2009, 23:58
Re: Sscanf Errors ;S - by Nameless303 - 19.11.2009, 19:06
Re: Sscanf Errors ;S - by Nameless303 - 19.11.2009, 20:18
Re: [UNSOLVED] Sscanf Errors ;S Please Help! - by LarzI - 19.11.2009, 20:38
Re: [UNSOLVED] Sscanf Errors ;S Please Help! - by Nameless303 - 19.11.2009, 20:41
Re: [UNSOLVED] Sscanf Errors ;S Please Help! - by LarzI - 19.11.2009, 20:50
Re: [UNSOLVED] Sscanf Errors ;S Please Help! - by Nameless303 - 19.11.2009, 20:54

Forum Jump:


Users browsing this thread: 1 Guest(s)