Function compose_character_attrs

Source
pub fn compose_character_attrs(
    config: &GameConfig,
    level: i64,
    inventory: &[Item],
    pets: &[Pet],
) -> Result<(AttrMap, i64), String>
Expand description

Compose the char-level + items + pets attribute map (the input to power_from_attrs) plus the summed per-item power_bonus jitter. Extracted from character_attrs_power so character_power can reuse the composed attrs for the honest ability EHP cap (it needs hp/attack).