Exemplo n.º 1
0
 public override void Draw(SectionModule section)
 {
     if (ImpactProcessor.ShowDetails)
     {
         this.DrawLine(TimeFormatter.ConvertToString(ImpactProcessor.Time), section.IsHud);
     }
 }
Exemplo n.º 2
0
 public override void Draw(Unity.Flight.ISectionModule section)
 {
     if (RendezvousProcessor.ShowDetails)
     {
         this.DrawLine(TimeFormatter.ConvertToString(RendezvousProcessor.TimeToTransferAngle), section.IsHud);
     }
 }
Exemplo n.º 3
0
 public override void Draw(SectionModule section)
 {
     if (RendezvousProcessor.ShowDetails)
     {
         this.DrawLine(TimeFormatter.ConvertToString(RendezvousProcessor.TimeToRendezvous), section.IsHud);
     }
 }
 public override void Draw(Unity.Flight.ISectionModule section)
 {
     if (RendezvousProcessor.ShowDetails)
     {
         this.DrawLine(TimeFormatter.ConvertToString(RendezvousProcessor.OrbitalPeriod, "F3"), section.IsHud);
     }
 }
        public override void Draw(Unity.Flight.ISectionModule section)
        {
            if (!ManoeuvreProcessor.ShowDetails)
            {
                return;
            }

            this.DrawLine("Time to Node", TimeFormatter.ConvertToString(ManoeuvreProcessor.UniversalTime - Planetarium.GetUniversalTime()), section.IsHud);
        }
Exemplo n.º 6
0
        public override void Draw(Unity.Flight.ISectionModule section)
        {
            if (!ManoeuvreProcessor.ShowDetails)
            {
                return;
            }

            this.DrawLine(TimeFormatter.ConvertToString(ManoeuvreProcessor.PostBurnPeriod, "F3"), section.IsHud);
        }
Exemplo n.º 7
0
        public override void Draw(Unity.Flight.ISectionModule section)
        {
            if (!SimulationProcessor.ShowDetails || !Surface.ImpactProcessor.ShowDetails)
            {
                return;
            }

            this.DrawLine(TimeFormatter.ConvertToString(Surface.ImpactProcessor.SuicideLength), section.IsHud);
        }
Exemplo n.º 8
0
        public override void Draw(Unity.Flight.ISectionModule section)
        {
            if (!ManoeuvreProcessor.ShowDetails)
            {
                return;
            }

            this.DrawLine("Node Burn Time", TimeFormatter.ConvertToString(ManoeuvreProcessor.BurnTime), section.IsHud);
        }
Exemplo n.º 9
0
 public override void Draw(Unity.Flight.ISectionModule section)
 {
     if (RendezvousProcessor.ShowDetails)
     {
         if (double.IsNaN(RendezvousProcessor.TimeTilEncounter))
         {
             this.DrawLine("N/A", section.IsHud);
         }
         else
         {
             this.DrawLine(TimeFormatter.ConvertToString(RendezvousProcessor.TimeTilEncounter), section.IsHud);
         }
     }
 }
Exemplo n.º 10
0
 /// <summary>
 ///     Draws the burn time column.
 /// </summary>
 private void DrawBurnTime()
 {
     GUILayout.BeginVertical(GUILayout.Width(75.0f * GuiDisplaySize.Offset));
     GUILayout.Label("BURN", titleStyle);
     for (int i = 0; i < stagesLength; ++i)
     {
         stage = stages[i];
         if (showAllStages || stage.deltaV > 0.0)
         {
             GUILayout.Label(TimeFormatter.ConvertToString(stage.time), infoStyle);
         }
     }
     GUILayout.EndVertical();
 }
Exemplo n.º 11
0
        public override void Draw(SectionModule section)
        {
            String str;
            Orbit  orbit = FlightGlobals.ship_orbit;

            if (orbit.referenceBody.atmosphere && orbit.PeA < orbit.referenceBody.atmosphereDepth && orbit.ApA > orbit.referenceBody.atmosphereDepth)
            {
                double tA = orbit.TrueAnomalyAtRadius(orbit.referenceBody.atmosphereDepth + orbit.referenceBody.Radius);
                //log.buf.AppendFormat("tA = {0}\n", tA);
                double utTime = Planetarium.GetUniversalTime();
                //log.buf.AppendFormat("utTime = {0}\n", utTime);
                double timeAtRad1 = orbit.GetUTforTrueAnomaly(tA, orbit.period * 0.5);
                //log.buf.AppendFormat("timeAtRad1 = {0}\n", timeAtRad1);
                if (timeAtRad1 < utTime)
                {
                    timeAtRad1 += orbit.period;
                    //log.buf.AppendFormat("timeAtRad1 = {0}\n", timeAtRad1);
                }
                double timeAtRad2 = orbit.GetUTforTrueAnomaly(-tA, orbit.period * 0.5);
                //log.buf.AppendFormat("timeAtRad2 = {0}\n", timeAtRad2);
                if (timeAtRad2 < utTime)
                {
                    timeAtRad2 += orbit.period;
                    //log.buf.AppendFormat("timeAtRad2 = {0}\n", timeAtRad2);
                }
                double time = Math.Min(timeAtRad1, timeAtRad2) - utTime;
                //log.buf.AppendFormat("time = {0}\n", time);

                if (Double.IsNaN(time))
                {
                    str = "---s";
                    //log.buf.AppendLine("time is NaN");
                }
                else
                {
                    str = TimeFormatter.ConvertToString(time);
                    //log.buf.AppendFormat("str = {0}\n", str);
                }
            }
            else
            {
                str = "---s";
                //log.buf.AppendLine("no atmosphere, pe > atmosphere, or ap < atmosphere");
            }

            //log.Flush();
            this.DrawLine(str, section.IsHud);
        }
        public override void Draw(SectionModule section)
        {
            if (RendezvousProcessor.ShowDetails)
            {
                if (RendezvousProcessor.overrideANDN || RendezvousProcessor.overrideANDNRev)
                {
                    double time = RendezvousProcessor.TimeToPlane[0];

                    this.DrawLine("(L) " + TimeFormatter.ConvertToString(time), section.IsHud);
                }
                else
                {
                    this.DrawLine(TimeFormatter.ConvertToString(RendezvousProcessor.TimeToAscendingNode), section.IsHud);
                }
            }
        }
Exemplo n.º 13
0
        public override void Draw(SectionModule section)
        {
            if (!SimulationProcessor.ShowDetails)
            {
                return;
            }

            foreach (var stage in SimulationProcessor.Stages.Where(stage => stage.deltaV > 0 || stage.number == Staging.CurrentStage))
            {
                this.DrawLine("DeltaV (S" + stage.number + ")", stage.deltaV.ToString("N0") + "m/s (" + TimeFormatter.ConvertToString(stage.time) + ")", section.IsHud);
            }
        }
Exemplo n.º 14
0
 public override void Draw(Unity.Flight.ISectionModule section)
 {
     this.DrawLine(TimeFormatter.ConvertToString(OrbitExtensions.GetTimeToDescendingNode(FlightGlobals.ActiveVessel.orbit)), section.IsHud);
 }
Exemplo n.º 15
0
 public override void Draw(Unity.Flight.ISectionModule section)
 {
     this.DrawLine(TimeFormatter.ConvertToString(FlightGlobals.ship_orbit.timeToAp), section.IsHud);
 }
 public override void Draw(SectionModule section)
 {
     this.DrawLine(TimeFormatter.ConvertToString(FlightGlobals.ActiveVessel.orbit.GetTimeToAscendingNode()), section.IsHud);
 }
        public override void Draw(Unity.Flight.ISectionModule section)
        {
            if (SimulationProcessor.ShowDetails == false || StageManager.Instance == null)
            {
                return;
            }

            foreach (Stage stage in SimulationProcessor.Stages.Where(stage => stage.deltaV > 0 || stage.number == StageManager.CurrentStage))
            {
                DrawLine("DeltaV (S" + stage.number + ")", EggConverter.ConvertDeltaV(stage.deltaV).ToString("N0") + EggConverter.DeltaV + " (" + TimeFormatter.ConvertToString(stage.time) + ")", section.IsHud);
            }
        }
 public override void Draw(Unity.Flight.ISectionModule section)
 {
     if (SimulationProcessor.ShowDetails)
     {
         this.DrawLine(EggConverter.ConvertDeltaV(SimulationProcessor.LastStage.deltaV).ToString("N0") + EggConverter.DeltaV + " (" + TimeFormatter.ConvertToString(SimulationProcessor.LastStage.time) + ")", section.IsHud);
     }
 }
Exemplo n.º 19
0
 public override void Draw(Unity.Flight.ISectionModule section)
 {
     if (SimulationProcessor.ShowDetails)
     {
         this.DrawLine(SimulationProcessor.LastStage.RCSdeltaVStart.ToString("N0") + "m/s (" + TimeFormatter.ConvertToString(SimulationProcessor.LastStage.RCSBurnTime) + ")", section.IsHud);
     }
 }
Exemplo n.º 20
0
 public override void Draw(SectionModule section)
 {
     if (SimulationProcessor.ShowDetails)
     {
         this.DrawLine(SimulationProcessor.LastStage.deltaV.ToString("N0") + "m/s (" + TimeFormatter.ConvertToString(SimulationProcessor.LastStage.time) + ")", section.IsHud);
     }
 }
Exemplo n.º 21
0
 public override void Draw(SectionModule section)
 {
     this.DrawLine(TimeFormatter.ConvertToString(FlightGlobals.ship_orbit.period, "F3"), section.IsHud);
 }