Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- alias myhlnick {
- var %max = $numtok(%nohlchans, 32)
- var %i = 1
- while (%i <= %max) {
- var %chan = $gettok(%nohlchans, %i, 32)
- if (%chan == $chan) return $null
- inc %i
- }
- return $me
- }
- alias -l isnohlon {
- return $iif($findtok(%nohlchans, $1, 32) == $null, $false, $true)
- }
- alias -l togglenohl {
- var %status = $isnohlon($1)
- if (%status == $true) set %nohlchans $remtok(%nohlchans, $1, 1, 32)
- else set %nohlchans $addtok(%nohlchans, $1, 32)
- echo -at Highlighting on $1 is now $iif(%status, ON, OFF)
- }
- menu channel {
- -
- Highlight is $iif($isnohlon($chan), OFF, ON)
- .Turn highlight $iif($isnohlon($chan), ON, OFF):togglenohl $chan
- }
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement