Commit 54836231 by BellCodeEditor

save project

parent faf65332
Showing with 17 additions and 5 deletions
class Hore: class Hero:
def __init__(self): def __init__(self,name,hp,attack):
self.level=1 self.level=1
self.hp=200 self.name=name
self.attack=20 self.hp=hp
\ No newline at end of file self.attack=attack
yase=Hero("亚瑟",300,20)
def ShengJi():
yase.level=yase.level+1
yase.hp=yase.hp+50
yase.attack=yase=attack+10
ShengJi()
ShengJi()
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