Commit 44e74873 by BellCodeEditor

save project

parent 3f97e085
Showing with 11 additions and 2 deletions
......@@ -9,4 +9,13 @@ hy=Hero('hy',250,23)
k=Hero('K',5600,199)
print(yase.attack)
print(hy.attack)
print(k.attack)
\ No newline at end of file
print(k.attack)
def upgrade():
hy.level+=1
hy.hp+=50
hy.attack+=10
hy=Hero("后羿,300,20")
print("后羿的初始血量值为:",hy.hp)
upgrade()
upgrade()
print("升级两次后,后羿的血量值为:",hy.hp)
\ No newline at end of file
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment