Cheiron commented on a Page, Unique Auto Voicer  -  Mar 06, 2008

some nicks obviously are taken so in order to keep the nick, people use characters infront of the nick.. ie.. ^helen {helen} [helen] `helen etc..... what the script is doing is ignoring those characters until it finds the first letter. then it checks whether it is upper or lower case. if it is lowercase, then mode +v is given.. on change to an Uppercase letter at the start of the name.. the script will remove the voice. hope that clears it up.. the regex is there to sift through the code.. this was the original

uppercheck on

alias startwithupper {
if ( $1 == $null ) {
return $false
}
return $isupper($left($$1,1))
}

on @*:JOIN:#Channel:{
if ( $startwithupper($nick) == $true ) {
mode #Channel +v $nick
}
}

on @*:NICK:{
if ( ( $startwithupper($newnick) == $true ) && ( $newnick !isvoice #Channel ) ) {
; New nick is with upper case and previous is unvoiced
mode #Channel +v $newnick
}
if ( ( $startwithupper($newnick) == $false ) && ( $newnick isvoice #Channel ) ) {
; New nick is with lower case and previous is voiced
mode #Channel -v $newnick
}
}

uppercheck end

but that was for an uppercase nick getting the voice. sdamon did the debug for me with help from Warder to clean it up.\"i\'ve updated your code to check $1 whilst removing characters such as ` and {. I\'ve also dumped that long channel name into a local alias ($_c) to return it; makes it easier and cleaner\"

hope that answers your questions :)

 Respond  
Are you sure you want to unfollow this person?
Are you sure you want to delete this?
Click "Unsubscribe" to stop receiving notices pertaining to this post.
Click "Subscribe" to resume notices pertaining to this post.