Commit 539d375b by BellCodeEditor

save project

parent 8d75fbc4
Showing with 5 additions and 5 deletions
......@@ -6,10 +6,10 @@ class Hero:
self.attck=attck
yase=Hero('亚瑟',300,20)
houyi=Hero('后羿',240,30)
def upgradge():
def upgrade():
yase.level+=1
yase.hp+=50
yase.attck+=4
upgradge()
print(yase.hp)
print(houyi.hp)
\ No newline at end of file
upgrade()
upgrade()
print(yase.level)
\ 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