Beispiel #1
0
        public void ActivatePlayerStructure(bool value)
        {
            if (value)
            {
                _audioComponent.PlayAudio("chose-player");
                _cinemachine.Follow = this.transform;
            }

            if (_hightlight != null)
            {
                _hightlight.SetActive(value);
            }

            _activePlayerUI.ActivatePlayerSlot(slotInstanceId.Value);

            _uIManager.ActivateInventory(_isMainPlayer);
            _uIManager.ActivateActionSlots(_isMainPlayer);
            _uIManager.ActivateStomach(_canPoop);

            IsActive = value;
            if (_canMoveByClick)
            {
                _movementMouseComponent.SetActivationComponent(value);
            }
            if (_canInteract)
            {
                _interactableComponent.SetActivationComponent(value);
            }
            if (_canPoop)
            {
                _stomachComponent.SetActivationComponent(value);
            }
        }