warning by sscanf
#1

sscanf warning: Strings without a length are deprecated, please add a destination size.

Even tho i have set the string size..
Also my messages wont show up if there longer then lets say 20 characters, i cant type a full sentence i have to split it up.
the code is shown below, i have set the lenghts right?

Код:
CMD:a(playerid,params[])
{
	new aText[128],aName[MAX_PLAYER_NAME],string[128];
	if(sscanf(params,"s",aText)) return SendClientMessage(playerid,COLOR_WHITE,"{ff387a}[Syntax]:{ffffff} ''/a [text]''.");
	if(pData[playerid][Admin] == 0) return SendClientMessage(playerid,COLOR_WHITE,"{ff0000}[Error]:{ffffff} You are not an Administrator with the required level.");
	GetPlayerName(playerid,aName,sizeof(aName));
	format(string,sizeof(string),"{ff387a}[Admin] {ffffff}%s: %s",aName,aText);
	SendClientMessageToAdmins(COLOR_WHITE,string);
	return 1;
}
Reply


Messages In This Thread
warning by sscanf - by yvoms - 01.12.2015, 14:33
Re: warning by sscanf - by AbyssMorgan - 01.12.2015, 14:45
Re: warning by sscanf - by yvoms - 01.12.2015, 14:51
Re: warning by sscanf - by DRIFT_HUNTER - 01.12.2015, 15:04
Re: warning by sscanf - by yvoms - 01.12.2015, 15:10
Re: warning by sscanf - by Jefff - 01.12.2015, 15:20

Forum Jump:


Users browsing this thread: 1 Guest(s)