Read observed target contacts only from daemon

This commit is contained in:
Meta Vens 2026-06-21 18:26:58 +01:00
commit ff4916df26
2 changed files with 7 additions and 8 deletions

View file

@ -3236,7 +3236,7 @@ public class ActionGameManager : MonoBehaviour
return targetEntity;
}
return observer?.Target.Value;
return null;
}
private float GetObservedInfoGathered(Entity observer, Entity target)
@ -3244,11 +3244,7 @@ public class ActionGameManager : MonoBehaviour
if (TryQueryDaemonEntityContact(observer, target, out var contact))
return (float)contact.InfoGathered;
return observer != null &&
target != null &&
observer.EntityInfoGathered.TryGetValue(target, out var infoGathered)
? infoGathered
: 0f;
return 0f;
}
private bool IsObservedHostileContact(Entity observer, Entity target)
@ -3256,7 +3252,7 @@ public class ActionGameManager : MonoBehaviour
if (TryQueryDaemonEntityContact(observer, target, out var contact))
return contact.Hostile;
return target != null && target.IsHostileTo(observer);
return false;
}
private void ReconcileVisibleTargetIndicators()