// Use this for initialization void Start () { Instance = this; slowSpeed = 4.0f; fastSpeed = 6.0f; slow = true; fast = false; }
// Use this for initialization void Start () { roadO = GameObject.FindGameObjectWithTag("MainCamera"); roadScript = roadO.GetComponent<ForegroundScript>(); slowSpeed = 4.0f; fastSpeed = 6.0f; currSpeed = 0.0f; startP = new Vector3(30, getStartPos(), -1); this.transform.position = startP; startTime = getStartTime(); }
// checking bools objects. // Use this for initialization void Start () { Instance = this; player = GameObject.FindGameObjectWithTag("Player"); playerScript = player.GetComponent<mainPlayer>(); roadO = GameObject.FindGameObjectWithTag("MainCamera"); roadScript = roadO.GetComponent<ForegroundScript>(); currentLane = getRandomLane(); prevLane = currentLane; getColor(); currTime = 0; startTime = getStartTime(); }
// Use this for initialization void Start () { Instance = this; roadO = GameObject.FindGameObjectWithTag("MainCamera"); roadScript = roadO.GetComponent<ForegroundScript>(); startPosition = new Vector3(30,getStartPosition(),-1); this.transform.position = startPosition; startTime = (float)Random.Range(0.0f,10.0f); currentSpeed = 0.0f; fastSpeed = 6.0f; slowSpeed = 4.0f; rotSpeed = 0.01f; rotPosition = 0.0f; }