Some basic code cleaning, mainly in player.js