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.

Vip Script Based on Hosts ?

Requests for complete scripts or modifications/fixes for scripts you didn't write. Response not guaranteed, and no thread bumping!
r
r0t3n
Owner
Posts: 507
Joined: Tue May 31, 2005 6:56 pm
Location: UK

Post by r0t3n »

It was just a basebone..
A working version would be:

Code: Select all

set chanvoice(channel) "#channel"
set chanvoice(file) "chanvoice.txt"

bind join -|- {*} chanvoice:join
bind raw -|- {354} chanvoice:raw

proc chanvoice:join {nick host hand chan} {
  global chanvoice
  if {![string equal -nocase $chanvoice(channel) $chan]} { return }
  puthelp "WHO $nick n%at,88"
}

proc chanvoice:raw {from raw arg} {
  global chanvoice
  set tag [lindex [split $arg] 1]
  if {$tag != "88"} { return }
  set nick [lindex [split $arg] 2]
  set auth [lindex [split $arg] 3]
  if {$auth == "" || $auth == "0"} { return }
  set data [read -nonewline [set file [open "$chanvoice(file)" r]]]
  close $file
  foreach x [split $data \n] {
    if {$x == ""} { return }
    if {[string equal -nocase $auth $x]} {
        pushmode $chanvoice(channel) +v $nick
        break
    }
  }
}
Not tested, but should work...
r0t3n @ #r0t3n @ Quakenet
Post Reply