Remove Player.CanViewActor and .CanTargetActor.
This commit is contained in:
@@ -90,7 +90,9 @@ namespace OpenRA.Mods.Common.Activities
|
||||
// HACK: This would otherwise break targeting frozen actors
|
||||
// The problem is that Shroud.IsTargetable returns false (as it should) for
|
||||
// frozen actors, but we do want to explicitly target the underlying actor here.
|
||||
if (!attack.Info.IgnoresVisibility && type == TargetType.Actor && !Target.Actor.Info.HasTraitInfo<FrozenUnderFogInfo>() && !self.Owner.CanTargetActor(Target.Actor))
|
||||
if (!attack.Info.IgnoresVisibility && type == TargetType.Actor
|
||||
&& !Target.Actor.Info.HasTraitInfo<FrozenUnderFogInfo>()
|
||||
&& !Target.Actor.CanBeViewedByPlayer(self.Owner))
|
||||
return NextActivity;
|
||||
|
||||
// Drop the target once none of the weapons are effective against it
|
||||
|
||||
Reference in New Issue
Block a user