Decompiled source of Nicks Mod v1.0.0

NicksMod.dll

Decompiled 11 months ago
using System.Diagnostics;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using System.Runtime.Versioning;
using BepInEx;
using BepInEx.Logging;
using GameNetcodeStuff;
using HarmonyLib;
using NicksMod.Patches;
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("NicksMod")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("NicksMod")]
[assembly: AssemblyCopyright("Copyright ©  2023")]
[assembly: AssemblyTrademark("")]
[assembly: ComVisible(false)]
[assembly: Guid("3613c385-c60a-4cbb-b60f-a704296a13b0")]
[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 NicksMod
{
	[BepInPlugin("Poseidon.NicksMod", "Nicks Mod", "1.0.0.0")]
	public class ModBase : BaseUnityPlugin
	{
		private const string modGUID = "Poseidon.NicksMod";

		private const string modName = "Nicks Mod";

		private const string modVersion = "1.0.0.0";

		private readonly Harmony harmony = new Harmony("Poseidon.NicksMod");

		private static ModBase instance;

		internal ManualLogSource mls;

		private void Awake()
		{
			if ((Object)(object)instance == (Object)null)
			{
				instance = this;
			}
			mls = Logger.CreateLogSource("Poseidon.NicksMod");
			mls.LogInfo((object)"The test mod has launched, sweet.");
			harmony.PatchAll(typeof(ModBase));
			harmony.PatchAll(typeof(PlayerControllerBPatch));
		}
	}
}
namespace NicksMod.Patches
{
	[HarmonyPatch(typeof(PlayerControllerB))]
	internal class PlayerControllerBPatch
	{
		[HarmonyPatch("Update")]
		[HarmonyPostfix]
		private static void infiniteSprintPatch(ref float ___sprintMeter)
		{
			___sprintMeter = 1f;
		}
	}
}