Ecosyste.ms: Awesome

An open API service indexing awesome lists of open source software.

Awesome Lists | Featured Topics | Projects

https://github.com/bilalm04/crashed-oop

Car dodging game created using the p5.js JavaScript library.
https://github.com/bilalm04/crashed-oop

game gui javascript object-oriented-programming p5js

Last synced: 5 days ago
JSON representation

Car dodging game created using the p5.js JavaScript library.

Awesome Lists containing this project

README

        

# CRASHED!

Welcome to CRASHED!, an educational car-dodging game built using the p5.js library. This game demonstrates the principles of object-oriented programming, specifically focusing on inheritance and polymorphism.

**Try it out:** https://bilalm04.itch.io/crashed

![image](https://github.com/BilalM04/CRASHED-OOP/assets/77511892/1515bef7-fc13-4db2-aaa9-5438419c7a4f)
![image](https://github.com/BilalM04/CRASHED-OOP/assets/77511892/629a38ad-a628-4c4a-8597-a55a7b2d9593)
![image](https://github.com/BilalM04/CRASHED-OOP/assets/77511892/6b59803e-b674-4908-981c-be8b844e4f5d)

## Overview

CRASHED! is a simple yet engaging project that allows players to navigate a car through a dynamic environment filled with obstacles. The game is not just about dodging cars; it's also a showcase of how object-oriented design principles can be applied to create modular and scalable code.

## Features

- **p5.js Integration:** The game leverages the capabilities of p5.js, a JavaScript library for creative coding and visualization. This makes it easy to handle graphics and user interactions.

- **Object-Oriented Design:** The code is organized using object-oriented principles, emphasizing inheritance and polymorphism. This design approach enhances code readability, maintainability, and scalability.

- **Dynamic Environment:** Experience a dynamic gaming environment where obstacles move and present challenges for the player. The game showcases how object-oriented concepts can be applied to create interactive and responsive simulations.

## How to Play

1. **Controls:**
- Use the arrow keys (Up, Down, Left, Right) to control the movement of your car.
- Navigate through the moving obstacles to score points.

2. **Scoring:**
- Earn points for every successful dodge.
- Be cautious! Colliding with an obstacle will result in a game over.

3. **Objective:**
- See how long you can survive and how high you can score by dodging obstacles.