Advertisement
Schleimpilz

Untitled

May 20th, 2019
87
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.33 KB | None | 0 0
  1. import random
  2.  
  3. playerHP=10
  4. playerMaxHP=100
  5. appleCount=10
  6. def heal(appleCount, PlayerHP,playerMaxHP):
  7. appleEat=random.range(0,appleCount)
  8. for X in range appleEat
  9. healAmount=random.randrange(11,16)
  10. appleCount-=1
  11. newHP=playerHP+healAmount
  12. if newHP>=playerMaxHP:
  13. newHP=playerMaxHP
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement