An open API service indexing awesome lists of open source software.

https://github.com/dheovani/snakegame

Recreated my SnakeGame in C++ with SFML Graphics library
https://github.com/dheovani/snakegame

cplusplus cpp game game-development gamedev sfml sfml-cpp sfml-game sfml-game-development sfml-graphics-library snake snake-game snakegame

Last synced: about 2 months ago
JSON representation

Recreated my SnakeGame in C++ with SFML Graphics library

Awesome Lists containing this project

README

        

# SnakeGame

[Gameplay](https://github.com/Dheovani/SnakeGame/assets/79609196/dbbe117f-a8fb-4a6a-ab3d-7d1fde38cffb)

This is a classic Snake game implemented in C++. It's a simple yet entertaining game where the player controls a snake that grows longer as it consumes food.

## How to Play

1. Clone or download the repository.
2. Compile the code using a C++ compiler, e.g., `gcc main.cpp -o snake_game`.
3. Run the game with `./snake_game` (on Unix-based systems) or `snake_game.exe` (on Windows).

## Controls

- Use the arrow keys to control the direction of the snake:
- Up: `↑`
- Down: `↓`
- Left: `←`
- Right: `→`
- Enter: 🔄

## Gameplay

- The snake starts with a length of one.
- Move the snake to collect food (green circles).
- The snake grows in size when it eats food.
- Try to achieve the highest score by eating as much food as possible without colliding with yourself.

## License

This Snake Game in C++ is open-source and available under the [MIT License](LICENSE). You are free to use and modify the code for your purposes.

Happy gaming! 🐍