Skip to content

Commit fe9a3f3

Browse files
committed
Merge 1.6.2.0 to master
2 parents b5588b4 + 54fa0c9 commit fe9a3f3

File tree

5 files changed

+28
-9
lines changed

5 files changed

+28
-9
lines changed

PluginFiles/ReadMe-TransferWindowPlanner.txt

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,10 @@ LICENSE
2727
This work is licensed under an MIT license as outlined at the OSI site. Visit the documentation site for more details and Attribution
2828

2929
VERSION HISTORY
30+
Version 1.6.2.0 - KSP Version: 1.3.0
31+
- Recompile for 1.3.0
32+
- Added guard clause to always create the PluginData folder if its missing
33+
3034
Version 1.6.1.0 - KSP Version: 1.2.2
3135
- Moved settings to PluginData to help out for MM peeps
3236
- Tidied up some minor obselesence

TransferWindowPlanner/Framework/ConfigNodeStorage.cs

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -156,6 +156,19 @@ public Boolean Save()
156156
public Boolean Save(String fileFullName)
157157
{
158158
Boolean blnReturn = false;
159+
try
160+
{
161+
if (!System.IO.Directory.Exists(System.IO.Path.GetDirectoryName(fileFullName)))
162+
{
163+
System.IO.Directory.CreateDirectory(System.IO.Path.GetDirectoryName(fileFullName));
164+
}
165+
}
166+
catch (Exception ex)
167+
{
168+
LogFormatted("Unable to create directory for ConfigNode file({0})-Error:{1}", fileFullName, ex.Message);
169+
blnReturn = false;
170+
}
171+
159172
try
160173
{
161174
//Encode the current object

TransferWindowPlanner/Properties/AssemblyInfo.cs

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,5 +32,5 @@
3232
// You can specify all the values or you can default the Build and Revision Numbers
3333
// by using the '*' as shown below:
3434
// [assembly: AssemblyVersion("1.0.*")]
35-
[assembly: AssemblyVersion("1.6.1.0")]
36-
[assembly: AssemblyFileVersion("1.6.1.0")]
35+
[assembly: AssemblyVersion("1.6.2.0")]
36+
[assembly: AssemblyFileVersion("1.6.2.0")]

TransferWindowPlanner/TWP.cs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,10 @@ internal override void Awake()
4444
{
4545
LogFormatted("Awakening the TransferWindowPlanner (TWP)");
4646

47+
LogFormatted("Checking for PluginData folder");
48+
if (!System.IO.Directory.Exists(Resources.PathPlugin + "/PluginData"))
49+
System.IO.Directory.CreateDirectory(Resources.PathPlugin + "/PluginData");
50+
4751
LogFormatted("Loading Settings");
4852
settings = new Settings("PluginData/settings.cfg");
4953
Boolean blnSettingsLoaded = settings.Load();
@@ -54,8 +58,6 @@ internal override void Awake()
5458
if (blnSettingsLoaded)
5559
{
5660
settings.FilePath = "PluginData/settings.cfg";
57-
if (!System.IO.Directory.Exists(Resources.PathPlugin + "/PluginData"))
58-
System.IO.Directory.CreateDirectory(Resources.PathPlugin + "/PluginData");
5961
System.IO.File.Move(Resources.PathPlugin + "/settings.cfg", Resources.PathPlugin + "/PluginData/settings.cfg");
6062
}
6163
}

TransferWindowPlanner/TransferWindowPlanner.version

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -5,22 +5,22 @@
55
"VERSION": {
66
"MAJOR": 1,
77
"MINOR": 6,
8-
"PATCH": 1,
8+
"PATCH": 2,
99
"BUILD": 0
1010
},
1111
"KSP_VERSION": {
1212
"MAJOR": 1,
13-
"MINOR": 2,
14-
"PATCH": 2
13+
"MINOR": 3,
14+
"PATCH": 0
1515
},
1616
"KSP_VERSION_MIN": {
1717
"MAJOR": 1,
18-
"MINOR": 2,
18+
"MINOR": 3,
1919
"PATCH": 0
2020
},
2121
"KSP_VERSION_MAX": {
2222
"MAJOR": 1,
23-
"MINOR": 2,
23+
"MINOR": 3,
2424
"PATCH": 99
2525
}
2626
}

0 commit comments

Comments
 (0)