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.

Weird eggdrop-error with that script

Old posts that have not been replied to for several years.
Locked
p
puffi
Voice
Posts: 25
Joined: Tue Jun 01, 2004 10:09 am

Weird eggdrop-error with that script

Post by puffi »

when i load that script into eggdrop
(all this is in namespace automodes)

Code: Select all


bind raw * JOIN automodes::rawjoin_automode

  proc rawjoin_automode {from keyword txt} {
    set n [lindex [split $from "!"] 0]
    set u [lindex [split $from "!"] 1]
    set h "*"
    set c [string range $txt [string first "#" $txt] end]
    set a ""
    join_automode $n $u $h $c $a
  }

  proc join_automode {n u h c a} {
    global automodes::doautomodes_on_myop
    if {[isbotnick $n]} {
      putlog "Joined Auto-Mode channel $c. Do automodes as soon as i get op."
      set automodes::doautomodes_on_myop($c) 1
    } else {
      if {![botisop $c]} { return 0 }
      if {[channel get $c av]} {
        putserv "MODE $c +v $n"
      }
      if {[channel get $c ao]} {
        putserv "MODE $c +o $n"
      }
    }
  }
and i .restart it (not rehash) then it joins all channels, and just after the
Joined Auto-Mode channel $c. Do automodes as soon as i get op.
is put into the partyline..that happens

Code: Select all

[20:52] Oops.   Someone made me join #chan... leaving...
then the eggdrop leaves the channel and rejoins in 10-15 seconds. when it rejoins the same message comes up and it would loop infinitely (i guess)

any suggestions?
User avatar
De Kus
Revered One
Posts: 1361
Joined: Sun Dec 15, 2002 11:41 am
Location: Germany

Post by De Kus »

does the channel contain some wired character that cause the bot not getting a match when triing to the match the just joined channel again the chanlist?

does it happen as well when you add "return 0" the line below "join_automode $n $u $h $c $a"?

not do mention its completly unnecessary to bind to raw and make 2 procs out of it @_o.
De Kus
StarZ|De_Kus, De_Kus or DeKus on IRC
Copyright © 2005-2009 by De Kus - published under The MIT License
Love hurts, love strengthens...
Locked