Update player.js

Closes #1