Decompiled source of DebloatedSeeker v1.0.0

DebloatedSeeker.dll

Decompiled a day ago
using System;
using System.Collections;
using System.Collections.Generic;
using System.Diagnostics;
using System.Linq;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.Versioning;
using System.Security;
using System.Security.Permissions;
using System.Text.RegularExpressions;
using AncientScepter;
using BepInEx;
using BepInEx.Bootstrap;
using DebloatedSeeker.Modules;
using EntityStates;
using EntityStates.Seeker;
using IL.EntityStates.Seeker;
using IL.RoR2;
using Microsoft.CodeAnalysis;
using Mono.Cecil.Cil;
using MonoMod.Cil;
using On;
using On.EntityStates.Seeker;
using On.RoR2;
using R2API;
using R2API.Utils;
using RoR2;
using RoR2.ContentManagement;
using RoR2.HudOverlay;
using RoR2.Projectile;
using RoR2.Skills;
using UnityEngine;
using UnityEngine.AddressableAssets;
using UnityEngine.Networking;
using UnityEngine.ResourceManagement.AsyncOperations;

[assembly: CompilationRelaxations(8)]
[assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)]
[assembly: Debuggable(DebuggableAttribute.DebuggingModes.Default | DebuggableAttribute.DebuggingModes.DisableOptimizations | DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints | DebuggableAttribute.DebuggingModes.EnableEditAndContinue)]
[assembly: TargetFramework(".NETStandard,Version=v2.1", FrameworkDisplayName = ".NET Standard 2.1")]
[assembly: AssemblyCompany("DebloatedSeeker")]
[assembly: AssemblyConfiguration("Debug")]
[assembly: AssemblyFileVersion("1.0.0.0")]
[assembly: AssemblyInformationalVersion("1.0.0+740d638e0822071bdf5f69c255e36ef02194e032")]
[assembly: AssemblyProduct("DebloatedSeeker")]
[assembly: AssemblyTitle("DebloatedSeeker")]
[assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)]
[assembly: AssemblyVersion("1.0.0.0")]
[module: UnverifiableCode]
namespace Microsoft.CodeAnalysis
{
	[CompilerGenerated]
	[Microsoft.CodeAnalysis.Embedded]
	internal sealed class EmbeddedAttribute : Attribute
	{
	}
}
namespace System.Runtime.CompilerServices
{
	[CompilerGenerated]
	[Microsoft.CodeAnalysis.Embedded]
	[AttributeUsage(AttributeTargets.Class | AttributeTargets.Property | AttributeTargets.Field | AttributeTargets.Event | AttributeTargets.Parameter | AttributeTargets.ReturnValue | AttributeTargets.GenericParameter, AllowMultiple = false, Inherited = false)]
	internal sealed class NullableAttribute : Attribute
	{
		public readonly byte[] NullableFlags;

		public NullableAttribute(byte P_0)
		{
			NullableFlags = new byte[1] { P_0 };
		}

		public NullableAttribute(byte[] P_0)
		{
			NullableFlags = P_0;
		}
	}
	[CompilerGenerated]
	[Microsoft.CodeAnalysis.Embedded]
	[AttributeUsage(AttributeTargets.Class | AttributeTargets.Struct | AttributeTargets.Method | AttributeTargets.Interface | AttributeTargets.Delegate, AllowMultiple = false, Inherited = false)]
	internal sealed class NullableContextAttribute : Attribute
	{
		public readonly byte Flag;

		public NullableContextAttribute(byte P_0)
		{
			Flag = P_0;
		}
	}
}
namespace DebloatedSeeker
{
	public class Buffs
	{
		[Serializable]
		[CompilerGenerated]
		private sealed class <>c
		{
			public static readonly <>c <>9 = new <>c();

			public static Func<Instruction, bool> <>9__2_2;

			public static Func<bool, CharacterBody, bool> <>9__2_1;

			public static Manipulator <>9__2_0;

			internal void <CreateTranquility2>b__2_0(ILContext il)
			{
				//IL_0002: Unknown result type (might be due to invalid IL or missing references)
				//IL_0008: Expected O, but got Unknown
				//IL_004b: Unknown result type (might be due to invalid IL or missing references)
				ILCursor val = new ILCursor(il);
				if (val.TryGotoNext(new Func<Instruction, bool>[1]
				{
					(Instruction x) => ILPatternMatchingExt.MatchLdsfld(x, typeof(Buffs), "WarCryBuff")
				}))
				{
					val.Index += 2;
					val.Emit(OpCodes.Ldarg_0);
					val.EmitDelegate<Func<bool, CharacterBody, bool>>((Func<bool, CharacterBody, bool>)((bool hasWarCry, CharacterBody self) => hasWarCry || self.HasBuff(Tranquility2)));
				}
				else
				{
					Debug.LogError((object)"DebloatedSeeker: OnClientBuffsChanged IL hook failed.");
				}
			}

			internal bool <CreateTranquility2>b__2_2(Instruction x)
			{
				return ILPatternMatchingExt.MatchLdsfld(x, typeof(Buffs), "WarCryBuff");
			}

			internal bool <CreateTranquility2>b__2_1(bool hasWarCry, CharacterBody self)
			{
				return hasWarCry || self.HasBuff(Tranquility2);
			}
		}

		public static BuffDef Tranquility2;

		internal static void Init()
		{
			CreateTranquility2();
		}

		private static void CreateTranquility2()
		{
			//IL_0019: Unknown result type (might be due to invalid IL or missing references)
			//IL_001e: Unknown result type (might be due to invalid IL or missing references)
			//IL_0050: Unknown result type (might be due to invalid IL or missing references)
			//IL_0055: 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_0096: Expected O, but got Unknown
			//IL_009e: Unknown result type (might be due to invalid IL or missing references)
			//IL_00a8: Expected O, but got Unknown
			//IL_00bd: 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_00c8: Expected O, but got Unknown
			if (Object.op_Implicit((Object)(object)Tranquility2))
			{
				return;
			}
			BuffDef val = Addressables.LoadAssetAsync<BuffDef>((object)"RoR2/DLC2/Seeker/RevitalizeBuff/bdRevitalizeBuff.asset").WaitForCompletion();
			BuffDef val2 = ScriptableObject.CreateInstance<BuffDef>();
			((Object)val2).name = "DebloatedSeekerTranquility";
			val2.canStack = true;
			val2.isCooldown = false;
			val2.isDebuff = false;
			val2.buffColor = val.buffColor;
			val2.iconSprite = val.iconSprite;
			PluginContentPack.buffDefs.Add(val2);
			((Object)val2).name = ((Object)val2).name;
			Tranquility2 = val2;
			RecalculateStatsAPI.GetStatCoefficients += new StatHookEventHandler(RecalculateStatsAPI_GetStatCoefficients);
			CharacterBody.AddTimedBuff_BuffDef_float += new hook_AddTimedBuff_BuffDef_float(CharacterBody_AddTimedBuff_BuffDef_float);
			object obj = <>c.<>9__2_0;
			if (obj == null)
			{
				Manipulator val3 = delegate(ILContext il)
				{
					//IL_0002: Unknown result type (might be due to invalid IL or missing references)
					//IL_0008: Expected O, but got Unknown
					//IL_004b: Unknown result type (might be due to invalid IL or missing references)
					ILCursor val4 = new ILCursor(il);
					if (val4.TryGotoNext(new Func<Instruction, bool>[1]
					{
						(Instruction x) => ILPatternMatchingExt.MatchLdsfld(x, typeof(Buffs), "WarCryBuff")
					}))
					{
						val4.Index += 2;
						val4.Emit(OpCodes.Ldarg_0);
						val4.EmitDelegate<Func<bool, CharacterBody, bool>>((Func<bool, CharacterBody, bool>)((bool hasWarCry, CharacterBody self) => hasWarCry || self.HasBuff(Tranquility2)));
					}
					else
					{
						Debug.LogError((object)"DebloatedSeeker: OnClientBuffsChanged IL hook failed.");
					}
				};
				<>c.<>9__2_0 = val3;
				obj = (object)val3;
			}
			CharacterBody.OnClientBuffsChanged += (Manipulator)obj;
		}

		private static void CharacterBody_AddTimedBuff_BuffDef_float(orig_AddTimedBuff_BuffDef_float orig, CharacterBody self, BuffDef buffDef, float duration)
		{
			//IL_0034: Unknown result type (might be due to invalid IL or missing references)
			//IL_003a: Unknown result type (might be due to invalid IL or missing references)
			orig.Invoke(self, buffDef, duration);
			if (!((Object)(object)buffDef == (Object)(object)Tranquility2))
			{
				return;
			}
			foreach (TimedBuff timedBuff in self.timedBuffs)
			{
				if (timedBuff.buffIndex == buffDef.buffIndex && timedBuff.timer < duration)
				{
					timedBuff.timer = duration;
				}
			}
		}

		private static void RecalculateStatsAPI_GetStatCoefficients(CharacterBody sender, StatHookEventArgs args)
		{
			int buffCount = sender.GetBuffCount(Tranquility2);
			if (buffCount > 0)
			{
				args.attackSpeedMultAdd += 0.3f * (float)buffCount;
				args.moveSpeedMultAdd += 0.3f * (float)buffCount;
				args.regenMultAdd += 0.3f * (float)buffCount;
			}
		}
	}
	[BepInDependency(/*Could not decode attribute arguments.*/)]
	[BepInDependency(/*Could not decode attribute arguments.*/)]
	[BepInDependency(/*Could not decode attribute arguments.*/)]
	[BepInDependency(/*Could not decode attribute arguments.*/)]
	[BepInDependency(/*Could not decode attribute arguments.*/)]
	[NetworkCompatibility(/*Could not decode attribute arguments.*/)]
	[BepInPlugin("com.Moffein.DebloatedSeeker", "DebloatedSeeker", "1.0.0")]
	public class DebloatedSeekerPlugin : BaseUnityPlugin
	{
		private static GameObject cleanseEffect = Addressables.LoadAssetAsync<GameObject>((object)"RoR2/DLC2/Seeker/SpiritPunchMuzzleFlashVFX.prefab").WaitForCompletion();

		internal void Awake()
		{
			//IL_0031: 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)
			//IL_0087: Unknown result type (might be due to invalid IL or missing references)
			//IL_0091: Expected O, but got Unknown
			PluginUtils.scepterLoaded = Chainloader.PluginInfos.ContainsKey("com.DestroyedClone.AncientScepter");
			new PluginContentPack().Initialize();
			LanguageTokens.Init();
			Buffs.Init();
			GameObject seekerObject = Addressables.LoadAssetAsync<GameObject>((object)"RoR2/DLC2/Seeker/SeekerBody.prefab").WaitForCompletion();
			NerfBaseStats(seekerObject);
			DisablePassive(seekerObject);
			DebloatSpiritPunch();
			DebloatUnseenHand();
			DebloatSojourn();
			DebloatMeditate();
			DebloatSoulSpiral();
			DebloatReprieve();
			DebloatPalmBlast();
			Language.GetLocalizedStringByToken += new hook_GetLocalizedStringByToken(Language_GetLocalizedStringByToken);
			RoR2Application.onLoad = (Action)Delegate.Combine(RoR2Application.onLoad, new Action(OnLoadActions));
		}

		private void OnLoadActions()
		{
			//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)
			PluginUtils.ScepterIndex = ItemCatalog.FindItemIndex("ITEM_ANCIENT_SCEPTER");
		}

		private string Language_GetLocalizedStringByToken(orig_GetLocalizedStringByToken orig, Language self, string token)
		{
			string text = orig.Invoke(self, token);
			if (text != token)
			{
				switch (token)
				{
				case "SEEKER_PRIMARY_DESCRIPTION":
					text = text.Replace("350", "500");
					break;
				case "SEEKER_SECONDARY_DESCRIPTION":
					text = Regex.Replace(text.Replace("600", "1200"), "3.*5", "5", RegexOptions.None);
					break;
				case "SEEKER_SPECIAL_ALT1_DESCRIPTION":
					text = text.Replace("400", "1000").Replace("700", "2000");
					break;
				}
			}
			return text;
		}

		private void NerfBaseStats(GameObject seekerObject)
		{
			CharacterBody component = seekerObject.GetComponent<CharacterBody>();
			component.armor = 0f;
			component.baseMaxHealth = 90f;
			component.levelMaxHealth = 27f;
			component.baseRegen = 1f;
			component.levelRegen = 0.2f;
		}

		private void DisablePassive(GameObject seekerObject)
		{
			//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)
			//IL_007c: Unknown result type (might be due to invalid IL or missing references)
			//IL_0086: Expected O, but got Unknown
			//IL_008e: Unknown result type (might be due to invalid IL or missing references)
			//IL_0098: Expected O, but got Unknown
			SurvivorDef val = Addressables.LoadAssetAsync<SurvivorDef>((object)"RoR2/DLC2/Seeker/Seeker.asset").WaitForCompletion();
			val.descriptionToken = "SEEKER_DESCRIPTION_DEBLOATED";
			GenericSkill[] components = seekerObject.GetComponents<GenericSkill>();
			GenericSkill val2 = null;
			GenericSkill[] array = components;
			foreach (GenericSkill val3 in array)
			{
				if (val3.skillName == "InnerStrength")
				{
					val3.hideInCharacterSelect = true;
					val3.hideInLoadoutSelect = true;
					val2 = val3;
					break;
				}
			}
			SeekerController.CmdIncrementChakraGate += new hook_CmdIncrementChakraGate(SpawnChakraVFXOnly);
			SeekerController.OnEnable += new hook_OnEnable(RemoveOverlay);
		}

