예제 #1
0
 private void OnTriggerEnter(Collider other)
 {
     if (other.tag == "Player")
     {
         carSceneManagaer.GameEnd(true);
         Debug.Log("GameEnd");
     }
 }
 void Update()
 {
     fuel -= Time.deltaTime;
     UIManager.Instance.UpdateFuelBar(fuel / fuelMaxAmt);
     UIManager.Instance.UpdateDistBar((cardist.position.x - startdist) / 1800f);
     if (fuel < 0)
     {
         carSceneManagaer.GameEnd(false);
     }
 }