| View previous topic :: View next topic |
| Author |
Message |
neoclust Halfop
Joined: 14 Aug 2009 Posts: 55
|
Posted: Fri Aug 13, 2010 9:14 pm Post subject: +v-v $nick $nick in one line |
|
|
| Hello can i use pushmode $chan +v-v $nick $nick in one line ? |
|
| Back to top |
|
 |
Luminous Op
Joined: 12 Feb 2010 Posts: 146
|
Posted: Fri Aug 13, 2010 10:01 pm Post subject: |
|
|
Not exactly... pushmode is intended to lump several mode commands into a single line. Not sure why you would want to cancel out a mode like that, but this would probably work:
| Code: | pushmode $chan +v $nick
pushmode $chan -v $nick |
|
|
| Back to top |
|
 |
neoclust Halfop
Joined: 14 Aug 2009 Posts: 55
|
Posted: Sat Aug 14, 2010 6:21 am Post subject: |
|
|
I tried that but it does not work :
utimer 10 [list pushmode $chan +v $nick]
utimer 1 [list pushmode $chan -v $nick]
the result :
[11:20] *** Eggy sets mode: +v neoclust |
|
| Back to top |
|
 |
Luminous Op
Joined: 12 Feb 2010 Posts: 146
|
Posted: Sat Aug 14, 2010 9:49 am Post subject: |
|
|
Back to back timers causes issues for me.. try something like this instead, even though its ugly:
| Code: |
... code....
utimer 10 [list cancel_mode $nick $chan]
... rest of code....
}
proc cancel_mode {nick chan} {
pushmode $chan +v $nick
pushmode $chan -v $nick
} |
If that doesn't do it... I don't know.. :\ |
|
| Back to top |
|
 |
willyw Revered One
Joined: 15 Jan 2009 Posts: 1175
|
Posted: Sat Aug 14, 2010 10:25 am Post subject: Re: +v-v $nick $nick in one line |
|
|
| neoclust wrote: | | Hello can i use pushmode $chan +v-v $nick $nick in one line ? |
If you want to get it on one line, try:
| Code: |
putserv "mode #chan -v+v $firstnick $secondnick"
|
but, did you mean to use the same nick twice? Nothing will happen if you use the same nick twice. ... maybe I'm not understanding the goal. |
|
| Back to top |
|
 |
Luminous Op
Joined: 12 Feb 2010 Posts: 146
|
Posted: Sat Aug 14, 2010 10:44 am Post subject: |
|
|
| Yeah, puserv/quick/help would work just fine with that. I did a mode +b-b *!*@* *!*@* in one line in my egg a minute ago and it worked fine, aside from freaking out another bot that was on the channel, haha. |
|
| Back to top |
|
 |
speechles Revered One

Joined: 26 Aug 2006 Posts: 1398 Location: emerald triangle, california (coastal redwoods)
|
Posted: Sat Aug 14, 2010 11:35 am Post subject: |
|
|
The problem is pushmode will stack modes and wait for either the end of the invoked procedure, or flushmode before it actually sends them to the server. Modes enabling/negating the same thing get stripped naturally. To get around this, you can flushmode after the pushmode.
| Code: | pushmode $chan +v $nick
flushmode $chan
pushmode $chan -v $nick
flushmode $chan |
_________________ speechles' eggdrop tcl archive |
|
| Back to top |
|
 |
neoclust Halfop
Joined: 14 Aug 2009 Posts: 55
|
Posted: Sat Aug 14, 2010 5:43 pm Post subject: |
|
|
Hello i'm using
| Code: |
utimer 10 [list cancel_mode $nick $chan]
proc cancel_mode {nick chan} {
pushmode $chan +v $nick
putlog "up"
flushmode $chan
pushmode $chan -v $nick
putlog "down"
flushmode $chan
}
|
I received the message putlog but remains devoice which was not the case
| Quote: | [22:37] ((nino): [21:37] Userfile loaded, unpacking...
[22:37] ((nino): [21:37] up
[22:37] ((nino): [21:37] down
[22:37] ((nino): [21:37] #test: mode change '+v fg' by nino !blah@blah.com
[22:40] ((nino): [21:40] @#test (+smtDn) : [m/3 o/1 h/0 v/2 n/0 b/0 e/- I/-] |
In channel :
| Quote: | [22:37] *** [#test] users- 1 op(s) 33.33% - 1 voice(s) 33.33% - 1 other(s) 33.33%
[22:37] *** ········································
[22:37] *** nino sets mode: +v fg |
|
|
| Back to top |
|
 |
neoclust Halfop
Joined: 14 Aug 2009 Posts: 55
|
Posted: Sat Aug 14, 2010 6:13 pm Post subject: |
|
|
| The objective of this script is to publish the users who are in hidden mode in the presence of mode +Dm of the canal and keep only those identified in X and that *.users.undernet.org in their Host I hope you understand me |
|
| Back to top |
|
 |
|