Skip to content

Commit a083a8d

Browse files
committed
Making thing thing compilable on KSP 1.3.1 (and still working on KSP 1.8 )
1 parent b03b7c7 commit a083a8d

File tree

6 files changed

+21
-8
lines changed

6 files changed

+21
-8
lines changed

Source/ModuleManager/Cats/CatAnimator.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
using System.Collections;
22
using UnityEngine;
33

4+
#if CATS
45
namespace ModuleManager.Cats
56
{
67
class CatAnimator : MonoBehaviour
@@ -36,3 +37,4 @@ IEnumerator Animate()
3637
}
3738
}
3839
}
40+
#endif

Source/ModuleManager/Cats/CatManager.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2,6 +2,7 @@
22
using UnityEngine;
33
using K = KSPe.Util.Log;
44

5+
#if CATS
56
namespace ModuleManager.Cats
67
{
78
public static class CatManager
@@ -122,3 +123,4 @@ private static GameObject LaunchCat(int scale)
122123
internal static readonly K.Logger LOG = K.Logger.CreateForType<CatAnimator>(true);
123124
}
124125
}
126+
#endif

Source/ModuleManager/Cats/CatMover.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,7 @@
11
using System.Collections;
22
using UnityEngine;
33

4+
#if CATS
45
namespace ModuleManager.Cats
56
{
67
public class CatMover : MonoBehaviour
@@ -77,3 +78,4 @@ void Update()
7778

7879
}
7980
}
81+
#endif

Source/ModuleManager/Cats/CatOrbiter.cs

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44
using UnityEngine;
55
using Random = UnityEngine.Random;
66

7+
#if CATS
78
namespace ModuleManager.Cats
89
{
910
class CatOrbiter : MonoBehaviour
@@ -134,3 +135,4 @@ void FixedUpdate()
134135
}
135136
}
136137
}
138+
#endif

Source/ModuleManager/ModuleManager.cs

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,9 @@
77
using System.Reflection;
88
using TMPro;
99
using UnityEngine;
10+
#if CATS
1011
using ModuleManager.Cats;
12+
#endif
1113
using ModuleManager.Extensions;
1214
using ModuleManager.Logging;
1315

@@ -157,14 +159,14 @@ internal void Awake()
157159
private TextMeshProUGUI errors;
158160
private TextMeshProUGUI warning;
159161

160-
161162
private void Start()
162163
{
164+
#if CATS
163165
if (nCats)
164166
CatManager.LaunchCats();
165167
else if (nyan)
166168
CatManager.LaunchCat();
167-
169+
#endif
168170
Canvas canvas = LoadingScreen.Instance.GetComponentInChildren<Canvas>();
169171

170172
status = CreateTextObject(canvas, "MMStatus");

Source/ModuleManager/ModuleManager.csproj

Lines changed: 9 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -111,17 +111,17 @@
111111
<ItemGroup>
112112
<Reference Include="System" />
113113
<Reference Include="System.Drawing" />
114+
<Reference Include="KSPe">
115+
<HintPath>..\..\..\..\..\..\LIB\plugins\KSPe.dll</HintPath>
116+
</Reference>
114117
<Reference Include="Assembly-CSharp">
115-
<HintPath>..\..\..\..\..\..\LIB\managed\1.4.1\Assembly-CSharp.dll</HintPath>
118+
<HintPath>..\..\..\..\..\..\LIB\managed\1.3.1\Assembly-CSharp.dll</HintPath>
116119
</Reference>
117120
<Reference Include="UnityEngine.UI">
118-
<HintPath>..\..\..\..\..\..\LIB\managed\1.4.1\UnityEngine.UI.dll</HintPath>
121+
<HintPath>..\..\..\..\..\..\LIB\managed\1.3.1\UnityEngine.UI.dll</HintPath>
119122
</Reference>
120123
<Reference Include="UnityEngine">
121-
<HintPath>..\..\..\..\..\..\LIB\managed\1.4.1\UnityEngine.dll</HintPath>
122-
</Reference>
123-
<Reference Include="KSPe">
124-
<HintPath>..\..\..\..\..\..\LIB\plugins\KSPe.dll</HintPath>
124+
<HintPath>..\..\..\..\..\..\LIB\managed\1.3.1\UnityEngine.dll</HintPath>
125125
</Reference>
126126
</ItemGroup>
127127
<ItemGroup>
@@ -173,6 +173,9 @@
173173
<ItemGroup>
174174
<None Include="Properties\rainbow2.png" />
175175
</ItemGroup>
176+
<ItemGroup>
177+
<Folder Include="Cats\" />
178+
</ItemGroup>
176179
<Import Project="$(MSBuildBinPath)\Microsoft.CSharp.targets" />
177180
<PropertyGroup>
178181
<PostBuildEvent></PostBuildEvent>

0 commit comments

Comments
 (0)