This is the new home of the egghelp.org community forum.
All data has been migrated (including user logins/passwords) to a new phpBB version.


For more information, see this announcement post. Click the X in the top right-corner of this box to dismiss this message.

Autosecret.tcl

Old posts that have not been replied to for several years.
M
Mikey
Voice
Posts: 13
Joined: Sun Apr 25, 2004 1:31 am
Location: Florida, USA

Post by Mikey »

Same result, sets but not removing.

Mikey
User avatar
user
 
Posts: 1452
Joined: Tue Mar 18, 2003 9:58 pm
Location: Norway

Post by user »

Mikey wrote:Same result, sets but not removing.
What did you try? Did you .restart recently? Check '.binds <type of bind that should trigger the -s>' to see if the bind is triggered.
Have you ever read "The Manual"?
M
Mikey
Voice
Posts: 13
Joined: Sun Apr 25, 2004 1:31 am
Location: Florida, USA

Post by Mikey »

The code tried is by User; restarted just now with the same resuts.

<Mikey> .binds join
<bones> Command bindings:
<bones> TYPE FLGS COMMAND HITS BINDING (TCL)
<bones> join -|- * 3 do_joinstat
<bones> join -|- * 3 check_onjoin
<bones> join P|- * 0 do_join_cancel_logout
<bones> join -|- * 3 do_the_s_check

Respectfully,

Mikey
User avatar
user
&nbsp;
Posts: 1452
Joined: Tue Mar 18, 2003 9:58 pm
Location: Norway

Post by user »

what did you set s_threshold to?
Have you ever read "The Manual"?
M
Mikey
Voice
Posts: 13
Joined: Sun Apr 25, 2004 1:31 am
Location: Florida, USA

Post by Mikey »

set s_threshold 1

Mikey
M
Mikey
Voice
Posts: 13
Joined: Sun Apr 25, 2004 1:31 am
Location: Florida, USA

Post by Mikey »

Ok lets try this from ground zero...

Bot dies; set s_threshold 5 (since with 4 other bots); channel is set +s before the bot joins; bot joins its HOME channel ONLY (previous tests it was in 3 channels)

<bones> Channel #Mikey, 5 members, mode +strn:
.binds join
<bones> Command bindings:
<bones> TYPE FLGS COMMAND HITS BINDING (TCL)
<bones> join -|- * 1 do_joinstat
<bones> join -|- * 1 check_onjoin
<bones> join P|- * 0 do_join_cancel_logout
<bones> join -|- * 1 do_the_s_check

<bones> Channel #Mikey, 6 members, mode +strn:
.binds join
<bones> Command bindings:
<bones> TYPE FLGS COMMAND HITS BINDING (TCL)
<bones> join -|- * 2 do_joinstat
<bones> join -|- * 2 check_onjoin
<bones> join P|- * 0 do_join_cancel_logout
<bones> join -|- * 2 do_the_s_check
(+s stays)

<@Mikey> b mode -s
* Bones sets mode: -s

<bones> Channel #Mikey, 5 members, mode +trn:
.binds part
<bones> Command bindings:
<bones> TYPE FLGS COMMAND HITS BINDING (TCL)
<bones> part L|- * 1 do_part_timer_logout
<bones> part -|- * 1 do_the_s_check
(-s stays)

And that is the play by play...

Respectfully,

Mikey
User avatar
caesar
Mint Rubber
Posts: 3778
Joined: Sun Oct 14, 2001 8:00 pm
Location: Mint Factory

Post by caesar »

Oups! :oops: Yes user, you are right about the "[lindex [split [getchanmode $a]] 0]" thing, haven't thinked about the key. :roll:
Once the game is over, the king and the pawn go back in the same box.
User avatar
user
&nbsp;
Posts: 1452
Joined: Tue Mar 18, 2003 9:58 pm
Location: Norway

Post by user »

I guess I should have tested it :P This version is...

Code: Select all

set s_threshold 1
bind join - * {do_the_s_check 0}
bind part - * {do_the_s_check 1}
bind sign - * {do_the_s_check 1}

proc do_the_s_check {off nick uhost hand chan args} {
	if {![validchan $chan]||[string match *s* [channel get $chan chanmode]]} return
	if {[isbotnick $nick]} {
		utimer 5 [list do_the_s_check 0 . . . $chan]
	} elseif {[botisop $chan]} {
		if {([llength [chanlist $chan]]-$off)>$::s_threshold} {
			if {[string match *s* [lindex [getchanmode $chan] 0]]} {
				pushmode $chan -s
			}
		} elseif {![string match *s* [lindex [getchanmode $chan] 0]]} {
			pushmode $chan +s
		}
	}
}
Have you ever read "The Manual"?
M
Mikey
Voice
Posts: 13
Joined: Sun Apr 25, 2004 1:31 am
Location: Florida, USA

Post by Mikey »

Thanks User. Initial test show the same thing happening -- no response(s). I will strip all my other tcl's and make a skeleton bot and start from there. (Currently running Stormbot and Bar & Grill).

Let me also, really look at your earlier comment about "there might be a key containing "s"".

There MUST be a reason for this not working for me. To bad I just cant put a finger on it (YET!! ;) )

Again, thanks for your time in helping me find a script that will work for myself, our network and hopefully others that may find it useful.

Respectfully,

Mikey
M
Mikey
Voice
Posts: 13
Joined: Sun Apr 25, 2004 1:31 am
Location: Florida, USA

Post by Mikey »

Sir User: Welp!! Finally have been able to get back to this script after an absence...

(Short of being a complete idiot) I have real no idea why this was not working the first time I tried it but, it is working flawlessly now!! MANY THANKS!!! :)

Now, if I can further pick your brain; can we make it do this for other channels the bot(s) (may) reside in with (perhaps) not the same 's_threshold #" setting?

Many thanks again - KUDOS!!!!

mab
Locked