stop posts on chan.
#1
salut a tous..

hi .a friend of mine ask me for help for about a code what he uses on his eggdrop. he said he uses this code for triggering some help lines on channel.its a very simple code what he used. so he asked me that some help triggers are too long,and i want to cut that off with a "!stop" command and than bot should stop posting these help lines on channel.
(by the way those help lines not in a readable .txt file)

so i tried couple of things allnight long on this code.but i couldn't make it to stop the bot posting lines.here it is my edit of the code :
Code :
bind pub - !start foo_start bind pub - !stop stop_foo proc foo_start {nick uhost hand chan text} { if {![isop $nick $chan]} { global foo_status set foo_status 1 if {!$foo_status} break utimer 15 [list puthelp "PRIVMSG $chan :message"] utimer 25 [list puthelp "PRIVMSG $chan :message 1"] utimer 35 [list puthelp "PRIVMSG $chan :message 2"] utimer 45 [list puthelp "PRIVMSG $chan :message 3"] } } proc stop_foo {nick uhost hand chan text} { global foo_status set foo_status 0 }
but as you can see ,its not working .so than i connect #egghelp channel for to get a suggestion how can i do that !stop thing*.
and speechless suggest me to edit like that,they said it should work like that.here is the second edition of this code:
Code :
bind pub - !start foo_start bind pub - !stop stop_foo proc foo_start {nick uhost hand chan text} { if {![isop $nick $chan]} { global foo_status if {![array exists foo_status]} { set foo_status(1) [utimer 15 [list puthelp "PRIVMSG $chan :message"]] set foo_status(2) [utimer 25 [list puthelp "PRIVMSG $chan :message 1"]] set foo_status(3) [utimer 35 [list puthelp "PRIVMSG $chan :message 2"]] set foo_status(4) [utimer 45 [list puthelp "PRIVMSG $chan :message 3"]] } } } proc stop_foo {nick uhost hand chan text} { global foo_status foreach timer [list 1 2 3 4] { killutimer $timer } array unset foo_status }

but this edition is not working either...
and it has some terrible issues : like when it starts !stop not working and gave an error on partyline like : invalid timerID stop_foo..
and if when make it !stop you have to restart the bot after to try second time !start command..so its useless and not working for to stop posting lines.

so i would like to open a new thread in here for to ask your advices and suggestions for about this issue.

thanks in advance.
Répondre


Messages dans ce sujet
stop posts on chan. - par heartbroken - 18/11/2012, 10:44
RE: stop posts on chan. - par CrazyCat - 18/11/2012, 11:39
RE: stop posts on chan. - par heartbroken - 19/11/2012, 03:56
RE: stop posts on chan. - par heartbroken - 21/11/2012, 00:59
RE: stop posts on chan. - par CrazyCat - 21/11/2012, 15:17
RE: stop posts on chan. - par heartbroken - 21/11/2012, 17:44
RE: stop posts on chan. - par CrazyCat - 22/11/2012, 10:11
RE: stop posts on chan. - par Artix - 23/11/2012, 22:07

Atteindre :


Utilisateur(s) parcourant ce sujet : 1 visiteur(s)
Tchat 100% gratuit - Discutez en toute liberté - Transitionnez vers Linux - Discussions dans le Lauragais - Communauté LGBT respectueuse - soutien aux victimes de cybermalveillance - pour les filles par les filles Le forum pour passer le temps