Cleanup.
Added a character manager class and copied code into it. Not used yet.