Config updated to MM 2.0.
Config updated to MM 2.0.

--- /dev/null
+++ b/ARConfiguration.cs
@@ -1,1 +1,125 @@
+// AntennaRange © 2014 toadicus
+//
+// This work is licensed under the Creative Commons Attribution-NonCommercial-ShareAlike 3.0 Unported License. To view a
+// copy of this license, visit http://creativecommons.org/licenses/by-nc-sa/3.0/
 
+using KSP;
+using System;
+using ToadicusTools;
+using UnityEngine;
+
+namespace AntennaRange
+{
+	[KSPAddon(KSPAddon.Startup.SpaceCentre, false)]
+	public class ARConfiguration : MonoBehaviour
+	{
+		private bool showConfigWindow;
+		private Rect configWindowPos;
+
+		private IButton toolbarButton;
+
+		public void Awake()
+		{
+			Tools.PostDebugMessage(this, "Waking up.");
+
+			this.showConfigWindow = false;
+			this.configWindowPos = new Rect(Screen.width / 4, Screen.height / 2, 180, 15);
+
+			Tools.PostDebugMessage(this, "Awake.");
+		}
+
+		public void OnGUI()
+		{
+			if (this.toolbarButton == null && ToolbarManager.ToolbarAvailable)
+			{
+				Tools.PostDebugMessage(this, "Toolbar available; initializing button.");
+
+				this.toolbarButton = ToolbarManager.Instance.add("AntennaRange", "ARConfiguration");
+				this.toolbarButton.Visibility = new GameScenesVisibility(GameScenes.SPACECENTER);
+				this.toolbarButton.Text = "AR";
+				this.toolbarButton.TexturePath = "AntennaRange/Textures/toolbarIcon";
+				this.toolbarButton.TextColor = (Color)XKCDColors.Amethyst;
+				this.toolbarButton.OnClick += delegate(ClickEvent e)
+				{
+					this.showConfigWindow = !this.showConfigWindow;
+				};
+
+				var config = KSP.IO.PluginConfiguration.CreateForType<AntennaRelay>();
+
+				config.load();
+
+				this.configWindowPos = config.GetValue<Rect>("configWindowPos", this.configWindowPos);
+				AntennaRelay.requireLineOfSight = config.GetValue<bool>("requireLineOfSight", false);
+
+				config.save();
+			}
+
+			if (this.showConfigWindow)
+			{
+				Rect configPos = GUILayout.Window(354163056,
+					this.configWindowPos,
+					this.ConfigWindow,
+					"AntennaRange Configuration",
+					GUILayout.ExpandHeight(true),
+					GUILayout.ExpandWidth(true)
+				);
+
+				configPos = Tools.ClampRectToScreen(configPos, 20);
+
+				if (configPos != this.configWindowPos)
+				{
+					this.configWindowPos = configPos;
+					this.SaveConfigValue("configWindowPos", this.configWindowPos);
+				}
+			}
+		}
+
+		public void ConfigWindow(int _)
+		{
+			GUILayout.BeginVertical(GUILayout.ExpandHeight(true));
+
+			GUILayout.BeginHorizontal(GUILayout.ExpandWidth(true));
+			bool requireLineOfSight = GUILayout.Toggle(AntennaRelay.requireLineOfSight, "Require Line of Sight");
+			if (requireLineOfSight != AntennaRelay.requireLineOfSight)
+			{
+				AntennaRelay.requireLineOfSight = requireLineOfSight;
+				this.SaveConfigValue("requireLineOfSight", requireLineOfSight);
+			}
+
+			GUILayout.EndHorizontal();
+
+			GUILayout.EndVertical();
+
+			GUI.DragWindow();
+		}
+
+		public void Destroy()
+		{
+			if (this.toolbarButton != null)
+			{
+				this.toolbarButton.Destroy();
+			}
+		}
+
+		private T LoadConfigValue<T>(string key, T defaultValue)
+		{
+			var config = KSP.IO.PluginConfiguration.CreateForType<AntennaRelay>();
+
+			config.load();
+
+			return config.GetValue(key, defaultValue);
+		}
+
+		private void SaveConfigValue<T>(string key, T value)
+		{
+			var config = KSP.IO.PluginConfiguration.CreateForType<AntennaRelay>();
+
+			config.load();
+
+			config.SetValue(key, value);
+
+			config.save();
+		}
+	}
+}
+

--- a/AntennaRange.cfg
+++ b/AntennaRange.cfg
@@ -37,7 +37,7 @@
 // maxDataFactor:	The multipler on packetSize that defines the maximum data bandwidth of the antenna.
 // 
 
-@PART[longAntenna]
+@PART[longAntenna]:FOR[AntennaRange]:NEEDS[!RemoteTech2]
 {
 	@MODULE[ModuleDataTransmitter]
 	{
@@ -48,7 +48,7 @@
 	}
 }
 
