Commit c3331d1c by BellCodeEditor

save project

parent 3d33959f
Showing with 11 additions and 16 deletions
...@@ -4,22 +4,16 @@ class Houre: ...@@ -4,22 +4,16 @@ class Houre:
self.hp=hp self.hp=hp
self.attack=attack self.attack=attack
self.mp=mp self.mp=mp
def ufh(self):
self.level=self.level+1
self.hp=self.hp+50
self.attack=self.attack+10
self.mp=self.mp+5
lan=Houre(1000,890,999999) lan=Houre(1000,890,999999)
lubanqihao=Houre(250,500,999999)
print("l",lan.hp)
print("7",lubanqihao.hp)
def ufh():
lan.level=lan.level+1
lan.hp=lan.hp+50
lan.attack=lan.attack+10
lan.mp=lan.mp+5
def csj():
lubanqihao.level=lubanqihao.level+1
lubanqihao.hp=lubanqihao.hp+50
lubanqihao.attack=lubanqihao.attack+10
lubanqihao.mp=lubanqihao.mp+5
ufh()
print(lan.hp) print(lan.hp)
csj() lan.ufh()
print(lan.hp)
lubanqihao=Houre(250,500,999999)
print(lubanqihao.hp) print(lubanqihao.hp)
lubanqihao.ufh()
print(lubanqihao.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