09.02.2013, 16:12
Hello,
I'm getting these errors
this is the command I'm making
I'm getting these errors
Код:
(2439) : error 003: declaration of a local variable must appear in a compound block (2439) : warning 217: loose indentation (2439) : error 017: undefined symbol "string" (2439) : warning 215: expression has no effect (2439) : error 001: expected token: ";", but found "]" (2439) : fatal error 107: too many error messages on one line
pawn Код:
CMD:a(playerid, params[])
{
if(Player[playerid][pAdminLevel] >= 1)
{
if(!isnull(params))
new string[128];//This is the errors line 2439
if(Player[playerid][pAdminLevel] == 1) format(string, sizeof(string), "[Admin Chat] {kleur}Retired Admin{FFFFFF} %s: %s", GetName(playerid, params);
else if(Player[playerid][pAdminLevel] == 2) format(string, sizeof(string), "[Admin Chat] {kleur}Junior Admin{FFFFFF} %s: %s", GetName(playerid, params);
else if(Player[playerid][pAdminLevel] == 3) format(string, sizeof(string), "[Admin Chat] {kleur}General Admin{FFFFFF} %s: %s", GetName(playerid, params);
else if(Player[playerid][pAdminLevel] == 4) format(string, sizeof(string), "[Admin Chat] {kleur}Senior Admin{FFFFFF} %s: %s", GetName(playerid, params);
else if(Player[playerid][pAdminLevel] == 5) format(string, sizeof(string), "[Admin Chat] {kleur}Head Admin{FFFFFF} %s: %s", GetName(playerid, params);
else if(Player[playerid][pAdminLevel] == 6) format(string, sizeof(string), "[Admin Chat] {kleur}Server Owner{FFFFFF} %s: %s", GetName(playerid, params);
return SendClientMessage(playerid, -1, "Syntax: /a(dmin) [text]");
}
SendToAdmins(0xF2FF00FF, string);
}
return 1;
}