Fix attack behaviour of disabled units.

This commit is contained in:
Lars Beckers
2019-03-30 14:46:17 +00:00
committed by reaperrr
parent 1bb319425b
commit e6750bf19c
4 changed files with 21 additions and 7 deletions

View File

@@ -50,7 +50,7 @@ namespace OpenRA.Mods.D2k.Traits
Info = info;
}
public override void DoAttack(Actor self, Target target, IEnumerable<Armament> armaments = null)
public override void DoAttack(Actor self, Target target)
{
// This is so that the worm does not launch an attack against a target that has reached solid rock
if (target.Type != TargetType.Actor || !CanAttack(self, target))
@@ -86,6 +86,11 @@ namespace OpenRA.Mods.D2k.Traits
targetIsHiddenActor = false;
return target;
}
protected override void DoAttack(Actor self, AttackFrontal attack, IEnumerable<Armament> armaments)
{
attack.DoAttack(self, target);
}
}
}
}