Exemplo n.º 1
0
 public void EnterCar(SimpleCarController activeCar)
 {
     Debug.Log("Enter Car Triggered");
     activeCar.isCarActive = true;
     this.activeCar        = activeCar;
     gameObject.SetActive(false);
     transform.parent = activeCar.centerOfMass.transform; //Connect to car, allows exit at proper location.
     activeCar.PlayerEnter(this);
     Camera.main.GetComponent <SmoothCameraMove>().SwitchTarget(activeCar.carCamera.transform);
     Camera.main.cullingMask &= ~(1 << LayerMask.NameToLayer("Car Indicators"));
 }