Decompiled source of BonelabRichPresence v2.1.2

Mods/BLRPC.dll

Decompiled 8 months ago
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.IO;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using System.Runtime.Versioning;
using System.Text;
using BLRPC;
using BLRPC.Internal;
using BLRPC.Melon;
using BLRPC.Presence;
using BLRPC.Presence.Handlers;
using BLRPC.Presence.Handlers.Helpers;
using BoneLib;
using BoneLib.BoneMenu;
using BoneLib.BoneMenu.Elements;
using Discord;
using HarmonyLib;
using LabFusion.Network;
using LabFusion.Preferences;
using LabFusion.Representation;
using LabFusion.Utilities;
using MelonLoader;
using MelonLoader.Preferences;
using Microsoft.CodeAnalysis;
using ModioModNetworker.Data;
using ModioModNetworker.Utilities;
using NEP.DOOMLAB.Entities;
using SLZ.AI;
using SLZ.Marrow.SceneStreaming;
using SLZ.Marrow.Warehouse;
using SLZ.Props;
using SLZ.Props.Weapons;
using SLZ.Rig;
using SLZ.VRMK;
using Steamworks;
using UnityEngine;

[assembly: CompilationRelaxations(8)]
[assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)]
[assembly: Debuggable(DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints)]
[assembly: AssemblyTitle("Discord Rich Presence for BONELAB")]
[assembly: AssemblyDescription("Discord Rich Presence for BONELAB")]
[assembly: AssemblyCompany("Weather Electric")]
[assembly: AssemblyProduct("BLRPC")]
[assembly: AssemblyCopyright("Developed by SoulWithMae")]
[assembly: AssemblyTrademark("Weather Electric")]
[assembly: AssemblyFileVersion("2.1.2")]
[assembly: MelonInfo(typeof(Main), "BLRPC", "2.1.2", "SoulWithMae", "https://bonelab.thunderstore.io/package/SoulWithMae/BonelabRichPresence/")]
[assembly: MelonColor(ConsoleColor.Blue)]
[assembly: MelonGame("Stress Level Zero", "BONELAB")]
[assembly: MelonOptionalDependencies(new string[] { "DOOMLAB", "LabFusion", "ModioModNetworker" })]
[assembly: TargetFramework(".NETFramework,Version=v4.7.2", FrameworkDisplayName = ".NET Framework 4.7.2")]
[assembly: AssemblyVersion("2.1.2.0")]
[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 BLRPC
{
	public class Main : MelonMod
	{
		internal const string Name = "BLRPC";

		internal const string Description = "Discord Rich Presence for BONELAB";

		internal const string Author = "SoulWithMae";

		internal const string Company = "Weather Electric";

		internal const string Version = "2.1.2";

		internal const string DownloadLink = "https://bonelab.thunderstore.io/package/SoulWithMae/BonelabRichPresence/";

		public static bool IsQuest;

		private static bool _checkedQuest;

		public static bool FusionInstalled;

		public static bool NetworkerInstalled;

		public static bool DiscordClosed;

		public override void OnInitializeMelon()
		{
			ModConsole.Setup(((MelonBase)this).LoggerInstance);
			if (!IsQuest)
			{
				Preferences.Setup();
				if (DiscordOpen())
				{
					UserData.Setup();
					ModConsole.Msg("Initializing RPC", 1);
					RpcManager.Init();
					BoneMenu.Setup();
					Hooking.OnLevelInitialized += OnLevelLoad;
				}
			}
		}

		public override void OnLateInitializeMelon()
		{
			if (HelperMethods.CheckIfAssemblyLoaded("labfusion"))
			{
				FusionHandler.Init();
			}
			NetworkerInstalled = HelperMethods.CheckIfAssemblyLoaded("modiomodnetworker");
			FusionInstalled = HelperMethods.CheckIfAssemblyLoaded("labfusion");
		}

		private static bool DiscordOpen()
		{
			Process[] processesByName = Process.GetProcessesByName("discord");
			Process[] processesByName2 = Process.GetProcessesByName("discordcanary");
			Process[] processesByName3 = Process.GetProcessesByName("discordptb");
			if (processesByName2.Length == 0 && processesByName.Length == 0 && processesByName3.Length == 0)
			{
				ModConsole.Error("Neither Discord, Discord Canary, or Discord PTB are running!");
				DiscordClosed = true;
				return false;
			}
			if ((processesByName.Length != 0 && processesByName2.Length != 0) || (processesByName.Length != 0 && processesByName3.Length != 0) || (processesByName2.Length != 0 && processesByName3.Length != 0))
			{
				ModConsole.Error("You have 2 Discords open! Discord may struggle to pick one, and it may not work! Please close one and restart!");
			}
			return true;
		}

		public override void OnApplicationQuit()
		{
			if (!IsQuest && !DiscordClosed)
			{
				RpcManager.Dispose();
				UserData.Dispose();
			}
		}

		public override void OnUpdate()
		{
			if (_checkedQuest)
			{
				if (HelperMethods.IsAndroid())
				{
					ModConsole.Error("You are on Quest! This mod won't work! Please use the PC version of BONELAB!");
					IsQuest = true;
				}
				_checkedQuest = true;
			}
			if (!IsQuest && !DiscordClosed)
			{
				RpcManager.Discord.RunCallbacks();
			}
		}

		private static void OnLevelLoad(LevelInfo levelInfo)
		{
			//IL_0014: Unknown result type (might be due to invalid IL or missing references)
			//IL_0061: Unknown result type (might be due to invalid IL or missing references)
			if (!IsQuest && !DiscordClosed)
			{
				ModConsole.Msg("Level loaded: " + levelInfo.title, 1);
				if (Preferences.ResetKillsOnLevelLoad.Value)
				{
					DeathHandler.NPC.Counter = 0;
				}
				if (Preferences.ResetGunShotsOnLevelLoad.Value)
				{
					GunshotHandler.Counter = 0;
				}
				if (Preferences.ResetDeathsOnLevelLoad.Value)
				{
					DeathHandler.Player.Counter = 0;
				}
				SpawnGunHandler.Counter = 0;
				LevelHandler.OnLevelLoaded(levelInfo);
			}
		}
	}
}
namespace BLRPC.Presence
{
	internal static class RpcManager
	{
		public enum ActivityField
		{
			State,
			Details,
			LargeImageKey,
			LargeImageText,
			SmallImageKey,
			SmallImageText,
			Party,
			JoinSecret
		}

		public static global::Discord.Discord Discord;

		public static ActivityManager ActivityManager;

		private static readonly long Start = DateTimeOffset.UtcNow.ToUnixTimeSeconds();

		private static Activity _activity;

		public static void Init()
		{
			ModConsole.Msg("Initializing RPC", 1);
			Discord = new global::Discord.Discord(Preferences.DiscordAppId.Value, 0uL);
			ModConsole.Msg($"Discord is {Discord}", 1);
			ModConsole.Msg($"Application ID is {Preferences.DiscordAppId.Value}", 1);
			ActivityManager = Discord.GetActivityManager();
			ModConsole.Msg($"Activity manager is {ActivityManager}", 1);
			Activity activity = default(Activity);
			activity.State = "Loading Game";
			activity.Timestamps.Start = Start;
			activity.Assets.LargeImage = "bonelab";
			activity.Assets.LargeText = "BONELAB";
			activity.Instance = false;
			_activity = activity;
			UpdateRpc();
		}

		public static void Dispose()
		{
			Discord.Dispose();
		}

		public static void SetActivity(ActivityField activityField, string value)
		{
			switch (activityField)
			{
			case ActivityField.State:
				_activity.State = value;
				break;
			case ActivityField.Details:
				_activity.Details = value;
				break;
			case ActivityField.LargeImageKey:
				_activity.Assets.LargeImage = value;
				break;
			case ActivityField.LargeImageText:
				_activity.Assets.LargeText = value;
				break;
			case ActivityField.SmallImageKey:
				_activity.Assets.SmallImage = value;
				break;
			case ActivityField.SmallImageText:
				_activity.Assets.SmallText = value;
				break;
			case ActivityField.JoinSecret:
				_activity.Secrets.Join = value;
				break;
			case ActivityField.Party:
				ModConsole.Error("This error is my fault, called a method wrong.");
				break;
			default:
				ModConsole.Error("Invalid activity field!");
				break;
			}
			UpdateRpc();
		}

		public static void SetActivity(ActivityField activityField, ActivityParty party)
		{
			switch (activityField)
			{
			case ActivityField.State:
				ModConsole.Error("This error is my fault, called a method wrong.");
				break;
			case ActivityField.Details:
				ModConsole.Error("This error is my fault, called a method wrong.");
				break;
			case ActivityField.LargeImageKey:
				ModConsole.Error("This error is my fault, called a method wrong.");
				break;
			case ActivityField.LargeImageText:
				ModConsole.Error("This error is my fault, called a method wrong.");
				break;
			case ActivityField.SmallImageKey:
				ModConsole.Error("This error is my fault, called a method wrong.");
				break;
			case ActivityField.SmallImageText:
				ModConsole.Error("This error is my fault, called a method wrong.");
				break;
			case ActivityField.Party:
				_activity.Party = party;
				break;
			default:
				ModConsole.Error("Invalid activity field!");
				break;
			}
			UpdateRpc();
		}

		public static void UpdateRpc()
		{
			ModConsole.Msg("Setting activity | Details: " + _activity.Details + " | State: " + _activity.State + " | LargeImageKey: " + _activity.Assets.LargeImage + " | LargeImageText: " + _activity.Assets.LargeText + " | SmallImageKey: " + _activity.Assets.SmallImage + " | SmallImageText: " + _activity.Assets.SmallText, 1);
			ActivityManager.UpdateActivity(_activity, delegate(Result result)
			{
				if (result == Result.Ok)
				{
					ModConsole.Msg("Successfully set activity!", 1);
				}
				else
				{
					ModConsole.Error("Failed to set activity: " + result);
				}
			});
		}
	}
}
namespace BLRPC.Presence.Handlers
{
	internal static class AvatarHandler
	{
		[HarmonyPatch(typeof(ArtRig), "SetAvatar")]
		public class ArtRigSetAvatar
		{
			public static void Postfix(ArtRig __instance, Avatar avatar)
			{
				if (Main.FusionInstalled && !FusionPlayer.IsSelf(((Rig)__instance).manager))
				{
					return;
				}
				DelayUtilities.Delay((Action)delegate
				{
					Barcode barcode = ((Scannable)((CrateReferenceT<AvatarCrate>)(object)((Rig)__instance).manager.AvatarCrate).Crate).Barcode;
					string title = ((Scannable)((CrateReferenceT<AvatarCrate>)(object)((Rig)__instance).manager.AvatarCrate).Crate).Title;
					if (title != null && !(barcode == (Barcode)null))
					{
						RpcManager.SetActivity(RpcManager.ActivityField.SmallImageKey, CheckBarcode.CheckAvatar(Barcode.op_Implicit(barcode)));
						RpcManager.SetActivity(RpcManager.ActivityField.SmallImageText, title);
					}
				}, 2);
			}
		}
	}
	internal static class DeathHandler
	{
		public static class NPC
		{
			[HarmonyPatch(typeof(AIBrain), "OnDeath")]
			public class AIBrain_OnDeath
			{
				public static void Postfix(AIBrain __instance)
				{
					if (!Main.IsQuest && !Main.DiscordClosed && Preferences.DetailsMode.Value == DetailsMode.NPCDeaths)
					{
						UpdateCounter();
					}
				}
			}

			[HarmonyPatch(typeof(Mobj), "Kill")]
			public class Mobj_OnDeath
			{
				public static void Postfix(Mobj __instance)
				{
					//IL_0029: Unknown result type (might be due to invalid IL or missing references)
					if (!Main.IsQuest && !Main.DiscordClosed && Preferences.DetailsMode.Value == DetailsMode.NPCDeaths && Preferences.CountDoomlabDeaths.Value && ((Enum)__instance.flags).HasFlag((Enum)(object)(MobjFlags)4194304))
					{
						UpdateCounter();
					}
				}
			}

			public static int Counter;

			private static void UpdateCounter()
			{
				Counter++;
				ModConsole.Msg($"NPC died, new death count is {Counter}", 1);
				RpcManager.SetActivity(RpcManager.ActivityField.Details, $"NPC Deaths: {Counter}");
			}
		}

		public static class Player
		{
			[HarmonyPatch(typeof(Player_Health), "Death")]
			public class PlayerDeath
			{
				public static void Postfix(Player_Health __instance)
				{
					if (!Main.IsQuest && !Main.DiscordClosed && Preferences.DetailsMode.Value == DetailsMode.PlayerDeaths)
					{
						UpdateCounter();
					}
				}
			}

			public static int Counter;

			private static void UpdateCounter()
			{
				Counter++;
				ModConsole.Msg($"Player died, new death count is {Counter}", 1);
				RpcManager.SetActivity(RpcManager.ActivityField.Details, $"Player Deaths: {Counter}");
			}
		}
	}
	internal static class FusionHandler
	{
		[CompilerGenerated]
		private static class <>O
		{
			public static ServerEvent <0>__OnJoinLobby;

			public static ServerEvent <1>__OnLeaveLobby;

			public static ServerEvent <2>__OnStartLobby;

			public static PlayerUpdate <3>__OnPlayerJoin;

			public static PlayerUpdate <4>__OnPlayerLeave;

			public static ServerEvent <5>__OnServerSettingsChanged;

			public static LobbyManager.ConnectLobbyWithActivitySecretHandler <6>__DiscordJoinLobby;

			public static LobbyManager.CreateLobbyHandler <7>__OnDiscordLobbyCreate;
		}

		public static bool InServer;

		private static ActivityParty _party;

		private static Lobby _lobby;

		private static LobbyManager _lobbyManager;

		private static ActivityPartyPrivacy ConvertPartyPrivacy(ServerPrivacy serverPrivacy)
		{
			//IL_0000: Unknown result type (might be due to invalid IL or missing references)
			//IL_0016: Expected I4, but got Unknown
			return (int)serverPrivacy switch
			{
				0 => ActivityPartyPrivacy.Public, 
				2 => ActivityPartyPrivacy.Private, 
				1 => ActivityPartyPrivacy.Private, 
				3 => ActivityPartyPrivacy.Private, 
				_ => ActivityPartyPrivacy.Private, 
			};
		}

		private static LobbyType ConvertLobbyType(ServerPrivacy serverPrivacy)
		{
			//IL_0000: Unknown result type (might be due to invalid IL or missing references)
			//IL_0016: Expected I4, but got Unknown
			return (int)serverPrivacy switch
			{
				0 => LobbyType.Public, 
				2 => LobbyType.Private, 
				1 => LobbyType.Private, 
				3 => LobbyType.Private, 
				_ => LobbyType.Private, 
			};
		}

		public static void Init()
		{
			//IL_001f: Unknown result type (might be due to invalid IL or missing references)
			//IL_0024: Unknown result type (might be due to invalid IL or missing references)
			//IL_002a: Expected O, but got Unknown
			//IL_003f: 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_004a: Expected O, but got Unknown
			//IL_005f: Unknown result type (might be due to invalid IL or missing references)
			//IL_0064: Unknown result type (might be due to invalid IL or missing references)
			//IL_006a: Expected O, but got Unknown
			//IL_007f: Unknown result type (might be due to invalid IL or missing references)
			//IL_0084: Unknown result type (might be due to invalid IL or missing references)
			//IL_008a: Expected O, but got Unknown
			//IL_009f: Unknown result type (might be due to invalid IL or missing references)
			//IL_00a4: Unknown result type (might be due to invalid IL or missing references)
			//IL_00aa: Expected O, but got Unknown
			//IL_00bf: Unknown result type (might be due to invalid IL or missing references)
			//IL_00c4: Unknown result type (might be due to invalid IL or missing references)
			//IL_00ca: Expected O, but got Unknown
			_lobbyManager = RpcManager.Discord.GetLobbyManager();
			object obj = <>O.<0>__OnJoinLobby;
			if (obj == null)
			{
				ServerEvent val = OnJoinLobby;
				<>O.<0>__OnJoinLobby = val;
				obj = (object)val;
			}
			MultiplayerHooking.OnJoinServer += (ServerEvent)obj;
			object obj2 = <>O.<1>__OnLeaveLobby;
			if (obj2 == null)
			{
				ServerEvent val2 = OnLeaveLobby;
				<>O.<1>__OnLeaveLobby = val2;
				obj2 = (object)val2;
			}
			MultiplayerHooking.OnDisconnect += (ServerEvent)obj2;
			object obj3 = <>O.<2>__OnStartLobby;
			if (obj3 == null)
			{
				ServerEvent val3 = OnStartLobby;
				<>O.<2>__OnStartLobby = val3;
				obj3 = (object)val3;
			}
			MultiplayerHooking.OnStartServer += (ServerEvent)obj3;
			object obj4 = <>O.<3>__OnPlayerJoin;
			if (obj4 == null)
			{
				PlayerUpdate val4 = OnPlayerJoin;
				<>O.<3>__OnPlayerJoin = val4;
				obj4 = (object)val4;
			}
			MultiplayerHooking.OnPlayerJoin += (PlayerUpdate)obj4;
			object obj5 = <>O.<4>__OnPlayerLeave;
			if (obj5 == null)
			{
				PlayerUpdate val5 = OnPlayerLeave;
				<>O.<4>__OnPlayerLeave = val5;
				obj5 = (object)val5;
			}
			MultiplayerHooking.OnPlayerLeave += (PlayerUpdate)obj5;
			object obj6 = <>O.<5>__OnServerSettingsChanged;
			if (obj6 == null)
			{
				ServerEvent val6 = OnServerSettingsChanged;
				<>O.<5>__OnServerSettingsChanged = val6;
				obj6 = (object)val6;
			}
			MultiplayerHooking.OnServerSettingsChanged += (ServerEvent)obj6;
			ActivityParty party = default(ActivityParty);
			party.Id = "disconnected";
			party.Size.CurrentSize = 0;
			party.Size.MaxSize = 0;
			_party = party;
			RpcManager.ActivityManager.OnActivityJoin += delegate(string secret)
			{
				_lobbyManager.ConnectLobbyWithActivitySecret(secret, DiscordJoinLobby);
			};
		}

		private static void DiscordJoinLobby(Result result, ref Lobby lobby)
		{
			//IL_0043: Unknown result type (might be due to invalid IL or missing references)
			//IL_0048: Unknown result type (might be due to invalid IL or missing references)
			//IL_0058: Unknown result type (might be due to invalid IL or missing references)
			if (InServer)
			{
				return;
			}
			if (result != 0)
			{
				ModConsole.Error("Failed to join lobby: " + result);
				return;
			}
			SteamId val = SteamId.op_Implicit(ulong.Parse(_lobbyManager.GetLobbyMetadataValue(lobby.Id, "steamLobbyId")));
			NetworkLayer currentNetworkLayer = NetworkInfo.CurrentNetworkLayer;
			SteamNetworkLayer val2 = (SteamNetworkLayer)(object)((currentNetworkLayer is SteamNetworkLayer) ? currentNetworkLayer : null);
			if (val2 != null)
			{
				val2.JoinServer(val);
			}
			_lobby = lobby;
			RpcManager.SetActivity(RpcManager.ActivityField.JoinSecret, _lobbyManager.GetLobbyActivitySecret(lobby.Id));
		}

		private static void OnJoinLobby()
		{
			//IL_0052: Unknown result type (might be due to invalid IL or missing references)
			InServer = true;
			ModConsole.Msg("Joined lobby, setting party activity.", 1);
			_party.Size.CurrentSize = PlayerIdManager.PlayerCount;
			_party.Size.MaxSize = FusionPreferences.ActiveServerSettings.MaxPlayers.GetValue();
			_party.Privacy = ConvertPartyPrivacy(FusionPreferences.ActiveServerSettings.Privacy.GetValue());
			_party.Id = _lobby.Id.ToString();
			RpcManager.SetActivity(RpcManager.ActivityField.Party, _party);
		}

		private static void OnServerSettingsChanged()
		{
			//IL_0040: Unknown result type (might be due to invalid IL or missing references)
			//IL_0086: Unknown result type (might be due to invalid IL or missing references)
			//IL_00a1: Unknown result type (might be due to invalid IL or missing references)
			//IL_00a7: Invalid comparison between Unknown and I4
			if (!InServer)
			{
				return;
			}
			ModConsole.Msg("Server settings changed, updating party activity.", 1);
			_party.Size.MaxSize = FusionPreferences.ActiveServerSettings.MaxPlayers.GetValue();
			_party.Privacy = ConvertPartyPrivacy(FusionPreferences.ActiveServerSettings.Privacy.GetValue());
			LobbyTransaction lobbyUpdateTransaction = _lobbyManager.GetLobbyUpdateTransaction(_lobby.Id);
			lobbyUpdateTransaction.SetCapacity(FusionPreferences.ActiveServerSettings.MaxPlayers.GetValue());
			lobbyUpdateTransaction.SetType(ConvertLobbyType(FusionPreferences.ActiveServerSettings.Privacy.GetValue()));
			lobbyUpdateTransaction.SetLocked((int)FusionPreferences.ActiveServerSettings.Privacy.GetValue() == 3);
			_lobbyManager.UpdateLobby(_lobby.Id, lobbyUpdateTransaction, delegate(Result res)
			{
				if (res != 0)
				{
					ModConsole.Error("Failed to update lobby: " + res);
				}
			});
			RpcManager.SetActivity(RpcManager.ActivityField.Party, _party);
		}

		private static void OnStartLobby()
		{
			//IL_0033: Unknown result type (might be due to invalid IL or missing references)
			//IL_004e: Unknown result type (might be due to invalid IL or missing references)
			//IL_0054: Invalid comparison between Unknown and I4
			InServer = true;
			LobbyTransaction lobbyCreateTransaction = _lobbyManager.GetLobbyCreateTransaction();
			lobbyCreateTransaction.SetCapacity(FusionPreferences.ActiveServerSettings.MaxPlayers.GetValue());
			lobbyCreateTransaction.SetType(ConvertLobbyType(FusionPreferences.ActiveServerSettings.Privacy.GetValue()));
			lobbyCreateTransaction.SetLocked((int)FusionPreferences.ActiveServerSettings.Privacy.GetValue() == 3);
			_lobbyManager.CreateLobby(lobbyCreateTransaction, OnDiscordLobbyCreate);
		}

		private static void OnDiscordLobbyCreate(Result result, ref Lobby lobby)
		{
			//IL_0039: Unknown result type (might be due to invalid IL or missing references)
			//IL_003e: Unknown result type (might be due to invalid IL or missing references)
			//IL_00ce: Unknown result type (might be due to invalid IL or missing references)
			//IL_00d3: Unknown result type (might be due to invalid IL or missing references)
			if (result != 0)
			{
				ModConsole.Error("Failed to create lobby: " + result);
				return;
			}
			LobbyTransaction lobbyUpdateTransaction = _lobbyManager.GetLobbyUpdateTransaction(lobby.Id);
			SteamId steamId = SteamClient.SteamId;
			lobbyUpdateTransaction.SetMetadata("steamLobbyId", ((object)(SteamId)(ref steamId)).ToString());
			_lobbyManager.UpdateLobby(lobby.Id, lobbyUpdateTransaction, delegate(Result res)
			{
				if (res != 0)
				{
					ModConsole.Error("Failed to update lobby: " + res);
				}
			});
			_lobby = lobby;
			ModConsole.Msg("Started lobby, setting party activity.", 1);
			_party.Size.CurrentSize = PlayerIdManager.PlayerCount;
			_party.Size.MaxSize = FusionPreferences.ActiveServerSettings.MaxPlayers.GetValue();
			steamId = SteamClient.SteamId;
			_party.Id = ((object)(SteamId)(ref steamId)).ToString();
			RpcManager.SetActivity(RpcManager.ActivityField.Party, _party);
			RpcManager.SetActivity(RpcManager.ActivityField.JoinSecret, _lobbyManager.GetLobbyActivitySecret(lobby.Id));
		}

		private static void OnLeaveLobby()
		{
			InServer = false;
			ModConsole.Msg("Left lobby, clearing party activity.", 1);
			_party.Id = "";
			_party.Size.CurrentSize = 0;
			_party.Size.MaxSize = 0;
			RpcManager.SetActivity(RpcManager.ActivityField.Party, _party);
			RpcManager.SetActivity(RpcManager.ActivityField.State, "In " + ((Scannable)SceneStreamer.Session.Level).Title);
			RpcManager.SetActivity(RpcManager.ActivityField.JoinSecret, "");
		}

		private static void OnPlayerJoin(PlayerId playerId)
		{
			ModConsole.Msg("Player joined, updating party activity.", 1);
			_party.Size.CurrentSize = PlayerIdManager.PlayerCount;
			RpcManager.SetActivity(RpcManager.ActivityField.Party, _party);
		}

		private static void OnPlayerLeave(PlayerId playerId)
		{
			ModConsole.Msg("Player left, updating party activity.", 1);
			_party.Size.CurrentSize = PlayerIdManager.PlayerCount;
			RpcManager.SetActivity(RpcManager.ActivityField.Party, _party);
		}
	}
	internal static class GunshotHandler
	{
		[HarmonyPatch(typeof(Gun), "OnFire")]
		public class GunFire
		{
			public static void Postfix(Gun __instance)
			{
				if (!Main.IsQuest && !Main.DiscordClosed && Preferences.DetailsMode.Value == DetailsMode.GunShots && !Object.op_Implicit((Object)(object)((Component)__instance).GetComponent<SpawnGun>()))
				{
					UpdateCounter();
				}
			}
		}

		public static int Counter;

		private static void UpdateCounter()
		{
			Counter++;
			ModConsole.Msg($"Gun fired, new shot count is {Counter}", 1);
			RpcManager.SetActivity(RpcManager.ActivityField.Details, $"Gun Shots Fired: {Counter}");
		}
	}
	internal static class LevelHandler
	{
		public static void OnLevelLoaded(LevelInfo levelInfo)
		{
			//IL_001f: Unknown result type (might be due to invalid IL or missing references)
			//IL_000d: Unknown result type (might be due to invalid IL or missing references)
			//IL_0035: Unknown result type (might be due to invalid IL or missing references)
			//IL_0046: Unknown result type (might be due to invalid IL or missing references)
			RpcManager.SetActivity(RpcManager.ActivityField.State, FusionHandler.InServer ? ("In " + levelInfo.title + " | Fusion") : ("In " + levelInfo.title));
			RpcManager.SetActivity(RpcManager.ActivityField.LargeImageKey, CheckBarcode.CheckMap(levelInfo.barcode));
			RpcManager.SetActivity(RpcManager.ActivityField.LargeImageText, levelInfo.title);
			switch (Preferences.DetailsMode.Value)
			{
			case DetailsMode.GunShots:
				RpcManager.SetActivity(RpcManager.ActivityField.Details, $"Gun Shots Fired: {GunshotHandler.Counter}");
				break;
			case DetailsMode.NPCDeaths:
				RpcManager.SetActivity(RpcManager.ActivityField.Details, $"NPC Deaths: {DeathHandler.NPC.Counter}");
				break;
			case DetailsMode.SpawnablesPlaced:
				RpcManager.SetActivity(RpcManager.ActivityField.Details, $"Objects Spawned: {SpawnGunHandler.Counter}");
				break;
			case DetailsMode.SDKMods:
				RpcManager.SetActivity(RpcManager.ActivityField.Details, $"SDK Mods Loaded: {CheckPallets.GetPalletCount()}");
				break;
			case DetailsMode.Extraes:
				RpcManager.SetActivity(RpcManager.ActivityField.Details, ExtraesMode.RandomScreamingAboutNonsense());
				break;
			case DetailsMode.Entries:
				RpcManager.SetActivity(RpcManager.ActivityField.Details, GetEntry());
				break;
			case DetailsMode.PlayerDeaths:
				RpcManager.SetActivity(RpcManager.ActivityField.Details, $"Player Deaths: {DeathHandler.Player.Counter}");
				break;
			default:
				ModConsole.Error("You don't have a proper mode set!");
				RpcManager.SetActivity(RpcManager.ActivityField.Details, "Somehow, this broke!");
				break;
			}
		}

		private static string GetEntry()
		{
			Random random = new Random();
			string[] array = File.ReadAllLines(UserData.UserEntriesPath);
			int num = random.Next(array.Length);
			return array[num];
		}
	}
	internal static class SpawnGunHandler
	{
		[HarmonyPatch(typeof(SpawnGun), "OnFire")]
		public class SpawnGunSpawn
		{
			public static void Postfix(SpawnGun __instance)
			{
				if (!Main.IsQuest && !Main.DiscordClosed && Preferences.DetailsMode.Value == DetailsMode.SpawnablesPlaced)
				{
					UpdateCounter();
				}
			}
		}

		public static int Counter;

		private static void UpdateCounter()
		{
			Counter++;
			ModConsole.Msg($"Spawnable placed, new spawn count is {Counter}", 1);
			RpcManager.SetActivity(RpcManager.ActivityField.Details, $"Objects Spawned: {Counter}");
		}
	}
}
namespace BLRPC.Presence.Handlers.Helpers
{
	internal static class CheckBarcode
	{
		public static string CheckAvatar(string barcode)
		{
			return barcode switch
			{
				"fa534c5a83ee4ec6bd641fec424c4142.Avatar.Heavy" => "heavy", 
				"fa534c5a83ee4ec6bd641fec424c4142.Avatar.Fast" => "fast", 
				"fa534c5a83ee4ec6bd641fec424c4142.Avatar.CharFurv4GB" => "short", 
				"fa534c5a83ee4ec6bd641fec424c4142.Avatar.CharTallv4" => "tall", 
				"fa534c5a83ee4ec6bd641fec424c4142.Avatar.Strong" => "strong", 
				"SLZ.BONELAB.Content.Avatar.Anime" => "light", 
				"SLZ.BONELAB.Content.Avatar.CharJimmy" => "jimmy", 
				"SLZ.BONELAB.Content.Avatar.FordBW" => "ford", 
				"SLZ.BONELAB.Content.Avatar.CharFord" => "ford", 
				"SLZ.BONELAB.Core.Avatar.PeasantFemaleA" => "peasantfemalea", 
				"c3534c5a-10bf-48e9-beca-4ca850656173" => "peasantfemaleb", 
				"c3534c5a-2236-4ce5-9385-34a850656173" => "peasantfemalec", 
				"c3534c5a-87a3-48b2-87cd-f0a850656173" => "peasantmalea", 
				"c3534c5a-f12c-44ef-b953-b8a850656173" => "peasantmaleb", 
				"c3534c5a-3763-4ddf-bd86-6ca850656173" => "peasantmalec", 
				"SLZ.BONELAB.Content.Avatar.Nullbody" => "nullbody", 
				"fa534c5a83ee4ec6bd641fec424c4142.Avatar.Charskeleton" => "skeleton", 
				"c3534c5a-d388-4945-b4ff-9c7a53656375" => "securityguard", 
				"SLZ.BONELAB.Content.Avatar.DogDuckSeason" => "duckseasondog", 
				"c3534c5a-94b2-40a4-912a-24a8506f6c79" => "polyblank", 
				"SLZ.BONELAB.NoBuild.Avatar.PolyDebugger" => "polyblank", 
				_ => Main.NetworkerInstalled ? RemoteImageHandler.CheckforExternalImage(barcode, "moddedavatar") : "moddedavatar", 
			};
		}

		public static string CheckMap(string barcode)
		{
			return barcode switch
			{
				"c2534c5a-80e1-4a29-93ca-f3254d656e75" => "mainmenu", 
				"c2534c5a-4197-4879-8cd3-4a695363656e" => "descent", 
				"c2534c5a-6b79-40ec-8e98-e58c5363656e" => "blhub", 
				"c2534c5a-56a6-40ab-a8ce-23074c657665" => "longrun", 
				"c2534c5a-54df-470b-baaf-741f4c657665" => "minedive", 
				"c2534c5a-7601-4443-bdfe-7f235363656e" => "biganomaly", 
				"SLZ.BONELAB.Content.Level.LevelStreetPunch" => "streetpuncher", 
				"SLZ.BONELAB.Content.Level.SprintBridge04" => "sprintbridge", 
				"SLZ.BONELAB.Content.Level.SceneMagmaGate" => "magmagate", 
				"SLZ.BONELAB.Content.Level.MoonBase" => "moonbase", 
				"SLZ.BONELAB.Content.Level.LevelKartRace" => "monogonmotorway", 
				"c2534c5a-c056-4883-ac79-e051426f6964" => "pillarclimb", 
				"SLZ.BONELAB.Content.Level.LevelBigAnomalyB" => "biganomaly2", 
				"c2534c5a-db71-49cf-b694-24584c657665" => "ascent", 
				"SLZ.BONELAB.Content.Level.LevelOutro" => "home", 
				"fa534c5a868247138f50c62e424c4144.Level.VoidG114" => "voidg114", 
				"c2534c5a-61b3-4f97-9059-79155363656e" => "baseline", 
				"fa534c5a83ee4ec6bd641fec424c4142.Level.LevelKartBowling" => "bigbonebowling", 
				"c2534c5a-de61-4df9-8f6c-416954726547" => "droppit", 
				"c2534c5a-5c2f-4eef-a851-66214c657665" => "dungeonwarrior", 
				"fa534c5a868247138f50c62e424c4144.Level.LevelArenaMin" => "fantasyarena", 
				"fa534c5a83ee4ec6bd641fec424c4142.Level.LevelGunRange" => "gunrange", 
				"fa534c5a83ee4ec6bd641fec424c4142.Level.LevelHalfwayPark" => "halfwaypark", 
				"fa534c5a83ee4ec6bd641fec424c4142.Level.LevelHoloChamber" => "holochamber", 
				"fa534c5a83ee4ec6bd641fec424c4142.Level.LevelMuseumBasement" => "museumbasement", 
				"fa534c5a83ee4ec6bd641fec424c4142.Level.SceneparkourDistrictLogic" => "neonparkour", 
				"c2534c5a-4f3b-480e-ad2f-69175363656e" => "neontrial", 
				"c2534c5a-c6ac-48b4-9c5f-b5cd5363656e" => "rooftops", 
				"c2534c5a-c180-40e0-b2b7-325c5363656e" => "tunneltipper", 
				"c2534c5a-2c4c-4b44-b076-203b5363656e" => "tuscany", 
				"c2534c5a-162f-4661-a04d-975d5363656e" => "containeryard", 
				"SLZ.BONELAB.Content.Level.LevelMirror" => "mirror", 
				_ => Main.NetworkerInstalled ? RemoteImageHandler.CheckforExternalImage(barcode, "moddedmap") : "moddedmap", 
			};
		}
	}
	internal static class CheckPallets
	{
		public static int GetPalletCount()
		{
			ModConsole.Msg("Getting pallet count", 1);
			int count = AssetWarehouse.Instance.GetPallets().Count;
			ModConsole.Msg($"Pallet count is {count}", 1);
			return count;
		}
	}
}
namespace BLRPC.Melon
{
	internal static class BoneMenu
	{
		private static MenuCategory _mainCategory;

		private static MenuCategory _menuCategory;

		private static FunctionElement _reloadButton;

		private static readonly MelonEvent<DetailsMode, DetailsMode> EntryValueChanged = Preferences.DetailsMode.OnEntryValueChanged;

		public static void Setup()
		{
			//IL_0037: Unknown result type (might be due to invalid IL or missing references)
			//IL_0057: Unknown result type (might be due to invalid IL or missing references)
			//IL_0082: Unknown result type (might be due to invalid IL or missing references)
			//IL_00a2: Unknown result type (might be due to invalid IL or missing references)
			//IL_00d1: Unknown result type (might be due to invalid IL or missing references)
			_mainCategory = MenuManager.CreateCategory("Weather Electric", "#6FBDFF");
			_menuCategory = _mainCategory.CreateCategory("BLRPC", "#5769ec");
			_menuCategory.CreateEnumPreference<DetailsMode>("Details Mode", Color.white, Preferences.DetailsMode, Preferences.Category);
			SubPanelElement category = _menuCategory.CreateSubPanel("NPC Deaths Settings", Color.green);
			category.CreateBoolPreference("Count DOOMLAB Kills", "#840000", Preferences.CountDoomlabDeaths, Preferences.Category);
			category.CreateBoolPreference("Reset Kills On Level Load", Color.green, Preferences.ResetKillsOnLevelLoad, Preferences.Category);
			_menuCategory.CreateSubPanel("Player Deaths Settings", Color.red).CreateBoolPreference("Reset Deaths On Level Load", "#840000", Preferences.ResetDeathsOnLevelLoad, Preferences.Category);
			_menuCategory.CreateSubPanel("Gun Shots Settings", Color.blue).CreateBoolPreference("Reset Gun Shots On Level Load", "#840000", Preferences.ResetGunShotsOnLevelLoad, Preferences.Category);
			((MelonEventBase<LemonAction<DetailsMode, DetailsMode>>)(object)EntryValueChanged).Subscribe((LemonAction<DetailsMode, DetailsMode>)AddReloadButton, 0, false);
		}

		private static void AddReloadButton(DetailsMode oldval, DetailsMode newval)
		{
			//IL_0012: Unknown result type (might be due to invalid IL or missing references)
			if (_reloadButton == null)
			{
				_reloadButton = _menuCategory.CreateFunctionElement("Reload Level", Color.red, (Action)delegate
				{
					SceneStreamer.Reload();
					_menuCategory.Elements.Remove((MenuElement)(object)_reloadButton);
					_reloadButton = null;
				});
			}
		}
	}
	internal static class BoneMenuExtensions
	{
		public static BoolElement CreateBoolPreference(this MenuCategory category, string name, Color color, MelonPreferences_Entry<bool> pref, MelonPreferences_Category prefCategory, bool autoSave = true)
		{
			//IL_001f: Unknown result type (might be due to invalid IL or missing references)
			return category.CreateBoolElement(name, color, pref.Value, (Action<bool>)delegate(bool v)
			{
				pref.Value = v;
				if (autoSave)
				{
					prefCategory.SaveToFile(false);
				}
			});
		}

		public static BoolElement CreateBoolPreference(this MenuCategory category, string name, string hexColor, MelonPreferences_Entry<bool> pref, MelonPreferences_Category prefCategory, bool autoSave = true)
		{
			return category.CreateBoolElement(name, hexColor, pref.Value, (Action<bool>)delegate(bool v)
			{
				pref.Value = v;
				if (autoSave)
				{
					prefCategory.SaveToFile(false);
				}
			});
		}

		public static BoolElement CreateBoolPreference(this SubPanelElement category, string name, Color color, MelonPreferences_Entry<bool> pref, MelonPreferences_Category prefCategory, bool autoSave = true)
		{
			//IL_001f: Unknown result type (might be due to invalid IL or missing references)
			return category.CreateBoolElement(name, color, pref.Value, (Action<bool>)delegate(bool v)
			{
				pref.Value = v;
				if (autoSave)
				{
					prefCategory.SaveToFile(false);
				}
			});
		}

		public static BoolElement CreateBoolPreference(this SubPanelElement category, string name, string hexColor, MelonPreferences_Entry<bool> pref, MelonPreferences_Category prefCategory, bool autoSave = true)
		{
			return category.CreateBoolElement(name, hexColor, pref.Value, (Action<bool>)delegate(bool v)
			{
				pref.Value = v;
				if (autoSave)
				{
					prefCategory.SaveToFile(false);
				}
			});
		}

		public static FloatElement CreateFloatPreference(this MenuCategory category, string name, Color color, float increment, float min, float max, MelonPreferences_Entry<float> pref, MelonPreferences_Category prefCategory, bool autoSave = true)
		{
			//IL_0020: Unknown result type (might be due to invalid IL or missing references)
			return category.CreateFloatElement(name, color, pref.Value, increment, min, max, (Action<float>)delegate(float v)
			{
				pref.Value = v;
				if (autoSave)
				{
					prefCategory.SaveToFile(false);
				}
			});
		}

		public static FloatElement CreateFloatPreference(this MenuCategory category, string name, string hexColor, float increment, float min, float max, MelonPreferences_Entry<float> pref, MelonPreferences_Category prefCategory, bool autoSave = true)
		{
			return category.CreateFloatElement(name, hexColor, pref.Value, increment, min, max, (Action<float>)delegate(float v)
			{
				pref.Value = v;
				if (autoSave)
				{
					prefCategory.SaveToFile(false);
				}
			});
		}

		public static FloatElement CreateFloatPreference(this SubPanelElement category, string name, Color color, float increment, float min, float max, MelonPreferences_Entry<float> pref, MelonPreferences_Category prefCategory, bool autoSave = true)
		{
			//IL_0020: Unknown result type (might be due to invalid IL or missing references)
			return category.CreateFloatElement(name, color, pref.Value, increment, min, max, (Action<float>)delegate(float v)
			{
				pref.Value = v;
				if (autoSave)
				{
					prefCategory.SaveToFile(false);
				}
			});
		}

		public static FloatElement CreateFloatPreference(this SubPanelElement category, string name, string hexColor, float increment, float min, float max, MelonPreferences_Entry<float> pref, MelonPreferences_Category prefCategory, bool autoSave = true)
		{
			return category.CreateFloatElement(name, hexColor, pref.Value, increment, min, max, (Action<float>)delegate(float v)
			{
				pref.Value = v;
				if (autoSave)
				{
					prefCategory.SaveToFile(false);
				}
			});
		}

		public static IntElement CreateIntPreference(this MenuCategory category, string name, Color color, int increment, int min, int max, MelonPreferences_Entry<int> pref, MelonPreferences_Category prefCategory, bool autoSave = true)
		{
			//IL_0020: Unknown result type (might be due to invalid IL or missing references)
			return category.CreateIntElement(name, color, pref.Value, increment, min, max, (Action<int>)delegate(int v)
			{
				pref.Value = v;
				if (autoSave)
				{
					prefCategory.SaveToFile(false);
				}
			});
		}

		public static IntElement CreateIntPreference(this MenuCategory category, string name, string hexColor, int increment, int min, int max, MelonPreferences_Entry<int> pref, MelonPreferences_Category prefCategory, bool autoSave = true)
		{
			return category.CreateIntElement(name, hexColor, pref.Value, increment, min, max, (Action<int>)delegate(int v)
			{
				pref.Value = v;
				if (autoSave)
				{
					prefCategory.SaveToFile(false);
				}
			});
		}

		public static IntElement CreateIntPreference(this SubPanelElement category, string name, Color color, int increment, int min, int max, MelonPreferences_Entry<int> pref, MelonPreferences_Category prefCategory, bool autoSave = true)
		{
			//IL_0020: Unknown result type (might be due to invalid IL or missing references)
			return category.CreateIntElement(name, color, pref.Value, increment, min, max, (Action<int>)delegate(int v)
			{
				pref.Value = v;
				if (autoSave)
				{
					prefCategory.SaveToFile(false);
				}
			});
		}

		public static IntElement CreateIntPreference(this SubPanelElement category, string name, string hexColor, int increment, int min, int max, MelonPreferences_Entry<int> pref, MelonPreferences_Category prefCategory, bool autoSave = true)
		{
			return category.CreateIntElement(name, hexColor, pref.Value, increment, min, max, (Action<int>)delegate(int v)
			{
				pref.Value = v;
				if (autoSave)
				{
					prefCategory.SaveToFile(false);
				}
			});
		}

		public static EnumElement<TEnum> CreateEnumPreference<TEnum>(this MenuCategory category, string name, Color color, MelonPreferences_Entry<TEnum> pref, MelonPreferences_Category prefCategory, bool autoSave = true) where TEnum : Enum
		{
			//IL_001f: Unknown result type (might be due to invalid IL or missing references)
			return category.CreateEnumElement<TEnum>(name, color, pref.Value, (Action<TEnum>)delegate(TEnum v)
			{
				pref.Value = v;
				if (autoSave)
				{
					prefCategory.SaveToFile(false);
				}
			});
		}

		public static EnumElement<TEnum> CreateEnumPreference<TEnum>(this MenuCategory category, string name, string hexColor, MelonPreferences_Entry<TEnum> pref, MelonPreferences_Category prefCategory, bool autoSave = true) where TEnum : Enum
		{
			return category.CreateEnumElement<TEnum>(name, hexColor, pref.Value, (Action<TEnum>)delegate(TEnum v)
			{
				pref.Value = v;
				if (autoSave)
				{
					prefCategory.SaveToFile(false);
				}
			});
		}

		public static EnumElement<TEnum> CreateEnumPreference<TEnum>(this SubPanelElement category, string name, Color color, MelonPreferences_Entry<TEnum> pref, MelonPreferences_Category prefCategory, bool autoSave = true) where TEnum : Enum
		{
			//IL_001f: Unknown result type (might be due to invalid IL or missing references)
			return category.CreateEnumElement<TEnum>(name, color, pref.Value, (Action<TEnum>)delegate(TEnum v)
			{
				pref.Value = v;
				if (autoSave)
				{
					prefCategory.SaveToFile(false);
				}
			});
		}

		public static EnumElement<TEnum> CreateEnumPreference<TEnum>(this SubPanelElement category, string name, string hexColor, MelonPreferences_Entry<TEnum> pref, MelonPreferences_Category prefCategory, bool autoSave = true) where TEnum : Enum
		{
			return category.CreateEnumElement<TEnum>(name, hexColor, pref.Value, (Action<TEnum>)delegate(TEnum v)
			{
				pref.Value = v;
				if (autoSave)
				{
					prefCategory.SaveToFile(false);
				}
			});
		}
	}
	internal static class ModConsole
	{
		private static Instance _logger;

		public static void Setup(Instance loggerInstance)
		{
			_logger = loggerInstance;
		}

		public static void Msg(object obj, int loggingMode = 0)
		{
			string text = ((loggingMode == 1) ? $"[DEBUG] {obj}" : obj.ToString());
			ConsoleColor consoleColor = ((loggingMode == 1) ? ConsoleColor.Yellow : ConsoleColor.Gray);
			if (Preferences.LoggingMode.Value >= loggingMode)
			{
				_logger.Msg(consoleColor, text);
			}
		}

		public static void Msg(string txt, int loggingMode = 0)
		{
			string text = ((loggingMode == 1) ? ("[DEBUG] " + txt) : txt);
			ConsoleColor consoleColor = ((loggingMode == 1) ? ConsoleColor.Yellow : ConsoleColor.Gray);
			if (Preferences.LoggingMode.Value >= loggingMode)
			{
				_logger.Msg(consoleColor, text);
			}
		}

		public static void Msg(ConsoleColor txtcolor, object obj, int loggingMode = 0)
		{
			string text = ((loggingMode == 1) ? $"[DEBUG] {obj}" : obj.ToString());
			if (Preferences.LoggingMode.Value >= loggingMode)
			{
				_logger.Msg(txtcolor, text);
			}
		}

		public static void Msg(ConsoleColor txtcolor, string txt, int loggingMode = 0)
		{
			string text = ((loggingMode == 1) ? ("[DEBUG] " + txt) : txt);
			if (Preferences.LoggingMode.Value >= loggingMode)
			{
				_logger.Msg(txtcolor, text);
			}
		}

		public static void Msg(string txt, int loggingMode = 0, params object[] args)
		{
			string text = ((loggingMode == 1) ? ("[DEBUG] " + txt) : txt);
			ConsoleColor consoleColor = ((loggingMode == 1) ? ConsoleColor.Yellow : ConsoleColor.Gray);
			if (Preferences.LoggingMode.Value >= loggingMode)
			{
				_logger.Msg(consoleColor, text, args);
			}
		}

		public static void Msg(ConsoleColor txtcolor, string txt, int loggingMode = 0, params object[] args)
		{
			string text = ((loggingMode == 1) ? ("[DEBUG] " + txt) : txt);
			if (Preferences.LoggingMode.Value >= loggingMode)
			{
				_logger.Msg(txtcolor, text, args);
			}
		}

		public static void Error(object obj, int loggingMode = 0)
		{
			string text = ((loggingMode == 1) ? $"[DEBUG] {obj}" : obj.ToString());
			if (Preferences.LoggingMode.Value >= loggingMode)
			{
				_logger.Error(text);
			}
		}

		public static void Error(string txt, int loggingMode = 0)
		{
			string text = ((loggingMode == 1) ? ("[DEBUG] " + txt) : txt);
			if (Preferences.LoggingMode.Value >= loggingMode)
			{
				_logger.Error(text);
			}
		}

		public static void Error(string txt, int loggingMode = 0, params object[] args)
		{
			string text = ((loggingMode == 1) ? ("[DEBUG] " + txt) : txt);
			if (Preferences.LoggingMode.Value >= loggingMode)
			{
				_logger.Error(text, args);
			}
		}

		public static void Warning(object obj, int loggingMode = 0)
		{
			string text = ((loggingMode == 1) ? $"[DEBUG] {obj}" : obj.ToString());
			if (Preferences.LoggingMode.Value >= loggingMode)
			{
				_logger.Warning(text);
			}
		}

		public static void Warning(string txt, int loggingMode = 0)
		{
			string text = ((loggingMode == 1) ? ("[DEBUG] " + txt) : txt);
			if (Preferences.LoggingMode.Value >= loggingMode)
			{
				_logger.Warning(text);
			}
		}

		public static void Warning(string txt, int loggingMode = 0, params object[] args)
		{
			string text = ((loggingMode == 1) ? ("[DEBUG] " + txt) : txt);
			if (Preferences.LoggingMode.Value >= loggingMode)
			{
				_logger.Warning(text, args);
			}
		}
	}
	internal static class Preferences
	{
		private static readonly MelonPreferences_Category GlobalCategory = MelonPreferences.CreateCategory("Global");

		public static readonly MelonPreferences_Category Category = MelonPreferences.CreateCategory("BLRPC");

		public static MelonPreferences_Entry<int> LoggingMode;

		public static MelonPreferences_Entry<long> DiscordAppId;

		public static MelonPreferences_Entry<DetailsMode> DetailsMode;

		public static MelonPreferences_Entry<bool> CountDoomlabDeaths;

		public static MelonPreferences_Entry<bool> ResetKillsOnLevelLoad;

		public static MelonPreferences_Entry<bool> ResetDeathsOnLevelLoad;

		public static MelonPreferences_Entry<bool> ResetGunShotsOnLevelLoad;

		public static void Setup()
		{
			LoggingMode = GlobalCategory.GetEntry<int>("LoggingMode") ?? GlobalCategory.CreateEntry<int>("LoggingMode", 0, "Logging Mode", "The level of logging to use. 0 = Important Only, 1 = All", false, false, (ValueValidator)null, (string)null);
			DiscordAppId = Category.CreateEntry<long>("DiscordAppId", 1162864836418490388L, "Discord Application ID", "The application ID for the Discord application that will be used for Rich Presence.", false, false, (ValueValidator)null, (string)null);
			DetailsMode = Category.CreateEntry<DetailsMode>("DetailsMode", BLRPC.Melon.DetailsMode.Entries, "Details Mode", "The mode for the details section. Possible Values: Entries, NPCDeaths, GunShots, Extraes, SDKMods, SpawnablesPlaced", false, false, (ValueValidator)null, (string)null);
			CountDoomlabDeaths = Category.CreateEntry<bool>("CountDOOMLABDeaths", true, "Count DOOMLAB Deaths", "Whether or not to count DOOMLAB deaths in the NPC Deaths counter", false, false, (ValueValidator)null, (string)null);
			ResetKillsOnLevelLoad = Category.CreateEntry<bool>("ResetKillsOnLevelLoad", true, "Reset Kills On Level Load", "Whether or not to reset the NPC kill counter on level load", false, false, (ValueValidator)null, (string)null);
			ResetDeathsOnLevelLoad = Category.CreateEntry<bool>("ResetDeathsOnLevelLoad", true, "Reset Deaths On Level Load", "Whether or not to reset the player death counter on level load", false, false, (ValueValidator)null, (string)null);
			ResetGunShotsOnLevelLoad = Category.CreateEntry<bool>("ResetGunShotsOnLevelLoad", true, "Reset Gun Shots On Level Load", "Whether or not to reset the gun shot counter on level load", false, false, (ValueValidator)null, (string)null);
			GlobalCategory.SetFilePath(MelonUtils.UserDataDirectory + "/WeatherElectric.cfg");
			GlobalCategory.SaveToFile(false);
			Category.SetFilePath(MelonUtils.UserDataDirectory + "/WeatherElectric.cfg");
			Category.SaveToFile(false);
			ModConsole.Msg("Finished preferences setup", 1);
		}
	}
	public enum DetailsMode
	{
		Entries,
		NPCDeaths,
		GunShots,
		Extraes,
		SDKMods,
		SpawnablesPlaced,
		PlayerDeaths
	}
	internal static class UserData
	{
		private static readonly string UserDataDirectory = Path.Combine(MelonUtils.UserDataDirectory, "Weather Electric/BLRPC");

		private static readonly string LegacyDirectory = Path.Combine(MelonUtils.UserDataDirectory, "BLRPC");

		private static readonly string DLLPath = Path.Combine(UserDataDirectory, "discord_game_sdk.dll");

		public static readonly string UserEntriesPath = Path.Combine(UserDataDirectory, "UserEntries.txt");

		private static bool _hasLoadedLib;

		private static IntPtr _rpcLib;

		public static void Setup()
		{
			if (!Directory.Exists(UserDataDirectory))
			{
				ModConsole.Msg("User data directory not found, creating at " + UserDataDirectory, 1);
				Directory.CreateDirectory(UserDataDirectory);
			}
			if (!File.Exists(DLLPath))
			{
				ModConsole.Msg("Discord SDK not unpacked, checking legacy path", 1);
				if (Directory.Exists(LegacyDirectory) && File.Exists(Path.Combine(LegacyDirectory, "discord_game_sdk.dll")))
				{
					File.Move(Path.Combine(LegacyDirectory, "discord_game_sdk.dll"), DLLPath);
				}
				else
				{
					ModConsole.Msg("Legacy path not found, creating at " + DLLPath, 1);
					File.WriteAllBytes(DLLPath, EmbeddedResource.GetResourceBytes("discord_game_sdk.dll"));
				}
			}
			if (!File.Exists(UserEntriesPath))
			{
				ModConsole.Msg("User entries file not unpacked, checking legacy path", 1);
				if (Directory.Exists(LegacyDirectory) && File.Exists(Path.Combine(LegacyDirectory, "UserEntries.txt")))
				{
					File.Move(Path.Combine(LegacyDirectory, "UserEntries.txt"), UserEntriesPath);
				}
				else
				{
					ModConsole.Msg("Legacy path not found, creating at " + UserEntriesPath, 1);
					File.WriteAllBytes(UserEntriesPath, EmbeddedResource.GetResourceBytes("UserEntries.txt"));
				}
			}
			if (!_hasLoadedLib)
			{
				ModConsole.Msg("Loading Discord SDK from " + DLLPath, 1);
				_rpcLib = DllTools.LoadLibrary(DLLPath);
				_hasLoadedLib = true;
			}
		}

		public static void Dispose()
		{
			if (_hasLoadedLib)
			{
				DllTools.FreeLibrary(_rpcLib);
				_hasLoadedLib = false;
			}
		}
	}
}
namespace BLRPC.Internal
{
	internal static class DllTools
	{
		[DllImport("kernel32.dll")]
		public static extern IntPtr LoadLibrary(string dllToLoad);

		[DllImport("kernel32.dll")]
		public static extern bool FreeLibrary(IntPtr hModule);
	}
	internal static class EmbeddedResource
	{
		public static byte[] GetResourceBytes(string filename)
		{
			Assembly executingAssembly = Assembly.GetExecutingAssembly();
			string[] manifestResourceNames = executingAssembly.GetManifestResourceNames();
			foreach (string text in manifestResourceNames)
			{
				if (!text.Contains(filename))
				{
					continue;
				}
				using Stream stream = executingAssembly.GetManifestResourceStream(text);
				if (stream == null)
				{
					return null;
				}
				byte[] array = new byte[stream.Length];
				stream.Read(array, 0, array.Length);
				return array;
			}
			return null;
		}
	}
	internal static class ExtraesMode
	{
		private static readonly string[] Ads = new string[627]
		{
			"my balls lol!!!!!!!!", "deez what sir", "hey mods... ni-", "we do a little trolling", "ping camobiwan and tell him 'helo!!!!!!' for free chill role!", "javascript users SEETHING at this release!", "shoutouts to trev for putting up with my fuckery", "localize mother 3", "4K African", "https://www.youtube.com/watch?v=AGvrDe3rKxA",
			"ur gam haxd by anoms, giv fortnit pswd 2 unhax", "hi :)", "upvote on thunderstore for free cheese wiz", "if you report a crash you better send a log file", "dnspy aint got shit on my shitcode", "shoutouts to simpleflips", "simply an issue of skill", "this mod isnt poorly coded, youre just bad lol", "this mod is poorly coded and unity keeps buckling under its stresses", "swag.",
			"delete system32", "Directory.Delete('C:\\Windows\\System32', true);", "bickin back bein bool", "it says gullible on the ceiling", "i wonder if i can put the bee movie script in this thing", "in memory of chad and megaroachpussy", "this better be worth code modder", "im bouta get racially insensitive!!!!", "double space times new roman 12pt font", "i love arial font!!!!!!!!!!!!!!!!!!",
			"the p4 teaser didnt come out before i released this mod", "gee thanks il2cpp for fucking my shit up", "franzj presents", "install gentoo", "who shit myself", "INSTALL GENTOO INSTALL GENTOO INSTALL GENTOO INSTALL GENTOO INSTALL GENTOO INSTALL GENTOO INSTALL GENTOO INSTALL GENTOO INSTALL GENTOO INSTALL GENTOO INSTALL GENTOO INSTALL GENTOO", "stop playing vr games and get some pussy", "im not homophobic so stop playing vr games and get some dick", "i am sexist, women belong in my bed  please", "FAttY SPiNS - Doin' Your Mom",
			"hotel? trivago. your mom? done.", "if you will indulge me, please suspend disbelief for a moment. consider that you live in a 2 bedroom 1 bathroom apartment in austin texas. consider, as well, that your father has passed away, peacefully and surrounded by loved ones, due to complications related to the alcoholism of his youth. your mother, now in her 60s, is mourning the passing of her husband. now here's where i come in, i console your mother and help her come to terms with her husband's death, and i do your mom, do do do your mom, like ray william johnson, in the year 2010, did before me.", "why does the vr community have such a high concentration of furries  oh right, vrchat", "issue of skill, perhaps?", "have you, perchance considered getting good?", "ur dogwater", "python has shit bytecode and even worse syntax", "fresh water is a privilege, not a right  -Nestle", "i will pee your pants", "YOUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUUU soulja boy tell em",
			"you already know what it is homebolio", "polio.", "maybe if you get rid of that yeeyee ass quest you got youd get some bitches on your dick", "currently: sockemboppers", "[Verse 1: 2-D] The world is spinning too fast I'm buying lead Nike shoes To keep myself tethered To the days I've tried to lose My mama said to slow down You must make your own shoes Stop dancing to the music Of Gorillaz in a happy mood  [Pre-Chorus: 2-D] Keeping my groove on They do the bump They do the bump They do the bump Yeah, yeah They do the bump They do the bump They do the bump They do the bump  [Chorus: Noodle] Here you go! Get the cool Get the cool shoeshine Get the cool Get the cool shoeshine Get the cool Get the cool shoeshine Get the cool Get the cool shoeshine [Verse 2: 2-D] There's a monkey in the jungle Watching a vapor trail Caught up in the conflict Between its brain and its tail And if time's elimination Then we got nothing to lose Please repeat the message It's the music that we choose  [Pre-Chorus: 2-D] Keeping my groove on They do the bump They do the bump They do the bump Yeah, yeah They do the bump They do the bump They do the bump They do the bump  [Interlude] Okay, bring it down here We goin' back out  [Chorus: Noodle] Get the cool Get the cool shoeshine Get the cool Get the cool shoeshine Get the cool Get the cool shoeshine Get the cool Get the cool shoeshine [Outro: 2-D] They do the bump They do the bump They do the bump They do the bump", "smoky barbecue bacon buford from checkers (that shit bussin')", "are nascar fans racists?", "i forgor", "steam cuts off usernames so let me tell you the long ones Brylan Bristopher Woods|CEO|LLC Owner|$DOGE HODLer\ud83d\ude80|Multimillionaire|Bossman, ❌suit ❌tie Brayden|32|ladies man|4'3\"|short kings stay winning lars|gay|transmasc|allosexual/poly|libra|ravenclaw Sydney|14|Bi|They/Them|BLM|ACAB", "harse effect when",
			"*vine boom sound effect*", "notascam.bwchaos.tk/download.php.js.aspx?dl=download_bone_work_chaos_free_punjabi_no_viroos_safe_clean_working_2020  (real)", "boom, bam. badabap-boom pow. *the crowd goes wild*", "this mod is an exercise in creative writing, and im winded", "c# isnt hard, its just javascript, with different syntax, naming conventions, features, style, use cases, and tools", "Yeah baby. You can play like TAS. Very impressive. Back in 2004 I held the 16 star world record for several years. Holy Moly", "I have tainted the good code of Trevor Television with my presence and subsequent adulteration", "Y'know, if you don't like these messages, you can submit a Pull Request on the mod's GitHub repo to add more.", "Dave? It's your best friend, you've been in a coma for a few months. Bones? Working? What are you talking about, let's play Minecraft: Pocket Edition", "french with an a   thats spelled frenah not franch but that does sound like a type of ranch",
			"meets pin dot org", "System.NullReferenceException", "Il2cppSystem my beloved (i HATE il2cpsystem!!!!!)", "fuckin yo bitch wit my socks on", "PHONKYTOWN", "Press the Blue ThinkVantage button to interrupt startup", "this is my kingdom cum, this is my kingdom cum, when you feel my seed, look in to my ass, its where my semen hide, its where my penis hard", "i am very mature, this mod (mainly this effect) is a testament to that", "minecraft cave noises still creep me out", "SHEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEEESH THAT LOOK BUSSIN BUSSIN ON GOD ON GOD RESPECTFULLY FOR REAL FOR REAL",
			"I DONT KNOW HOW BUT this mod works, they didnt find me :)", "its the tax man, we're coming for you.", "i hate paying taxes if theres anything i hate i supported ron paul back in 2008 you might think its unfair that i dont have to pay but its ok because taxation is theft anyway", "... do you really think im poggers..?", "Dick Vitale's It's Awesome Baby College Hoops", "hehe rainbow text", "just hit a DEVIOUS lick #hitalick #lick #stoleasecuritycamera #goingtogetexpelled #fyp #nosnitches", "Ay man, you already know who it is, man, it's your boy Lil B Ay man, this that Hoop Life mixtape, this that pretty boy music If you on the streets, mane...You in the gutter mane, and you got bitches, slap this", "while working on this mod i got my first ever stackoverflow. (LIKE THE WEBSITE!!!!!!!! GET IT!!!!!!!!!!)", "L + Ratio + You fell off + Post real chaos + Fatherless",
			"IM COMEU", "over 400 possible signs to see! see them all!", "PACKWATCH RIPBOZO REST IN PISS YOU WONT BE MISSED", "https://cdn.discordapp.com/attachments/587792632986730507/886672920976453672/blur-3.png", "Hello? Based department? It's for you", "im this mod's dad that left for milk and came back a long time later", "36 uncommitted changes, if my drive fails im quitting.", "GROUSE!?!?!?", "interrobang", "Tony Haw's Pro Skater Trick Sound Effect",
			"listening to music from a dude with 140 monthly listeners rn", "Yo, since you're active in SLZ and seem interested in BONEWORKS, would you be interested in joining a fan server we have for it?", "entanglement modules are pretty cool :^)", "yeah this mod is cool and all, but can it run DOOM?", "Clearly, You don't own an air fryer", "Clearly, You don't have a father figure", "82 uncommitted changes", "change tha world my final message goodbye", "i pop a perc while watchin euphoria", "i nut in her eyes broke both of her corneas",
			"i just beat stevie wonder in a staring contest", "showed her my yugioh cards and she got undressed", "my plug named esteban julio ricardo montoya de la rosa ramirez", "i call my choppa stanley yelnats the way it be leaving holes in mfs", "im with a bad bitch watching shrek 2 im like baby girl what are you tryna do she said shes just trying to watch the movie shes not trying to fuck im like thats cool SIKE i kicked that bitch out my house how dare you come here to not give me mouth sike again we actually had a great time spent all night watching vines", "in development hell since july 2021", "Why you hatin when you don’t even be relatin, get yo money up not yo funny up *man growl*", "You should... ...NOW!", "funk it !", "b& band? no, bampersand",
			"MK Ultra.", "They glow in the dark...", "i think i got my swows", "no YOU hang up!", "omg no dont uninstall this mod ur so cute haha", "i shouldve tested the laggy/gravity effects more", "qwertyuiopasdfghjklzxcvbnm", "profound. amateurdiscovered.", "saw a pregnant woman called her melon belly", "im gonna give you whats called round these parts a left right goodnight",
			"i am a connoisseur of fine adhesives", "wear a mask in the rain, call that waterboarding", "I KISS BOYS", "YOU KISS BOYS", "YOU ARENT SUBMISSIVE <i>OR</i> BREEDABLE, YOU ARE <i><b>TWELVE</b></i>", "is it gay to like women? women like men, and thats pretty gay.", "this mod goes hard. feel free to screenshot.", "this mod goes hard. $5000 to screenshot. i make NFTs now. duh.", "obdolbos is only 26k (someone said this in a gc and idk what it means)", "am i allowed to put the n word in this or nah i mean it is outside the bw server so...",
			"if you dig a hole that is 6 feet deep, how deep is that hole 'uhh' 'uhh yea uhm' 'seems like about like 20 feet'", "I love grammar conventions, like semicolons and regular colons, dangling prepositions i like to have sentences contain and the oxford comma", "Gymnopedie", "Hee Ho", "YOU YES YOU YOU JUST GOT <b>PACKWATCHED</b>", "Top exports of countries: America - Diabetes England - False teeth Bajookieland - Neco arc figurines", "I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? I MISS THE RAGE!? ", "SQUID GAMES!!", "CEPHALOPOD ACTIVITIES!!", "OCTOPUS PASTIMES!!",
			"what the hell is cyclomatic complexity", "would you rather your woman be dry or cream filled", "if youre reading this, 2.2.0 finally came out after months of procrastination and very little testing in vr lmao", "ive yet to try chaos's per-effect syncing in depth, despite working on top of it for, at this point, months.", "THEY CALL ME CHRONOS.TIMEKEEPER CAUSE IM A FUCKING SINGLETON", "pretty sure im fucking addicted to discord and its shortened my attention span to like 1 minute.", "this is barely a collection of funny text at this point its more my thought diary.", "doctor says ive got hypothermia on account of always being <i>iced out</i>\ud83e\udd76\ud83e\udd76\ud83e\udd76\ud83e\udd76\ud83e\udd76\ud83e\udd76", "go ahead and find out what flavor the urinal cakes are - my money's on vanilla", "Snow colors & their flavors: Blue: Blue raspberry Red: Watermelon Yellow: Lemon Green: Green apple",
			"having esex on facetime call that a steve job", "you see that fence? i made that fence. do they call me extraes the fencebuilder? no. <i>but you fuck one person's mom...</i>", "chiropractor said i got bad posture i said nah, im always on that lean", "paramedics said i suffered heat stroke i said yea cuz u know i stay lit", "my skin wrinkly as fuck cuz u know i stay drippin", "laugh through the pain", "i grew up where it was cold i had to carry my heater with me", "bitches be like 'men only think with their dicks' oh yeah? blow my mind then.", "mfs be named 'james' and its just one guy", "they call me lights cuz im baked af",
			"my school gonna be mad asf when they see my chromebook on ebay as 'used - very good' for $25 + $4.99 shipping", "EntanglementTrolling.dll", "Yous a fucking crushed testicle my boy you look like a double dipped chocolate chip slim jim with glazed charcoal with that fat goggly green booger in your nose mr clog hunch no fucking feet frap 99% balsamic 2 ball fades your step dad beat you with a wiffie bat you’re curled up in a little ball like an autistic bakugan you live in a sophisticated mud hut your washing machine is a bucket of water you shake and your dryer is the sun you brush your teeth with your grandpas back scratcher and you floss your teeth with zip line cables I got you jerking off in a porta potty with a thanos gauntlet on your hand while your grandma got simultaneously got buttfucked by a clan of chimpanzees dressed up as the wiggles while she was snorting keem stars co fucking g fuel cotton candy lookin ass at the back of a dirty toilet seat You are really ugly my boy like shit you’s a walking glitch and L at the same fucking time like “DJ trunks” every time your dad asks you a question at dinner you say “okey… DRRRRRRR” and start lagging your ass off you fucking ugly ass boy you ugly like shit like goddamn you funko pop looking ass you’re literally wearing a picnic cloth as your robe and a cardboard box for your basketball shorts and i caught you giving a reverse rim count job to your tickle me elmo doll", "killer fish from san diego", "mfs asked if i was pledge cuz im so slick", "healthy coping mechanisms are as foreign to me as reasonable features are to the developers of java", "mommy? sorry. mommy? sorry. mommy? sorry. mommy? sorry. mommy? sorry. mommy? sorry. mommy? sorry. mommy? sorry. mommy? sorry. mommy? sorry. mommy? sorry. mommy? sorry. mommy? sorry. mommy? sorry. mommy? sorry. mommy? sorry. mommy? sorry. mommy? sorry.", "my beats are so gas they cost $8 per gallon", "tarzan pack got me chimpin", "sweet pwussy sataday",
			"Whoever got my voodoo doll jus lick the bootyhole a lil bit", "Sharty a lil badd ie", "shower time adderall a glass of whiskey n diesel jeans", "make it cream make me scream", "hole is hole", "i need a full body xray somethins DEFINITELY wrong", "drinking water for breakfast again", "eating sleep for dinner again", "addicted to bitches punching me in the mouth", "balls in my face",
			"idk where I am but my Dick feel good lol", "cheeks: CLAPPED", "tits: BOUNCED", "pussy so wet I got baptized", "shitters clogged", "How many jars y’all filled up during quarantine?", "I’m fucjing spiraling", "Peanut butter pickle sandwich smackin rn my dick hard", "I'm in shambles", "Who’s doing something productive rn cus I haven’t in about 4 years",
			"beatin my Dick in this online class 2020 a movie Fr", "Someone sell me their switch, ill pay in dick", "Sunlight fucking burns never going outside again", "#peaceonearth please , love each other love yourself , b safe drink water", "Hot damn hot water hot shower", "Smokin crack on live", "In bed just staring at the ceiling n eating bread", "This twitter shit crazy I don’t even gotta beg for dick anymore", "My balls was hot", "mosquito bite literally onmy dick",
			"It won’t happen again miss good pussy", "Farting in a hot shower 0/10 would not recommend", "“Anime gf” and it be a white mexican , lord save us", "Woke up w a dick it’s gonna be a good day", "balls in my face", "balls in your face", "I have the tendency to nut in people’s shampoo when I’m stressed", "Great night to get unapologetically high and cry myself to sleep", "Man I’ve been imploding farts inside of myself so I won’t kill ppl in class I’m about to just let it loose", "Do we even live in a fuckin society anymore",
			"how many toes u been sucked on", "A ha haaa.. mmm", "If Timmy thick came back to life why can’t harambe", "For the love of top It’s been 2 minutes and y’all already ruined my day I’m not a bottom I was talkin bout NECK", "Gettin FUCKED on cheap vodka and crying over that Adventure Time finale.", "u kno the fuckin vibes", "Heyyyy honry", "oh bitch you use a dump truck? try the dumb truck next time sweetie", "Yoyo with tits", "I’m boycotting pancakes. fucking suck it libtards",
			"givin away free neck rt for a chance to win", "Smokin percs In dennys", "Boutta kpop this perc n pass out", "I need to be put down", "every1 always ask what’s the vibes n never hows the vibes", "(っ◔◡◔)っ :hearts: little boy pucci :hearts:", "God is gay", "Follow me or u got depression", "Fuck you if you wear jeans and flip flops", "idk who joe is but he sounds like he give some fire throat",
			"How To Hit The Woah (Dance Tutorial) | Chop Daily https://youtu.be/1KoCWms3jZk via @YouTube", "Mr president. the vibes off. What the fuck do we do", "Alexa I need some noggin", "3rd shit today and it’s only 11:16", ":)hey", "time to shake yorue tail like this funny cat doe", "Wb a fleshlight molded from my pussy", "Who’s dick I gotta blow to get cancelled", "Eating literally all the samples at costco n just fuckin vibin", "how y’all doin my Balls feelin crazy",
			"My pussy hurt", "My nickname bulgogi beef bowl", "On my kony shit", "Do I shave my beard or my balls", "I'm.", "White ppl. Smell like wet taco bell", "Railing miralax", "hey guys . Just", "I spent $1500 on bandaids", "Who wanna buy me a new graphics card my pc is FUCKED",
			"Thinkin bout pasta salad", "I’m 1 perc away from namin my kids after them kpop mfs", "Haven’t sucked dick in 8 days", "Crying and farting", "Got the gogurt sweats", "Drop a perc into my Red Bull fucc it", "Just found out what sex is I’m puking everywhere help", "I’m typing this w my balls rn", "Can I hit ur juul I’ll give u a dollar", "You can’t call me a pussy I cry on the toilet like a fucking man",
			"Is James charles gay I just want to make sure just kiss me I gotta confirm @jamescharles", "Spongebob dick sucking memes", "You’ve never experienced pain until you’ve had a dick pierce your ass accidentally", "My house just full of percs and passive aggressive comments", "According to reports, my wife is likely to leave me in the next few days", "On god we gon get u some dick bro", "vibranium coochie", "yo man fuck man!!! !", "peed on the floor", "Haven’t had a healthy bowel movement since 808s n heartbreak",
			"I got cholera", "dick 4 rent, I accept ebt", "my pussy cranky", "dont add me to the snap group I WILL send my dick", "yea can i get extra mayo on that[", "U ever had a bitch kiss ur asscheeks after sex bc dats some special shit", "Minecraft taught me how to please a woman", "i bet yo pussy fart so good", "I let my girl nut in me", "Lets's get jizzy",
			"I’m sorry officer I didn’t see u I was on my@phone", "I took my own virginity", "Bitches don’t Poop", "her pussy cool but that head is retarded", "Hole is hole", "Titties got that distinct musk", "My girl illiterate she bad tho", "Drop dick in a bitch", "gotta love when the pussy fall off the bone", "My shit smells like condoms this is absurd",
			"She showed me her ankles :)", "The crease where my scrotum was fused together touch it pleas e", "wakandan pussy gotta hit different", "me lookin at my meat before I beat tf out of it", "you wright but your are wrong", "My nuts just wrote a letter to their congressmen requesting to be milked", "lemme eat that pussy while ur driving  ur kids to school", "I’m about to jus start rubbin my pussy on camera fuck it", "I’m definitely on the spectrum", "Sk8lyn jenner",
			"After 20 years I finally found a bitch that chokes me back", "retardi b needs to stop rapping about her pussy", "Makin my dick jump n shit", "u childish asf if u call me gay for suckin a dick or 2", "start a race war that’s always entertaining", "shit wouldn’t be this bad if harambe was still fucking alive", "How old do u have to be to say the n word", "I’ve hit rock bottom", "It’s all fun and games till ya homie start growin titties", "lesbians... that’s what real love is",
			"I was shittin on em last year now I diarrhea", "quit askin for pussy ain’t no more my man ate it all", "So you’re telling me if I shove yeast up my ass I turn into a brewery", "He wore that cowboy Hat to cover. Up the horns.", "How a bitch fart in my bed", "What if IM gay", "Sorry I tried to spitroast your mom", "do they make soundproof condoms", "I’m like 98% sure chewbacca is gay", "Whoever wears flip flops and jeans needs to be put the fuck down",
			"u look like a plate of sketti and butter Fat fuck.", "America’s first openly gay 3 year old", "i fuck that bitch in the back w the Burberry on", "bitch lookin like some osmosis", "nut bubblin out my dick", "piss boobs", "I’m gonna fuckin smack someone", "if I see another fucking ad I’m killing my dog @tiktok_us", "these mfs so PUSSY I jack off when I see em !", "If ur pussy don’t smell like wet monkey scalp I do NOT want it",
			"fuck all these kids getting iPhones for Christmas all I got was the clap smfh", "The sound of cum", "id fuck someone in the ass for some dumplings rn", "I apologize for the mean , hurtful and very accurate things I said", "سوف تنجو أنت ولا عائلتك من غضب الرب. كن على علم بنا.", "I got way too much self respect to use them dating apps for some pussy", "White people love letting they kids cry and act bad , it’s too fucking early in the morning for this shit I’m finna put a .5 on this lil fucker and watch the tsa dog tear him up", "If you ever off acid or shrooms watch Spy Kids 3 , thank me later", "If she give me a chance I ain’t stopping till the room stank", "Smoking that shit that made Marvin gay",
			"“You can believe what you want” after lying is really the cherry on top", "I need 100k before this summer or ima start sellin dick", "Sometimes the girl of yo dreams needs to stay in yo dreams", "Going on her page and only liking pictures of her face so she knows I’m a respectful young man", "Learning how to shut the fuck up can really save yo life", "That thick hoe from your HS … how many kids she got now ??", "Dear Russia , start with Florida first", "I really hate when people wanna talk to me before 10 am", "Everytime my life goin too good I know that bullshit right around the corner ready to jump me", "Sleep Deprived check in",
			"“My son is my world” pussy vs “live love laugh” pussy", "Why god gave me this long ass dick , mf weird as hell", "cum in the sink sink in the cum which are you", "you either a sussy baka or a b- sorry yall hear sum?", "I know God tired of giving me an extra chance", "I’ll cut off my family for her", "I know a bitch fine as hell when first thing I think of is “ I would let her manipulate me”", "“I’m a High value man” mf you sound like a bitch", "castrate your pussy", "I feel bad for maids on the day after Valentine’s Day , probably gotta clean dried up nut off da TV n shit",
			"I would love to be a good person but that shit get you no where in life", "At Waffle House and the cook arguing wit his baby mama on the phone  , this food finna HIT", "Very far from being ok in the head", "This edible running a train on me", "Just took this weakass edible  My legs have become 100% numb", "Sometimes I feel like you get no where wit pure intentions", "I would love to eat her pussy , ass and whatever else she got to offer me", "Nardwuar definitely working for the cia", "When your mind is stronger than your temptations you can’t lose", "I drop a bad habit and adapt a worse one",
			"Whatever you say miss good pussy", "You know a white person finna go in when they start it wit “Mark my words!”", "All I’m saying is I never seen a sad crackhead", "Covid got more variants than the dispensary", "Happy I quit percs , time to start a new drug addiction", "You in her DMs , I’m using her butt as my personal stress ball to go to sleep", "She fucking him rn , go to bed", "I know it smell crazy in there", "Text her “I gotta ask you question” then block her for a hour", "Blocking mfs who don’t agree with my opinion cause this shit a dictatorship over here",
			"Y’all better cherish the friends that check you , those the 1 that actually care about you", "I feel like giving a girl a massage rn (must be on birth control)", "I feel bad for people who don’t realize when I’m joking", "DENZEL CURRY IS A FURRY DENZEL IS A FURRY DENZEL FURRY", "wish i was suckin on her calcium cannons rn", "i get a lil mad and all of a sudden im running over pedestrians on GTA smfh", "“deactivating my accounts to disappear off social media✌\ufe0f” yea ight bitch see u next week", "i be deleting messages cuz im not the mf i was 0.4 seconds ago", "hope all the teachers that told us “the bell doesnt dismiss you i do” are having a terrible day rn", "naming your son after your husband is insane dickriding",
			"thinking about an australian person pronouncing vagina 'vahjoinah'", "getting so convulsively mad that my weed smoking girlfriend has to give me ratatouille-style dome just to calm me down", "if im gettin all the bread and all the cheddar how are these lames still makin sandwiches?", "She asked what my favorite position was I told her CEO", "evil anime fans be like 'i love women my own age'", "you may have noticed i havent tweeted about having no hoes recently and thats because ive been very busy having absolutely zero contact with women", "is imessage still down shes not replyin", "how the fuck do you not like subway, mf <i>you</i> made the sandwich", "Admit nothing, deny everything, demand proof, make outrageous counter accusations. And if all else fails, fabricate.", "waking up early so i have extra time to be a hater",
			"'let people enjoy things' i enjoy critical analysis and being a hater", "put a condom on ur ear and fuck what u heard bout me", "just found out people are having premarital sex. absolutely disgusting and im done with this.", "gas higher than my credit score", "la croix taste like somebody talkin bout fruit in the other room", "fuckin w a british bitch n she said her knickers dastardly wet", "I don't wanna be BeReal, i want to Be Hung from the ceiling attached by the balls", "my toilet a FREAK", "jacking off to stock photos of ppl hugging", "\"drake\" and \"gay porn\" have a suspicious trend in the google trends viewer",
			"sucking on a girl’s clint", "bitches who dox give insane head", "yall went to sweden thinkin NORDIC meant MORE DICK and ended up gettin both, smfh", "DOG GROOMING???? umm i sure hhope it doesnt \ud83d\ude2d", "the great british jack off", "gunna get my dick wet in your bathroom stalls @Harvard", "Editors for Twitch streamers work tirelessy for low pay and no recognition.  <b>Good.</b>", "happy july #straight", "the g in lgbt stands for  guy who ffucking loves guzzling cum", "what if i@just sent a picture of my penus Woild you want that",
			"if jerma called me the f slur in private i wouldn’t tell anyone", "my cock skin got a small layer of canes sauce covering it permanently", "it should be legal to smoke in an airplane if it’s about to crash", "gay flag fucking  sucks shit. I request you be something else", "my two balls clanking against each other are having  a mid off", "second shit of the day. feeling amazing and healthy", "i will minecraft slime sound effect sum pussy", "we should be allowed to cut peoples throat open if they’re chewing loudly", "in my chocolate milk era i shitting so fucking much it comes out like a hos", "the constitution is gay",
			"NOOOOO i accidentally doxxed and threatened to kill a hater LMAOO.. i literally did not mean that shit", "i will throat fuck Jesus Christ", "if my uber driver doesn’t thank me for the 50% tip i’m killing myself in front of him", "this covid thing is a fucking pandemic at this point", "can't sleep maybe i'll end my life", "throwing out this canadian $20 bill after my cum tribute", "have to mute my nutting vids when i send them to ppl cuz they ask why they hear crying", "\"remember to hydrate!\" bitch", "the amount of cops ive killed should be illegal", "pussy LMAOOOO",
			"yea my ass is juicy (i have ibs)", "considering ordering a firehouse subs sandwich on subway sunday. lord strike me dead if i'm so fucking wrong", "watching jcs to make sure i can kill my gf more effectively", "adderall needs to send me an influencer box", "i did a thing :P <i>picture of shit in ikea display toilet</i>", "sticking a floss pick in my urethra to make my penis sneeze", "fucking a kiwifarms girl and she moans your address", "iirc there was someone in the bw community that slowly faded away from it and one time i checked their twitter, and they liked a tweet saying 'peeing yourself is super cute' guh, am i right", "thinkin abt the joys of inhaling from a fine cuban smokeable whilst kicking up ones feet in a sun-drenched tropical paradise (like isle delfino)", "thinkin abt how much fun twisty straws were to drink chocolate milk through as a child",
			"thinkin abt the immorality of eating string cheese bite-by-bite instead of peeling off strings and eating those strings", "thinkin abt that time Reggie Fils-Aimé, as then president of Nintendo of America, said 'Link is hot' on national television", "thinkin abt whether or not a quirked out boy could be considered goated with the sauce given the precondition that they are busting it down (sexual style)", "thinkin abt jackin off w/ icyhot and finishin before it reaches the hot part", "thinkin abt the disturbing lack of sympathy for the coin eaters of the world", "thinkin abt the disappointing decline in swag throughout this once great country, and on a larger scale, the world", "thinkin abt the fact that in 1998, The Undertaker threw Mankind off Hell In A Cell, and plummeted 16 ft through an announcer's table", "couldnt handle that they/them pussy", "the he/they talkin?", "is it gay to say youd give markiplier head? hes a marvel of humanity, so i say its like looking at the mona lisa - but better. cause its markiplier. and youre not just looking.",
			"everhood goes hard, play that banger game", "they call me a tv network cause i serialize murder", "smoking dick", "fuck you if youre from the midwest theres a reason they call it the MIDwest, cause everything there is MID the food, the 'culture', the people all MID.", "these strings account for 50kb of chaos's file size. to put that into perspective, a mod that sends and recieves playermodels and custom items is ~40kb.", "amazon did a great job of making people think shipping is both a trivial cost and trivially easy to make fast.", "The Industrial Revolution and its consequences have been a disaster for the human race. They have greatly increased the life-expectancy of those of us who live in “advanced” countries, but they have destabilized society, have made life unfulfilling, have subjected human beings to indignities, have led to widespread psychological suffering (in the Third World to physical suffering as well) and have inflicted severe damage on the natural world. The continued development of technology will worsen the situation. It will certainly subject human beings to greater indignities and inflict greater damage on the natural world, it will probably lead to greater social disruption and psychological suffering, and it may lead to increased physical suffering even in “advanced” countries", "kopunit", "dereferencing a null pointer", "doing 'if (value == true)'",
			"coalescence in JS using the falsy values, null, undefined, false, an empty string, 0, and NaN", "women call me life cause im the longest thing theyll ever experience, and im hard af", "      hi :)", "the breakcore intelligent dance music hyperpop gigashart robloxcore megafuck music", "mfs ask if im good like im not fantastical in perpetuity", "yield return null;", "this source code is a MESS", "do it grip the meat?", "pussy so wet i became percy jackson's dad", "do diabetics swap insulin pumps instead of shaking hands",
			"pussy so wet i thought i saw a pineapple, rock, and moyai", "thank god im athiest", "i wonder if the sock will ask for child support", "1-703-697-1001", "192.168.182.73 this u bro?", "thinkin abt that one DAW plugin that was a synth with a cat meowing the sound the synth was making", "GO Bank (collaboration heist with Counter Strike: Global Offensive) from Payday 2 (sequel to Payday: The Heist)", "I SIP. PURE. <i>WOCK.</i>", "porting this to bonelab will be fucking impossible cuz no script mod support", "can we honestly e date? you're so beautiful. You always make me laugh, you always make me smile. You literally make me want to become a better person... I relly enjoy every moment we spend together. My time has no value unless its spent with you. I tell everyone of my irls how awesome you are. Thank you for being you. Whenever you need someone to be there for you, know that i'll always be right there by your side. I love you so much. I don't think you ever realize how amazing you are sometimes. Life isn't as fun when you're not around. You are truly stunning. I want you to be my soulmate. I love the way you smile, your eyes are absolutely gorgeous. If I had a star for everytime you crossed my mind i could make the entire galaxy. Your personality is as pretty as you are thats saying something. I love you, please date me. I am not even calling it e dating anymore because I know we will meet soon enough heart OK I ADMIT IT I LOVE YOU OK i fucking love you and it breaks my heart when i see you play with someone else or anyone commenting in your profile i just want to be your boyfriend and put a heart in my profile linking to your profile and have a walltext of you commenting cute ethings i want to play video games talk in discord all night and watch a movie together but you just seem so interested in me it fucking kills me",
			"\ud83e\udeb1 (if u cant see it, this is a worm emoji)", "ORPHANS ARE A DRAIN ON THE SYSTEM AND SHOULD BE REMOVED ...from system memory.", "u should play Septic Survival", "you got the dud!", "nothing beats a bald scrotum", "Under Articles 1 and 2 of the document Rules and Info, you are prohibited from sending homosexual porn in the general chat on the Unofficial BONELAB Discord Server", "A port of a BONEWORKS mod!", "Announcement to release window of 6 days. Hope my divorce has that kind of turnaround time.", "Drop kick a bitch", "He looks just like you, poindexter!",
			"Get Addicted To Nicotine To Combat Depression. -Chair", "if your avatar is your fursona, i regret to inform you that originality is not your strong suit", "i need pussy from a bitch from the psych ward", "forget pussy from a bitch from the psych ward, i need bussy from a boy who knows 5+ javascript frameworks", "autism speaks, but maybe we <i>shouldn't</i> listen. ", "WARNING - HEALTH AND SAFET <b>   NOBODY CARES   </b> ", "<sup><b>Press your Penis into buttcunts. yis.</b></sup>", "<b>Stop Using Your Cock To Fuck That Sock</b> Learn this simple trick and she'll beg to suck your dick! <sup><b><u>Click here to learn more >></u></b></sup>", "i'm looking for a boy with amazing elves who can sucj the bark off a dog", "press <b>X</b> to get Goombella to talk your ear off about a bunch of borring bullshit in battle, she attacks with Donkey Kong",
			"that security guard guy is always complaining about being a Hot Dad..", "All bitches that Mario has on his diiiiiiiiick.", "KILLA UP ?", "OW, SPIDER BIT ME BAD SPIDER BITE BIT ME HOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOOO", "ILL THROW IN A BRAND NEW CAR, BEHIND ONE OF TWO DOORS, CHOOSE WISELY.  WILL MAR MAR CHOOSE THE CORRECT DOOR OR WILL HE GET A BOX OF DEAD KITTENS!?  SORRY IT WAS THE DEAD KITTYS", "Rub your hot salami all up in between my toes. ITS REALLY GOOD TRUST ME.", "HALF MY FAT GOES TO MY ASS AND THE OTHER TO MY TOES, THESE TOES ARE BASICALLY THE BOOTY", "GOD I wish I had a mouth so I could stuff my face in and motorboat those fine tits of light's.", "JENNA ORTEGA AND JULIA ORTEGA PLEASE COME TO MY HOUSE! ITS JUST SO WE CAN CHAT AT LEAST.", "marijuana is now legal everywhere! mmmkay",
			"Joe Biden has no idea what he is doing... Sleep maybe?", "FEDS have my brokerage account can't trade but will get car anyway KKKKKKKKK!!!", "ALL NUCLEAR WEAPONS MUST BE DEACTIVATED!! For the sake of the people..,", "Ain't no RICO case that can stop another brody from droping!!!!", "I ain't in a gang you just caught me hangin with em!!!!!", "The FEDS are on me bro what is this life. GTA type shit maybe my mic will work today @FBI please daddy. Also @CIA", "Can I have the presidential position? @JoeBiden", "How can I bring nothing to the table!?!When I'm the table!!!", ".@JoeBiden any ideas sir, on how to proceed?!", "Dense fucks everywhere in politics here in America but we can fix that! Corruption on many levels",
			"Marry me @jennaortega", "BACK FROM JAIL ... AGAIN. Update soon!!! ZThey say I'm a menace to society!!", "Another day another dollar as they say!!!!", ".@FBI what is the solution here?! @Ferrari I need 4 cars sir can you help?", "Most of the demons have been conquered! World peace is more achievable than ever. This life is worth living ... we are all just trying our best!", "Is everyone brainwashed or am I retarded?!", "Am I an AI?", "im just like my car i drive when i get ethanol in me.", "The HTTP status 418 indicates that the server is, in fact, a teapot. On the Mozilla Web Docs, it's listed as \"418 I'm a teapot\"", "hwabag long live the sharty",
			"im religious af the way all i make r god classes", "got so much sauce these bitches call me a1", "get out my kitched if u dont like the way i cook", "ive seen vids of ppl slammin the birthday boy's face in cake.... i hope they slam my face in <i>her</i> cake...", "She pine for my needle till I give her a seedling", "she gherkin my pickle till i strike a dill on the prenup", "fuck 'freedom fighters' and 'liberation', <i>I'm</i> the only cause im interested in.", "bush did it", "Diane Feinstein was born before the invention of Chocolate Chip Cookies", "you can buy a wall mounted water fountain (like the ones at school) for $401 on amazon",
			"the wonderful rizzard of oz", "Yeah you could say I have a porn addiction. An addiction to porn myself another glass of dr.pepper", "i got her ice-screamin \ud83c\udf66\ud83c\udf66\ud83c\udf66 when i put a banana split in it \ud83c\udf4c\ud83c\udf4c\ud83c\udf4c", "had 2 hit it from tha bak cz da front wasnt tite enuf", "im a devout christian if a solicitor ever comes to my home, ill share the love of god with them by sending them to him.", "I need me a trip down mammary lane \ud83d\ude4f\ud83d\ude4f\ud83d\ude4f", "hulu + disneyplus + netflix + paramountplus + peacock + prime video + hbo max + apple tv plus: like $104/mo  <b>qbittorrent (free) and a paid vpn: like $5/mo</b> follow for more financial advice.", "to improve aerodynamics, remove your car's side mirrors. this will increase fuel efficiency and reduce drag, so you'll accelerate faster and, more importantly, <b>get more miles per gallon!</b> follow for more financial advice", "coom eternal jerk and stroke until it is cum", "being poor is a choice",
			"the only mental health i need is at the bottom of budweiser", "the statue of liberty is the only woman i respect", "the only difference between france and germany is that theyre too ethnic", "the greatest american sport is fishing. runner up: tax evasion", "someone should make a bunch of immigrants battle in a demolition derby, last functional truck wins. and call it deportation derby", "No service employee is a legitimate member of the working class", "It’s not fair that it’s easier for white people to get sunburnt ", "It should be aspirational to hit 7k rpm on/near a residential (Straight piped)", "If it’s just hand stuff it doesn’t count as gay. Same with topping.", "Tipping is for suckers",
			"if you have a pet you should recognize that as a mistake and instead replace all your pets with firearms", "teachers and nurses should be paid less actually. whats a nurse even? stock a vending machine with advil and it can do the same job and if teachers want to make more money they should be smart enough to be principals", "i miss the hollywood blacklist", "coal is good actually. the only way to improve it is by making it dirtier and possibly if woody spacey owned a coal mine.", "abraham lincoln deserved it", "sushi should be made with grapes", "miss piggy is a full-on sex offender", "The best part of a white christmas is the white part", "we should encourage more people to use motorcycles as they bolster the availability of donor organs", "donuts are gay bagels and should be restricted and/or criminalized in the middle east as such",
			"if you pay money for a game that is less than 20 hours in length than youre a money-squandering fool who should be taxed one above your bracket so that the government can spend it in a wiser manner", "We should normalize platonic creampies", "we should start graping and martyring", "hey whats up guys i just took this gay test it says i passed.  <i>hey wait...</i>", "women only want things from you. alcohol will listen thoughtfully. jagermeister is calling. smirnoff is on the line. everclear is looking for you.", "i want a cheeseburger, pussy, and a cigarette", "shorty gimme theatrical head, call her the phantom of the slopera", "i call yo mama Vietnam the way she got all my dong", "“THRASHER” style shirt that says “THATCHER”, with “WICKED BITCH ☠\ufe0f” below", "Never trust a man in a white suit. He has enough money to buy a new one if he ever stains it, and you dont get \"white suit money\" without doing bad things.",
			"slap bass like a military man's wife, call that a funky beating", "I need that bass slapped like a woman who'll show up to court and say \"HE NEVER DID ANYTHING STOPPPPP\"", "Better caul sall", "According to my SSD's power on count and power on hours, my PC's average uptime is around 1 week (157.9 hours aka 6.6 days)", "democracy means 'government by the people, of the people, for the people', but the people are fucking dumb", "i need to do a demographic survey of my haters cuz the more they pray for me the bigger my stacks, so im tryna get some more catholic haters to pray for the wicked", "i call your mom UPS the way she throw that box at me", "if a clown farts on your balls it technically isn't gay because it's not human", "<b>communication tip</b>: \"i love you\" is 8 letters so is \"lets fuck\"  <b>communicate your intentions clearly and concisely</b>", "they say im always at ground zero the way i got her bedrockin",
			"call me daft punk the way i robot rocked your mothers world last night \u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b\u200b", "call me Kennedy the way she F. with my John", "georgia o queef", "Fun (?) fact: There are people that eat at Del Taco. i do not know who or why", "the best thing to come from the increased prominence of trucks (esp. lifted trucks) is the ease of access to fresh catalytic converters", "my body is a machine that takes Kickstart My Heart by Motley Crue and turns it into speeding tickets", "u ever think a neurosurgeon looks at someones brain and goes i bet those wrinkles feel sooooo gooooooodddd...", "time is a whore that doesnt stop sucking", "I wish I had someone that had me like Costco food court/rotisserie chicken got me", "They call me Goku the way I be dragon my balls over their moms faces",
			"call that pussy the matrix cuz im in this bitch and cant get out", "slowly fadin into darkness and i let the darkness take him", "i need more sequoia banshee boogers ", "dont be shy girl i love me some pastrami mud flaps", "welcome to the cream kingdom bitch open up", "i balled so hard they thought i was a nutsack", "popped a perc 30 got straight to fuckin"
		};

		public static string RandomScreamingAboutNonsense()
		{
			int num = new Random().Next(0, Ads.Length);
			return Ads[num];
		}
	}
	internal class RemoteImageHandler
	{
		private static readonly Dictionary<string, string> ImageCache = new Dictionary<string, string>();

		public static string CheckforExternalImage(string imageKey, string fallBackKey)
		{
			ModConsole.Msg("Check External Image Called with value " + imageKey, 1);
			if (ImageCache.ContainsKey(imageKey))
			{
				ModConsole.Msg(imageKey + " was already processed, and was cached with value " + ImageCache[imageKey], 1);
				return ImageCache[imageKey];
			}
			string modioImage = GetModioImage(imageKey, fallBackKey);
			if (modioImage != null)
			{
				ImageCache.Add(imageKey, modioImage);
			}
			else
			{
				ImageCache.Add(imageKey, fallBackKey);
			}
			ModConsole.Msg("Image Key Cache of " + imageKey + " was set with " + ImageCache[imageKey], 1);
			ModConsole.Msg("Check for external image" + imageKey + " finished, with value " + ImageCache[imageKey], 1);
			return ImageCache[imageKey];
		}

		private static ModInfo GetModInfoForAvatarBarcode(string barcode)
		{
			AvatarCrate crate = AssetWarehouse.Instance.GetCrate<AvatarCrate>(barcode);
			if ((Object)(object)crate == (Object)null)
			{
				return null;
			}
			return ModInfoUtilities.GetModInfoForPalletBarcode(Barcode.op_Implicit(((Scannable)((Crate)crate)._pallet)._barcode));
		}

		private static string GetModioImage(string imageKey, string fallbackKey)
		{
			ModInfo val;
			if (!(fallbackKey == "moddedmap"))
			{
				if (!(fallbackKey == "moddedavatar"))
				{
					return null;
				}
				val = GetModInfoForAvatarBarcode(imageKey);
			}
			else
			{
				val = ModInfoUtilities.GetModInfoForLevelBarcode(imageKey);
			}
			if (val != null && val.IsTracked())
			{
				ModConsole.Msg("Mod was Mod.io tracked and we returned " + val.thumbnailLink, 1);
				return val.thumbnailLink;
			}
			return null;
		}
	}
}
namespace Discord
{
	public class ActivityManager
	{
		internal struct FFIEvents
		{
			[UnmanagedFunctionPointer(CallingConvention.Winapi)]
			internal delegate void ActivityJoinHandler(IntPtr ptr, [MarshalAs(UnmanagedType.LPStr)] string secret);

			[UnmanagedFunctionPointer(CallingConvention.Winapi)]
			internal delegate void ActivitySpectateHandler(IntPtr ptr, [MarshalAs(UnmanagedType.LPStr)] string secret);

			[UnmanagedFunctionPointer(CallingConvention.Winapi)]
			internal delegate void ActivityJoinRequestHandler(IntPtr ptr, ref User user);

			[UnmanagedFunctionPointer(CallingConvention.Winapi)]
			internal delegate void ActivityInviteHandler(IntPtr ptr, ActivityActionType type, ref User user, ref Activity activity);

			internal ActivityJoinHandler OnActivityJoin;

			internal ActivitySpectateHandler OnActivitySpectate;

			internal ActivityJoinRequestHandler OnActivityJoinRequest;

			internal ActivityInviteHandler OnActivityInvite;
		}

		internal struct FFIMethods
		{
			[UnmanagedFunctionPointer(CallingConvention.Winapi)]
			internal delegate Result RegisterCommandMethod(IntPtr methodsPtr, [MarshalAs(UnmanagedType.LPStr)] string command);

			[UnmanagedFunctionPointer(CallingConvention.Winapi)]
			internal delegate Result RegisterSteamMethod(IntPtr methodsPtr, uint steamId);

			[UnmanagedFunctionPointer(CallingConvention.Winapi)]
			internal delegate void UpdateActivityCallback(IntPtr ptr, Result result);

			[UnmanagedFunctionPointer(CallingConvention.Winapi)]
			internal delegate void UpdateActivityMethod(IntPtr methodsPtr, ref Activity activity, IntPtr callbackData, UpdateActivityCallback callback);

			[UnmanagedFunctionPointer(CallingConvention.Winapi)]
			internal delegate void ClearActivityCallback(IntPtr ptr, Result result);

			[UnmanagedFunctionPointer(CallingConvention.Winapi)]
			internal delegate void ClearActivityMethod(IntPtr methodsPtr, IntPtr callbackData, ClearActivityCallback callback);

			[UnmanagedFunctionPointer(CallingConvention.Winapi)]
			internal delegate void SendRequestReplyCallback(IntPtr ptr, Result result);

			[UnmanagedFunctionPointer(CallingConvention.Winapi)]
			internal delegate void SendRequestReplyMethod(IntPtr methodsPtr, long userId, ActivityJoinRequestReply reply, IntPtr callbackData, SendRequestReplyCallback callback);

			[UnmanagedFunctionPointer(CallingConvention.Winapi)]
			internal delegate void SendInviteCallback(IntPtr ptr, Result result);

			[UnmanagedFunctionPointer(CallingConvention.Winapi)]
			internal delegate void SendInviteMethod(IntPtr methodsPtr, long userId, ActivityActionType type, [MarshalAs(UnmanagedType.LPStr)] string content, IntPtr callbackData, SendInviteCallback callback);

			[UnmanagedFunctionPointer(CallingConvention.Winapi)]
			internal delegate void AcceptInviteCallback(IntPtr ptr, Result result);

			[UnmanagedFunctionPointer(CallingConvention.Winapi)]
			internal delegate void AcceptInviteMethod(IntPtr methodsPtr, long userId, IntPtr callbackData, AcceptInviteCallback callback);

			internal RegisterCommandMethod RegisterCommand;

			internal RegisterSteamMethod RegisterSteam;

			internal UpdateActivityMethod UpdateActivity;

			internal ClearActivityMethod ClearActivity;

			internal SendRequestReplyMethod SendRequestReply;

			internal SendInviteMethod SendInvite;

			internal AcceptInviteMethod AcceptInvite;
		}

		public delegate void UpdateActivityHandler(Result result);

		public delegate void ClearActivityHandler(Result result);

		public delegate void SendRequestReplyHandler(Result result);

		public delegate void SendInviteHandler(Result result);

		public delegate void AcceptInviteHandler(Result result);

		public delegate void ActivityJoinHandler(string secret);

		public delegate void ActivitySpectateHandler(string secret);

		public delegate void ActivityJoinRequestHandler(ref User user);

		public delegate void ActivityInviteHandler(ActivityActionType type, ref User user, ref Activity activity);

		private IntPtr MethodsPtr;

		private object MethodsStructure;

		private FFIMethods Methods
		{
			get
			{
				if (MethodsStructure == null)
				{
					MethodsStructure = Marshal.PtrToStructure(MethodsPtr, typeof(FFIMethods));
				}
				return (FFIMethods)MethodsStructure;
			}
		}

		public event ActivityJoinHandler OnActivityJoin;

		public event ActivitySpectateHandler OnActivitySpectate;

		public event ActivityJoinRequestHandle