Skip to content

Commit da2f288

Browse files
authored
Merge pull request #27 from Sigma88/Development
Sigma Binary 1.6.1
2 parents 54405bd + 55d173c commit da2f288

File tree

7 files changed

+110
-104
lines changed

7 files changed

+110
-104
lines changed

Changelog.txt

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
**v1.6.1**
2+
3+
- Fixed Kopernicus compatibility (again)
4+
5+
16
**v1.6.0**
27

38
- Updated to KSP 1.2.1 and Kopernicus 1.2.1-1
-1 KB
Binary file not shown.

GameData/Sigma/Binary/SigmaBinary.version

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
{
1414
"MAJOR": 1,
1515
"MINOR": 6,
16-
"PATCH": 0,
16+
"PATCH": 1,
1717
"BUILD": 0
1818
},
1919
"KSP_VERSION":

License.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -5,4 +5,4 @@ All Rights Reserved
55

66

77
For more info visit the KSP Forum Thread:
8-
http://forum.kerbalspaceprogram.com/index.php?/topic/115114-/
8+
http://forum.kerbalspaceprogram.com/index.php?/topic/115114-0
-1 KB
Binary file not shown.

[Source]/SigmaBinary/LateFixes.cs

Lines changed: 6 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -4,11 +4,11 @@
44

55
using UnityEngine;
66

7+
using Kopernicus;
78
using Kopernicus.Components;
89
using Kopernicus.Configuration;
910
using Kopernicus.OnDemand;
10-
using System.Threading;
11-
using System.Reflection;
11+
1212
using KSP.UI.Screens;
1313

1414

@@ -76,22 +76,22 @@ public static void TextureFixer(Body body1, Body body2, List<Body> list)
7676
else
7777
pBody.generatedBody.celestialBody.gameObject.AddComponent<NameChanger>().newName = "3.1415";
7878
}
79-
else if (Kopernicus.Templates.orbitPatches.ContainsKey(pBody.name) && Kopernicus.Templates.orbitPatches[pBody.name].GetValue("referenceBody") == "Sun")
79+
else if (pBody.generatedBody.celestialBody.Has("orbitPatches") && pBody.generatedBody.celestialBody.Get<ConfigNode>("orbitPatches").GetValue("referenceBody") == "Sun")
8080
{
8181
pList.Add(pBody.generatedBody.celestialBody, pBody.generatedBody.orbitDriver.orbit.semiMajorAxis);
8282
}
83-
else if (pBody.orbit.referenceBody == "Sun" && !(Kopernicus.Templates.orbitPatches.ContainsKey(pBody.name) && Kopernicus.Templates.orbitPatches[pBody.name].GetValue("referenceBody") != "Sun"))
83+
else if (pBody.orbit.referenceBody == "Sun" && !(pBody.generatedBody.celestialBody.Has("orbitPatches") && pBody.generatedBody.celestialBody.Get<ConfigNode>("orbitPatches").GetValue("referenceBody") != "Sun"))
8484
{
8585
if (!(pBody.name == "Kerbin" && SigmaBinary.kerbinFixer != "Sun"))
8686
{
8787
pList.Add(pBody.generatedBody.celestialBody, pBody.generatedBody.orbitDriver.orbit.semiMajorAxis);
8888
}
8989
}
9090

91-
if (pList.ContainsKey(pBody.generatedBody.celestialBody) && Kopernicus.Templates.orbitPatches.ContainsKey(pBody.name) && Kopernicus.Templates.orbitPatches[pBody.name].GetValue("semiMajorAxis") != null)
91+
if (pList.ContainsKey(pBody.generatedBody.celestialBody) && pBody.generatedBody.celestialBody.Has("orbitPatches") && pBody.generatedBody.celestialBody.Get<ConfigNode>("orbitPatches").GetValue("semiMajorAxis") != null)
9292
{
9393
NumericParser<double> sma = new NumericParser<double>();
94-
sma.SetFromString(Kopernicus.Templates.orbitPatches[pBody.name].GetValue("semiMajorAxis"));
94+
sma.SetFromString(pBody.generatedBody.celestialBody.Get<ConfigNode>("orbitPatches").GetValue("semiMajorAxis"));
9595
pList[pBody.generatedBody.celestialBody] = sma.value;
9696
}
9797
}

[Source]/SigmaBinary/SigmaBinary.cs

Lines changed: 97 additions & 96 deletions
Large diffs are not rendered by default.

0 commit comments

Comments
 (0)