		private void RemoveOverlay(orig_OnEnable orig, SeekerController self)
		{
			orig.Invoke(self);
			if (self.overlayController != null)
			{
				HudOverlayManager.RemoveOverlay(self.overlayController);
			}
		}

		private void SpawnChakraVFXOnly(orig_CmdIncrementChakraGate orig, SeekerController self)
		{
			//IL_0048: Unknown result type (might be due to invalid IL or missing references)
			//IL_004f: Expected O, but got Unknown
			//IL_0056: Unknown result type (might be due to invalid IL or missing references)
			//IL_005b: Unknown result type (might be due to invalid IL or missing references)
			//IL_006d: Unknown result type (might be due to invalid IL or missing references)
			//IL_0072: Unknown result type (might be due to invalid IL or missing references)
			//IL_007a: Unknown result type (might be due to invalid IL or missing references)
			//IL_0090: Unknown result type (might be due to invalid IL or missing references)
			//IL_0214: Unknown result type (might be due to invalid IL or missing references)
			//IL_0219: Unknown result type (might be due to invalid IL or missing references)
			//IL_0220: Unknown result type (might be due to invalid IL or missing references)
			//IL_0231: Expected O, but got Unknown
			//IL_0128: Unknown result type (might be due to invalid IL or missing references)
			//IL_00cc: Unknown result type (might be due to invalid IL or missing references)
			//IL_0264: Unknown result type (might be due to invalid IL or missing references)
			//IL_00f5: Unknown result type (might be due to invalid IL or missing references)
			if (!NetworkServer.active || !Object.op_Implicit((Object)(object)self.specialSkillSlot))
			{
				return;
			}
			if ((Object)(object)self.specialSkillSlot.baseSkill == (Object)(object)self.meditateSkillDef)
			{
				List<HurtBox> list = new List<HurtBox>();
				List<CharacterBody> list2 = new List<CharacterBody>();
				SphereSearch val = new SphereSearch();
				val.mask = ((LayerIndex)(ref LayerIndex.entityPrecise)).mask;
				val.origin = ((Component)self).gameObject.transform.position;
				val.queryTriggerInteraction = (QueryTriggerInteraction)2;
				val.radius = 25f;
				bool flag = false;
				TeamMask val2 = default(TeamMask);
				if (Object.op_Implicit((Object)(object)self.characterBody))
				{
					if (Object.op_Implicit((Object)(object)self.characterBody.teamComponent))
					{
						((TeamMask)(ref val2)).AddTeam(self.characterBody.teamComponent.teamIndex);
					}
					if (Object.op_Implicit((Object)(object)self.characterBody.inventory) && self.characterBody.inventory.GetItemCountEffective(PluginUtils.ScepterIndex) > 0)
					{
						flag = true;
					}
				}
				val.RefreshCandidates();
				val.FilterCandidatesByDistinctHurtBoxEntities();
				val.RefreshCandidates().FilterCandidatesByHurtBoxTeam(val2).FilterCandidatesByDistinctHurtBoxEntities()
					.GetHurtBoxes(list);
				int i = 0;
				for (int count = list.Count; i < count; i++)
				{
					HealthComponent healthComponent = list[i].healthComponent;
					if (Object.op_Implicit((Object)(object)healthComponent) && Object.op_Implicit((Object)(object)healthComponent.body) && !list2.Contains(healthComponent.body))
					{
						list2.Add(healthComponent.body);
						healthComponent.body.AddTimedBuff(Buffs.Tranquility2, 10f);
						if (flag)
						{
							healthComponent.body.AddTimedBuff(Buffs.Tranquility2, 10f);
						}
					}
				}
			}
			else
			{
				if (!((Object)(object)self.specialSkillSlot.baseSkill == (Object)(object)self.palmBlastSkillDef))
				{
					return;
				}
				EffectManager.SpawnEffect(self.palmBlastSuccessEffectPrefab, new EffectData
				{
					origin = self.characterBody.corePosition
				}, true);
				bool flag2 = false;
				if (Object.op_Implicit((Object)(object)self.characterBody))
				{
					if (Object.op_Implicit((Object)(object)self.characterBody.inventory) && self.characterBody.inventory.GetItemCountEffective(PluginUtils.ScepterIndex) > 0)
					{
						flag2 = true;
					}
					self.characterBody.AddTimedBuff(Buffs.Tranquility2, 10f);
					if (flag2)
					{
						self.characterBody.AddTimedBuff(Buffs.Tranquility2, 10f);
					}
				}
			}
		}

		private void DebloatSpiritPunch()
		{
			//IL_0045: Unknown result type (might be due to invalid IL or missing references)
			//IL_004a: Unknown result type (might be due to invalid IL or missing references)
			PluginUtils.SetAddressableEntityStateField("RoR2/DLC2/Seeker/EntityStates.Seeker.SpiritPunch.asset", "damageCoefficient", "2.5");
			PluginUtils.SetAddressableEntityStateField("RoR2/DLC2/Seeker/EntityStates.Seeker.SpiritPunch.asset", "comboDamageCoefficient", "5");
			PluginUtils.SetAddressableEntityStateField("RoR2/DLC2/Seeker/EntityStates.Seeker.SpiritPunch.asset", "dmgBuffIncrease", "0");
			SkillDef skillDef = Addressables.LoadAssetAsync<SkillDef>((object)"RoR2/DLC2/Seeker/SeekerBodySpiritPunchCrosshair.asset").WaitForCompletion();
			PluginUtils.RemoveTranquilityKeyword(skillDef);
		}

		private void DebloatUnseenHand()
		{
			//IL_001b: Unknown result type (might be due to invalid IL or missing references)
			//IL_0020: Unknown result type (might be due to invalid IL or missing references)
			//IL_0073: Unknown result type (might be due to invalid IL or missing references)
			//IL_0078: Unknown result type (might be due to invalid IL or missing references)
			PluginUtils.SetAddressableEntityStateField("RoR2/DLC2/Seeker/EntityStates.Seeker.UnseenHand.asset", "fistDamageCoefficient", "12");
			GameObject val = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync<GameObject>((object)"RoR2/DLC2/Seeker/UnseenHandMovingProjectile.prefab").WaitForCompletion(), "DebloatedSeekerUnseenHandMovingProjectile", true);
			PluginContentPack.projectilePrefabs.Add(val);
			UnseenHandHealingProjectile component = val.GetComponent<UnseenHandHealingProjectile>();
			component.chakraIncrease = 0f;
			component.fractionOfDamage = 0.035f;
			PluginUtils.SetAddressableEntityStateField("RoR2/DLC2/Seeker/EntityStates.Seeker.UnseenHand.asset", "fistProjectilePrefab", (Object)(object)val);
			SkillDef skillDef = Addressables.LoadAssetAsync<SkillDef>((object)"RoR2/DLC2/Seeker/SeekerBodyUnseenHand.asset").WaitForCompletion();
			PluginUtils.RemoveTranquilityKeyword(skillDef);
		}

