VOID_SurfAtmo: changed vesselHeading syntax to use new vessel extension tool.
VOID_SurfAtmo: changed vesselHeading syntax to use new vessel extension tool.

file:a/Tools.cs -> file:b/Tools.cs
--- a/Tools.cs
+++ b/Tools.cs
@@ -149,67 +149,17 @@
 			return string.Format("{0}° {1}", Math.Abs(v_lat).ToString(format), dir_lat);
 		}
 
-		///////////////////////////////////////////////////////////////////////////////
-
-		//For MuMech_get_heading()
-		public class MuMech_MovingAverage
-		{
-			private double[] store;
-			private int storeSize;
-			private int nextIndex = 0;
-
-			public double value
-			{
-				get
-				{
-					double tmp = 0;
-					foreach (double i in store)
-					{
-						tmp += i;
-					}
-					return tmp / storeSize;
-				}
-				set
-				{
-					store[nextIndex] = value;
-					nextIndex = (nextIndex + 1) % storeSize;
-				}
-			}
-
-			public MuMech_MovingAverage(int size = 10, double startingValue = 0)
-			{
-				storeSize = size;
-				store = new double[size];
-				force(startingValue);
-			}
-
-			public void force(double newValue)
-			{
-				for (int i = 0; i < storeSize; i++)
-				{
-					store[i] = newValue;
-				}
-			}
-
-			public static implicit operator double(MuMech_MovingAverage v)
-			{
-				return v.value;
-			}
-
-			public override string ToString()
-			{
-				return value.ToString();
-			}
-
-			public string ToString(string format)
-			{
-				return value.ToString(format);
-			}
-		}
-		//From http://svn.mumech.com/KSP/trunk/MuMechLib/VOID.vesselState.cs
-		public static double MuMech_get_heading(Vessel vessel)
-		{
-			Vector3d CoM;
+		/*
+		* MuMechLib Methods
+		* The methods below are adapted from MuMechLib, © 2013-2014 r4m0n
+		* The following methods are a derivative work of the code from MuMechLib in the MechJeb project.
+		* Used under license.
+		* */
+
+		// Derived from MechJeb2/VesselState.cs
+		public static Quaternion getSurfaceRotation(this Vessel vessel)
+		{
+			Vector3 CoM;
 
 			try
 			{
@@ -217,25 +167,42 @@
 			}
 			catch
 			{
-				return double.NaN;
-			}
-
-			Vector3d up = (CoM - vessel.mainBody.position).normalized;
-			Vector3d north = Vector3d.Exclude(
-				                 up,
-				                 (vessel.mainBody.position +
-				                 vessel.mainBody.transform.up * (float)vessel.mainBody.Radius
-				                 ) - CoM).normalized;
-
-			Quaternion rotationSurface = Quaternion.LookRotation(north, up);
-			Quaternion rotationvesselSurface = Quaternion.Inverse(
-				                                   Quaternion.Euler(90, 0, 0) *
-				                                   Quaternion.Inverse(vessel.transform.rotation) *
-				                                   rotationSurface);
-
-			return rotationvesselSurface.eulerAngles.y;
-		}
-		//From http://svn.mumech.com/KSP/trunk/MuMechLib/MuUtils.cs
+				return new Quaternion();
+			}
+
+			Vector3 bodyPosition = vessel.mainBody.position;
+			Vector3 bodyUp = vessel.mainBody.transform.up;
+
+			Vector3 surfaceUp = (CoM - vessel.mainBody.position).normalized;
+			Vector3 surfaceNorth = Vector3.Exclude(
+				surfaceUp,
+				(bodyPosition + bodyUp * (float)vessel.mainBody.Radius) - CoM
+			).normalized;
+
+			Quaternion surfaceRotation = Quaternion.LookRotation(surfaceNorth, surfaceUp);
+
+			return Quaternion.Inverse(
+				Quaternion.Euler(90, 0, 0) * Quaternion.Inverse(vessel.GetTransform().rotation) * surfaceRotation
+			);
+		}
+
+		// Derived from MechJeb2/VesselState.cs
+		public static double getSurfaceHeading(this Vessel vessel)
+		{
+			return vessel.getSurfaceRotation().eulerAngles.y;
+		}
+
+		// Derived from MechJeb2/VesselState.cs
+		public static double getSurfacePitch(this Vessel vessel)
+		{
+			Quaternion vesselSurfaceRotation = vessel.getSurfaceRotation();
+
+			return (vesselSurfaceRotation.eulerAngles.x > 180f) ?
+				(360f - vesselSurfaceRotation.eulerAngles.x) :
+				-vesselSurfaceRotation.eulerAngles.x;
+		}
+
+		// Derived from MechJeb2/MuUtils.cs
 		public static string MuMech_ToSI(
 			double d, int digits = 3, int MinMagnitude = 0, int MaxMagnitude = int.MaxValue
 		)
