| View previous topic :: View next topic |
| Author |
Message |
opsb Halfop
Joined: 01 Sep 2007 Posts: 41
|
Posted: Wed Jan 30, 2008 8:36 pm Post subject: simple cycle script |
|
|
hi
i need small cycle script that will rejoin few channels (not all) in interval of 15 mins.
I found some scripts in archive but nothing works for me..
sorry on bad english
thnx |
|
| Back to top |
|
 |
iamdeath Master

Joined: 11 Feb 2005 Posts: 323 Location: *HeLL*
|
Posted: Thu Jan 31, 2008 11:30 am Post subject: |
|
|
| Code: | bind time - "00 * * * *" my:cycle
bind time - "15 * * * *" my:cycle
bind time - "30 * * * *" my:cycle
bind time - "45 * * * *" my:cycle
proc my:cycle {min hour day month year} {
putserv "PART #MyChannel :Hello, this is just a part msg."
putserv "JOIN #MyChannel"
} |
This will cycle your channel every 15 minutes, any problems let me know.
peace
death _________________ |AmDeAtH @ Undernet
Death is only the *Beginning*... |
|
| Back to top |
|
 |
opsb Halfop
Joined: 01 Sep 2007 Posts: 41
|
Posted: Thu Jan 31, 2008 6:42 pm Post subject: |
|
|
Okay and how to edit this to cycle all channels except monitoring chan..
variable for monitoring chan is
set spambotmon #channel |
|
| Back to top |
|
 |
iamdeath Master

Joined: 11 Feb 2005 Posts: 323 Location: *HeLL*
|
Posted: Thu Jan 31, 2008 10:58 pm Post subject: |
|
|
| Code: | proc my:cycle {min hour day month year} {
putserv "PART #channel1 :Hello, this is just a part msg."
putserv "PART #channel2 :Hello, this is just a part msg."
putserv "PART #channel3 :Hello, this is just a part msg."
putserv "JOIN #channel1"
putserv "JOIN #channel2"
putserv "JOIN #channel3"
} |
or do like this:
You need to give flag like to enable cycle on any channel:
| Code: | | .chanset #Channel +mycycle |
| Code: | setudef flag mycycle
bind time - "00 * * * *" my:cycle
bind time - "15 * * * *" my:cycle
bind time - "30 * * * *" my:cycle
bind time - "45 * * * *" my:cycle
proc my:cycle {min hour day month year} {
foreach chan [channels] {
if {[channel get $chan mycycle]} {
putserv "PART $chan :Hello, this is just a part msg"
putserv "JOIN $chan"
}
}
} |
I have'nt tested the second code so I am not sure how perfect it is.
peace
death _________________ |AmDeAtH @ Undernet
Death is only the *Beginning*...
Last edited by iamdeath on Thu Jan 31, 2008 11:09 pm; edited 2 times in total |
|
| Back to top |
|
 |
Alchera Revered One

Joined: 11 Aug 2003 Posts: 3344 Location: Ballarat Victoria, Australia
|
Posted: Thu Jan 31, 2008 11:04 pm Post subject: |
|
|
opsb: If you are after an anti spam script (which involves a bot cycling at settable intervals) then you should be looking at demon's spambuster script. _________________ Add [SOLVED] to the thread title if your issue has been.
Search | FAQ | RTM
Last edited by Alchera on Fri Feb 01, 2008 11:00 am; edited 1 time in total |
|
| Back to top |
|
 |
opsb Halfop
Joined: 01 Sep 2007 Posts: 41
|
Posted: Fri Feb 01, 2008 7:06 am Post subject: |
|
|
My bot is deoped on all channels.. and can't kick/ban.
Just scanning for spam for specific words and monitoring to ops channel |
|
| Back to top |
|
 |
opsb Halfop
Joined: 01 Sep 2007 Posts: 41
|
Posted: Fri Feb 01, 2008 8:20 am Post subject: |
|
|
| iamdeath wrote: | You need to give flag like to enable cycle on any channel:
| Code: | | .chanset #Channel +mycycle |
| Code: | setudef flag mycycle
bind time - "00 * * * *" my:cycle
bind time - "15 * * * *" my:cycle
bind time - "30 * * * *" my:cycle
bind time - "45 * * * *" my:cycle
proc my:cycle {min hour day month year} {
foreach chan [channels] {
if {[channel get $chan mycycle]} {
putserv "PART $chan :Hello, this is just a part msg"
putserv "JOIN $chan"
}
}
} |
I have'nt tested the second code so I am not sure how perfect it is.
peace
death |
This script works very good..
So will this be correct
| Code: | proc my:cycle {min hour day month year} {
global timewait
foreach chan [channels] {
if {[channel get $chan mycycle]} {
putserv "PART $chan :Hello, this is just a part msg"
timer $timewait putserv "JOIN $chan"
}
}
} |
and then use variable
set timewait 1 |
|
| Back to top |
|
 |
iamdeath Master

Joined: 11 Feb 2005 Posts: 323 Location: *HeLL*
|
Posted: Fri Feb 01, 2008 9:40 am Post subject: |
|
|
| Code: | setudef flag mycycle
bind time - "00 * * * *" my:cycle
bind time - "15 * * * *" my:cycle
bind time - "30 * * * *" my:cycle
bind time - "45 * * * *" my:cycle
proc my:cycle {min hour day month year} {
foreach chan [channels] {
if {[channel get $chan mycycle]} {
putserv "PART $chan :Hello, this is just a part msg"
utimer 60 [list putserv "JOIN $chan"]
}
}
} |
This should be fine because it will make your bot rejoin your channel in 60 seconds, I have'nt tested it but let me know.
peace
death. _________________ |AmDeAtH @ Undernet
Death is only the *Beginning*... |
|
| Back to top |
|
 |
opsb Halfop
Joined: 01 Sep 2007 Posts: 41
|
|
| Back to top |
|
 |
iamdeath Master

Joined: 11 Feb 2005 Posts: 323 Location: *HeLL*
|
Posted: Fri Feb 01, 2008 1:06 pm Post subject: |
|
|
I don't understand you or I can't get what you're looking for sorry. _________________ |AmDeAtH @ Undernet
Death is only the *Beginning*... |
|
| Back to top |
|
 |
metroid Owner
Joined: 16 Jun 2004 Posts: 771
|
Posted: Fri Feb 01, 2008 1:14 pm Post subject: |
|
|
That's because eggdrops rejoin their own channels the moment it notices it has parted.
| Code: | setudef flag mycycle
bind time - "00 * * * *" my:cycle
bind time - "15 * * * *" my:cycle
bind time - "30 * * * *" my:cycle
bind time - "45 * * * *" my:cycle
proc my:cycle {min hour day month year} {
foreach chan [channels] {
if {[channel get $chan mycycle]} {
channel set $chan +inactive
utimer 60 [list channel set $chan -inactive]
}
}
} |
Also, you should stop requesting pieces of scripting to add to your "anti spambot" script because you're not doing any of the work, nor do you seem able to do so. |
|
| Back to top |
|
 |
opsb Halfop
Joined: 01 Sep 2007 Posts: 41
|
Posted: Fri Feb 01, 2008 1:20 pm Post subject: |
|
|
| iamdeath wrote: | | I don't understand you or I can't get what you're looking for sorry. |
Something Like this
[18:12:15] Part Eggdrop
[18:13:15] Join Eggdrop
[18:28:15] Part Eggdrop
[18:29:15] Join Eggdrop
And so on |
|
| Back to top |
|
 |
|