Snippets Project Page
Author: entropy
Added: 3y
Updated: 3y
mIRC: Unknown
Hits: 1,000
Downloads: 28
Review: westor
Size: 1.55KB
1 0
Login to vote.
URL Colorer
v1.2
This snippet colors URL's when someone says URL's in channel.
Download
JSON
▲ Review
▼ Source
; ============================================== ; URL Colorer v1.2 - by entropy 2020 ; ============================================== menu menubar,status,channel,query { - URL Colorer v1.2 .Turn $chr(9) $replace($group(#url).status,on,On,off,Off) { $iif($group(#url).status == on,.disable,.enable) #url echo 4 -ag * URL Colorer is now $replace($group(#url).status,o,O) } .Color $chr(9) %url_color { %url_color = $input(Double digit color?,5,Color) | echo 4 -ag * URL Color is now %url_color } - } on *:load:{ %url_color = 04 } on *:unload:{ unset %url_color } #url on on ^*:action:*:#,?:{ docolor describe $1- | haltdef } on ^*:text:*:#,?:{ docolor msg $1- | haltdef } #url end alias -l domode { return $iif($left($nick(#,$nick).pnick,1) isin ~&@%+,$v1) } alias -l doline { return $+($chr(3),%url_color,$chr(31),$1-,$chr(31),$chr(3)) } alias -l docolor { var %a = 1, %b, %total = $2-, %target while ($gettok($2-,%a,32) != $null) { %b = $v1 if (http://* iswm %b || https://* iswm %b || irc://* iswm %b || ftp://* iswm %b || www.* iswm %b) { %total = $reptok(%total,%b,$doline(%b),1,32) } inc %a } if ($left($target,1) == $chr(35)) { %target = # } else { %target = $nick } window -g1 %target if ($1 == describe) { echo $color(action) -t %target * $+($domode,$nick) %total } else { echo $color(normal) -t %target $+(<,$chr(3),$line(%target,$fline(%target,$nick,1,1),1).color,$domode,$nick,$chr(3),>) %total } }
Changelog:
0
0
Comments (2)