Merge branch 'master' of zeetha:VOID
Merge branch 'master' of zeetha:VOID

--- a/IVOID_Module.cs
+++ b/IVOID_Module.cs
@@ -38,5 +38,13 @@
 
 		void _SaveToConfig(KSP.IO.PluginConfiguration config);
 	}
+
+	
+
+	public interface IVOID_BehaviorModule : IVOID_Module
+	{
+		void Update();
+		void FixedUpdate();
+	}
 }
 

--- a/VOID.csproj
+++ b/VOID.csproj
@@ -33,6 +33,11 @@
     <WarningLevel>4</WarningLevel>
     <ConsolePause>false</ConsolePause>
     <DefineConstants>TRACE</DefineConstants>
+    <CustomCommands>
+      <CustomCommands>
+        <Command type="AfterBuild" command="/usr/bin/cp -fv ${ProjectDir}/bin/Release/VOID.dll /mnt/games/ssd/KSP_linux/GameData/VOID/Plugins/" />
+      </CustomCommands>
+    </CustomCommands>
   </PropertyGroup>
   <Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
   <ItemGroup>
@@ -50,6 +55,7 @@
     <Compile Include="VOID_CBInfoBrowser.cs" />
     <Compile Include="VOID_Rendezvous.cs" />
     <Compile Include="VOID_VesselRegister.cs" />
+    <Compile Include="VOID_DataLogger.cs" />
   </ItemGroup>
   <ItemGroup>
     <Reference Include="Assembly-CSharp">

--- a/VOIDFlightMaster.cs
+++ b/VOIDFlightMaster.cs
@@ -56,7 +56,7 @@
 		{
 			if (this.Core == null)
 			{
-				return;
+				this.Awake();
 			}
 
 			this.Core.Update ();
@@ -65,6 +65,13 @@
 			{
 				SimManager.Instance.Gravity = VOID_Core.Instance.vessel.mainBody.gravParameter / Math.Pow(VOID_Core.Instance.vessel.mainBody.Radius, 2);
 				SimManager.Instance.TryStartSimulation();
+			}
+
+			if (this.Core.factoryReset)
+			{
+				KSP.IO.File.Delete<VOID_Core>("config.xml");
+				this.Core = null;
+				VOID_Core.Reset();
 			}
 		}
 
@@ -77,6 +84,16 @@
 
 			this.Core.FixedUpdate ();
 		}
+
+		public void OnGUI()
+		{
+			if (this.Core == null)
+			{
+				return;
+			}
+
+			this.Core.OnGUI();
+		}
     }
 }
 

--- a/VOID_CBInfoBrowser.cs
+++ b/VOID_CBInfoBrowser.cs
@@ -45,6 +45,9 @@
 		public VOID_CBInfoBrowser()
 		{
 			this._Name = "Celestial Body Information Browser";
+
+			this.WindowPos.x = 10;
+			this.WindowPos.y = 85;
 		}
 
 		public override void ModuleWindow(int _)

--- a/VOID_Core.cs
+++ b/VOID_Core.cs
@@ -55,6 +55,13 @@
 			}
 		}
 
+		public static void Reset()
+		{
+			_instance.StopGUI();
+			_instance = null;
+			_initialized = false;
+		}
+
 		public static double Constant_G = 6.674e-11;
 
 		/*
@@ -63,6 +70,8 @@
 		protected string VoidName = "VOID";
 		protected string VoidVersion = "0.9.9";
 
+		protected bool _factoryReset = false;
+
 		[AVOID_SaveValue("configValue")]
 		protected VOID_SaveValue<int> configVersion = 1;
 
@@ -70,13 +79,13 @@
 		protected bool _modulesLoaded = false;
 
 		[AVOID_SaveValue("mainWindowPos")]
-		protected VOID_SaveValue<Rect> mainWindowPos = new Rect(Screen.width / 2, Screen.height / 2, 10f, 10f);
+		protected VOID_SaveValue<Rect> mainWindowPos = new Rect(475, 575, 10f, 10f);
 
 		[AVOID_SaveValue("mainGuiMinimized")]
 		protected VOID_SaveValue<bool> mainGuiMinimized = false;
 
 		[AVOID_SaveValue("configWindowPos")]
-		protected VOID_SaveValue<Rect> configWindowPos = new Rect(Screen.width / 2, Screen.height  /2, 10f, 10f);
+		protected VOID_SaveValue<Rect> configWindowPos = new Rect(825, 625, 10f, 10f);
 
 		[AVOID_SaveValue("configWindowMinimized")]
 		protected VOID_SaveValue<bool> configWindowMinimized = true;
@@ -88,6 +97,7 @@
 		protected Texture2D VOIDIconTexture;
 		protected string VOIDIconOnPath = "VOID/Textures/void_icon_on";
 		protected string VOIDIconOffPath = "VOID/Textures/void_icon_off";
+		protected bool VOIDIconLocked = true;
 
 		protected int windowBaseID = -96518722;
 		protected int _windowID = 0;
@@ -121,13 +131,33 @@
 		public float saveTimer = 0;
 
 		protected string defaultSkin = "KSP window 2";
-		protected VOID_SaveValue<string> _skin;
+		protected VOID_SaveValue<int> _skinIdx = int.MinValue;
+		protected List<GUISkin> skin_list;
+		protected string[] forbiddenSkins =
+		{
+			"PlaqueDialogSkin",
+			"FlagBrowserSkin",
+			"SSUITextAreaDefault",
+			"ExperimentsDialogSkin",
+			"ExpRecoveryDialogSkin",
+			"KSP window 5",
+			"KSP window 6"
+		};
+		protected bool skinsLoaded = false;
 
 		public bool configDirty;
 
 		/*
 		 * Properties
 		 * */
+		public bool factoryReset
+		{
+			get
+			{
+				return this._factoryReset;
+			}
+		}
+
 		public List<IVOID_Module> Modules
 		{
 			get
@@ -140,11 +170,11 @@
 		{
 			get
 			{
-				if (this._skin == null)
-				{
-					this._skin = this.defaultSkin;
-				}
-				return AssetBase.GetGUISkin(this._skin);
+				if (this.skin_list == null || this._skinIdx < 0 || this._skinIdx > this.skin_list.Count)
+				{
+					return AssetBase.GetGUISkin(this.defaultSkin);
+				}
+				return this.skin_list[this._skinIdx];
 			}
 		}
 
@@ -191,18 +221,20 @@
 		{
 			this._Name = "VOID Core";
 
+			this._Active = true;
+
 			this.VOIDIconOn = GameDatabase.Instance.GetTexture (this.VOIDIconOnPath, false);
 			this.VOIDIconOff = GameDatabase.Instance.GetTexture (this.VOIDIconOffPath, false);
 
 			this.LoadConfig ();
 		}
 
-		protected void LoadModules()
+		protected void LoadModulesOfType<T>()
 		{
 			var types = AssemblyLoader.loadedAssemblies
 				.Select (a => a.assembly.GetExportedTypes ())
 					.SelectMany (t => t)
-					.Where (v => typeof(IVOID_Module).IsAssignableFrom (v)
+					.Where (v => typeof(T).IsAssignableFrom (v)
 					        && !(v.IsInterface || v.IsAbstract) &&
 					        !typeof(VOID_Core).IsAssignableFrom (v)
 					        );
@@ -225,7 +257,11 @@
 
 			this._modulesLoaded = true;
 
-			Tools.PostDebugMessage (string.Format ("VOID_Core: Loaded {0} modules.", this.Modules.Count));
+			Tools.PostDebugMessage(string.Format(
+				"{0}: Loaded {1} modules.",
+				this.GetType().Name,
+				this.Modules.Count
+			));
 		}
 
 		protected void LoadModule(Type T)
@@ -281,9 +317,18 @@
 				{
 					module.StartGUI ();
 				}
-				if (module.guiRunning && !module.toggleActive || !this.togglePower || !HighLogic.LoadedSceneIsFlight)
+				if (module.guiRunning && !module.toggleActive ||
+				    !this.togglePower ||
+				    !HighLogic.LoadedSceneIsFlight
+				    || this.factoryReset
+				    )
 				{
 					module.StopGUI();
+				}
+
+				if (module is IVOID_BehaviorModule)
+				{
+					((IVOID_BehaviorModule)module).Update();
 				}
 			}
 
@@ -312,6 +357,43 @@
 					this.powerAvailable = false;
 				}
 			}
+
+			foreach (IVOID_BehaviorModule module in
+			         this._modules.OfType<IVOID_BehaviorModule>().Where(m => !m.GetType().IsAbstract))
+			{
+				module.FixedUpdate();
+			}
+		}
+
+		protected void LoadSkins()
+		{
+			this.skin_list = AssetBase.FindObjectsOfTypeIncludingAssets(typeof(GUISkin))
+				.Where(s => !this.forbiddenSkins.Contains(s.name))
+					.Select(s => s as GUISkin)
+					.ToList();
+
+			Tools.PostDebugMessage(string.Format(
+				"{0}: loaded {1} GUISkins.",
+				this.GetType().Name,
+				this.skin_list.Count
+			));
+
+			if (this._skinIdx == int.MinValue)
+			{
+				this._skinIdx = this.skin_list.IndexOf(this.Skin);
+				Tools.PostDebugMessage(string.Format(
+					"{0}: resetting _skinIdx to default.",
+					this.GetType().Name
+					));
+			}
+
+			Tools.PostDebugMessage(string.Format(
+				"{0}: _skinIdx = {1}.",
+				this.GetType().Name,
+				this._skinIdx.ToString()
+				));
+
+			this.skinsLoaded = true;
 		}
 
 		protected void LoadGUIStyles()