		private void DebloatSojourn()
		{
			//IL_0008: Unknown result type (might be due to invalid IL or missing references)
			//IL_0012: Expected O, but got Unknown
			//IL_0018: Unknown result type (might be due to invalid IL or missing references)
			//IL_001d: Unknown result type (might be due to invalid IL or missing references)
			SojournVehicle.UpdateBlastRadius += new Manipulator(SojournVehicle_UpdateBlastRadius);
			SkillDef skillDef = Addressables.LoadAssetAsync<SkillDef>((object)"RoR2/DLC2/Seeker/SeekerBodySojourn.asset").WaitForCompletion();
			PluginUtils.RemoveTranquilityKeyword(skillDef);
		}

		private void SojournVehicle_UpdateBlastRadius(ILContext il)
		{
			//IL_0002: Unknown result type (might be due to invalid IL or missing references)
			//IL_0008: Expected O, but got Unknown
			ILCursor val = new ILCursor(il);
			if (val.TryGotoNext((MoveType)2, new Func<Instruction, bool>[1]
			{
				(Instruction x) => ILPatternMatchingExt.MatchCallvirt<CharacterBody>(x, "GetBuffCount")
			}))
			{
				val.EmitDelegate<Func<int, int>>((Func<int, int>)((int orig) => 5));
			}
			else
			{
				Debug.LogError((object)"DebloatedSeeker: SojournVehicle_UpdateBlastRadius IL hook failed.");
			}
		}

		private void DebloatMeditate()
		{
			//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)
			//IL_00a3: Unknown result type (might be due to invalid IL or missing references)
			//IL_00ad: Expected O, but got Unknown
			//IL_00b5: Unknown result type (might be due to invalid IL or missing references)
			//IL_00bf: Expected O, but got Unknown
			//IL_00c7: Unknown result type (might be due to invalid IL or missing references)
			//IL_00d1: Expected O, but got Unknown
			//IL_011c: Unknown result type (might be due to invalid IL or missing references)
			//IL_0121: Unknown result type (might be due to invalid IL or missing references)
			//IL_01ac: Unknown result type (might be due to invalid IL or missing references)
			//IL_01b1: Unknown result type (might be due to invalid IL or missing references)
			SkillDef val = Addressables.LoadAssetAsync<SkillDef>((object)"RoR2/DLC2/Seeker/SeekerBodyMeditate.asset").WaitForCompletion();
			val.keywordTokens = new string[1] { "SEEKER_TRANQUILITY_DEBLOATED" };
			val.skillDescriptionToken = "SEEKER_SPECIAL_DESCRIPTION_DEBLOATED";
			PluginUtils.SetAddressableEntityStateField("RoR2/DLC2/Seeker/EntityStates.Seeker.Meditate.asset", "damageCoefficient", "20");
			PluginUtils.SetAddressableEntityStateField("RoR2/DLC2/Seeker/EntityStates.Seeker.Meditate.asset", "percentPerGate", "0");
			PluginUtils.SetAddressableEntityStateField("RoR2/DLC2/Seeker/EntityStates.Seeker.Meditate.asset", "blastProcCoefficient", "1");
			PluginUtils.SetAddressableEntityStateField("RoR2/DLC2/Seeker/EntityStates.Seeker.Meditate.asset", "blastRadiusScaling", "0");
			PluginUtils.SetAddressableEntityStateField("RoR2/DLC2/Seeker/EntityStates.Seeker.Meditate.asset", "blastRadius", "25");
			SeekerController.CmdTriggerHealPulse += new hook_CmdTriggerHealPulse(SeekerController_CmdTriggerHealPulse);
			Meditate.Update += new Manipulator(Meditate_Update);
			Meditate.OnEnter += new hook_OnEnter(MeditateScepterStats);
			if (PluginUtils.scepterLoaded)
			{
				SkillDef val2 = ScriptableObject.CreateInstance<SkillDef>();
				val2.skillNameToken = "ANCIENTSCEPTER_SEEKER_MEDITATENAME";
				val2.skillDescriptionToken = "SEEKER_SPECIAL_DESCRIPTION_DEBLOATED_SCEPTER";
				val2.icon = null;
				val2.beginSkillCooldownOnSkillEnd = val.beginSkillCooldownOnSkillEnd;
				val2.baseMaxStock = val.baseMaxStock;
				val2.activationState = val.activationState;
				val2.activationStateMachineName = val.activationStateMachineName;
				val2.attackSpeedBuffsRestockSpeed = val.attackSpeedBuffsRestockSpeed;
				val2.attackSpeedBuffsRestockSpeed_Multiplier = val.attackSpeedBuffsRestockSpeed_Multiplier;
				val2.autoHandleLuminousShot = val.autoHandleLuminousShot;
				val2.cancelSprintingOnActivation = val.cancelSprintingOnActivation;
				val2.canceledFromSprinting = val.canceledFromSprinting;
				val2.dontAllowPastMaxStocks = val.dontAllowPastMaxStocks;
				val2.forceSprintDuringState = val.forceSprintDuringState;
				val2.fullRestockOnAssign = val.forceSprintDuringState;
				val2.hideCooldown = val.hideCooldown;
				val2.hideStockCount = val.hideStockCount;
				val2.interruptPriority = val.interruptPriority;
				val2.isCombatSkill = val.isCombatSkill;
				val2.isCooldownBlockedUntilManuallyReset = val.isCooldownBlockedUntilManuallyReset;
				val2.keywordTokens = val.keywordTokens;
				val2.mustKeyPress = val.mustKeyPress;
				val2.rechargeStock = val.rechargeStock;
				val2.requiredStock = val.requiredStock;
				val2.resetCooldownTimerOnUse = val.resetCooldownTimerOnUse;
				val2.skillName = val.skillName + "DebloatedScepter";
				val2.stockToConsume = val.stockToConsume;
				val2.suppressSkillActivation = val.suppressSkillActivation;
				val2.triggeredByPressRelease = val.triggeredByPressRelease;
				PluginContentPack.skillDefs.Add(val2);
				PluginUtils.RegisterScepterSkill(val2, val);
			}
		}

