// Use this for initialization void Start() { x2life = 1.0f; pjx = (GameObject)GameObject.FindGameObjectWithTag("Player"); porteria = (GameObject)GameObject.FindGameObjectWithTag("porteria"); lR = (GameObject)GameObject.FindGameObjectWithTag("limitR"); lF = (GameObject)GameObject.FindGameObjectWithTag("limitL"); x2boost = (GameObject)GameObject.FindGameObjectWithTag("x2boost"); x2Void = (GameObject)GameObject.FindGameObjectWithTag("x2void"); restart.gameObject.SetActive(false); nextL.gameObject.SetActive(false); rigidbody = GetComponent <Rigidbody>(); showsum = FindObjectOfType <ShowSum>(); showgoal = FindObjectOfType <ShowGoal> (); }
// Use this for initialization void Start() { //Insatiate Every GameObject InstanciateAll = Instantiate(Arkball); InstanciateAll.transform.SetParent(this.transform); Input.ResetInputAxes(); allD = GameObject.FindGameObjectsWithTag("cube"); ball = FindObjectOfType <BallArk> (); pspeed = FindObjectOfType <PlayerArk> (); arb = FindObjectOfType <Arbrito> (); liveE = FindObjectOfType <ExplodeLife> (); player = (GameObject)GameObject.FindGameObjectWithTag("Player"); playerSpawn = (GameObject)GameObject.FindGameObjectWithTag("PlayerSpawn"); showsum = FindObjectOfType <ShowSum> (); ShowDeathMenu.SetActive(false); StartGame(); timeToAdvance = 0.3f; advanceDistance = 0.1f; waitforNextRow = 16.0f; puntoInicialXL = arrow1.transform.position.x; puntoInicialXR = arrow2.transform.position.x; }