Please disclose if your mod was created primarily 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 Caprisun v1.0.0
CapriSunReplacer.dll
Decompiled 2 years agousing System.Diagnostics; using System.IO; using System.Reflection; using System.Runtime.CompilerServices; using System.Runtime.InteropServices; using System.Runtime.Versioning; using BepInEx; using GameNetcodeStuff; using HarmonyLib; using LethalLib.Modules; using UnityEngine; [assembly: CompilationRelaxations(8)] [assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)] [assembly: Debuggable(DebuggableAttribute.DebuggingModes.Default | DebuggableAttribute.DebuggingModes.DisableOptimizations | DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints | DebuggableAttribute.DebuggingModes.EnableEditAndContinue)] [assembly: AssemblyTitle("CapriSunReplacer")] [assembly: AssemblyDescription("")] [assembly: AssemblyConfiguration("")] [assembly: AssemblyCompany("")] [assembly: AssemblyProduct("CapriSunReplacer")] [assembly: AssemblyCopyright("Copyright © 2024")] [assembly: AssemblyTrademark("")] [assembly: ComVisible(false)] [assembly: Guid("cd148226-4604-45af-a09c-62e71c1fc8fc")] [assembly: AssemblyFileVersion("1.0.0.0")] [assembly: TargetFramework(".NETFramework,Version=v4.7.2", FrameworkDisplayName = ".NET Framework 4.7.2")] [assembly: AssemblyVersion("1.0.0.0")] namespace CapriSunReplacer { [BepInPlugin("Poseidon.CapriSunReplacer", "CapriSunReplacer", "1.0.0")] public class CapriSunReplacer : BaseUnityPlugin { private const string modGUID = "Poseidon.CapriSunReplacer"; private const string modName = "CapriSunReplacer"; private const string modVersion = "1.0.0"; private static CapriSunReplacer Instance; private void Awake() { if ((Object)(object)Instance == (Object)null) { Instance = this; } string text = Path.Combine(Path.GetDirectoryName(Assembly.GetExecutingAssembly().Location), "caprisun"); AssetBundle val = AssetBundle.LoadFromFile(text); Item val2 = val.LoadAsset<Item>("Assets/CapriSun.asset"); NetworkPrefabs.RegisterNetworkPrefab(val2.spawnPrefab); Utilities.FixMixerGroups(val2.spawnPrefab); Items.RegisterScrap(val2, 30, (LevelTypes)(-1)); ((BaseUnityPlugin)this).Logger.LogInfo((object)"Patched CapriSun Item"); } } } namespace CapriSunReplacer.Patches { [HarmonyPatch(typeof(PlayerControllerB))] internal class PlayerControllerBPatch { [HarmonyPatch("Update")] [HarmonyPostfix] private static void infiniteSprintPatch(ref float ___sprintMeter) { ___sprintMeter = 1f; } } }