public override void Interact(GameObject originator, Vector3 position, string hand) { PlayerNetworkActions pna = PlayerManager.LocalPlayer.GetComponent <PlayerNetworkActions>(); // Close the door if it's open if (doorController.IsOpened && allowInput) { pna.CmdTryCloseDoor(gameObject); allowInput = false; StartCoroutine(DoorInputCoolDown()); } // Attempt to open if it's closed if (doorController != null && allowInput) { pna.CmdCheckDoorPermissions(gameObject, PlayerManager.LocalPlayerScript.gameObject); allowInput = false; StartCoroutine(DoorInputCoolDown()); } }