24 #define FINISH_HIM_CITY_COUNT 5
29 struct unit *attacker);
37 struct unit *punit,
bool igwall);
44 struct city *pcity,
int danger,
struct unit_list *() player_unit_list_getter(struct player *pplayer)
void dai_assess_danger_player(struct ai_type *ait, struct player *pplayer, const struct civ_map *dmap)
Call assess_danger() for all cities owned by pplayer.
int assess_defense(struct ai_type *ait, struct city *pcity)
Estimate defense strength of city.
struct unit_type * dai_choose_defender_versus(struct city *pcity, struct unit *attacker)
Choose the best unit the city can build to defend against attacker v.
struct adv_choice * military_advisor_choose_build(struct ai_type *ait, struct player *pplayer, struct city *pcity, const struct civ_map *mamap, player_unit_list_getter ul_cb)
This function selects either a defender or an attacker to be built.
int dai_unit_attack_desirability(struct ai_type *ait, const struct unit_type *punittype)
How much we would want that unit to attack with?
bool dai_process_defender_want(struct ai_type *ait, struct player *pplayer, struct city *pcity, int danger, struct adv_choice *choice)
What would be the best defender for that city? Records the best defender type in choice.
int dai_unit_defence_desirability(struct ai_type *ait, const struct unit_type *punittype)
How much we would want that unit to defend a city? (Do not use this function to find bodyguards for s...
int assess_defense_quadratic(struct ai_type *ait, struct city *pcity)
Need positive feedback in m_a_c_b and bodyguard routines.
int assess_defense_unit(struct ai_type *ait, struct city *pcity, struct unit *punit, bool igwall)
One unit only, mostly for findjob; handling boats correctly.