Fix LoginEvent not being called.

If the server is in offline mode, the LoginEvent should be called.
Merge pull request #261 from roblabla/patch-2

Fix LoginEvent not being called.