		private void Meditate_Update(ILContext il)
		{
			//IL_0002: Unknown result type (might be due to invalid IL or missing references)
			//IL_0008: Expected O, but got Unknown
			ILCursor val = new ILCursor(il);
			if (val.TryGotoNext((MoveType)2, new Func<Instruction, bool>[1]
			{
				(Instruction x) => ILPatternMatchingExt.MatchLdcR4(x, 0.04f)
			}))
			{
				val.EmitDelegate<Func<float, float>>((Func<float, float>)((float x) => 0.25f));
			}
			else
			{
				Debug.LogError((object)"DebloatedSeeker: Meditate base healing IL Hook failed.");
			}
			if (val.TryGotoNext(new Func<Instruction, bool>[1]
			{
				(Instruction x) => ILPatternMatchingExt.MatchCallvirt<BlastAttack>(x, "Fire")
			}))
			{
				val.EmitDelegate<Func<BlastAttack, BlastAttack>>((Func<BlastAttack, BlastAttack>)delegate(BlastAttack blast)
				{
					ref DamageType damageType = ref blast.damageType.damageType;
					damageType = (DamageType)((uint)damageType | 0x20u);
					return blast;
				});
			}
			else
			{
				Debug.LogError((object)"DebloatedSeeker: Meditate Stun IL Hook failed.");
			}
		}

		private void SeekerController_CmdTriggerHealPulse(orig_CmdTriggerHealPulse orig, SeekerController self, float value, Vector3 corePosition, float blastRadius, float fxScale)
		{
			//IL_0046: Unknown result type (might be due to invalid IL or missing references)
			//IL_0053: Unknown result type (might be due to invalid IL or missing references)
			//IL_0059: Expected O, but got Unknown
			//IL_005f: Unknown result type (might be due to invalid IL or missing references)
			//IL_0064: Unknown result type (might be due to invalid IL or missing references)
			//IL_006a: Unknown result type (might be due to invalid IL or missing references)
			//IL_006c: Unknown result type (might be due to invalid IL or missing references)
			//IL_0073: Unknown result type (might be due to invalid IL or missing references)
			//IL_0082: Unknown result type (might be due to invalid IL or missing references)
			//IL_008a: 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_0041: Unknown result type (might be due to invalid IL or missing references)
			//IL_016c: Unknown result type (might be due to invalid IL or missing references)
			//IL_0171: Unknown result type (might be due to invalid IL or missing references)
			//IL_0172: Unknown result type (might be due to invalid IL or missing references)
			//IL_017a: Unknown result type (might be due to invalid IL or missing references)
			//IL_017b: Unknown result type (might be due to invalid IL or missing references)
			//IL_0180: Unknown result type (might be due to invalid IL or missing references)
			//IL_0185: Unknown result type (might be due to invalid IL or missing references)
			//IL_0193: Expected O, but got Unknown
			//IL_013f: Unknown result type (might be due to invalid IL or missing references)
			//IL_0145: Unknown result type (might be due to invalid IL or missing references)
			//IL_0121: Unknown result type (might be due to invalid IL or missing references)
			//IL_0127: Unknown result type (might be due to invalid IL or missing references)
			//IL_01c8: Unknown result type (might be due to invalid IL or missing references)
			//IL_01cd: 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_01e2: Unknown result type (might be due to invalid IL or missing references)
			//IL_01e7: Unknown result type (might be due to invalid IL or missing references)
			//IL_01ec: Unknown result type (might be due to invalid IL or missing references)
			//IL_0252: Unknown result type (might be due to invalid IL or missing references)
			//IL_0261: Unknown result type (might be due to invalid IL or missing references)
			if (!NetworkServer.active)
			{
				return;
			}
			TeamIndex val = (TeamIndex)((!Object.op_Implicit((Object)(object)self.characterBody) || !Object.op_Implicit((Object)(object)self.characterBody.teamComponent)) ? (-1) : ((int)self.characterBody.teamComponent.teamIndex));
			List<HurtBox> list = new List<HurtBox>();
			List<HealthComponent> list2 = new List<HealthComponent>();
			SphereSearch val2 = new SphereSearch();
			val2.mask = ((LayerIndex)(ref LayerIndex.entityPrecise)).mask;
			val2.origin = corePosition;
			val2.queryTriggerInteraction = (QueryTriggerInteraction)2;
			val2.radius = blastRadius;
			TeamMask val3 = default(TeamMask);
			((TeamMask)(ref val3)).AddTeam(val);
			val2.RefreshCandidates();
			val2.FilterCandidatesByDistinctHurtBoxEntities();
			val2.RefreshCandidates().FilterCandidatesByHurtBoxTeam(val3).FilterCandidatesByDistinctHurtBoxEntities()
				.GetHurtBoxes(list);
			int i = 0;
			for (int count = list.Count; i < count; i++)
			{
				HealthComponent healthComponent = list[i].healthComponent;
				if (!list2.Contains(healthComponent))
				{
					list2.Add(healthComponent);
					if (Object.op_Implicit((Object)(object)self.characterBody) && (Object)(object)self.characterBody.healthComponent == (Object)(object)healthComponent)
					{
						healthComponent.Heal(value, default(ProcChainMask), true);
					}
					else
					{
						healthComponent.Heal(value * 2f, default(ProcChainMask), true);
					}
				}
			}
			EffectManager.SpawnEffect(self.healingExplosionPrefab, new EffectData
			{
				origin = corePosition,
				rotation = Quaternion.identity,
				scale = fxScale
			}, true);
			List<ProjectileController> instancesList = InstanceTracker.GetInstancesList<ProjectileController>();
			List<GameObject> list3 = new List<GameObject>();
			foreach (ProjectileController item in instancesList)
			{
				if (!item.cannotBeDeleted && item.teamFilter.teamIndex != val)
				{
					Vector3 val4 = ((Component)item).transform.position - ((Component)self).transform.position;
					if (!(((Vector3)(ref val4)).sqrMagnitude >= blastRadius * blastRadius))
					{
						list3.Add(((Component)item).gameObject);
					}
				}
			}
			GameObject[] array = list3.ToArray();
			for (int j = 0; j < array.Length; j++)
			{
				EffectManager.SimpleEffect(cleanseEffect, array[j].transform.position, array[j].transform.rotation, true);
				Object.Destroy((Object)(object)array[j]);
			}
		}

