i dont see whats wrong with this code: - Printable Version
+- SA-MP Forums Archive (
https://sampforum.blast.hk)
+-- Forum: SA-MP Scripting and Plugins (
https://sampforum.blast.hk/forumdisplay.php?fid=8)
+--- Forum: Scripting Help (
https://sampforum.blast.hk/forumdisplay.php?fid=12)
+--- Thread: i dont see whats wrong with this code: (
/showthread.php?tid=287226)
i dont see whats wrong with this code: -
Zonoya - 02.10.2011
simple i dont see the problem here it is:
pawn Код:
dcmd_Admins(playerid, params[])
{
new count = 0;
new string[128];
#pragma unused params
SendClientMessage(playerid, Green, " ");
SendClientMessage(playerid, Green, "___________ |- Current Online Admins -| ___________");
SendClientMessage(playerid, Green, " ");
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))
{
if(pOnDuty[i] == 1)
{
count++
GetPlayerName(i, pOnDuty, sizeof(pOnDuty));
format(string, sizeof(string), "%s [LVL %d]\n", pOnDuty, pInfo[i][AdminLevel]);
SendClientMessage(playerid, Yellow, string);
SendClientMessage(playerid, Green, " ");
SendClientMessage(playerid, Green, "_______________________________________________");
}
}
}
if(count == 0)
{
SendClientMessage(playerid, Yellow,"No Admins online right now buddy.");
SendClientMessage(playerid, Green, " ");
SendClientMessage(playerid, Green, "_____________________________________________");
SendClientMessage(playerid, Green, " ");
}
return 1;
}
the error is here:
pawn Код:
GetPlayerName(i, pOnDuty, sizeof(pOnDuty));
and this is the error
Код:
C:\DOCUME~1\Rhys\Desktop\SA8BEC~1\FILTER~1\Account.pwn(343) : error 001: expected token: ";", but found "-identifier-"
Pawn compiler 3.2.3664 Copyright © 1997-2006, ITB CompuPhase
1 Error.
i just want the line the error is on fixed dont change ANYTHING else please this is the error i have now
Re: i dont see whats wrong with this code: -
Pharrel - 02.10.2011
count++ -> count++;
Re: i dont see whats wrong with this code: -
Zonoya - 02.10.2011
loool didn't see that lol