Spielerando

Split an area's ore into veins so the total comes out exactly right

If every vein in an area rolls its own size, one area has far too much and the next too little, and the world economy drifts with luck. Fixing the total per area and dividing it up keeps the economy steady, but splitting a number into whole parts is where ore quietly goes missing.

Why this works

A promise about a total is only kept if no part is lost on the way, and rounding each share alone always loses or invents some. Handing the leftover pieces to the largest fractions makes the parts add up exactly, with no one cheated by chance.

When not to use it

Skip it when the total does not have to be exact, for instance in an endless world where veins just appear by chance and nobody counts. There, a simple random size per vein is easier and costs you nothing in feel.

In the full entry

  • What to build, step by step
  • Starting values and the reason for each
  • 4 common mistakes and the fix
  • 19 lines of example code with 3 checks that pass
  • How your AI shows you that it works

Say this to your AI

Use the Spielerando entry "Split an area's ore into veins so the total comes out exactly right" (read_entry ore-vein-sizes-that-add-up-exactly) in my game. Build it step by step, and show me how you checked that it works.

Or skip this and connect the MCP: your AI then finds all of this by itself.Connect the MCP