https://github.com/prathameshdhande22/snake-game
A Snake game implemented using pygame with a main menu implemented using tkinter. The player can use the arrow keys to control the movement of the snake and collect food to increase the score. The game ends when the snake collides with a wall or itself.
https://github.com/prathameshdhande22/snake-game
game pygame python python3 snake-game tkinter-gui
Last synced: about 2 months ago
JSON representation
A Snake game implemented using pygame with a main menu implemented using tkinter. The player can use the arrow keys to control the movement of the snake and collect food to increase the score. The game ends when the snake collides with a wall or itself.
- Host: GitHub
- URL: https://github.com/prathameshdhande22/snake-game
- Owner: PrathameshDhande22
- License: gpl-3.0
- Created: 2022-06-18T15:26:06.000Z (almost 3 years ago)
- Default Branch: main
- Last Pushed: 2022-07-31T08:12:19.000Z (over 2 years ago)
- Last Synced: 2025-01-14T12:26:01.438Z (3 months ago)
- Topics: game, pygame, python, python3, snake-game, tkinter-gui
- Language: Python
- Homepage:
- Size: 10.6 MB
- Stars: 1
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Snake Game In Pygame
The game is old but still fun to play the game. So i have created this game using pygame.
This is my first game using Pygame python module.
If You like to Play this game without the python interperter download the Snake game setup v1.0 From release so you can download and simply install and play , but **Note** It Works for windows Operating system only.
Please don't delete any file or images it may lead to occur the Exception in the game.
The game first page is created using the tkinter module in python which is in-built in windows version.
The game is made using the OOPs concept to ensure the code reusability.
### Module Required :
1. Tkinter - Inbuilt in Python
2. pillow - Python Imaging Library to manages the images in the gui.
3. pygame - Most import module without this we can't create the game.
4. random - This module is also inbuilt this module helps us to place the snake food in random direction.
5. configparser - To read the config file which stores the highscore of the game.
Install the pygame module using the following command :>pip install pygame
Refer the Documentation of pygame [Read Here](https://www.pygame.org/docs/)
Install the pillow module using the following command:>pip install pillow
It reads the config.ini file to read the highscore saved in this file. Even if the file is deleted it creates the same file while game is played but at that time to highscore will be set to 0.
Game made using the python version 3.9.12.
## Screenshots :
1. Game Main GUI made using Tkinter
![]()
2. Setting Page in GUI
![]()
3. Set the difficulty level before Playing the game.
![]()
4. Main Game
![]()
5. Game Over Screen
![]()
## Author : Prathamesh Dhande