Commit 0ad564f5 by BellCodeEditor

save project

parent 9223d2c8
Showing with 7 additions and 1 deletions
...@@ -6,5 +6,11 @@ class Hero: ...@@ -6,5 +6,11 @@ class Hero:
a.name=name a.name=name
yase=Hero(300,20,"亚瑟") yase=Hero(300,20,"亚瑟")
houyin=Hero(250,23,"后羿") houyin=Hero(250,23,"后羿")
print(houyin.name) def A():
yase.hp=yase.hp+50
yase.level=yase.level+1
yase.attack=yase.attack+4
A()
A()
print(yase.hp)
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