// Use this for initialization void Start() { Bola = GameObject.Find("Bola").GetComponent <bola>(); obstacles = GameObject.Find("ObstacleController").GetComponent <obstacleController>(); cameraMain = GameObject.Find("MainCamera").GetComponent <cameraMove>(); back = GameObject.Find("BackgroundController").GetComponent <background>(); deadCanvas.SetActive(false); pressSpaceT.SetActive(true); final = false; running = false; }
// Use this for initialization void Start() { myRigidbody = GetComponent <Rigidbody2D>(); myCollider = GetComponent <BoxCollider2D>(); myCircleCollider = GetComponent <CircleCollider2D>(); myAnimator = GetComponent <Animator>(); obstacleCtrl = GameObject.FindObjectOfType <obstacleController>(); theScoreController = FindObjectOfType <scoreController>(); }
void Start() { instance = this; particle = GameObject.Find("Particle").GetComponent <ParticleSystem>(); }