Skip to content

maaz2417/CAR-GAME

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

4 Commits
Β 
Β 
Β 
Β 

Repository files navigation

πŸš— Car Trading & Modification Game

A C++ console-based simulation game developed as a semester project. This application allows users to buy specific cars, modify their specifications, and manage a garage using a persistent save system.

πŸ“ Description

This project demonstrates the principles of Object-Oriented Programming (OOP) applied to a game logic system. The program simulates a car dealership and workshop environment where players can:

  • Browse a catalog of specific car models.
  • Purchase vehicles and add them to their garage.
  • Modify car stats (like Horsepower) through a tuning system.
  • Save and load progress using a custom file handling system.

πŸš€ Features

  • Car Dealership System: Buy specific makes and models.
  • Modification System: Upgrade car variants and horsepower.
  • Persistent Data: Uses File Handling to save car attributes (Make, Model, Variant, HP) to a text file.
  • Garage Management: Support for saving multiple cars in a single save file.
  • Console Interface: Interactive menus powered by Windows.h for smooth navigation.

πŸ› οΈ Tech Stack & Concepts

  • Language: C++
  • Core Concepts:
    • OOP: Heavy use of Classes and Objects.
    • Inheritance: To manage different vehicle categories/types.
    • Polymorphism: For dynamic method overriding in car behaviors.
    • Encapsulation: Protecting data members like engine stats.
  • System:
    • File Handling: Custom logic to read/write object data to .txt files.
    • Windows.h: Used for console formatting and system interactions.

πŸ’» How to Run

Note: This project is designed for Windows due to the dependency on <Windows.h>.

  1. Clone the repository
    git clone [https://github.com/your-username/car-game.git](https://github.com/your-username/car-game.git)
  2. Open the project
    • Open the .cpp files in your IDE (Visual Studio, Dev-C++, or VS Code).
  3. Compile and Run
    • Ensure your compiler supports C++11 or higher.
    • Build and run the main executable.

πŸ“‚ Project Structure

  • main.cpp - The entry point of the game loop.
  • Car.h / Car.cpp - Base class definitions.
  • savefile.txt - (Generated) Stores user progress.

πŸ‘₯ Contributors

  • [Maaz Arshad Akhund] - Logic implementation & File Handling
  • [Bushra Asad] - Class Design & Testing

Created for the Object-Oriented Programming Semester Project at IMSciences.

About

This is a car modification/ specific car buying game which i made in OOP for my semester project along with my group partner

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages