/ban /kick /teletransport
#1

I'm noob at this... well... here's my question...

I'm doing a server, and i need /kick /ban cmds, so I searched in wikisamp and I found that

Quote:
Originally Posted by WIKISAMP
public OnPlayerCommandText( playerid, cmdtext[] )
{
if( strcmp( cmdtext, "/banme", true ) == 0 )
{
// Ban the player who offers this command.
Ban( playerid );
return 1;
}
}
but it bans myself.... What can I do??

thx for your attention,
McDonald
Reply
#2

Quote:
Originally Posted by McDonald
I'm noob at this... well... here's my question...

I'm doing a server, and i need /kick /ban cmds, so I searched in wikisamp and I found that

Quote:
Originally Posted by WIKISAMP
public OnPlayerCommandText( playerid, cmdtext[] )
{
if( strcmp( cmdtext, "/banme", true ) == 0 )
{
// Ban the player who offers this command.
Ban( playerid );
return 1;
}
}
but it bans myself.... What can I do??

thx for your attention,
McDonald
Lol, it looks like you want to ban your self /banME
Reply
#3

Quote:
Originally Posted by MrLennart`
Quote:
Originally Posted by McDonald
I'm noob at this... well... here's my question...

I'm doing a server, and i need /kick /ban cmds, so I searched in wikisamp and I found that

Quote:
Originally Posted by WIKISAMP
public OnPlayerCommandText( playerid, cmdtext[] )
{
if( strcmp( cmdtext, "/banme", true ) == 0 )
{
// Ban the player who offers this command.
Ban( playerid );
return 1;
}
}
but it bans myself.... What can I do??

thx for your attention,
McDonald
Lol, it looks like you want to ban your self /banME
SPAM!
@ McDonald i want a Double hamburger (Joke).: Try to find Adnre's Admi filterscript it has the commands /kick and /ban
Nice! ya,
Reply
#4

lol, it was on wiki samp!!!

Lol, i tried to search, nbut i couldn't find anything ...
Reply
#5

Quote:
Originally Posted by ♫ -Źḥ€яʘ- ♫
Quote:
Originally Posted by MrLennart`
Quote:
Originally Posted by McDonald
I'm noob at this... well... here's my question...

I'm doing a server, and i need /kick /ban cmds, so I searched in wikisamp and I found that

Quote:
Originally Posted by WIKISAMP
public OnPlayerCommandText( playerid, cmdtext[] )
{
if( strcmp( cmdtext, "/banme", true ) == 0 )
{
// Ban the player who offers this command.
Ban( playerid );
return 1;
}
}
but it bans myself.... What can I do??

thx for your attention,
McDonald
Lol, it looks like you want to ban your self /banME
SPAM!
@ McDonald i want a Double hamburger (Joke).: Try to find Adnre's Admi filterscript it has the commands /kick and /ban
Nice! ya,
LOL its Andre's Admin
Reply
#6

/banme would seem that its bans themself but here is answer to your problem.

hope this helps

Код:
public OnPlayerCommandText(playerid, cmdtext[])
{
  new giveplayerid;

  if( strcmp( cmdtext, "/ban", true ) == 0 )
  {
   Ban(giveplayerid);
   return 1;
   }
   return 0;
}
Reply
#7

this bans id 0
Reply
#8

i would like a coke...a big mac...some fries...and some fukin soda! ... hmm ..look for otherz admins FS... is easier :P
Reply
#9

Quote:
Originally Posted by viper_viper
/banme would seem that its bans themself but here is answer to your problem.

hope this helps

Код:
public OnPlayerCommandText(playerid, cmdtext[])
{
  new giveplayerid;

  if( strcmp( cmdtext, "/ban", true ) == 0 )
  {
   Ban(giveplayerid);
   return 1;
   }
   return 0;
}
lol....

http://pastebin.com/m27605517

This should work. It's kind of big only because it requires strtok and IsNumeric but if you already have those then you can cut most of this out.
Reply
#10

Or just make it using dcmd, much smaller, and faster (check the wiki for more information)...

http://pawn.pastebin.com/m2489de63
Reply


Forum Jump:


Users browsing this thread: 1 Guest(s)