Don't Be lazy, do a little debug..
Just before login line output some debug strings with informations such as if your player element is valid, his nickname, given username and password, name of account that you are trying to log player into.
That's debugging.
I cannot tell you more without gui part, but i think it's not a problem to output some values, right?