$fulltok

By Sigh_ on Jun 18, 2005

;; Not strictly a token identifier as the name would suggest

;; It generates a list of output from a specific identifier which accepts an N parameter

;;

;; Usage: $fulltok(name,C,params[,params...])[.prop]

;;

;; For example: $fulltok(nick,44,#mirc)

;; Will call $nick(#mirc,N) to retrieve all nicknames and put them in a comma delimited list

;;

;; $fulltok(fline,32,#chan,word)

;; Calls $fline(#chan,word,N) to get the line numbers of all matching lines

;;

;; It knows how far to loop by passing an initial N parameter of 0 and using the value returned

alias fulltok {
  var %i = 2,%x
  while (%i < $0) {
    inc %i
    %x = %x $($ $+ %i,2) ,
  }
  var %r = $+($,$1( %x % $+ b),$iif($prop,. $+ $v1)), $&
    %b = 0,%m = $(%r,2),%o
  while (%b < %m) {
    inc %b
    %o = $instok(%o,$(%r,2),0,$2)
  }
  return %o
}

Comments

Sign in to comment.
aeros   -  Jun 25, 2005

nice ;o wtf is it? lol

 Respond  
chaplja   -  Jun 19, 2005

nice

 Respond  
Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.