Commit 9c114a0b by BellCodeEditor

save project

parent 7be586f1
Showing with 3 additions and 2 deletions
...@@ -44,8 +44,9 @@ class Player(Hero): ...@@ -44,8 +44,9 @@ class Player(Hero):
if self.hp+60 < self.max_hp: if self.hp+60 < self.max_hp:
self.hp+=blood self.hp+=blood
else: else:
plus_hp=self.max_hp-self.hp blood=self.max_hp-self.hp
self.hp+=plus_hp self.hp+=blood
print(self.name+"使用了治疗,血量增加:", int(blood),",目前的血量为:",self.hp)
houyi = Player("射手", "后羿") houyi = Player("射手", "后羿")
yase = Hero("垭瑟") yase = Hero("垭瑟")
print("*"*30) print("*"*30)
......
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