		private void MeditateScepterStats(orig_OnEnter orig, Meditate self)
		{
			//IL_0033: Unknown result type (might be due to invalid IL or missing references)
			orig.Invoke(self);
			if (Object.op_Implicit((Object)(object)((EntityState)self).characterBody) && Object.op_Implicit((Object)(object)((EntityState)self).characterBody.inventory) && ((EntityState)self).characterBody.inventory.GetItemCountEffective(PluginUtils.ScepterIndex) > 0)
			{
				self.damageCoefficient *= 1.5f;
				self.blastRadius *= 1.5f;
				self.healingExplosionAmount *= 1.5f;
			}
		}

		private void DebloatSoulSpiral()
		{
			//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)
			//IL_007c: Unknown result type (might be due to invalid IL or missing references)
			//IL_0081: Unknown result type (might be due to invalid IL or missing references)
			GameObject val = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync<GameObject>((object)"RoR2/DLC2/Seeker/SoulSpiralProjectile.prefab").WaitForCompletion(), "DebloatedSeekerSoulSpiralProjectile", true);
			PluginContentPack.projectilePrefabs.Add(val);
			PluginUtils.SetAddressableEntityStateField("RoR2/DLC2/Seeker/EntityStates.Seeker.SoulSpiral.asset", "projectilePrefab", (Object)(object)val);
			ProjectileOverlapLimitHits component = val.GetComponent<ProjectileOverlapLimitHits>();
			component.hitLimit = 15;
			SoulSpiralProjectile component2 = val.GetComponent<SoulSpiralProjectile>();
			component2.hitStackPerBuff = 0;
			UnseenHandHealingProjectile component3 = val.GetComponent<UnseenHandHealingProjectile>();
			component3.barrierPercent = 0.06f;
			component3.chakraIncrease = 0f;
			SkillDef skillDef = Addressables.LoadAssetAsync<SkillDef>((object)"RoR2/DLC2/Seeker/SeekerBodySoulSpiral.asset").WaitForCompletion();
			PluginUtils.RemoveTranquilityKeyword(skillDef);
		}

		private void DebloatReprieve()
		{
			//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)
			//IL_004e: Unknown result type (might be due to invalid IL or missing references)
			//IL_0053: Unknown result type (might be due to invalid IL or missing references)
			//IL_0070: Unknown result type (might be due to invalid IL or missing references)
			//IL_0075: Unknown result type (might be due to invalid IL or missing references)
			GameObject val = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync<GameObject>((object)"RoR2/DLC2/Seeker/SeekerCyclonePrefab.prefab").WaitForCompletion(), "DebloatedSeekerCycloneProjectile", true);
			PluginContentPack.projectilePrefabs.Add(val);
			SeekerCycloneController component = val.GetComponent<SeekerCycloneController>();
			component.baseLifetime = 7f;
			component.durationBonusPerStack = 0f;
			GameObject val2 = Addressables.LoadAssetAsync<GameObject>((object)"RoR2/DLC2/Seeker/SojournVehicle/ReprieveVehicle.prefab").WaitForCompletion();
			ReprieveVehicle component2 = val2.GetComponent<ReprieveVehicle>();
			component2.cyclonePrefab = val;
			SkillDef val3 = Addressables.LoadAssetAsync<SkillDef>((object)"RoR2/DLC2/Seeker/SeekerBodyReprieve.asset").WaitForCompletion();
			val3.keywordTokens = new string[0];
		}

		private void DebloatPalmBlast()
		{
			//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)
			//IL_008e: Unknown result type (might be due to invalid IL or missing references)
			//IL_0093: Unknown result type (might be due to invalid IL or missing references)
			//IL_0138: Unknown result type (might be due to invalid IL or missing references)
			//IL_013d: Unknown result type (might be due to invalid IL or missing references)
			//IL_0171: Unknown result type (might be due to invalid IL or missing references)
			//IL_017b: Expected O, but got Unknown
			//IL_01c0: Unknown result type (might be due to invalid IL or missing references)
			//IL_01c5: Unknown result type (might be due to invalid IL or missing references)
			//IL_025c: Unknown result type (might be due to invalid IL or missing references)
			//IL_0261: Unknown result type (might be due to invalid IL or missing references)
			GameObject val = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync<GameObject>((object)"RoR2/DLC2/Seeker/PalmBlastProjectile.prefab").WaitForCompletion(), "DebloatedSeekerPalmBlastProjectile", true);
			PluginContentPack.projectilePrefabs.Add(val);
			PalmBlastProjectileController component = val.GetComponent<PalmBlastProjectileController>();
			component.projectileSize = 1.5f;
			component.bonusProjectileSizePerStack = 0f;
			component.damageCoefficient = 10f;
			component.bonusDamageCoefficientPerStack = 0f;
			component.bonusAllyHealingPercentPerStack = 0f;
			component.allyHealingPercent = 0.25f;
			component.barrierPercent = 0.15f;
			GameObject val2 = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync<GameObject>((object)"RoR2/DLC2/Seeker/PalmBlastChargedProjectile.prefab").WaitForCompletion(), "DebloatedSeekerPalmBlastChargedProjectile", true);
			PluginContentPack.projectilePrefabs.Add(val2);
			PalmBlastProjectileController component2 = val2.GetComponent<PalmBlastProjectileController>();
			component2.projectileSize = 2.5f;
			component2.bonusProjectileSizePerStack = 0f;
			component2.damageCoefficient = 20f;
			component2.bonusDamageCoefficientPerStack = 0f;
			component2.bonusAllyHealingPercentPerStack = 0f;
			component2.allyHealingPercent = 0.5f;
			component2.barrierPercent = 0.3f;
			PluginUtils.SetAddressableEntityStateField("RoR2/DLC2/Seeker/EntityStates.Seeker.PalmBlastFire.asset", "projectilePrefab", (Object)(object)val);
			PluginUtils.SetAddressableEntityStateField("RoR2/DLC2/Seeker/EntityStates.Seeker.PalmBlastFire.asset", "chargedProjectilePrefab", (Object)(object)val2);
			SkillDef val3 = Addressables.LoadAssetAsync<SkillDef>((object)"RoR2/DLC2/Seeker/SeekerPalmBlast.asset").WaitForCompletion();
			val3.keywordTokens = new string[1] { "SEEKER_TRANQUILITY_DEBLOATED" };
			if (PluginUtils.scepterLoaded)
			{
				PalmBlastProjectileController.Init += new hook_Init(PalmBlastProjectileController_Init);
				SkillDef val4 = ScriptableObject.CreateInstance<SkillDef>();
				val4.skillNameToken = "ANCIENTSCEPTER_SEEKER_PALMBLASTNAME";
				val4.skillDescriptionToken = "SEEKER_SPECIALL_ALT1_DESCRIPTION_DEBLOATED_SCEPTER";
				val4.icon = null;
				val4.beginSkillCooldownOnSkillEnd = val3.beginSkillCooldownOnSkillEnd;
				val4.baseMaxStock = val3.baseMaxStock;
				val4.activationState = val3.activationState;
				val4.activationStateMachineName = val3.activationStateMachineName;
				val4.attackSpeedBuffsRestockSpeed = val3.attackSpeedBuffsRestockSpeed;
				val4.attackSpeedBuffsRestockSpeed_Multiplier = val3.attackSpeedBuffsRestockSpeed_Multiplier;
				val4.autoHandleLuminousShot = val3.autoHandleLuminousShot;
				val4.cancelSprintingOnActivation = val3.cancelSprintingOnActivation;
				val4.canceledFromSprinting = val3.canceledFromSprinting;
				val4.dontAllowPastMaxStocks = val3.dontAllowPastMaxStocks;
				val4.forceSprintDuringState = val3.forceSprintDuringState;
				val4.fullRestockOnAssign = val3.forceSprintDuringState;
				val4.hideCooldown = val3.hideCooldown;
				val4.hideStockCount = val3.hideStockCount;
				val4.interruptPriority = val3.interruptPriority;
				val4.isCombatSkill = val3.isCombatSkill;
				val4.isCooldownBlockedUntilManuallyReset = val3.isCooldownBlockedUntilManuallyReset;
				val4.keywordTokens = val3.keywordTokens;
				val4.mustKeyPress = val3.mustKeyPress;
				val4.rechargeStock = val3.rechargeStock;
				val4.requiredStock = val3.requiredStock;
				val4.resetCooldownTimerOnUse = val3.resetCooldownTimerOnUse;
				val4.skillName = val3.skillName + "DebloatedScepter";
				val4.stockToConsume = val3.stockToConsume;
				val4.suppressSkillActivation = val3.suppressSkillActivation;
				val4.triggeredByPressRelease = val3.triggeredByPressRelease;
				PluginContentPack.skillDefs.Add(val4);
				PluginUtils.RegisterScepterSkill(val4, val3);
			}
		}

		private void PalmBlastProjectileController_Init(orig_Init orig, PalmBlastProjectileController self, CharacterBody body)
		{
			//IL_0025: Unknown result type (might be due to invalid IL or missing references)
			orig.Invoke(self, body);
			if (Object.op_Implicit((Object)(object)body) && Object.op_Implicit((Object)(object)body.inventory) && body.inventory.GetItemCountEffective(PluginUtils.ScepterIndex) > 0)
			{
				self.damageCoefficient *= 1.5f;
				self.healingToApply *= 1.5f;
				self.barrierPercent *= 1.5f;
			}
		}
	}
	public static class LanguageTokens
	{
		public const string LoadoutDescriptionToken = "SEEKER_DESCRIPTION_DEBLOATED";

		public const string Tranquility2Token = "SEEKER_TRANQUILITY_DEBLOATED";

		public const string MeditateToken = "SEEKER_SPECIAL_DESCRIPTION_DEBLOATED";

		public const string MeditateScepterToken = "SEEKER_SPECIAL_DESCRIPTION_DEBLOATED_SCEPTER";

		public const string PalmBlastToken = "SEEKER_SPECIAL_ALT1_DESCRIPTION_DEBLOATED";

		public const string PalmBlastScepterToken = "SEEKER_SPECIALL_ALT1_DESCRIPTION_DEBLOATED_SCEPTER";

		internal static void Init()
		{
			LanguageAPI.Add("SEEKER_DESCRIPTION_DEBLOATED", "As a meditative mid-range brawler, Seeker utilizes powerful healing to sustain herself and her team.<style=cSub>\r\n\r\n< ! > Every third Spirit Punch in a row fires a high-damaging explosive burst of Soul. Flow between targets while holding the primary to deal maximum damage.\r\n\r\n< ! > Seeker’s Unseen Hand heals you for every enemy hit. Prioritize enemy groups to maximize healing.\r\n\r\n< ! > Use Sojourn to escape dangerous situations, rush to teammates, or enter the fray. Use Sojourn again to end your flight to deal damage to enemies. While in Sojourn, your health quickly depletes, so use it wisely.\r\n\r\n< ! > Meditate places you in a vulnerable state, but provides a powerful buff upon completion. Positioning and timing are key to empowering you and your teammates.\r\n</style>\r\n");
			LanguageAPI.Add("SEEKER_TRANQUILITY_DEBLOATED", "<style=cKeywordName>Tranquility</style><style=cSub>Increase movement speed, attack speed, and health regeneration by <style=cIsDamage>30%</style>.");
			LanguageAPI.Add("SEEKER_SPECIAL_DESCRIPTION_DEBLOATED", "<style=cIsUtility>Focus your mind</style> to blast enemies for <style=cIsDamage>2000% damage</style>, <style=cIsHealing>heal</style> nearby allies, and grant <style=cIsUtility>Tranquility</style> for <style=cIsUtility>10 seconds</style>.");
			LanguageAPI.Add("SEEKER_SPECIAL_DESCRIPTION_DEBLOATED_SCEPTER", "<style=cIsUtility>Focus your mind</style> to blast enemies for <style=cIsDamage>3000% damage</style>, <style=cIsHealing>heal</style> nearby allies, and grant <style=cIsUtility>2 stacks of Tranquility</style> for <style=cIsUtility>10 seconds</style>.");
			LanguageAPI.Add("SEEKER_SPECIALL_ALT1_DESCRIPTION_DEBLOATED_SCEPTER", "<style=cIsUtility>Charge</style> a <style=cIsDamage>piercing</style>, spectral hand that deals <style=cIsDamage>1500%-3000% damage</style> and <style=cIsHealing>heals</style> allies. <style=cIsDamage>Multihit</style> three characters to gain <style=cIsUtility>2 stacks of Tranquility</style> and <style=cIsHealing>barrier</style>.");
		}
	}
	internal static class PluginUtils
	{
		internal static bool scepterLoaded;

		internal static ItemIndex ScepterIndex = (ItemIndex)(-1);

		internal static void SetAddressableEntityStateField(string fullEntityStatePath, string fieldName, string value)
		{
			//IL_0016: 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)
			string fieldName2 = fieldName;
			string value2 = value;
			AsyncOperationHandle<EntityStateConfiguration> val = Addressables.LoadAssetAsync<EntityStateConfiguration>((object)fullEntityStatePath);
			val.Completed += delegate(AsyncOperationHandle<EntityStateConfiguration> handle)
			{
				//IL_0000: Unknown result type (might be due to invalid IL or missing references)
				SetAddressableEntityStateField_String_Completed(handle, fieldName2, value2);
			};
		}

		private static void SetAddressableEntityStateField_String_Completed(AsyncOperationHandle<EntityStateConfiguration> handle, string fieldName, string value)
		{
			EntityStateConfiguration result = handle.Result;
			for (int i = 0; i < result.serializedFieldsCollection.serializedFields.Length; i++)
			{
				if (result.serializedFieldsCollection.serializedFields[i].fieldName == fieldName)
				{
					result.serializedFieldsCollection.serializedFields[i].fieldValue.stringValue = value;
					return;
				}
			}
			Debug.LogError((object)("DebloatedSeeker: " + ((object)result)?.ToString() + " does not have field " + fieldName));
		}

		internal static void SetAddressableEntityStateField(string fullEntityStatePath, string fieldName, Object newObject)
		{
			//IL_0016: 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)
			string fieldName2 = fieldName;
			Object newObject2 = newObject;
			AsyncOperationHandle<EntityStateConfiguration> val = Addressables.LoadAssetAsync<EntityStateConfiguration>((object)fullEntityStatePath);
			val.Completed += delegate(AsyncOperationHandle<EntityStateConfiguration> handle)
			{
				//IL_0000: Unknown result type (might be due to invalid IL or missing references)
				SetAddressableEntityStateField_Object_Completed(handle, fieldName2, newObject2);
			};
		}

		private static void SetAddressableEntityStateField_Object_Completed(AsyncOperationHandle<EntityStateConfiguration> handle, string fieldName, Object newObject)
		{
			EntityStateConfiguration result = handle.Result;
			for (int i = 0; i < result.serializedFieldsCollection.serializedFields.Length; i++)
			{
				if (result.serializedFieldsCollection.serializedFields[i].fieldName == fieldName)
				{
					result.serializedFieldsCollection.serializedFields[i].fieldValue.objectValue = newObject;
					return;
				}
			}
			Debug.LogError((object)("DebloatedSeeker: " + ((object)result)?.ToString() + " does not have field " + fieldName));
		}

		internal static void RemoveTranquilityKeyword(SkillDef skillDef)
		{
			if (Object.op_Implicit((Object)(object)skillDef))
			{
				skillDef.keywordTokens = skillDef.keywordTokens.Where((string keyword) => !keyword.Contains("TRANQUILITY_DESCRIPTION")).ToArray();
			}
		}

		internal static void RegisterScepterSkill(SkillDef skill, SkillDef orig)
		{
			if (scepterLoaded)
			{
				RegisterScepterSkillInternal(skill, orig);
			}
		}

		[MethodImpl(MethodImplOptions.NoInlining | MethodImplOptions.NoOptimization)]
		internal static void RegisterScepterSkillInternal(SkillDef skill, SkillDef orig)
		{
			if (skill.skillNameToken == "ANCIENTSCEPTER_SEEKER_MEDITATENAME")
			{
				skill.icon = SpriteAssets.SeekerMeditate2;
			}
			else if (skill.skillNameToken == "ANCIENTSCEPTER_SEEKER_PALMBLASTNAME")
			{
				skill.icon = SpriteAssets.SeekerPalmBlast2;
			}
			ItemBase<AncientScepterItem>.instance.RegisterScepterSkill(skill, "SeekerBody", orig);
		}
	}
}
namespace DebloatedSeeker.Modules
{
	public class PluginContentPack : IContentPackProvider
	{
		[CompilerGenerated]
		private sealed class <FinalizeAsync>d__8 : IEnumerator<object>, IEnumerator, IDisposable
		{
			private int <>1__state;

