This is a 2D side-scrolling game called "Flinstone Pizza" developed using Pygame. The player controls a dino character and must navigate through various levels, avoiding obstacles like rocks, shells, pitfalls, and traps to deliver pizza.
The player controls a dino and runs from left to right. The dino can jump to avoid obstacles. The goal is to reach the end of each level without colliding with obstacles. Colliding with an obstacle results in restarting the current level. Completing all levels leads to a "Game Completed" screen.
- Multiple Levels: The game features multiple levels, each with unique backgrounds and obstacles.
- Obstacle Avoidance: Players must avoid various obstacles, including rocks, shells, pitfalls, log traps, cat traps, water pitfalls and a Barney trap.
- Jumping: The dino can jump to avoid obstacles.
- Sound Effects: The game includes jump and losing sound effects, as well as background music.
- Level Transitions: The game seamlessly transitions between levels.
- Game Completion: A "Game Completed" screen is displayed upon successful completion of all levels.
- Intro Video and Image: The game starts with a short intro video followed by a static image before the main gameplay begins.
-
Clone the repository:
git clone [https://github.com/](https://github.com/)[your-github-username]/FLINSTONE-PIZZA-2D-GAME.git # Replace with your repo URL
-
Install dependencies:
pip install pygame opencv-python numpy
-
Place Assets:
Ensure all image and sound files are placed in the correct directories as specified in the code. The code assumes a specific directory structure (e.g., img/, sounds/, start_vid/). Adjust the file paths in the code if necessary.
A suggested structure is:
FLINSTONE-PIZZA-2D-GAME/
├── img/
│ ├── background/
│ ├── clouds/
│ ├── Obstacles/
│ └── sprites/
│ └── dino/
│ └── Barney/
├── sounds/
│ ├── jump.wav
│ ├── losing.wav
│ └── playing music.mp3
└── start_vid/
├── 1.mp4
└── gaaa.jpg
└── FLINSTONE-PIZZA-2D-GAME.py
└── README.md
Left Arrow Key: Move left
Right Arrow Key: Move right
Spacebar/Up Arrow Key: Jump
The game includes the following levels:
Pygame OpenCV (cv2) NumPy
Navigate to the game directory in your terminal. Run the main Python file: Bash
python FLINSTONE-PIZZA-2D-GAME.py
This game was developed by
[Hasini Liyanawadu] - https://github.com/Has362
[Dewmini Apsara] - https://github.com/Apsara-dew
[Pavan Pramod] -
[Vidun Tharumika] - https://github.com/Tharumika
All the image assets including backgrounds, Obstacles were created by our selves.