This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.


For more information, see this announcement post. Click the X in the top right-corner of this box to dismiss this message.

help with script

Old posts that have not been replied to for several years.
Locked
L
LeWren

Post by LeWren »

i'm wondering is there any script for eggdrop, kicking too long nicknames. coz i'm sick of ppl who are using 20 or 30 letter nicks. but problem is that i don't know so much about tcl scripting to make it by myself. i will very thankful if someone will guide me, where can i find this kind of script..
User avatar
stdragon
Owner
Posts: 959
Joined: Sun Sep 23, 2001 8:00 pm
Contact:

Post by stdragon »

Code: Select all

set max_nick_len 15

bind join - * nick_join
bind nick - * nick_change

proc nick_join {nick uhost hand chan} {
  global max_nick_len
  if {[string length $nick] > $max_nick_len} { nick_punish $nick $chan }
}

proc nick_change {nick uhost hand chan newnick} {
  global max_nick_len
  if {[string length $newnick] > $max_nick_len} { nick_punish $newnick $chan }
}

proc nick_punish {nick chan} {
  global max_nick_len
  putserv "KICK $chan $nick :Your nickname is too long! Make it $max_nick_len characters or fewer."
}

putlog "Loaded: The amazing nick length checker by stdragon"
<font size=-1>[ This Message was edited by: stdragon on 2002-03-13 08:21 ]</font>
L
LeWren

Post by LeWren »

thanx a lot stdragon
is there some tutorials or something how to make scripts for eggdrops or something. i don't like to beg ppl
User avatar
Yourname
Master
Posts: 358
Joined: Mon Sep 24, 2001 8:00 pm
Location: Toronto

Post by Yourname »

Cant it be made to do a nick ban too without just kicking, as it generates a kick flood on mIRC clients.

Something like:

nick!*host@*.com
Dormant egghead.
L
LeWren

Post by LeWren »

just kick workes fine, when someone will autorejoin, then he/she get banned for autorejoin.
User avatar
Yourname
Master
Posts: 358
Joined: Mon Sep 24, 2001 8:00 pm
Location: Toronto

Post by Yourname »

You can learn TCL scripting from the tutorial at http://www.suninet.nl/tclguide as well as referring to the TCL commands eggdrop uses in the tcl-commands.doc provided along with the eggdrop.
Dormant egghead.
L
LeWren

Post by LeWren »

i'm in heaven, thanx a lot
W
Wcc
Master
Posts: 278
Joined: Sun Oct 28, 2001 8:00 pm
Location: USA
Contact:

Post by Wcc »

There is also an html version of tcl-commands.doc in doc/html/tcl-commands.html new in 1.6.9 if that helps :smile:.
User avatar
Yourname
Master
Posts: 358
Joined: Mon Sep 24, 2001 8:00 pm
Location: Toronto

Post by Yourname »

Did anyone read my first post? :razz:
Dormant egghead.
L
LeWren

Post by LeWren »

i did, and i answered also. but it's not solution for you... this is possible, but i have no skills for that
e
egghead
Master
Posts: 481
Joined: Mon Oct 29, 2001 8:00 pm
Contact:

Post by egghead »

On 2002-03-13 11:00, Yourname wrote:
Cant it be made to do a nick ban too without just kicking, as it generates a kick flood on mIRC clients.

Something like:

nick!*host@*.com
Adding a ban to the script provided by stdragon shouldn't be too difficult.
Note, however, that a mildly malicious user, with little effort, can force your bot to send out many kicks and fill the ban list of your bot/channel easily, with a nick based ban as you propose.
Also note that the irc-server will punish your bot for sending many kicks AND bans and eventually may ignore the kicks for a while (although the queue mechanism of eggdrop can prevent that).

A flood-join setting of something like 3:20 will create a ban with more wild cards, which can help.

A ban is a bit of a tough punishment for such a little offense of having a long nickname :smile:
Actually, what to do if the bot guards a channel with 500 users where 5 % of the users has a long nickname?

Personally, if I had to take action on long nicknames, my script would make the bot kick such a nick on join, and after that kick it once in a while. With a maximum of say 5 kicks per 20 seconds.

My attempt to script such a thing is:
http://members.fortunecity.com/eggheadt ... en.tcl.txt
This could be a start for your own developmnents, as I've no intention to develop it further.

Another point to note: there are scripts out there to check for weird/offending nicknames. You can try to modify such script to not check for the "content" of the nickname, but for its length.

But actually, long nicks are only annoying when they start talking :smile:
So, a much easier script can help you out:

http://members.fortunecity.com/eggheadt ... lk.tcl.txt


<font size=-1>[ This Message was edited by: egghead on 2002-03-26 20:38 ]</font>
Locked