Ejemplo n.º 1
0
        public void StartFastTravel(ContentReader.MapSummary destinationSummary)
        {
            DFLocation targetLocation;

            if (DaggerfallUnity.Instance.ContentReader.GetLocation(
                    destinationSummary.RegionIndex, destinationSummary.MapIndex, out targetLocation))
            {
                destinationName          = targetLocation.Name;
                travelUi.DestinationName = destinationName;
            }
            else
            {
                throw new ArgumentException("TediousTravel destination not found!");
            }

            playerAutopilot            = new PlayerAutoPilot(destinationSummary);
            playerAutopilot.OnArrival += () =>
            {
                travelUi.CancelWindow();
                DaggerfallUI.Instance.DaggerfallHUD.SetMidScreenText("You have arrived at your destination", 5f);
            };

            this.destinationSummary = destinationSummary;
            DisableAnnoyingSounds();
            DisableWeather();
            SetTimeScale(travelUi.TimeCompressionSetting);
            diseaseCount = GameManager.Instance.PlayerEffectManager.DiseaseCount;

            Debug.Log("started tedious travel");
        }
Ejemplo n.º 2
0
 /// <summary>
 /// Stops fast travel, but leaves current destination active
 /// </summary>
 public void InterruptFastTravel()
 {
     SetTimeScale(1);
     playerAutopilot = null;
     GameManager.Instance.PlayerMouseLook.enableMouseLook  = true;
     GameManager.Instance.PlayerMouseLook.lockCursor       = true;
     GameManager.Instance.PlayerMouseLook.simpleCursorLock = false;
     EnableAnnoyingSounds();
 }
Ejemplo n.º 3
0
 /// <summary>
 /// Stops fast travel, but leaves current destination active
 /// </summary>
 public void InterruptFastTravel()
 {
     Debug.Log("fast travel interrupted");
     SetTimeScale(1);
     GameManager.Instance.PlayerMouseLook.enableMouseLook  = true;
     GameManager.Instance.PlayerMouseLook.lockCursor       = true;
     GameManager.Instance.PlayerMouseLook.simpleCursorLock = false;
     playerAutopilot.MouseLookAtDestination();
     playerAutopilot = null;
     EnableAnnoyingSounds();
     EnableWeather();
 }