Please disclose if any significant portion of your mod was created using AI tools by adding the 'AI Generated' category. Failing to do so may result in the mod being removed from Thunderstore.
Decompiled source of SkillGainMultiplier v1.0.0
SkillGainMultiplier.dll
Decompiled a month agousing System; using System.Diagnostics; using System.Reflection; using System.Runtime.CompilerServices; using System.Runtime.Versioning; using BepInEx; using BepInEx.Configuration; 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(".NETFramework,Version=v4.7.2", FrameworkDisplayName = ".NET Framework 4.7.2")] [assembly: AssemblyCompany("SkillGainMultiplier")] [assembly: AssemblyConfiguration("Debug")] [assembly: AssemblyFileVersion("1.0.0.0")] [assembly: AssemblyInformationalVersion("1.0.0")] [assembly: AssemblyProduct("SkillGainMultiplier")] [assembly: AssemblyTitle("SkillGainMultiplier")] [assembly: AssemblyVersion("1.0.0.0")] [module: RefSafetyRules(11)] namespace Microsoft.CodeAnalysis { [CompilerGenerated] [Embedded] internal sealed class EmbeddedAttribute : Attribute { } } namespace System.Runtime.CompilerServices { [CompilerGenerated] [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 SkillGainMultiplier { [BepInPlugin("bakkemo.erguden.skillgainmultiplier", "Skill Gain Multiplier", "1.0.0")] public class SkillGainMultiplierPlugin : BaseUnityPlugin { public const string PluginGuid = "bakkemo.erguden.skillgainmultiplier"; public const string PluginName = "Skill Gain Multiplier"; public const string PluginVersion = "1.0.0"; internal static ConfigEntry<float> SkillMultiplier; private Harmony _harmony; private void Awake() { //IL_002f: Unknown result type (might be due to invalid IL or missing references) //IL_0039: Expected O, but got Unknown //IL_0044: Unknown result type (might be due to invalid IL or missing references) //IL_004e: Expected O, but got Unknown SkillMultiplier = ((BaseUnityPlugin)this).Config.Bind<float>("General", "SkillGainMultiplier", 2f, new ConfigDescription("Multiplier applied to all skill XP gained. 1.0 = vanilla, 1.5 = +50%, 2.0 = +100%, 3.0 = +200%.", (AcceptableValueBase)(object)new AcceptableValueRange<float>(0f, 100f), Array.Empty<object>())); _harmony = new Harmony("bakkemo.erguden.skillgainmultiplier"); _harmony.PatchAll(); ((BaseUnityPlugin)this).Logger.LogInfo((object)("Skill Gain Multiplier 1.0.0 loaded. " + $"Current XP multiplier: {SkillMultiplier.Value}x")); } private void OnDestroy() { Harmony harmony = _harmony; if (harmony != null) { harmony.UnpatchSelf(); } } } [HarmonyPatch(typeof(Skills), "RaiseSkill")] public static class SkillsRaiseSkillPatch { [HarmonyPrefix] private static void Prefix(ref float factor) { factor *= SkillGainMultiplierPlugin.SkillMultiplier.Value; } } }