IsVisible patched to know about GPS
This commit is contained in:
@@ -146,6 +146,9 @@ namespace OpenRA
|
|||||||
|
|
||||||
public static bool IsVisible(this Actor a)
|
public static bool IsVisible(this Actor a)
|
||||||
{
|
{
|
||||||
|
if (a.World.LocalPlayer.Shroud.Disabled)
|
||||||
|
return true;
|
||||||
|
|
||||||
var shroud = a.World.WorldActor.traits.Get<Shroud>();
|
var shroud = a.World.WorldActor.traits.Get<Shroud>();
|
||||||
if (!Shroud.GetVisOrigins(a).Any(o => shroud.exploredCells[o.X, o.Y])) // covered by shroud
|
if (!Shroud.GetVisOrigins(a).Any(o => shroud.exploredCells[o.X, o.Y])) // covered by shroud
|
||||||
return false;
|
return false;
|
||||||
|
|||||||
Reference in New Issue
Block a user