Skip to content

Extract weekly polling resolution into the pure simulation layer #5

Description

@aribradshaw

Goal

Reduce the contributor cost of changing weekly polling without destabilizing the campaign facade.

Suggested boundary

Extract one polling-resolution phase from GameEngine.ts into a pure function under src/game/simulation/. Accept immutable state, planned actions, and an injected random source. Return the next polling state plus explanatory deltas for the weekly recap.

Acceptance criteria

  • No global Math.random() is introduced.
  • Input maps are not mutated.
  • Existing campaign outcomes remain inside documented calibration bounds.
  • Focused determinism, bounds, and no-NaN tests are added.
  • GameEngine delegates to the new function.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    architectureSimulation boundaries and maintainabilityenhancementNew feature or requesthelp wantedExtra attention is needed

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions