• Welcome to Valhalla Legends Archive.
 

Creating a Spam Ban Function

Started by CrAz3D, May 24, 2003, 03:44 PM

Previous topic - Next topic

CrAz3D

Couldn't find ne thing in search so I started this.
I was wondering how I'd go about making a SpamBan option.  I was thinkin' somewhere along the lines as a Rejoin Ban, but that is not exactly what is happening.

Maybe This?

Quote
spam as Long
spam = spam +1
User_Talk
ChannelList.FindItem(strUser).text
   ChannelList.FindItem (strUser).ListSubitems.add Spam




TmrSpam_()
Interval = 5000
if ChannelList.FindItem(strUser), Spam > 5 then
     Send "/ban " & strUser & " Spamming"
end if
This look close?
rebundance - having or being in excess of sheer stupidity
(ré-bun-dance)
Quote from: Spht on June 22, 2004, 07:32 PMSlap.
Quote from: Adron on January 28, 2005, 09:17 AMIn a way, I believe that religion is inherently evil, which includes Christianity. I'd also say Christianity is eviller than Buddhism (has more potential for evil).
Quote from: iago on April 19, 2005, 01:06 PM
CrAz3D's ... is too big vertically, at least, too big with ... iago ...

Mesiah / haiseM

wont work, but if you made the interval on the timer smaller, and if the Spam number is under 5, then set the subitem to 0, this will be like resetting it.
]HighBrow Innovations
Coming soon...

AIM Online Status: 

CrAz3D

#2
I am able to add the person's name to a ListView but I am not able to their Spam count...
like
RoomList.ListItems.add,,Username
roomlist.listitems.add,,Spamb

Might anyone be able to help with this?
rebundance - having or being in excess of sheer stupidity
(ré-bun-dance)
Quote from: Spht on June 22, 2004, 07:32 PMSlap.
Quote from: Adron on January 28, 2005, 09:17 AMIn a way, I believe that religion is inherently evil, which includes Christianity. I'd also say Christianity is eviller than Buddhism (has more potential for evil).
Quote from: iago on April 19, 2005, 01:06 PM
CrAz3D's ... is too big vertically, at least, too big with ... iago ...

CrAz3D

I got lost in my own thoughts, can anyone help me get through this?
rebundance - having or being in excess of sheer stupidity
(ré-bun-dance)
Quote from: Spht on June 22, 2004, 07:32 PMSlap.
Quote from: Adron on January 28, 2005, 09:17 AMIn a way, I believe that religion is inherently evil, which includes Christianity. I'd also say Christianity is eviller than Buddhism (has more potential for evil).
Quote from: iago on April 19, 2005, 01:06 PM
CrAz3D's ... is too big vertically, at least, too big with ... iago ...

Kp

Quote from: CrAz3D on May 27, 2003, 02:40 PM
I got lost in my own thoughts, can anyone help me get through this?
I typically implement spamban to be event-driven.  If the user speaking is the same one who just spoke, increment the spam counter.  Otherwise, clear the counter and store the name of the speaking user.  If the counter ever exceeds some threshold, ban the speaking user.  Note that this requires that the spammer be the only one speaking -- but if that wasn't the case, how does the bot know he's spamming? :)
[19:20:23] (BotNet) <[vL]Kp> Any idiot can make a bot with CSB, and many do!

tA-Kane

#5
Quote from: Kp on May 27, 2003, 02:51 PMhow does the bot know he's spamming?
By the user saying the same thing twice.

Or, by the user coming into the channel, saying something, and leaving before a set time has expired (eg, join, spam, leave in 5-10 seconds). This could be argued as fast leave ban, though.
Quote
Macintosh programmer and enthusiast.
Battle.net Bot Programming: http://www.bash.org/?240059
I can write programs. Can you right them?

http://www.clan-mac.com
http://www.eve-online.com

CrAz3D

so maybe put strText = to the strSpam & then if the second strText = strSpam ban their hind end?...is that what ur saying?...sounds good to me.

