document.addEventListener("keydown", (e) => { if (e.key === "ArrowLeft") { piece.x--; } else if (e.key === "ArrowRight") { piece.x++; } else if (e.key === "ArrowDown") { piece.y++; } draw(); });