private void RebuildTrack() { m_streetView.ToggleAppearance(false, () => { m_splineManager.GenerateTrackFromTrackData(); m_streetView.ToggleAppearance(true, null); }); }
private void UpdateTrackMesh() { m_streetView.ToggleAppearance(false, () => { m_splineManager.GenerateTrack(); m_streetView.ToggleAppearance(true, null); }); }
public override void EnterState() { Debug.Log("Entered RaceSetupState"); base.EnterState(); // Rebuild track once more before the race m_streetView.ToggleAppearance(false, () => { m_splineMgr.GenerateTrackFromTrackData(); m_vehicleManager.SpawnVehicleAtStart(); m_streetView.ToggleAppearance(true, null); }); // Reset the speed value; m_input.SetValue(0f); }