Spielerando

Grade a battle by what each side lost, so a lucky scout kill is not a triumph

After a fight the game shows a rating and hands out rank points. Counting only heads rewards trading ten cheap soldiers for one expensive one, and a tiny skirmish can look like a great victory. This entry shows a grade based on the value lost on each side with a minimum size, and handles the cases where nothing happened.

Why this works

A fight is judged by what each side gave up compared with what it gained, and a unit's worth is what it cost, not how many there were. Comparing the two losses directly stays fair when one side loses nothing, and a minimum size stops tiny clashes looking grand.

When not to use it

Skip it when the fight is about something other than losses, such as holding a place, escorting someone or surviving a timer. Grade those by whether the goal was met, since a costly win can still be the right one.

In the full entry

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

Say this to your AI

Use the Spielerando entry "Grade a battle by what each side lost, so a lucky scout kill is not a triumph" (read_entry battle-result-grade-from-lost-value-not-head-count) 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