Fix bug #12630...

...(Swarm number of attacks not updated in unit overview) At least for
the standard case. The code checking max and min seems inconsistent
and is not documented in wiki. I will clean this part later.
This commit is contained in:
Ali El Gariani 2008-11-28 21:25:42 +00:00
parent 41baed939f
commit afb6433d6f

View File

@ -238,7 +238,7 @@ Units cannot be killed by poison alone. The poison will not reduce it below 1 HP
}
int nattacks = at_it->num_attacks();
// Compute swarm attacks:
unit_ability_list swarm = at_it->get_specials("attacks");
unit_ability_list swarm = at_it->get_specials("swarm");
if(!swarm.empty()) {
int swarm_max_attacks = swarm.highest("attacks_max",nattacks).first;
int swarm_min_attacks = swarm.highest("attacks_min").first;