Example #1
0
    public void AdjustTrack()
    {
        PlayerManager.Type = "BuilderPlayer";
        foreach (iVehicleManager VM in DrivingPlayManager.Current.VehicleManagers)
        {
            VM.DestroyVehicle();
        }
        DrivingPlayManager.Current.PlayerCarManager = null;
        DrivingPlayManager.Current.VehicleManagers.Clear();
        DrivingPlayManager.Current.Dispose(); //also gets rid of Race current and RaceRecorder and Recrdng.Current
        DrivingPlayManager.Current = null;

        ShowMenuPanel(false);

        BuildingPlayManager BPM = new BuildingPlayManager();

        BuildingPlayManager.Current = BPM;
        BuildingPlayManager.Current.PlayOffline();
        foreach (PlaceableObject PO in Scenery.Instance.Objects)
        {
            PO.EnableClickColliders();
        }
    }