From 1aae7b41dcfa154cd65f03120d95b2da5b0c81b0 Mon Sep 17 00:00:00 2001 From: JohnCorby Date: Sun, 16 Oct 2022 18:42:52 -0700 Subject: [PATCH] more marker visibility things --- QSB/Player/PlayerHUDMarker.cs | 6 +++++- QSB/Player/PlayerMapMarker.cs | 7 ++++++- 2 files changed, 11 insertions(+), 2 deletions(-) diff --git a/QSB/Player/PlayerHUDMarker.cs b/QSB/Player/PlayerHUDMarker.cs index 82131999..ebcc7e04 100644 --- a/QSB/Player/PlayerHUDMarker.cs +++ b/QSB/Player/PlayerHUDMarker.cs @@ -34,7 +34,11 @@ public class PlayerHUDMarker : HUDDistanceMarker return false; } - return _player.IsReady && !_player.IsDead && (!_player.InDreamWorld || QSBPlayerManager.LocalPlayer.InDreamWorld) && _player.Visible; + return _player.IsReady && + !_player.IsDead && + _player.Visible && + _player.InDreamWorld == QSBPlayerManager.LocalPlayer.InDreamWorld && + _player.IsInMoon == QSBPlayerManager.LocalPlayer.IsInMoon; } private void Update() diff --git a/QSB/Player/PlayerMapMarker.cs b/QSB/Player/PlayerMapMarker.cs index 4d35a734..6904b095 100644 --- a/QSB/Player/PlayerMapMarker.cs +++ b/QSB/Player/PlayerMapMarker.cs @@ -60,7 +60,12 @@ public class PlayerMapMarker : MonoBehaviour var playerScreenPos = Locator.GetActiveCamera().WorldToScreenPoint(transform.position); var isInfrontOfCamera = playerScreenPos.z > 0f; - return _player.IsReady && !_player.IsDead && (!_player.InDreamWorld || QSBPlayerManager.LocalPlayer.InDreamWorld) && _player.Visible && isInfrontOfCamera; + return isInfrontOfCamera && + _player.IsReady && + !_player.IsDead && + _player.Visible && + _player.InDreamWorld == QSBPlayerManager.LocalPlayer.InDreamWorld && + _player.IsInMoon == QSBPlayerManager.LocalPlayer.IsInMoon; } public void LateUpdate()