A classic Snake game implementation in Python using OpenCV.
demo.mp4
- Clone this repository.
- Install the required libraries:
pip install numpy opencv-python
. - Run the game:
python snake_game.py
.
- Use
a
to move left. - Use
d
to move right. - Use
w
to move up. - Use
s
to move down. - Press
Esc
to quit the game.
- Snake movement and collision logic.
- Apple spawning and scoring system.
- Game over conditions and score display.
Contributions are welcome! To contribute:
- Fork this repository.
- Create a new branch for your feature:
git checkout -b feature-name
. - Commit your changes:
git commit -m 'Add feature'
. - Push to the branch:
git push origin feature-name
. - Create a pull request.
This project is licensed under the MIT License. See LICENSE for details.
You can reach out to me via GitHub: Soumelee
Feel free to connect with me in LinkedIn: Soumili Mondal