A classic Snake game implemented in C, featuring smooth gameplay and a console-based interface. This project demonstrates basic game development concepts, including input handling, rendering, and collision detection, in the C programming language.
- Smooth Gameplay: Enjoy responsive and smooth snake movement.
- Scoring System: Tracks and displays the player's score.
- Simple Controls: Navigate the snake using the arrow keys or
WASD. - Dynamic Environment: Random fruit generation and growing snake tail.
- Programming Language: C
- Libraries:
conio.hfor input handlingwindows.hfor delay (Sleep) function
Clone the repository:
git clone https://github.com/proobker/Snake_Game.gitNavigate to the project directory:
cd Snake_GameCompile the source code:
gcc snake_game.c -o snake_gameRun the game:
./snake_game- Use
W,A,S,Dor arrow keys to move the snake. - Collect fruits to grow the snake and increase your score.
- Avoid running into the walls or the snake's own tail.
- Press
Xto quit the game.
Contributions are welcome! Follow these steps to contribute:
- Fork this repository.
- Create a new branch:
git checkout -b feature-name
- Commit your changes:
git commit -m "Add feature description" - Push to the branch:
git push origin feature-name
- Create a pull request.
This project is licensed under the MIT License.
For queries or feedback, contact:
- Email: rrabi.dahal@gmail.com
- GitHub: proobker
Thank you for exploring this repository! We hope this project inspires your game development journey.
