warning 202: number of arguments does not match definition
#1

Код:
			{
  					AdministratorMessage(COLOR_YELLOW, string);
			}
Some reason it gives me a warning, Anyone can help me?
Reply
#2

Is it defined?
Is it a valid code,
Please provide a error or bit more code
Reply
#3

Код:
	if(strcmp(cmd, "/admin", true) == 0 || strcmp(cmd, "/a", true) == 0)
	{
	  if(IsPlayerConnected(playerid))
	  {
	    new sendername[MAX_PLAYER_NAME];
			GetPlayerName(playerid, sendername, sizeof(sendername));
			new length = strlen(cmdtext);
			while ((idx < length) && (cmdtext[idx] <= ' '))
			{
				idx++;
			}
			new offset = idx;
			new result[64];
			while ((idx < length) && ((idx - offset) < (sizeof(result) - 1)))
			{
				result[idx - offset] = cmdtext[idx];
				idx++;
			}
			result[idx - offset] = EOS;
			if(!strlen(result))
			{
				SendClientMessage(playerid, COLOR_GREY, "[USAGE] (/a)dmin [admin chat]");
				return 1;
			}

			new arank[64];
			if(PlayerInfo[playerid][pAdmin] == 1) { arank = "Trial Admin"; }
			else if(PlayerInfo[playerid][pAdmin] == 2) { arank = "RP Admin"; }
			else if(PlayerInfo[playerid][pAdmin] == 3) { arank = "Game Admin"; }
			else if(PlayerInfo[playerid][pAdmin] == 19) { arank = "Lead Admin"; }
			else if(PlayerInfo[playerid][pAdmin] == 20) { arank = "Community Owner"; }
			else if(PlayerInfo[playerid][pAdmin] == 1337) { arank = "Hidden Lead Admin"; }
			else if(PlayerInfo[playerid][pAdmin] == 1338) { arank = "Community Owner"; }
			else { arank = "Unknown Admin Rank"; }

			format(string, sizeof(string), "*%s %s: %s", arank, sendername, result);
			if (PlayerInfo[playerid][pAdmin] >= 1)
			{
  					AdministratorMessage(COLOR_YELLOW, string);  // Error line
			}
			printf("Admin %s: %s", sendername, result);
		}
		return 1;
	}
This is the whole command.
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)