menu channel,status,menubar { Highlight .$iif(%hlt.on == 1,Disable,Enable):{ if (%hlt.on == 1) { set %hlt.on 0 } else { set %hlt.on 1 } } .Open:hlt .Unload:{ unset %hlt.* unload -rs highlight.mrc echo -a Highlight by AlternativeNick Unloaded } } alias -l hlt { if ($dialog(hlt) == $null) { dialog -ma hlt hlt } else { dialog -v hlt } } dialog hlt { title "Highlighter" size -1 -1 155 99 option dbu text "Highlight on", 1, 6 5 29 8 edit "", 2, 4 14 145 10 edit "", 3, 5 76 145 20, read multi box "", 4, 0 69 155 6 button "Save", 5, 121 57 27 12 text "On Highlight-", 6, 13 28 31 8 check "Play Sound", 7, 24 37 38 10 check "Log Instance", 8, 24 48 50 10 check "Display in Active", 9, 24 59 50 10 edit "", 10, 62 37 50 10 button "Browse", 11, 115 37 22 10 button "Cancel", 12, 91 57 27 12, cancel } on *:DIALOG:hlt:init:*:{ if (%hlt.sound == 1) { did -c $dname 7 } if (%hlt.log == 1) { did -c $dname 8 } if (%hlt.echo == 1) { did -c $dname 9 } if (%hlt.soundf != $null) { did -a $dname 10 %hlt.soundf } if (%hlt.list != $null) { did -a $dname 2 %hlt.list } } on *:DIALOG:hlt:sclick:*:{ if ($did == 11) { did -a $dname 10 $sfile($mircdir $+ \ $+ *, Choose a sound file.) set %hlt.soundf $! } elseif ($did == 5) { if ($did($dname,7).state == 1) { set %hlt.sound 1 } if ($did($dname,8).state == 1) { set %hlt.log 1 } if ($did($dname,9).state == 1) { set %hlt.echo 1 } if ($did($dname,10).text != $null) { set %hlt.soundf $did($dname,10).text } if ($did($dname,2).text != $null) { set %hlt.list $did($dname,2).text } } } on *:DIALOG:hlt:mouse:*:{ if ($mouse.x isnum 1 - 300 ) && ($mouse.y isnum 1 - 148) { if ($mouse.y isnum 20-50) { did -r $dname 3 did -a $dname 3 Place all triggers for highlighting here, seperated by a comma. Use $me to trigger on your nickname } ;Checkboxe Explanations if ($mouse.x isnum 1 - 155) && ($mouse.y isnum 60 - 140) { if ($mouse.y isnum 80 - 95) { did -r $dname 3 did -a $dname 3 Check this box to enable sound playing on highlight. Also, indicate the sound in the box to the right. } if ($mouse.y isnum 96 - 110) { did -r $dname 3 did -a $dname 3 Check this box to enable Instance Logging. This will log eveything that triggers a highlight to highlightlog.txt } if ($mouse.y isnum 115 - 130) { did -r $dname 3 did -a $dname 3 Check this box to enable Active Display. This will display anything triggering a highlight to the current window } } } } on *:TEXT:*:*:{ if (%hlt.on == 1) { var %i = 0 while (%i < $numtok(%hlt.list,44)) { inc %i 1 if ($eval($gettok(%hlt.list,%i,44),2) isin $1-) { if (%hlt.log == 1) { write highlightlog.txt $time $nick // $+ $chan $+ \\ :: $1- } if (%hlt.echo == 1) && ($chan != $active) { echo -a $nick in $chan said $1- } if (%hlt.sound == 1) && (%hlt.soundf != $null) { splay %hlt.soundf } } } } }