What bout diff msg spams?
"Clan aSUFhsd"
"Join clan aSUFhsd"
something like that?
rebundance - having or being in excess of sheer stupidity
(ré-bun-dance)
Quote from: Spht on June 22, 2004, 07:32 PMSlap.
Quote from: Adron on January 28, 2005, 09:17 AMIn a way, I believe that religion is inherently evil, which includes Christianity. I'd also say Christianity is eviller than Buddhism (has more potential for evil).
Quote from: iago on April 19, 2005, 01:06 PM
CrAz3D's ... is too big vertically, at least, too big with ... iago ...

______

I would suggest not to look at messages as much , but look at how many times a user has talked and the rate. if it exceeds your rate check if they safelisted else ban them.

CrAz3D

that's wat I was thinkin' but I'm wondering how I should make the bot look at it.  A listview? an Integer?
rebundance - having or being in excess of sheer stupidity
(ré-bun-dance)
Quote from: Spht on June 22, 2004, 07:32 PMSlap.
Quote from: Adron on January 28, 2005, 09:17 AMIn a way, I believe that religion is inherently evil, which includes Christianity. I'd also say Christianity is eviller than Buddhism (has more potential for evil).
Quote from: iago on April 19, 2005, 01:06 PM
CrAz3D's ... is too big vertically, at least, too big with ... iago ...

Soul Taker

#9
I use a two-dimensional string array for my spam-ban.  Have it be like Arr(Messages, Ticks), where Messages are the messages (so you can check their lengths, mostly), and Ticks is the tick that the corresponding message was sent at.  Then just fool around until you get a system that bans people that are spamming while usually not banning people that are just chatting, basically a backwards anti-flood.

CrAz3D

Thank ya, think I could find en thing that might help on on this in ShadowBot source?
rebundance - having or being in excess of sheer stupidity
(ré-bun-dance)
Quote from: Spht on June 22, 2004, 07:32 PMSlap.
Quote from: Adron on January 28, 2005, 09:17 AMIn a way, I believe that religion is inherently evil, which includes Christianity. I'd also say Christianity is eviller than Buddhism (has more potential for evil).
Quote from: iago on April 19, 2005, 01:06 PM
CrAz3D's ... is too big vertically, at least, too big with ... iago ...

Skywing

Quote from: tA-Kane on May 27, 2003, 03:00 PM
Quote from: Kp on May 27, 2003, 02:51 PMhow does the bot know he's spamming?
By the user saying the same thing twice.

Or, by the user coming into the channel, saying something, and leaving before a set time has expired (eg, join, spam, leave in 5-10 seconds). This could be argued as fast leave ban, though.
Quote
ZeroBot supports both things (separately).  Repeated message ban in it is what you're describing.

CrAz3D

How might I go about declaring all of this crap, it is erally gettin confusing.  Rejoin Ban I use just check's a listview, but if spamban is enabled it has to keep track of user & how much they talk for however long...ne code help maybe?
rebundance - having or being in excess of sheer stupidity
(ré-bun-dance)
Quote from: Spht on June 22, 2004, 07:32 PMSlap.
Quote from: Adron on January 28, 2005, 09:17 AMIn a way, I believe that religion is inherently evil, which includes Christianity. I'd also say Christianity is eviller than Buddhism (has more potential for evil).
Quote from: iago on April 19, 2005, 01:06 PM
CrAz3D's ... is too big vertically, at least, too big with ... iago ...

c0ol

set a timer, like 5 seconds, start a variable somwhere associated with the person, when they join again or speak or whatever increment it, when the timer ends, clear it. if the variable reaches like 10 ban them.

CrAz3D

do i have to do a variable per person?  or can it be just o ne?
rebundance - having or being in excess of sheer stupidity
(ré-bun-dance)
Quote from: Spht on June 22, 2004, 07:32 PMSlap.
Quote from: Adron on January 28, 2005, 09:17 AMIn a way, I believe that religion is inherently evil, which includes Christianity. I'd also say Christianity is eviller than Buddhism (has more potential for evil).
Quote from: iago on April 19, 2005, 01:06 PM
CrAz3D's ... is too big vertically, at least, too big with ... iago ...