void Start() { obAgregar = GameObject.FindGameObjectWithTag("GameManager"); agregar = obAgregar.GetComponent <puntuacion>(); ganaste = obAgregar.GetComponent <mostrarPantallaTxt>(); //vida vida = obAgregar.GetComponent <vidaActual>(); }
void Start() { Nisty = GameObject.FindGameObjectWithTag("nisty"); //vida gameObVida = GameObject.FindGameObjectWithTag("GameManager"); vida = gameObVida.GetComponent <vidaActual>(); //puntuacion gameObPuntuacion = GameObject.FindGameObjectWithTag("GameManager"); puntaje = gameObPuntuacion.GetComponent <puntuacion>(); // asdfg gameOver = gameObPuntuacion.GetComponent <mostrarPantallaTxt>(); }
void Start() { controlador = GetComponent <CharacterController>(); trampolin = GameObject.FindGameObjectWithTag("trampolinY"); velocidad.y = 0; //morido? gameObVida = GameObject.FindGameObjectWithTag("GameManager"); vida = gameObVida.GetComponent <vidaActual>(); gameOver = gameObVida.GetComponent <mostrarPantallaTxt>(); //soio de nuevo Nisty = GameObject.FindGameObjectWithTag("nisty"); //sonido saltoSound = saltar.GetComponent <AudioSource>(); //pausar pausarJuego = gameObVida.GetComponent <menus>(); estaSaltando = false; }