-@PART[mediumDishAntenna]
+@PART[mediumDishAntenna]:FOR[AntennaRange]:NEEDS[!RemoteTech2]
 {
 	@MODULE[ModuleDataTransmitter]
 	{
@@ -59,7 +59,7 @@
 	}
 }
 
-@PART[commDish]
+@PART[commDish]:FOR[AntennaRange]:NEEDS[!RemoteTech2]
 {
 	@MODULE[ModuleDataTransmitter]
 	{

--- a/AntennaRange.csproj
+++ b/AntennaRange.csproj
@@ -96,6 +96,13 @@
     <Compile Include="..\ToadicusTools\IModuleDB.cs">
       <Link>ToadicusTools\IModuleDB.cs</Link>
     </Compile>
+    <Compile Include="ARConfiguration.cs" />
+    <Compile Include="..\ToadicusTools\Wrapper\ToolbarWrapper.cs">
+      <Link>ToadicusTools\ToolbarWrapper.cs</Link>
+    </Compile>
+    <Compile Include="..\ToadicusTools\WindowTools.cs">
+      <Link>WindowTools.cs</Link>
+    </Compile>
   </ItemGroup>
   <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
   <ItemGroup>

--- a/AntennaRelay.cs
+++ b/AntennaRelay.cs
@@ -35,6 +35,8 @@
 {
 	public class AntennaRelay
 	{
+		public static bool requireLineOfSight;
+
 		// We don't have a Bard, so we'll hide Kerbin here.
 		protected CelestialBody Kerbin;
 
@@ -44,8 +46,6 @@
 		protected System.Diagnostics.Stopwatch searchTimer;
 		protected long millisecondsBetweenSearches;
 
-		protected bool requireLineOfSight;
-
 		/// <summary>
 		/// Gets the parent Vessel.
 		/// </summary>
@@ -134,7 +134,7 @@
 		{
 			if (
 				this.transmitDistance > this.maxTransmitDistance ||
-				(this.requireLineOfSight && this.nearestRelay == null && !this.vessel.hasLineOfSightTo(this.Kerbin))
+				(requireLineOfSight && this.nearestRelay == null && !this.vessel.hasLineOfSightTo(this.Kerbin))
 			)
 			{
 				return false;
@@ -188,12 +188,6 @@
 				// Skip vessels that have already been checked for a nearest relay this pass.
 				if (RelayDatabase.Instance.CheckedVesselsTable.ContainsKey(potentialVessel.id))
 				{
-					Tools.PostDebugMessage(
-						this,
-						"Vessel {0} discarded because it has already been checked this pass.",
-						potentialVessel.vesselName,
-						potentialVessel.vesselType
-					);
 					continue;
 				}
 
@@ -205,12 +199,6 @@
 					case VesselType.EVA:
 					case VesselType.SpaceObject:
 					case VesselType.Unknown:
-						Tools.PostDebugMessage(
-							this,
-							"Vessel {0} discarded because it is of invalid type {1}.",
-							potentialVessel.vesselName,
-							potentialVessel.vesselType
-						);
 						continue;
 					default:
 						break;
@@ -223,7 +211,7 @@
 				}
 
 				// Skip vessels to which we do not have line of sight.
-				if (this.requireLineOfSight && !this.vessel.hasLineOfSightTo(potentialVessel))
+				if (requireLineOfSight && !this.vessel.hasLineOfSightTo(potentialVessel))
 				{
 					Tools.PostDebugMessage(
 						this,
@@ -295,12 +283,15 @@
 			// HACK: This might not be safe in all circumstances, but since AntennaRelays are not built until Start,
 			// we hope it is safe enough.
 			this.Kerbin = FlightGlobals.Bodies.FirstOrDefault(b => b.name == "Kerbin");
-
+		}
+
+		static AntennaRelay()
+		{
 			var config = KSP.IO.PluginConfiguration.CreateForType<AntennaRelay>();
 
 			config.load();
 
-			this.requireLineOfSight = config.GetValue<bool>("requireLineOfSight", false);
+			AntennaRelay.requireLineOfSight = config.GetValue<bool>("requireLineOfSight", false);
 
 			config.save();
 		}

--- a/ModuleLimitedDataTransmitter.cs
+++ b/ModuleLimitedDataTransmitter.cs
@@ -259,11 +259,7 @@
 		// is only one reason for this.
 		protected void PostCannotTransmitError()
 		{
-			string ErrorText = string.Format (
-				"Unable to transmit: out of range!  Maximum range = {0}m; Current range = {1}m.",
-				Tools.MuMech_ToSI((double)this.maxTransmitDistance, 2),
-				Tools.MuMech_ToSI((double)this.transmitDistance, 2)
-				);
+			string ErrorText = string.Intern("Unable to transmit: no visible receivers in range!");
 
 			this.ErrorMsg.message = string.Format(
 				"<color='#{0}{1}{2}{3}'><b>{4}</b></color>",