A modern Tetris game built with Go using the Ebiten game engine.
- ✅ Smooth Tetromino movement & rotation
- ✅ Wall Kick System (SRS)
- ✅ Hard Drop (SPACE Key)
- ✅ Scoring System
- ✅ Game Speed Increases Over Time
- 🚧 Upcoming: Hold & Swap (SHIFT Key), & Leveling
This project follows a Go workspace structure:
go-tetris-ws/
│── tetris/ # Core Tetris game logic (library)
│ ├── board.go
│ ├── config.go
│ ├── game.go
│ ├── input.go
│ ├── shapes.go
│ ├── tetromino.go
│ ├── ui.go
│ ├── go.mod
│── tetris-main/ # Main entry point
│ ├── go.mod
│ ├── main.go
│── go.work # Go workspace file
│── README.md
│── LICENSE
│── .gitignore
$ git clone https://github.com/dynamicy/go-tetris.git
$ cd go-tetris/go-tetris-ws
$ go work use ./tetris ./tetris-main
$ cd tetris-main
$ go run .
$ go get github.com/dynamicy/go-tetris-ws/tetris
import "github.com/dynamicy/go-tetris-ws/tetris"
Key | Action |
---|---|
← / → | Move left / right |
↓ | Soft Drop |
Space | Hard Drop |
Z / X | Rotate CCW / CW |
Shift | Hold Tetromino (Upcoming Feature) |
Want to improve Go-Tetris? Feel free to fork the repository, make changes, and submit a Pull Request!