08.02.2015, 06:58
You haven't added anything to detect if there's no admins online, you just detect if there's a player with a level of 0 it seems.
Add a variable that increases for each admin that's online, then check if that counter equals 0, and display the message.
If you do not know what indentation is, look here: https://sampforum.blast.hk/showthread.php?tid=256961
Add a variable that increases for each admin that's online, then check if that counter equals 0, and display the message.
pawn Код:
new online;
for(new i = 0; i < MAX_PLAYERS; i++)
{
if(IsPlayerConnected(i) && PlayerInfo[i][Level] > 0)
{
online++;
if(online == 0) format(string,sizeof(string), "No admin online in the list");