Zcmd error... -
Код:
CMD:admin(playerid, params[])
{
if(IsPlayerConnected(playerid))
{
new length = strlen(cmdtext);
while ((idx < length) && (cmdtext[idx] <= ' '))
{
idx++;
}
new offset = idx;
new result[256];
while ((idx < length) && ((idx - offset) < (sizeof(result) - 1)))
{
result[idx - offset] = cmdtext[idx];
idx++;
}
result[idx - offset] = EOS;
if(!strlen(result))
{
SendClientMessage(playerid, COLOR_WHITE, "Използвай: (/a)dmin [admin chat]");
return 1;
}
format(string, sizeof(string), "{9AFF00}({FFFFFF}Admin{9AFF00}) {FF0000}%s: {008480}%s", PlayerName(playerid), result);
if (PlayerInfo[playerid][pAdmin] >= 1)
{
SendAdminMessage(COLOR_WHITE, string);
}
}
return 1;
}
Код:
C:\Users\НИКИ\Desktop\gangwars4.pwn(3437) : error 017: undefined symbol "cmdtext"
C:\Users\НИКИ\Desktop\gangwars4.pwn(3438) : error 017: undefined symbol "idx"
C:\Users\НИКИ\Desktop\gangwars4.pwn(3438) : error 029: invalid expression, assumed zero
C:\Users\НИКИ\Desktop\gangwars4.pwn(3438) : error 029: invalid expression, assumed zero
Re : Zcmd error... -