Skip to content

Villy-P/ASCII-Snake

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

28 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

ASCII-Snake

An ASCII implementation of Snake within C. All within your very own console! This project uses <windows.h>, so it is only compatible with Windows OS.

Image

How it works

A simple while loop with a sleep statment at the end of the logic moves the screen, while ANSII escape codes handle "refreshing" the screen.

The program uses the Windows function GetAsyncKeyState to get keypresses that occured while the program was still refreshing.

Running the program

Make sure you have ninja, cmake, and a C compiler.

Then run these commands:

make reset
make run

ASCII-Snake uses classic WASD controls.

About

An ASCII implementation of Snake within C. All within your very own console!

Topics

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published