[QUESTION] Checking for if someone is offline
#1

I'm trying to finish my Anticheat and i am making it so when there is no admins online, instead of warning the admins it will Kick the player; is there any way to detect if there aren't admins online?


Very Thankfully and sorry for wasting your time
Reply
#2

pawn Код:
new adminson = 0;
for(new i = 0; i < MAX_PLAYERS; i ++ ) {
  if(IsPlayerConnected(i)) {
    if(IsPlayerAdmin(i)) {
      adminson ++;
    }
  }
}
if(adminson == 0 ) {
  print("Your code here if there's no admins on");
}
Reply
#3

Very Thankfully

_________________________________________________


i only used the variables thingy, not the loop thru the players, Thank you; it works perfectly

(6/4/2010)[22:56:21] Anticheat Has Kicked CuervO for: Weapon Hacking [Chainsaw]
(6/4/2010)[23:1:56] Anticheat Has Kicked CuervO for: Weapon Hacking [Chainsaw]
(6/4/2010)[23:7:27] Anticheat Has Kicked CuervO for: Weapon Hacking [Chainsaw]
(6/4/2010)[23:12:14] Anticheat Has Kicked CuervO for: Weapon Hacking [Minigun]

That was when i wasn't an admin, so no admins online were atm
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)