forked from nikita/muzika-gromche
Save Harmony own instance in private static
That's how other mods do it. Might be useful to reload patches.
This commit is contained in:
parent
38c9472cb1
commit
a4ca1c86ec
|
|
@ -27,6 +27,7 @@ namespace MuzikaGromche
|
|||
[BepInDependency("BMX.LobbyCompatibility", BepInDependency.DependencyFlags.SoftDependency)]
|
||||
public class Plugin : BaseUnityPlugin
|
||||
{
|
||||
private static Harmony Harmony = null!;
|
||||
internal static ManualLogSource Log = null!;
|
||||
internal new static Config Config { get; private set; } = null!;
|
||||
|
||||
|
|
@ -945,17 +946,17 @@ namespace MuzikaGromche
|
|||
Config = new Config(base.Config);
|
||||
DiscoBallManager.Load();
|
||||
PoweredLightsAnimators.Load();
|
||||
var harmony = new Harmony(PluginInfo.PLUGIN_NAME);
|
||||
harmony.PatchAll(typeof(GameNetworkManagerPatch));
|
||||
harmony.PatchAll(typeof(JesterPatch));
|
||||
harmony.PatchAll(typeof(EnemyAIPatch));
|
||||
harmony.PatchAll(typeof(PoweredLightsAnimatorsPatch));
|
||||
harmony.PatchAll(typeof(AllPoweredLightsPatch));
|
||||
harmony.PatchAll(typeof(DiscoBallTilePatch));
|
||||
harmony.PatchAll(typeof(DiscoBallDespawnPatch));
|
||||
harmony.PatchAll(typeof(SpawnRatePatch));
|
||||
harmony.PatchAll(typeof(DeathScreenGameOverTextResetPatch));
|
||||
harmony.PatchAll(typeof(ScreenFiltersManager.HUDManagerScreenFiltersPatch));
|
||||
Harmony = new Harmony(PluginInfo.PLUGIN_NAME);
|
||||
Harmony.PatchAll(typeof(GameNetworkManagerPatch));
|
||||
Harmony.PatchAll(typeof(JesterPatch));
|
||||
Harmony.PatchAll(typeof(EnemyAIPatch));
|
||||
Harmony.PatchAll(typeof(PoweredLightsAnimatorsPatch));
|
||||
Harmony.PatchAll(typeof(AllPoweredLightsPatch));
|
||||
Harmony.PatchAll(typeof(DiscoBallTilePatch));
|
||||
Harmony.PatchAll(typeof(DiscoBallDespawnPatch));
|
||||
Harmony.PatchAll(typeof(SpawnRatePatch));
|
||||
Harmony.PatchAll(typeof(DeathScreenGameOverTextResetPatch));
|
||||
Harmony.PatchAll(typeof(ScreenFiltersManager.HUDManagerScreenFiltersPatch));
|
||||
NetcodePatcher();
|
||||
Compatibility.Register(this);
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in New Issue