Skip to content

DrShahinstein/c-snake-game

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

19 Commits
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Snake Game in C using Raylib

This has been the first project of mine where I used C and learned a lot.

Keys

Key Func
Space Pause game
Enter Unpause game
Enter Restart game

Showcase

showcase.mp4

Build

See releases to get executable binaries right away. If you want to build from source, raylib must be installed and maintained on your machine.

Linux

Clone the repository and simply run make tool to build snake game in Linux.

$ git clone https://github.com/DrShahinstein/c-snake-game
$ cd c-snake-game/
$ make
$ make run

Windows

Make sure you have w64devkit installed on your machine. Using w64devkit terminal, you can follow the exact same instruction with Linux.

$ git clone https://github.com/DrShahinstein/c-snake-game
$ cd c-snake-game/
$ make
$ make run

Troubleshooting

In Windows, if you ever face an issue like raylib window not being initialized just as in here:

problem

You can change the compatibility of the executable to run on Windows 8 or anything else if necessarry like this:

windowscompatibility