Remove IPreventsTeleport interface.

MadTank is changed to use conditions instead.
This has a side-benefit of disabling the move
cursor while deployed.
This commit is contained in:
Paul Chote
2018-08-12 21:30:41 +01:00
parent e6d552eee7
commit 6f864b055d
4 changed files with 19 additions and 9 deletions

View File

@@ -87,8 +87,7 @@ namespace OpenRA.Mods.Cnc.Traits
foreach (var t in tiles)
units.UnionWith(Self.World.ActorMap.GetActorsAt(t));
return units.Where(a => a.TraitsImplementing<Chronoshiftable>().Any(cs => !cs.IsTraitDisabled) &&
!a.TraitsImplementing<IPreventsTeleport>().Any(condition => condition.PreventsTeleport(a)));
return units.Where(a => a.TraitsImplementing<Chronoshiftable>().Any(cs => !cs.IsTraitDisabled));
}
public bool SimilarTerrain(CPos xy, CPos sourceLocation)