added setWalkableAt method, commented useless console.log, added tests, added params for allowDiagonal & dontCrossCorners, compiled files

Tell me if it's ok :)

I've written test from scratch, ideally we could use mocha for example