Feature #1169 » 0024-Unhardcode-wld.map-from-city_support.patch
common/city.c | ||
---|---|---|
}
|
||
/**********************************************************************//**
|
||
Calculate upkeep costs. This builds the pcity->usage[] array as well
|
||
Calculate upkeep costs. This builds the pcity->usage[] array as well
|
||
as setting some happiness values.
|
||
**************************************************************************/
|
||
static inline void city_support(struct city *pcity)
|
||
static inline void city_support(const struct civ_map *nmap,
|
||
struct city *pcity)
|
||
{
|
||
int free_unhappy, martial_law_each;
|
||
const struct civ_map *nmap = &(wld.map);
|
||
/* Clear all usage values. */
|
||
memset(pcity->usage, 0, O_LAST * sizeof(*pcity->usage));
|
||
... | ... | |
/* Calculate the tile_cache[] values. */
|
||
city_tile_cache_update(nmap, pcity);
|
||
/* manage settlers, and units */
|
||
city_support(pcity);
|
||
city_support(nmap, pcity);
|
||
}
|
||
/* Calculate output from citizens (uses city_tile_cache_get_output()). */
|
- « Previous
- 1
- 2
- Next »