Move calls to player to separate JS

- Next step to make a flock.js file and move stuff out there