using System; using System.Diagnostics; using System.Reflection; using System.Runtime.CompilerServices; using System.Runtime.InteropServices; using System.Runtime.Versioning; using BepInEx; using BepInEx.Configuration; using BepInEx.Logging; using HarmonyLib; [assembly: CompilationRelaxations(8)] [assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)] [assembly: Debuggable(DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints)] [assembly: AssemblyTitle("ExtraCosmeticBox")] [assembly: AssemblyDescription("")] [assembly: AssemblyConfiguration("")] [assembly: AssemblyCompany("")] [assembly: AssemblyProduct("ExtraCosmeticBox")] [assembly: AssemblyCopyright("Copyright © 2026")] [assembly: AssemblyTrademark("")] [assembly: ComVisible(false)] [assembly: Guid("d45565f6-6ea3-4fdd-b5bd-ab211bf51448")] [assembly: AssemblyFileVersion("1.0.7.0")] [assembly: TargetFramework(".NETFramework,Version=v4.8", FrameworkDisplayName = ".NET Framework 4.8")] [assembly: AssemblyVersion("1.0.7.0")] namespace ExtraCosmeticBoxMod; [BepInPlugin("com.HalHally.extra_cosmeticbox", "Extra Cosmetic Box", "1.0.7")] [BepInDependency(/*Could not decode attribute arguments.*/)] public class ExtraCosmeticBoxPlugin : BaseUnityPlugin { public static ConfigEntry ExtraRolls; internal static ManualLogSource Logger; private void Awake() { //IL_002e: Unknown result type (might be due to invalid IL or missing references) //IL_0038: Expected O, but got Unknown //IL_0042: Unknown result type (might be due to invalid IL or missing references) Logger = ((BaseUnityPlugin)this).Logger; ExtraRolls = ((BaseUnityPlugin)this).Config.Bind("Cosmetic Box", "Additional Cosmetic Rolls", 2, new ConfigDescription("Adds extra cosmetic box roll attempts.", (AcceptableValueBase)(object)new AcceptableValueRange(0, 10), Array.Empty())); new Harmony("com.HalHally.extra_cosmeticbox").PatchAll(); Logger.LogInfo((object)"ExtraCosmeticBox patch applied."); } } [HarmonyPatch(typeof(ValuableDirector), "CosmeticWorldObjectLevelLoopsClampedGet")] public static class HalHally_ExtraCosmeticBox_LoopPatch { [HarmonyPostfix] private static void Postfix(ref int __result) { __result += ExtraCosmeticBoxPlugin.ExtraRolls.Value; ExtraCosmeticBoxPlugin.Logger.LogInfo((object)$"Added {ExtraCosmeticBoxPlugin.ExtraRolls.Value} extra cosmetic rolls."); } }