Skip to content

Commit

Permalink
Harmony patch tweak
Browse files Browse the repository at this point in the history
  • Loading branch information
Falki-git committed Apr 14, 2023
1 parent 9105496 commit 8502928
Showing 1 changed file with 3 additions and 5 deletions.
8 changes: 3 additions & 5 deletions SkipSplashScreenProject/SkipSplashScreenPlugin.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,6 @@ namespace SkipSplashScreen;

[BepInPlugin(MyPluginInfo.PLUGIN_GUID, MyPluginInfo.PLUGIN_NAME, MyPluginInfo.PLUGIN_VERSION)]
[BepInDependency(SpaceWarpPlugin.ModGuid, SpaceWarpPlugin.ModVer)]
[HarmonyPatch(typeof(SequentialFlow))]
public class SkipSplashScreenPlugin : BaseSpaceWarpPlugin
{
// These are useful in case some other mod wants to add a dependency to this one
Expand All @@ -19,7 +18,7 @@ public class SkipSplashScreenPlugin : BaseSpaceWarpPlugin

public void Start()
{
Harmony.CreateAndPatchAll(typeof(SkipSplashScreenPlugin).Assembly);
Harmony.CreateAndPatchAll(typeof(SkipSplashScreenPlugin));
}

public void Update()
Expand All @@ -31,10 +30,9 @@ public void Update()

if (GameManager.Instance.Game.GlobalGameState.GetState() == GameState.MainMenu)
Destroy(this);
}
}

[HarmonyPatch("AddAction")]
[HarmonyPrefix]
[HarmonyPatch(typeof(SequentialFlow), "AddAction"), HarmonyPrefix]
private static bool SequentialFlow_AddAction(FlowAction action)
{
if (action.Name == "Creating Splash Screens Prefab")
Expand Down

0 comments on commit 8502928

Please sign in to comment.