			private object <>2__current;

			public FinalizeAsyncArgs args;

			public PluginContentPack <>4__this;

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

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

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

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

			private bool MoveNext()
			{
				if (<>1__state != 0)
				{
					return false;
				}
				<>1__state = -1;
				args.ReportProgress(1f);
				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 <GenerateContentPackAsync>d__9 : IEnumerator<object>, IEnumerator, IDisposable
		{
			private int <>1__state;

			private object <>2__current;

			public GetContentPackAsyncArgs args;

			public PluginContentPack <>4__this;

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

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

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

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

			private bool MoveNext()
			{
				if (<>1__state != 0)
				{
					return false;
				}
				<>1__state = -1;
				ContentPack.Copy(content, args.output);
				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 <LoadStaticContentAsync>d__10 : IEnumerator<object>, IEnumerator, IDisposable
		{
			private int <>1__state;

			private object <>2__current;

			public LoadStaticContentAsyncArgs args;

			public PluginContentPack <>4__this;

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

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

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

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

			private bool MoveNext()
			{
				if (<>1__state != 0)
				{
					return false;
				}
				<>1__state = -1;
				content.buffDefs.Add(buffDefs.ToArray());
				content.projectilePrefabs.Add(projectilePrefabs.ToArray());
				content.skillDefs.Add(skillDefs.ToArray());
				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 ContentPack content = new ContentPack();

		public static List<GameObject> projectilePrefabs = new List<GameObject>();

		public static List<BuffDef> buffDefs = new List<BuffDef>();

		public static List<SkillDef> skillDefs = new List<SkillDef>();

		public string identifier => "DebloatedSeeker.content";

		internal void Initialize()
		{
			//IL_0008: Unknown result type (might be due to invalid IL or missing references)
			//IL_0012: Expected O, but got Unknown
			ContentManager.collectContentPackProviders += new CollectContentPackProvidersDelegate(ContentManager_collectContentPackProviders);
		}

		private void ContentManager_collectContentPackProviders(AddContentPackProviderDelegate addContentPackProvider)
		{
			addContentPackProvider.Invoke((IContentPackProvider)(object)this);
		}

		[IteratorStateMachine(typeof(<FinalizeAsync>d__8))]
		public IEnumerator FinalizeAsync(FinalizeAsyncArgs args)
		{
			//yield-return decompiler failed: Unexpected instruction in Iterator.Dispose()
			return new <FinalizeAsync>d__8(0)
			{
				<>4__this = this,
				args = args
			};
		}

		[IteratorStateMachine(typeof(<GenerateContentPackAsync>d__9))]
		public IEnumerator GenerateContentPackAsync(GetContentPackAsyncArgs args)
		{
			//yield-return decompiler failed: Unexpected instruction in Iterator.Dispose()
			return new <GenerateContentPackAsync>d__9(0)
			{
				<>4__this = this,
				args = args
			};
		}

		[IteratorStateMachine(typeof(<LoadStaticContentAsync>d__10))]
		public IEnumerator LoadStaticContentAsync(LoadStaticContentAsyncArgs args)
		{
			//yield-return decompiler failed: Unexpected instruction in Iterator.Dispose()
			return new <LoadStaticContentAsync>d__10(0)
			{
				<>4__this = this,
				args = args
			};
		}
	}
}