Reorganise and more progress towards next release.

New playerLoginEvent handling logic implemented.
Code reorganisation.