Decompiled source of FentoKill v1.3.89

FentoKill.dll

Decompiled 2 weeks ago
using System;
using System.Collections;
using System.Collections.Generic;
using System.Diagnostics;
using System.IO;
using System.Linq;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.InteropServices;
using System.Runtime.Versioning;
using BepInEx;
using BepInEx.Logging;
using HarmonyLib;
using PluginConfig.API;
using PluginConfig.API.Decorators;
using PluginConfig.API.Fields;
using TMPro;
using UnityEngine;
using UnityEngine.AI;
using UnityEngine.InputSystem;
using UnityEngine.SceneManagement;
using UnityEngine.UI;

[assembly: CompilationRelaxations(8)]
[assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)]
[assembly: Debuggable(DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints)]
[assembly: AssemblyTitle("FentoKill")]
[assembly: AssemblyDescription("")]
[assembly: AssemblyConfiguration("")]
[assembly: AssemblyCompany("")]
[assembly: AssemblyProduct("FentoKill")]
[assembly: AssemblyCopyright("Copyright ©  2025")]
[assembly: AssemblyTrademark("")]
[assembly: ComVisible(false)]
[assembly: Guid("d24676a8-4da0-4d43-a77a-48484b462e3c")]
[assembly: AssemblyFileVersion("1.0.0.0")]
[assembly: TargetFramework(".NETFramework,Version=v4.7.2", FrameworkDisplayName = ".NET Framework 4.7.2")]
[assembly: AssemblyVersion("1.0.0.0")]
namespace FentoKill;

public static class Fento_Utils
{
	public enum DetectebleEnemies
	{
		Super_Projectile_Zombie,
		Minotaur,
		Body,
		MinosBoss,
		DroneSkull_Variant,
		Guttertank,
		Zombie,
		Mandalore,
		Gutterman,
		Gabriel,
		V2,
		Big_Johninator,
		DroneFlesh,
		Gabriel_2nd_Variant,
		Flesh_Prison,
		Turret,
		Streetcleaner,
		Virtue,
		DroneFleshCamera_Variant,
		Wicked,
		MinosPrime,
		ShotgunHusk,
		Ferryman,
		Mindflayer,
		Sisyphus,
		Idol,
		Drone,
		CentaurMortar,
		Mannequin,
		Projectile_Zombie,
		CentaurTower,
		Puppet,
		SisyphusPrime,
		Very_Cancerous_Rodent,
		V2_Green_Arm_Variant,
		Stalker,
		Cancerous_Rodent,
		Mass,
		CentaurRocketLauncher,
		Flesh_Prison_2,
		SwordsMachineNonboss,
		Cerberus
	}

	public struct PathObject
	{
		public string path;

		public GameObject obj;

		public GameObject Object
		{
			get
			{
				if ((Object)(object)obj == (Object)null)
				{
					obj = FindObjectByPath(path);
				}
				return obj;
			}
		}

		public Transform[] childs => GetAllChilds(transform);

		public Transform transform
		{
			get
			{
				if ((Object)(object)Object != (Object)null)
				{
					return Object.transform;
				}
				return null;
			}
		}

		public GameObject gameObject => Object;

		public T GetComponent<T>()
		{
			if ((Object)(object)Object != (Object)null)
			{
				return Object.GetComponent<T>();
			}
			return default(T);
		}

		public Transform GetChild(int id)
		{
			if ((Object)(object)transform != (Object)null)
			{
				return transform.GetChild(id);
			}
			return null;
		}

		public PathObject(string path)
		{
			this.path = path;
			obj = null;
		}

		public static implicit operator PathObject(string path)
		{
			return new PathObject(path);
		}

		public static explicit operator GameObject(PathObject entry)
		{
			return entry.Object;
		}

		public override string ToString()
		{
			return path;
		}
	}

	[CompilerGenerated]
	private sealed class <Delay_Coroutine>d__3 : IEnumerator<object>, IDisposable, IEnumerator
	{
		private int <>1__state;

		private object <>2__current;

		public float time;

		public Action action;

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

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

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

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

		private bool MoveNext()
		{
			//IL_001e: Unknown result type (might be due to invalid IL or missing references)
			//IL_0028: Expected O, but got Unknown
			switch (<>1__state)
			{
			default:
				return false;
			case 0:
				<>1__state = -1;
				<>2__current = (object)new WaitForSeconds(time);
				<>1__state = 1;
				return true;
			case 1:
				<>1__state = -1;
				try
				{
					action?.Invoke();
				}
				catch
				{
					Fento_Loader._Logger.LogError((object)"NextFrameCoroutine - Error Detected");
				}
				return false;
			}
		}

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

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

	[CompilerGenerated]
	private sealed class <Next_FrameCoroutine>d__2 : IEnumerator<object>, IDisposable, IEnumerator
	{
		private int <>1__state;

		private object <>2__current;

		public Action action;

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

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

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

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

		private bool MoveNext()
		{
			//IL_0018: Unknown result type (might be due to invalid IL or missing references)
			//IL_0022: Expected O, but got Unknown
			switch (<>1__state)
			{
			default:
				return false;
			case 0:
				<>1__state = -1;
				<>2__current = (object)new WaitForEndOfFrame();
				<>1__state = 1;
				return true;
			case 1:
				<>1__state = -1;
				try
				{
					action?.Invoke();
				}
				catch
				{
					Fento_Loader._Logger.LogError((object)"NextFrameCoroutine - Error Detected");
				}
				return false;
			}
		}

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

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

	public static Type DetectEnemyType = typeof(DetectebleEnemies);

	public static EnemyIdentifier[] AllEnemies = (EnemyIdentifier[])(object)new EnemyIdentifier[0];

	public static void Invoke_NextFrame(Action action)
	{
		//IL_0005: Unknown result type (might be due to invalid IL or missing references)
		//IL_000a: Unknown result type (might be due to invalid IL or missing references)
		//IL_0015: Expected O, but got Unknown
		//IL_001a: Expected O, but got Unknown
		GameObject val = new GameObject("Wait And LOader");
		Object.Destroy((Object)val, 1f);
		((MonoBehaviour)GameObjectExtensions.GetOrAddComponent<Fento_DontLoop_Tag>(val)).StartCoroutine(Next_FrameCoroutine(action));
	}

	public static void Invoke_WithDelay(float time, Action action)
	{
		//IL_0005: Unknown result type (might be due to invalid IL or missing references)
		//IL_000a: Unknown result type (might be due to invalid IL or missing references)
		//IL_0015: Expected O, but got Unknown
		//IL_001a: Expected O, but got Unknown
		GameObject val = new GameObject("Wait And LOader");
		Object.Destroy((Object)val, 1f);
		((MonoBehaviour)GameObjectExtensions.GetOrAddComponent<Fento_DontLoop_Tag>(val)).StartCoroutine(Delay_Coroutine(time, action));
	}

	[IteratorStateMachine(typeof(<Next_FrameCoroutine>d__2))]
	public static IEnumerator Next_FrameCoroutine(Action action)
	{
		//yield-return decompiler failed: Unexpected instruction in Iterator.Dispose()
		return new <Next_FrameCoroutine>d__2(0)
		{
			action = action
		};
	}

	[IteratorStateMachine(typeof(<Delay_Coroutine>d__3))]
	public static IEnumerator Delay_Coroutine(float time, Action action)
	{
		//yield-return decompiler failed: Unexpected instruction in Iterator.Dispose()
		return new <Delay_Coroutine>d__3(0)
		{
			time = time,
			action = action
		};
	}

	public static void Forse_Clear()
	{
		//IL_0014: Unknown result type (might be due to invalid IL or missing references)
		//IL_0019: Unknown result type (might be due to invalid IL or missing references)
		//IL_0029: Unknown result type (might be due to invalid IL or missing references)
		//IL_002e: Unknown result type (might be due to invalid IL or missing references)
		ActivateArena[] array = Resources.FindObjectsOfTypeAll<ActivateArena>();
		foreach (ActivateArena val in array)
		{
			Scene scene = ((Component)val).gameObject.scene;
			if (((Scene)(ref scene)).IsValid())
			{
				scene = ((Component)val).gameObject.scene;
				if (((Scene)(ref scene)).isLoaded)
				{
					Fento_Loader._Logger.LogInfo((object)("Forse_Clear - " + ((Object)((Component)val).transform).name + " ActivateArena Cleared From Nulls"));
					val.enemies = val.enemies.RemoveDestroyed().ToArray();
				}
			}
		}
	}

	public static void Set_HudMessage(this HudMessage hudMessage, string message, string message2 = "", InputActionReference actionReference = null)
	{
		if ((Object)(object)hudMessage == (Object)null)
		{
			Fento_Loader._Logger.LogError((object)"Set_HudMessage - hudMessage is null");
			return;
		}
		hudMessage.message = message;
		hudMessage.message2 = message2;
		hudMessage.actionReference = actionReference;
	}

	public static void For_InStack(Transform GetFrom, Action<Transform> action)
	{
		Transform[] allChilds = GetAllChilds(GetFrom);
		foreach (Transform obj in allChilds)
		{
			action?.Invoke(obj);
		}
	}

	public static void Enemy_InStack(Transform GetFrom, Action<EnemyIdentifier> action, bool Hard_Mode_Only = false)
	{
		if (Hard_Mode_Only && Difficulty_Options.Issue_Disable_Most_Buffs)
		{
			return;
		}
		Transform[] allChilds = GetAllChilds(GetFrom);
		if (allChilds == null)
		{
			return;
		}
		Transform[] array = allChilds;
		for (int i = 0; i < array.Length; i++)
		{
			EnemyIdentifier component = ((Component)array[i]).GetComponent<EnemyIdentifier>();
			if ((Object)(object)component != (Object)null)
			{
				action?.Invoke(component);
			}
		}
	}

	public static void Make_List_MachineSymbiote(List<Machine> machines)
	{
		if (machines == null || machines.Count < 2)
		{
			Fento_Loader._Logger.LogWarning((object)"Make_List_MachineSymbiote - Need More Machines To Make Symbiotes");
			return;
		}
		for (int i = 0; i < machines.Count; i++)
		{
			Machine toMake = machines[i];
			Machine symbiote = machines[(i + 1) % machines.Count];
			Make_MachineSymbiote(toMake, symbiote);
		}
	}

	public static void Make_MachineSymbiote(Machine toMake, Machine symbiote)
	{
		if ((Object)(object)toMake == (Object)null)
		{
			Fento_Loader._Logger.LogWarning((object)"Make_MachineSymbiote - No toMake");
			return;
		}
		if ((Object)(object)symbiote == (Object)null)
		{
			Fento_Loader._Logger.LogWarning((object)"Make_MachineSymbiote - No symbiote");
			return;
		}
		if (Difficulty_Options.Mech_Disable_Custom_Symbiotes)
		{
			Fento_Loader._Logger.LogInfo((object)$"Make_MachineSymbiote - {toMake} + {symbiote} Disabled From - Difficulty_Options.Disable_Custom_Symbiotes");
			return;
		}
		toMake.symbiote = symbiote;
		Fento_Loader._Logger.LogInfo((object)$"Make_MachineSymbiote - New Symbiot Pair: {toMake} + {symbiote}");
	}

	public static void Clear_AreaFromClones(Transform ToClear)
	{
		Enemy_InStack(ToClear, delegate(EnemyIdentifier enemy)
		{
			if (!Object.op_Implicit((Object)(object)((Component)enemy).GetComponent<Fento_DontLoop_Tag>()))
			{
				Object.Destroy((Object)(object)((Component)enemy).gameObject);
			}
		});
	}

	public static void Update_ActivateNextWave(ActivateNextWave activateNextWave, Transform GetFrom = null)
	{
		if ((Object)(object)GetFrom == (Object)null)
		{
			GetFrom = ((Component)activateNextWave).transform;
		}
		List<GameObject> list = new List<GameObject>();
		for (int i = 0; i < GetFrom.childCount; i++)
		{
			Transform child = GetFrom.GetChild(i);
			if (Object.op_Implicit((Object)(object)((Component)child).GetComponent<EnemyIdentifier>()))
			{
				list.Add(((Component)child).gameObject);
			}
		}
		activateNextWave.toActivate = list.ToArray();
	}

	public static void Update_ActivateArena(ActivateArena activateArena, Transform GetFrom = null)
	{
		if ((Object)(object)GetFrom == (Object)null)
		{
			GetFrom = ((Component)activateArena).transform;
		}
		List<GameObject> list = new List<GameObject>();
		for (int i = 0; i < GetFrom.childCount; i++)
		{
			Transform child = GetFrom.GetChild(i);
			if (Object.op_Implicit((Object)(object)((Component)child).GetComponent<EnemyIdentifier>()) || Object.op_Implicit((Object)(object)((Component)child).GetComponent<Fento_DontLoop_Tag>()))
			{
				list.Add(((Component)child).gameObject);
			}
		}
		activateArena.enemies = list.ToArray();
	}

	public static EnemyIdentifier Custom_ReplaceEnemy(DetectebleEnemies enemy, Transform toReplace, Vector3 Pos = default(Vector3), Quaternion Quart = default(Quaternion), bool active = false, bool DestroyOnReplace = true)
	{
		//IL_0018: Unknown result type (might be due to invalid IL or missing references)
		//IL_0019: Unknown result type (might be due to invalid IL or missing references)
		if (Object.op_Implicit((Object)(object)((Component)toReplace).GetComponent<Fento_DontLoop_Tag>()))
		{
			return null;
		}
		EnemyIdentifier result = Integrate_Enemy(enemy, toReplace.parent, active, Pos, Quart);
		if (DestroyOnReplace)
		{
			Object.Destroy((Object)(object)((Component)toReplace).gameObject);
		}
		return result;
	}

	public static EnemyIdentifier Base_ReplaceEnemy(DetectebleEnemies enemy, Transform toReplace, Vector3 extraPos = default(Vector3), bool DestroyOnReplace = true)
	{
		//IL_0022: Unknown result type (might be due to invalid IL or missing references)
		//IL_0027: 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: Unknown result type (might be due to invalid IL or missing references)
		if (Object.op_Implicit((Object)(object)((Component)toReplace).GetComponent<Fento_DontLoop_Tag>()))
		{
			return null;
		}
		EnemyIdentifier result = Integrate_Enemy(enemy, toReplace.parent, ((Component)toReplace).gameObject.activeSelf, toReplace.position + extraPos, toReplace.rotation);
		if (DestroyOnReplace)
		{
			Object.Destroy((Object)(object)((Component)toReplace).gameObject);
		}
		return result;
	}

	public static EnemyIdentifier Integrate_Enemy(DetectebleEnemies enemy, Transform Parent, bool active, Vector3 Pos = default(Vector3), Quaternion Quart = default(Quaternion))
	{
		//IL_0007: Unknown result type (might be due to invalid IL or missing references)
		//IL_0008: Unknown result type (might be due to invalid IL or missing references)
		EnemyIdentifier obj = FindEnemyByType(enemy);
		GameObject gameObject = ((Component)Object.Instantiate<EnemyIdentifier>(obj, Pos, Quart)).gameObject;
		gameObject.transform.parent = Parent;
		gameObject.SetActive(active);
		GameObjectExtensions.GetOrAddComponent<Fento_DontLoop_Tag>(gameObject);
		KeepInBounds component = gameObject.GetComponent<KeepInBounds>();
		if (Object.op_Implicit((Object)(object)component))
		{
			Object.Destroy((Object)(object)component);
		}
		NavMeshAgent component2 = gameObject.GetComponent<NavMeshAgent>();
		if (Object.op_Implicit((Object)(object)component2))
		{
			((Behaviour)component2).enabled = true;
		}
		return obj;
	}

	public static string ParseRealName(string input)
	{
		return input?.Replace('_', ' ');
	}

	public static EnemyIdentifier FindEnemyByType(DetectebleEnemies enemy)
	{
		string realName = ParseRealName(Enum.GetName(DetectEnemyType, enemy));
		return AllEnemies.Where((EnemyIdentifier o) => ((Object)o).name == realName).FirstOrDefault();
	}

	public static GameObject FindEnemyByName(string name)
	{
		return Fento_Core.AllObjs.Where((GameObject o) => (Object)(object)o != (Object)null && ((Object)o).name == name && o.scene != Fento_Core.CurrentScene && Object.op_Implicit((Object)(object)o.GetComponent<EnemyIdentifier>())).FirstOrDefault();
	}

	public static GameObject FindObjectByPath(string path)
	{
		string[] array = path.Split(new char[1] { '/' });
		if (array.Length == 0)
		{
			return null;
		}
		GameObject val = FindObjectByDirectPath(path);
		if ((Object)(object)val != (Object)null)
		{
			return val;
		}
		return FindObjectByStepwisePath(array);
	}

	public static string GetFullRootPath(Transform transform)
	{
		string text = ((Object)transform).name;
		while ((Object)(object)transform.parent != (Object)null)
		{
			transform = transform.parent;
			text = ((Object)transform).name + "/" + text;
		}
		return text;
	}

	[Obsolete]
	private static GameObject FindObjectByDirectPath(string path)
	{
		GameObject obj = GameObject.Find(path);
		if ((Object)(object)obj == (Object)null)
		{
			Fento_Loader._Logger.LogWarning((object)("Direct Search - Object not found with path: " + path));
		}
		return obj;
	}

	[Obsolete]
	private static GameObject FindObjectByStepwisePath(string[] pathParts)
	{
		//IL_001a: Unknown result type (might be due to invalid IL or missing references)
		//IL_001f: Unknown result type (might be due to invalid IL or missing references)
		//IL_002b: Unknown result type (might be due to invalid IL or missing references)
		//IL_0030: Unknown result type (might be due to invalid IL or missing references)
		GameObject val = null;
		GameObject[] allObjs = Fento_Core.AllObjs;
		foreach (GameObject val2 in allObjs)
		{
			if ((Object)(object)val2 == (Object)null)
			{
				continue;
			}
			Scene scene = val2.scene;
			if (((Scene)(ref scene)).IsValid())
			{
				scene = val2.scene;
				if (((Scene)(ref scene)).isLoaded && ((Object)val2).name == pathParts[0])
				{
					val = val2;
					break;
				}
			}
		}
		if ((Object)(object)val == (Object)null)
		{
			Fento_Loader._Logger.LogWarning((object)("FindObjectByStepwisePath - Root not found: " + pathParts[0]));
			return null;
		}
		return FindObjectByPathInHierarchy(val, pathParts, 1);
	}

	[Obsolete]
	private static GameObject FindObjectByPathInHierarchy(GameObject parent, string[] pathParts, int index)
	{
		//IL_001c: Unknown result type (might be due to invalid IL or missing references)
		//IL_0022: Expected O, but got Unknown
		if (index >= pathParts.Length)
		{
			return parent;
		}
		foreach (Transform item in parent.transform)
		{
			Transform val = item;
			if (((Object)val).name == pathParts[index])
			{
				GameObject val2 = FindObjectByPathInHierarchy(((Component)val).gameObject, pathParts, index + 1);
				if ((Object)(object)val2 != (Object)null)
				{
					return val2;
				}
			}
		}
		return null;
	}

	public static Transform[] GetAllChilds(Transform GetFrom)
	{
		//IL_0020: Unknown result type (might be due to invalid IL or missing references)
		//IL_0026: Expected O, but got Unknown
		if ((Object)(object)GetFrom == (Object)null)
		{
			return null;
		}
		List<Transform> list = new List<Transform>();
		foreach (Transform item2 in GetFrom)
		{
			Transform item = item2;
			list.Add(item);
		}
		return list.ToArray();
	}

	public static void AddCount(this ref int i, bool[] toCount)
	{
		for (int j = 0; j < toCount.Length; j++)
		{
			if (toCount[j])
			{
				i++;
			}
		}
	}

	public static T[] Append<T>(this T[] array, T item)
	{
		if (array == null)
		{
			return new T[1] { item };
		}
		T[] array2 = new T[array.Length + 1];
		array.CopyTo(array2, 0);
		array2[array.Length] = item;
		return array2;
	}

	public static IEnumerable<GameObject> RemoveDestroyed(this IEnumerable<GameObject> array)
	{
		List<GameObject> list = array.ToList();
		list.RemoveAll(delegate(GameObject obj)
		{
			//IL_000a: Unknown result type (might be due to invalid IL or missing references)
			//IL_000f: Unknown result type (might be due to invalid IL or missing references)
			//IL_001a: Unknown result type (might be due to invalid IL or missing references)
			//IL_001f: Unknown result type (might be due to invalid IL or missing references)
			if (!((Object)(object)obj == (Object)null))
			{
				Scene scene = obj.scene;
				if (((Scene)(ref scene)).IsValid())
				{
					scene = obj.scene;
					return !((Scene)(ref scene)).isLoaded;
				}
			}
			return true;
		});
		return list;
	}

	public static IEnumerable<T> RemoveNulls<T>(this IEnumerable<T> array)
	{
		List<T> list = array.ToList();
		list.RemoveAll((T l) => l == null);
		return list;
	}

	public static bool Try_GetFrom_Config(BoolField boolField, bool regular = false)
	{
		if (boolField != null)
		{
			return boolField.value;
		}
		return regular;
	}

	public static float Try_GetFrom_Config(FloatField floatField, float regular = 1f)
	{
		if (floatField != null)
		{
			return floatField.value;
		}
		return regular;
	}
}
[BepInPlugin("com.notalaser.fentokill", "FentoKill", "1.3.89")]
public class Fento_Loader : BaseUnityPlugin
{
	public const string GUID = "com.notalaser.fentokill";

	public const string Name = "FentoKill";

	public const string Version = "1.3.89";

	private Harmony _Harmony = new Harmony("com.notalaser.fentokill.levelpatches");

	public static ManualLogSource _Logger;

	public const string Set_Guid = "com.notalaser.fentokill.settings";

	public PluginConfigurator config;

	public bool Confing_Loaded;

	public void Awake()
	{
		//IL_0090: Unknown result type (might be due to invalid IL or missing references)
		//IL_00a1: Unknown result type (might be due to invalid IL or missing references)
		//IL_00a6: Unknown result type (might be due to invalid IL or missing references)
		//IL_00c2: Unknown result type (might be due to invalid IL or missing references)
		//IL_00db: Unknown result type (might be due to invalid IL or missing references)
		//IL_00e0: Unknown result type (might be due to invalid IL or missing references)
		//IL_00fc: Unknown result type (might be due to invalid IL or missing references)
		//IL_0105: Unknown result type (might be due to invalid IL or missing references)
		//IL_010a: Unknown result type (might be due to invalid IL or missing references)
		//IL_0126: Unknown result type (might be due to invalid IL or missing references)
		//IL_013c: Unknown result type (might be due to invalid IL or missing references)
		//IL_0141: Unknown result type (might be due to invalid IL or missing references)
		//IL_0161: Unknown result type (might be due to invalid IL or missing references)
		//IL_016b: Expected O, but got Unknown
		//IL_0181: Unknown result type (might be due to invalid IL or missing references)
		//IL_018b: Expected O, but got Unknown
		//IL_019d: Unknown result type (might be due to invalid IL or missing references)
		//IL_01b3: Unknown result type (might be due to invalid IL or missing references)
		//IL_01b8: Unknown result type (might be due to invalid IL or missing references)
		//IL_01d8: Unknown result type (might be due to invalid IL or missing references)
		//IL_01e2: Expected O, but got Unknown
		//IL_01f8: Unknown result type (might be due to invalid IL or missing references)
		//IL_0202: Expected O, but got Unknown
		//IL_0218: Unknown result type (might be due to invalid IL or missing references)
		//IL_0222: Expected O, but got Unknown
		//IL_023c: Unknown result type (might be due to invalid IL or missing references)
		//IL_0246: Expected O, but got Unknown
		//IL_0260: Unknown result type (might be due to invalid IL or missing references)
		//IL_026a: Expected O, but got Unknown
		//IL_0284: Unknown result type (might be due to invalid IL or missing references)
		//IL_028e: Expected O, but got Unknown
		//IL_02a0: Unknown result type (might be due to invalid IL or missing references)
		//IL_02b2: Unknown result type (might be due to invalid IL or missing references)
		//IL_02b7: Unknown result type (might be due to invalid IL or missing references)
		//IL_02d7: Unknown result type (might be due to invalid IL or missing references)
		//IL_02e1: Expected O, but got Unknown
		//IL_02f7: Unknown result type (might be due to invalid IL or missing references)
		//IL_0301: Expected O, but got Unknown
		//IL_0317: Unknown result type (might be due to invalid IL or missing references)
		//IL_0321: Expected O, but got Unknown
		//IL_0333: Unknown result type (might be due to invalid IL or missing references)
		//IL_0348: Unknown result type (might be due to invalid IL or missing references)
		//IL_034d: Unknown result type (might be due to invalid IL or missing references)
		//IL_036d: Unknown result type (might be due to invalid IL or missing references)
		//IL_0377: Expected O, but got Unknown
		//IL_038d: Unknown result type (might be due to invalid IL or missing references)
		//IL_0397: Expected O, but got Unknown
		//IL_03a9: Unknown result type (might be due to invalid IL or missing references)
		//IL_03bc: Unknown result type (might be due to invalid IL or missing references)
		//IL_03c1: Unknown result type (might be due to invalid IL or missing references)
		//IL_03e5: Unknown result type (might be due to invalid IL or missing references)
		//IL_03ef: Expected O, but got Unknown
		//IL_0409: Unknown result type (might be due to invalid IL or missing references)
		//IL_0413: Expected O, but got Unknown
		//IL_042d: Unknown result type (might be due to invalid IL or missing references)
		//IL_0437: Expected O, but got Unknown
		_Logger = ((BaseUnityPlugin)this).Logger;
		_Logger.LogInfo((object)"Fento_Loader v1.3.89 has started.");
		try
		{
			config = PluginConfigurator.Create("FENTOKILL", "com.notalaser.fentokill.settings");
			string text = Path.Combine(Path.GetDirectoryName(typeof(Fento_Loader).Assembly.Location), "icon.png");
			_Logger.LogInfo((object)$"Fento Icon Path {text}");
			config.SetIconWithURL("file://" + text);
			new ConfigHeader(config.rootPanel, "SOME CHANGES REQUIRE LEVEL RESTART", 24).textColor = Color32.op_Implicit(new Color32(byte.MaxValue, (byte)0, (byte)0, byte.MaxValue));
			new ConfigHeader(config.rootPanel, "They will be marked with <color=#FF0000>+</color>", 24).textColor = Color32.op_Implicit(new Color32(byte.MaxValue, byte.MaxValue, byte.MaxValue, byte.MaxValue));
			new ConfigHeader(config.rootPanel, "     ", 24).textColor = Color32.op_Implicit(new Color32((byte)0, (byte)0, (byte)0, (byte)0));
			new ConfigHeader(config.rootPanel, "Main / Global Settings", 24).textColor = Color32.op_Implicit(new Color32((byte)105, (byte)172, byte.MaxValue, byte.MaxValue));
			Difficulty_Options.B__Global_Disable_Level_Changes = new BoolField(config.rootPanel, "Disable Level Changes<color=#FF0000>+</color>", "com.notalaser.fentokill.settings.B__Global_Disable_Level_Changes", false);
			Difficulty_Options.B__Global_Enable_Modify_Everyone = new BoolField(config.rootPanel, "Modify Every Enemy With Changes Below", "com.notalaser.fentokill.settings.B__Global_Enable_Modify_Everyone", false);
			new ConfigHeader(config.rootPanel, "Extra Respected Difficulty Options", 24).textColor = Color32.op_Implicit(new Color32(byte.MaxValue, (byte)158, (byte)105, byte.MaxValue));
			Difficulty_Options.B__Res_Forse_All_ImmuneFriendly = new BoolField(config.rootPanel, "Make Friendly Fire Weaker", "com.notalaser.fentokill.settings.B__Res_Forse_All_ImmuneFriendly", false);
			Difficulty_Options.B__Res_Forse_All_PreSanded = new BoolField(config.rootPanel, "Make Every Enemy Pre Sanded", "com.notalaser.fentokill.settings.B__Res_Forse_All_PreSanded", false);
			Difficulty_Options.B__Res_Forse_All_Radiance = new BoolField(config.rootPanel, "Make Every Enemy Radiant", "com.notalaser.fentokill.settings.B__Res_Forse_All_Radiance", false);
			Difficulty_Options.V__Varb_Multiply_HardDamage = new FloatField(config.rootPanel, "Change Hard Damage Multiplier", "com.notalaser.fentokill.settings.V__Varb_Multiply_HardDamage", 1f);
			Difficulty_Options.V__Varb_Multiply_Radiance_Tier = new FloatField(config.rootPanel, "Change Radiance Tier Multiplier", "com.notalaser.fentokill.settings.V__Varb_Multiply_Radiance_Tier", 1f);
			Difficulty_Options.V__Varb_Add_Radiance_Tier = new FloatField(config.rootPanel, "Add Extra Radiance Tier", "com.notalaser.fentokill.settings.V__Varb_Add_Radiance_Tier", 0f);
			new ConfigHeader(config.rootPanel, "Skill Issue Options", 24).textColor = Color32.op_Implicit(new Color32((byte)61, (byte)204, (byte)0, byte.MaxValue));
			Difficulty_Options.B__Issue_Disable_Most_Buffs = new BoolField(config.rootPanel, "Disable Most Fento Buffs<color=#FF0000>+</color>", "com.notalaser.fentokill.settings.B__Issue_Disable_Most_Buffs", false);
			Difficulty_Options.B__Issue_Disable_PreSanded = new BoolField(config.rootPanel, "Disable Pre Sanded Buff", "com.notalaser.fentokill.settings.B__Issue_Disable_PreSanded", false);
			Difficulty_Options.B__Issue_Disable_Radiance = new BoolField(config.rootPanel, "Disable Radiance Buff", "com.notalaser.fentokill.settings.B__Issue_Disable_Radiance", false);
			new ConfigHeader(config.rootPanel, "Fento Custom Mechanics Options", 24).textColor = Color32.op_Implicit(new Color32((byte)0, (byte)204, (byte)132, byte.MaxValue));
			Difficulty_Options.B__Mech_Disable_RadIdols_Buff = new BoolField(config.rootPanel, "Disable Rad Idols <color=#89FFFF>INCREASE RADIANCE</color>", "com.notalaser.fentokill.settings.B__Mech_Disable_RadIdols_Buff", false);
			Difficulty_Options.B__Mech_Disable_Custom_Symbiotes = new BoolField(config.rootPanel, "Disable <color=#89FFFF>UNIQUE SYMBIOTIC PAIRS</color><color=#FF0000>+</color>", "com.notalaser.fentokill.settings.B__Mech_Disable_Custom_Symbiotes", false);
			new ConfigHeader(config.rootPanel, "Extra Radiance Options", 24).textColor = Color32.op_Implicit(new Color32((byte)93, (byte)74, (byte)186, byte.MaxValue));
			Difficulty_Options.V__Varb_Radiance_Health_Mult = new FloatField(config.rootPanel, "Change Radiance Health Multiplier", "com.notalaser.fentokill.settings.V__Varb_Extra_Rad_Health_Mult", 1f);
			Difficulty_Options.V__Varb_Radiance_Damage_Mult = new FloatField(config.rootPanel, "Change Radiance Damage Multiplier", "com.notalaser.fentokill.settings.V__Varb_Extra_Rad_Damage_Mult", 1f);
			Difficulty_Options.V__Varb_Radiance_Speed_Mult = new FloatField(config.rootPanel, "Change Radiance Speed Multiplier", "com.notalaser.fentokill.settings.V__Varb_Extra_Rad_Speed_Mult", 1f);
			Confing_Loaded = true;
		}
		catch
		{
			_Logger.LogError((object)"Fento_Loader v1.3.89 !!!---!!! ERROR With PluginConfigurator Init");
		}
		Fento_Core.Boot_Core();
		_Harmony.PatchAll(typeof(Waves_Patches_Debug));
		_Harmony.PatchAll(typeof(Other_Classes));
		_Logger.LogInfo((object)"Fento_Loader v1.3.89 loaded successfully without error.");
	}
}
public static class Difficulty_Options
{
	public static BoolField B__Global_Disable_Level_Changes;

