It's not a proper change. You should not edit core scripts at all. They work for years already.
In this script, fields necessary for parsing are re-associated under bb_func_usrdat.php. You don't have to mess the indexes to get the script to work properly. Most likely, exactly because of some of your "undocumented" changes it doesn't work.
As for your case, at first, regarding
one of our rules, before coming up with the "problem", try to repeat it on
demo forum or at least this forum. If it can't be repeated - we can't say what's wrong on your end. I've tried to register the username you've mentioned, and of course it worked, because it doesn't contain anything specific.
Regarding the error you've got, it may be related to the minimum/maximum length you've set under $uname_minlength/$uname_max
length; may be other reason?... if you know how to edit the code, I suppose you also know how to debug it - only this would help to determine where this error comes from...