@@ -390,20 +472,94 @@
 		{
 			this.consumeResource = GUILayout.Toggle (this.consumeResource, "Consume Resources");
 
+			this.VOIDIconLocked = GUILayout.Toggle (this.VOIDIconLocked, "Lock Icon Position");
+
+			GUILayout.BeginHorizontal(GUILayout.ExpandWidth(true));
+
+			GUILayout.Label("Skin:", GUILayout.ExpandWidth(false));
+
+			GUIContent _content = new GUIContent();
+
+			_content.text = "◄";
+			_content.tooltip = "Select previous skin";
+			if (GUILayout.Button(_content, GUILayout.ExpandWidth(true)))
+			{
+				this._skinIdx--;
+				if (this._skinIdx < 0) this._skinIdx = skin_list.Count - 1;
+				Tools.PostDebugMessage("[VOID] new this._skin = " + this._skinIdx + " :: skin_list.Count = " + skin_list.Count);
+			}
+
+			string skin_name = skin_list[this._skinIdx].name;
+			_content.text = skin_name;
+			_content.tooltip = "Current skin";
+			GUILayout.Label(_content, this.LabelStyles["center"], GUILayout.ExpandWidth(true));
+
+			_content.text = "►";
+			_content.tooltip = "Select next skin";
+			if (GUILayout.Button(_content, GUILayout.ExpandWidth(true)))
+			{
+				this._skinIdx++;
+				if (this._skinIdx >= skin_list.Count) this._skinIdx = 0;
+				Tools.PostDebugMessage("[VOID] new this._skin = " + this._skinIdx + " :: skin_list.Count = " + skin_list.Count);
+			}
+
+			GUILayout.EndHorizontal();
+
 			foreach (IVOID_Module mod in this.Modules)
 			{
 				mod.DrawConfigurables ();
 			}
+
+			this._factoryReset = GUILayout.Toggle (this._factoryReset, "Factory Reset");
+		}
+
+		public void OnGUI()
+		{
+			if (!this.VOIDIconLocked &&
+			    VOIDIconPos.value.Contains(Event.current.mousePosition)
+			    && Event.current.type == EventType.mouseDrag
+			    )
+			{
+				Tools.PostDebugMessage(string.Format(
+					"Event.current.type: {0}" +
+					"\ndelta.x: {1}; delta.y: {2}",
+					Event.current.type,
+					Event.current.delta.x,
+					Event.current.delta.y
+				));
+
+				Rect tmp = new Rect(VOIDIconPos);
+
+				tmp.x = Event.current.mousePosition.x - tmp.width / 2;
+				tmp.y = Event.current.mousePosition.y - tmp.height / 2;
+
+				if (tmp.x > Screen.width - tmp.width)
+				{
+					tmp.x = Screen.width - tmp.width;
+				}
+
+				if (tmp.y > Screen.height - tmp.height)
+				{
+					tmp.y = Screen.height - tmp.height;
+				}
+
+				VOIDIconPos = tmp;
+			}
 		}
 
 		public override void DrawGUI()
 		{
 			if (!this._modulesLoaded)
 			{
-				this.LoadModules ();
+				this.LoadModulesOfType<IVOID_Module> ();
 			}
 
 			this._windowID = this.windowBaseID;
+
+			if (!this.skinsLoaded)
+			{
+				this.LoadSkins();
+			}
 
 			GUI.skin = this.Skin;
 
@@ -414,7 +570,7 @@
 
 			this.VOIDIconTexture = this.VOIDIconOff;  //icon off default
 			if (this.togglePower) this.VOIDIconTexture = this.VOIDIconOn;     //or on if power_toggle==true
-			if (GUI.Button(new Rect(VOIDIconPos), VOIDIconTexture, new GUIStyle()))
+			if (GUI.Button(VOIDIconPos, VOIDIconTexture, new GUIStyle()) && this.VOIDIconLocked)
 			{
 				this.mainGuiMinimized = !this.mainGuiMinimized;
 			}

--- /dev/null
+++ b/VOID_DataLogger.cs
@@ -1,1 +1,226 @@
-
+//
+//  VOID_Orbital.cs
+//
+//  Author:
+//       toadicus <>
+//
+//  Copyright (c) 2013 toadicus
+//
+//  This program is free software: you can redistribute it and/or modify
+//  it under the terms of the GNU General Public License as published by
+//  the Free Software Foundation, either version 3 of the License, or
+//  (at your option) any later version.
+//
+//  This program is distributed in the hope that it will be useful,
+//  but WITHOUT ANY WARRANTY; without even the implied warranty of
+//  MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the
+//  GNU General Public License for more details.
+//
+//  You should have received a copy of the GNU General Public License
+//  along with this program.  If not, see <http://www.gnu.org/licenses/>.
+using KSP;
+using System;
+using System.Collections.Generic;
+using UnityEngine;
+
+namespace VOID
+{
+	public class VOID_DataLogger : VOID_WindowModule, IVOID_BehaviorModule
+	{
+		/*
+		 * Fields
+		 * */
+		protected bool stopwatch1_running = false;
+
+		protected bool csv_logging = false;
+		protected bool first_write = true;
+
+		protected double stopwatch1 = 0;
+
+		protected string csv_log_interval_str = "0.5";
+
+		protected float csv_log_interval;
+
+		protected double csvWriteTimer = 0;
+		protected double csvCollectTimer = 0;
+
+		protected List<string> csvList = new List<string>();
+
+		/*
+		 * Properties
+		 * */
+
+
+		/*
+		 * Methods
+		 * */
+		public VOID_DataLogger()
+		{
+			this._Name = "CSV Data Logger";
+
+			this.WindowPos.x = Screen.width - 520;
+			this.WindowPos.y = 85;
+		}
+
+		public override void ModuleWindow(int _)
+		{
+			GUIStyle txt_white = new GUIStyle(GUI.skin.label);
+			txt_white.normal.textColor = txt_white.focused.textColor = Color.white;
+			txt_white.alignment = TextAnchor.UpperRight;
+			GUIStyle txt_green = new GUIStyle(GUI.skin.label);
+			txt_green.normal.textColor = txt_green.focused.textColor = Color.green;
+			txt_green.alignment = TextAnchor.UpperRight;
+			GUIStyle txt_yellow = new GUIStyle(GUI.skin.label);
+			txt_yellow.normal.textColor = txt_yellow.focused.textColor = Color.yellow;
+			txt_yellow.alignment = TextAnchor.UpperRight;
+
+			GUILayout.BeginVertical();
+
+			GUILayout.Label("System time: " + DateTime.Now.ToString("HH:mm:ss"));
+			GUILayout.Label(Tools.ConvertInterval(stopwatch1));
+
+			GUILayout.BeginHorizontal(GUILayout.ExpandWidth(true));
+			if (GUILayout.Button("Start"))
+			{
+				if (stopwatch1_running == false) stopwatch1_running = true;
+			}
+			if (GUILayout.Button("Stop"))
+			{
+				if (stopwatch1_running == true) stopwatch1_running = false;
+			}
+			if (GUILayout.Button("Reset"))
+			{
+				if (stopwatch1_running == true) stopwatch1_running = false;
+				stopwatch1 = 0;
+			}
+			GUILayout.EndHorizontal();
+
+			GUIStyle label_style = txt_white;
+			string log_label = "Inactive";
+			if (csv_logging && vessel.situation.ToString() == "PRELAUNCH")
+			{
+				log_label = "Awaiting launch";
+				label_style = txt_yellow;
+			}
+			if (csv_logging && vessel.situation.ToString() != "PRELAUNCH")
+			{
+				log_label = "Active";
+				label_style = txt_green;
+			}
+			GUILayout.BeginHorizontal(GUILayout.ExpandWidth(true));
+			csv_logging = GUILayout.Toggle(csv_logging, "Data logging: ", GUILayout.ExpandWidth(false));
+			GUILayout.Label(log_label, label_style, GUILayout.ExpandWidth(true));
+			GUILayout.EndHorizontal();
+
+			GUILayout.BeginHorizontal(GUILayout.ExpandWidth(true));
+			GUILayout.Label("Interval: ", GUILayout.ExpandWidth(false));
+			csv_log_interval_str = GUILayout.TextField(csv_log_interval_str, GUILayout.ExpandWidth(true));
+			GUILayout.Label("s", GUILayout.ExpandWidth(false));
+			GUILayout.EndHorizontal();
+
+			float new_log_interval;
+			if (Single.TryParse(csv_log_interval_str, out new_log_interval)) csv_log_interval = new_log_interval;
+
+			GUILayout.EndVertical();
+			GUI.DragWindow();
+		}
+
+		public void Update()
+		{
+			// CSV Logging
+			// from ISA MapSat
+			if (csv_logging)
+			{
+				//data logging is on
+				//increment timers
+				csvWriteTimer += Time.deltaTime;
+				csvCollectTimer += Time.deltaTime;
+
+				if (csvCollectTimer >= csv_log_interval && vessel.situation != Vessel.Situations.PRELAUNCH)
+				{
+					//data logging is on, vessel is not prelaunch, and interval has passed
+					//write a line to the list
+					line_to_csvList();  //write to the csv
+				}
+
+				if (csvList.Count != 0 && csvWriteTimer >= 15f)
+				{
+					// csvList is not empty and interval between writings to file has elapsed
+					//write it
+					string[] csvData;
+					csvData = (string[])csvList.ToArray();
+					Innsewerants_writeData(csvData);
+					csvList.Clear();
+					csvWriteTimer = 0f;
+				}
+			}
+			else
+			{
+				//data logging is off
+				//reset any timers and clear anything from csvList
+				csvWriteTimer = 0f;
+				csvCollectTimer = 0f;
+				if (csvList.Count > 0) csvList.Clear();
+			}
+
+			if (stopwatch1_running)
+			{
+				stopwatch1 += Time.deltaTime;
+			}
+		}
+
+		public void FixedUpdate() {}
+
+		private void Innsewerants_writeData(string[] csvArray)
+		{
+			var efile = KSP.IO.File.AppendText<VOID_Core>(vessel.vesselName + "_data.csv", null);
+			foreach (string line in csvArray)
+			{
+				efile.Write(line);
+			}
+			efile.Close();
+		}
+
+		private void line_to_csvList()
+		{
+			//called if logging is on and interval has passed
+			//writes one line to the csvList
+
+			string line = "";
+			if (first_write && !KSP.IO.File.Exists<VOID_Core>(vessel.vesselName + "_data.csv", null))
+			{
+				first_write = false;
+				line += "Mission Elapsed Time (s);Altitude ASL (m);Altitude above terrain (m);Orbital Velocity (m/s);Surface Velocity (m/s);Vertical Speed (m/s);Horizontal Speed (m/s);Gee Force (gees);Temperature (°C);Gravity (m/s²);Atmosphere Density (g/m³);\n";
+			}
+			//Mission time
+			line += vessel.missionTime.ToString("F3") + ";";
+			//Altitude ASL
+			line += vessel.orbit.altitude.ToString("F3") + ";";
+			//Altitude (true)
+			double alt_true = vessel.orbit.altitude - vessel.terrainAltitude;
+			if (vessel.terrainAltitude < 0) alt_true = vessel.orbit.altitude;
+			line += alt_true.ToString("F3") + ";";
+			//Orbital velocity
+			line += vessel.orbit.vel.magnitude.ToString("F3") + ";";
+			//surface velocity
+			line += vessel.srf_velocity.magnitude.ToString("F3") + ";";
+			//vertical speed
+			line += vessel.verticalSpeed.ToString("F3") + ";";
+			//horizontal speed
+			line += vessel.horizontalSrfSpeed.ToString("F3") + ";";
+			//gee force
+			line += vessel.geeForce.ToString("F3") + ";";
+			//temperature
+			line += vessel.flightIntegrator.getExternalTemperature().ToString("F2") + ";";
+			//gravity
+			double r_vessel = vessel.mainBody.Radius + vessel.mainBody.GetAltitude(vessel.findWorldCenterOfMass());
+			double g_vessel = (VOID_Core.Constant_G * vessel.mainBody.Mass) / Math.Pow(r_vessel, 2);
+			line += g_vessel.ToString("F3") + ";";
+			//atm density
+			line += (vessel.atmDensity * 1000).ToString("F3") + ";";
+			line += "\n";
+			if (csvList.Contains(line) == false) csvList.Add(line);
+			csvCollectTimer = 0f;
+		}
+	}
+}

--- a/VOID_HUD.cs
+++ b/VOID_HUD.cs
@@ -66,6 +66,9 @@
 		public VOID_HUD() : base()
 		{
 			this._Name = "Heads-Up Display";
+
+			this._Active = true;
+
 			this.textColors.Add(Color.green);
 			this.textColors.Add(Color.black);
 			this.textColors.Add(Color.white);

--- a/VOID_Module.cs
+++ b/VOID_Module.cs
@@ -32,7 +32,7 @@
 		 * Fields
 		 * */
 		[AVOID_SaveValue("Active")]
-		protected VOID_SaveValue<bool> _Active = true;
+		protected VOID_SaveValue<bool> _Active = false;
 		protected bool _Running = false;
 
 		protected string _Name;
@@ -185,7 +185,9 @@
 	public abstract class VOID_WindowModule : VOID_Module
 	{
 		[AVOID_SaveValue("WindowPos")]
-		protected Rect WindowPos = new Rect(Screen.width / 2, Screen.height / 2, 10f, 10f);
+		protected Rect WindowPos = new Rect(Screen.width / 2, Screen.height / 2, 250f, 50f);
+		protected float defWidth = 250f;
+		protected float defHeight = 50f;
 
 		public abstract void ModuleWindow(int _);
 
@@ -197,8 +199,10 @@
 				VOID_Core.Instance.windowID,
 				_Pos,
 				this.ModuleWindow,
-				this.Name, GUILayout.Width(250),
-				GUILayout.Height(50));
+				this.Name,
+				GUILayout.Width(this.defWidth),
+				GUILayout.Height(this.defHeight)
+			);
 
 			if (_Pos != this.WindowPos)
 			{
@@ -207,12 +211,6 @@
 			}
 		}
 	}
-
-	public abstract class VOID_BehaviorModule : VOID_Module
-	{
-		public virtual void Update() {}
-		public virtual void FixedUpdate() {}
-	}
 }
 
 

--- a/VOID_Orbital.cs
+++ b/VOID_Orbital.cs
@@ -32,6 +32,9 @@
 		public VOID_Orbital()
 		{
 			this._Name = "Orbital Information";
+
+			this.WindowPos.x = Screen.width - 520f;
+			this.WindowPos.y = 250f;
 		}
 
 		public override void ModuleWindow(int _)

--- a/VOID_Rendezvous.cs
+++ b/VOID_Rendezvous.cs
@@ -39,6 +39,9 @@
 		public VOID_Rendezvous()
 		{
 			this._Name = "Rendezvous Information";
+
+			this.WindowPos.x = 845;
+			this.WindowPos.y = 85;
 		}
 
 		public override void ModuleWindow(int _)

--- a/VOID_SaveValue.cs
+++ b/VOID_SaveValue.cs
@@ -83,6 +83,11 @@
 			}
 			return r;
 		}
+
+		public new string ToString()
+		{
+			return this.value.ToString();
+		}
 	}
 
 	public interface IVOID_SaveValue

--- a/VOID_SurfAtmo.cs
+++ b/VOID_SurfAtmo.cs
@@ -29,6 +29,9 @@
 		public VOID_SurfAtmo()
 		{
 			this._Name = "Surface & Atmospheric Information";
+
+			this.WindowPos.x = Screen.width - 260f;
+			this.WindowPos.y = 85;
 		}
 
 		public override void ModuleWindow(int _)

--- a/VOID_Transfer.cs
+++ b/VOID_Transfer.cs
@@ -35,6 +35,10 @@
 		public VOID_Transfer()
 		{
 			this._Name = "Transfer Angle Information";
+
+			this.WindowPos.x = 475;
+			this.WindowPos.y = 85;
+			this.defWidth = 315;
 		}
 
 		public override void ModuleWindow(int _)

--- a/VOID_VesselInfo.cs
+++ b/VOID_VesselInfo.cs
@@ -32,6 +32,9 @@
 		public VOID_VesselInfo()
 		{
 			this._Name = "Vessel Information";
+
+			this.WindowPos.x = Screen.width - 260;
+			this.WindowPos.y = 450;
 		}
 
 		public override void ModuleWindow(int _)

--- a/VOID_VesselRegister.cs
+++ b/VOID_VesselRegister.cs
@@ -52,6 +52,10 @@
 		public VOID_VesselRegister()
 		{
 			this._Name = "Vessel Register";
+
+			this.WindowPos.x = 845;
+			this.WindowPos.y = 275;
+			this.defHeight = 375;
 		}
 
 		public override void ModuleWindow(int _)