|
|
hace 3 meses | |
|---|---|---|
| src | hace 3 meses | |
| .gitignore | hace 1 año | |
| README.md | hace 3 meses | |
| compile.sh | hace 3 meses |
A simple snake game in the terminal. No third party libraries needed.
Run:
compile.sh release
to compile an optimized build. The script creates a directory called 'target' that contains the executable.
See:
compile.sh help
for more.
Run:
sanke
to play with defaults settings.
See:
sanke --help
for setting game options.
The program makes the terminal use non-canonical input and output by using termios. Then it updates and prints a 2D character array containing the board borders, snake, and food. Before terminating, the program restores canonical mode.
Only tested with