Spielerando

Resupply units so the emptiest are topped up first

A supply wagon with too little ammunition for everyone should not fill the first squad to the brim while the last one has nothing. This entry hands out the load so that the squad running emptiest, compared with its own size, always gets the next unit, until the wagon is empty.

Why this works

Need is relative to size. A squad with room for little and a squad with room for a lot are hurt differently by the same shortage, so handing the next unit to whoever is emptiest compared with its own size lets all levels rise together.

When not to use it

Skip it when some units matter far more than others, such as a leader or a siege engine that must be filled first. Then rank by importance, as in rationing by priority, rather than by how empty a unit is.

In the full entry

  • What to build, step by step
  • Starting values and the reason for each
  • 4 common mistakes and the fix
  • 17 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 "Resupply units so the emptiest are topped up first" (read_entry resupply-lowest-fill-first) 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