@@ -325,6 +292,10 @@
 			}
 		}
 
+		/*
+		 * END MuMecLib METHODS
+		 * */
+
 		public static string ConvertInterval(double seconds)
 		{
 			string format_1 = "{0:D1}y {1:D1}d {2:D2}h {3:D2}m {4:D2}.{5:D1}s";

--- a/VOID_HUD.cs
+++ b/VOID_HUD.cs
@@ -130,6 +130,10 @@
 					VOID_Data.oribtPeriAlt.ToSIString(),
 					VOID_Data.timeToPeri.ValueUnitString()
 				);
+				leftHUD.AppendFormat("\nTot Δv: {0} Stg Δv: {1}",
+					VOID_Data.totalDeltaV.ToSIString(2),
+					VOID_Data.stageDeltaV.ToSIString(2)
+				);
 			}
 			else
 			{
@@ -157,7 +161,11 @@
 
 			if (VOID_Core.Instance.powerAvailable)
 			{
-				rightHUD.AppendFormat("Srf Alt: {0} Srf Vel: {1}",
+				rightHUD.AppendFormat("Biome: {0} Sit: {1}",
+					VOID_Data.currBiome.ValueUnitString(),
+					VOID_Data.expSituation.ValueUnitString()
+				);
+				rightHUD.AppendFormat("\nSrf Alt: {0} Srf Vel: {1}",
 					VOID_Data.trueAltitude.ToSIString(),
 					VOID_Data.surfVelocity.ToSIString()
 				);
@@ -169,10 +177,9 @@
 					VOID_Data.surfLatitude.ValueUnitString(),
 					VOID_Data.surfLongitude.ValueUnitString()
 				);
-				rightHUD.AppendFormat("\nHdg: {0}", VOID_Data.vesselHeading.ValueUnitString());
-				rightHUD.AppendFormat("\nBiome: {0} Sit: {1}",
-					VOID_Data.currBiome.ValueUnitString(),
-					VOID_Data.expSituation.ValueUnitString()
+				rightHUD.AppendFormat("\nHdg: {0} Pit: {1}",
+					VOID_Data.vesselHeading.ValueUnitString(),
+					VOID_Data.vesselPitch.ToSIString(2)
 				);
 			}
 			else
@@ -244,6 +251,12 @@
 			new Func<string> (() => VOID_Core.Instance.vessel.GetExperimentSituation().HumanString())
 		);
 
+		public static VOID_DoubleValue vesselPitch = new VOID_DoubleValue(
+			"Pitch",
+			() => core.vessel.getSurfacePitch(),
+			"°"
+		);
+
 		public static VOID_DoubleValue stageMassFlow = new VOID_DoubleValue(
 			"Stage Mass Flow",
 			delegate()
@@ -295,7 +308,7 @@
 			"s"
 		);
 
-		protected static double burnTime(double deltaV, double initialMass, double massFlow, double thrust)
+		private static double burnTime(double deltaV, double initialMass, double massFlow, double thrust)
 		{
 			return initialMass / massFlow * (Math.Exp(deltaV * massFlow / thrust) - 1d);
 		}

--- a/VOID_SurfAtmo.cs
+++ b/VOID_SurfAtmo.cs
@@ -128,7 +128,7 @@
 			"Heading",
 			delegate()
 		{
-			double heading = Tools.MuMech_get_heading(VOID_Core.Instance.vessel);
+			double heading = core.vessel.getSurfaceHeading();
 			string cardinal = Tools.get_heading_text(heading);
 
 			return string.Format(