on *:TEXT:*:#:{ if ($+(*,$me,*) iswm $1-) || (*Arbiter* iswm $1-) { if ($isbot($nick) == $false) { if ($($+(%,highlightspam.,$address($nick,2)),2) >= 5) { .ignore -u60 $nick 2 | echo -a $nick triggerd your highlight spam protection! Ignoring user for 60 seconds. | unset $+(%,highlightspam.,$address($nick,2)) } if ($appactive == $false) { inc -u10 $+(%,highlightspam.,$address($nick,2)) if ($window(@Highlights)) { closewin | showpopup $nick highlighted you in $chan on $network saying $strip($qt($1-)) } else { showpopup $nick highlighted you in $chan on $network saying $strip($qt($1-)) } if (%logging.high == on) { write highlights.txt $time([hh:nn:ssTT) @ $date(dd/mm/yy]) $+($nick,/,$chan,/,$network,:) $strip($1-) } } else { echo -a $nick highlighted you in $chan on $network saying $strip($qt($1-)) inc -u10 $+(%,highlightspam.,$address($nick,2)) if (%logging.high == on) { write highlights.txt $time([hh:nn:ssTT) @ $date(dd/mm/yy]) $+($nick,/,$chan,/,$network,:) $strip($1-) } } } } } menu channel,status { - Highlight Logs:highlightlogs } dialog highlight { title Highlight logs $+($chr(40),$lines(highlights.txt),$chr(41)) size -1 -1 242 161 option dbu list 1, 6 12 231 81, size hsbar vsbar box "Logs", 2, 4 2 235 96 button "Delete", 3, 81 107 37 12 button "Clear logs", 4, 81 125 37 12 text "Written by Mr_White (AKA Arbiter) @ sir_sonic1234@yahoo.com", 9, 5 146 163 8 link "alice.heliohost.org", 11, 182 145 54 8 button "Close", 12, 136 125 37 12, ok cancel radio "Enable Logging", 8, 7 112 50 10 radio "Disable Logging", 10, 7 128 50 10 button "Update Bots", 13, 136 107 37 12 text "Credit for the popup alias goes to Xnemesis (www.crispycrisp.org)", 14, 180 109 54 25 } on *:dialog:highlight:*:*:{ if ($devent == init) && ($did == 0) { updateit } if ($devent == sclick) { if ($did == 3) { var %l = $read(highlights.txt,nw,$+(*,$gettok($did(highlight,1).seltext,5-,32),*)) write -dw $+ $qt(%l) highlights.txt %l closeit } if ($did == 4) { write -c highlights.txt | echo -at *** Highlight log files cleard. | closeit } if ($did == 8) { if (%logging.high == on) { echo -at *** Error: Highlight logging is already on. } else { set %logging.high on echo -at *** Highlight logging enabled. } } if ($did == 10) { if (%logging.high == off) { echo -at *** Error: Highlight logging is already on. } else { set %logging.high off echo -at *** Highlight logging disabled. } } if ($did == 12) { dialog -x highlight } if ($did == 13) { botlist } } } alias -l updateit { did -c highlight $iif(%logging.high == on,8,10) var %i = 1 while (%i <= $lines(highlights.txt)) { did -a highlight 1 $read(highlights.txt,n,%i) inc %i } } alias -l closeit { dialog -x highlight | dialog -dm highlight highlight } alias highlightlogs { if ($dialog(highlight)) { dialog -x highlight | dialog -dm highlight highlight } else { dialog -dm highlight highlight } } on ^*:NOTICE:*:?: { if ($nick = BotServ && %botlist) { haltdef if ($regex($1-,/^(\S+) \(\w+@\w+\.\w+(?:\.\w+)*\)$/Si)) write bots.txt $regml(1) elseif ($regex($1-,/^(\d+) bots available\.$/Si)) { unset %botlist echo -a Finished writing bots to BotList. There are currently $regml(1) bots available. This alias was written by Kol of SwiftIRC. } } } alias isbot return $iif($read(bots.txt,r,/^\Q $+ $$1 $+ \E$/),$true,$false) alias botlist { echo -a Updating BotList bs botlist set %botlist on write -c bots.txt } alias closewin { close -@Highlights } alias showPopup { window -pBdk0w0o +blL @Highlights $calc(%highlights.screenx - 250) $calc(%highlights.screenx - 92) 250 63 drawfill @Highlights $popc1 $popc1 0 0 var %highlights.nxtln = $true, %highlights.popup = $1-, %highlights.y = 9 while (%highlights.nxtln) { if ($len(%highlights.popup) > 50) { if (%highlights.y == 39) { drawtext -p @Highlights $popc2 10 %highlights.y $mid(%highlights.popup,0,46) ... unset %highlights.nxtln unset %highlights.popup } else { drawtext -p @Highlights $popc2 10 %highlights.y $mid(%highlights.popup,0,50) %highlights.popup = $mid(%highlights.popup,51,$mid(%highlights.popup,51,0)) } } else { drawtext -p @Highlights $popc2 10 %highlights.y %highlights.popup unset %highlights.nxtln unset %highlights.popup } inc %highlights.y 10 } .timer 1 5 close -@Highlights } alias -l popc1 { return 15 } alias -l popc2 { return 01 } on *:start:{ %highlights.screenx = $window(-1).w %highlights.screeny = $window(-1).h } on *:load:{ %highlights.screenx = $window(-1).w %highlights.screeny = $window(-1).h }