void Start() { ballRigidBody = GetComponent <Rigidbody> (); ballRigidBody.useGravity = false; initialPosition = transform.position; misses = FindObjectOfType <AttemptsRemaining> (); hitDetector = FindObjectOfType <HitDetector> (); }
void Start() { ball = FindObjectOfType <Ball> (); particleSystem = FindObjectOfType <ParticleSystem> (); boxDisplay = FindObjectOfType <BoxDisplay> (); attempts = FindObjectOfType <AttemptsRemaining> (); mainCamera = FindObjectOfType <Camera> (); }