A classic Snake game built using Python's Turtle graphics library. The objective of the game is to control the snake to eat food, grow in length, and avoid colliding with the walls or itself.
-
Snake Movement:
- Use the arrow keys to control the snake's direction (Up, Down, Left, Right).
-
Food Generation:
- The snake can eat food to grow longer.
- The food is randomly placed on the screen.
-
Scoring System:
- The score increases by one for every food item eaten.
- The high score is saved in a file.
-
Collision Detection:
- The game ends when the snake collides with the wall or itself.
-
Reset Functionality:
- The snake and score reset upon collision.
- Python 3.x
- Turtle graphics library (pre-installed with Python)
- Clone the repository or download the code files.
- Run the
snake_game.py
script using Python:python snake_game.py