Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- import random
- class Tamagochi:
- featerus = [ 0, 100, 0, 100, 0]
- # age, healthbar, exhausted, hunger, bored
- animalType = ["cat", "dog", "bunny", "frog", "dragon"]
- food = []
- def __init__(self):
- pets = {"mittzy" : [animalType[0], featrus[2, 100, 0, 5, 20]]}
- def eatingTime(featrus):
- if(featerus[3] > 80):
- print("{} לא רעב, נסה מאוחר יותר".format(pets.keys))
- else:
- print("הזמן לאכול!, תבחר מה תרצה להאכיל את {}".format(pets.keys))
- print(food)
- choice = int(input())
- n1 = random.randint(0, 10)
- n2 = random.randint(0, 10)
- print("{} צריך לאכול {} אבל, הוא אכל רק {}. כמה נשאר לו לאכול?".format(pets.keys, n1, n2))
- answer = int(input())
- if (n1-n2 == answer):
- print("כל הכבוד!!!! {} אכל את כל האוכל, הוא כבר לא רעב".format(pets.keys))
- featerus[3] = 100
- else:
- print("אופס! התשובה היתה {}, {} עדיין רעב".format(n1-n2,pets.keys))
- featerus[3] += 10
- def playingTime(featrus):
- def sleepingTime(featrus):
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement