Skip to main content

health_after

Function health_after 

Source
pub fn health_after(
    e: u32,
    health: f32,
    age: f32,
    adult_age: f32,
    at_school: bool,
    max: f32,
) -> f32
Expand description

A citizen’s health after an interval’s events: up 0.5 for a good interval, down for a poor one, down 1 for each of the two worst events, down 0.25 for an adult not at school with no work done; then no lower than 0 and no higher than the maximum.

Measured: tools/emu/health.py (the original on 2,000 cases, NaN ages and healths among them).

Original: FUN_140117e60.