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.

notify script

Help for those learning Tcl or writing their own scripts.
Post Reply
n
nixi
Voice
Posts: 2
Joined: Tue Mar 30, 2010 4:57 am
Location: Germany

notify script

Post by nixi »

Hi all of you

Can anyone of you tell me why doesn't this code work ?

Code: Select all

set ntfy_nickstocheck {
Engineer
Developer
Tester
Mapherick
}


proc ntfy_settimer {args} {
  timer 5 ntfy_check
}

proc ntfy_check {args} {
  global ntfy_nickstocheck

  set intc [join $ntfy_nickstocheck]
  putserv "ISON $intc"
  ntfy_settimer
}

proc ntfy_process {from keyw args} {
  global ntfy_nickstocheck
  set ionl [split [lindex [split [lindex $args 0] ":"] 1]]
  foreach nick $ionl {lappend ionll [string tolower $nick]}

  foreach nick $ntfy_nickstocheck {
    if {[lsearch $ionll [string tolower $nick]] == -1} {
      lappend iofl $nick
    }
  }

  putlog "NTFY: ONLINE: [join $ionl]"
  putlog "NTFY: OFFLINE: $iofl"

}


bind raw - 303 ntfy_process
n
nixi
Voice
Posts: 2
Joined: Tue Mar 30, 2010 4:57 am
Location: Germany

Post by nixi »

I ve got that tcl from this page :

http://forum.egghelp.org/viewtopic.php?t=2396

thanks for your attention
Post Reply