update/revolt: Fix mil count for che move after getting caught
When military catch che, their their count isn't updated for their losses. The count is later used when che consider moving to an adjacent sector. This could conceivably make them move instead of stay. Broken when Chainsaw 3 added land units. Fix it. Note that the sector's military count includes land units, but the adjacent sectors' doesn't. Should be improved some day; add a TODO comment. Signed-off-by: Markus Armbruster <armbru@pond.sub.org>
This commit is contained in:
parent
849af9e06c
commit
e55fb2227b
1 changed files with 2 additions and 0 deletions
|
@ -295,6 +295,7 @@ guerrilla(struct sctstr *sp)
|
|||
}
|
||||
}
|
||||
take_casualties(sp, mc);
|
||||
mil -= mc;
|
||||
recruit = 0;
|
||||
}
|
||||
}
|
||||
|
@ -362,6 +363,7 @@ domove:
|
|||
else
|
||||
min_mil = mil;
|
||||
/* search adjacent sectors for a nice one */
|
||||
/* TODO consider land units in addition to mil */
|
||||
for (n = 1; n <= 6; n++) {
|
||||
nsp = getsectp(sp->sct_x + diroff[n][0],
|
||||
sp->sct_y + diroff[n][1]);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue