Decompiled source of True Darkness v1.3.0

TrueDarkness.dll

Decompiled a month ago
using System;
using System.Diagnostics;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.Versioning;
using System.Security;
using System.Security.Permissions;
using BepInEx;
using BepInEx.Bootstrap;
using BepInEx.Configuration;
using BepInEx.Logging;
using CSync.Extensions;
using CSync.Lib;
using Friskzips.TrueDarkness;
using Friskzips.TrueDarkness.configStuff;
using Friskzips.TrueDarkness.patch;
using Friskzips.clientPatch;
using GameNetcodeStuff;
using HarmonyLib;
using LCOffice.Patches;
using LethalConfig;
using LethalConfig.ConfigItems;
using LethalConfig.ConfigItems.Options;
using LobbyCompatibility.Attributes;
using Microsoft.CodeAnalysis;
using MoreShipUpgrades.UpgradeComponents.TierUpgrades.Player;
using Unity.Netcode;
using UnityEngine;

[assembly: CompilationRelaxations(8)]
[assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)]
[assembly: Debuggable(DebuggableAttribute.DebuggingModes.Default | DebuggableAttribute.DebuggingModes.DisableOptimizations | DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints | DebuggableAttribute.DebuggingModes.EnableEditAndContinue)]
[assembly: TargetFramework(".NETStandard,Version=v2.1", FrameworkDisplayName = ".NET Standard 2.1")]
[assembly: IgnoresAccessChecksTo("0Harmony")]
[assembly: IgnoresAccessChecksTo("AmazingAssets.TerrainToMesh")]
[assembly: IgnoresAccessChecksTo("Assembly-CSharp-firstpass")]
[assembly: IgnoresAccessChecksTo("Assembly-CSharp")]
[assembly: IgnoresAccessChecksTo("BepInEx")]
[assembly: IgnoresAccessChecksTo("BMX.LobbyCompatibility")]
[assembly: IgnoresAccessChecksTo("ClientNetworkTransform")]
[assembly: IgnoresAccessChecksTo("com.sigurd.csync")]
[assembly: IgnoresAccessChecksTo("DissonanceVoip")]
[assembly: IgnoresAccessChecksTo("Facepunch Transport for Netcode for GameObjects")]
[assembly: IgnoresAccessChecksTo("Facepunch.Steamworks.Win64")]
[assembly: IgnoresAccessChecksTo("LCOffice")]
[assembly: IgnoresAccessChecksTo("LethalConfig")]
[assembly: IgnoresAccessChecksTo("Microsoft.Win32.Primitives")]
[assembly: IgnoresAccessChecksTo("Mono.Cecil")]
[assembly: IgnoresAccessChecksTo("Mono.Cecil.Mdb")]
[assembly: IgnoresAccessChecksTo("Mono.Cecil.Pdb")]
[assembly: IgnoresAccessChecksTo("Mono.Cecil.Rocks")]
[assembly: IgnoresAccessChecksTo("MonoMod.RuntimeDetour")]
[assembly: IgnoresAccessChecksTo("MonoMod.Utils")]
[assembly: IgnoresAccessChecksTo("MoreShipUpgrades")]
[assembly: IgnoresAccessChecksTo("mscorlib")]
[assembly: IgnoresAccessChecksTo("netstandard")]
[assembly: IgnoresAccessChecksTo("Newtonsoft.Json")]
[assembly: IgnoresAccessChecksTo("System.AppContext")]
[assembly: IgnoresAccessChecksTo("System.Buffers")]
[assembly: IgnoresAccessChecksTo("System.Collections.Concurrent")]
[assembly: IgnoresAccessChecksTo("System.Collections")]
[assembly: IgnoresAccessChecksTo("System.Collections.NonGeneric")]
[assembly: IgnoresAccessChecksTo("System.Collections.Specialized")]
[assembly: IgnoresAccessChecksTo("System.ComponentModel.Composition")]
[assembly: IgnoresAccessChecksTo("System.ComponentModel")]
[assembly: IgnoresAccessChecksTo("System.ComponentModel.EventBasedAsync")]
[assembly: IgnoresAccessChecksTo("System.ComponentModel.Primitives")]
[assembly: IgnoresAccessChecksTo("System.ComponentModel.TypeConverter")]
[assembly: IgnoresAccessChecksTo("System.Console")]
[assembly: IgnoresAccessChecksTo("System.Core")]
[assembly: IgnoresAccessChecksTo("System.Data.Common")]
[assembly: IgnoresAccessChecksTo("System.Data")]
[assembly: IgnoresAccessChecksTo("System.Diagnostics.Contracts")]
[assembly: IgnoresAccessChecksTo("System.Diagnostics.Debug")]
[assembly: IgnoresAccessChecksTo("System.Diagnostics.FileVersionInfo")]
[assembly: IgnoresAccessChecksTo("System.Diagnostics.Process")]
[assembly: IgnoresAccessChecksTo("System.Diagnostics.StackTrace")]
[assembly: IgnoresAccessChecksTo("System.Diagnostics.TextWriterTraceListener")]
[assembly: IgnoresAccessChecksTo("System.Diagnostics.Tools")]
[assembly: IgnoresAccessChecksTo("System.Diagnostics.TraceSource")]
[assembly: IgnoresAccessChecksTo("System.Diagnostics.Tracing")]
[assembly: IgnoresAccessChecksTo("System")]
[assembly: IgnoresAccessChecksTo("System.Drawing")]
[assembly: IgnoresAccessChecksTo("System.Drawing.Primitives")]
[assembly: IgnoresAccessChecksTo("System.Dynamic.Runtime")]
[assembly: IgnoresAccessChecksTo("System.Globalization.Calendars")]
[assembly: IgnoresAccessChecksTo("System.Globalization")]
[assembly: IgnoresAccessChecksTo("System.Globalization.Extensions")]
[assembly: IgnoresAccessChecksTo("System.IO.Compression")]
[assembly: IgnoresAccessChecksTo("System.IO.Compression.FileSystem")]
[assembly: IgnoresAccessChecksTo("System.IO.Compression.ZipFile")]
[assembly: IgnoresAccessChecksTo("System.IO")]
[assembly: IgnoresAccessChecksTo("System.IO.FileSystem")]
[assembly: IgnoresAccessChecksTo("System.IO.FileSystem.DriveInfo")]
[assembly: IgnoresAccessChecksTo("System.IO.FileSystem.Primitives")]
[assembly: IgnoresAccessChecksTo("System.IO.FileSystem.Watcher")]
[assembly: IgnoresAccessChecksTo("System.IO.IsolatedStorage")]
[assembly: IgnoresAccessChecksTo("System.IO.MemoryMappedFiles")]
[assembly: IgnoresAccessChecksTo("System.IO.Pipes")]
[assembly: IgnoresAccessChecksTo("System.IO.UnmanagedMemoryStream")]
[assembly: IgnoresAccessChecksTo("System.Linq")]
[assembly: IgnoresAccessChecksTo("System.Linq.Expressions")]
[assembly: IgnoresAccessChecksTo("System.Linq.Parallel")]
[assembly: IgnoresAccessChecksTo("System.Linq.Queryable")]
[assembly: IgnoresAccessChecksTo("System.Memory")]
[assembly: IgnoresAccessChecksTo("System.Net")]
[assembly: IgnoresAccessChecksTo("System.Net.Http")]
[assembly: IgnoresAccessChecksTo("System.Net.NameResolution")]
[assembly: IgnoresAccessChecksTo("System.Net.NetworkInformation")]
[assembly: IgnoresAccessChecksTo("System.Net.Ping")]
[assembly: IgnoresAccessChecksTo("System.Net.Primitives")]
[assembly: IgnoresAccessChecksTo("System.Net.Requests")]
[assembly: IgnoresAccessChecksTo("System.Net.Security")]
[assembly: IgnoresAccessChecksTo("System.Net.Sockets")]
[assembly: IgnoresAccessChecksTo("System.Net.WebHeaderCollection")]
[assembly: IgnoresAccessChecksTo("System.Net.WebSockets.Client")]
[assembly: IgnoresAccessChecksTo("System.Net.WebSockets")]
[assembly: IgnoresAccessChecksTo("System.Numerics")]
[assembly: IgnoresAccessChecksTo("System.Numerics.Vectors")]
[assembly: IgnoresAccessChecksTo("System.ObjectModel")]
[assembly: IgnoresAccessChecksTo("System.Reflection.DispatchProxy")]
[assembly: IgnoresAccessChecksTo("System.Reflection")]
[assembly: IgnoresAccessChecksTo("System.Reflection.Emit")]
[assembly: IgnoresAccessChecksTo("System.Reflection.Emit.ILGeneration")]
[assembly: IgnoresAccessChecksTo("System.Reflection.Emit.Lightweight")]
[assembly: IgnoresAccessChecksTo("System.Reflection.Extensions")]
[assembly: IgnoresAccessChecksTo("System.Reflection.Primitives")]
[assembly: IgnoresAccessChecksTo("System.Reflection.TypeExtensions")]
[assembly: IgnoresAccessChecksTo("System.Resources.Reader")]
[assembly: IgnoresAccessChecksTo("System.Resources.ResourceManager")]
[assembly: IgnoresAccessChecksTo("System.Resources.Writer")]
[assembly: IgnoresAccessChecksTo("System.Runtime.CompilerServices.VisualC")]
[assembly: IgnoresAccessChecksTo("System.Runtime")]
[assembly: IgnoresAccessChecksTo("System.Runtime.Extensions")]
[assembly: IgnoresAccessChecksTo("System.Runtime.Handles")]
[assembly: IgnoresAccessChecksTo("System.Runtime.InteropServices")]
[assembly: IgnoresAccessChecksTo("System.Runtime.InteropServices.RuntimeInformation")]
[assembly: IgnoresAccessChecksTo("System.Runtime.Numerics")]
[assembly: IgnoresAccessChecksTo("System.Runtime.Serialization")]
[assembly: IgnoresAccessChecksTo("System.Runtime.Serialization.Formatters")]
[assembly: IgnoresAccessChecksTo("System.Runtime.Serialization.Json")]
[assembly: IgnoresAccessChecksTo("System.Runtime.Serialization.Primitives")]
[assembly: IgnoresAccessChecksTo("System.Runtime.Serialization.Xml")]
[assembly: IgnoresAccessChecksTo("System.Security.Claims")]
[assembly: IgnoresAccessChecksTo("System.Security.Cryptography.Algorithms")]
[assembly: IgnoresAccessChecksTo("System.Security.Cryptography.Csp")]
[assembly: IgnoresAccessChecksTo("System.Security.Cryptography.Encoding")]
[assembly: IgnoresAccessChecksTo("System.Security.Cryptography.Primitives")]
[assembly: IgnoresAccessChecksTo("System.Security.Cryptography.X509Certificates")]
[assembly: IgnoresAccessChecksTo("System.Security.Principal")]
[assembly: IgnoresAccessChecksTo("System.Security.SecureString")]
[assembly: IgnoresAccessChecksTo("System.ServiceModel.Web")]
[assembly: IgnoresAccessChecksTo("System.Text.Encoding")]
[assembly: IgnoresAccessChecksTo("System.Text.Encoding.Extensions")]
[assembly: IgnoresAccessChecksTo("System.Text.RegularExpressions")]
[assembly: IgnoresAccessChecksTo("System.Threading")]
[assembly: IgnoresAccessChecksTo("System.Threading.Overlapped")]
[assembly: IgnoresAccessChecksTo("System.Threading.Tasks")]
[assembly: IgnoresAccessChecksTo("System.Threading.Tasks.Extensions")]
[assembly: IgnoresAccessChecksTo("System.Threading.Tasks.Parallel")]
[assembly: IgnoresAccessChecksTo("System.Threading.Thread")]
[assembly: IgnoresAccessChecksTo("System.Threading.ThreadPool")]
[assembly: IgnoresAccessChecksTo("System.Threading.Timer")]
[assembly: IgnoresAccessChecksTo("System.Transactions")]
[assembly: IgnoresAccessChecksTo("System.ValueTuple")]
[assembly: IgnoresAccessChecksTo("System.Web")]
[assembly: IgnoresAccessChecksTo("System.Windows")]
[assembly: IgnoresAccessChecksTo("System.Xml")]
[assembly: IgnoresAccessChecksTo("System.Xml.Linq")]
[assembly: IgnoresAccessChecksTo("System.Xml.ReaderWriter")]
[assembly: IgnoresAccessChecksTo("System.Xml.Serialization")]
[assembly: IgnoresAccessChecksTo("System.Xml.XDocument")]
[assembly: IgnoresAccessChecksTo("System.Xml.XmlDocument")]
[assembly: IgnoresAccessChecksTo("System.Xml.XmlSerializer")]
[assembly: IgnoresAccessChecksTo("System.Xml.XPath")]
[assembly: IgnoresAccessChecksTo("System.Xml.XPath.XDocument")]
[assembly: IgnoresAccessChecksTo("TrueDarknessClient")]
[assembly: IgnoresAccessChecksTo("Unity.AI.Navigation")]
[assembly: IgnoresAccessChecksTo("Unity.Animation.Rigging")]
[assembly: IgnoresAccessChecksTo("Unity.Animation.Rigging.DocCodeExamples")]
[assembly: IgnoresAccessChecksTo("Unity.Burst")]
[assembly: IgnoresAccessChecksTo("Unity.Burst.Unsafe")]
[assembly: IgnoresAccessChecksTo("Unity.Collections")]
[assembly: IgnoresAccessChecksTo("Unity.Collections.LowLevel.ILSupport")]
[assembly: IgnoresAccessChecksTo("Unity.InputSystem")]
[assembly: IgnoresAccessChecksTo("Unity.InputSystem.ForUI")]
[assembly: IgnoresAccessChecksTo("Unity.Jobs")]
[assembly: IgnoresAccessChecksTo("Unity.Mathematics")]
[assembly: IgnoresAccessChecksTo("Unity.Multiplayer.Tools.Common")]
[assembly: IgnoresAccessChecksTo("Unity.Multiplayer.Tools.MetricTypes")]
[assembly: IgnoresAccessChecksTo("Unity.Multiplayer.Tools.NetStats")]
[assembly: IgnoresAccessChecksTo("Unity.Multiplayer.Tools.NetStatsMonitor.Component")]
[assembly: IgnoresAccessChecksTo("Unity.Multiplayer.Tools.NetStatsMonitor.Configuration")]
[assembly: IgnoresAccessChecksTo("Unity.Multiplayer.Tools.NetStatsMonitor.Implementation")]
[assembly: IgnoresAccessChecksTo("Unity.Multiplayer.Tools.NetStatsReporting")]
[assembly: IgnoresAccessChecksTo("Unity.Multiplayer.Tools.NetworkProfiler.Runtime")]
[assembly: IgnoresAccessChecksTo("Unity.Multiplayer.Tools.NetworkSolutionInterface")]
[assembly: IgnoresAccessChecksTo("Unity.Netcode.Components")]
[assembly: IgnoresAccessChecksTo("Unity.Netcode.Runtime")]
[assembly: IgnoresAccessChecksTo("Unity.Networking.Transport")]
[assembly: IgnoresAccessChecksTo("Unity.ProBuilder.Csg")]
[assembly: IgnoresAccessChecksTo("Unity.ProBuilder")]
[assembly: IgnoresAccessChecksTo("Unity.ProBuilder.KdTree")]
[assembly: IgnoresAccessChecksTo("Unity.ProBuilder.Poly2Tri")]
[assembly: IgnoresAccessChecksTo("Unity.ProBuilder.Stl")]
[assembly: IgnoresAccessChecksTo("Unity.Profiling.Core")]
[assembly: IgnoresAccessChecksTo("Unity.RenderPipelines.Core.Runtime")]
[assembly: IgnoresAccessChecksTo("Unity.RenderPipelines.Core.ShaderLibrary")]
[assembly: IgnoresAccessChecksTo("Unity.RenderPipelines.HighDefinition.Config.Runtime")]
[assembly: IgnoresAccessChecksTo("Unity.RenderPipelines.HighDefinition.Runtime")]
[assembly: IgnoresAccessChecksTo("Unity.RenderPipelines.ShaderGraph.ShaderGraphLibrary")]
[assembly: IgnoresAccessChecksTo("Unity.Services.Authentication")]
[assembly: IgnoresAccessChecksTo("Unity.Services.Core.Analytics")]
[assembly: IgnoresAccessChecksTo("Unity.Services.Core.Configuration")]
[assembly: IgnoresAccessChecksTo("Unity.Services.Core.Device")]
[assembly: IgnoresAccessChecksTo("Unity.Services.Core")]
[assembly: IgnoresAccessChecksTo("Unity.Services.Core.Environments")]
[assembly: IgnoresAccessChecksTo("Unity.Services.Core.Environments.Internal")]
[assembly: IgnoresAccessChecksTo("Unity.Services.Core.Internal")]
[assembly: IgnoresAccessChecksTo("Unity.Services.Core.Networking")]
[assembly: IgnoresAccessChecksTo("Unity.Services.Core.Registration")]
[assembly: IgnoresAccessChecksTo("Unity.Services.Core.Scheduler")]
[assembly: IgnoresAccessChecksTo("Unity.Services.Core.Telemetry")]
[assembly: IgnoresAccessChecksTo("Unity.Services.Core.Threading")]
[assembly: IgnoresAccessChecksTo("Unity.Services.QoS")]
[assembly: IgnoresAccessChecksTo("Unity.Services.Relay")]
[assembly: IgnoresAccessChecksTo("Unity.TextMeshPro")]
[assembly: IgnoresAccessChecksTo("Unity.Timeline")]
[assembly: IgnoresAccessChecksTo("Unity.VisualEffectGraph.Runtime")]
[assembly: IgnoresAccessChecksTo("UnityEngine.AccessibilityModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.AIModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.AndroidJNIModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.AnimationModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.ARModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.AssetBundleModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.AudioModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.ClothModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.ClusterInputModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.ClusterRendererModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.ContentLoadModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.CoreModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.CrashReportingModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.DirectorModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine")]
[assembly: IgnoresAccessChecksTo("UnityEngine.DSPGraphModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.GameCenterModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.GIModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.GridModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.HotReloadModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.ImageConversionModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.IMGUIModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.InputLegacyModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.InputModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.JSONSerializeModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.LocalizationModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.NVIDIAModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.ParticleSystemModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.PerformanceReportingModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.Physics2DModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.PhysicsModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.ProfilerModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.PropertiesModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.RuntimeInitializeOnLoadManagerInitializerModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.ScreenCaptureModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.SharedInternalsModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.SpriteMaskModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.SpriteShapeModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.StreamingModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.SubstanceModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.SubsystemsModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.TerrainModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.TerrainPhysicsModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.TextCoreFontEngineModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.TextCoreTextEngineModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.TextRenderingModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.TilemapModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.TLSModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.UI")]
[assembly: IgnoresAccessChecksTo("UnityEngine.UIElementsModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.UIModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.UmbraModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.UnityAnalyticsCommonModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.UnityAnalyticsModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.UnityConnectModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.UnityCurlModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.UnityTestProtocolModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.UnityWebRequestAssetBundleModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.UnityWebRequestAudioModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.UnityWebRequestModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.UnityWebRequestTextureModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.UnityWebRequestWWWModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.VehiclesModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.VFXModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.VideoModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.VirtualTexturingModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.VRModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.WindModule")]
[assembly: IgnoresAccessChecksTo("UnityEngine.XRModule")]
[assembly: AssemblyCompany("TrueDarkness")]
[assembly: AssemblyConfiguration("Debug")]
[assembly: AssemblyFileVersion("1.0.3.0")]
[assembly: AssemblyInformationalVersion("1.0.3-alpha.0.2+8b2da66df728d4504593eb40d1802a75a0321995")]
[assembly: AssemblyProduct("TrueDarkness")]
[assembly: AssemblyTitle("TrueDarkness")]
[assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)]
[assembly: AssemblyVersion("1.0.0.0")]
[module: UnverifiableCode]
[module: RefSafetyRules(11)]
namespace Microsoft.CodeAnalysis
{
	[CompilerGenerated]
	[Microsoft.CodeAnalysis.Embedded]
	internal sealed class EmbeddedAttribute : Attribute
	{
	}
}
namespace System.Runtime.CompilerServices
{
	[CompilerGenerated]
	[Microsoft.CodeAnalysis.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 YourThunderstoreTeam
{
	public static class PluginInfo
	{
		public const string PLUGIN_GUID = "TrueDarkness";

		public const string PLUGIN_NAME = "TrueDarkness";

		public const string PLUGIN_VERSION = "1.0.0";
	}
}
namespace Friskzips
{
	public class LateGameUpgradesCompatibility
	{
		internal static bool LguNightVision;

		private static bool? _enabled;

		public static bool enabled
		{
			get
			{
				if (!_enabled.HasValue)
				{
					_enabled = Chainloader.PluginInfos.ContainsKey("com.malco.lethalcompany.moreshipupgrades");
				}
				return _enabled.Value;
			}
		}

		[HarmonyPatch(typeof(NightVision))]
		[HarmonyPatch("TurnOn")]
		[HarmonyPostfix]
		internal static void NightVisionOn()
		{
			Plugin.Log.LogDebug((object)"NightVision on");
			LguNightVision = true;
		}

		[HarmonyPatch(typeof(NightVision))]
		[HarmonyPatch("TurnOff")]
		[HarmonyPostfix]
		internal static void NightVisionOff()
		{
			Plugin.Log.LogDebug((object)"NightVision off");
			LguNightVision = false;
		}
	}
	public class LethalConfigCompatibility
	{
		private static bool? _enabled;

		public static bool enabled
		{
			get
			{
				if (!_enabled.HasValue)
				{
					_enabled = Chainloader.PluginInfos.ContainsKey("ainavt.lc.lethalconfig");
				}
				return _enabled.Value;
			}
		}

		internal static void initLethalConfig()
		{
			//IL_0010: Unknown result type (might be due to invalid IL or missing references)
			//IL_0015: Unknown result type (might be due to invalid IL or missing references)
			//IL_001d: Unknown result type (might be due to invalid IL or missing references)
			//IL_0028: Expected O, but got Unknown
			//IL_0029: Unknown result type (might be due to invalid IL or missing references)
			//IL_0034: Expected O, but got Unknown
			//IL_003a: Expected O, but got Unknown
			//IL_0035: Unknown result type (might be due to invalid IL or missing references)
			//IL_003b: Expected O, but got Unknown
			ConfigEntry<float> entry = Plugin.Config.Intensity.Entry;
			FloatSliderOptions val = new FloatSliderOptions
			{
				RequiresRestart = false
			};
			((BaseRangeOptions<float>)val).Min = 0f;
			((BaseRangeOptions<float>)val).Max = 1000f;
			FloatSliderConfigItem val2 = new FloatSliderConfigItem(entry, val);
			LethalConfigManager.AddConfigItem((BaseConfigItem)(object)val2);
			LethalConfigManager.SetModDescription("Do you want to be on the dark but diversity is too much for your modpack? then this is for you!");
		}
	}
	public class TrueDarknessClientCompatibility
	{
		private static bool? _enabled;

		public static bool enabled
		{
			get
			{
				if (!_enabled.HasValue)
				{
					_enabled = Chainloader.PluginInfos.ContainsKey("Friskzips.TrueDarknessClient");
				}
				return _enabled.Value;
			}
		}

		[HarmonyPatch(typeof(NightVisionOverrideClient))]
		[HarmonyPatch("OnNightVisionEnabled")]
		[HarmonyPrefix]
		public static bool DisableTheMod()
		{
			return false;
		}
	}
}
namespace Friskzips.service
{
	public class FriskzipsService
	{
		public bool ReturnTrue()
		{
			return true;
		}

		public bool ReturnFalse()
		{
			return false;
		}
	}
}
namespace Friskzips.TrueDarkness
{
	public class LC_OfficeCompatibility
	{
		private static bool? _enabled;

		public static bool enabled
		{
			get
			{
				if (!_enabled.HasValue)
				{
					_enabled = Chainloader.PluginInfos.ContainsKey("Piggy.LCOffice");
				}
				return _enabled.Value;
			}
		}

		[HarmonyPatch(typeof(HaltRoom))]
		[HarmonyPatch("Update")]
		[HarmonyPostfix]
		public static void DisableMyStuff(ref HaltRoom __instance)
		{
			if (HaltRoom.isInHaltSequance)
			{
				Plugin.nightVision = false;
				Plugin.Log.LogInfo((object)"Halt sequence detected disabling my night vision");
			}
			else
			{
				Plugin.nightVision = true;
				Plugin.Log.LogInfo((object)"Halt sequence ended enabling my night vision");
			}
		}
	}
	[BepInDependency("com.sigurd.csync", "5.0.1")]
	[BepInDependency(/*Could not decode attribute arguments.*/)]
	[BepInDependency(/*Could not decode attribute arguments.*/)]
	[BepInDependency(/*Could not decode attribute arguments.*/)]
	[BepInPlugin("Friskzips.TrueDarkness", "TrueDarkness", "1.3.0")]
	[BepInDependency(/*Could not decode attribute arguments.*/)]
	[LobbyCompatibility(/*Could not decode attribute arguments.*/)]
	public class Plugin : BaseUnityPlugin
	{
		internal static bool nightVision = true;

		private readonly Harmony _harmony = new Harmony("Friskzips.TrueDarkness");

		internal static Config Config;

		public static Plugin Instance { get; set; }

		public static ManualLogSource Log => ((BaseUnityPlugin)Instance).Logger;

		public Plugin()
		{
			//IL_0006: Unknown result type (might be due to invalid IL or missing references)
			//IL_0010: Expected O, but got Unknown
			Instance = this;
		}

		private void Awake()
		{
			Config = new Config(((BaseUnityPlugin)this).Config);
			Log.LogInfo((object)"Applying patches...");
			ApplyPluginPatch();
			Log.LogInfo((object)"Patches applied");
		}

		private void ApplyPluginPatch()
		{
			_harmony.PatchAll(typeof(NightVisionOverride));
			_harmony.PatchAll(typeof(MainMenu));
			if (TrueDarknessClientCompatibility.enabled)
			{
				Log.LogWarning((object)"Mod conflict with TrueDarknessClient!");
				Log.LogWarning((object)"I am just gonna disable the other one.");
				_harmony.PatchAll(typeof(TrueDarknessClientCompatibility));
			}
			if (LethalConfigCompatibility.enabled)
			{
				Log.LogInfo((object)"LethalConfig found!");
				LethalConfigCompatibility.initLethalConfig();
			}
			if (LateGameUpgradesCompatibility.enabled)
			{
				Log.LogInfo((object)"LateGameUpgrades found!");
				_harmony.PatchAll(typeof(LateGameUpgradesCompatibility));
			}
		}
	}
	public static class PluginInfo
	{
		public const string PLUGIN_GUID = "Friskzips.TrueDarkness";

		public const string PLUGIN_NAME = "TrueDarkness";

		public const string PLUGIN_VERSION = "1.3.0";
	}
}
namespace Friskzips.TrueDarkness.patch
{
	[HarmonyPatch(typeof(MenuManager))]
	internal class MainMenu
	{
		[HarmonyPatch("OnEnable")]
		[HarmonyPostfix]
		private static void ResetStuff()
		{
			Plugin.Log.LogDebug((object)"Reset stuff");
			LateGameUpgradesCompatibility.LguNightVision = false;
		}
	}
	[HarmonyPatch(typeof(PlayerControllerB))]
	public class NightVisionOverride
	{
		[HarmonyPatch("SetNightVisionEnabled")]
		[HarmonyPostfix]
		private static void OnNightVisionEnabled(ref PlayerControllerB __instance)
		{
			if (((Behaviour)__instance.nightVision).enabled && Plugin.nightVision && ((NetworkBehaviour)__instance).IsOwner && __instance.nightVision.intensity != Plugin.Config.Intensity.Value && !LateGameUpgradesCompatibility.LguNightVision)
			{
				if (Plugin.Config.Intensity.Value < 0f)
				{
					Plugin.Log.LogError((object)"I don't think that this value would work so im setting it to 0\n");
					Plugin.Config.Intensity.LocalValue = 0f;
				}
				__instance.nightVision.intensity = Plugin.Config.Intensity.Value;
				Plugin.Log.LogDebug((object)("NightVision enabled intensity: " + __instance.nightVision.intensity));
			}
			if (!((NetworkBehaviour)__instance).IsOwner)
			{
				__instance.nightVision.intensity = 366.9317f;
			}
			if (!((Behaviour)__instance.nightVision).enabled && !Plugin.nightVision)
			{
				Plugin.nightVision = true;
			}
		}
	}
}
namespace Friskzips.TrueDarkness.configStuff
{
	public class Config : SyncedConfig2<Config>
	{
		[field: SyncedEntryField]
		public SyncedEntry<float> Intensity { get; private set; }

		public Config(ConfigFile cfg)
			: base("Friskzips.TrueDarkness")
		{
			//IL_0019: Unknown result type (might be due to invalid IL or missing references)
			//IL_002e: Unknown result type (might be due to invalid IL or missing references)
			//IL_0038: Expected O, but got Unknown
			//IL_0038: Expected O, but got Unknown
			Intensity = SyncedBindingExtensions.BindSyncedEntry<float>(cfg, new ConfigDefinition("Night vision", "Intensity"), 0f, new ConfigDescription("The lower the less you see, the higher the more you see.\n Vanilla value: 366,9317", (AcceptableValueBase)null, Array.Empty<object>()));
			ConfigManager.Register<Config>((SyncedConfig2<Config>)this);
		}
	}
}
namespace System.Runtime.CompilerServices
{
	[AttributeUsage(AttributeTargets.Assembly, AllowMultiple = true)]
	internal sealed class IgnoresAccessChecksToAttribute : Attribute
	{
		internal IgnoresAccessChecksToAttribute(string assemblyName)
		{
		}
	}
}