Many (most?) IRCds will limit the "user" field to 10 characters, so this is why $address() truncates it to 10. The primary purpose of $address() is to generate wildcard masks for purposes like banning a user. If your network supports usernames longer than 10 characters, you need to avoid using $address(nick,5) and instead use $ial(nick) in all situations.
To understand exactly why mIRC does what it does, you'd need to consider a situation like this: You want to ban user joe!abcdefghij@somehost.com from your channel, but want to make sure he still can't get in even if he disables identd. So you attempt to do: /mode #channel +b *!*abcdefghij@somehost.com
Now unfortunately, IRCds are stupid and limit the user field in ban masks to 10 characters too (including wildcard characters), so it will truncate it from the left and actually set a ban for *!*abcdefghi@somehost.com which doesn't even match the user you are trying to ban in the first place. To counter this, mIRC automatically "corrects" it to *!*bcdefghij@somehost.com when you let it set the ban so that the server won't truncate it and the ban will actually match the user you want to ban.
Now, mIRC does make the assumption that the username is never longer than 10 characters when it does this, so admittedly it can cause problems when it is longer than 10 characters. It's sort of a workaround that isn't perfect but is probably more useful than detrimental.
I suppose you could get the best of both worlds by changing $address() and $mask() so they only truncate when a wildcard is present in the user field.
Last edited by drum; 19/12/11 02:23 PM.