public void GetChoice() { string choiceName = UnityEngine.EventSystems.EventSystem.current.currentSelectedGameObject.name; GameChoice selectedChoice = GameChoice.NONE; switch (choiceName) { case "Rock": selectedChoice = GameChoice.ROCK; break; case "Paper": selectedChoice = GameChoice.PAPER; break; case "scissors": selectedChoice = GameChoice.SCISSORS; break; } playController.SetChoice(selectedChoice); animationController.PlayerMadeChoice(); }