Fixed issue 31 and 32 and optimized the code surrounding storage of players.