Struct
Food
Food that a sloth can consume.
Sloths love to eat the leaves and twigs they find in the rainforest canopy as they
slowly move around. To feed them these items, you can use the Twig,
Regular_Leaf and Large_Leaf default foods.
Sloth.sloth_eat(sloth, Sloth.SlothFoodEnum.Large_Leaf)
You can also define your own custom sloth food by providing a name and the
energy level. When the sloth eats your custom food, their energy level increases
by the energy of the food:
flower := Food{name = "Flower Bud", energy = 10}
Sloth.sloth_eat(sloth, flower)
Declaration
Food :: struct
Values
name
The name of the food.
Declaration
name: string
energy
The amount of energy the food contains.
When sloths metabolize the food they eat, their Sloth/energy_level
increases by the amount of energy the food contains.
Declaration
energy: int