Fred: fix bug in attack and counter attack acceptability rating

The attack and defense rating (which are a measure for the damage taken
by the attacker and defender) can go negative if a unit is likely to
level up.  This was messing up the damage ratio calculation, resulting
in Fred taking some suicidal risks sometimes.