Skip to content

Commit c8f0b0f

Browse files
authored
Merge pull request #3 from Falki-git/dev
Recompile for KSP2 v0.1.5.0
2 parents 17188c3 + af18906 commit c8f0b0f

File tree

3 files changed

+16
-7
lines changed

3 files changed

+16
-7
lines changed

plugin_template/swinfo.json

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -5,17 +5,17 @@
55
"name": "Skip Splash Screen",
66
"description": "Skips the splash screen and health warning. To be used only for developing mods (faster iteration).",
77
"source": "https://github.com/Falki-git/SkipSplashScreen",
8-
"version": "1.1.1",
8+
"version": "1.1.2",
99
"version_check": "https://raw.githubusercontent.com/Falki-git/SkipSplashScreen/master/plugin_template/swinfo.json",
1010
"ksp2_version": {
11-
"min": "0.1.3",
11+
"min": "0.1.5",
1212
"max": "*"
1313
},
1414
"dependencies": [
1515
{
1616
"id": "com.github.x606.spacewarp",
1717
"version": {
18-
"min": "1.4.0",
18+
"min": "1.5.2",
1919
"max": "*"
2020
}
2121
}
Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,8 @@
11
<?xml version="1.0" encoding="utf-8"?>
22
<Project Sdk="Microsoft.NET.Sdk">
3-
<!-- Project references -->
3+
<PropertyGroup>
4+
<TargetFramework>netstandard2.1</TargetFramework>
5+
</PropertyGroup>
46
<ItemGroup Label="DLL file references">
57
<!-- Add references to any DLL files you want to use in your mod here -->
68
</ItemGroup>
@@ -11,8 +13,8 @@
1113
<PackageReference Include="BepInEx.Core" Version="5.*"/>
1214
<PackageReference Include="BepInEx.PluginInfoProps" Version="2.*"/>
1315
<PackageReference Include="HarmonyX" Version="2.10.1"/>
14-
<PackageReference Include="KerbalSpaceProgram2.GameLibs" Version="0.1.3" PrivateAssets="all"/>
15-
<PackageReference Include="SpaceWarp" Version="1.4.0"/>
16-
<PackageReference Include="UnityEngine.Modules" Version="2020.3.33.1"/>
16+
<PackageReference Include="KerbalSpaceProgram2.GameLibs" Version="0.1.5" PrivateAssets="all"/>
17+
<PackageReference Include="SpaceWarp" Version="1.5.2"/>
18+
<PackageReference Include="UnityEngine.Modules" Version="2022.3.5"/>
1719
</ItemGroup>
1820
</Project>

src/SkipSplashScreen/SkipSplashScreenPlugin.cs

Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,6 +5,7 @@
55
using KSP.Game;
66
using SpaceWarp;
77
using SpaceWarp.API.Mods;
8+
using BepInEx.Logging;
89

910
namespace SkipSplashScreen;
1011

@@ -17,6 +18,8 @@ public class SkipSplashScreenPlugin : BaseSpaceWarpPlugin
1718
[PublicAPI] public const string ModName = MyPluginInfo.PLUGIN_NAME;
1819
[PublicAPI] public const string ModVer = MyPluginInfo.PLUGIN_VERSION;
1920

21+
private static ManualLogSource _logger = BepInEx.Logging.Logger.CreateLogSource("SkipSplashScreen");
22+
2023
public void Start()
2124
{
2225
Harmony.CreateAndPatchAll(typeof(SkipSplashScreenPlugin));
@@ -30,14 +33,18 @@ public void Update()
3033
return;
3134

3235
if (gameState == GameState.MainMenu)
36+
{
37+
_logger.LogDebug($"disappears into oblivion...");
3338
Destroy(this);
39+
}
3440
}
3541

3642
[HarmonyPatch(typeof(SequentialFlow), "AddAction"), HarmonyPrefix]
3743
private static bool SequentialFlow_AddAction(FlowAction action)
3844
{
3945
if (action.Name == "Creating Splash Screens Prefab")
4046
{
47+
_logger.LogDebug($"'Creating Splash Screens Prefab' action found. Skipping!");
4148
GameManager.Instance.HasPhotosensitivityWarningBeenShown = true;
4249
return false;
4350
}

0 commit comments

Comments
 (0)