Show ghosts popups etc through walls (#8077)

* Show ghosts popups etc through walls

* Stage moment

* crashes
This commit is contained in:
metalgearsloth
2022-05-12 21:18:38 +10:00
committed by GitHub
parent 40361ec0ad
commit 6903209a31
4 changed files with 25 additions and 14 deletions

View File

@@ -102,6 +102,14 @@ namespace Content.Shared.Examine
return ExamineRange;
}
/// <summary>
/// True if occluders are drawn for this entity, otherwise false.
/// </summary>
public bool IsOccluded(EntityUid uid)
{
return TryComp<SharedEyeComponent>(uid, out var eye) && eye.DrawFov;
}
public static bool InRangeUnOccluded(MapCoordinates origin, MapCoordinates other, float range, Ignored? predicate, bool ignoreInsideBlocker = true, IEntityManager? entMan = null)
{
// No, rider. This is better.