Decompiled source of StopBeesOpeningDoors v1.1.0

StopBeesOpeningDoors.dll

Decompiled 8 months ago
using System.Diagnostics;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.Versioning;
using System.Security;
using System.Security.Permissions;
using BepInEx;
using BepInEx.Logging;
using HarmonyLib;

[assembly: CompilationRelaxations(8)]
[assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)]
[assembly: Debuggable(/*Could not decode attribute arguments.*/)]
[assembly: TargetFramework(".NETCoreApp,Version=v8.0", FrameworkDisplayName = ".NET 8.0")]
[assembly: AssemblyCompany("StopBeesOpeningDoors")]
[assembly: AssemblyConfiguration("Debug")]
[assembly: AssemblyDescription("According to all known laws of aviation, there is no way a bee should be able to open a door...")]
[assembly: AssemblyFileVersion("1.1.0.0")]
[assembly: AssemblyInformationalVersion("1.1.0")]
[assembly: AssemblyProduct("StopBeesOpeningDoors")]
[assembly: AssemblyTitle("StopBeesOpeningDoors")]
[assembly: SecurityPermission(8, SkipVerification = true)]
[assembly: AssemblyVersion("1.1.0.0")]
[module: UnverifiableCode]
[module: RefSafetyRules(11)]
namespace StopBeesOpeningDoors;

[HarmonyPatch(typeof(ButlerBeesEnemyAI), "Start")]
public static class ButlerBeesEnemyAIPatch
{
	[HarmonyPostfix]
	private static void Postfix(ButlerBeesEnemyAI __instance)
	{
		((EnemyAI)__instance).openDoorSpeedMultiplier = 0f;
	}
}
[HarmonyPatch(typeof(RedLocustBees), "Start")]
public static class RedLocustBeesPatch
{
	[HarmonyPostfix]
	private static void Postfix(RedLocustBees __instance)
	{
		((EnemyAI)__instance).openDoorSpeedMultiplier = 0f;
	}
}
[BepInPlugin("StopBeesOpeningDoors", "StopBeesOpeningDoors", "1.1.0")]
public class Plugin : BaseUnityPlugin
{
	public static ManualLogSource Logger;

	private static readonly Harmony Harmony = new Harmony("StopBeesOpeningDoors");

	private void Awake()
	{
		Logger = ((BaseUnityPlugin)this).Logger;
		Logger.LogInfo((object)"Plugin StopBeesOpeningDoors is loading...");
		Harmony.PatchAll();
		Logger.LogInfo((object)"Plugin StopBeesOpeningDoors is loaded!");
	}
}
public static class PluginInfo
{
	public const string PLUGIN_GUID = "StopBeesOpeningDoors";

	public const string PLUGIN_NAME = "StopBeesOpeningDoors";

	public const string PLUGIN_VERSION = "1.1.0";
}