26.09.2011, 13:05
If you can't see what is wrong, then I seriously doubt me debugging your script is going to help you
basically, the logic, indentation, and number of braces in this piece of code is completely wrong.
good luck
pawn Код:
if (strcmp(cmdtext, "/events", true) == 0)
{
if(IsPlayerConnected(playerid))
{
SendClientMessage(playerid, COLOR_GREEN, "Events admins Online:");
new
count,
string[64]
;
for(new i; i < MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i))
{
if(PlayerInfo[i][pEventadmin] >= 1
{
GetPlayerName(i, string, sizeof(string));
format( string , sizeof(string) , "(%d) %s" , i , string );
SendClientMessage(playerid, COLOR_GREEN, string);
count++;
}
}
}
if( !count )
{
SendClientMessage(playerid, COLOR_YELLOW, "*** Server Info *** : No events admins ONLINE");
} else {
SendClientMessage(playerid, COLOR_GREEN, "______________");
}
}
return 1;
}
good luck