Decompiled source of NoQuicksand v1.0.1

NoQuicksand.dll

Decompiled 9 months ago
using System.Diagnostics;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using System.Runtime.Versioning;
using System.Threading;
using BepInEx;
using BepInEx.Logging;
using HarmonyLib;

[assembly: CompilationRelaxations(8)]
[assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)]
[assembly: Debuggable(DebuggableAttribute.DebuggingModes.Default | DebuggableAttribute.DebuggingModes.DisableOptimizations | DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints | DebuggableAttribute.DebuggingModes.EnableEditAndContinue)]
[assembly: AssemblyTitle("NoQuicksand")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("NoQuicksand")]
[assembly: AssemblyCopyright("Copyright ©  2024")]
[assembly: AssemblyTrademark("")]
[assembly: ComVisible(false)]
[assembly: Guid("5806cf39-99da-4a27-af68-02bd2d34eee6")]
[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 NoQuicksand;

[BepInPlugin("jogatinas.noQuicksand", "noQuicksand", "1.0.0")]
public class Plugin : BaseUnityPlugin
{
	public const string PLUGIN_GUID = "jogatinas.noQuicksand";

	public const string PLUGIN_NAME = "noQuicksand";

	public const string PLUGIN_VERSION = "1.0.0";

	private readonly Harmony harmony = new Harmony("noQuicksand");

	public static ManualLogSource Print;

	private void Awake()
	{
		Print = Logger.CreateLogSource("noQuicksand");
		Print.LogInfo((object)"EU ODEIO AREIA MOVEDIÇA!!!!");
		Thread.Sleep(1500);
		harmony.PatchAll(typeof(Plugin));
	}

	[HarmonyPatch(typeof(RoundManager), "SpawnOutsideHazards")]
	[HarmonyPrefix]
	public static bool AvoidQuickSand()
	{
		//IL_0006: Unknown result type (might be due to invalid IL or missing references)
		//IL_000c: Invalid comparison between Unknown and I4
		if ((int)TimeOfDay.Instance.currentLevelWeather == 1)
		{
			Print.LogInfo((object)"A Areia movediça se foi embora hahahahha");
			return false;
		}
		return true;
	}
}