English | 简体中文
You are a Doggo trainer, and you have to fight against other Doggo trainers.
You have to choose your only one Doggo from the three starter Doggos.
Battle with other Doggo trainers! And become the best Doggo trainer in the world!
Doggo-Fight is my final project of the course CS50P. It is a game that you can choose your Doggo and fight with other Doggo trainers.
CS50P Final Project Specification
- Your project must be implemented in Python.
- Your project must have a
main
function and three or more additional functions. At least three of those additional functions must be accompanied by tests that can be executed withpytest
.- Your
main
function must be in a file calledproject.py
, which should be in the “root” (i.e., top-level folder) of your project. - Your 3 required custom functions other than
main
must also be inproject.py
and defined at the same indentation level asmain
(i.e., not nested under any classes or functions). - Your test functions must be in a file called
test_project.py
, which should also be in the “root” of your project. Be sure they have the same name as your custom functions, prepended withtest_
(test_custom_function
, for example, wherecustom_function
is a function you’ve implemented inproject.py
). - You are welcome to implement additional classes and functions as you see fit beyond the minimum requirement.
- Your
- Implementing your project should entail more time and effort than is required by each of the course’s problem sets.
- Any
pip
-installable libraries that your project requires must be listed, one per line, in a file calledrequirements.txt
in the root of your project.
Video Demo: Click me
- Choose your dog
- Name your dog
- The dog with higher speed will act first
- Choose your action: attack or defend? Your choice!
- Repeat the process until one of the dog is defeated
- Every time a dog attacks, its charge level will increase by 1
- Every time a dog defends, its charge level will decrease by 1
- The charge level of a dog will affect the damage it deals
- One dog can have at most 10 charge level
- When a dog defends, its defense value will double, until it attacks again
- Python 3.10+
- This is because I used the
match
statement in the code. It is adjustable since this statement only occurs a few time and can be replaced byif-elif-else
statement.
- This is because I used the
- Pygame 2.5.2
- The version is not tested. This is the version I used to develop this game.
- Add more Doggos
- Rewrite the battle system
- Rewrite the logic of displaying damage