Decompiled source of CrowdControl Peglin v1.0.1

BepInEx/plugins/CrowdControl/CrowdControl.dll

Decompiled 10 hours ago
using System;
using System.Collections.Generic;
using System.Diagnostics;
using System.Globalization;
using System.Linq;
using System.Net;
using System.Net.Sockets;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using System.Runtime.Versioning;
using System.Text;
using System.Threading;
using Battle;
using Battle.Attacks;
using Battle.Enemies;
using Battle.StatusEffects;
using BepInEx;
using BepInEx.Logging;
using Currency;
using HarmonyLib;
using Newtonsoft.Json;
using Relics;
using UnityEngine;

[assembly: CompilationRelaxations(8)]
[assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)]
[assembly: Debuggable(DebuggableAttribute.DebuggingModes.Default | DebuggableAttribute.DebuggingModes.DisableOptimizations | DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints | DebuggableAttribute.DebuggingModes.EnableEditAndContinue)]
[assembly: AssemblyTitle("LethalCompanyTestMod")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("LethalCompanyTestMod")]
[assembly: AssemblyCopyright("Copyright ©  2023")]
[assembly: AssemblyTrademark("")]
[assembly: ComVisible(false)]
[assembly: Guid("d4f6b961-e8ae-4e4b-950c-37644e42d4ca")]
[assembly: AssemblyFileVersion("1.0.0.0")]
[assembly: TargetFramework(".NETFramework,Version=v4.8", FrameworkDisplayName = ".NET Framework 4.8")]
[assembly: AssemblyVersion("1.0.0.0")]
namespace BepinControl;

public enum TimedType
{
	INVUL
}
public class Timed
{
	public TimedType type;

	private static int frames;

	public Timed(TimedType t)
	{
		type = t;
	}

	public void addEffect()
	{
		TimedType timedType = type;
		TimedType timedType2 = timedType;
	}

	public void removeEffect()
	{
		TimedType timedType = type;
		TimedType timedType2 = timedType;
	}

	public void tick()
	{
		frames++;
		if (type == TimedType.INVUL)
		{
			TestMod.ActionQueue.Enqueue(delegate
			{
			});
		}
	}
}
public class TimedThread
{
	public static List<TimedThread> threads = new List<TimedThread>();

	public readonly Timed effect;

	public int duration;

	public int remain;

	public int id;

	public bool paused;

	public static bool isRunning(TimedType t)
	{
		foreach (TimedThread thread in threads)
		{
			if (thread.effect.type == t)
			{
				return true;
			}
		}
		return false;
	}

	public static void tick()
	{
		foreach (TimedThread thread in threads)
		{
			if (!thread.paused)
			{
				thread.effect.tick();
			}
		}
	}

	public static void addTime(int duration)
	{
		try
		{
			lock (threads)
			{
				foreach (TimedThread thread in threads)
				{
					Interlocked.Add(ref thread.duration, duration + 5);
					if (!thread.paused)
					{
						int dur = Volatile.Read(in thread.remain);
						new TimedResponse(thread.id, dur, CrowdResponse.Status.STATUS_PAUSE).Send(ControlClient.Socket);
						thread.paused = true;
					}
				}
			}
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)ex.ToString());
		}
	}

	public static void tickTime(int duration)
	{
		try
		{
			lock (threads)
			{
				foreach (TimedThread thread in threads)
				{
					int num = Volatile.Read(in thread.remain);
					num -= duration;
					if (num < 0)
					{
						num = 0;
					}
					Volatile.Write(ref thread.remain, num);
				}
			}
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)ex.ToString());
		}
	}

	public static void unPause()
	{
		try
		{
			lock (threads)
			{
				foreach (TimedThread thread in threads)
				{
					if (thread.paused)
					{
						int dur = Volatile.Read(in thread.remain);
						new TimedResponse(thread.id, dur, CrowdResponse.Status.STATUS_RESUME).Send(ControlClient.Socket);
						thread.paused = false;
					}
				}
			}
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)ex.ToString());
		}
	}

	public TimedThread(int id, TimedType type, int duration)
	{
		effect = new Timed(type);
		this.duration = duration;
		remain = duration;
		this.id = id;
		paused = false;
		try
		{
			lock (threads)
			{
				threads.Add(this);
			}
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)ex.ToString());
		}
	}

	public void Run()
	{
		Thread.CurrentThread.CurrentCulture = CultureInfo.InvariantCulture;
		effect.addEffect();
		try
		{
			for (int num = Volatile.Read(in duration); num > 0; num = Volatile.Read(in duration))
			{
				Interlocked.Add(ref duration, -num);
				Thread.Sleep(num);
			}
			effect.removeEffect();
			lock (threads)
			{
				threads.Remove(this);
			}
			new TimedResponse(id, 0, CrowdResponse.Status.STATUS_STOP).Send(ControlClient.Socket);
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)ex.ToString());
		}
	}
}
[BepInPlugin("WarpWorld.CrowdControl", "Crowd Control", "1.0.0.0")]
public class TestMod : BaseUnityPlugin
{
	private const string modGUID = "WarpWorld.CrowdControl";

	private const string modName = "Crowd Control";

	private const string modVersion = "1.0.0.0";

	private readonly Harmony harmony = new Harmony("WarpWorld.CrowdControl");

	public static ManualLogSource mls;

	internal static TestMod Instance = null;

	private ControlClient client = null;

	public static float speed = 1f;

	public static float jump = 1f;

	public static Random rnd = new Random();

	public static Queue<Action> ActionQueue = new Queue<Action>();

	public static BattleController battle = null;

	public int getGameState()
	{
		//IL_0026: Unknown result type (might be due to invalid IL or missing references)
		//IL_002c: Invalid comparison between Unknown and I4
		//IL_002e: Unknown result type (might be due to invalid IL or missing references)
		//IL_0034: Invalid comparison between Unknown and I4
		try
		{
			if (!Object.op_Implicit((Object)(object)battle))
			{
				return -16;
			}
			if (BattleController.PreBattlePause)
			{
				return -7;
			}
			if ((int)BattleController.CurrentBattleState != 3 && (int)BattleController.CurrentBattleState != 2)
			{
				return -12;
			}
		}
		catch
		{
			return 0;
		}
		return 1;
	}

	private void Awake()
	{
		Instance = this;
		mls = Logger.CreateLogSource("Crowd Control");
		mls.LogInfo((object)"Loaded WarpWorld.CrowdControl. Patching.");
		harmony.PatchAll(typeof(TestMod));
		mls.LogInfo((object)"Initializing Crowd Control");
		try
		{
			client = new ControlClient();
			new Thread(client.NetworkLoop).Start();
			new Thread(client.RequestLoop).Start();
		}
		catch (Exception ex)
		{
			mls.LogInfo((object)("CC Init Error: " + ex.ToString()));
		}
		mls.LogInfo((object)"Crowd Control Initialized");
		mls = ((BaseUnityPlugin)this).Logger;
	}

	private void Update()
	{
	}

	[HarmonyPatch(typeof(BattleController), "Awake")]
	[HarmonyPrefix]
	private static void GetController(BattleController __instance)
	{
		battle = __instance;
	}

	[HarmonyPatch(typeof(BattleController), "Update")]
	[HarmonyPrefix]
	private static void RunEffects()
	{
		if (ActionQueue.Count > 0)
		{
			Action action = ActionQueue.Dequeue();
			action();
		}
		lock (TimedThread.threads)
		{
			foreach (TimedThread thread in TimedThread.threads)
			{
				if (!thread.paused)
				{
					thread.effect.tick();
				}
			}
		}
	}
}
public class ControlClient
{
	public static readonly string CV_HOST = "127.0.0.1";

	public static readonly int CV_PORT = 51337;

	private bool paused = false;

	public bool inGame = true;

	private Dictionary<string, CrowdDelegate> Delegate { get; set; }

	private IPEndPoint Endpoint { get; set; }

	private Queue<CrowdRequest> Requests { get; set; }

	private bool Running { get; set; }

	public static Socket Socket { get; set; }

	public ControlClient()
	{
		Endpoint = new IPEndPoint(IPAddress.Parse(CV_HOST), CV_PORT);
		Requests = new Queue<CrowdRequest>();
		Running = true;
		Socket = null;
		Delegate = new Dictionary<string, CrowdDelegate>
		{
			{
				"damage20",
				CrowdDelegates.Damage20
			},
			{
				"damage50",
				CrowdDelegates.Damage50
			},
			{
				"kill",
				CrowdDelegates.Kill
			},
			{
				"heal20",
				CrowdDelegates.Heal20
			},
			{
				"heal50",
				CrowdDelegates.Heal50
			},
			{
				"healall",
				CrowdDelegates.HealAll
			},
			{
				"maxup",
				CrowdDelegates.MaxUp
			},
			{
				"maxdown",
				CrowdDelegates.MaxDown
			},
			{
				"armor1",
				CrowdDelegates.Armor1
			},
			{
				"armor5",
				CrowdDelegates.Armor5
			},
			{
				"remarmor1",
				CrowdDelegates.RemArmor1
			},
			{
				"remarmor5",
				CrowdDelegates.RemArmor5
			},
			{
				"gold10",
				CrowdDelegates.Gold10
			},
			{
				"gold50",
				CrowdDelegates.Gold50
			},
			{
				"remgold10",
				CrowdDelegates.RemGold10
			},
			{
				"remgold50",
				CrowdDelegates.RemGold50
			},
			{
				"ballance1",
				CrowdDelegates.Ballance1
			},
			{
				"ballance5",
				CrowdDelegates.Ballance5
			},
			{
				"remballance1",
				CrowdDelegates.RemBallance1
			},
			{
				"remballance5",
				CrowdDelegates.RemBallance5
			},
			{
				"spinesse1",
				CrowdDelegates.Spinesse1
			},
			{
				"spinesse5",
				CrowdDelegates.Spinesse5
			},
			{
				"remspinesse1",
				CrowdDelegates.RemSpinesse1
			},
			{
				"remspinesse5",
				CrowdDelegates.RemSpinesse5
			},
			{
				"blind1",
				CrowdDelegates.Blind1
			},
			{
				"blind5",
				CrowdDelegates.Blind5
			},
			{
				"remblind1",
				CrowdDelegates.RemBlind1
			},
			{
				"remblind5",
				CrowdDelegates.RemBlind5
			},
			{
				"confusion1",
				CrowdDelegates.Confusion1
			},
			{
				"confusion5",
				CrowdDelegates.Confusion5
			},
			{
				"remconfusion1",
				CrowdDelegates.RemConfusion1
			},
			{
				"remconfusion5",
				CrowdDelegates.RemConfusion5
			},
			{
				"relic1",
				CrowdDelegates.Relic1
			},
			{
				"relic2",
				CrowdDelegates.Relic2
			},
			{
				"relic3",
				CrowdDelegates.Relic3
			},
			{
				"remrelic",
				CrowdDelegates.RemRelic
			},
			{
				"teletop",
				CrowdDelegates.TeleTop
			},
			{
				"ballup",
				CrowdDelegates.LaunchUp
			},
			{
				"balldown",
				CrowdDelegates.LaunchDown
			},
			{
				"ballleft",
				CrowdDelegates.LaunchLeft
			},
			{
				"ballright",
				CrowdDelegates.LaunchRight
			},
			{
				"multi",
				CrowdDelegates.Multi
			},
			{
				"incdamage10",
				CrowdDelegates.IncDamage10
			},
			{
				"incdamage50",
				CrowdDelegates.IncDamage50
			},
			{
				"remdamage10",
				CrowdDelegates.RemDamage10
			},
			{
				"remdamage50",
				CrowdDelegates.RemDamage50
			},
			{
				"orb1",
				CrowdDelegates.Orb1
			},
			{
				"orb2",
				CrowdDelegates.Orb2
			},
			{
				"orb3",
				CrowdDelegates.Orb3
			},
			{
				"remorb",
				CrowdDelegates.RemOrb
			},
			{
				"orbup",
				CrowdDelegates.OrbUp
			},
			{
				"fire",
				CrowdDelegates.Fire
			},
			{
				"aimup",
				CrowdDelegates.AimUp
			},
			{
				"aimdown",
				CrowdDelegates.AimDown
			},
			{
				"bounceup",
				CrowdDelegates.BounceUp
			},
			{
				"bouncedown",
				CrowdDelegates.BounceDown
			},
			{
				"bomb",
				CrowdDelegates.Bomb
			},
			{
				"rigged",
				CrowdDelegates.Rigged
			},
			{
				"refresh",
				CrowdDelegates.Reset
			},
			{
				"crit",
				CrowdDelegates.Crit
			},
			{
				"bounceslime",
				CrowdDelegates.BounceSlime
			},
			{
				"poisonslime",
				CrowdDelegates.PoisonSlime
			},
			{
				"healslime",
				CrowdDelegates.HealSlime
			},
			{
				"damupslime",
				CrowdDelegates.DamageUpSlime
			},
			{
				"damdownslime",
				CrowdDelegates.DamageDownSlime
			},
			{
				"remslime",
				CrowdDelegates.RemoveSlime
			},
			{
				"buff",
				CrowdDelegates.Buff
			},
			{
				"debuff",
				CrowdDelegates.Debuff
			},
			{
				"coin",
				CrowdDelegates.Coin
			},
			{
				"remcoin",
				CrowdDelegates.RemCoin
			},
			{
				"shield",
				CrowdDelegates.Shield
			},
			{
				"remshield",
				CrowdDelegates.RemShield
			},
			{
				"refreshall",
				CrowdDelegates.RefreshAll
			},
			{
				"movecrit",
				CrowdDelegates.MoveCrit
			},
			{
				"movereset",
				CrowdDelegates.MoveReset
			},
			{
				"edamage20",
				CrowdDelegates.EDamage20
			},
			{
				"edamage20all",
				CrowdDelegates.EDamage20All
			},
			{
				"eheal20",
				CrowdDelegates.EHeal20
			},
			{
				"eheal20all",
				CrowdDelegates.EHeal20All
			},
			{
				"ekill",
				CrowdDelegates.EKill
			},
			{
				"ekillall",
				CrowdDelegates.EKillAll
			},
			{
				"ehealfull",
				CrowdDelegates.EHealFull
			},
			{
				"ehealfullall",
				CrowdDelegates.EHealFullAll
			},
			{
				"earmor10",
				CrowdDelegates.EArmor10
			},
			{
				"earmor50",
				CrowdDelegates.EArmor50
			},
			{
				"eremarmor10",
				CrowdDelegates.ERemArmor10
			},
			{
				"eremarmor50",
				CrowdDelegates.ERemArmor50
			},
			{
				"ebramble1",
				CrowdDelegates.EBramble1
			},
			{
				"ebramble5",
				CrowdDelegates.EBramble5
			},
			{
				"erembramble1",
				CrowdDelegates.ERemBramble1
			},
			{
				"erembramble5",
				CrowdDelegates.ERemBramble5
			},
			{
				"espinfection1",
				CrowdDelegates.ESpinfection1
			},
			{
				"espinfection5",
				CrowdDelegates.ESpinfection5
			},
			{
				"eremspinfection1",
				CrowdDelegates.ERemSpinfection1
			},
			{
				"eremspinfection5",
				CrowdDelegates.ERemSpinfection5
			},
			{
				"eblind1",
				CrowdDelegates.EBlin1
			},
			{
				"eblind5",
				CrowdDelegates.EBlind5
			},
			{
				"eremblind1",
				CrowdDelegates.ERemBlind1
			},
			{
				"eremblind5",
				CrowdDelegates.ERemBlind5
			}
		};
	}

	public bool isReady()
	{
		//IL_0024: Unknown result type (might be due to invalid IL or missing references)
		//IL_002a: Invalid comparison between Unknown and I4
		//IL_002c: Unknown result type (might be due to invalid IL or missing references)
		//IL_0032: Invalid comparison between Unknown and I4
		try
		{
			if (!Object.op_Implicit((Object)(object)TestMod.battle))
			{
				return false;
			}
			if (BattleController.PreBattlePause)
			{
				return false;
			}
			if ((int)BattleController.CurrentBattleState != 3 && (int)BattleController.CurrentBattleState != 2)
			{
				return false;
			}
		}
		catch (Exception ex)
		{
			TestMod.mls.LogError((object)ex.ToString());
			return false;
		}
		return true;
	}

	public static void HideEffect(string code)
	{
		CrowdResponse crowdResponse = new CrowdResponse(0, CrowdResponse.Status.STATUS_NOTVISIBLE);
		crowdResponse.type = 1;
		crowdResponse.code = code;
		crowdResponse.Send(Socket);
	}

	public static void ShowEffect(string code)
	{
		CrowdResponse crowdResponse = new CrowdResponse(0, CrowdResponse.Status.STATUS_VISIBLE);
		crowdResponse.type = 1;
		crowdResponse.code = code;
		crowdResponse.Send(Socket);
	}

	public static void DisableEffect(string code)
	{
		CrowdResponse crowdResponse = new CrowdResponse(0, CrowdResponse.Status.STATUS_NOTSELECTABLE);
		crowdResponse.type = 1;
		crowdResponse.code = code;
		crowdResponse.Send(Socket);
	}

	public static void EnableEffect(string code)
	{
		CrowdResponse crowdResponse = new CrowdResponse(0, CrowdResponse.Status.STATUS_SELECTABLE);
		crowdResponse.type = 1;
		crowdResponse.code = code;
		crowdResponse.Send(Socket);
	}

	private void ClientLoop()
	{
		TestMod.mls.LogInfo((object)"Connected to Crowd Control");
		Timer timer = new Timer(timeUpdate, null, 0, 200);
		try
		{
			while (Running)
			{
				CrowdRequest crowdRequest = CrowdRequest.Recieve(this, Socket);
				if (crowdRequest == null || crowdRequest.IsKeepAlive())
				{
					continue;
				}
				if (crowdRequest.IsGameState())
				{
					new GameStateResponse(crowdRequest.id, TestMod.Instance.getGameState()).Send(Socket);
				}
				else if (!(crowdRequest.type != "0") || !(crowdRequest.type != "1"))
				{
					lock (Requests)
					{
						Requests.Enqueue(crowdRequest);
					}
				}
			}
		}
		catch (Exception)
		{
			TestMod.mls.LogInfo((object)"Disconnected from Crowd Control");
			Socket.Close();
		}
	}

	public void timeUpdate(object state)
	{
		inGame = true;
		if (!isReady())
		{
			inGame = false;
		}
		if (!inGame)
		{
			TimedThread.addTime(200);
			paused = true;
		}
		else if (paused)
		{
			paused = false;
			TimedThread.unPause();
			TimedThread.tickTime(200);
		}
		else
		{
			TimedThread.tickTime(200);
		}
	}

	public bool IsRunning()
	{
		return Running;
	}

	public void NetworkLoop()
	{
		Thread.CurrentThread.CurrentCulture = CultureInfo.InvariantCulture;
		while (Running)
		{
			TestMod.mls.LogInfo((object)"Attempting to connect to Crowd Control");
			try
			{
				Socket = new Socket(Endpoint.AddressFamily, SocketType.Stream, ProtocolType.Tcp);
				Socket.SetSocketOption(SocketOptionLevel.Socket, SocketOptionName.KeepAlive, optionValue: true);
				if (Socket.BeginConnect(Endpoint, null, null).AsyncWaitHandle.WaitOne(10000, exitContext: true) && Socket.Connected)
				{
					ClientLoop();
				}
				else
				{
					TestMod.mls.LogInfo((object)"Failed to connect to Crowd Control");
				}
				Socket.Close();
			}
			catch (Exception ex)
			{
				TestMod.mls.LogInfo((object)ex.GetType().Name);
				TestMod.mls.LogInfo((object)"Failed to connect to Crowd Control");
			}
			Thread.Sleep(10000);
		}
	}

	public void RequestLoop()
	{
		Thread.CurrentThread.CurrentCulture = CultureInfo.InvariantCulture;
		while (Running)
		{
			try
			{
				CrowdRequest crowdRequest = null;
				lock (Requests)
				{
					if (Requests.Count == 0)
					{
						continue;
					}
					crowdRequest = Requests.Dequeue();
					goto IL_0060;
				}
				IL_0060:
				string reqCode = crowdRequest.GetReqCode();
				try
				{
					CrowdResponse crowdResponse = (isReady() ? Delegate[reqCode](this, crowdRequest) : new CrowdResponse(crowdRequest.GetReqID(), CrowdResponse.Status.STATUS_RETRY));
					if (crowdResponse == null)
					{
						new CrowdResponse(crowdRequest.GetReqID(), CrowdResponse.Status.STATUS_FAILURE, "Request error for '" + reqCode + "'").Send(Socket);
					}
					crowdResponse.Send(Socket);
				}
				catch (KeyNotFoundException)
				{
					new CrowdResponse(crowdRequest.GetReqID(), CrowdResponse.Status.STATUS_FAILURE, "Request error for '" + reqCode + "'").Send(Socket);
				}
			}
			catch (Exception)
			{
				TestMod.mls.LogInfo((object)"Disconnected from Crowd Control");
				Socket.Close();
			}
		}
	}

	public void Stop()
	{
		Running = false;
	}
}
public delegate CrowdResponse CrowdDelegate(ControlClient client, CrowdRequest req);
public class CrowdDelegates
{
	public static Random rnd = new Random();

	public static CrowdResponse Damage20(ControlClient client, CrowdRequest req)
	{
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			float amt = TestMod.battle.PlayerHealthController.MaxHealth / 5f;
			if (TestMod.battle.PlayerHealthController.CurrentHealth <= amt)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Health too low");
			}
			if (TimedThread.isRunning(TimedType.INVUL))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Currently Invulnerable");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				try
				{
					TestMod.battle.PlayerHealthController.DealUnblockableDamage(amt, true, false, false);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse Damage50(ControlClient client, CrowdRequest req)
	{
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			float amt = TestMod.battle.PlayerHealthController.MaxHealth / 2f;
			if (TestMod.battle.PlayerHealthController.CurrentHealth <= amt)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Health too low");
			}
			if (TimedThread.isRunning(TimedType.INVUL))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Currently Invulnerable");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				try
				{
					TestMod.battle.PlayerHealthController.DealUnblockableDamage(amt, true, false, false);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse Kill(ControlClient client, CrowdRequest req)
	{
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			float amt = 999f;
			if (TimedThread.isRunning(TimedType.INVUL))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Currently Invulnerable");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				try
				{
					TestMod.battle.PlayerHealthController.DealUnblockableDamage(amt, true, true, false);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse Heal20(ControlClient client, CrowdRequest req)
	{
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			float amt = TestMod.battle.PlayerHealthController.MaxHealth / 5f;
			if (TestMod.battle.PlayerHealthController.CurrentHealth >= TestMod.battle.PlayerHealthController.MaxHealth)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Health already full");
			}
			if (TimedThread.isRunning(TimedType.INVUL))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Currently Invulnerable");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				try
				{
					TestMod.battle.PlayerHealthController.Heal(amt);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse Heal50(ControlClient client, CrowdRequest req)
	{
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			float amt = TestMod.battle.PlayerHealthController.MaxHealth / 2f;
			if ((double)TestMod.battle.PlayerHealthController.CurrentHealth >= (double)TestMod.battle.PlayerHealthController.MaxHealth * 0.9)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Health already near full");
			}
			if (TimedThread.isRunning(TimedType.INVUL))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Currently Invulnerable");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				try
				{
					TestMod.battle.PlayerHealthController.Heal(amt);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse HealAll(ControlClient client, CrowdRequest req)
	{
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			if (TestMod.battle.PlayerHealthController.CurrentHealth >= TestMod.battle.PlayerHealthController.MaxHealth)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Health already full");
			}
			if (TimedThread.isRunning(TimedType.INVUL))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Currently Invulnerable");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				try
				{
					TestMod.battle.PlayerHealthController.HealToFull();
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse MaxUp(ControlClient client, CrowdRequest req)
	{
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			if (TestMod.battle.PlayerHealthController.MaxHealth >= 500f)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Health too high");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				try
				{
					TestMod.battle.PlayerHealthController.AdjustMaxHealth(5f);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse MaxDown(ControlClient client, CrowdRequest req)
	{
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			if (TestMod.battle.PlayerHealthController.MaxHealth <= 24f)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Health too low");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				try
				{
					TestMod.battle.PlayerHealthController.AdjustMaxHealth(-5f);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse Armor1(ControlClient client, CrowdRequest req)
	{
		//IL_0020: Unknown result type (might be due to invalid IL or missing references)
		//IL_002a: Expected O, but got Unknown
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			PlayerStatusEffectController effects = (PlayerStatusEffectController)getProperty(TestMod.battle, "_playerStatusEffectController");
			if ((float)effects.EffectStrength((StatusEffectType)12) >= 999f)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Armor too high");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_0020: Unknown result type (might be due to invalid IL or missing references)
				//IL_002b: Expected O, but got Unknown
				//IL_006f: Unknown result type (might be due to invalid IL or missing references)
				//IL_0075: Expected O, but got Unknown
				//IL_0089: Unknown result type (might be due to invalid IL or missing references)
				//IL_008f: Expected O, but got Unknown
				try
				{
					if (!effects.HasEffect((StatusEffectType)12))
					{
						effects.ApplyStatusEffect(new StatusEffect((StatusEffectType)12, 1), (StatusEffectSource)1);
					}
					else
					{
						callFunc(effects, "FindAndUpdateStatusEffect", new object[2]
						{
							(object)(StatusEffectType)12,
							1
						});
					}
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.ArmourBlockSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse Armor5(ControlClient client, CrowdRequest req)
	{
		//IL_0020: Unknown result type (might be due to invalid IL or missing references)
		//IL_002a: Expected O, but got Unknown
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			PlayerStatusEffectController effects = (PlayerStatusEffectController)getProperty(TestMod.battle, "_playerStatusEffectController");
			if ((float)effects.EffectStrength((StatusEffectType)12) >= 999f)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Armor too high");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_00ae: Unknown result type (might be due to invalid IL or missing references)
				//IL_00b4: Expected O, but got Unknown
				//IL_00c8: Unknown result type (might be due to invalid IL or missing references)
				//IL_00ce: Expected O, but got Unknown
				try
				{
					if (!effects.HasEffect((StatusEffectType)12))
					{
						callFunc(effects, "FindAndUpdateStatusEffect", new object[2]
						{
							(object)(StatusEffectType)12,
							1
						});
						callFunc(effects, "FindAndUpdateStatusEffect", new object[2]
						{
							(object)(StatusEffectType)12,
							4
						});
					}
					else
					{
						callFunc(effects, "FindAndUpdateStatusEffect", new object[2]
						{
							(object)(StatusEffectType)12,
							5
						});
					}
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.ArmourBlockSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse RemArmor1(ControlClient client, CrowdRequest req)
	{
		//IL_0020: Unknown result type (might be due to invalid IL or missing references)
		//IL_002a: Expected O, but got Unknown
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			PlayerStatusEffectController effects = (PlayerStatusEffectController)getProperty(TestMod.battle, "_playerStatusEffectController");
			if ((float)effects.EffectStrength((StatusEffectType)12) < 1f)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Armor too low");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_0040: Unknown result type (might be due to invalid IL or missing references)
				//IL_0046: Expected O, but got Unknown
				//IL_005a: Unknown result type (might be due to invalid IL or missing references)
				//IL_0060: Expected O, but got Unknown
				try
				{
					callFunc(effects, "FindAndUpdateStatusEffect", new object[2]
					{
						(object)(StatusEffectType)12,
						-1
					});
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.ArmourBreakSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse RemArmor5(ControlClient client, CrowdRequest req)
	{
		//IL_0020: Unknown result type (might be due to invalid IL or missing references)
		//IL_002a: Expected O, but got Unknown
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			PlayerStatusEffectController effects = (PlayerStatusEffectController)getProperty(TestMod.battle, "_playerStatusEffectController");
			if ((float)effects.EffectStrength((StatusEffectType)12) < 1f)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Armor too low");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_0041: Unknown result type (might be due to invalid IL or missing references)
				//IL_0047: Expected O, but got Unknown
				//IL_005b: Unknown result type (might be due to invalid IL or missing references)
				//IL_0061: Expected O, but got Unknown
				try
				{
					callFunc(effects, "FindAndUpdateStatusEffect", new object[2]
					{
						(object)(StatusEffectType)12,
						-5
					});
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.ArmourBreakSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse Gold10(ControlClient client, CrowdRequest req)
	{
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_0024: Unknown result type (might be due to invalid IL or missing references)
				//IL_002a: Expected O, but got Unknown
				//IL_003e: Unknown result type (might be due to invalid IL or missing references)
				//IL_0044: Expected O, but got Unknown
				try
				{
					CurrencyManager.Instance.AddGold(10, false);
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.LootRewardSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse Gold50(ControlClient client, CrowdRequest req)
	{
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_0024: Unknown result type (might be due to invalid IL or missing references)
				//IL_002a: Expected O, but got Unknown
				//IL_003e: Unknown result type (might be due to invalid IL or missing references)
				//IL_0044: Expected O, but got Unknown
				try
				{
					CurrencyManager.Instance.AddGold(50, false);
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.LootRewardSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse RemGold10(ControlClient client, CrowdRequest req)
	{
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			if (!CurrencyManager.Instance.CanAfford(10))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Not enough money");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_0025: Unknown result type (might be due to invalid IL or missing references)
				//IL_002b: Expected O, but got Unknown
				//IL_003f: Unknown result type (might be due to invalid IL or missing references)
				//IL_0045: Expected O, but got Unknown
				try
				{
					CurrencyManager.Instance.RemoveGold(10, false, true);
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.LootRewardSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse RemGold50(ControlClient client, CrowdRequest req)
	{
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			if (!CurrencyManager.Instance.CanAfford(50))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Not enough money");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_0025: Unknown result type (might be due to invalid IL or missing references)
				//IL_002b: Expected O, but got Unknown
				//IL_003f: Unknown result type (might be due to invalid IL or missing references)
				//IL_0045: Expected O, but got Unknown
				try
				{
					CurrencyManager.Instance.RemoveGold(50, false, true);
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.LootRewardSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse Ballance1(ControlClient client, CrowdRequest req)
	{
		//IL_0020: Unknown result type (might be due to invalid IL or missing references)
		//IL_002a: Expected O, but got Unknown
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			PlayerStatusEffectController effects = (PlayerStatusEffectController)getProperty(TestMod.battle, "_playerStatusEffectController");
			if ((float)effects.EffectStrength((StatusEffectType)10) >= 999f)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Status effect maxed");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_0020: Unknown result type (might be due to invalid IL or missing references)
				//IL_002b: Expected O, but got Unknown
				//IL_006f: Unknown result type (might be due to invalid IL or missing references)
				//IL_0075: Expected O, but got Unknown
				//IL_0089: Unknown result type (might be due to invalid IL or missing references)
				//IL_008f: Expected O, but got Unknown
				try
				{
					if (!effects.HasEffect((StatusEffectType)10))
					{
						effects.ApplyStatusEffect(new StatusEffect((StatusEffectType)10, 1), (StatusEffectSource)1);
					}
					else
					{
						callFunc(effects, "FindAndUpdateStatusEffect", new object[2]
						{
							(object)(StatusEffectType)10,
							1
						});
					}
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.ArmourBlockSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse Ballance5(ControlClient client, CrowdRequest req)
	{
		//IL_0020: Unknown result type (might be due to invalid IL or missing references)
		//IL_002a: Expected O, but got Unknown
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			PlayerStatusEffectController effects = (PlayerStatusEffectController)getProperty(TestMod.battle, "_playerStatusEffectController");
			if ((float)effects.EffectStrength((StatusEffectType)10) >= 999f)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Status Effect Maxed");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_00ae: Unknown result type (might be due to invalid IL or missing references)
				//IL_00b4: Expected O, but got Unknown
				//IL_00c8: Unknown result type (might be due to invalid IL or missing references)
				//IL_00ce: Expected O, but got Unknown
				try
				{
					if (!effects.HasEffect((StatusEffectType)10))
					{
						callFunc(effects, "FindAndUpdateStatusEffect", new object[2]
						{
							(object)(StatusEffectType)10,
							1
						});
						callFunc(effects, "FindAndUpdateStatusEffect", new object[2]
						{
							(object)(StatusEffectType)10,
							4
						});
					}
					else
					{
						callFunc(effects, "FindAndUpdateStatusEffect", new object[2]
						{
							(object)(StatusEffectType)10,
							5
						});
					}
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.ArmourBlockSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse RemBallance1(ControlClient client, CrowdRequest req)
	{
		//IL_0020: Unknown result type (might be due to invalid IL or missing references)
		//IL_002a: Expected O, but got Unknown
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			PlayerStatusEffectController effects = (PlayerStatusEffectController)getProperty(TestMod.battle, "_playerStatusEffectController");
			if ((float)effects.EffectStrength((StatusEffectType)10) < 1f)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Status duration too low");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_0040: Unknown result type (might be due to invalid IL or missing references)
				//IL_0046: Expected O, but got Unknown
				//IL_005a: Unknown result type (might be due to invalid IL or missing references)
				//IL_0060: Expected O, but got Unknown
				try
				{
					callFunc(effects, "FindAndUpdateStatusEffect", new object[2]
					{
						(object)(StatusEffectType)10,
						-1
					});
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.ArmourBreakSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse RemBallance5(ControlClient client, CrowdRequest req)
	{
		//IL_0020: Unknown result type (might be due to invalid IL or missing references)
		//IL_002a: Expected O, but got Unknown
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			PlayerStatusEffectController effects = (PlayerStatusEffectController)getProperty(TestMod.battle, "_playerStatusEffectController");
			if ((float)effects.EffectStrength((StatusEffectType)10) < 1f)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Status duration too low");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_0041: Unknown result type (might be due to invalid IL or missing references)
				//IL_0047: Expected O, but got Unknown
				//IL_005b: Unknown result type (might be due to invalid IL or missing references)
				//IL_0061: Expected O, but got Unknown
				try
				{
					callFunc(effects, "FindAndUpdateStatusEffect", new object[2]
					{
						(object)(StatusEffectType)10,
						-5
					});
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.ArmourBreakSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse Spinesse1(ControlClient client, CrowdRequest req)
	{
		//IL_0020: Unknown result type (might be due to invalid IL or missing references)
		//IL_002a: Expected O, but got Unknown
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			PlayerStatusEffectController effects = (PlayerStatusEffectController)getProperty(TestMod.battle, "_playerStatusEffectController");
			if ((float)effects.EffectStrength((StatusEffectType)9) >= 999f)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Status effect maxed");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_0020: Unknown result type (might be due to invalid IL or missing references)
				//IL_002b: Expected O, but got Unknown
				//IL_006f: Unknown result type (might be due to invalid IL or missing references)
				//IL_0075: Expected O, but got Unknown
				//IL_0089: Unknown result type (might be due to invalid IL or missing references)
				//IL_008f: Expected O, but got Unknown
				try
				{
					if (!effects.HasEffect((StatusEffectType)9))
					{
						effects.ApplyStatusEffect(new StatusEffect((StatusEffectType)9, 1), (StatusEffectSource)1);
					}
					else
					{
						callFunc(effects, "FindAndUpdateStatusEffect", new object[2]
						{
							(object)(StatusEffectType)9,
							1
						});
					}
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.ArmourBlockSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse Spinesse5(ControlClient client, CrowdRequest req)
	{
		//IL_0020: Unknown result type (might be due to invalid IL or missing references)
		//IL_002a: Expected O, but got Unknown
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			PlayerStatusEffectController effects = (PlayerStatusEffectController)getProperty(TestMod.battle, "_playerStatusEffectController");
			if ((float)effects.EffectStrength((StatusEffectType)9) >= 999f)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Status Effect Maxed");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_00ae: Unknown result type (might be due to invalid IL or missing references)
				//IL_00b4: Expected O, but got Unknown
				//IL_00c8: Unknown result type (might be due to invalid IL or missing references)
				//IL_00ce: Expected O, but got Unknown
				try
				{
					if (!effects.HasEffect((StatusEffectType)9))
					{
						callFunc(effects, "FindAndUpdateStatusEffect", new object[2]
						{
							(object)(StatusEffectType)9,
							1
						});
						callFunc(effects, "FindAndUpdateStatusEffect", new object[2]
						{
							(object)(StatusEffectType)9,
							4
						});
					}
					else
					{
						callFunc(effects, "FindAndUpdateStatusEffect", new object[2]
						{
							(object)(StatusEffectType)9,
							5
						});
					}
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.ArmourBlockSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse RemSpinesse1(ControlClient client, CrowdRequest req)
	{
		//IL_0020: Unknown result type (might be due to invalid IL or missing references)
		//IL_002a: Expected O, but got Unknown
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			PlayerStatusEffectController effects = (PlayerStatusEffectController)getProperty(TestMod.battle, "_playerStatusEffectController");
			if ((float)effects.EffectStrength((StatusEffectType)9) < 1f)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Status duration too low");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_0040: Unknown result type (might be due to invalid IL or missing references)
				//IL_0046: Expected O, but got Unknown
				//IL_005a: Unknown result type (might be due to invalid IL or missing references)
				//IL_0060: Expected O, but got Unknown
				try
				{
					callFunc(effects, "FindAndUpdateStatusEffect", new object[2]
					{
						(object)(StatusEffectType)9,
						-1
					});
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.ArmourBreakSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse RemSpinesse5(ControlClient client, CrowdRequest req)
	{
		//IL_0020: Unknown result type (might be due to invalid IL or missing references)
		//IL_002a: Expected O, but got Unknown
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			PlayerStatusEffectController effects = (PlayerStatusEffectController)getProperty(TestMod.battle, "_playerStatusEffectController");
			if ((float)effects.EffectStrength((StatusEffectType)9) < 1f)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Status duration too low");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_0041: Unknown result type (might be due to invalid IL or missing references)
				//IL_0047: Expected O, but got Unknown
				//IL_005b: Unknown result type (might be due to invalid IL or missing references)
				//IL_0061: Expected O, but got Unknown
				try
				{
					callFunc(effects, "FindAndUpdateStatusEffect", new object[2]
					{
						(object)(StatusEffectType)9,
						-5
					});
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.ArmourBreakSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse Blind1(ControlClient client, CrowdRequest req)
	{
		//IL_0020: Unknown result type (might be due to invalid IL or missing references)
		//IL_002a: Expected O, but got Unknown
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			PlayerStatusEffectController effects = (PlayerStatusEffectController)getProperty(TestMod.battle, "_playerStatusEffectController");
			if ((float)effects.EffectStrength((StatusEffectType)3) >= 999f)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Status effect maxed");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_001e: Unknown result type (might be due to invalid IL or missing references)
				//IL_0029: Expected O, but got Unknown
				//IL_006c: Unknown result type (might be due to invalid IL or missing references)
				//IL_0072: Expected O, but got Unknown
				//IL_0086: Unknown result type (might be due to invalid IL or missing references)
				//IL_008c: Expected O, but got Unknown
				try
				{
					if (!effects.HasEffect((StatusEffectType)3))
					{
						effects.ApplyStatusEffect(new StatusEffect((StatusEffectType)3, 1), (StatusEffectSource)1);
					}
					else
					{
						callFunc(effects, "FindAndUpdateStatusEffect", new object[2]
						{
							(object)(StatusEffectType)3,
							1
						});
					}
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.ArmourBlockSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse Blind5(ControlClient client, CrowdRequest req)
	{
		//IL_0020: Unknown result type (might be due to invalid IL or missing references)
		//IL_002a: Expected O, but got Unknown
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			PlayerStatusEffectController effects = (PlayerStatusEffectController)getProperty(TestMod.battle, "_playerStatusEffectController");
			if ((float)effects.EffectStrength((StatusEffectType)3) >= 999f)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Status Effect Maxed");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_00aa: Unknown result type (might be due to invalid IL or missing references)
				//IL_00b0: Expected O, but got Unknown
				//IL_00c4: Unknown result type (might be due to invalid IL or missing references)
				//IL_00ca: Expected O, but got Unknown
				try
				{
					if (!effects.HasEffect((StatusEffectType)3))
					{
						callFunc(effects, "FindAndUpdateStatusEffect", new object[2]
						{
							(object)(StatusEffectType)3,
							1
						});
						callFunc(effects, "FindAndUpdateStatusEffect", new object[2]
						{
							(object)(StatusEffectType)3,
							4
						});
					}
					else
					{
						callFunc(effects, "FindAndUpdateStatusEffect", new object[2]
						{
							(object)(StatusEffectType)3,
							5
						});
					}
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.ArmourBlockSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse RemBlind1(ControlClient client, CrowdRequest req)
	{
		//IL_0020: Unknown result type (might be due to invalid IL or missing references)
		//IL_002a: Expected O, but got Unknown
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			PlayerStatusEffectController effects = (PlayerStatusEffectController)getProperty(TestMod.battle, "_playerStatusEffectController");
			if ((float)effects.EffectStrength((StatusEffectType)3) < 1f)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Status duration too low");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_003f: Unknown result type (might be due to invalid IL or missing references)
				//IL_0045: Expected O, but got Unknown
				//IL_0059: Unknown result type (might be due to invalid IL or missing references)
				//IL_005f: Expected O, but got Unknown
				try
				{
					callFunc(effects, "FindAndUpdateStatusEffect", new object[2]
					{
						(object)(StatusEffectType)3,
						-1
					});
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.ArmourBreakSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse RemBlind5(ControlClient client, CrowdRequest req)
	{
		//IL_0020: Unknown result type (might be due to invalid IL or missing references)
		//IL_002a: Expected O, but got Unknown
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			PlayerStatusEffectController effects = (PlayerStatusEffectController)getProperty(TestMod.battle, "_playerStatusEffectController");
			if ((float)effects.EffectStrength((StatusEffectType)3) < 1f)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Status duration too low");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_0040: Unknown result type (might be due to invalid IL or missing references)
				//IL_0046: Expected O, but got Unknown
				//IL_005a: Unknown result type (might be due to invalid IL or missing references)
				//IL_0060: Expected O, but got Unknown
				try
				{
					callFunc(effects, "FindAndUpdateStatusEffect", new object[2]
					{
						(object)(StatusEffectType)3,
						-5
					});
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.ArmourBreakSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse Confusion1(ControlClient client, CrowdRequest req)
	{
		//IL_0020: Unknown result type (might be due to invalid IL or missing references)
		//IL_002a: Expected O, but got Unknown
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			PlayerStatusEffectController effects = (PlayerStatusEffectController)getProperty(TestMod.battle, "_playerStatusEffectController");
			if ((float)effects.EffectStrength((StatusEffectType)4) >= 999f)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Status effect maxed");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_001e: Unknown result type (might be due to invalid IL or missing references)
				//IL_0029: Expected O, but got Unknown
				//IL_006c: Unknown result type (might be due to invalid IL or missing references)
				//IL_0072: Expected O, but got Unknown
				//IL_0086: Unknown result type (might be due to invalid IL or missing references)
				//IL_008c: Expected O, but got Unknown
				try
				{
					if (!effects.HasEffect((StatusEffectType)4))
					{
						effects.ApplyStatusEffect(new StatusEffect((StatusEffectType)4, 1), (StatusEffectSource)1);
					}
					else
					{
						callFunc(effects, "FindAndUpdateStatusEffect", new object[2]
						{
							(object)(StatusEffectType)4,
							1
						});
					}
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.ArmourBlockSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse Confusion5(ControlClient client, CrowdRequest req)
	{
		//IL_0020: Unknown result type (might be due to invalid IL or missing references)
		//IL_002a: Expected O, but got Unknown
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			PlayerStatusEffectController effects = (PlayerStatusEffectController)getProperty(TestMod.battle, "_playerStatusEffectController");
			if ((float)effects.EffectStrength((StatusEffectType)4) >= 999f)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Status Effect Maxed");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_00aa: Unknown result type (might be due to invalid IL or missing references)
				//IL_00b0: Expected O, but got Unknown
				//IL_00c4: Unknown result type (might be due to invalid IL or missing references)
				//IL_00ca: Expected O, but got Unknown
				try
				{
					if (!effects.HasEffect((StatusEffectType)4))
					{
						callFunc(effects, "FindAndUpdateStatusEffect", new object[2]
						{
							(object)(StatusEffectType)4,
							1
						});
						callFunc(effects, "FindAndUpdateStatusEffect", new object[2]
						{
							(object)(StatusEffectType)4,
							4
						});
					}
					else
					{
						callFunc(effects, "FindAndUpdateStatusEffect", new object[2]
						{
							(object)(StatusEffectType)4,
							5
						});
					}
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.ArmourBlockSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse RemConfusion1(ControlClient client, CrowdRequest req)
	{
		//IL_0020: Unknown result type (might be due to invalid IL or missing references)
		//IL_002a: Expected O, but got Unknown
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			PlayerStatusEffectController effects = (PlayerStatusEffectController)getProperty(TestMod.battle, "_playerStatusEffectController");
			if ((float)effects.EffectStrength((StatusEffectType)4) < 1f)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Status duration too low");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_003f: Unknown result type (might be due to invalid IL or missing references)
				//IL_0045: Expected O, but got Unknown
				//IL_0059: Unknown result type (might be due to invalid IL or missing references)
				//IL_005f: Expected O, but got Unknown
				try
				{
					callFunc(effects, "FindAndUpdateStatusEffect", new object[2]
					{
						(object)(StatusEffectType)4,
						-1
					});
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.ArmourBreakSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse RemConfusion5(ControlClient client, CrowdRequest req)
	{
		//IL_0020: Unknown result type (might be due to invalid IL or missing references)
		//IL_002a: Expected O, but got Unknown
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			PlayerStatusEffectController effects = (PlayerStatusEffectController)getProperty(TestMod.battle, "_playerStatusEffectController");
			if ((float)effects.EffectStrength((StatusEffectType)4) < 1f)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Status duration too low");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_0040: Unknown result type (might be due to invalid IL or missing references)
				//IL_0046: Expected O, but got Unknown
				//IL_005a: Unknown result type (might be due to invalid IL or missing references)
				//IL_0060: Expected O, but got Unknown
				try
				{
					callFunc(effects, "FindAndUpdateStatusEffect", new object[2]
					{
						(object)(StatusEffectType)4,
						-5
					});
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.ArmourBreakSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse Relic1(ControlClient client, CrowdRequest req)
	{
		//IL_0025: Unknown result type (might be due to invalid IL or missing references)
		//IL_002f: Expected O, but got Unknown
		//IL_005a: Unknown result type (might be due to invalid IL or missing references)
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			RelicManager relics = (RelicManager)getProperty(TestMod.battle.PlayerHealthController, "_relicManager");
			Relic relic = relics.GetCommonRelic(false);
			if (!Object.op_Implicit((Object)(object)relic) || relics.RelicEffectActive(relic.effect))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Relic not available");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_0020: Unknown result type (might be due to invalid IL or missing references)
				//IL_003f: Unknown result type (might be due to invalid IL or missing references)
				//IL_0045: Expected O, but got Unknown
				//IL_0059: Unknown result type (might be due to invalid IL or missing references)
				//IL_005f: Expected O, but got Unknown
				try
				{
					relics.AddRelic(relic);
					relics.FlashRelic(relic.effect);
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.LootRewardSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse Relic2(ControlClient client, CrowdRequest req)
	{
		//IL_0025: Unknown result type (might be due to invalid IL or missing references)
		//IL_002f: Expected O, but got Unknown
		//IL_005a: Unknown result type (might be due to invalid IL or missing references)
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			RelicManager relics = (RelicManager)getProperty(TestMod.battle.PlayerHealthController, "_relicManager");
			Relic relic = relics.GetBossRelic(false);
			if (!Object.op_Implicit((Object)(object)relic) || relics.RelicEffectActive(relic.effect))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Relic not available");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_0020: Unknown result type (might be due to invalid IL or missing references)
				//IL_003f: Unknown result type (might be due to invalid IL or missing references)
				//IL_0045: Expected O, but got Unknown
				//IL_0059: Unknown result type (might be due to invalid IL or missing references)
				//IL_005f: Expected O, but got Unknown
				try
				{
					relics.AddRelic(relic);
					relics.FlashRelic(relic.effect);
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.LootRewardSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse Relic3(ControlClient client, CrowdRequest req)
	{
		//IL_0025: Unknown result type (might be due to invalid IL or missing references)
		//IL_002f: Expected O, but got Unknown
		//IL_005a: Unknown result type (might be due to invalid IL or missing references)
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			RelicManager relics = (RelicManager)getProperty(TestMod.battle.PlayerHealthController, "_relicManager");
			Relic relic = relics.GetRareRelic(false);
			if (!Object.op_Implicit((Object)(object)relic) || relics.RelicEffectActive(relic.effect))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Relic not available");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_0020: Unknown result type (might be due to invalid IL or missing references)
				//IL_003f: Unknown result type (might be due to invalid IL or missing references)
				//IL_0045: Expected O, but got Unknown
				//IL_0059: Unknown result type (might be due to invalid IL or missing references)
				//IL_005f: Expected O, but got Unknown
				try
				{
					relics.AddRelic(relic);
					relics.FlashRelic(relic.effect);
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.LootRewardSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse RemRelic(ControlClient client, CrowdRequest req)
	{
		//IL_0025: Unknown result type (might be due to invalid IL or missing references)
		//IL_002f: Expected O, but got Unknown
		//IL_008d: Unknown result type (might be due to invalid IL or missing references)
		//IL_0092: Unknown result type (might be due to invalid IL or missing references)
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			RelicManager relics = (RelicManager)getProperty(TestMod.battle.PlayerHealthController, "_relicManager");
			if (relics.GetRelicCount() < 1)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Relic not available");
			}
			Dictionary<RelicEffect, Relic> dictionary = (Dictionary<RelicEffect, Relic>)getProperty(relics, "_ownedRelics");
			RelicEffect effect = dictionary.ElementAt(TestMod.rnd.Next(0, dictionary.Count)).Key;
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_0009: Unknown result type (might be due to invalid IL or missing references)
				//IL_0028: Unknown result type (might be due to invalid IL or missing references)
				//IL_002e: Expected O, but got Unknown
				//IL_0042: Unknown result type (might be due to invalid IL or missing references)
				//IL_0048: Expected O, but got Unknown
				try
				{
					relics.RemoveRelic(effect);
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.ArmourBreakSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse TeleTop(ControlClient client, CrowdRequest req)
	{
		//IL_0010: Unknown result type (might be due to invalid IL or missing references)
		//IL_0016: Invalid comparison between Unknown and I4
		//IL_00a9: Unknown result type (might be due to invalid IL or missing references)
		//IL_00ae: Unknown result type (might be due to invalid IL or missing references)
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			if ((int)BattleController.CurrentBattleState == 2)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Ball not available");
			}
			GameObject activePachinkoBall = TestMod.battle.activePachinkoBall;
			if (!Object.op_Implicit((Object)(object)activePachinkoBall))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Ball not available");
			}
			PachinkoBall ball = activePachinkoBall.GetComponent<PachinkoBall>();
			if (!Object.op_Implicit((Object)(object)ball))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Ball not available");
			}
			Vector3 position = ((Component)ball).transform.position;
			position.y = ((Vector2)(ref StaticGameData.battleYBounds))[1];
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_0009: Unknown result type (might be due to invalid IL or missing references)
				//IL_0028: Unknown result type (might be due to invalid IL or missing references)
				//IL_002e: Expected O, but got Unknown
				//IL_0042: Unknown result type (might be due to invalid IL or missing references)
				//IL_0048: Expected O, but got Unknown
				try
				{
					ball.TeleportTo(position);
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.PlayerDodgeSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse LaunchUp(ControlClient client, CrowdRequest req)
	{
		//IL_0010: Unknown result type (might be due to invalid IL or missing references)
		//IL_0016: Invalid comparison between Unknown and I4
		//IL_00ad: Unknown result type (might be due to invalid IL or missing references)
		//IL_00b2: Unknown result type (might be due to invalid IL or missing references)
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			if ((int)BattleController.CurrentBattleState == 2)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Ball not available");
			}
			GameObject activePachinkoBall = TestMod.battle.activePachinkoBall;
			if (!Object.op_Implicit((Object)(object)activePachinkoBall))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Ball not available");
			}
			PachinkoBall ball = activePachinkoBall.GetComponent<PachinkoBall>();
			if (!Object.op_Implicit((Object)(object)ball))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Ball not available");
			}
			Vector3 force = new Vector3(0f, 1800f, 0f);
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_0013: Unknown result type (might be due to invalid IL or missing references)
				//IL_0018: Unknown result type (might be due to invalid IL or missing references)
				//IL_0037: Unknown result type (might be due to invalid IL or missing references)
				//IL_003d: Expected O, but got Unknown
				//IL_0051: Unknown result type (might be due to invalid IL or missing references)
				//IL_0057: Expected O, but got Unknown
				try
				{
					((Component)ball).gameObject.GetComponent<Rigidbody2D>().AddForce(Vector2.op_Implicit(force));
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.PlayerDodgeSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse LaunchDown(ControlClient client, CrowdRequest req)
	{
		//IL_0010: Unknown result type (might be due to invalid IL or missing references)
		//IL_0016: Invalid comparison between Unknown and I4
		//IL_00ad: Unknown result type (might be due to invalid IL or missing references)
		//IL_00b2: Unknown result type (might be due to invalid IL or missing references)
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			if ((int)BattleController.CurrentBattleState == 2)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Ball not available");
			}
			GameObject activePachinkoBall = TestMod.battle.activePachinkoBall;
			if (!Object.op_Implicit((Object)(object)activePachinkoBall))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Ball not available");
			}
			PachinkoBall ball = activePachinkoBall.GetComponent<PachinkoBall>();
			if (!Object.op_Implicit((Object)(object)ball))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Ball not available");
			}
			Vector3 force = new Vector3(0f, -1800f, 0f);
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_0013: Unknown result type (might be due to invalid IL or missing references)
				//IL_0018: Unknown result type (might be due to invalid IL or missing references)
				//IL_0037: Unknown result type (might be due to invalid IL or missing references)
				//IL_003d: Expected O, but got Unknown
				//IL_0051: Unknown result type (might be due to invalid IL or missing references)
				//IL_0057: Expected O, but got Unknown
				try
				{
					((Component)ball).gameObject.GetComponent<Rigidbody2D>().AddForce(Vector2.op_Implicit(force));
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.PlayerDodgeSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse LaunchLeft(ControlClient client, CrowdRequest req)
	{
		//IL_0010: Unknown result type (might be due to invalid IL or missing references)
		//IL_0016: Invalid comparison between Unknown and I4
		//IL_00ad: Unknown result type (might be due to invalid IL or missing references)
		//IL_00b2: Unknown result type (might be due to invalid IL or missing references)
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			if ((int)BattleController.CurrentBattleState == 2)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Ball not available");
			}
			GameObject activePachinkoBall = TestMod.battle.activePachinkoBall;
			if (!Object.op_Implicit((Object)(object)activePachinkoBall))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Ball not available");
			}
			PachinkoBall ball = activePachinkoBall.GetComponent<PachinkoBall>();
			if (!Object.op_Implicit((Object)(object)ball))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Ball not available");
			}
			Vector3 force = new Vector3(-1800f, 0f, 0f);
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_0013: Unknown result type (might be due to invalid IL or missing references)
				//IL_0018: Unknown result type (might be due to invalid IL or missing references)
				//IL_0037: Unknown result type (might be due to invalid IL or missing references)
				//IL_003d: Expected O, but got Unknown
				//IL_0051: Unknown result type (might be due to invalid IL or missing references)
				//IL_0057: Expected O, but got Unknown
				try
				{
					((Component)ball).gameObject.GetComponent<Rigidbody2D>().AddForce(Vector2.op_Implicit(force));
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.PlayerDodgeSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse LaunchRight(ControlClient client, CrowdRequest req)
	{
		//IL_0010: Unknown result type (might be due to invalid IL or missing references)
		//IL_0016: Invalid comparison between Unknown and I4
		//IL_00ad: Unknown result type (might be due to invalid IL or missing references)
		//IL_00b2: Unknown result type (might be due to invalid IL or missing references)
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			if ((int)BattleController.CurrentBattleState == 2)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Ball not available");
			}
			GameObject activePachinkoBall = TestMod.battle.activePachinkoBall;
			if (!Object.op_Implicit((Object)(object)activePachinkoBall))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Ball not available");
			}
			PachinkoBall ball = activePachinkoBall.GetComponent<PachinkoBall>();
			if (!Object.op_Implicit((Object)(object)ball))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Ball not available");
			}
			Vector3 force = new Vector3(1800f, 0f, 0f);
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_0013: Unknown result type (might be due to invalid IL or missing references)
				//IL_0018: Unknown result type (might be due to invalid IL or missing references)
				//IL_0037: Unknown result type (might be due to invalid IL or missing references)
				//IL_003d: Expected O, but got Unknown
				//IL_0051: Unknown result type (might be due to invalid IL or missing references)
				//IL_0057: Expected O, but got Unknown
				try
				{
					((Component)ball).gameObject.GetComponent<Rigidbody2D>().AddForce(Vector2.op_Implicit(force));
					AudioSource val = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val2 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val.PlayOneShot(val2.PlayerDodgeSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse Multi(ControlClient client, CrowdRequest req)
	{
		//IL_0010: Unknown result type (might be due to invalid IL or missing references)
		//IL_0016: Invalid comparison between Unknown and I4
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			if ((int)BattleController.CurrentBattleState == 2)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Ball not available");
			}
			GameObject activePachinkoBall = TestMod.battle.activePachinkoBall;
			if (!Object.op_Implicit((Object)(object)activePachinkoBall))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Ball not available");
			}
			PachinkoBall ball = activePachinkoBall.GetComponent<PachinkoBall>();
			if (!Object.op_Implicit((Object)(object)ball))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Ball not available");
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_0019: Unknown result type (might be due to invalid IL or missing references)
				//IL_001e: Unknown result type (might be due to invalid IL or missing references)
				//IL_0022: Unknown result type (might be due to invalid IL or missing references)
				//IL_002c: Unknown result type (might be due to invalid IL or missing references)
				//IL_0031: Unknown result type (might be due to invalid IL or missing references)
				//IL_0044: Unknown result type (might be due to invalid IL or missing references)
				//IL_0049: Unknown result type (might be due to invalid IL or missing references)
				//IL_004a: Unknown result type (might be due to invalid IL or missing references)
				//IL_006b: Unknown result type (might be due to invalid IL or missing references)
				//IL_0071: Expected O, but got Unknown
				//IL_0085: Unknown result type (might be due to invalid IL or missing references)
				//IL_008c: Expected O, but got Unknown
				try
				{
					GameObject gameObject = ((Component)ball).gameObject;
					Vector3 right = ((Component)ball).transform.right;
					Vector3 val = ((Vector3)(ref right)).normalized * 1100f;
					GameObject val2 = ball.SpawnMultiballFromLocation(gameObject, ((Component)ball).transform.position, Vector2.op_Implicit(val), (Attack)null, true);
					AudioSource val3 = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val4 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val3.PlayOneShot(val4.PlayerDodgeSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse IncDamage10(ControlClient client, CrowdRequest req)
	{
		//IL_0010: Unknown result type (might be due to invalid IL or missing references)
		//IL_0016: Invalid comparison between Unknown and I4
		//IL_00ce: Unknown result type (might be due to invalid IL or missing references)
		//IL_00d5: Expected O, but got Unknown
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			if ((int)BattleController.CurrentBattleState == 2)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Ball not available");
			}
			GameObject activePachinkoBall = TestMod.battle.activePachinkoBall;
			if (!Object.op_Implicit((Object)(object)activePachinkoBall))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Ball not available");
			}
			PachinkoBall ball = activePachinkoBall.GetComponent<PachinkoBall>();
			if (!Object.op_Implicit((Object)(object)ball))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Ball not available");
			}
			int bonus = (int)getProperty(TestMod.battle, "_damageBonus");
			RelicManager val = (RelicManager)getProperty(TestMod.battle.PlayerHealthController, "_relicManager");
			float num = (float)getProperty(TestMod.battle, "_damageMultiplier");
			int num2 = (int)getProperty(TestMod.battle, "_pegMultiplierDamageTally");
			int pegs = (int)getProperty(TestMod.battle, "_numPegsHit");
			float damage = TestMod.battle.attackManager.GetCurrentDamage(num2, num, (long)bonus, BattleController.criticalHitCount, true);
			damage += 10f;
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_002f: Unknown result type (might be due to invalid IL or missing references)
				//IL_0035: Expected O, but got Unknown
				//IL_004e: Unknown result type (might be due to invalid IL or missing references)
				//IL_0063: Unknown result type (might be due to invalid IL or missing references)
				//IL_006d: Unknown result type (might be due to invalid IL or missing references)
				//IL_008d: Unknown result type (might be due to invalid IL or missing references)
				//IL_0093: Expected O, but got Unknown
				//IL_00a7: Unknown result type (might be due to invalid IL or missing references)
				//IL_00ad: Expected O, but got Unknown
				try
				{
					setProperty(TestMod.battle, "_damageBonus", bonus + 10);
					DamageCountDisplay val2 = (DamageCountDisplay)getProperty(TestMod.battle, "_damageCountDisplay");
					val2.DisplayDamage((long)damage, pegs, new Vector2(((Component)ball).transform.position.x, ((Component)ball).transform.position.y));
					AudioSource val3 = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val4 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val3.PlayOneShot(val4.PlayerHitSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse IncDamage50(ControlClient client, CrowdRequest req)
	{
		//IL_0010: Unknown result type (might be due to invalid IL or missing references)
		//IL_0016: Invalid comparison between Unknown and I4
		//IL_00ce: Unknown result type (might be due to invalid IL or missing references)
		//IL_00d5: Expected O, but got Unknown
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			if ((int)BattleController.CurrentBattleState == 2)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Ball not available");
			}
			GameObject activePachinkoBall = TestMod.battle.activePachinkoBall;
			if (!Object.op_Implicit((Object)(object)activePachinkoBall))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Ball not available");
			}
			PachinkoBall ball = activePachinkoBall.GetComponent<PachinkoBall>();
			if (!Object.op_Implicit((Object)(object)ball))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Ball not available");
			}
			int bonus = (int)getProperty(TestMod.battle, "_damageBonus");
			RelicManager val = (RelicManager)getProperty(TestMod.battle.PlayerHealthController, "_relicManager");
			float num = (float)getProperty(TestMod.battle, "_damageMultiplier");
			int num2 = (int)getProperty(TestMod.battle, "_pegMultiplierDamageTally");
			int pegs = (int)getProperty(TestMod.battle, "_numPegsHit");
			float damage = TestMod.battle.attackManager.GetCurrentDamage(num2, num, (long)bonus, BattleController.criticalHitCount, true);
			damage += 50f;
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_002f: Unknown result type (might be due to invalid IL or missing references)
				//IL_0035: Expected O, but got Unknown
				//IL_004e: Unknown result type (might be due to invalid IL or missing references)
				//IL_0063: Unknown result type (might be due to invalid IL or missing references)
				//IL_006d: Unknown result type (might be due to invalid IL or missing references)
				//IL_008c: Unknown result type (might be due to invalid IL or missing references)
				//IL_0092: Expected O, but got Unknown
				//IL_00a6: Unknown result type (might be due to invalid IL or missing references)
				//IL_00ac: Expected O, but got Unknown
				try
				{
					setProperty(TestMod.battle, "_damageBonus", bonus + 50);
					DamageCountDisplay val2 = (DamageCountDisplay)getProperty(TestMod.battle, "_damageCountDisplay");
					val2.DisplayDamage((long)damage, pegs, new Vector2(((Component)ball).transform.position.x, ((Component)ball).transform.position.y));
					AudioSource val3 = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val4 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val3.PlayOneShot(val4.PlayerHitSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse RemDamage10(ControlClient client, CrowdRequest req)
	{
		//IL_0010: Unknown result type (might be due to invalid IL or missing references)
		//IL_0016: Invalid comparison between Unknown and I4
		//IL_00ce: Unknown result type (might be due to invalid IL or missing references)
		//IL_00d5: Expected O, but got Unknown
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			if ((int)BattleController.CurrentBattleState == 2)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Ball not available");
			}
			GameObject activePachinkoBall = TestMod.battle.activePachinkoBall;
			if (!Object.op_Implicit((Object)(object)activePachinkoBall))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Ball not available");
			}
			PachinkoBall ball = activePachinkoBall.GetComponent<PachinkoBall>();
			if (!Object.op_Implicit((Object)(object)ball))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Ball not available");
			}
			int bonus = (int)getProperty(TestMod.battle, "_damageBonus");
			RelicManager val = (RelicManager)getProperty(TestMod.battle.PlayerHealthController, "_relicManager");
			float num = (float)getProperty(TestMod.battle, "_damageMultiplier");
			int num2 = (int)getProperty(TestMod.battle, "_pegMultiplierDamageTally");
			int pegs = (int)getProperty(TestMod.battle, "_numPegsHit");
			float damage = TestMod.battle.attackManager.GetCurrentDamage(num2, num, (long)bonus, BattleController.criticalHitCount, true);
			if (damage <= 0f)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "No damage to reduce");
			}
			if (damage < 10f)
			{
				bonus += (int)(10f - damage);
				damage = 0f;
			}
			else
			{
				damage -= 10f;
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_002f: Unknown result type (might be due to invalid IL or missing references)
				//IL_0035: Expected O, but got Unknown
				//IL_004e: Unknown result type (might be due to invalid IL or missing references)
				//IL_0063: Unknown result type (might be due to invalid IL or missing references)
				//IL_006d: Unknown result type (might be due to invalid IL or missing references)
				//IL_008c: Unknown result type (might be due to invalid IL or missing references)
				//IL_0092: Expected O, but got Unknown
				//IL_00a6: Unknown result type (might be due to invalid IL or missing references)
				//IL_00ac: Expected O, but got Unknown
				try
				{
					setProperty(TestMod.battle, "_damageBonus", bonus - 10);
					DamageCountDisplay val2 = (DamageCountDisplay)getProperty(TestMod.battle, "_damageCountDisplay");
					val2.DisplayDamage((long)damage, pegs, new Vector2(((Component)ball).transform.position.x, ((Component)ball).transform.position.y));
					AudioSource val3 = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val4 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val3.PlayOneShot(val4.PlayerHitSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse RemDamage50(ControlClient client, CrowdRequest req)
	{
		//IL_0010: Unknown result type (might be due to invalid IL or missing references)
		//IL_0016: Invalid comparison between Unknown and I4
		//IL_00ce: Unknown result type (might be due to invalid IL or missing references)
		//IL_00d5: Expected O, but got Unknown
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			if ((int)BattleController.CurrentBattleState == 2)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Ball not available");
			}
			GameObject activePachinkoBall = TestMod.battle.activePachinkoBall;
			if (!Object.op_Implicit((Object)(object)activePachinkoBall))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Ball not available");
			}
			PachinkoBall ball = activePachinkoBall.GetComponent<PachinkoBall>();
			if (!Object.op_Implicit((Object)(object)ball))
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "Ball not available");
			}
			int bonus = (int)getProperty(TestMod.battle, "_damageBonus");
			RelicManager val = (RelicManager)getProperty(TestMod.battle.PlayerHealthController, "_relicManager");
			float num = (float)getProperty(TestMod.battle, "_damageMultiplier");
			int num2 = (int)getProperty(TestMod.battle, "_pegMultiplierDamageTally");
			int pegs = (int)getProperty(TestMod.battle, "_numPegsHit");
			float damage = TestMod.battle.attackManager.GetCurrentDamage(num2, num, (long)bonus, BattleController.criticalHitCount, true);
			if (damage <= 0f)
			{
				return new CrowdResponse(req.GetReqID(), CrowdResponse.Status.STATUS_RETRY, "No damage to reduce");
			}
			if (damage < 50f)
			{
				bonus += (int)(50f - damage);
				damage = 0f;
			}
			else
			{
				damage -= 50f;
			}
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_002f: Unknown result type (might be due to invalid IL or missing references)
				//IL_0035: Expected O, but got Unknown
				//IL_004e: Unknown result type (might be due to invalid IL or missing references)
				//IL_0063: Unknown result type (might be due to invalid IL or missing references)
				//IL_006d: Unknown result type (might be due to invalid IL or missing references)
				//IL_008d: Unknown result type (might be due to invalid IL or missing references)
				//IL_0093: Expected O, but got Unknown
				//IL_00a7: Unknown result type (might be due to invalid IL or missing references)
				//IL_00ad: Expected O, but got Unknown
				try
				{
					setProperty(TestMod.battle, "_damageBonus", bonus - 50);
					DamageCountDisplay val2 = (DamageCountDisplay)getProperty(TestMod.battle, "_damageCountDisplay");
					val2.DisplayDamage((long)damage, pegs, new Vector2(((Component)ball).transform.position.x, ((Component)ball).transform.position.y));
					AudioSource val3 = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val4 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val3.PlayOneShot(val4.PlayerHitSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch (Exception ex)
		{
			TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex.ToString()));
		}
		return new CrowdResponse(req.GetReqID(), status, message);
	}

	public static CrowdResponse Orb1(ControlClient client, CrowdRequest req)
	{
		CrowdResponse.Status status = CrowdResponse.Status.STATUS_SUCCESS;
		string message = "";
		try
		{
			TestMod.ActionQueue.Enqueue(delegate
			{
				//IL_0011: Unknown result type (might be due to invalid IL or missing references)
				//IL_0017: Expected O, but got Unknown
				//IL_005b: Unknown result type (might be due to invalid IL or missing references)
				//IL_0061: Expected O, but got Unknown
				//IL_0075: Unknown result type (might be due to invalid IL or missing references)
				//IL_007c: Expected O, but got Unknown
				try
				{
					DeckManager val = (DeckManager)getProperty(TestMod.battle, "_deckManager");
					GameObject[] array = val.CommonOrbPool.ToArray();
					GameObject val2 = array[TestMod.rnd.Next(0, array.Count())];
					val.AddOrbToDeck(val2);
					val.ShuffleCompleteDeck(true);
					AudioSource val3 = (AudioSource)getProperty(TestMod.battle.PlayerHealthController, "_sfxSource");
					PlayerSfx val4 = (PlayerSfx)getProperty(TestMod.battle.PlayerHealthController, "_playerSfx");
					val3.PlayOneShot(val4.LootRewardSfx);
				}
				catch (Exception ex2)
				{
					TestMod.mls.LogInfo((object)("Crowd Control Error: " + ex2.ToString()));
				}
			});
		}
		catch