Kick clan tag
#1

Hi i searched but didnt found someting like this.When a [BLABLA]name enters the respective server he gets kicked and the same for all [BLABLA] clan members. is this posible? Thanks

//Rikker
Reply
#2

Use the GetPlayerTag function.
Reply
#3

Ok i will try thanks but it works only for the clans tag not for the clans tag + player name?
Reply
#4

Only for the tags, but you can get the player's name and check it with strcmp.
Reply
#5

It works thanks Andre9977 and GtakriZ
Reply
#6

Yeah Andre.. No problem!
Reply
#7

ok im in lol
how do i add more?
do i do this?

new pName[MAX_PLAYER_NAME];
GetPlayerName(playerid, pName, sizeof(pName));
if(strfind(pName, "[POOP],[PSW]", true) == 0)
{
Ban(playerid);
}

i dont think thats right lol
Reply
#8

thats sexy lol
thanks
i got a list of know hacker clans and IP so this would be useful thx
Reply
#9

Remember that strfind returns the location of the found substring, so using '== 0' may not be the best option.
pawn Код:
if(strfind(pName, "[CUEBALL]", true) != -1)
  return Ban(playerid);
That will ban the player if they have the [CUEBALL] tag anywhere in their name. Andre's method will only work if it is at the start of his name.

~Cueball~
Reply
#10

Can U list the clans?
Reply
#11

Quote:
Originally Posted by [AU
GtakriZ ]
Use the GetPlayerTag function.
a scripter,.. From AU? WOW ! Im Kabuto in the AU Server But , About The Register System in AU what does it use? dini? or sscanf? How Ever, There Is no GetPlayerTag
o.o
Reply
#12

Quote:
Originally Posted by Andre9977
You could do:
pawn Код:
new BANTags[] =
{
  "[POOP]",
  "[Rstar]",
  "[ROOK]"
};

// ...
for(new a = 0; a < sizeof(BANTags); a++)
{
  if(strfind(pName, a, true) == 0)
  {
    // ...
  }
}
Or
pawn Код:
new pName[MAX_PLAYER_NAME];
GetPlayerName(playerid, pName, sizeof(pName));
if(strfind(pName, "[POOP]", true) == 0 || strfind(pName, "[PSF]", true) == 0)
{
  Ban(playerid);
}
well it is possible i think this:

pawn Код:
if(strfind(pName, "[HAXER]", true) == 0
{
  Ban(playerid);
}
if(strfind(pName, "[IDIOT]", true) == 0
{
  Ban(playerid);
}
Or ?
Reply
#13

a cheaper way could be if you use XtremeAdmin2, there is an auto kick function witch act a little like a funnier ban for anyone who has a part of his name in the list
Reply
#14

Quote:
Originally Posted by [KMA
Lord_Deji ]
a cheaper way could be if you use XtremeAdmin2, there is an auto kick function witch act a little like a funnier ban for anyone who has a part of his name in the list
Nah, i dont like that admin script
Reply
#15

if(strfind(pName, "[HAXER]", true) == 0 )
{
Ban(playerid);
}
if(strfind(pName, "[IDIOT]", true) == 0 )
{
Ban(playerid);
}



xD
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)