Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import random
- playerHP=10
- playerMaxHP=100
- appleCount=10
- def heal(appleCount, PlayerHP,playerMaxHP):
- appleEat=random.range(0,appleCount)
- for X in range appleEat
- healAmount=random.randrange(11,16)
- appleCount-=1
- newHP=playerHP+healAmount
- if newHP>=playerMaxHP:
- newHP=playerMaxHP
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement