GameHub is a Python project that acts as a hub for multiple mini-games. The project uses modular Object-Oriented Programming (OOP) to create scalable, stable, and easily testable game modules.
- General Knowledge Quiz - Test your general knowledge with a series of questions.
- Tic Tac Toe - Play the classic game against a friend or an AI.
- Hangman - Guess the word letter-by-letter before you run out of attempts.
- Anagram - Unscramble letters to find the correct word.
- Solver - Solve math or word problems with hints.
gamehub/ ├── games/ │ ├── gk_quiz.py │ ├── tic_tac_toe.py │ ├── hangman.py │ ├── anagram.py │ └── solver.py ├── tests/ │ ├── test_gk_quiz.py │ ├── test_tic_tac_toe.py │ ├── test_hangman.py │ ├── test_anagram.py │ └── test_solver.py └── main.py
- main.py: The main hub file that allows users to select and play games.
- games/: Contains modules for each individual game.
- tests/: Contains unit tests for each game module to ensure functionality.
Install required packages: pip install -r requirements.txt
Run main.py to access the GameHub: python main.py
You can run all tests by executing: python -m unittest discover -s tests