void Update() { if (manager.getGameState() == "GameON") { timer += Time.deltaTime; CreateApple(); } }
void OnTriggerEnter2D(Collider2D otro) { if (otro.tag == "suelo" && appleState != "Hit") { textM.text = ""; appleAnim.SetBool("isPlof", true); setAppleState("Eliminated"); if (isGood() && manager.getGameState() == "GameON") { Instantiate(failSymbol, transform.position, Quaternion.identity); setAppleState("Fail"); manager.badSelection();// manager.badSelection(); } } }