![Villager Comfort](https://media.forgecdn.net/avatars/thumbnails/624/28/256/256/638019003088260489.png)
Track villager social activity for comfort
cactusdualcore opened this issue · 0 comments
Nobody wants to be alone and left out. Villager comfort should be affected by social interactions.
Too prevent stupid villagers from dying to loneliness, this has a prerequisite on a "want for social interaction" which makes villagers look for nearby villagers to talk to.
For the comfort, I think a X-times-per-last-Y-days should be fine, so the comfort can be calculated like this
import java.lang.Math;
private final float MAX_COMFORT_FROM_SOCIAL = 10.0;
float comfort = MAX_COMFORT_FROM_SOCIAL * (interactions / max_interactions);
max_interactions
is a constant (or read from the config) and I don't know how to track interactions
. Note that villagers should start with a non-zero value for ìnteractions
or they'll be miserable in the beginning.