Tetris in JavaScript