Ok... so call me crazy but I never had to enter any special crap to get the logon thing to work properly and not once have I ever watched Mega try to go east at all when I enter.
The one thing that stands out to me is people are talking about this =a or ;a thing that Mega is doing to enable ansi. Perhaps this has something to do with it? I've never used it (ever) and please note that TGS always assumes you are using ansi even if you aren't, so whether your terminal program can render it properly or not, you're getting the ansi codes.
I'm willing to help everyone figure out what the problem is, but please note it's not difficult to get this working. We're not going to switch the GREATERMUD prompt to say MAJORMUD and that's just not negotiable.