Decompiled source of UnlockAllFollowerForms v1.0.0

Plugins/UnlockAllFollowerForms.dll

Decompiled 6 months ago
using System;
using System.Diagnostics;
using System.IO;
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;
using Microsoft.CodeAnalysis;

[assembly: CompilationRelaxations(8)]
[assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)]
[assembly: Debuggable(DebuggableAttribute.DebuggingModes.Default | DebuggableAttribute.DebuggingModes.DisableOptimizations | DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints | DebuggableAttribute.DebuggingModes.EnableEditAndContinue)]
[assembly: TargetFramework(".NETStandard,Version=v2.0", FrameworkDisplayName = ".NET Standard 2.0")]
[assembly: AssemblyCompany("UnlockAllFollowerForms")]
[assembly: AssemblyConfiguration("Debug")]
[assembly: AssemblyFileVersion("1.0.0")]
[assembly: AssemblyInformationalVersion("1.0.0+bb1d850312a2f355da24e81710c072142ea06ddd")]
[assembly: AssemblyProduct("UnlockAllFollowerForms")]
[assembly: AssemblyTitle("UnlockAllFollowerForms")]
[assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)]
[assembly: AssemblyVersion("1.0.0.0")]
[module: UnverifiableCode]
[module: RefSafetyRules(11)]
namespace Microsoft.CodeAnalysis
{
	[CompilerGenerated]
	[Microsoft.CodeAnalysis.Embedded]
	internal sealed class EmbeddedAttribute : Attribute
	{
	}
}
namespace System.Runtime.CompilerServices
{
	[CompilerGenerated]
	[Microsoft.CodeAnalysis.Embedded]
	[AttributeUsage(AttributeTargets.Module, AllowMultiple = false, Inherited = false)]
	internal sealed class RefSafetyRulesAttribute : Attribute
	{
		public readonly int Version;

		public RefSafetyRulesAttribute(int P_0)
		{
			Version = P_0;
		}
	}
}
namespace CotLTemplateMod
{
	public static class Logging
	{
		public static ManualLogSource Logger => Plugin.Log;

		public static void Log(LogLevel level, string message)
		{
			//IL_0005: Unknown result type (might be due to invalid IL or missing references)
			Logger.Log(level, (object)message);
		}

		public static void LogInfo(string message)
		{
			Logger.LogInfo((object)message);
		}

		public static void LogDebug(string message)
		{
			Logger.LogDebug((object)message);
		}

		public static void LogWarning(string message)
		{
			Logger.LogWarning((object)message);
		}

		public static void LogError(string message)
		{
			Logger.LogError((object)message);
		}

		public static void LogFatal(string message)
		{
			Logger.LogFatal((object)message);
		}
	}
	[BepInPlugin("xyz.zelzmiy.UnlockAllFollowerForms", "UnlockAllFOllowerForms", "1.0.0")]
	[BepInDependency(/*Could not decode attribute arguments.*/)]
	[HarmonyPatch]
	public class Plugin : BaseUnityPlugin
	{
		public const string PluginGuid = "xyz.zelzmiy.UnlockAllFollowerForms";

		public const string PluginName = "UnlockAllFOllowerForms";

		public const string PluginVer = "1.0.0";

		internal static ManualLogSource Log;

		internal static readonly Harmony Harmony = new Harmony("xyz.zelzmiy.UnlockAllFollowerForms");

		internal static string PluginPath;

		private void Awake()
		{
			Log = ((BaseUnityPlugin)this).Logger;
			PluginPath = Path.GetDirectoryName(((BaseUnityPlugin)this).Info.Location);
		}

		private void OnEnable()
		{
			Harmony.PatchAll();
		}

		private void OnDisable()
		{
			Harmony.UnpatchSelf();
			Logging.LogInfo("Unloaded UnlockAllFOllowerForms!");
		}

		[HarmonyPatch(typeof(DataManager), "GetFollowerSkinUnlocked")]
		[HarmonyPrefix]
		public static bool UnlockAllSkins(ref bool __result)
		{
			__result = true;
			return false;
		}
	}
}