Commit 3d33959f by BellCodeEditor

save project

parent 52392d36
Showing with 16 additions and 1 deletions
class Houre:
def __init__(self,hp,attack,mp):
self.level=1
self.hp=hp
self.attack=attack
self.mp=mp
lan=Houre(1000,890,999999)
lubanqihao=Houre(250,500,999999)
print(lubanqihao.hp)
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)
csj()
print(lubanqihao.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