mIRC Homepage
Posted By: ATMA mass commands - 14/09/03 03:41 AM
umm ok for some reason i just decided to make a script to mass kick bots out of a channel beacuse we constantly get hit with them but the prob is it only kicks 1 bot and thats it O-o idk
Code:
alias mass_kick {
  .set %masskick.count 0
  .set %masskick.total $nick(#,0)
  .set %masskick.me $nick(#, $me) 
  :loop
  if (%masskick.count >= %masskick.total) { goto end }
  k $snick(#,$snick(#,%masskick.count)) Mass Kick
  inc %masskick.count 1
  goto loop
  :end
}
menu nicklist {
  mass kick: { mass_kick }
}
Posted By: LocutusofBorg Re: mass commands - 14/09/03 07:15 AM
We do not help with channel take-over scripts. Your code intends to kick everyone out, not just the bots. You can stop a botflood with a simple join-flood code that sets a mode +i on a channel.
Posted By: r0ck0 Re: mass commands - 14/09/03 02:43 PM
Code:
alias mass_kick {
  var %i = 1
  while ($nick(#,%i) != $null) {
    if (($nick(#,%i) == $me) || ($nick(#,%i) == %lastnick)) inc %i
    else {
      [color:green]ban -u10 # $+($nick(#,%i),!*@*)[/color]
      kick # $nick(#,%i) Mass Kick
      var %lastnick = $nick(#,%i)
    }
  }
}
menu nicklist,channel {
  Mass Kick:mass_kick
}


Edit: Ok I'll add this ...
ATMA, please don't use this for taking over channels.
Posted By: andymps Re: mass commands - 14/09/03 03:13 PM
locutusofborg said:

We do not help with channel take-over scripts. Your code intends to kick everyone out, not just the bots. You can stop a botflood with a simple join-flood code that sets a mode +i on a channel.
Posted By: r0ck0 Re: mass commands - 14/09/03 03:15 PM
only thing I have to say about that is ...
locutusofborg shouldn't use the word we in a denial of help statement.
Posted By: andymps Re: mass commands - 14/09/03 03:17 PM
well who would want to help a channel take over script?
i know i wouldnt
Posted By: r0ck0 Re: mass commands - 14/09/03 03:18 PM
well I just did [/high & mightiness]
Posted By: pheonix Re: mass commands - 14/09/03 03:19 PM
1 problem:
a mass kick can be used as a channel takeover, doesnt mean it is going to be for that....
Posted By: r0ck0 Re: mass commands - 14/09/03 03:21 PM
tyvm pheonix .. exactly
go add a comment here too will ya? thx smile
Posted By: andymps Re: mass commands - 14/09/03 03:21 PM
well im sure that alot of people agree with me about mass kick scripts
EDIT*
even what apears to be a harmless enough mass voice script can be turned into a mass deop
Posted By: pheonix Re: mass commands - 14/09/03 03:30 PM
maybe he wants the mass kick simply because he doesnt want his room any more, maybe he wants it for the reason he said, maybe he wants it for channel takeovers, whatever the reason, you cant control him nor know what he needs it for..
Posted By: KingTomato Re: mass commands - 14/09/03 03:31 PM
To take it a step further, here you go...

Code:
; mode changes

; Usage: /massmode <chan> <mode>
; Example: /massmode #mychannel +o
/massmode {
  var %chan = $$1, %nick = 1, %nicks
  while ($nick(%chan, %nick)) {
    var %nicks = $addtok(%nicks, $ifmatch, 32)
    if ($numtok(%nicks, 32) == $modespl) || (%nick == $nick(%chan, 0)) {
      /mode %chan $+($left($$2, 1),$str($right($$2, 1),$modespl)) %nicks
      /unset %nicks
    }
    /inc %nick
  }
}


Personally, if you dont like the idea of a take over (in all the seriousness you bing to it), try setting chanserv protections. ChanServ can limit modes like +b, where noone can eb banned. Also, you have user levels, use them. Set those who regular ur channel to protected. If your netowrk doesnt have services, write a script..

Code:
on !@*:BAN:#: {
  /inc -u3 % [ $+ [ $chan ] $+ ] . [ $+ [ $nick ] ]
  if (% [ $+ [ $chan ] $+ ] . [ $+ [ $nick ] ] > 4) /kick $chan $nick Takeover Detected
}

on !@*:KICK:#: {
  /inc -u3 % [ $+ [ $chan ] $+ ] . [ $+ [ $nick ] ]
  if (% [ $+ [ $chan ] $+ ] . [ $+ [ $nick ] ] > 4) /kick $chan $nick Takeover Detected
}


There, that allows only 4 mode changes per three seconds (including kicks). If they do more, they get the golden boot award... It simple people
Posted By: andymps Re: mass commands - 14/09/03 03:32 PM
well thats why u dont help mass anything scripts
Posted By: r0ck0 Re: mass commands - 14/09/03 03:32 PM
smile
Posted By: pheonix Re: mass commands - 14/09/03 03:32 PM
i can help with whatever i want..
if you dont help him he's only going to get it elsewhere, so ya might as well save him the trouble;\
Posted By: ATMA Re: mass commands - 14/09/03 03:34 PM
its not a channel take over script -_- my server gets smashed by bots and stuff so me and my friend were trying to find a way to remove them quickly
Posted By: Watchdog Re: mass commands - 14/09/03 04:11 PM
All discussion about a war script aside for a sec...

Keep in mind that you can only kick a certain number of bots or people before you, yourself, get killed for flooding the server. Since bot attacks are unwelcome on just about every network maybe this is something you should discuss with an oper. Unless you are able to provide this bot of yours with an o:line (provides immunity against being flooded off) then it simply will not go the distance against a big attack, regardless of whether you use mIRC, an eggdrop or whatever.
Posted By: LocutusofBorg Re: mass commands - 14/09/03 05:17 PM
I wouldn't have to if people would stop helping with lame take-over scripts. IRC is a place to have fun, not a place to annoy the hell out of someone and forcibly take what is not yours. I for one keep that in mind when I help people. I do not provide them with answers to code that can be used or mostly will be used in harmful ways, either to themselves, other users or a IRC network. I was hoping the serious IRC lovers would agree with me there. Guess some people just enjoy harassing others and helping people to harass others.

That said: mass commands generally serve no other purpose than to wreak havoc in a channel (just like "revenge" scripts, which 95% of the IRC population apparantly mistakes for "protection" scripts). His problem was with floodbots. That problem does NOT require you to kick all the users from the channel. Just the bots. You can simply set a +i on the channel to stop the flood.
Posted By: pheonix Re: mass commands - 14/09/03 05:26 PM
maybe he doesnt want +i on :tongue:, if you meant only set +i when the bots flood-join, then maybe they dont flood-join and only join every so often, until there are loads and then the flooding starts.
Posted By: r0ck0 Re: mass commands - 14/09/03 05:36 PM
I don't care to question why .. he needed help and I helped .. end of story.
Posted By: KoRn18 Re: mass commands - 14/09/03 06:12 PM
i can back ATMA up on that.. i have join his server a couple times, and i see how bad these bots are
Posted By: LocutusofBorg Re: mass commands - 14/09/03 06:37 PM
A good script can detect such. Also - your arguments hold no ground. If he detects the bots to start the masskick, he also detects them to set the +i. All that I suggest he change is the action he takes.
Posted By: LocutusofBorg Re: mass commands - 14/09/03 06:38 PM
Well, then you are the kind of people who make IRC not fun for a lot of newbies. As they say, if you're not part of the solution, you're part of the problem...
Posted By: LocutusofBorg Re: mass commands - 14/09/03 06:39 PM
That doesn't change the point of my reasoning. There is no need to kick ALL the users out of a channel. That will just scare away your userbase.
Posted By: KoRn18 Re: mass commands - 14/09/03 06:50 PM
he is only kicking $snick's, not everyone, you should check over the script before running ur yapp. :tongue:
Posted By: ATMA Re: mass commands - 14/09/03 07:06 PM
yes indeed you should look at the code more closely next time k? :tongue:
Posted By: LocutusofBorg Re: mass commands - 14/09/03 07:23 PM
First, it doesn't change anything I said. In fact, if you wanna go down that path -- it makes it worse and supports my path even more. How much time do you think he's gonna need to manually select all the botnicks? Halfway decent spambot floods these days are bots joining and parting like crazy, maybe throwing in one or two lines of text between. Before you select the second nick, the first will be gone already. Manually selecting botnicks in a botflood is completely and totally pointless. Infact anything manual is completely and totally pointless against a flood. If you want to protect a channel, you MUST automate it.....
Posted By: pheonix Re: mass commands - 14/09/03 07:26 PM
i never have trouble with that because i normally stick to small networks, other than dalnet every so often, but i would say a mass kick is far better than any kind of flood prot anyway;\
Posted By: LocutusofBorg Re: mass commands - 14/09/03 07:37 PM
Masking the symptoms is NEVER better than solving the problem. You can keep kicking out the floodbots till hell freezes over, unless you do something to prevent them from joining back, and prevent others from joining as well, the flood is gonna keep going. Setting a temporary +i is the only way to stop them from rejoining (bans don't cut it, especially on networks where you can connect through proxies).

PS: "only way" is relative, on DALnet you can use +R to prevent floodbots from joining too.

PPS: don't take that "till hell freezes over" too literally -- it already did a few years ago.
Posted By: neophyte Re: mass commands - 15/09/03 02:04 AM
Perhaps you might be wiser off letting the rest of this community decide whether we want to help this person or not.

If you think the question asked has the potential to be used in a malicious manner, don't respond.
On the other hand, if you really have the need to say something, by all means, go ahead, but please don't bring the greater community into the battle, because we can make our own decisions.


Personally, I have a command similar to this, however, I've hardly used it. In fact, I'm thinking of re-coding it so it will only allow three or four events/mode changes to happen at once.

As for bans, I suggest using $modespl to return how many modes can be changed at once on your server, and modifying the script to suit.
Posted By: LocutusofBorg Re: mass commands - 15/09/03 05:12 AM
Whether or not we should help here isn't the point I am trying to make. The point I am trying to make is that the code is useless when a half decent botflood shows up...

And excuse me for trying to do my part in making IRC a better place
Posted By: pheonix Re: mass commands - 15/09/03 06:17 AM
Quote:
And excuse me for trying to do my part in making IRC a better place

not everyone wants the same as you.....
Posted By: sparta Re: mass commands - 15/09/03 06:37 AM
I using my mass kick to fast secure a channel (clear it out) if its being a TO atemt.. if somone get server ops and start to mass kick the ops, then i dont just want the channel to be set +i, that means that my ops cant join it without a invite, so a mass kick can be good for many reasons. but if its made to do a TO with, then its not that good, but as allways it depends on the person that using it, if you got a gun that dont mean you shot somone, but then again you have ppl that doing just that.. so a mass kick on its own arent so bad, it all depends on who using it and for what reason smile
Posted By: pheonix Re: mass commands - 15/09/03 06:41 AM
Quote:
if you got a gun that dont mean you shot somone

exactly shocked
Posted By: LocutusofBorg Re: mass commands - 15/09/03 09:42 AM
Apparantly there are some people who want to do nothing but harass others/annoy others.

I said "a better place"

A better place is a place where every user can chat freely without being harassed by spammers, without being insulted by idiots, without being banned from their own channel by people who use warscripts. That is what "good" and "safe" and "normal" IRC is, regardless of whether you want it to be such.
Posted By: LocutusofBorg Re: mass commands - 15/09/03 09:43 AM
In that case, why not simply deop everyone and set +i. You can then reop the real ops and kick the lamers.
Posted By: ATMA Re: mass commands - 15/09/03 12:04 PM
Quote:

Apparantly there are some people who want to do nothing but harass others/annoy others.


did i ever say i was going to harass ppl with this script no i didnt i am a owner of a server and i know what to do when to do it so just stfu ppl are getting sick of you [censored] saying [censored] like this it just floods the message boards k thx
Posted By: r0ck0 Re: mass commands - 15/09/03 12:39 PM
You're saying I'm part of the problem because I choose to help people without the preaching ?
Posted By: sparta Re: mass commands - 15/09/03 01:06 PM
You shouldent say to somone here that just says what he/she thinks to "stfu", they are here to help ppl, and if they feel its wrong to help with serten things, then thats ok too, and LocutusofBorg do say much good in this forum, so i dont see any reason to be rude? that will only make it harder for you to get help with som other problem you maybe will have, no one here wants to help somone that are rude.. smile
Posted By: KingTomato Re: mass commands - 15/09/03 02:43 PM
Quote:

A better place is a place where every user can chat freely without being harassed by spammers, without being insulted by idiots, without being banned from their own channel by people who use warscripts. That is what "good" and "safe" and "normal" IRC is, regardless of whether you want it to be such.


I used to own a channel with a 100 ppl on avaerage there, and I never was taken over.. i'm sorry, but if a person's channel gets taken over that they own, its their own fault. If you couldnt do something as simple as /chanserv identify <chan> <pass> or /chanserv access <chan> add <name> <protected_level>, then you need to learn from your mistakes. Even just mkaing a 1 line script

on 1:JOIN:#channel_i_own: /chanserv identify <chan> <pass>

thats like having a car, leaving the key in the ignition, and being a distance away. Its your fault u didnt take the initiative to secure your car. Now dont get me wrong, the one who stole the car is still at fault, but your the one that basically handed it over.
Posted By: _D3m0n_ Re: mass commands - 15/09/03 04:21 PM
it is beyond me why ANY server owner would ever need a mass kick script in thier IRC ......that being said ... if the channel is yours and your the server netadmin ..... no one can touch you and your room...... so why would there ever be a need to have such a script?
Posted By: sparta Re: mass commands - 15/09/03 05:26 PM
if you arent a owner of the server then? smile hard to do a /kill if u dont have that status. wink
Posted By: _D3m0n_ Re: mass commands - 15/09/03 05:35 PM
what relevance does /kill have to a mass kick script? please tell me where they are the same thing?..... any ircop can /kill ..... doesnt even have to be a server owner. if u dont know that much then u really shouldnt own a server
Posted By: r0ck0 Re: mass commands - 15/09/03 05:35 PM
he said he was a server owner .. not the server owner.
Posted By: _D3m0n_ Re: mass commands - 15/09/03 05:39 PM
ok a server owner and an ircop are two entirely different things, if hes not able to distinguish that then he really doesnt need to be either of the two.
Posted By: r0ck0 Re: mass commands - 15/09/03 05:44 PM
No .. what I mean is, he never said he was oper on the server in question .. he only stated he was a server owner.

Even though it really isn't that hard of a job, some opers/admins for some reason just do not like to do what they're supposed to in those situations. I don't know why, but it seems like they just don't want to be bothered with it .. sad but true. I'm not saying this is the case in his situation because maybe it isn't, but it seems like most opers just want the social status of being an oper while not really wanting to do the job or don't know how.
Posted By: _D3m0n_ Re: mass commands - 15/09/03 06:36 PM
well if he mentioned the /kill command it would be a safe bet he is infact an oper on his server that he owns... therefore everything u just took the time to post was nonsensical, furthermore what does any of this has to do with a mass kick command? why would he waste the time to tell us about /kill? basically my point is there is no such need for a server op on any network to ever have a mass script to kick anyone as even if thier room was taken over ... it would be short lived .. and in most cases the offenders would be also removed from the network....... never needing to ever utilize a mass kick. and anyone with any sense would have to agree with my point. I ran a small network with 3 links to it and if i ever caught any oper using a war script that oper was infact dismissed... it is unprofessional to have anyone like that representing a network.
Posted By: r0ck0 Re: mass commands - 15/09/03 06:41 PM
Maybe the server he owns isn't on the network where he is having the problems. Maybe it is. I don't know why he mentioned that he owns a server. But you're right, I am a server owner on a small network and I wouldn't want any opers that use war scripts either .. been there. Have seen too many opers that will use /kill at the drop of a hat but seem to disappear when it comes to actually solving a problem such as floodbots and such.
Posted By: ATMA Re: mass commands - 15/09/03 07:29 PM
Quote:

I used to own a channel with a 100 ppl on avaerage there, and I never was taken over.. i'm sorry, but if a person's channel gets taken over that they own, its their own fault.

ehh well one thing is my friends server well we get into alot of fights with the japs so we are constantly nulling each other and attacking ones servers =/
Posted By: r0ck0 Re: mass commands - 15/09/03 07:34 PM
lol @ japs
* RoCk no longer wonders why your channel gets so many floodbot attacks
Posted By: _D3m0n_ Re: mass commands - 15/09/03 11:08 PM
hey heres a suggestion ..... stop pissin in ppls cheerios and ud not have a need for it
Posted By: Akill Re: mass commands - 26/06/04 12:20 PM
well it looks like i better help this dude out since you all are paranoid about him taking over channels.
good mass kicker:

alias mk {
var %num.nick 0
var %user.tot $nick(#,0)
:start
inc %num.nick
if (%num.nick > %user.tot) { halt }
if ($nick(#,%num.nick) == $me) { goto start }
else { kick # $nick(#,%num.nick) mass kick | goto start }
}

have fun!
Posted By: Watchdog Re: mass commands - 26/06/04 12:23 PM
Masskicking isn't really good at all. Unless you have an o:line you are subject to being disconnected by the server if you flood it with commands and even then I believe that not all IRCds support that immunity. Your code is only useful to IRC war kiddies. At any rate people stopped posting here around 9 months ago.
Posted By: Akill Re: mass commands - 26/06/04 12:25 PM
also,
locutusofBorg: ATMA asked for a hand with his script, not a 10 post speach about how you dont like mass kicking.
Posted By: Watchdog Re: mass commands - 26/06/04 12:26 PM
It's not a question of whether someone happens to like it or not. It's stupid.
Posted By: Akill Re: mass commands - 26/06/04 12:29 PM
9 months ago?!?! ...why do i even bother :tongue:
© mIRC Discussion Forums