So we start by the Day Night system. An in game Day Night cycle 24 hours is 1 hour equally distributed with the day and night. To balance the game, as predators can be seen more during the night for hunting.
Considering that, that gives us 3600 seconds.
Now the player Stats. Health - the HP of player increases by 0.00002 / second. Which will replenish in 50,000 seconds. There are item pickups that will boost this tremendously also eating food items will replenish HP.
Energy / Stamina – Each animal runs at a different speed and also has varied stamina. However for the Player we have a Levelling system, more on that later. But there will be a different base value to start from for each animal. Hunger – The animals in real life have a certain amount of food they need to eat per day to live a healthy life. If they don’t find food they have a buffer number of days till they survive but also depleting in Health. Same is in the game. - But we do not calculate it per day as each day is an hour long and we don’t wish to bore the player out with no tasks at hand. So, the depletion / stat check is done 10 times a day. 10 times because it gave an even distribution of the system.
For ex. A lion can stay hungry for 14 days and can eat 40kgs at one go. Now in the game the player will be able to easily find a stag or rabbit in 14 days. Also, I do not expect a player to be playing for 14 HOURS without hunting. Which is the most interesting part of the game.
Thirst – The animals aren’t very needy of water but do drink ample amounts at a time. Also there isn’t sufficient data available for all animals. Most of it will be calculated by myself.
Strength – This stat will not increase by itself, but it will be gained by each level passed (more on levelling system below). Strength will have no effect on attacking prowess of the animal but on defense. More on the attack and defense logic after the Levelling system. Intelligence – This stat does not have any use as of now, but it does increment and might be used for future purposes.
The animals will gain exp points by eating food items. Doesn’t matter if harmful or good food. They will gain exp points in any case.
Exp points for each animal have the same formula. The same formula allows the Herbivores and Carnivores to settle on the right path like in real life.
Carnivores eat meat and a lot of it. Which will allow them to gain levels quickly but will slow on the level gaining after a set of levels.
Herbivores however eat plants and for the sake of comfort, I’ve put all plants to a weigh of 2kg. Still the herbivores who are grazers will be eating a lot but won’t reach the levels the Carnivores are at. Making them weak and vulnerable.
What does the Levelling System effect ?
Size and Speed are interlinked as we are using Root Motion, as size grows the speed will increase. This will only affect babies.
Weight gain will be different for each animal on each level. The weight of the baby will be assigned in the beginning and the weight gain will be the Minimum weight an adult has divided by 6. As 6 is the most common level that the player can achieve, Carnivore or Herbivore.
Stamina this will start off slow and will really affect the adult animal.
Strength will have a gain of +0.05 per each level.
Eating Capacity will increase by total amount the animal eats per day divided by 6. FIGHTING SYSTEM
We press Q to find a food item. The green items are herbivores / plants and Red are carnivores.
Plants can be just eaten up but Animals need to be killed first. Animals right now use Sight vision to see danger or if you strike them they feel the danger and they will either RUN or FIGHT.
If they choose to fight that depends on your Strength level, Weight and Health.
If they seem underpowered they will Run.
Damage function acts like this. When attacking the concerned paws are checked for the duration of the animation for any collisions. Then we calculate the weight of the attacker * the speed at which it is attacking. That information is the Damage.
Receiving Damage, the weight of the attacked animal * strength x 10 gives the defense buffer and that is subtracted from the Damage info sent.
So that is all I wanted to write today. Hope I was clear and I hope the mechanics and calculations I’ve thought of so far are balanced and work in the game.
All of the mentioned above is implemented already in the game.