Commit efa2dad2 by BellCodeEditor

save project

parent d2c38a84
Showing with 6 additions and 5 deletions
......@@ -5,14 +5,14 @@ class Hero:
self.hp=hp
self.attack=attack
def uprgrade():
yase.level+=50
yase.hp+=50
yase.attack+=50
def uprgrade(self):
self.level+=50
self.hp+=50
self.attack+=50
yase=Hero("亚瑟",300,50)
#houyi=Hero("后羿",300,50)
print(yase.hp)
#print(houyi.attack)
uprgrade()
yase.uprgrade()
print(yase.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