![]() |
Freeciv21
Develop your civilization from humble roots to a global empire
|
Include dependency graph for aihunt.h:
This graph shows which files directly or indirectly include this file:Go to the source code of this file.
Functions | |
| void | dai_hunter_choice (struct ai_type *ait, struct player *pplayer, struct city *pcity, struct adv_choice *choice, bool allow_gold_upkeep) |
| Check if we want to build a hunter. More... | |
| bool | dai_hunter_qualify (struct player *pplayer, struct unit *punit) |
| Does this unit qualify as a hunter? More... | |
| int | dai_hunter_manage (struct ai_type *ait, struct player *pplayer, struct unit *punit) |
| Manage a (possibly virtual) hunter. More... | |
| void dai_hunter_choice | ( | struct ai_type * | ait, |
| struct player * | pplayer, | ||
| struct city * | pcity, | ||
| struct adv_choice * | choice, | ||
| bool | allow_gold_upkeep | ||
| ) |
Check if we want to build a hunter.
Definition at line 262 of file aihunt.cpp.
Referenced by military_advisor_choose_build().
Manage a (possibly virtual) hunter.
Return the want for building a hunter like this. If we return 0, then we have nothing to do with the hunter. If we return -1, then we succeeded, and can try again. If we return > 0 then we are hunting but ran out of moves (this is also used for construction want).
We try to keep track of our original target, but also opportunistically snatch up closer targets if they are better.
We set punit->server.ai->target to target's id.
Definition at line 445 of file aihunt.cpp.
Referenced by dai_manage_military(), and eval_hunter_want().
Does this unit qualify as a hunter?
Definition at line 297 of file aihunt.cpp.
Referenced by dai_hunter_find(), dai_hunter_missile_want(), and dai_manage_military().