// Start is called before the first frame update void Start() { roofSlowPos = FindObjectOfType <RoofSlow>(); theFallingController = FindObjectOfType <StartScreen>(); whatElementInArrayX = rnd.Next(1, theFallingController.locationX.Length - 1); //gameObject.transform.position = new Vector3(theFallingController.locationX[whatElementInArrayX].transform.position.x, gameObject.transform.position.y, 0); InvokeRepeating("changeY", 0f, 0.05f); //transform.Rotate(0, 0, rnd.Next(0,4) * 90); //changeColliderX = true; //changeColliderY = true; }