bind pub - * triggers
proc triggers {nick uhost hand chan arg} {
set trigger [lindex [split $arg] 0]
set command [string tolower $trigger]
switch -- $command {
"!url" {
putserv "NOTICE $nick :Visit us at http://11th-wolverines.net"
}
"!contact" {
putserv "NOTICE $nick :Contact us through our public forums http://11thwolverines.forumsplace.com "
}
"!forums" {
putserv "NOTICE $nick :Check out our forums at http://11thwolverines.forumsplace.com"
}
"!staff" {
putserv "NOTICE $nick :Staff List is incomplete at this time"
}
"!help" {
putserv "NOTICE $nick :Commands for the bot are !url, !contact, !forums, !staff"
}
default {
putserv "NOTICE $nick :Unknown command: $trigger"
}
}
}
The lifecycle of a noob is complex. Fledgling noobs gestate inside biometric pods. Once a budding noob has matured thru gestation they climb out of their pod, sit down at a PC, ask a bunch of questions that are clearly in the FAQ, The Noob is born
The lifecycle of a noob is complex. Fledgling noobs gestate inside biometric pods. Once a budding noob has matured thru gestation they climb out of their pod, sit down at a PC, ask a bunch of questions that are clearly in the FAQ, The Noob is born
But how to make these commands work only on some specific channels ? For example at clan's private channel only, not the other channels this bot is on ???
set clanchan "#clanchan"
if { [string tolower $chan] != [string tolower $clanchan] } {
return
} else {
... do the rest of the code ...
}
The lifecycle of a noob is complex. Fledgling noobs gestate inside biometric pods. Once a budding noob has matured thru gestation they climb out of their pod, sit down at a PC, ask a bunch of questions that are clearly in the FAQ, The Noob is born
heh I may of been faster but your way is more usefull in the long run so I would suggest to you decl that you use Sir_Fz's code as it supports multiple channels rather than my way which only supports 1 channel.
Future Proofing is the way to go baby yeahhhh
The lifecycle of a noob is complex. Fledgling noobs gestate inside biometric pods. Once a budding noob has matured thru gestation they climb out of their pod, sit down at a PC, ask a bunch of questions that are clearly in the FAQ, The Noob is born
Another question. If I want the commands work on 2 channels ?
In clan case, two different priv channels, so different commands on them.. How to do so that #chan1 and #chan2 would have different commands ? But ONLY these two channels.. ? :f