Commit c6c3ac79 by BellCodeEditor

save project

parent 22354288
Showing with 19 additions and 0 deletions
class Hero:
def __init__(self,name,level,HP,attack):
self.name=''
self.level=1
self.HP=100
self.attack=20
def LevelUp(self):
self.HP-=200
self.level+=1
self.attack-=100
GZA = Hero('GZA',-1000,0.0001,-1000000)
for i in range(10):
GZA.LevelUp()
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