This project is a remake of the old Snake game, written in C++ and based on SDL2.
I have worked on this project with another person at Gaming Campus (our school) for a month. The primary goals of this project were to make us discover object-oriented programming (OOP) through the C++ language, and make us learn some of the basic Linux shell commands.
Initially, adding textures to our game was purely optional. The main goal was to get used to the C++ language and object oriented programming, and having a working snake game at the end of the month.
Having been a self-taught C++ programmer for four years, and the game's specifications allowing bonus points to be earned, I decided to push the bonuses to the absolute limit :
score display and saving, textures on everything, main menu and gameover screen, different types of fruits, etc...
For the textures, I actually modeled the background, snake and fruits in three-dimensions, and rendered those models on flat textures which we used in the final game.
The game provides three different fruit types :
Click an image to enlarge.
The game's main menu screen
Beginning of the game (notice the three kinds of fruits)
There is no limit to how long the snake can grow
Eating a ghost fruit prevents the snake from bumping into itself for a few seconds
The game over screen, showing the final and high scores
Index