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.

A script that send /msg to the bot owner

Old posts that have not been replied to for several years.
Locked
M
Mandor

A script that send /msg to the bot owner

Post by Mandor »

I definitly suck at tcl scripting, thats why I requiere the help of all the skilled programmers that are arround.

As you probably know, the bot only echos on the partyline bans and kicks that occurs in the channel the console is tuned on.

Would that be possible to make a little tcl script that makes the bot send a /msg to a specific nick each times he bans or kick someone on a channel ?
And if the /msg could say the nick of the person that got kicked / banned and the channel it occured on, and maybe the kick / ban reason, that would be great.

This little script would be of great use, because I like to know where and why my bot is banning people, and if it happens on a channel my console isn't monitoring, I'm only aware of the ban when people start complaining.

Thanks in advance to the person who will comit the time to make this little script.
N
Nexus6
Op
Posts: 114
Joined: Mon Sep 02, 2002 4:41 am
Location: Tuchola, Poland

Post by Nexus6 »

I was a bit bored so I decided to write such script, I'm not sure if it's what you wanted but oh well ;) If you would like anything to be changed, ask :)

Code: Select all

# This tcl was requested by Mandor at http://forum.egghelp.org # tcl 
# Makes bot send a msg to a person, with info of nick who got # kicked, nick 
# who executed kick and kick reason, similar with ban.

# Settings 

# Nick of the person who will get msgs about kicks/bans
set nickmsg "NickWhichWillGetK/BReports"

# Binds  
bind kick - * reportk
bind mode - "* +b" reportb
# Procs
proc reportk {nick uhost handle chan kicked reason} {
global nickmsg 
set addy [getchanhost $kicked]
puthelp "PRIVMSG $nickmsg :Kick report - \002$kicked\002!$addy was kicked off \002$chan\002 with a reason: $reason by \002$nick\002"
}
proc reportb {nick uhost handle chan ban victim} {
global nickmsg
puthelp "PRIVMSG $nickmsg :Ban report - \002$nick\002 has set +b $victim on \002$chan\002"
}
putlog "Kick/Ban report by Nexus6 loaded"
M
Mandor

Post by Mandor »

Thats exactly what I wanted, thanks. :)
Locked