; The contents of this script file are copyrighted by Insides Technologies, 2001. ; Definitions hereby supplied are owned by Insides Technologies and INSIDES - insides@qscripts.cjb.net, the script author. ; Please read the End User License Agreement supplied in order to understand the copy restrictions. ; Please contact the author of the script for any questions you might have. ; Thanks for understanding. alias -l repnick { return $replace($1,[,@,],~) } alias -l retnick { return $replace($1,@,[,~,]) } alias -l rse { return $readini $sf $1 $2 } alias -l ws { writeini $sf $1 $2 $3- } alias -l sf { return $profcdir $+ seen.qm } alias -l sact { return $rse($retnick($1),action) } alias -l svar { return $rse($retnick($1),$2) } alias -l swrd { if ($rse(seenmsg,trig) != $null) { return $ifmatch } | else { return !SEEN } } alias -l stxt { tokenize 44 $1 | return $replace($rse(seenmsg,$1),,$2,,$svar($2,time),,$svar($2,channel),,$sqmsg($svar($2,message)),,$svar($2,kicker),,$svar($2,nick),,$3,,$4) } alias -l sqmsg { return $chr(123) $+ $chr(32) $+ $1- $+ $chr(32) $+ $chr(125) } On *:TEXT:*:#:{ if ($swrd == $1) { seenlook text $2 $nick $chan } } alias seenlook { var %reply if ($qvar(qseen) == 0) { if ($1 == text) { return } | else { emsgbox The Specified Nickname ( %n ) Could Not Be Found. | return } } if ($2 == $me) { set %reply me $+ , $+ $2 $+ $iif($3,$chr(44)) $+ $3 $+ $iif($4,$chr(44)) $+ $4 | goto reply } if ($2 == $3) { set %reply own $+ , $+ $2 $+ $iif($3,$chr(44)) $+ $3 $+ $iif($4,$chr(44)) $+ $4 | goto reply } if ($2 ison $chan) { set %reply onchan $+ , $+ $2 $+ $iif($3,$chr(44)) $+ $3 $+ $iif($4,$chr(44)) $+ $4 | goto reply } if ($sact($2) == $null) { set %reply noseen $+ , $+ $2 $+ $iif($3,$chr(44)) $+ $3 $+ $iif($4,$chr(44)) $+ $4 | goto reply } if ($sact($2) isin Join Part Quit Kick Nick Text Action) { set %reply $sact($2) $+ , $+ $2 $+ $iif($3,$chr(44)) $+ $3 $+ $iif($4,$chr(44)) $+ $4 | goto reply } :reply if ($1 == text) { .msg $3 $stxt(%reply) } else { msgbox $stxt(%reply) $+ §Seen System [/seen] } } #seensave on On *:JOIN:#:{ remini $sf $repnick($nick) | ws $repnick($nick) Action Join | ws $repnick($nick) Channel $chan | ws $repnick($nick) Time $asctime(dd.mm.yyyy At HH:nn:ss) } On *:PART:#:{ remini $sf $repnick($nick) | ws $repnick($nick) Action Part | ws $repnick($nick) Channel $chan | ws $repnick($nick) Time $asctime(dd.mm.yyyy At HH:nn:ss) } On *:QUIT:{ remini $sf $repnick($nick) | ws $repnick($nick) Action Quit | ws $repnick($nick) Time $asctime(dd.mm.yyyy At HH:nn:ss) | ws $repnick($nick) Message $iif($1- == $null,None,$1-) } On *:KICK:#:{ remini $sf $repnick($knick) | ws $repnick($knick) Action Kick | ws $repnick($knick) Channel $chan | ws $repnick($knick) Time $asctime(dd.mm.yyyy At HH:nn:ss) | ws $repnick($knick) Kicker $nick } On *:NICK:{ remini $sf $repnick($nick) | ws $repnick($nick) Action Nick | ws $repnick($nick) Time $asctime(dd.mm.yyyy At HH:nn:ss) | ws $repnick($nick) Nick $newnick } On *:TEXT:*:#:{ remini $sf $repnick($nick) | ws $repnick($nick) Action Text | ws $repnick($nick) Channel $chan | ws $repnick($nick) Time $asctime(dd.mm.yyyy At HH:nn:ss) } On *:ACTION:*:#:{ remini $sf $repnick($nick) | ws $repnick($nick) Action Action | ws $repnick($nick) Channel $chan | ws $repnick($nick) Time $asctime(dd.mm.yyyy At HH:nn:ss) } #seensave end alias seen { if ($1 == settings) { qdlg seen } | else { seenlook look $inputbox(nick§Seen System [/seen]) } } dialog seen { title "" size -1 -1 192 194 option dbu box "",1,-3 -3 300 4 box "Seen System Configuration",2,3 3 186 22 check "Seen System",3,7 13 40 7 text "Seen System Trigger - Word",4,57 13 50 7 edit "",5,109 11 76 11,autohs,limit 15 box "Seen Message Configuration",6,3 26 186 152 text "Me",7,7 36 25 7 edit "",8,35 34 150 11,autohs text "Self",9,7 49 25 7 edit "",10,35 47 150 11,autohs text "Present",11,7 62 25 7 edit "",12,35 60 150 11,autohs text "Nothing",13,7 75 25 7 edit "",14,35 73 150 11,autohs text "Join",15,7 88 25 7 edit "",16,35 86 150 11,autohs text "Part",17,7 101 25 7 edit "",18,35 99 150 11,autohs text "Quit",19,7 114 25 7 edit "",20,35 112 150 11,autohs text "Kick",21,7 127 25 7 edit "",22,35 125 150 11,autohs text "Nick",23,7 140 25 7 edit "",24,35 138 150 11,autohs text "Text",25,7 153 25 7 edit "",26,35 151 150 11,autohs text "Action",27,7 166 25 7 edit "",28,35 164 150 11,autohs button "Save",29,63 181 20 11,ok button "Look",30,86 181 20 11 button "Close",31,109 181 20 11,cancel } On *:DIALOG:seen:*:*:{ if ($devent == init) { mdx.init $dname | mdx.nfinit $dname 31 | mdx SetDialog $dname icon 28 $icons | if ($group(#seensave) = on) { did -c $dname 3 } | dialog -t $dname Seen System | did -f $dname 31 | sinit } if ($devent == sclick) { if ($did == 29) { if ($did(3).state == 1) { .enable #seensave } | else { .disable #seensave } | wse trig 5 | wse me 8 | wse own 10 | wse onchan 12 | wse noseen 14 | wse join 16 | wse part 18 | wse quit 20 | wse kick 22 | wse nick 24 | wse text 26 | wse action 28 } if ($did == 30) { seen } } } alias -l sinit { did -a seen 8 $rse(seenmsg,me) | did -a seen 10 $rse(seenmsg,own) | did -a seen 12 $rse(seenmsg,onchan) | did -a seen 14 $rse(seenmsg,noseen) | did -a seen 16 $rse(seenmsg,join) | did -a seen 18 $rse(seenmsg,part) | did -a seen 20 $rse(seenmsg,quit) | did -a seen 22 $rse(seenmsg,kick) | did -a seen 24 $rse(seenmsg,nick) | did -a seen 26 $rse(seenmsg,text) | did -a seen 28 $rse(seenmsg,action) | did -a seen 5 $swrd } alias -l wse { writeini $sf seenmsg $1 $did(seen,$2) } alias logs { if ($window(@Log) != $null) { window -c @Log } window -ekl12 @Log if ($nopath($theme($qvar(qtheme),images,logo))) { background -c @Log $ifmatch } titlebar @Log Viewer lfill if ($1 != $null) { logpfill $1- } } alias -l lfill { qpbar 7§Logs [/logs]§Filling Log List. var %e $findfile($logdir,*.log,0) if (%e == 0) { dialog -x qpbar } var %m 1 aline -l 4 @Log LOGS aline -l @Log ˇˇˇ var %c 1 var %lc1 $findfile($logdir,*.log,0,1) if (%lc1 == 0) { aline -l @Log None } while ($findfile($logdir,*.log,%c,1) != $null) { aline -l @Log $nopath($findfile($logdir,*.log,%c,1)) | qps Log : $nopath($findfile($logdir,*.log,%c,1)) | qpg %m %e | inc %m | inc %c } aline -l @Log ˇˇˇ aline -l 4 @Log REQUESTS aline -l @Log ˇˇˇ var %c 1 var %l $logdir $+ FRList\ var %lc2 $findfile(%l,*.log,0,1) if (%lc2 == 0) { aline -l @Log None } while ($findfile(%l,*.log,%c,1) != $null) { aline -l @Log $nopath($findfile(%l,*.log,%c,1)) | qps Log : $nopath($findfile(%l,*.log,%c,1)) | qpg %m %e | inc %m | inc %c } aline -l @Log ˇˇˇ aline -l 4 @Log REPLIES aline -l @Log ˇˇˇ var %c 1 var %l $logdir $+ CTCP\ var %lc3 $findfile(%l,*.log,0,1) if (%lc3 == 0) { aline -l @Log None } while ($findfile(%l,*.log,%c,1) != $null) { aline -l @Log $nopath($findfile(%l,*.log,%c,1)) | qps Log : $nopath($findfile(%l,*.log,%c,1)) | qpg %m %e | inc %m | inc %c } aline -l @Log ˇˇˇ aline -l 4 @Log PAGES aline -l @Log ˇˇˇ var %c 1 var %l $logdir $+ PGLogs\ var %lc4 $findfile(%l,*.log,0,1) if (%lc4 == 0) { aline -l @Log None } while ($findfile(%l,*.log,%c,1) != $null) { aline -l @Log $nopath($findfile(%l,*.log,%c,1)) | qps Log : $nopath($findfile(%l,*.log,%c,1)) | qpg %m %e | inc %m | inc %c } aline -l @Log ˇˇˇ aline -l 4 @Log PINGS aline -l @Log ˇˇˇ var %c 1 var %l $logdir $+ APList\ var %lc5 $findfile(%l,*.log,0,1) if (%lc5 == 0) { aline -l @Log None } while ($findfile(%l,*.log,%c,1) != $null) { aline -l @Log $nopath($findfile(%l,*.log,%c,1)) | qps Log : $nopath($findfile(%l,*.log,%c,1)) | qpg %m %e | inc %m | inc %c } aline -l @Log ˇˇˇ set %qlogs 3 $+ - $+ $calc(%lc1 + 2) var %h $calc(6 + %lc1) set %qreqs %h $+ - $+ $calc(%h + %lc2 - 1) var %h $calc(%h + %lc2 + 3) set %qreps %h $+ - $+ $calc(%h + %lc3 - 1) var %h $calc(%h + %lc3 + 3) set %qpages %h $+ - $+ $calc(%h + %lc4 - 1) var %h $calc(%h + %lc4 + 3) set %qpings %h $+ - $+ $calc(%h + %lc5 - 1) } alias -l logfill { clear @Log | var %c 1- $+ $lines($1-) | aline @Log 4LOG : $remove($nopath($1-),.log) | titlebar @Log Viewer - $remove($nopath($1-),.log) | aline $colour(background) @Log - | .loadbuf %c -p @Log $1- } alias -l logpfill { var %p $logdir $+ $1- | if ($exists(%p)) { logfill %p } } alias -l logres { var %c = $strip($sline(@Log,1)),%l = $sline(@Log,1).ln,%f | if ($istok(PAGES LOGS REQUESTS REPLIES PINGS None ˇˇˇ,%c,32) != $true) { if (%l isnum %qlogs) { var %f $logdir $+ %c } | if (%l isnum %qreqs) { var %f $logdir $+ FRList\ $+ %c } | if (%l isnum %qreps) { var %f $logdir $+ CTCP\ $+ %c } | if (%l isnum %qpages) { var %f $logdir $+ PGLogs\ $+ %c } | if (%l isnum %qpings) { var %f $logdir $+ APList\ $+ %c } | return %f } } alias -l logrem { if ($exists($logres)) { .remove $logres | logs } } alias -l logcopy { var %f $inputbox(Please Enter Filename.§Log Viewer [/logs]) | if (%f) && ($exists($logres)) { .copy $logres %f } } menu @Log { dclick:{ logfill $logres } Refresh ...:logs $iif($mouse.lb,Open ...):logfill $logres - $iif($mouse.lb,Copy ...):logcopy $iif($mouse.lb,Delete ...):logrem - Close ...:window -c @Log } On *:CLOSE:@Log:{ unset %qlogs | unset %qreqs | unset %qreps | unset %qpages | unset %qpings } dialog qpbar { title "" size -1 -1 106 42 option dbu box "",1,-3 -3 200 4 text "",2,4 4 150 7 text "",3,3 15 100 10 box "",4,-3 -3 200 33 text "",10,4 32 150 7 button "",6,0 0 0 0,cancel } On *:DIALOG:qpbar:init:0:{ mdx.init $dname mdx.finit $dname 2 3 5 6 10 11 12 mdx SetControlMDX $dname 3 progressbar smooth > [ $gdll ] } alias qpbar { qdlg qpbar | mdx SetDialog qpbar icon 26 $icons | dialog -t qpbar $gettok($1-,2,167) | did -ra qpbar 2 $gettok($1-,3,167) } alias qps { did -ra qpbar 10 $1- } alias qpg { did -ra qpbar 3 $1 0 $2 | if ($1 >= $2) && ($dialog(qpbar) != $null) { dialog -x qpbar } } dialog ulist { title "" size -1 -1 185 145 option dbu box "",1,-3 -3 400 4 box "Users",2,3 3 66 126 list 3,7 12 58 120 box "User Flags",4,72 3 110 50 check "Friend",5,76 12 30 7 check "Op",6,76 22 30 7 check "Voice",7,76 32 30 7 check "Help",8,76 42 30 7 check "Enemy",9,109 12 30 7 check "DeOp",10,109 22 30 7 check "Kick",11,109 32 30 7 check "Ban",12,109 42 30 7 check "Bot",13,142 12 30 7 check "DCC Get",14,142 22 37 7 check "DCC Send",15,142 32 37 7 check "DCC Chat",16,142 42 37 7 box "User Information",17,72 54 110 75 text "Nick",18,77 65 20 7 edit "",19,96 63 82 11,autohs text "Name",20,77 78 20 7 edit "",21,96 76 82 11,autohs text "Host",22,77 91 20 7 edit "",23,96 89 82 11,autohs text "E-Mail",24,77 104 20 7 edit "",25,96 102 82 11,autohs text "Note",26,77 117 20 7 edit "",27,96 115 82 11,autohs button "Add",28,23 132 16 11 button "Remove",29,42 132 26 11 button "Save",30,71 132 20 11 button "Clear",33,94 132 20 11,cancel button "Close",31,117 132 20 11,cancel button "Help",32,140 132 20 11 } On *:DIALOG:ulist:*:*:{ if ($devent == init) { mdx.init $dname | mdx.nfinit $dname 33 | mdx SetDialog $dname icon 18 $icons | dialog -t $dname User List | did -f $dname 31 | ulfill } if ($devent == sclick) { if ($did == 3) { if ($did(3).sel != $null) { ufill $did(3,$did(3).sel) } } if ($did isnum 5-8) { if ($did($did).state == 1) { did -u $dname 9,10,11,12 } } if ($did isnum 9-12) { if ($did($did).state == 1) { did -u $dname 5,6,7,8 } } if ($did == 28) { .writeini $ul users $inputbox(nick§User List [/userlist]) f | ulfill } if ($did == 29) { .remini $ul users $did(3,$did(3).sel) | did -r $dname 19,21,23,25,27 | did -u $dname 5,6,7,8,9,10,11,12,13,14,15,16 | ulfill } if ($did == 30) { if ($did(19)) && ($uled) { .writeini $ul users $did(19) $uled $+ $iif($utxt,§) $+ $utxt | ulfill } } if ($did == 33) { did -r $dname 19,21,23,25,27 | did -u $dname 5,6,7,8,9,10,11,12,13,14,15,16 } } } alias userlist { qdlg ulist | if ($1 != $null) { ufill $1 } } alias ul { return $profcdir $+ userlist.qm } alias umode { var %c $readini $ul users $1 | var %p $replace($prop,flags,1,name,2,host,3,email,4,note,5) | if (%c == $null) { return } | if (%p == $null) { return %c } | return $gettok(%c,%p,167) } alias rumode { var %w,%t = f o v h e d k n b g s c,%e = Friend AutoOp AutoVoice AutoHelp Enemy DeOp AutoKick AutoBan Bot DCCGet DCCSend DCCChat, %r = $umode($1).flags,%c = 1 | while ($mid(%r,%c,1) != $null) { set %w %w $+ $gettok(%e,$findtok(%t,$mid(%r,%c,1),1,32),32) $+ ,_ | inc %c } | if ($right(%w,2) == ,_) { set %w $left(%w,$calc($len(%w) - 2)) } | if (%w == $null) { return No Modes Set. } | return $replace(%w,_,$chr(32)) } alias -l ulfill { did -r ulist 3 | var %c 1 | while (%c <= $lines($ul)) { var %l $read -l $+ %c $ul | if ([ !isin %l) { did -a ulist 3 $gettok(%l,1,61) } | inc %c } } alias -l uld { var %r $replace($umode($1).flags,f,5_,o,6_,v,7_,h,8_,e,9_,d,10_,k,11_,n,12_,b,13_,g,14_,s,15_,c,16_) | if ($right(%r,1) == _) { set %r $left(%r,$calc($len(%r) - 1)) } | return $replace(%r,_,$chr(44)) } alias -l ufill { if ($umode($1) == $null) { return } | did -u ulist 5,6,7,8,9,10,11,12,13,14,15,16 | did -ra ulist 19 $1 | did -ra ulist 21 $umode($1).name | did -ra ulist 23 $umode($1).host | did -ra ulist 25 $umode($1).email | did -ra ulist 27 $umode($1).note | did -c ulist $uld($1) | dialog -t ulist User List $iif($1,-) $1 } alias -l uled { var %c = 5,%r,%t = f o v h e d k n b g s c | while (%c <= 16) { set %r %r $+ $iif($did(ulist,%c).state == 1,$gettok(%t,$calc(%c - 4),32)) | inc %c } | return %r } alias -l utxt { return $did(ulist,21) $+ $iif($did(ulist,23),§) $+ $did(ulist,23) $+ $iif($did(ulist,25),§) $+ $did(ulist,25) $+ $iif($did(ulist,27),§) $+ $did(ulist,27) }