empserver/tests/update
Markus Armbruster bb495cac60 budget: Fix military count (but not yet their pay)
When we add up military payroll, we discard fractions.  Payroll is
therefore lower than it should be, but I'm not fixing that now.  The
number of military budget reports is actually computed from payroll,
and therefore also low.

The obvious way to fix that would be adding another out parameter to
tax() and upd_slmilcosts().  However, budget and the update track cost
and count of numerous things (sector products, unit maintenance and
building, ...), and it's time for a common way to do that.

Create struct budget_item for tracking cost and count, and struct
budget nat_budget[MAXNOC] for tracking a nation's budget.  Track only
military for now; more to follow.

This fixes the military count.  The cost of military remains low,
because we discard fractions exactly as before.

Signed-off-by: Markus Armbruster <armbru@pond.sub.org>
2017-08-06 19:59:59 +02:00
..
01-1 update: Don't use materials and work destroyed by che or plague 2017-08-06 19:59:58 +02:00
02-2 budget: Fix military count (but not yet their pay) 2017-08-06 19:59:59 +02:00
03-3 tests/update: New; exercises the update 2017-08-06 14:04:15 +02:00
04-4 budget: Fix level prod. forecast when required level is too low 2017-08-06 19:59:58 +02:00
05-5 tests/update: New; exercises the update 2017-08-06 14:04:15 +02:00
06-6 tests/update: New; exercises the update 2017-08-06 14:04:15 +02:00
07-7 tests/update: New; exercises the update 2017-08-06 14:04:15 +02:00
99-POGO update: Don't use materials and work destroyed by che or plague 2017-08-06 19:59:58 +02:00
final.xdump update: Fix avail roll over for stopped or broke sectors 2017-08-06 19:59:59 +02:00
journal.log budget: Fix military count (but not yet their pay) 2017-08-06 19:59:59 +02:00
server.log tests/update: New; exercises the update 2017-08-06 14:04:15 +02:00
setup-POGO update: Saner rounding of unit building money and work 2017-08-06 19:59:58 +02:00