Update grid.js

implement endless game