	public static BoolField B__Global_Enable_Modify_Everyone;

	public static BoolField B__Res_Forse_All_ImmuneFriendly;

	public static BoolField B__Res_Forse_All_PreSanded;

	public static BoolField B__Res_Forse_All_Radiance;

	public static FloatField V__Varb_Multiply_HardDamage;

	public static FloatField V__Varb_Multiply_Radiance_Tier;

	public static FloatField V__Varb_Add_Radiance_Tier;

	public static BoolField B__Issue_Disable_Most_Buffs;

	public static BoolField B__Issue_Disable_PreSanded;

	public static BoolField B__Issue_Disable_Radiance;

	public static BoolField B__Mech_Disable_RadIdols_Buff;

	public static BoolField B__Mech_Disable_Custom_Symbiotes;

	public static FloatField V__Varb_Radiance_Health_Mult;

	public static FloatField V__Varb_Radiance_Damage_Mult;

	public static FloatField V__Varb_Radiance_Speed_Mult;

	public static int Count_Extra_Skill_Respect
	{
		get
		{
			int i = 0;
			i.AddCount(new bool[9]
			{
				Res_Forse_All_ImmuneFriendly,
				Res_Forse_All_PreSanded,
				Res_Forse_All_Radiance,
				Varb_Multiply_HardDamage > 1f,
				Varb_Multiply_Radiance_Tier > 1f,
				Varb_Add_Radiance_Tier > 0f,
				Varb_Radiance_Health_Mult > 1f,
				Varb_Radiance_Damage_Mult > 1f,
				Varb_Radiance_Speed_Mult > 1f
			});
			return i;
		}
	}

	public static bool Extra_Skill_Respect => Count_Extra_Skill_Respect > 0;

	public static int Count_Issues_With_Skill
	{
		get
		{
			int i = 0;
			i.AddCount(new bool[11]
			{
				Issue_Disable_Most_Buffs,
				Issue_Disable_PreSanded,
				Issue_Disable_Radiance,
				Mech_Disable_RadIdols_Buff,
				Mech_Disable_Custom_Symbiotes,
				Varb_Multiply_HardDamage < 1f,
				Varb_Multiply_Radiance_Tier < 1f,
				Varb_Add_Radiance_Tier < 0f,
				Varb_Radiance_Health_Mult < 1f,
				Varb_Radiance_Damage_Mult < 1f,
				Varb_Radiance_Speed_Mult < 1f
			});
			return i;
		}
	}

	public static bool Skill_Issue => Count_Issues_With_Skill > 0;

	public static bool Global_Disable_Level_Changes => Fento_Utils.Try_GetFrom_Config(B__Global_Disable_Level_Changes);

	public static bool Global_Enable_Modify_Everyone => Fento_Utils.Try_GetFrom_Config(B__Global_Enable_Modify_Everyone);

	public static bool Res_Forse_All_ImmuneFriendly => Fento_Utils.Try_GetFrom_Config(B__Res_Forse_All_ImmuneFriendly);

	public static bool Res_Forse_All_PreSanded => Fento_Utils.Try_GetFrom_Config(B__Res_Forse_All_PreSanded);

	public static bool Res_Forse_All_Radiance => Fento_Utils.Try_GetFrom_Config(B__Res_Forse_All_Radiance);

	public static float Varb_Multiply_HardDamage => Fento_Utils.Try_GetFrom_Config(V__Varb_Multiply_HardDamage);

	public static float Varb_Multiply_Radiance_Tier => Fento_Utils.Try_GetFrom_Config(V__Varb_Multiply_Radiance_Tier);

	public static float Varb_Add_Radiance_Tier => Fento_Utils.Try_GetFrom_Config(V__Varb_Add_Radiance_Tier, 0f);

	public static bool Issue_Disable_Most_Buffs => Fento_Utils.Try_GetFrom_Config(B__Issue_Disable_Most_Buffs);

	public static bool Issue_Disable_PreSanded => Fento_Utils.Try_GetFrom_Config(B__Issue_Disable_PreSanded);

	public static bool Issue_Disable_Radiance => Fento_Utils.Try_GetFrom_Config(B__Issue_Disable_Radiance);

	public static bool Mech_Disable_RadIdols_Buff => Fento_Utils.Try_GetFrom_Config(B__Mech_Disable_RadIdols_Buff);

	public static bool Mech_Disable_Custom_Symbiotes => Fento_Utils.Try_GetFrom_Config(B__Mech_Disable_Custom_Symbiotes);

	public static float Varb_Radiance_Health_Mult => Fento_Utils.Try_GetFrom_Config(V__Varb_Radiance_Health_Mult);

	public static float Varb_Radiance_Damage_Mult => Fento_Utils.Try_GetFrom_Config(V__Varb_Radiance_Damage_Mult);

	public static float Varb_Radiance_Speed_Mult => Fento_Utils.Try_GetFrom_Config(V__Varb_Radiance_Speed_Mult);
}
public static class Fento_Core
{
	public static TMP_FontAsset MainFont;

	public static GameObject[] AllObjs = null;

	public static List<EnemyIdentifier> AllEnemFromLoad = new List<EnemyIdentifier>();

	public static Scene CurrentScene;

	public static int History = 0;

	public static int ActiveHistory = 0;

	public static EnemyClass Example_Class = (EnemyClass)0;

	public static EnemyType Example_Type = (EnemyType)34;

	public static void Boot_Core()
	{
		SceneManager.sceneLoaded += OnSceneLoaded;
		Fento_Loader._Logger.LogInfo((object)"Fento_Core v1.3.89 - Boot_Core successfully.");
	}

	public static void OnSceneLoaded(Scene scene, LoadSceneMode mode)
	{
		//IL_000c: Unknown result type (might be due to invalid IL or missing references)
		//IL_000d: Unknown result type (might be due to invalid IL or missing references)
		History = 0;
		ActiveHistory = 0;
		CurrentScene = scene;
		Fento_Loader._Logger.LogInfo((object)((Scene)(ref scene)).name);
		string currentScene = SceneHelper.CurrentScene;
		Fento_Loader._Logger.LogInfo((object)currentScene);
		AllObjs = Resources.FindObjectsOfTypeAll<GameObject>();
		if (Fento_Utils.AllEnemies.RemoveNulls().ToArray().Length <= 40)
		{
			Fento_Utils.AllEnemies = (from e in Resources.FindObjectsOfTypeAll<EnemyIdentifier>()
				where ((Component)e).gameObject.scene != CurrentScene
				select e).ToArray();
		}
		if ((Object)(object)MainFont == (Object)null)
		{
			MainFont = (from e in Resources.FindObjectsOfTypeAll<TMP_FontAsset>()
				where (Object)(object)e != (Object)null && ((Object)e).name == "VCR_OSD_MONO_1"
				select e).FirstOrDefault();
		}
		Setup_Levels(currentScene);
	}

	public static void Setup_Levels(string levelName)
	{
		if (levelName == "Main Menu")
		{
			Invoke_Load_FentoLevel(levelName, Fento_LevelLoaders.Main_Menu.SetupFentoLevel);
			return;
		}
		Fento_Utils.Invoke_NextFrame(delegate
		{
			if (MonoSingleton<FinalRank>.Instance.toAppear.Length != 0 && (Object)(object)MonoSingleton<FinalRank>.Instance.toAppear[0] != (Object)null && (Object)(object)MonoSingleton<FinalRank>.Instance.toAppear[0].transform.GetChild(1) != (Object)null)
			{
				ComponentExtensions.GetOrAddComponent<Add_Fento_Marked>((Component)(object)MonoSingleton<FinalRank>.Instance.toAppear[0].transform.GetChild(1)).Real_Level = false;
				GameObjectExtensions.GetOrAddComponent<Add_Fento_Skill_Marked>(((Component)MonoSingleton<FinalRank>.Instance.extraInfo).gameObject).Real_Level = false;
			}
		});
		if (!Difficulty_Options.Global_Disable_Level_Changes && levelName == "Level 0-1")
		{
			Invoke_Load_FentoLevel(levelName, Fento_LevelLoaders.Prelude_01.SetupFentoLevel);
		}
	}

	public static void Invoke_Load_FentoLevel(string levelName, Action levelCaster)
	{
		Fento_Utils.Invoke_NextFrame(delegate
		{
			if (MonoSingleton<FinalRank>.Instance.toAppear.Length != 0 && (Object)(object)MonoSingleton<FinalRank>.Instance.toAppear[0] != (Object)null && (Object)(object)MonoSingleton<FinalRank>.Instance.toAppear[0].transform.GetChild(1) != (Object)null)
			{
				ComponentExtensions.GetOrAddComponent<Add_Fento_Marked>((Component)(object)MonoSingleton<FinalRank>.Instance.toAppear[0].transform.GetChild(1)).Real_Level = true;
				GameObjectExtensions.GetOrAddComponent<Add_Fento_Skill_Marked>(((Component)MonoSingleton<FinalRank>.Instance.extraInfo).gameObject).Real_Level = true;
			}
		});
		if (levelCaster != null)
		{
			Fento_Loader._Logger.LogInfo((object)("!!!---!!! Start Fento LOADER " + levelName + " !!!---!!!"));
			Fento_Loader._Logger.LogWarning((object)("!!!---!!! Start Fento LOADER " + levelName + " !!!---!!!"));
			Fento_Loader._Logger.LogInfo((object)("!!!---!!! Start Fento LOADER " + levelName + " !!!---!!!"));
			levelCaster();
			Fento_Utils.Invoke_NextFrame(delegate
			{
				Fento_Utils.Invoke_WithDelay(0.5f, Fento_Utils.Forse_Clear);
			});
			Fento_Loader._Logger.LogInfo((object)("!!!---!!! End Fento LOADER " + levelName + " !!!---!!!"));
			Fento_Loader._Logger.LogWarning((object)("!!!---!!! End Fento LOADER " + levelName + " !!!---!!!"));
			Fento_Loader._Logger.LogInfo((object)("!!!---!!! End Fento LOADER " + levelName + " !!!---!!!"));
		}
		else
		{
			Fento_Loader._Logger.LogWarning((object)("!!!---!!! MISSING Fento Level Loader " + levelName + " !!!---!!!"));
			Fento_Loader._Logger.LogWarning((object)("!!!---!!! MISSING Fento Level Loader " + levelName + " !!!---!!!"));
			Fento_Loader._Logger.LogWarning((object)("!!!---!!! MISSING Fento Level Loader " + levelName + " !!!---!!!"));
			Fento_Loader._Logger.LogWarning((object)("!!!---!!! MISSING Fento Level Loader " + levelName + " !!!---!!!"));
			Fento_Loader._Logger.LogWarning((object)("!!!---!!! MISSING Fento Level Loader " + levelName + " !!!---!!!"));
		}
	}
}
public static class Fento_LevelLoaders
{
	public static class Main_Menu
	{
		public static Fento_Utils.PathObject ExtraText_1 = "Canvas/Main Menu (1)/LeftSide/Text (3)";

		public static Fento_Utils.PathObject ExtraText_2 = "Canvas/Main Menu (1)/LeftSide/Text (3)/Text";

		public static Fento_Utils.PathObject ExtraText_Christmas = "Canvas/Main Menu (1)/LeftSide/Holiday Greetings/Text (Christmas)";

		public static Fento_Utils.PathObject ExtraText_Halloween = "Canvas/Main Menu (1)/LeftSide/Holiday Greetings/Text (Halloween)";

		public static Fento_Utils.PathObject ExtraText_Easter = "Canvas/Main Menu (1)/LeftSide/Holiday Greetings/Text (Easter)";

		public static TextMeshProUGUI Text_1;

		public static TextMeshProUGUI Text_2;

		public static TextMeshProUGUI Text_Christmas;

		public static TextMeshProUGUI Text_Halloween;

		public static TextMeshProUGUI Text_Easter;

		public static void SetupFentoLevel()
		{
			if ((Object)(object)ExtraText_1.gameObject != (Object)null)
			{
				Text_1 = ExtraText_1.GetComponent<TextMeshProUGUI>();
				TryAddFento(Text_1);
			}
			if ((Object)(object)ExtraText_2.gameObject != (Object)null)
			{
				Text_2 = ExtraText_2.GetComponent<TextMeshProUGUI>();
				TryAddFento(Text_2);
			}
			if ((Object)(object)ExtraText_Christmas.gameObject != (Object)null)
			{
				Text_Christmas = ExtraText_Christmas.GetComponent<TextMeshProUGUI>();
				TryAddFento(Text_Christmas);
			}
			if ((Object)(object)ExtraText_Halloween.gameObject != (Object)null)
			{
				Text_Halloween = ExtraText_Halloween.GetComponent<TextMeshProUGUI>();
				TryAddFento(Text_Halloween);
			}
			if ((Object)(object)ExtraText_Easter.gameObject != (Object)null)
			{
				Text_Easter = ExtraText_Easter.GetComponent<TextMeshProUGUI>();
				TryAddFento(Text_Easter);
			}
			LevelSelectPanel val = Resources.FindObjectsOfTypeAll<LevelSelectPanel>().Where(delegate(LevelSelectPanel L)
			{
				//IL_0006: Unknown result type (might be due to invalid IL or missing references)
				//IL_000b: Unknown result type (might be due to invalid IL or missing references)
				Scene scene = ((Component)L).gameObject.scene;
				return ((Scene)(ref scene)).isLoaded && L.levelNumber == 1;
			}).FirstOrDefault();
			if ((Object)(object)val != (Object)null && (Object)(object)((Component)val).transform.GetChild(0) != (Object)null)
			{
				GameObjectExtensions.GetOrAddComponent<Add_Fento_Marked>(((Component)((Component)val).transform.GetChild(0)).gameObject).Real_Level = true;
			}
		}

		public static void TryAddFento(TextMeshProUGUI toAdd)
		{
			if (!((Object)(object)toAdd == (Object)null) && !((TMP_Text)toAdd).text.Contains("Fento Modfied"))
			{
				((TMP_Text)toAdd).text = ((TMP_Text)toAdd).text + "<color=#FF0000> + Fento</color> <color=#FF3F00>1.3.89</color> <color=#FF6A00>Modified</color>";
			}
		}
	}

	public static class Prelude_01
	{
		public static Fento_Utils.PathObject UTRAKILL = "Canvas/HurtScreen/Title Sound/Image";

		public static Fento_Utils.PathObject FentoTitle = "Canvas/HurtScreen/Title Sound";

		public static TextMeshProUGUI Text;

		public static Fento_Utils.PathObject A_Wave_1 = "3 - Gun Room/Enemies/Wave 1";

		public static Fento_Utils.PathObject A_Wave_2 = "3 - Gun Room/Enemies/Wave 2";

		public static Fento_Utils.PathObject A_Trigger_1 = "3 - Gun Room/Enemies/Trigger";

		public static ActivateArena A_ActivateArena_1;

		public static ActivateNextWave A_ActivateNextWave_1;

		public static Fento_Utils.PathObject B_Wave_1 = "4 - Hallway/4 Stuff/Enemy/Wave 1";

		public static Fento_Utils.PathObject B_Trigger_1 = "4 - Hallway/4 Stuff/Enemy/Trigger 1";

		public static Fento_Utils.PathObject B_Wave_2 = "4 - Hallway/4 Stuff/Enemy/Wave 2";

		public static Fento_Utils.PathObject B_Trigger_2 = "4 - Hallway/4 Stuff/Enemy/Trigger 2";

		public static ActivateArena B_ActivateArena_1;

		public static ActivateArena B_ActivateArena_2;

		public static Fento_Utils.PathObject C_Wave_1 = "6 - Glass Hallway/6 Content/Enemies";

		public static Fento_Utils.PathObject C_Trigger_1 = "6 - Glass Hallway/6 Content/Enemies/Trigger";

		public static ActivateArena C_ActivateArena_1;

		public static Fento_Utils.PathObject D_Wave_1 = "7 - Fan Room/7 Content/Enemies";

		public static Fento_Utils.PathObject D_Trigger_1 = "7 - Fan Room/7 Content/Enemies/Cube";

		public static Transform[] D_childs_1;

		public static ActivateArena D_ActivateArena_1;

		public static Fento_Utils.PathObject D_Wave_1_Clone = "7 - Fan Room/7 Content(Clone)/Enemies";

		public static Fento_Utils.PathObject E_Wave_1 = "9 - Projectile Arena/9 Content/Enemies/Projectile Wave";

		public static Fento_Utils.PathObject E_Wave_2 = "9 - Projectile Arena/9 Content/Enemies/New Wave";

		public static Fento_Utils.PathObject E_Trigger_1 = "9 - Projectile Arena/9 Content/Enemies/Cube";

		public static ActivateArena E_ActivateArena_1;

		public static ActivateNextWave E_ActivateNextWave_1;

		public static ActivateNextWave E_ActivateNextWave_2;

		public static Fento_Utils.PathObject E_Wave_1_Clone = "9 - Projectile Arena/9 Content(Clone)/Enemies/Projectile Wave";

		public static Fento_Utils.PathObject E_Wave_2_Clone = "9 - Projectile Arena/9 Content(Clone)/Enemies/New Wave";

		public static Fento_Utils.PathObject F_Wave_1 = "10 - Combo Hallway/10 Content/Enemies/Wave 1";

		public static Fento_Utils.PathObject F_Wave_2 = "10 - Combo Hallway/10 Content/Enemies/Wave 2";

		public static Fento_Utils.PathObject F_Trigger_1 = "10 - Combo Hallway/10 Content/Enemies/Trigger 1";

		public static Fento_Utils.PathObject F_Trigger_2 = "10 - Combo Hallway/10 Content/Enemies/Trigger 2";

		public static ActivateArena F_ActivateArena_1;

		public static ActivateArena F_ActivateArena_2;

		public static Fento_Utils.PathObject F_Wave_1_Clone = "10 - Combo Hallway/10 Content(Clone)/Enemies/Wave 1";

		public static Fento_Utils.PathObject F_Wave_2_Clone = "10 - Combo Hallway/10 Content(Clone)/Enemies/Wave 2";

		public static Fento_Utils.PathObject G_Wave_1 = "11 - Projectile Zombies Room/11 Content/Enemies/Wave 1";

		public static Fento_Utils.PathObject G_Wave_2 = "11 - Projectile Zombies Room/11 Content/Enemies/Wave 1/Filth";

		public static Fento_Utils.PathObject G_Trigger_1A = "11 - Projectile Zombies Room/11 Content/Enemies/Trigger 1A";

		public static Fento_Utils.PathObject G_Trigger_1B = "11 - Projectile Zombies Room/11 Content/Enemies/Trigger 1B";

		public static Fento_Utils.PathObject G_Trigger_2 = "11 - Projectile Zombies Room/11 Content/Enemies/Trigger 2";

		public static ActivateArena G_ActivateArena_1A;

		public static ActivateArena G_ActivateArena_1B;

		public static ActivateArena G_ActivateArena_2;

		public static Fento_Utils.PathObject G_Wave_1_Clone = "11 - Projectile Zombies Room/11 Content(Clone)/Enemies/Wave 1";

		public static Fento_Utils.PathObject G_Wave_2_Clone = "11 - Projectile Zombies Room/11 Content(Clone)/Enemies/Wave 1/Filth";

		public static Fento_Utils.PathObject H_Wave_1 = "12 - Boss Hallway/12 Content/Enemies";

		public static Fento_Utils.PathObject H_Trigger_1 = "12 - Boss Hallway/12 Content/Enemies/Cube";

		public static Transform[] H_childs_1;

		public static ActivateArena H_ActivateArena_1;

		public static Fento_Utils.PathObject H_Wave_1_Clone = "12 - Boss Hallway/12 Content(Clone)/Enemies";

		public static Fento_Utils.PathObject H_Secret_Wave_1 = "12 - Boss Hallway/12 Content/Secret Area";

		public static EnemyIdentifier I_Boss_MaliciousFace;

		public static List<Idol> I_Idols = new List<Idol>();

		public static Fento_Utils.PathObject I_Boss = "13 - Malicious Face Arena/13 Content/Boss/Spider";

		public static Fento_Utils.PathObject I_Wave_1 = "13 - Malicious Face Arena/13 Content/Boss";

		public static Fento_Utils.PathObject I_Trigger_1 = "13 - Malicious Face Arena/13 Content/Trigger";

		public static ObjectActivator I_ObjectActivator_1;

		public static ActivateNextWave I_ActivateNextWave_1;

		public static ActivateArena I_ActivateArena_1;

		public static Fento_Utils.PathObject I_Wave_1_Clone = "13 - Malicious Face Arena/13 Content(Clone)/Boss";

		public static List<Machine> A_3_Machines_1 = new List<Machine>();

		public static List<Machine> E_9_Machines_2 = new List<Machine>();

		public static List<Machine> F_10_Machines_3 = new List<Machine>();

		public static List<Machine> G_11_Machines_4 = new List<Machine>();

		public static List<Machine> H_12_Machines_5 = new List<Machine>();

		public static Fento_Utils.PathObject Hint_1 = "5 - Glass Intro/5 Nonstuff/Cube (2)";

		public static HudMessage Message_1;

		public const string Text_1 = "<color=orange>ENVIRONMENT</color> and <color=orange>TACTICS</color> can be very <color=#89FFFF>USEFUL</color> \n<color=#FF0000>YOU KNOW THE DRIL</color>";

		public static Fento_Utils.PathObject Hint_2 = "10 - Combo Hallway/10 Nonstuff/Hint";

		public static HudMessage Message_2;

		public const string Text_2 = "Upon death <color=orange>Radiance Idols</color> now can <color=#89FFFF>INCREASE RADIANCE TIER</color> \n<color=#FF0000>IT'S NOT GONNA HURT</color>";

		public static Fento_Utils.PathObject Hint_3 = "11 - Projectile Zombies Room/11 Nonstuff/Hint";

		public static HudMessage Message_3;

		public const string Text_3 = "<color=#FF6A00>SOME ENEMIES</color> now form <color=#89FFFF>UNIQUE SYMBIOTIC PAIRS</color> \n<color=#FF0000>DON'T BE SURPRISED</color>";

		public static Fento_Utils.PathObject Hint_4 = "12 - Boss Hallway/12 Nonstuff/Hint";

		public static HudMessage Message_4;

		public const string Text_4 = "<color=#FF0000>GOOD LUCK</color>";

		public static void SetupFentoLevel()
		{
			//IL_0077: Unknown result type (might be due to invalid IL or missing references)
			//IL_0114: Unknown result type (might be due to invalid IL or missing references)
			//IL_01d7: Unknown result type (might be due to invalid IL or missing references)
			//IL_01f0: Unknown result type (might be due to invalid IL or missing references)
			//IL_0209: Unknown result type (might be due to invalid IL or missing references)
			//IL_0222: Unknown result type (might be due to invalid IL or missing references)
			//IL_0227: Unknown result type (might be due to invalid IL or missing references)
			//IL_015f: Unknown result type (might be due to invalid IL or missing references)
			//IL_0178: Unknown result type (might be due to invalid IL or missing references)
			//IL_0191: Unknown result type (might be due to invalid IL or missing references)
			//IL_01aa: Unknown result type (might be due to invalid IL or missing references)
			//IL_01af: Unknown result type (might be due to invalid IL or missing references)
			//IL_070c: Unknown result type (might be due to invalid IL or missing references)
			//IL_0720: Unknown result type (might be due to invalid IL or missing references)
			//IL_0745: Unknown result type (might be due to invalid IL or missing references)
			//IL_0759: Unknown result type (might be due to invalid IL or missing references)
			//IL_077e: Unknown result type (might be due to invalid IL or missing references)
			//IL_0792: Unknown result type (might be due to invalid IL or missing references)
			//IL_07b7: Unknown result type (might be due to invalid IL or missing references)
			//IL_07cb: Unknown result type (might be due to invalid IL or missing references)
			//IL_07f0: Unknown result type (might be due to invalid IL or missing references)
			//IL_0804: Unknown result type (might be due to invalid IL or missing references)
			//IL_0828: Unknown result type (might be due to invalid IL or missing references)
			//IL_083c: Unknown result type (might be due to invalid IL or missing references)
			//IL_0860: Unknown result type (might be due to invalid IL or missing references)
			//IL_0874: Unknown result type (might be due to invalid IL or missing references)
			//IL_0898: Unknown result type (might be due to invalid IL or missing references)
			//IL_08ac: Unknown result type (might be due to invalid IL or missing references)
			//IL_08d1: Unknown result type (might be due to invalid IL or missing references)
			//IL_08e5: Unknown result type (might be due to invalid IL or missing references)
			//IL_0dad: Unknown result type (might be due to invalid IL or missing references)
			//IL_0dfe: Unknown result type (might be due to invalid IL or missing references)
			//IL_0e12: Unknown result type (might be due to invalid IL or missing references)
			//IL_0e37: Unknown result type (might be due to invalid IL or missing references)
			//IL_0e4b: Unknown result type (might be due to invalid IL or missing references)
			//IL_0e70: Unknown result type (might be due to invalid IL or missing references)
			//IL_0e84: Unknown result type (might be due to invalid IL or missing references)
			//IL_0ea8: Unknown result type (might be due to invalid IL or missing references)
			//IL_0ebc: Unknown result type (might be due to invalid IL or missing references)
			//IL_0ee1: Unknown result type (might be due to invalid IL or missing references)
			//IL_0ef5: Unknown result type (might be due to invalid IL or missing references)
			//IL_0f1a: Unknown result type (might be due to invalid IL or missing references)
			//IL_0f2e: Unknown result type (might be due to invalid IL or missing references)
			//IL_0f53: Unknown result type (might be due to invalid IL or missing references)
			//IL_0f67: Unknown result type (might be due to invalid IL or missing references)
			//IL_1030: Unknown result type (might be due to invalid IL or missing references)
			//IL_1044: Unknown result type (might be due to invalid IL or missing references)
			//IL_106b: Unknown result type (might be due to invalid IL or missing references)
			//IL_107f: Unknown result type (might be due to invalid IL or missing references)
			//IL_10a6: Unknown result type (might be due to invalid IL or missing references)
			//IL_10ba: Unknown result type (might be due to invalid IL or missing references)
			//IL_10e1: Unknown result type (might be due to invalid IL or missing references)
			//IL_10f5: Unknown result type (might be due to invalid IL or missing references)
			//IL_111c: Unknown result type (might be due to invalid IL or missing references)
			//IL_1130: Unknown result type (might be due to invalid IL or missing references)
			//IL_1157: Unknown result type (might be due to invalid IL or missing references)
			//IL_116b: Unknown result type (might be due to invalid IL or missing references)
			StatsManager instance = MonoSingleton<StatsManager>.Instance;
			for (int i = 0; i < instance.timeRanks.Length; i++)
			{
				instance.timeRanks[i] = (int)((float)instance.timeRanks[i] * 2.5f);
			}
			for (int j = 0; j < instance.styleRanks.Length; j++)
			{
				instance.styleRanks[j] *= 7;
			}
			if ((Object)(object)UTRAKILL.transform != (Object)null)
			{
				UTRAKILL.transform.localScale = Vector3.zero;
				UTRAKILL.gameObject.SetActive(false);
			}
			if ((Object)(object)FentoTitle.transform != (Object)null)
			{
				Text = GameObjectExtensions.GetOrAddComponent<TextMeshProUGUI>(FentoTitle.gameObject);
				if ((Object)(object)Text != (Object)null && ((TMP_Text)Text).text != (Difficulty_Options.Skill_Issue ? "SKILLISSUE" : "FENTOKILL"))
				{
					((TMP_Text)Text).font = Fento_Core.MainFont;
					((Graphic)Text).color = new Color(1f, 1f, 1f);
					if (Difficulty_Options.Skill_Issue)
					{
						((TMP_Text)Text).fontSize = 190f;
						((TMP_Text)Text).text = "SKILLISSUE";
						((TMP_Text)Text).colorGradient = new VertexGradient(new Color(0.3f, 1f, 0.3f, 1f), new Color(0.1f, 0.95f, 0.1f, 1f), new Color(0f, 0.5f, 0f, 1f), new Color(0f, 0.15f, 0f, 1f));
					}
					else
					{
						((TMP_Text)Text).colorGradient = new VertexGradient(new Color(1f, 0.3f, 0.3f, 1f), new Color(0.95f, 0.1f, 0.1f, 1f), new Color(0.5f, 0f, 0f, 1f), new Color(0.15f, 0f, 0f, 1f));
						if (Difficulty_Options.Extra_Skill_Respect)
						{
							((TMP_Text)Text).fontSize = 190f;
							((TMP_Text)Text).text = "FENTOKILL+";
						}
						else
						{
							((TMP_Text)Text).fontSize = 200f;
							((TMP_Text)Text).text = "FENTOKILL";
						}
					}
					((TMP_Text)Text).fontStyle = (FontStyles)1;
					((TMP_Text)Text).enableVertexGradient = true;
					((TMP_Text)Text).alignment = (TextAlignmentOptions)514;
				}
			}
			A_3_Machines_1.Clear();
			E_9_Machines_2.Clear();
			F_10_Machines_3.Clear();
			G_11_Machines_4.Clear();
			H_12_Machines_5.Clear();
			I_Idols.Clear();
			I_Boss_MaliciousFace = null;
			Message_1 = Hint_1.GetComponent<HudMessage>();
			Message_1.Set_HudMessage("<color=orange>ENVIRONMENT</color> and <color=orange>TACTICS</color> can be very <color=#89FFFF>USEFUL</color> \n<color=#FF0000>YOU KNOW THE DRIL</color>");
			Message_2 = Hint_2.GetComponent<HudMessage>();
			Message_2.Set_HudMessage("Upon death <color=orange>Radiance Idols</color> now can <color=#89FFFF>INCREASE RADIANCE TIER</color> \n<color=#FF0000>IT'S NOT GONNA HURT</color>");
			Message_3 = Hint_3.GetComponent<HudMessage>();
			Message_3.Set_HudMessage("<color=#FF6A00>SOME ENEMIES</color> now form <color=#89FFFF>UNIQUE SYMBIOTIC PAIRS</color> \n<color=#FF0000>DON'T BE SURPRISED</color>");
			Message_4 = Hint_4.GetComponent<HudMessage>();
			Message_4.Set_HudMessage("<color=#FF0000>GOOD LUCK</color>");
			A_ActivateArena_1 = A_Trigger_1.GetComponent<ActivateArena>();
			A_ActivateNextWave_1 = A_Wave_1.GetComponent<ActivateNextWave>();
			B_ActivateArena_1 = B_Trigger_1.GetComponent<ActivateArena>();
			B_ActivateArena_2 = B_Trigger_2.GetComponent<ActivateArena>();
			C_ActivateArena_1 = C_Trigger_1.GetComponent<ActivateArena>();
			D_childs_1 = D_Wave_1.childs;
			D_ActivateArena_1 = D_Trigger_1.GetComponent<ActivateArena>();
			E_ActivateArena_1 = E_Trigger_1.GetComponent<ActivateArena>();
			E_ActivateNextWave_1 = E_Wave_1.GetComponent<ActivateNextWave>();
			E_ActivateNextWave_2 = E_Wave_2.GetComponent<ActivateNextWave>();
			F_ActivateArena_1 = F_Trigger_1.GetComponent<ActivateArena>();
			F_ActivateArena_2 = F_Trigger_2.GetComponent<ActivateArena>();
			G_ActivateArena_1A = G_Trigger_1A.GetComponent<ActivateArena>();
			G_ActivateArena_1B = G_Trigger_1B.GetComponent<ActivateArena>();
			G_ActivateArena_2 = G_Trigger_2.GetComponent<ActivateArena>();
			H_childs_1 = H_Wave_1.childs;
			H_ActivateArena_1 = H_Trigger_1.GetComponent<ActivateArena>();
			I_ObjectActivator_1 = I_Trigger_1.GetComponent<ObjectActivator>();
			I_ActivateNextWave_1 = I_Wave_1.GetComponent<ActivateNextWave>();
			I_ActivateArena_1 = I_Trigger_1.GetComponent<ActivateArena>();
			Fento_Utils.Enemy_InStack(A_Wave_1.transform, delegate(EnemyIdentifier enemy)
			{
				//IL_0008: 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)
				Fento_Utils.Base_ReplaceEnemy(Fento_Utils.DetectebleEnemies.Mindflayer, ((Component)enemy).transform, Vector3.up * (5f + Random.value * 15f));
			});
			Fento_Utils.Enemy_InStack(A_Wave_1.transform, delegate(EnemyIdentifier enemy)
			{
				enemy.Sandify(false);
			}, Hard_Mode_Only: true);
			Fento_Utils.Update_ActivateArena(A_ActivateArena_1, A_Wave_1.transform);
			bool mini = false;
			Fento_Utils.Enemy_InStack(A_Wave_2.transform, delegate(EnemyIdentifier enemy)
			{
				//IL_003e: Unknown result type (might be due to invalid IL or missing references)
				//IL_0054: Unknown result type (might be due to invalid IL or missing references)
				//IL_001f: Unknown result type (might be due to invalid IL or missing references)
				//IL_0029: Unknown result type (might be due to invalid IL or missing references)
				mini = !mini;
				if (!mini)
				{
					Fento_Utils.Base_ReplaceEnemy(Fento_Utils.DetectebleEnemies.SwordsMachineNonboss, ((Component)enemy).transform, Vector3.up * 0.1f);
				}
				else
				{
					Fento_Utils.Base_ReplaceEnemy(Fento_Utils.DetectebleEnemies.Drone, ((Component)enemy).transform, Vector3.up * (16f + Random.value * 6f));
				}
			});
			Fento_Utils.Enemy_InStack(A_Wave_2.transform, delegate(EnemyIdentifier enemy)
			{
				//IL_0001: Unknown result type (might be due to invalid IL or missing references)
				//IL_0007: Invalid comparison between Unknown and I4
				//IL_0026: Unknown result type (might be due to invalid IL or missing references)
				//IL_002c: Invalid comparison between Unknown and I4
				if ((int)enemy.enemyType == 7)
				{
					Machine component10 = ((Component)enemy).GetComponent<Machine>();
					if ((Object)(object)component10 != (Object)null)
					{
						A_3_Machines_1.Add(component10);
					}
				}
				else if ((int)enemy.enemyType == 1)
				{
					GameObjectExtensions.GetOrAddComponent<Drone_AntiSoftLock>(((Component)enemy).gameObject);
				}
			});
			Fento_Utils.Enemy_InStack(A_Wave_2.transform, delegate(EnemyIdentifier enemy)
			{
				//IL_0008: Unknown result type (might be due to invalid IL or missing references)
				//IL_000e: Invalid comparison between Unknown and I4
				enemy.immuneToFriendlyFire = true;
				if ((int)enemy.enemyType == 1)
				{
					enemy.radianceTier += 1.1f;
					enemy.healthBuffModifier += 1.1f;
					enemy.BuffAll();
				}
			}, Hard_Mode_Only: true);
			Fento_Utils.Make_List_MachineSymbiote(A_3_Machines_1);
			Fento_Utils.Update_ActivateNextWave(A_ActivateNextWave_1, A_Wave_2.transform);
			Fento_Utils.Enemy_InStack(B_Wave_1.transform, delegate(EnemyIdentifier enemy)
			{
				//IL_000a: Unknown result type (might be due to invalid IL or missing references)
				//IL_0010: Unknown result type (might be due to invalid IL or missing references)
				Fento_Utils.Base_ReplaceEnemy(Fento_Utils.DetectebleEnemies.Ferryman, ((Component)enemy).transform);
			});
			Fento_Utils.Enemy_InStack(B_Wave_1.transform, delegate(EnemyIdentifier enemy)
			{
				enemy.Sandify(false);
			}, Hard_Mode_Only: true);
			Fento_Utils.Update_ActivateArena(B_ActivateArena_1, B_Wave_1.transform);
			Fento_Utils.Enemy_InStack(B_Wave_2.transform, delegate(EnemyIdentifier enemy)
			{
				//IL_000a: Unknown result type (might be due to invalid IL or missing references)
				//IL_0010: Unknown result type (might be due to invalid IL or missing references)
				Fento_Utils.Base_ReplaceEnemy(Fento_Utils.DetectebleEnemies.Cerberus, ((Component)enemy).transform);
			});
			Fento_Utils.Enemy_InStack(B_Wave_2.transform, delegate(EnemyIdentifier enemy)
			{
				//IL_0007: Unknown result type (might be due to invalid IL or missing references)
				//IL_0011: Unknown result type (might be due to invalid IL or missing references)
				Transform transform9 = ((Component)enemy).transform;
				transform9.localScale *= 0.55f;
				NavMeshAgent component9 = ((Component)enemy).GetComponent<NavMeshAgent>();
				if ((Object)(object)component9 != (Object)null)
				{
					component9.acceleration = 50f;
					component9.speed = 50f;
				}
			});
			Fento_Utils.Update_ActivateArena(B_ActivateArena_2, B_Wave_2.transform);
			bool variant = false;
			Fento_Utils.Enemy_InStack(C_Wave_1.transform, delegate(EnemyIdentifier enemy)
			{
				//IL_005b: Unknown result type (might be due to invalid IL or missing references)
				//IL_0060: 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_002e: Unknown result type (might be due to invalid IL or missing references)
				//IL_0033: Unknown result type (might be due to invalid IL or missing references)
				//IL_0036: Unknown result type (might be due to invalid IL or missing references)
				variant = !variant;
				Vector3 val;
				if (!variant)
				{
					Transform transform7 = ((Component)enemy).transform;
					val = new Vector3(Random.value, 0f, Random.value);
					Fento_Utils.Base_ReplaceEnemy(Fento_Utils.DetectebleEnemies.Turret, transform7, ((Vector3)(ref val)).normalized, DestroyOnReplace: false);
				}
				else
				{
					Transform transform8 = ((Component)enemy).transform;
					val = new Vector3(Random.value, 0f, Random.value);
					Fento_Utils.Base_ReplaceEnemy(Fento_Utils.DetectebleEnemies.ShotgunHusk, transform8, ((Vector3)(ref val)).normalized, DestroyOnReplace: false);
				}
				GameObjectExtensions.GetOrAddComponent<Fento_DontLoop_Tag>(((Component)enemy).gameObject);
			});
			Fento_Utils.Enemy_InStack(C_Wave_1.transform, delegate(EnemyIdentifier enemy)
			{
				//IL_0013: Unknown result type (might be due to invalid IL or missing references)
				//IL_001a: Invalid comparison between Unknown and I4
				enemy.radianceTier += 3.5f;
				if ((int)enemy.enemyType == 20)
				{
					enemy.Sandify(false);
					enemy.radianceTier -= 1.4f;
					enemy.healthBuffModifier += 0.55f;
				}
				else
				{
					enemy.healthBuffModifier += 1.7f;
				}
				enemy.damageBuffModifier += 0.5f;
				enemy.BuffAll();
			}, Hard_Mode_Only: true);
			Fento_Utils.Update_ActivateArena(C_ActivateArena_1, C_Wave_1.transform);
			Fento_Utils.Custom_ReplaceEnemy(Fento_Utils.DetectebleEnemies.Virtue, D_childs_1[0], new Vector3(10f, 61f, 576f), Quaternion.Euler(0f, 90f, 0f));
			Fento_Utils.Custom_ReplaceEnemy(Fento_Utils.DetectebleEnemies.Virtue, D_childs_1[1], new Vector3(60f, -10f, 607f), Quaternion.Euler(0f, 200f, 0f));
			Fento_Utils.Custom_ReplaceEnemy(Fento_Utils.DetectebleEnemies.Mindflayer, D_childs_1[2], new Vector3(23f, 25f, 565f), Quaternion.Euler(0f, 45f, 0f));
			Fento_Utils.Custom_ReplaceEnemy(Fento_Utils.DetectebleEnemies.Mindflayer, D_childs_1[3], new Vector3(68f, 30f, 597f), Quaternion.Euler(0f, 230f, 0f));
			Fento_Utils.Custom_ReplaceEnemy(Fento_Utils.DetectebleEnemies.SwordsMachineNonboss, D_childs_1[4], new Vector3(54f, -6.8762f, 567f), Quaternion.Euler(0f, 270f, 0f));
			Fento_Utils.Custom_ReplaceEnemy(Fento_Utils.DetectebleEnemies.Gutterman, D_childs_1[5], new Vector3(40f, 8.0833f, 621f), Quaternion.Euler(0f, 180f, 0f));
			Fento_Utils.Custom_ReplaceEnemy(Fento_Utils.DetectebleEnemies.Guttertank, D_childs_1[6], new Vector3(59f, -1.8618f, 585f), Quaternion.Euler(0f, 200f, 0f));
			Fento_Utils.Custom_ReplaceEnemy(Fento_Utils.DetectebleEnemies.Guttertank, D_childs_1[7], new Vector3(22f, 8.1667f, 590f), Quaternion.Euler(0f, 125f, 0f));
			Fento_Utils.Custom_ReplaceEnemy(Fento_Utils.DetectebleEnemies.CentaurRocketLauncher, D_childs_1[8], new Vector3(67f, 87.5f, 579f), Quaternion.Euler(0f, 180f, 0f));
			Fento_Utils.Enemy_InStack(D_Wave_1.transform, delegate(EnemyIdentifier enemy)
			{
				//IL_0001: Unknown result type (might be due to invalid IL or missing references)
				//IL_0008: Invalid comparison between Unknown and I4
				//IL_005a: Unknown result type (might be due to invalid IL or missing references)
				//IL_0060: Invalid comparison between Unknown and I4
				//IL_006c: Unknown result type (might be due to invalid IL or missing references)
				//IL_0073: Invalid comparison between Unknown and I4
				//IL_0076: Unknown result type (might be due to invalid IL or missing references)
				//IL_007d: Invalid comparison between Unknown and I4
				if ((int)enemy.enemyType == 35)
				{
					enemy.Sandify(false);
					enemy.damageBuffModifier += 0.75f;
					enemy.healthBuffModifier += 0.25f;
					enemy.speedBuffModifier += 0.5f;
					enemy.radianceTier += 2.5f;
				}
				if ((int)enemy.enemyType == 5)
				{
					enemy.Sandify(false);
				}
				else if ((int)enemy.enemyType != 34 && (int)enemy.enemyType != 9)
				{
					enemy.radianceTier += 1.25f;
					enemy.BuffAll();
				}
				enemy.immuneToFriendlyFire = true;
			}, Hard_Mode_Only: true);
			Fento_Utils.Update_ActivateArena(D_ActivateArena_1, D_Wave_1.transform);
			Fento_Utils.Invoke_NextFrame(delegate
			{
				Fento_Utils.Clear_AreaFromClones(D_Wave_1_Clone.transform);
			});
			Fento_Utils.Enemy_InStack(E_Wave_1.transform, delegate(EnemyIdentifier enemy)
			{
				//IL_000a: Unknown result type (might be due to invalid IL or missing references)
				//IL_0010: Unknown result type (might be due to invalid IL or missing references)
				Fento_Utils.Base_ReplaceEnemy(Fento_Utils.DetectebleEnemies.Turret, ((Component)enemy).transform);
			});
			Fento_Utils.Enemy_InStack(E_Wave_1.transform, delegate(EnemyIdentifier enemy)
			{
				enemy.Sandify(false);
				enemy.healthBuffModifier += 0.35f;
				enemy.radianceTier = 4f;
				enemy.BuffAll();
				NavMeshAgent component8 = ((Component)enemy).GetComponent<NavMeshAgent>();
				if ((Object)(object)component8 != (Object)null)
				{
					component8.acceleration += 15f;
					component8.speed += 15f;
				}
			}, Hard_Mode_Only: true);
			Fento_Utils.Update_ActivateArena(E_ActivateArena_1, E_Wave_1.transform);
			bool idolOnly = false;
			Fento_Utils.Enemy_InStack(E_Wave_2.transform, delegate(EnemyIdentifier enemy)
			{
				//IL_0001: Unknown result type (might be due to invalid IL or missing references)
				//IL_0007: Invalid comparison between Unknown and I4
				//IL_0087: 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_008f: Unknown result type (might be due to invalid IL or missing references)
				//IL_00a5: Unknown result type (might be due to invalid IL or missing references)
				//IL_00ab: Unknown result type (might be due to invalid IL or missing references)
				//IL_004f: Unknown result type (might be due to invalid IL or missing references)
				//IL_0054: Unknown result type (might be due to invalid IL or missing references)
				//IL_0057: Unknown result type (might be due to invalid IL or missing references)
				if ((int)enemy.enemyType == 3)
				{
					Object.Destroy((Object)(object)((Component)enemy).gameObject);
				}
				else
				{
					idolOnly = !idolOnly;
					Vector3 extraPos;
					if (idolOnly)
					{
						Transform transform4 = ((Component)enemy).transform;
						extraPos = new Vector3(Random.value * 3.5f, 0f, Random.value * 3.5f);
						Fento_Utils.Base_ReplaceEnemy(Fento_Utils.DetectebleEnemies.Idol, transform4, ((Vector3)(ref extraPos)).normalized);
					}
					else
					{
						Transform transform5 = ((Component)enemy).transform;
						extraPos = new Vector3(Random.value * 3.5f, 0f, Random.value * 3.5f);
						Fento_Utils.Base_ReplaceEnemy(Fento_Utils.DetectebleEnemies.Idol, transform5, ((Vector3)(ref extraPos)).normalized, DestroyOnReplace: false);
						Transform transform6 = ((Component)enemy).transform;
						extraPos = default(Vector3);
						Fento_Utils.Base_ReplaceEnemy(Fento_Utils.DetectebleEnemies.Sisyphus, transform6, extraPos);
					}
				}
			});
			Fento_Utils.Enemy_InStack(E_Wave_2.transform, delegate(EnemyIdentifier enemy)
			{
				//IL_0001: Unknown result type (might be due to invalid IL or missing references)
				//IL_0008: Invalid comparison between Unknown and I4
				if ((int)enemy.enemyType == 19)
				{
					Machine component7 = ((Component)enemy).GetComponent<Machine>();
					if ((Object)(object)component7 != (Object)null)
					{
						E_9_Machines_2.Add(component7);
					}
				}
			});
			Fento_Utils.Enemy_InStack(E_Wave_2.transform, delegate(EnemyIdentifier enemy)
			{
				//IL_0001: Unknown result type (might be due to invalid IL or missing references)
				//IL_0008: Invalid comparison between Unknown and I4
				//IL_0011: Unknown result type (might be due to invalid IL or missing references)
				//IL_001b: Unknown result type (might be due to invalid IL or missing references)
				if ((int)enemy.enemyType == 21)
				{
					Transform transform3 = ((Component)enemy).transform;
					transform3.localScale *= 0.6f;
					GameObjectExtensions.GetOrAddComponent<Idol_Buff_Radiance>(((Component)enemy).gameObject).TierToAdd = 0.15f;
					enemy.BuffAll();
					enemy.Sandify(false);
				}
			}, Hard_Mode_Only: true);
			Fento_Utils.Make_List_MachineSymbiote(E_9_Machines_2);
			Fento_Utils.Update_ActivateNextWave(E_ActivateNextWave_1, E_Wave_2.transform);
			E_ActivateNextWave_2.enemyCount = 6;
			Fento_Utils.Invoke_NextFrame(delegate
			{
				Fento_Utils.Clear_AreaFromClones(E_Wave_1_Clone.transform);
				Fento_Utils.Clear_AreaFromClones(E_Wave_2_Clone.transform);
			});
			Fento_Utils.Enemy_InStack(F_Wave_1.transform, delegate(EnemyIdentifier enemy)
			{
				//IL_0017: Unknown result type (might be due to invalid IL or missing references)
				//IL_002d: Unknown result type (might be due to invalid IL or missing references)
				//IL_0033: Unknown result type (might be due to invalid IL or missing references)
				Fento_Utils.Base_ReplaceEnemy(Fento_Utils.DetectebleEnemies.Idol, ((Component)enemy).transform, new Vector3(2f, 0f, 0f), DestroyOnReplace: false);
				Fento_Utils.Base_ReplaceEnemy(Fento_Utils.DetectebleEnemies.Streetcleaner, ((Component)enemy).transform);
			});
			Fento_Utils.Enemy_InStack(F_Wave_1.transform, delegate(EnemyIdentifier enemy)
			{
				//IL_0001: Unknown result type (might be due to invalid IL or missing references)
				//IL_0007: Invalid comparison between Unknown and I4
				//IL_0042: Unknown result type (might be due to invalid IL or missing references)
				//IL_0049: Invalid comparison between Unknown and I4
				//IL_005e: Unknown result type (might be due to invalid IL or missing references)
				//IL_0068: Unknown result type (might be due to invalid IL or missing references)
				if ((int)enemy.enemyType == 6)
				{
					enemy.healthBuffModifier += 8f;
					enemy.damageBuffModifier += 0.25f;
					enemy.radianceTier += 2.5f;
				}
				else if ((int)enemy.enemyType == 21)
				{
					GameObjectExtensions.GetOrAddComponent<Idol_Buff_Radiance>(((Component)enemy).gameObject);
					Transform transform2 = ((Component)enemy).transform;
					transform2.localScale *= 0.6f;
				}
				enemy.Sandify(false);
				enemy.BuffAll();
			}, Hard_Mode_Only: true);
			Fento_Utils.Update_ActivateArena(F_ActivateArena_1, F_Wave_1.transform);
			int swordsCount = 0;
			Fento_Utils.Enemy_InStack(F_Wave_2.transform, delegate(EnemyIdentifier enemy)
			{
				//IL_0001: Unknown result type (might be due to invalid IL or missing references)
				//IL_0007: Invalid comparison between Unknown and I4
				//IL_0052: Unknown result type (might be due to invalid IL or missing references)
				//IL_0058: Unknown result type (might be due to invalid IL or missing references)
				//IL_001c: 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)
				if ((int)enemy.enemyType == 3)
				{
					if (swordsCount < 3)
					{
						Fento_Utils.Base_ReplaceEnemy(Fento_Utils.DetectebleEnemies.SwordsMachineNonboss, ((Component)enemy).transform);
					}
					else
					{
						Object.Destroy((Object)(object)((Component)enemy).gameObject);
					}
					swordsCount++;
				}
				else
				{
					Fento_Utils.Base_ReplaceEnemy(Fento_Utils.DetectebleEnemies.Cerberus, ((Component)enemy).transform);
				}
			});
			Fento_Utils.Enemy_InStack(F_Wave_2.transform, delegate(EnemyIdentifier enemy)
			{
				//IL_0001: Unknown result type (might be due to invalid IL or missing references)
				//IL_0007: Invalid comparison between Unknown and I4
				//IL_0025: Unknown result type (might be due to invalid IL or missing references)
				//IL_0059: 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)
				if ((int)enemy.enemyType == 7)
				{
					Machine component5 = ((Component)enemy).GetComponent<Machine>();
					if ((Object)(object)component5 != (Object)null)
					{
						F_10_Machines_3.Add(component5);
					}
				}
				if ((int)enemy.enemyType == 0)
				{
					NavMeshAgent component6 = ((Component)enemy).GetComponent<NavMeshAgent>();
					if ((Object)(object)component6 != (Object)null)
					{
						component6.acceleration = 50f;
						component6.speed = 50f;
					}
					Transform transform = ((Component)enemy).transform;
					transform.localScale *= 0.75f;
				}
			});
			Fento_Utils.Enemy_InStack(F_Wave_2.transform, delegate(EnemyIdentifier enemy)
			{
				//IL_0001: Unknown result type (might be due to invalid IL or missing references)
				if ((int)enemy.enemyType == 0)
				{
					enemy.healthBuffModifier += 1.2f;
					enemy.radianceTier += 1.25f;
					enemy.Sandify(false);
				}
				enemy.radianceTier += 1.6f;
				enemy.BuffAll();
			}, Hard_Mode_Only: true);
			Fento_Utils.Make_List_MachineSymbiote(F_10_Machines_3);
			Fento_Utils.Update_ActivateArena(F_ActivateArena_2, F_Wave_2.transform);
			Fento_Utils.Invoke_NextFrame(delegate
			{
				Fento_Utils.Clear_AreaFromClones(F_Wave_1_Clone.transform);
				Fento_Utils.Clear_AreaFromClones(F_Wave_2_Clone.transform);
			});
			Fento_Utils.Update_ActivateArena(F_ActivateArena_1, F_Wave_1.transform);
			Fento_Utils.For_InStack(G_Wave_1.transform, delegate(Transform tr)
			{
				if ((Object)(object)((Component)tr).GetComponent<EnemyIdentifier>() == (Object)null)
				{
					GameObjectExtensions.GetOrAddComponent<Fento_DontLoop_Tag>(((Component)tr).gameObject);
				}
			});
			Fento_Utils.Enemy_InStack(G_Wave_1.transform, delegate(EnemyIdentifier enemy)
			{
				//IL_000a: Unknown result type (might be due to invalid IL or missing references)
				//IL_0010: Unknown result type (might be due to invalid IL or missing references)
				Fento_Utils.Base_ReplaceEnemy(Fento_Utils.DetectebleEnemies.ShotgunHusk, ((Component)enemy).transform);
			});
			Fento_Utils.Enemy_InStack(G_Wave_1.transform, delegate(EnemyIdentifier enemy)
			{
				GameObjectExtensions.GetOrAddComponent<Drone_AntiSoftLock>(((Component)enemy).gameObject).ReqTime = 25f;
			});
			Fento_Utils.Enemy_InStack(G_Wave_1.transform, delegate(EnemyIdentifier enemy)
			{
				enemy.radianceTier += 1f;
				enemy.healthBuffModifier += 2f;
				enemy.damageBuffModifier += 0.5f;
				enemy.speedBuffModifier -= 0.5f;
				enemy.BuffAll();
			}, Hard_Mode_Only: true);
			Fento_Utils.Enemy_InStack(G_Wave_2.transform, delegate(EnemyIdentifier enemy)
			{
				//IL_000a: Unknown result type (might be due to invalid IL or missing references)
				//IL_0010: Unknown result type (might be due to invalid IL or missing references)
				Fento_Utils.Base_ReplaceEnemy(Fento_Utils.DetectebleEnemies.Mannequin, ((Component)enemy).transform);
			});
			Fento_Utils.Enemy_InStack(G_Wave_2.transform, delegate(EnemyIdentifier enemy)
			{
				//IL_0001: Unknown result type (might be due to invalid IL or missing references)
				//IL_0008: Invalid comparison between Unknown and I4
				if ((int)enemy.enemyType == 31)
				{
					Machine component4 = ((Component)enemy).GetComponent<Machine>();
					if ((Object)(object)component4 != (Object)null)
					{
						G_11_Machines_4.Add(component4);
					}
					GameObjectExtensions.GetOrAddComponent<Drone_AntiSoftLock>(((Component)enemy).gameObject).ReqTime = 25f;
				}
			});
			Fento_Utils.Enemy_InStack(G_Wave_2.transform, delegate(EnemyIdentifier enemy)
			{
				enemy.Sandify(false);
				enemy.radianceTier += 2.5f;
				enemy.healthBuffModifier += 1f;
				enemy.damageBuffModifier += 0.5f;
				enemy.speedBuffModifier -= 0.5f;
				enemy.BuffAll();
			}, Hard_Mode_Only: true);
			Fento_Utils.Make_List_MachineSymbiote(G_11_Machines_4);
			Fento_Utils.Update_ActivateArena(G_ActivateArena_1A, G_Wave_1.transform);
			Fento_Utils.Update_ActivateArena(G_ActivateArena_1B, G_Wave_1.transform);
			Fento_Utils.Update_ActivateArena(G_ActivateArena_2, G_Wave_1.transform);
			Fento_Utils.Invoke_NextFrame(delegate
			{
				Fento_Utils.Clear_AreaFromClones(G_Wave_1_Clone.transform);
				Fento_Utils.Clear_AreaFromClones(G_Wave_2_Clone.transform);
			});
			H_Trigger_1.transform.localScale = new Vector3(80f, 160f, 35f);
			Fento_Utils.Enemy_InStack(H_Secret_Wave_1.transform, delegate(EnemyIdentifier enemy)
			{
				enemy.damageBuffModifier += 0.5f;
				enemy.healthBuffModifier += 4f;
				enemy.radianceTier += 3f;
				enemy.BuffAll();
			}, Hard_Mode_Only: true);
			Fento_Utils.Custom_ReplaceEnemy(Fento_Utils.DetectebleEnemies.Drone, H_childs_1[0], new Vector3(223f, 60f, 516f), Quaternion.Euler(0f, 270f, 0f));
			Fento_Utils.Custom_ReplaceEnemy(Fento_Utils.DetectebleEnemies.Drone, H_childs_1[1], new Vector3(180f, 60f, 516f), Quaternion.Euler(0f, 90f, 0f));
			Fento_Utils.Custom_ReplaceEnemy(Fento_Utils.DetectebleEnemies.Ferryman, H_childs_1[2], new Vector3(202f, 53.6667f, 492f), Quaternion.Euler(0f, 0f, 0f));
			Fento_Utils.Custom_ReplaceEnemy(Fento_Utils.DetectebleEnemies.Guttertank, H_childs_1[3], new Vector3(168f, 53.0833f, 488f), Quaternion.Euler(0f, 90f, 0f));
			Fento_Utils.Custom_ReplaceEnemy(Fento_Utils.DetectebleEnemies.CentaurTower, H_childs_1[4], new Vector3(178.5f, 104f, 520.5f), Quaternion.Euler(0f, 45f, 0f));
			Fento_Utils.Custom_ReplaceEnemy(Fento_Utils.DetectebleEnemies.Projectile_Zombie, H_childs_1[5], new Vector3(202f, 53.1493f, 527f), Quaternion.Euler(0f, 180f, 0f));
			Fento_Utils.Custom_ReplaceEnemy(Fento_Utils.DetectebleEnemies.Mass, H_childs_1[6], new Vector3(202f, 53f, 463f), Quaternion.Euler(0f, 0f, 0f));
			Fento_Utils.Enemy_InStack(H_Wave_1.transform, delegate(EnemyIdentifier enemy)
			{
				//IL_0001: Unknown result type (might be due to invalid IL or missing references)
				//IL_0008: Invalid comparison between Unknown and I4
				//IL_000b: Unknown result type (might be due to invalid IL or missing references)
				//IL_0012: Invalid comparison between Unknown and I4
				//IL_0030: Unknown result type (might be due to invalid IL or missing references)
				//IL_0036: Invalid comparison between Unknown and I4
				if ((int)enemy.enemyType == 34 || (int)enemy.enemyType == 26)
				{
					Machine component3 = ((Component)enemy).GetComponent<Machine>();
					if ((Object)(object)component3 != (Object)null)
					{
						H_12_Machines_5.Add(component3);
					}
				}
				if ((int)enemy.enemyType == 1)
				{
					GameObjectExtensions.GetOrAddComponent<Drone_AntiSoftLock>(((Component)enemy).gameObject);
				}
			});
			Fento_Utils.Enemy_InStack(H_Wave_1.transform, delegate(EnemyIdentifier enemy)
			{
				//IL_0008: Unknown result type (might be due to invalid IL or missing references)
				//IL_000f: Invalid comparison between Unknown and I4
				//IL_0022: Unknown result type (might be due to invalid IL or missing references)
				//IL_0029: Invalid comparison between Unknown and I4
				//IL_0012: Unknown result type (might be due to invalid IL or missing references)
				//IL_0018: Invalid comparison between Unknown and I4
				//IL_006c: Unknown result type (might be due to invalid IL or missing references)
				//IL_0072: Invalid comparison between Unknown and I4
				//IL_009b: Unknown result type (might be due to invalid IL or missing references)
				//IL_00a2: Invalid comparison between Unknown and I4
				//IL_010a: Unknown result type (might be due to invalid IL or missing references)
				//IL_0111: Invalid comparison between Unknown and I4
				//IL_00dd: Unknown result type (might be due to invalid IL or missing references)
				//IL_00e3: Invalid comparison between Unknown and I4
				//IL_0114: Unknown result type (might be due to invalid IL or missing references)
				//IL_011b: Invalid comparison between Unknown and I4
				enemy.immuneToFriendlyFire = true;
				if ((int)enemy.enemyType != 34 && (int)enemy.enemyType != 1)
				{
					enemy.Sandify(false);
				}
				if ((int)enemy.enemyType == 35)
				{
					enemy.radianceTier += 3.5f;
					MortarLauncher component2 = ((Component)enemy).GetComponent<MortarLauncher>();
					if ((Object)(object)component2 != (Object)null)
					{
						component2.firingDelay = 3f;
						component2.firstFireDelay = 3f;
					}
				}
				else if ((int)enemy.enemyType == 1)
				{
					enemy.radianceTier += 0.85f;
					enemy.healthBuffModifier += 4.5f;
				}
				else if ((int)enemy.enemyType == 13)
				{
					enemy.radianceTier += 5f;
					enemy.damageBuffModifier += 2f;
					enemy.healthBuffModifier += 2f;
				}
				else if ((int)enemy.enemyType == 2)
				{
					enemy.healthBuffModifier += 0.2f;
					enemy.radianceTier += 0.65f;
				}
				if ((int)enemy.enemyType != 34 && (int)enemy.enemyType != 26)
				{
					enemy.BuffAll();
				}
			}, Hard_Mode_Only: true);
			Fento_Utils.Make_List_MachineSymbiote(H_12_Machines_5);
			Fento_Utils.Update_ActivateArena(H_ActivateArena_1, H_Wave_1.transform);
			Fento_Utils.Invoke_NextFrame(delegate
			{
				Fento_Utils.Clear_AreaFromClones(H_Wave_1_Clone.transform);
			});
			Fento_Utils.Integrate_Enemy(Fento_Utils.DetectebleEnemies.Cerberus, I_Wave_1.transform, active: false, new Vector3(190f, 53.0833f, 428f), Quaternion.Euler(0f, 90f, 0f));
			Fento_Utils.Integrate_Enemy(Fento_Utils.DetectebleEnemies.Cerberus, I_Wave_1.transform, active: false, new Vector3(214f, 53.0833f, 428f), Quaternion.Euler(0f, 270f, 0f));
			Fento_Utils.Integrate_Enemy(Fento_Utils.DetectebleEnemies.Turret, I_Wave_1.transform, active: false, new Vector3(190f, 53.0833f, 404f), Quaternion.Euler(0f, 0f, 0f));
			Fento_Utils.Integrate_Enemy(Fento_Utils.DetectebleEnemies.Turret, I_Wave_1.transform, active: false, new Vector3(214f, 53.0833f, 404f), Quaternion.Euler(0f, 0f, 0f));
			Fento_Utils.Integrate_Enemy(Fento_Utils.DetectebleEnemies.Idol, I_Wave_1.transform, active: false, new Vector3(216f, 72f, 416f), Quaternion.Euler(0f, 90f, 0f));
			Fento_Utils.Integrate_Enemy(Fento_Utils.DetectebleEnemies.Idol, I_Wave_1.transform, active: false, new Vector3(188f, 74f, 416f), Quaternion.Euler(0f, 270f, 0f));
			Fento_Utils.Enemy_InStack(I_Wave_1.transform, delegate(EnemyIdentifier enemy)
			{
				//IL_0001: Unknown result type (might be due to invalid IL or missing references)
				//IL_0008: Invalid comparison between Unknown and I4
				//IL_0026: Unknown result type (might be due to invalid IL or missing references)
				//IL_002c: Invalid comparison between Unknown and I4
				if ((int)enemy.enemyType == 21)
				{
					Idol component = ((Component)enemy).GetComponent<Idol>();
					if ((Object)(object)component != (Object)null)
					{
						I_Idols.Add(component);
					}
				}
				if ((int)enemy.enemyType != 4 && (Object)(object)I_ObjectActivator_1 != (Object)null && I_ObjectActivator_1.events != null)
				{
					I_ObjectActivator_1.events.toActivateObjects.Append(((Component)enemy).gameObject);
				}
			});
			Fento_Utils.Enemy_InStack(I_Wave_1.transform, delegate(EnemyIdentifier enemy)
			{
				//IL_0015: Unknown result type (might be due to invalid IL or missing references)
				//IL_001c: Invalid comparison between Unknown and I4
				enemy.immuneToFriendlyFire = true;
				enemy.Sandify(false);
				enemy.BuffAll();
				if ((int)enemy.enemyType == 21)
				{
					GameObjectExtensions.GetOrAddComponent<Idol_Buff_Radiance>(((Component)enemy).gameObject);
				}
			}, Hard_Mode_Only: true);
			Fento_Utils.Enemy_InStack(I_Boss.transform, delegate(EnemyIdentifier enemy)
			{
				//IL_0001: Unknown result type (might be due to invalid IL or missing references)
				//IL_0007: Invalid comparison between Unknown and I4
				if ((int)enemy.enemyType == 4)
				{
					I_Boss_MaliciousFace = enemy;
					GameObjectExtensions.GetOrAddComponent<Fento_DontLoop_Tag>(((Component)enemy).gameObject);
				}
			});
			Fento_Utils.Enemy_InStack(I_Boss.transform, delegate(EnemyIdentifier enemy)
			{
				//IL_0001: Unknown result type (might be due to invalid IL or missing references)
				//IL_0007: Invalid comparison between Unknown and I4
				if ((int)enemy.enemyType == 4)
				{
					enemy.immuneToFriendlyFire = true;
					enemy.Sandify(false);
					enemy.radianceTier += 1.2f;
					enemy.healthBuffModifier += 7.5f;
					enemy.damageBuffModifier += 0.1f;
					enemy.BuffAll();
				}
			}, Hard_Mode_Only: true);
			if ((Object)(object)I_Boss_MaliciousFace != (Object)null)
			{
				foreach (Idol i_Idol in I_Idols)
				{
					i_Idol.overrideTarget = I_Boss_MaliciousFace;
				}
			}
			I_ActivateNextWave_1.enemyCount = 7;
			Fento_Utils.Update_ActivateArena(I_ActivateArena_1, I_Wave_1.transform);
			Fento_Utils.Invoke_NextFrame(delegate
			{
				Fento_Utils.Clear_AreaFromClones(I_Wave_1.transform);
			});
		}
	}
}
public static class Waves_Patches_Debug
{
	[HarmonyPatch(typeof(EnemyIdentifier), "Start")]
	[HarmonyPrefix]
	public static void EnemyIdentifier__Debug(EnemyIdentifier __instance)
	{
		Fento_Loader._Logger.LogInfo((object)("Activated EnemyIdentifier " + Fento_Utils.GetFullRootPath(((Component)__instance).transform)));
		if (Difficulty_Options.Global_Enable_Modify_Everyone)
		{
			GameObjectExtensions.GetOrAddComponent<Fento_DontLoop_Tag>(((Component)__instance).gameObject);
		}
	}

	[HarmonyPatch(typeof(ActivateNextWave), "Awake")]
	[HarmonyPostfix]
	public static void Awake__ActivateNextWaveWave__Debug(ActivateNextWave __instance)
	{
		Fento_Core.History++;
		Fento_Loader._Logger.LogInfo((object)("ActivateNextWave Found Pos - " + Fento_Core.History));
		if ((Object)(object)((Component)__instance).gameObject.GetComponentInParent<GoreZone>() == (Object)null)
		{
			Fento_Loader._Logger.LogInfo((object)("ActivateNextWave No GoreZone found in hierarchy of " + Fento_Utils.GetFullRootPath(((Component)__instance).transform)));
		}
		else
		{
			Fento_Loader._Logger.LogInfo((object)$"ActivateNextWave {Fento_Utils.GetFullRootPath(((Component)__instance).transform)} - Count {__instance.enemyCount}");
		}
	}

	[HarmonyPatch(typeof(ActivateNextWave), "SpawnEnemy")]
	[HarmonyPostfix]
	public static void Spawn__ActivateNextWaveWave__Debug(ActivateNextWave __instance)
	{
		Fento_Core.ActiveHistory++;
		Fento_Loader._Logger.LogInfo((object)("spawner Found Pos - " + Fento_Core.ActiveHistory));
		Fento_Loader._Logger.LogInfo((object)$"Spawn ActivateNextWave {Fento_Utils.GetFullRootPath(((Component)__instance).transform)} - Count {__instance.enemyCount}");
	}

	[HarmonyPatch(typeof(ActivateNextWaveHP), "OnEnable")]
	public static void Awake__ActivateNextWaveHP__Debug(ActivateNextWaveHP __instance)
	{
		Fento_Core.History++;
		Fento_Loader._Logger.LogInfo((object)("ActivateNextWaveHP Found Pos - " + Fento_Core.History));
		if ((Object)(object)((Component)__instance).gameObject.GetComponentInParent<GoreZone>() == (Object)null)
		{
			Fento_Loader._Logger.LogInfo((object)("ActivateNextWaveHP No GoreZone found in hierarchy of " + Fento_Utils.GetFullRootPath(((Component)__instance).transform)));
		}
		else
		{
			Fento_Loader._Logger.LogInfo((object)$"ActivateNextWaveHP {Fento_Utils.GetFullRootPath(((Component)__instance).transform)} - Count {__instance.nextEnemies.Count()}");
		}
	}

	[HarmonyPatch(typeof(ActivateNextWaveHP), "SpawnEnemy")]
	[HarmonyPostfix]
	public static void Spawn__ActivateNextWaveHP__Debug(ActivateNextWave __instance)
	{
		Fento_Core.ActiveHistory++;
		Fento_Loader._Logger.LogInfo((object)("spawner Found Pos - " + Fento_Core.ActiveHistory));
		Fento_Loader._Logger.LogInfo((object)$"Spawn ActivateNextWaveHP {Fento_Utils.GetFullRootPath(((Component)__instance).transform)} - Count {__instance.enemyCount}");
	}

	[HarmonyPatch(typeof(ActivateArena), "OnEnable")]
	[HarmonyPostfix]
	public static void Awake__ActivateArena__Debug(ActivateArena __instance)
	{
		Fento_Core.History++;
		Fento_Loader._Logger.LogInfo((object)("ActivateArena Found Pos - " + Fento_Core.History));
		if ((Object)(object)((Component)__instance).gameObject.GetComponentInParent<GoreZone>() == (Object)null)
		{
			Fento_Loader._Logger.LogInfo((object)("ActivateArena No GoreZone found in hierarchy of " + Fento_Utils.GetFullRootPath(((Component)__instance).transform)));
		}
		else
		{
			Fento_Loader._Logger.LogInfo((object)$"ActivateArena {Fento_Utils.GetFullRootPath(((Component)__instance).transform)} - Count {__instance.enemies.Count()}");
		}
	}

	[HarmonyPatch(typeof(ActivateArena), "SpawnEnemy")]
	[HarmonyPostfix]
	public static void Spawn__ActivateArena__Debug(ActivateNextWave __instance)
	{
		Fento_Core.ActiveHistory++;
		Fento_Loader._Logger.LogInfo((object)("spawner Found Pos - " + Fento_Core.ActiveHistory));
		Fento_Loader._Logger.LogInfo((object)$"Spawn ActivateArena {Fento_Utils.GetFullRootPath(((Component)__instance).transform)} - Count {__instance.enemyCount}");
	}
}
public static class Other_Classes
{
	[HarmonyPatch(typeof(NewMovement), "GetHurt")]
	[HarmonyPrefix]
	private static void Prefix(ref float hardDamageMultiplier)
	{
		hardDamageMultiplier *= Difficulty_Options.Varb_Multiply_HardDamage;
	}
}
public class Fento_DontLoop_Tag : MonoBehaviour
{
	private EnemyIdentifier eid;

	public void Start()
	{
		//IL_01cc: Unknown result type (might be due to invalid IL or missing references)
		//IL_01d3: Invalid comparison between Unknown and I4
		eid = ((Component)this).GetComponent<EnemyIdentifier>();
		if (!((Object)(object)eid == (Object)null))
		{
			if (Difficulty_Options.Res_Forse_All_ImmuneFriendly)
			{
				eid.immuneToFriendlyFire = true;
			}
			if (Difficulty_Options.Res_Forse_All_PreSanded && !eid.sandified)
			{
				eid.Sandify(false);
			}
			if (Difficulty_Options.Issue_Disable_PreSanded && eid.sandified)
			{
				eid.Desandify(false);
			}
			if (Difficulty_Options.Varb_Radiance_Health_Mult != 1f)
			{
				EnemyIdentifier obj = eid;
				obj.healthBuffModifier *= Difficulty_Options.Varb_Radiance_Health_Mult;
			}
			if (Difficulty_Options.Varb_Radiance_Damage_Mult != 1f)
			{
				EnemyIdentifier obj2 = eid;
				obj2.damageBuffModifier *= Difficulty_Options.Varb_Radiance_Damage_Mult;
			}
			if (Difficulty_Options.Varb_Radiance_Speed_Mult != 1f)
			{
				EnemyIdentifier obj3 = eid;
				obj3.speedBuffModifier *= Difficulty_Options.Varb_Radiance_Speed_Mult;
			}
			if (Difficulty_Options.Res_Forse_All_Radiance)
			{
				eid.BuffAll();
			}
			if (Difficulty_Options.Varb_Add_Radiance_Tier != 0f)
			{
				EnemyIdentifier obj4 = eid;
				obj4.radianceTier += Difficulty_Options.Varb_Add_Radiance_Tier;
				eid.UpdateBuffs(false, true);
			}
			if (Difficulty_Options.Varb_Multiply_Radiance_Tier != 1f)
			{
				EnemyIdentifier obj5 = eid;
				obj5.radianceTier *= Difficulty_Options.Varb_Multiply_Radiance_Tier;
				eid.UpdateBuffs(false, true);
			}
			if (Difficulty_Options.Issue_Disable_Radiance && (eid.damageBuff || eid.speedBuff || eid.healthBuff))
			{
				eid.damageBuffRequests = 0;
				eid.speedBuffRequests = 0;
				eid.healthBuffRequests = 0;
				eid.radianceTier = 0f;
				eid.UpdateBuffs(false, true);
			}
			if (Difficulty_Options.Global_Enable_Modify_Everyone && Difficulty_Options.Mech_Disable_RadIdols_Buff && (int)eid.enemyType == 21)
			{
				GameObjectExtensions.GetOrAddComponent<Idol_Buff_Radiance>(((Component)eid).gameObject);
			}
		}
	}
}
public class Add_Fento_Marked : MonoBehaviour
{
	public bool Real_Level;

	public void OnEnable()
	{
		if (!Difficulty_Options.Global_Enable_Modify_Everyone && (!Real_Level || Difficulty_Options.Global_Disable_Level_Changes))
		{
			return;
		}
		Fento_Utils.Invoke_WithDelay(0.01f, delegate
		{
			TextMeshProUGUI component = ((Component)this).GetComponent<TextMeshProUGUI>();
			if ((Object)(object)component != (Object)null)
			{
				string text = (Difficulty_Options.Skill_Issue ? "<color=#3DCC00> + Fento</color>" : "<color=#FF0000> + Fento</color>");
				if (!((TMP_Text)component).text.Contains(text))
				{
					((TMP_Text)component).text = ((TMP_Text)component).text + text;
				}
			}
		});
	}
}
public class Add_Fento_Skill_Marked : MonoBehaviour
{
	public bool Real_Level;

	public void OnEnable()
	{
		if (!Difficulty_Options.Global_Enable_Modify_Everyone && (!Real_Level || Difficulty_Options.Global_Disable_Level_Changes))
		{
			return;
		}
		Fento_Utils.Invoke_WithDelay(0.01f, delegate
		{
			TextMeshProUGUI component = ((Component)this).GetComponent<TextMeshProUGUI>();
			if ((Object)(object)component != (Object)null)
			{
				string text = "";
				if (Difficulty_Options.Skill_Issue)
				{
					text = $"<color=#3DCC00>- SKILL ISSUE x{Difficulty_Options.Count_Issues_With_Skill}</color>";
				}
				else
				{
					int i = 0;
					i.AddCount(new bool[1] { Real_Level });
					i += Difficulty_Options.Count_Extra_Skill_Respect;
					text = ((i != 0) ? $"<color=#FF0000>+ RESPECT+ x{i}</color>\n  (+{(Real_Level ? 750 : 0) + 350 * Difficulty_Options.Count_Extra_Skill_Respect}<color=orange>AURA</color>)" : "<color=#FF0000>+ RESPECT");
				}
				if (!((TMP_Text)component).text.Contains(text))
				{
					((TMP_Text)component).text = ((TMP_Text)component).text + text + "\n";
				}
			}
		});
	}
}
public class Drone_AntiSoftLock : MonoBehaviour
{
	public Vector3 Start;

	public float T;

	public float ReqTime = 5f;

	public void Awake()
	{
		//IL_0007: Unknown result type (might be due to invalid IL or missing references)
		//IL_000c: Unknown result type (might be due to invalid IL or missing references)
		Start = ((Component)this).transform.position;
	}

	public void FixedUpdate()
	{
		//IL_0032: Unknown result type (might be due to invalid IL or missing references)
		T += Time.fixedDeltaTime;
		if (T > ReqTime)
		{
			T = 0f;
			((Component)this).transform.position = Start;
		}
	}
}
public class Idol_Buff_Radiance : MonoBehaviour
{
	public float TierToAdd = 1.5f;

	public EnemyIdentifier LastFound;

	private EnemyIdentifier eid;

	private Idol Idol;

	public void OnEnable()
	{
		if (Difficulty_Options.Mech_Disable_RadIdols_Buff)
		{
			Object.Destroy((Object)(object)this);
			return;
		}
		Idol = ((Component)this).GetComponent<Idol>();
		eid = ((Component)this).GetComponent<EnemyIdentifier>();
	}

	public void FixedUpdate()
	{
		if (!((Object)(object)Idol == (Object)null) && (Object)(object)Idol.target != (Object)null && (Object)(object)Idol.target != (Object)(object)LastFound)
		{
			LastFound = Idol.target;
		}
	}

	public void OnDisable()
	{
		if ((Object)(object)LastFound != (Object)null)
		{
			EnemyIdentifier lastFound = LastFound;
			lastFound.radianceTier += TierToAdd;
			LastFound.BuffAll();
		}
	}
}