pub fn grant_unlocked_laws(
config: &GameConfig,
cores: &mut CoresState,
side: WorldSide,
) -> usizeExpand description
Grants every law side’s core has earned at its CURRENT level, and reports
how many were new.
Idempotent by construction: an owned law is skipped whole, so re-upgrading, replaying an event or backfilling never adds a copy. That matters because copies are the law upgrade currency — a duplicate grant would be free progression, not a cosmetic double.
A granted law is a plain level-1 OwnedLaw with zero copies, unslotted:
identical to what the first random copy drop used to produce, so nothing
downstream has to tell a granted law from a dropped one.