Skip to content

Cross-platform Snake game written in C language.

Notifications You must be signed in to change notification settings

bogdan0083/c-snake

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

9 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

C Snake

Cross-platform Snake game written in C language.

Extremely simple setup. Works on Windows, Linux and Mac!

Disclaimer

The purpose of this program is to demonstrate how to make a very simple game in C that works on all platforms. Please note that I'm not very proficient with C. The source code and overall architecture of the game can be improved in lots of ways. I would be happy to receive Pull Requests if you feel like something needs to be changed/improved.

Installation

Windows

Just run run-windows.bat in snake folder and you are good to go! All the necessary dependencies are already included in _win folder

Mac

The game wasn't tested on Mac OS. Please open an issue if it doesn't work for you

  1. Install clang by typing "clang" in Terminal and clicking the Install button.
  2. Open a snake folder and run run-mac.sh

Linux

TDOO: test on linux

  1. Install tcc, SDL2-dev, and GLEW-dev. Eg. for Debian/Ubuntu:

    sudo apt install tcc libsdl2-dev libsdl2-ttf-dev libglew-dev
    
  2. Open a snake folder and run run-linux.sh

More games

Wanna try more games? Check out Tiny C Games repository to find more mini games.

Thanks

This project is inspired by @superjer and his tinyc.games repo.

About

Cross-platform Snake game written in C language.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages