Decompiled source of decloak v1.1.4

decloak.dll

Decompiled a week ago
using System;
using System.Collections;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Reflection;
using System.Reflection.Emit;
using System.Runtime.CompilerServices;
using System.Runtime.Versioning;
using System.Security;
using System.Security.Permissions;
using BepInEx;
using BepInEx.Configuration;
using BepInEx.Logging;
using FishNet;
using FishNet.Connection;
using FishNet.Managing.Logging;
using FishNet.Managing.Server;
using FishNet.Object;
using FishNet.Serializing;
using HarmonyLib;
using Microsoft.CodeAnalysis;
using Steamworks;
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: AssemblyCompany("murderminemurder, murderminer")]
[assembly: AssemblyConfiguration("Debug")]
[assembly: AssemblyDescription("meatgrind the retarded")]
[assembly: AssemblyFileVersion("1.1.4.0")]
[assembly: AssemblyInformationalVersion("1.1.4")]
[assembly: AssemblyProduct("meatgrind the retarded")]
[assembly: AssemblyTitle("retard crusher")]
[assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)]
[assembly: AssemblyVersion("1.1.4.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 retardcrusher
{
	[BepInPlugin("murderminemurderer.decloak", "decloak", "1.1.4")]
	[BepInProcess("MageArena.exe")]
	public class euthanizetheretarded : BaseUnityPlugin
	{
		public static ManualLogSource Logger;

		public static bool debug = false;

		public const string guid = "murderminemurderer.decloak";

		public static string modsync = "host";

		internal void Awake()
		{
			//IL_002d: Unknown result type (might be due to invalid IL or missing references)
			Logger = ((BaseUnityPlugin)this).Logger;
			Logger.LogInfo((object)"decloak loaded");
			configman.dotheconfig(((BaseUnityPlugin)this).Config);
			new Harmony("murderminemurderer.decloak").PatchAll();
			gurglingnoise.StartCoroutine = ((MonoBehaviour)this).StartCoroutine;
		}
	}
	public static class configman
	{
		public static ConfigEntry<string> banlist;

		public static ConfigEntry<bool> poorlymadeservercooldowns;

		public static ConfigEntry<bool> debugmode;

		public static void dotheconfig(ConfigFile config)
		{
			string text = "decloak";
			banlist = config.Bind<string>(text, "retards", "", "steamids of retards to impale vlad the impaler style separated by space");
			poorlymadeservercooldowns = config.Bind<bool>(text, "poorlymadeservercooldowns", true, "enable poorly made server cooldown autokicking (might kick w/ lots of crystal soup)");
			debugmode = config.Bind<bool>(text, "debug", true, "more logs");
		}
	}
	[HarmonyPatch(typeof(BootstrapNetworkManager))]
	public class bootman
	{
		[HarmonyPatch("RpcLogic___ServerJoinHatsCall_852232071")]
		[HarmonyPrefix]
		public static bool singularityworshippinggroup(ref BootstrapNetworkManager __instance, string PlayerName, string steamid)
		{
			//IL_004b: Unknown result type (might be due to invalid IL or missing references)
			if (mormoncrusher.sidtoconnection.ContainsKey(steamid) && !mormoncrusher.hasauthed.ContainsKey(steamid))
			{
				mormoncrusher.hasauthed.Add(steamid, value: true);
			}
			if (mormoncrusher.sidtocsid.ContainsKey(steamid) && !PlayerName.ToLower().Contains(SteamFriends.GetFriendPersonaName(mormoncrusher.sidtocsid[steamid]).ToLower()))
			{
				try
				{
					rapeyou.crusher(steamid);
				}
				catch (Exception)
				{
				}
				return false;
			}
			return true;
		}
	}
	[HarmonyPatch(typeof(MainMenuManager))]
	public class gurglingnoise
	{
		[CompilerGenerated]
		private sealed class <myispisthrottlingme>d__4 : IEnumerator<object>, IEnumerator, IDisposable
		{
			private int <>1__state;

			private object <>2__current;

			public string steamid;

			private Exception <a>5__1;

			object IEnumerator<object>.Current
			{
				[DebuggerHidden]
				get
				{
					return <>2__current;
				}
			}

			object IEnumerator.Current
			{
				[DebuggerHidden]
				get
				{
					return <>2__current;
				}
			}

			[DebuggerHidden]
			public <myispisthrottlingme>d__4(int <>1__state)
			{
				this.<>1__state = <>1__state;
			}

			[DebuggerHidden]
			void IDisposable.Dispose()
			{
				<a>5__1 = null;
				<>1__state = -2;
			}

			private bool MoveNext()
			{
				switch (<>1__state)
				{
				default:
					return false;
				case 0:
					<>1__state = -1;
					<>2__current = waitperiod;
					<>1__state = 1;
					return true;
				case 1:
					<>1__state = -1;
					if (!mormoncrusher.hasauthed.ContainsKey(steamid) && mormoncrusher.sidtoconnection.ContainsKey(steamid))
					{
						try
						{
							rapeyou.crusher(steamid);
							mormoncrusher.sidtoconnection.Remove(steamid);
						}
						catch (Exception ex)
						{
							<a>5__1 = ex;
							euthanizetheretarded.Logger.LogInfo((object)("fuck " + <a>5__1));
						}
						return false;
					}
					return false;
				}
			}

			bool IEnumerator.MoveNext()
			{
				//ILSpy generated this explicit interface implementation from .override directive in MoveNext
				return this.MoveNext();
			}

			[DebuggerHidden]
			void IEnumerator.Reset()
			{
				throw new NotSupportedException();
			}
		}

		public static FieldInfo themethod = typeof(MainMenuManager).GetField("kickplayershold", BindingFlags.Instance | BindingFlags.Public);

		public static MainMenuManager theinstance;

		private static WaitForSecondsRealtime waitperiod = new WaitForSecondsRealtime(2.5f);

		public static Func<IEnumerator, Coroutine> StartCoroutine;

		[IteratorStateMachine(typeof(<myispisthrottlingme>d__4))]
		public static IEnumerator myispisthrottlingme(string steamid)
		{
			//yield-return decompiler failed: Unexpected instruction in Iterator.Dispose()
			return new <myispisthrottlingme>d__4(0)
			{
				steamid = steamid
			};
		}

		[HarmonyPatch("KickPlayer")]
		[HarmonyPostfix]
		public static void girlpuncher2006(ref string steamid)
		{
			if (mormoncrusher.sidtoconnection.ContainsKey(steamid))
			{
				InstanceFinder.ServerManager.Kick(mormoncrusher.sidtoconnection[steamid], (KickReason)1, (LoggingType)2, "(kick menu) retard crushed: " + mormoncrusher.sidtoconnection[steamid].ClientId + " steamid: " + steamid);
			}
		}

		[HarmonyPatch("SyncHats")]
		[HarmonyPrefix]
		public static void niggasonthemoon(ref MainMenuManager __instance)
		{
			theinstance = __instance;
		}

		[HarmonyTranspiler]
		[HarmonyPatch("SyncHats")]
		public static IEnumerable<CodeInstruction> samsaramurdercult(IEnumerable<CodeInstruction> instructions)
		{
			List<CodeInstruction> list = new List<CodeInstruction>(instructions);
			for (int i = 0; i <= 4; i++)
			{
				euthanizetheretarded.Logger.LogInfo((object)(i + " op: " + list[i].opcode.Name + ": " + list[i].operand));
				list[i].opcode = OpCodes.Nop;
			}
			return list.AsEnumerable();
		}
	}
	[HarmonyPatch(typeof(ChestNetController))]
	public class thewailingoftheforest
	{
		[HarmonyPatch(typeof(NetInteractionManager), "RpcReader___Server_SpawnBoulderServer_208080042")]
		[HarmonyPatch(typeof(DungeonGenerator), "RpcReader___Server_ServerPlaceHex_1692629761")]
		[HarmonyPatch(typeof(BootstrapNetworkManager), "RpcReader___Server_kickPlayerServer_3615296227")]
		[HarmonyPrefix]
		public static bool wahwahwah(PooledReader PooledReader0, NetworkConnection conn, MethodBase __originalMethod)
		{
			if (mormoncrusher.sidtoconnection.ContainsValue(conn))
			{
				rapeyou.humancentipede(conn, "retard attempted to call " + __originalMethod.Name + ":");
				feelingwrong.readfrompooled(PooledReader0, __originalMethod);
				return false;
			}
			return true;
		}

		[HarmonyPatch("RpcReader___Server_ServerSpawnLacky_215135683")]
		[HarmonyPrefix]
		public static bool ionlyplantostealwhateveriwant(PooledReader PooledReader0, NetworkConnection conn, MethodBase __originalMethod, ChestNetController __instance)
		{
			if (mormoncrusher.sidtoconnection.ContainsValue(conn))
			{
				rapeyou.humancentipede(conn, "retard attempted to ServerSpawnLacky: ");
				feelingwrong.readfrompooled(PooledReader0, __originalMethod);
				return false;
			}
			if (!feelingwrong.negativexp.ContainsKey(__instance.TeamNum))
			{
				feelingwrong.negativexp[__instance.TeamNum] = 0.001f;
				feelingwrong.tlvl[__instance.TeamNum] = 1;
			}
			feelingwrong.negativexp[__instance.TeamNum] += 1f;
			if (feelingwrong.negativexp[__instance.TeamNum] > (float)(3 * Mathf.Clamp(feelingwrong.tlvl[__instance.TeamNum], 0, 2)))
			{
				feelingwrong.tlvl[__instance.TeamNum]++;
			}
			return true;
		}
	}
	[HarmonyPatch(typeof(MageBookController))]
	public class feelingwrong
	{
		public static Dictionary<int, float> negativexp = new Dictionary<int, float>();

		public static Dictionary<int, int> tlvl = new Dictionary<int, int>();

		public static List<object> readfrompooled(PooledReader PooledReader0, MethodBase __originalMethod)
		{
			//IL_0126: Unknown result type (might be due to invalid IL or missing references)
			//IL_012b: Unknown result type (might be due to invalid IL or missing references)
			//IL_0134: Unknown result type (might be due to invalid IL or missing references)
			//IL_0139: Unknown result type (might be due to invalid IL or missing references)
			//IL_0150: Unknown result type (might be due to invalid IL or missing references)
			//IL_0159: Unknown result type (might be due to invalid IL or missing references)
			//IL_0235: Unknown result type (might be due to invalid IL or missing references)
			//IL_01bc: Unknown result type (might be due to invalid IL or missing references)
			//IL_01c1: Unknown result type (might be due to invalid IL or missing references)
			//IL_01e5: Unknown result type (might be due to invalid IL or missing references)
			//IL_017a: Unknown result type (might be due to invalid IL or missing references)
			//IL_017f: Unknown result type (might be due to invalid IL or missing references)
			//IL_019c: Unknown result type (might be due to invalid IL or missing references)
			//IL_021d: Unknown result type (might be due to invalid IL or missing references)
			switch (__originalMethod.Name)
			{
			case "RpcReader___Server_ShootFireballServer_3976682022":
			case "RpcReader___Server_CastSpellServer_3976682022":
			{
				GameObject val = ((Reader)PooledReader0).ReadGameObject();
				Vector3 val2 = ((Reader)PooledReader0).ReadVector3();
				int num = ((Reader)PooledReader0).ReadInt32();
				Vector3 val4 = ((Reader)PooledReader0).ReadVector3();
				return new List<object>(new <>z__ReadOnlyArray<object>(new object[4] { num, val, val2, val4 }));
			}
			case "RpcReader___Server_ShootFrostboltServer_1366904011":
			{
				GameObject val = ((Reader)PooledReader0).ReadGameObject();
				Vector3 val2 = ((Reader)PooledReader0).ReadVector3();
				int num = ((Reader)PooledReader0).ReadInt32();
				return new List<object>(new <>z__ReadOnlyArray<object>(new object[3] { num, val, val2 }));
			}
			case "RpcReader___Server_ShootMagicMissleServer_2308368969":
			{
				GameObject val = ((Reader)PooledReader0).ReadGameObject();
				Vector3 val2 = ((Reader)PooledReader0).ReadVector3();
				GameObject val3 = ((Reader)PooledReader0).ReadGameObject();
				int num = ((Reader)PooledReader0).ReadInt32();
				return new List<object>(new <>z__ReadOnlyArray<object>(new object[4] { num, val, val2, val3 }));
			}
			case "RpcReader___Server_ServerPlaceHex_1692629761":
				((Reader)PooledReader0).ReadInt32();
				((Reader)PooledReader0).ReadInt32();
				return new List<object>();
			case "RpcReader___Server_ServerSpawnLacky_215135683":
				((Reader)PooledReader0).ReadInt32();
				((Reader)PooledReader0).ReadVector3();
				return new List<object>();
			case "RpcReader___Server_SpawnBoulderServer_208080042":
				return new List<object>(new <>z__ReadOnlyArray<object>(new object[2]
				{
					((Reader)PooledReader0).ReadVector3(),
					((Reader)PooledReader0).ReadGameObject()
				}));
			default:
				return new List<object>();
			}
		}

		[HarmonyPatch("RpcReader___Server_ShootFireballServer_3976682022")]
		[HarmonyPatch("RpcReader___Server_ShootMagicMissleServer_2308368969")]
		[HarmonyPatch("RpcReader___Server_ShootFrostboltServer_1366904011")]
		[HarmonyPatch(typeof(PageController), "RpcReader___Server_CastSpellServer_3976682022")]
		[HarmonyPrefix]
		public static bool spellserv(ref PooledReader PooledReader0, MethodBase __originalMethod, ref NetworkConnection conn)
		{
			//IL_007e: Unknown result type (might be due to invalid IL or missing references)
			//IL_0044: Unknown result type (might be due to invalid IL or missing references)
			//IL_0049: Unknown result type (might be due to invalid IL or missing references)
			//IL_018a: Unknown result type (might be due to invalid IL or missing references)
			//IL_0194: Unknown result type (might be due to invalid IL or missing references)
			//IL_01a0: Unknown result type (might be due to invalid IL or missing references)
			//IL_0265: Unknown result type (might be due to invalid IL or missing references)
			int position = ((Reader)PooledReader0).Position;
			List<object> list = readfrompooled(PooledReader0, __originalMethod);
			string text = rapeyou.sporeinfection(conn);
			if (text == "fuck")
			{
				if (!(InstanceFinder.ClientManager.Connection == conn))
				{
					return false;
				}
				CSteamID steamID = SteamUser.GetSteamID();
				text = ((object)(CSteamID)(ref steamID)).ToString();
			}
			bool flag = false;
			float time = Time.time;
			float num = -1000f;
			PlayerMovement val = default(PlayerMovement);
			((GameObject)list[1]).TryGetComponent<PlayerMovement>(ref val);
			if (!negativexp.ContainsKey(val.playerTeam))
			{
				negativexp[val.playerTeam] = 0.001f;
				tlvl[val.playerTeam] = 1;
			}
			if (configman.poorlymadeservercooldowns.Value)
			{
				if (mormoncrusher.spellspeed.ContainsKey(text))
				{
					if (!mormoncrusher.spellspeed[text].ContainsKey(__originalMethod.Name))
					{
						mormoncrusher.spellspeed[text].Add(__originalMethod.Name, Time.time);
					}
					else
					{
						num = mormoncrusher.spellspeed[text][__originalMethod.Name];
					}
					float num2 = time - num;
					string name = __originalMethod.Name;
					string text2 = name;
					if (text2 != null)
					{
						if (text2 == "RpcReader___Server_ShootFireballServer_3976682022" && (num2 < 2f || Vector3.Distance(((GameObject)list[1]).transform.position, (Vector3)list[3]) > 30f))
						{
							flag = true;
						}
						else
						{
							string text3 = text2;
							if (text3 == "RpcReader___Server_ShootMagicMissleServer_2308368969" && num2 < 1f)
							{
								flag = true;
							}
							else
							{
								string text4 = text2;
								if (text4 == "RpcReader___Server_CastSpellServer_3976682022" && num2 < 0.2f)
								{
									flag = true;
								}
								else
								{
									string text5 = text2;
									if (text5 == "RpcReader___Server_ShootFrostboltServer_1366904011" && num2 < 2f)
									{
										flag = true;
									}
								}
							}
						}
					}
					mormoncrusher.spellspeed[text][__originalMethod.Name] = time;
					if (configman.debugmode.Value)
					{
						string text6 = (mormoncrusher.sidtocsid.ContainsKey(text) ? SteamFriends.GetFriendPersonaName(mormoncrusher.sidtocsid[text]) : "host");
						euthanizetheretarded.Logger.LogInfo((object)("plrsid: " + text + " name: " + text6 + " spell_lvl: " + (int)list[0] + " cast time: " + num2));
					}
				}
				else
				{
					mormoncrusher.spellspeed.Add(text, new Dictionary<string, float>());
				}
			}
			if ((int)list[0] > tlvl[val.playerTeam] || mormoncrusher.previouslykicked.ContainsKey(text) || flag)
			{
				rapeyou.humancentipede(conn, "retard attempted/already tried to levelspoof/spellspam: spell_lvl: " + (int)list[0] + " stuff:");
				return false;
			}
			((Reader)PooledReader0).Position = position;
			return true;
		}
	}
	[HarmonyPatch(typeof(BootstrapManager))]
	public class mormoncrusher
	{
		public static NetworkConnection latestclient;

		public static bool kicknewest = false;

		public static bool islobbyowner = false;

		public static string latestsid;

		public static KickPlayersHolder kickplayersdict;

		public static Dictionary<string, NetworkConnection> sidtoconnection = new Dictionary<string, NetworkConnection>();

		public static Dictionary<string, CSteamID> sidtocsid = new Dictionary<string, CSteamID>();

		public static Dictionary<string, bool> hasauthed = new Dictionary<string, bool>();

		public static Dictionary<string, bool> previouslykicked = new Dictionary<string, bool>();

		public static Dictionary<string, Dictionary<string, float>> spellspeed = new Dictionary<string, Dictionary<string, float>>();

		public static MethodInfo setnmaes = typeof(KickPlayersHolder).GetMethod("SetNames", BindingFlags.Instance | BindingFlags.NonPublic);

		[HarmonyPatch("OnLobbyChatUpdate")]
		[HarmonyPostfix]
		public static void euthanization(ref LobbyChatUpdate_t callback)
		{
			//IL_0007: Unknown result type (might be due to invalid IL or missing references)
			//IL_0019: Unknown result type (might be due to invalid IL or missing references)
			//IL_001e: Unknown result type (might be due to invalid IL or missing references)
			//IL_0023: Unknown result type (might be due to invalid IL or missing references)
			//IL_003b: Unknown result type (might be due to invalid IL or missing references)
			//IL_003d: Invalid comparison between Unknown and I4
			//IL_0069: Unknown result type (might be due to invalid IL or missing references)
			//IL_006e: Unknown result type (might be due to invalid IL or missing references)
			//IL_0070: Unknown result type (might be due to invalid IL or missing references)
			//IL_0096: Unknown result type (might be due to invalid IL or missing references)
			//IL_0107: Unknown result type (might be due to invalid IL or missing references)
			//IL_0156: Unknown result type (might be due to invalid IL or missing references)
			//IL_0160: Expected O, but got Unknown
			EChatMemberStateChange val = (EChatMemberStateChange)callback.m_rgfChatMemberStateChange;
			string text = callback.m_ulSteamIDUserChanged.ToString();
			if (SteamMatchmaking.GetLobbyOwner(new CSteamID(BootstrapManager.CurrentLobbyID)) == SteamUser.GetSteamID())
			{
				islobbyowner = true;
				if ((int)val == 1)
				{
					string[] source = configman.banlist.Value.Split(new char[1] { ' ' });
					CSteamID val2 = (CSteamID)callback.m_ulSteamIDUserChanged;
					string friendPersonaName = SteamFriends.GetFriendPersonaName(val2);
					euthanizetheretarded.Logger.LogInfo((object)("joined: " + text + " name: " + friendPersonaName));
					SteamFriends.SetPlayedWith(val2);
					latestsid = text;
					if (sidtocsid.ContainsKey(text))
					{
						try
						{
							sidtocsid.Remove(text);
							kickplayersdict.nametosteamid.Remove(friendPersonaName);
							setnmaes.Invoke(kickplayersdict, Array.Empty<object>());
						}
						catch (Exception ex)
						{
							euthanizetheretarded.Logger.LogError((object)ex);
						}
					}
					sidtocsid.Add(text, val2);
					if (source.Contains(text))
					{
						kicknewest = true;
					}
					if (!(gurglingnoise.themethod != null) || !((Object)(object)gurglingnoise.theinstance != (Object)null))
					{
						return;
					}
					kickplayersdict = (KickPlayersHolder)gurglingnoise.themethod.GetValue(gurglingnoise.theinstance);
					if (Object.op_Implicit((Object)(object)kickplayersdict))
					{
						try
						{
							kickplayersdict.AddToDict(friendPersonaName, text);
						}
						catch (Exception ex2)
						{
							euthanizetheretarded.Logger.LogWarning((object)ex2);
						}
					}
					gurglingnoise.StartCoroutine(gurglingnoise.myispisthrottlingme(text));
				}
				else if (sidtoconnection.ContainsKey(text))
				{
					sidtoconnection.Remove(text);
				}
			}
			else
			{
				islobbyowner = false;
			}
		}
	}
	[HarmonyPatch(typeof(PlayerRespawnManager))]
	public class blood
	{
		[HarmonyPatch("EndGame")]
		[HarmonyPrefix]
		public static void endgame()
		{
			mormoncrusher.sidtoconnection.Clear();
			mormoncrusher.hasauthed.Clear();
			mormoncrusher.sidtocsid.Clear();
			mormoncrusher.latestclient = null;
			mormoncrusher.latestsid = null;
			mormoncrusher.kicknewest = false;
			feelingwrong.negativexp.Clear();
			feelingwrong.tlvl.Clear();
		}
	}
	[HarmonyPatch(typeof(NetworkBehaviour))]
	public class rapeyou
	{
		public static void crusher(string steamid, string msg = "(hat hiding) retard crushed: ")
		{
			if (mormoncrusher.sidtoconnection.ContainsKey(steamid) && !mormoncrusher.previouslykicked.ContainsKey(steamid))
			{
				mormoncrusher.previouslykicked.Add(steamid, value: true);
			}
			BootstrapNetworkManager.KickPlayer(steamid);
			InstanceFinder.ServerManager.Kick(mormoncrusher.sidtoconnection[steamid], (KickReason)1, (LoggingType)2, msg + mormoncrusher.sidtoconnection[steamid].ClientId + " steamid: " + steamid);
		}

		public static string sporeinfection(NetworkConnection conn)
		{
			if (mormoncrusher.sidtoconnection.ContainsValue(conn))
			{
				return mormoncrusher.sidtoconnection.FirstOrDefault((KeyValuePair<string, NetworkConnection> albertfish) => albertfish.Value == conn).Key;
			}
			return "fuck";
		}

		public static void humancentipede(NetworkConnection conn, string msg = "")
		{
			if (mormoncrusher.sidtoconnection.ContainsValue(conn))
			{
				string text = sporeinfection(conn);
				if (text != null)
				{
					crusher(text, (msg != "") ? msg : "autokicked-retard: ");
				}
			}
		}

		[HarmonyPatch("OnSpawnServer")]
		[HarmonyPostfix]
		public static void spwn(ref NetworkConnection connection)
		{
			euthanizetheretarded.Logger.LogInfo((object)("spawned: " + connection.ClientId));
			mormoncrusher.latestclient = connection;
			if (!mormoncrusher.islobbyowner)
			{
				return;
			}
			if (mormoncrusher.kicknewest || (mormoncrusher.latestsid != null && mormoncrusher.previouslykicked.ContainsKey(mormoncrusher.latestsid)))
			{
				try
				{
					BootstrapNetworkManager.KickPlayer(mormoncrusher.latestsid);
				}
				catch (Exception)
				{
				}
				mormoncrusher.kicknewest = false;
				InstanceFinder.ServerManager.Kick(connection, (KickReason)1, (LoggingType)2, "retard crushed: " + mormoncrusher.latestclient.ClientId + " steamid: " + mormoncrusher.latestsid);
				mormoncrusher.latestsid = null;
			}
			else if (mormoncrusher.latestsid != null)
			{
				if (!mormoncrusher.sidtoconnection.ContainsKey(mormoncrusher.latestsid))
				{
					mormoncrusher.sidtoconnection.Add(mormoncrusher.latestsid, connection);
					mormoncrusher.latestsid = null;
				}
				else
				{
					mormoncrusher.sidtoconnection.Remove(mormoncrusher.latestsid);
					mormoncrusher.sidtoconnection.Add(mormoncrusher.latestsid, connection);
				}
			}
		}
	}
	public static class MyPluginInfo
	{
		public const string PLUGIN_GUID = "decloak";

		public const string PLUGIN_NAME = "meatgrind the retarded";

		public const string PLUGIN_VERSION = "1.1.4";
	}
}
[CompilerGenerated]
internal sealed class <>z__ReadOnlyArray<T> : IEnumerable, ICollection, IList, IEnumerable<T>, IReadOnlyCollection<T>, IReadOnlyList<T>, ICollection<T>, IList<T>
{
	int ICollection.Count => _items.Length;

	bool ICollection.IsSynchronized => false;

	object ICollection.SyncRoot => this;

	object IList.this[int index]
	{
		get
		{
			return _items[index];
		}
		set
		{
			throw new NotSupportedException();
		}
	}

	bool IList.IsFixedSize => true;

	bool IList.IsReadOnly => true;

	int IReadOnlyCollection<T>.Count => _items.Length;

	T IReadOnlyList<T>.this[int index] => _items[index];

	int ICollection<T>.Count => _items.Length;

	bool ICollection<T>.IsReadOnly => true;

	T IList<T>.this[int index]
	{
		get
		{
			return _items[index];
		}
		set
		{
			throw new NotSupportedException();
		}
	}

	public <>z__ReadOnlyArray(T[] items)
	{
		_items = items;
	}

	IEnumerator IEnumerable.GetEnumerator()
	{
		return ((IEnumerable)_items).GetEnumerator();
	}

	void ICollection.CopyTo(Array array, int index)
	{
		((ICollection)_items).CopyTo(array, index);
	}

	int IList.Add(object value)
	{
		throw new NotSupportedException();
	}

	void IList.Clear()
	{
		throw new NotSupportedException();
	}

	bool IList.Contains(object value)
	{
		return ((IList)_items).Contains(value);
	}

	int IList.IndexOf(object value)
	{
		return ((IList)_items).IndexOf(value);
	}

	void IList.Insert(int index, object value)
	{
		throw new NotSupportedException();
	}

	void IList.Remove(object value)
	{
		throw new NotSupportedException();
	}

	void IList.RemoveAt(int index)
	{
		throw new NotSupportedException();
	}

	IEnumerator<T> IEnumerable<T>.GetEnumerator()
	{
		return ((IEnumerable<T>)_items).GetEnumerator();
	}

	void ICollection<T>.Add(T item)
	{
		throw new NotSupportedException();
	}

	void ICollection<T>.Clear()
	{
		throw new NotSupportedException();
	}

	bool ICollection<T>.Contains(T item)
	{
		return ((ICollection<T>)_items).Contains(item);
	}

	void ICollection<T>.CopyTo(T[] array, int arrayIndex)
	{
		((ICollection<T>)_items).CopyTo(array, arrayIndex);
	}

	bool ICollection<T>.Remove(T item)
	{
		throw new NotSupportedException();
	}

	int IList<T>.IndexOf(T item)
	{
		return ((IList<T>)_items).IndexOf(item);
	}

	void IList<T>.Insert(int index, T item)
	{
		throw new NotSupportedException();
	}

	void IList<T>.RemoveAt(int index)
	{
		throw new NotSupportedException();
	}
}