Kick everyone besides people with a certain name?
#5

Quote:
Originally Posted by Ronyx69
Код:
public OnPlayerConnect(playerid)
  {
  new nick[MAX_PLAYER_NAME];
  GetPlayerName(playerid, nick, sizeof(nick));
  if(strfind(nick,"[B]Vortex",true)==-1&&strfind(nick,"Lazlow",true)==-1&&strfind(nick,"AjayRz",true)==-1&&strfind(nick,"TehFedra",true)==-1&&strfind(nick,"Arsham_Vafa",true)==-1)
    {
    SendClientMessage(playerid,COLOR_RED,"You are not a BETA Tester, banned.");
    BanEx(playerid,"BETA Testing.");
    return 1;
    }
  else
    {
    SendClientMessage(playerid,COLOR_RED,"You are recognized as a BETA Tester, welcome");
    }
  return 1;
  }
this would only "work" if the playerid was called ALL the names O_O
tho this bans the names XD

pawn Код:
public OnPlayerConnect(playerid)
  {
  new nick[MAX_PLAYER_NAME];
  GetPlayerName(playerid, nick, sizeof(nick));
  if(strcmp(nick, "TehFedra", true) == 0 || strcmp(nick, "[B]Vortex", true) == 0 || strcmp(nick, "Lazlow", true) == 0 || strcmp(nick, "AjayRz", true) == 0 || strcmp(nick, "Arsham_Vafa", true) == 0)
    {
    SendClientMessage(playerid,COLOR_RED,"You are recognized as a BETA Tester, welcome");
    return 1;
    }
  else
  SendClientMessage(playerid,COLOR_RED,"You are not a BETA Tester, banned.");
  BanEx(playerid,"BETA Testing.");
  return 1;
  }
thisone should work^^
Reply


Messages In This Thread

Forum Jump:


Users browsing this thread: 1 Guest(s)