Make the ICrushable interface a bit more sane, plus correct defaults for infantry

This commit is contained in:
Paul Chote
2009-12-23 02:55:37 -08:00
parent 77f56405b8
commit eae88e7774
3 changed files with 6 additions and 19 deletions

View File

@@ -243,9 +243,7 @@ namespace OpenRa.Game
{
return a != null &&
a.traits.WithInterface<ICrushable>()
.Any(c => c.CrushableBy(umt) &&
((c.IsCrushableByEnemy() && a.Owner != Game.LocalPlayer) ||
(c.IsCrushableByFriend() && a.Owner == Game.LocalPlayer)));
.Any(c => c.IsCrushableBy(umt, a.Owner));
}
public static bool IsWater(int2 a)