Bug #1242 » 0045-AI-Check-is_action_enabled_unit_on_stack-in-dai_ramp.patch
ai/default/daiunit.c | ||
---|---|---|
CHECK_UNIT(punit);
|
||
if (can_unit_attack_tile(punit, NULL, ptile)
|
||
&& (pdef = get_defender(nmap, punit, ptile, NULL))) {
|
||
&& (pdef = get_defender(nmap, punit, ptile, NULL))
|
||
/* Action enablers might prevent attacking */
|
||
&& is_action_enabled_unit_on_stack(nmap, ACTION_ATTACK,
|
||
punit, ptile)) {
|
||
/* See description of kill_desire() about these variables. */
|
||
int attack = unit_att_rating_now(punit);
|
||
int benefit = stack_cost(punit, pdef);
|
- « Previous
- 1
- …
- 3
- 4
- 5
- Next »