void Update() { if (Vector3.Distance(transform.position, player.transform.position) <= 2.5f) { if (!icon) { icon = hud.AddInteractionMarker(); } hud.SetMarkerPosition(icon, transform.position); if (Input.GetButtonDown(ControllerInput.INTERACT_BUTTON)) { Interact(); } } else { hud.RemoveMarker(icon); } }