This is a simple block fall down game clone written in Go. The entirety of the code was generated by Cursor AI by refining the prompt as issues were encountered. I specifically asked it to generate a game only using the standard library.
brew install go
go get golang.org/x/sys
go get golang.org/x/term
go run tetris.go
- Left/Right arrows: Move piece left/right
- Down arrow: Move piece down faster
- Up arrow: Hard drop piece
- 'a': Rotate piece counterclockwise
- 'd': Rotate piece clockwise
- 'q': Quit game