bind pub - !force myproc
bind time - "?0 * * * *" myproc
proc myproc {nick uhost hand chan text} {
set Something "text here"
set writeFile [open file.txt w]
puts $writeFile $Something
close $writeFile
putserv "PRIVMSG $chan : TEST TEXT"
}
When I write !force in my irc channel the proc "myproc" is performed. Good.
The funny part: With bind time it doesn't work! When I wait 10 minutes nothing is printed out by PRIVMSG but the text "text here" is written to the file file.txt.
Actually this means, the proc is performed with both "bind pub" and "bind time", but PRIVMSG doesn't work for bind time...
Can somebody please tell me how to use PRIVMSG within bind time...
Thanks!
# set here the time bind's output channel
set mychan "#whatever"
bind TIME - "?0 * * * *" myproc
proc myproc {minute hour day month year} {
global mychan
putserv "PRIVMSG $mychan :time bind triggered"
return 0
}
Last edited by arfer on Tue Dec 29, 2009 9:46 pm, edited 1 time in total.