void Start() { playerAction = FindObjectOfType <PlayerActions>(); healthBar = GetComponent <HealthBar>(); finalPunches = GetComponent <FinalPunches>(); timeLeft = finalPunches.maxTime; timerPanel.enabled = false; // Nascondi la barra di sfondo timerBar.enabled = false; // Nascondi la barra del Counter finalPunches.counterText.enabled = false; // Nascondi il testo del Counter finalPunches.pressButtonImage.enabled = false; // Nascondi il Tasto impiattaloText.enabled = false; }
void Start() { leftAnim = transform.GetChild(0).GetComponent <Animator>(); rightAnim = transform.GetChild(1).GetComponent <Animator>(); chefAnimator = GameObject.FindGameObjectWithTag("Enemy").GetComponent <Animator>(); leftPos = GameObject.Find("leftPos").transform; rightPos = GameObject.Find("rightPos").transform; pointPos = GameObject.Find("pointPos").transform; healthBar = FindObjectOfType <HealthBar>(); soundManager = FindObjectOfType <SoundManager>(); gameManager = FindObjectOfType <GameManager>(); finalPunches = FindObjectOfType <FinalPunches>(); canParryTimer = parryCooldown; leftStartingPos = leftAnim.transform.position; rightStartingPos = rightAnim.transform.position; }