tidy main.js
give player it's own directory within lib directory