Decompiled source of EscanorPaladinSkills v1.0.0

EscanorPaladinSkills.dll

Decompiled 2 weeks 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 BepInEx;
using BepInEx.Configuration;
using BepInEx.Logging;
using EntityStates;
using EntityStates.BrotherMonster;
using EntityStates.Commando.CommandoWeapon;
using EntityStates.Croco;
using EntityStates.Merc;
using EscanorPaladinSkills.Buffs;
using EscanorPaladinSkills.Components;
using EscanorPaladinSkills.Overlays;
using EscanorPaladinSkills.Projectiles;
using EscanorPaladinSkills.SkillDefs;
using EscanorPaladinSkills.States;
using EscanorPaladinSkills.States.Upgrades;
using EscanorPaladinSkills.States.Upgrades.SpinningSlash;
using EscanorPaladinSkills.States.Upgrades.SunlightSpear;
using EscanorPaladinSkills.VFX;
using IL.EntityStates;
using KinematicCharacterController;
using Microsoft.CodeAnalysis;
using Mono.Cecil.Cil;
using MonoMod.Cil;
using On.RoR2;
using PaladinMod;
using PaladinMod.Misc;
using PaladinMod.Modules;
using PaladinMod.States;
using R2API;
using RoR2;
using RoR2.Audio;
using RoR2.Projectile;
using RoR2.Skills;
using RoR2.UI;
using UnityEngine;
using UnityEngine.AddressableAssets;
using UnityEngine.Networking;

[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.0", FrameworkDisplayName = ".NET Standard 2.0")]
[assembly: AssemblyCompany("EscanorPaladinSkills")]
[assembly: AssemblyConfiguration("Debug")]
[assembly: AssemblyFileVersion("1.0.0.0")]
[assembly: AssemblyInformationalVersion("1.0.0")]
[assembly: AssemblyProduct("EscanorPaladinSkills")]
[assembly: AssemblyTitle("EscanorPaladinSkills")]
[assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)]
[assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)]
[assembly: AssemblyVersion("1.0.0.0")]
[module: UnverifiableCode]
[module: RefSafetyRules(11)]
namespace Microsoft.CodeAnalysis
{
	[CompilerGenerated]
	[Microsoft.CodeAnalysis.Embedded]
	internal sealed class EmbeddedAttribute : Attribute
	{
	}
}
namespace System.Runtime.CompilerServices
{
	[CompilerGenerated]
	[Microsoft.CodeAnalysis.Embedded]
	[AttributeUsage(AttributeTargets.Module, AllowMultiple = false, Inherited = false)]
	internal sealed class RefSafetyRulesAttribute : Attribute
	{
		public readonly int Version;

		public RefSafetyRulesAttribute(int P_0)
		{
			Version = P_0;
		}
	}
}
namespace EscanorPaladinSkills
{
	[BepInPlugin("HIFU.EscanorPaladinSkills", "EscanorPaladinSkills", "1.0.0")]
	[BepInDependency(/*Could not decode attribute arguments.*/)]
	[BepInDependency(/*Could not decode attribute arguments.*/)]
	[BepInDependency(/*Could not decode attribute arguments.*/)]
	[BepInDependency(/*Could not decode attribute arguments.*/)]
	public class Main : BaseUnityPlugin
	{
		public const string PluginGUID = "HIFU.EscanorPaladinSkills";

		public const string PluginAuthor = "HIFU";

		public const string PluginName = "EscanorPaladinSkills";

		public const string PluginVersion = "1.0.0";

		public static AssetBundle escanor;

		public static ManualLogSource logger;

		public static Xoroshiro128Plus rng;

		public static ConfigEntry<float> swordScale { get; set; }

		public void Awake()
		{
			logger = ((BaseUnityPlugin)this).Logger;
			Run.onRunStartGlobal += Run_onRunStartGlobal;
			swordScale = ((BaseUnityPlugin)this).Config.Bind<float>("Silly", "Sword Scale Multiplier", 1.5f, "Only works with Divine Axe Rhitta as your M1");
			escanor = AssetBundle.LoadFromFile(Assembly.GetExecutingAssembly().Location.Replace("EscanorPaladinSkills.dll", "escanorpaladinskills"));
			All.Init();
			DivineAxeRhitta.Init();
			FlameOfLife.Init();
			TheOne.Init();
			CruelSun.Init();
			CruelSunUpgraded.Init();
			EscanorPaladinSkills.VFX.Judgement.Init();
			EscanorPaladinSkills.Projectiles.Judgement.Init();
			Sunfall.Init();
			Init.SetUpComponents();
		}

		private void Run_onRunStartGlobal(Run run)
		{
			//IL_000b: Unknown result type (might be due to invalid IL or missing references)
			//IL_0015: Expected O, but got Unknown
			rng = new Xoroshiro128Plus(RoR2Application.rng.nextUlong);
		}

		public void Start()
		{
			SunlightSpearUpgraded.Init();
			DivineAxeRhittaJank.Init();
			AddESM();
			IEnumerable<Type> enumerable = from type in Assembly.GetExecutingAssembly().GetTypes()
				where !type.IsAbstract && type.IsSubclassOf(typeof(SkillDefBase))
				select type;
			logger.LogInfo((object)"==+----------------==SKILLS==----------------+==");
			foreach (Type item in enumerable)
			{
				SkillDefBase skillDefBase = (SkillDefBase)Activator.CreateInstance(item);
				if (!skillDefBase.Add)
				{
					skillDefBase.Init();
				}
				else if (ValidateSkillDef(skillDefBase))
				{
					skillDefBase.Init();
				}
			}
			AddStates();
			AddSkillUpgrades();
		}

		public void AddESM()
		{
			//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)
			//IL_0040: Unknown result type (might be due to invalid IL or missing references)
			//IL_0045: Unknown result type (might be due to invalid IL or missing references)
			GameObject characterPrefab = PaladinPlugin.characterPrefab;
			NetworkStateMachine component = characterPrefab.GetComponent<NetworkStateMachine>();
			EntityStateMachine val = characterPrefab.AddComponent<EntityStateMachine>();
			val.customName = "Flame";
			val.initialStateType = new SerializableEntityStateType(typeof(Idle));
			val.mainStateType = new SerializableEntityStateType(typeof(Idle));
			Array.Resize(ref component.stateMachines, component.stateMachines.Length + 1);
			component.stateMachines[component.stateMachines.Length - 1] = val;
		}

		public void AddStates()
		{
			//IL_000d: 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_0031: Unknown result type (might be due to invalid IL or missing references)
			//IL_0043: 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_0067: Unknown result type (might be due to invalid IL or missing references)
			//IL_0079: Unknown result type (might be due to invalid IL or missing references)
			//IL_008b: Unknown result type (might be due to invalid IL or missing references)
			//IL_009d: Unknown result type (might be due to invalid IL or missing references)
			//IL_00af: Unknown result type (might be due to invalid IL or missing references)
			//IL_00c1: Unknown result type (might be due to invalid IL or missing references)
			//IL_00d3: Unknown result type (might be due to invalid IL or missing references)
			//IL_00e5: Unknown result type (might be due to invalid IL or missing references)
			//IL_00f7: Unknown result type (might be due to invalid IL or missing references)
			bool flag = default(bool);
			ContentAddition.AddEntityState(typeof(CruelSunState), ref flag);
			ContentAddition.AddEntityState(typeof(CruelSunUpgradedState), ref flag);
			ContentAddition.AddEntityState(typeof(FlameOfLifeState), ref flag);
			ContentAddition.AddEntityState(typeof(DivineAxeRhittaState), ref flag);
			ContentAddition.AddEntityState(typeof(SunfallState), ref flag);
			ContentAddition.AddEntityState(typeof(SpinningSlashAirborneAltUpgradedState), ref flag);
			ContentAddition.AddEntityState(typeof(SpinningSlashAirborneUpgradedState), ref flag);
			ContentAddition.AddEntityState(typeof(SpinningSlashEntryUpgradedState), ref flag);
			ContentAddition.AddEntityState(typeof(SpinningSlashGroundedAltUpgradedState), ref flag);
			ContentAddition.AddEntityState(typeof(SpinningSlashGroundedUpgradedState), ref flag);
			ContentAddition.AddEntityState(typeof(CruelSunUpgradedState), ref flag);
			ContentAddition.AddEntityState(typeof(DivineAxeRhittaUpgradedState), ref flag);
			ContentAddition.AddEntityState(typeof(ChargeSunlightSpearUpgradedState), ref flag);
			ContentAddition.AddEntityState(typeof(ThrowSunlightSpearUpgradedState), ref flag);
		}

		public void AddSkillUpgrades()
		{
		}

		public bool ValidateSkillDef(SkillDefBase sdb)
		{
			if (sdb.isEnabled && ((BaseUnityPlugin)this).Config.Bind<bool>(sdb.ConfigNameText, "Enable?", true, "Vanilla is false").Value)
			{
				return true;
			}
			return false;
		}
	}
	internal class Publicize
	{
	}
}
namespace EscanorPaladinSkills.VFX
{
	public static class DivineAxeRhitta
	{
		public static GameObject prefab;

		public static GameObject groundPrefab;

		public static void Init()
		{
			//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_005f: Unknown result type (might be due to invalid IL or missing references)
			//IL_0069: Unknown result type (might be due to invalid IL or missing references)
			//IL_00a2: Unknown result type (might be due to invalid IL or missing references)
			//IL_00a7: 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_00b0: Unknown result type (might be due to invalid IL or missing references)
			//IL_00d0: Unknown result type (might be due to invalid IL or missing references)
			//IL_00d5: Unknown result type (might be due to invalid IL or missing references)
			//IL_016b: Unknown result type (might be due to invalid IL or missing references)
			//IL_0170: Unknown result type (might be due to invalid IL or missing references)
			//IL_0174: Unknown result type (might be due to invalid IL or missing references)
			//IL_0179: Unknown result type (might be due to invalid IL or missing references)
			//IL_017d: Unknown result type (might be due to invalid IL or missing references)
			//IL_0182: Unknown result type (might be due to invalid IL or missing references)
			//IL_01a9: Unknown result type (might be due to invalid IL or missing references)
			//IL_01b9: Unknown result type (might be due to invalid IL or missing references)
			//IL_01be: Unknown result type (might be due to invalid IL or missing references)
			//IL_023a: Unknown result type (might be due to invalid IL or missing references)
			//IL_023f: Unknown result type (might be due to invalid IL or missing references)
			//IL_0243: Unknown result type (might be due to invalid IL or missing references)
			//IL_0248: Unknown result type (might be due to invalid IL or missing references)
			//IL_024c: Unknown result type (might be due to invalid IL or missing references)
			//IL_0251: Unknown result type (might be due to invalid IL or missing references)
			//IL_0273: Unknown result type (might be due to invalid IL or missing references)
			//IL_0278: Unknown result type (might be due to invalid IL or missing references)
			//IL_02b4: Unknown result type (might be due to invalid IL or missing references)
			//IL_02c6: Unknown result type (might be due to invalid IL or missing references)
			//IL_02cb: Unknown result type (might be due to invalid IL or missing references)
			//IL_02e6: Unknown result type (might be due to invalid IL or missing references)
			//IL_02eb: Unknown result type (might be due to invalid IL or missing references)
			//IL_02fc: Unknown result type (might be due to invalid IL or missing references)
			//IL_0301: Unknown result type (might be due to invalid IL or missing references)
			//IL_0312: Unknown result type (might be due to invalid IL or missing references)
			//IL_0317: Unknown result type (might be due to invalid IL or missing references)
			//IL_031c: Unknown result type (might be due to invalid IL or missing references)
			//IL_0326: Expected O, but got Unknown
			//IL_0321: Unknown result type (might be due to invalid IL or missing references)
			//IL_0331: Unknown result type (might be due to invalid IL or missing references)
			//IL_0336: Unknown result type (might be due to invalid IL or missing references)
			//IL_03b6: Unknown result type (might be due to invalid IL or missing references)
			//IL_03bb: Unknown result type (might be due to invalid IL or missing references)
			//IL_03e4: Unknown result type (might be due to invalid IL or missing references)
			//IL_03e9: Unknown result type (might be due to invalid IL or missing references)
			//IL_042e: Unknown result type (might be due to invalid IL or missing references)
			//IL_0433: Unknown result type (might be due to invalid IL or missing references)
			//IL_045a: Unknown result type (might be due to invalid IL or missing references)
			//IL_045f: Unknown result type (might be due to invalid IL or missing references)
			prefab = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync<GameObject>((object)"RoR2/DLC1/MissileVoid/VoidImpactEffect.prefab").WaitForCompletion(), "Divine Axe Rhitta Impact VFX", false);
			EffectComponent component = prefab.GetComponent<EffectComponent>();
			component.soundName = string.Empty;
			component.applyScale = true;
			Transform transform = prefab.transform;
			for (int i = 0; i < transform.childCount; i++)
			{
				Transform child = transform.GetChild(i);
				child.localScale *= 2.5f;
			}
			ParticleSystemRenderer component2 = ((Component)transform.Find("Scaled Hitspark 1 (Random Color)")).GetComponent<ParticleSystemRenderer>();
			MainModule main = ((Component)component2).GetComponent<ParticleSystem>().main;
			MinMaxCurve startLifetime = ((MainModule)(ref main)).startLifetime;
			((MinMaxCurve)(ref startLifetime)).constantMin = 0.35f;
			((MinMaxCurve)(ref startLifetime)).constantMax = 0.5f;
			Material val = Object.Instantiate<Material>(Addressables.LoadAssetAsync<Material>((object)"RoR2/Base/Nullifier/matNullifierPortalEffectCenter.mat").WaitForCompletion());
			val.SetTexture("_RemapTex", (Texture)(object)Main.escanor.LoadAsset<Texture2D>("texRampDivineAxeRhitta1.png"));
			val.SetFloat("_InvFade", 0f);
			val.SetFloat("_Boost", 8.725851f);
			val.SetFloat("_AlphaBoost", 2.285f);
			val.SetFloat("_AlphaBias", 0.02575896f);
			((Renderer)component2).material = val;
			ParticleSystemRenderer component3 = ((Component)transform.Find("Scaled Hitspark 1 (Random Color) (1)")).GetComponent<ParticleSystemRenderer>();
			MainModule main2 = ((Component)component3).GetComponent<ParticleSystem>().main;
			MinMaxGradient startColor = ((MainModule)(ref main2)).startColor;
			MinMaxCurve startLifetime2 = ((MainModule)(ref main2)).startLifetime;
			((MinMaxCurve)(ref startLifetime2)).constantMin = 0.35f;
			((MinMaxCurve)(ref startLifetime2)).constantMax = 0.55f;
			((MinMaxGradient)(ref startColor)).mode = (ParticleSystemGradientMode)0;
			((MinMaxGradient)(ref startColor)).color = Color.white;
			Material val2 = Object.Instantiate<Material>(Addressables.LoadAssetAsync<Material>((object)"RoR2/DLC1/Common/Void/matOmniHitspark1Void.mat").WaitForCompletion());
			val2.SetTexture("_RemapTex", (Texture)(object)Main.escanor.LoadAsset<Texture2D>("texRampDivineAxeRhitta1.png"));
			val2.SetFloat("_Boost", 20f);
			val2.SetFloat("_AlphaBoost", 1.120074f);
			val2.SetFloat("_AlphaBias", 0.1589945f);
			((Renderer)component3).material = val2;
			MainModule main3 = ((Component)transform.Find("Flash, Hard")).GetComponent<ParticleSystem>().main;
			MinMaxGradient startColor2 = ((MainModule)(ref main3)).startColor;
			MinMaxCurve startLifetime3 = ((MainModule)(ref main3)).startLifetime;
			((MinMaxCurve)(ref startLifetime3)).constant = 0.3f;
			((MinMaxGradient)(ref startColor2)).color = Color32.op_Implicit(new Color32(byte.MaxValue, (byte)206, (byte)78, byte.MaxValue));
			ParticleSystemRenderer component4 = ((Component)transform.Find("Impact Shockwave")).GetComponent<ParticleSystemRenderer>();
			component4.alignment = (ParticleSystemRenderSpace)3;
			((Component)component4).transform.localScale = new Vector3(8f, 0.75f, 8f);
			SizeOverLifetimeModule sizeOverLifetime = ((Component)component4).GetComponent<ParticleSystem>().sizeOverLifetime;
			((SizeOverLifetimeModule)(ref sizeOverLifetime)).size = new MinMaxCurve(1f, new AnimationCurve((Keyframe[])(object)new Keyframe[3]
			{
				new Keyframe(0f, 0.85f),
				new Keyframe(0.85f, 1f),
				new Keyframe(1f, 0f)
			}));
			Material val3 = Object.Instantiate<Material>(Addressables.LoadAssetAsync<Material>((object)"RoR2/DLC1/Common/Void/matOmniRing1Void.mat").WaitForCompletion());
			val3.SetTexture("_RemapTex", (Texture)(object)Main.escanor.LoadAsset<Texture2D>("texRampDivineAxeRhitta2.png"));
			val3.SetFloat("_InvFade", 0f);
			val3.SetFloat("_Boost", 20f);
			val3.SetFloat("_AlphaBoost", 1.246044f);
			val3.SetFloat("_AlphaBias", 0.0275989f);
			val3.SetTexture("_MainTex", (Texture)(object)Addressables.LoadAssetAsync<Texture2D>((object)"RoR2/Base/Common/VFX/texOmniHitspark2Mask.png").WaitForCompletion());
			((Renderer)component4).material = val3;
			ContentAddition.AddEffect(prefab);
			groundPrefab = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync<GameObject>((object)"RoR2/DLC1/VoidCamp/PurchaseLockVoid.prefab").WaitForCompletion(), "Divine Axe Rhitta Ground VFX", false);
			Object.Destroy((Object)(object)groundPrefab.GetComponent<NetworkIdentity>());
			MeshRenderer component5 = ((Component)groundPrefab.transform.GetChild(0)).GetComponent<MeshRenderer>();
			Material val4 = Object.Instantiate<Material>(Addressables.LoadAssetAsync<Material>((object)"RoR2/DLC1/VoidCamp/matVoidCampLock.mat").WaitForCompletion());
			val4.SetColor("_TintColor", Color32.op_Implicit(new Color32(byte.MaxValue, (byte)213, (byte)0, (byte)133)));
			((Renderer)component5).material = val4;
			EffectComponent val5 = groundPrefab.AddComponent<EffectComponent>();
			val5.applyScale = true;
			val5.positionAtReferencedTransform = true;
			val5.parentToReferencedTransform = true;
			((Component)val5).gameObject.AddComponent<VFXAttributes>();
			DestroyOnTimer val6 = groundPrefab.AddComponent<DestroyOnTimer>();
			val6.duration = 0.5f;
			ContentAddition.AddEffect(groundPrefab);
		}
	}
	public static class DivineAxeRhittaJank
	{
		public static GameObject swingPrefab;

		public static void Init()
		{
			//IL_007c: Unknown result type (might be due to invalid IL or missing references)
			//IL_0086: Unknown result type (might be due to invalid IL or missing references)
			//IL_00b9: Unknown result type (might be due to invalid IL or missing references)
			//IL_00be: Unknown result type (might be due to invalid IL or missing references)
			//IL_00df: Unknown result type (might be due to invalid IL or missing references)
			//IL_00e4: Unknown result type (might be due to invalid IL or missing references)
			//IL_0163: Unknown result type (might be due to invalid IL or missing references)
			//IL_016d: Unknown result type (might be due to invalid IL or missing references)
			swingPrefab = PrefabAPI.InstantiateClone(Assets.mainAssetBundle.LoadAsset<GameObject>("PaladinSwing"), "Divine Axe Rhitta Swing VFX", false);
			Object.Destroy((Object)(object)swingPrefab.GetComponent<NetworkIdentity>());
			swingPrefab.GetComponent<DestroyOnTimer>().duration = 5f;
			EffectComponent component = swingPrefab.GetComponent<EffectComponent>();
			component.applyScale = false;
			component.parentToReferencedTransform = true;
			component.positionAtReferencedTransform = true;
			Transform transform = swingPrefab.transform;
			Transform val = transform.Find("SwingTrail");
			val.localScale = Vector3.one * 4f;
			Material val2 = Object.Instantiate<Material>(Assets.mainAssetBundle.LoadAsset<Material>("matPaladinSwing3"));
			val2.SetColor("_Color", Color32.op_Implicit(new Color32(byte.MaxValue, (byte)0, (byte)74, byte.MaxValue)));
			val2.SetColor("_EmissionColor", Color32.op_Implicit(new Color32(byte.MaxValue, (byte)144, (byte)0, byte.MaxValue)));
			val2.SetFloat("_Cutoff", 0.12f);
			val2.SetFloat("_BlendOp", 4f);
			val2.SetTexture("_MainTex", (Texture)(object)Main.escanor.LoadAsset<Texture2D>("texMaskSwing.png"));
			val2.SetTexture("_EmissionMap", (Texture)(object)Main.escanor.LoadAsset<Texture2D>("texMaskSwing.png"));
			((Renderer)((Component)val).GetComponent<ParticleSystemRenderer>()).material = val2;
			Transform val3 = val.Find("SwingTrail2");
			val3.localScale = Vector3.one * 2f;
			ContentAddition.AddEffect(swingPrefab);
		}
	}
	public static class Judgement
	{
		public static GameObject prefab;

		public static void Init()
		{
			//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)
			prefab = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync<GameObject>((object)"RoR2/Base/Merc/OmniImpactVFXSlashMerc.prefab").WaitForCompletion(), "Judgement VFX", false);
			EffectComponent component = prefab.GetComponent<EffectComponent>();
			component.soundName = string.Empty;
			component.applyScale = true;
			ContentAddition.AddEffect(prefab);
		}
	}
}
namespace EscanorPaladinSkills.States
{
	public class CruelSunState : BaseState
	{
		public static float baseDuration = 0.75f;

		public float duration;

		public static string sound;

		public Ray aimRay;

		public bool hasFired = false;

		public bool hasPlayedSound = false;

		public static float barrierGain = 0.06f;

		public override void OnEnter()
		{
			((BaseState)this).OnEnter();
			duration = baseDuration / base.attackSpeedStat;
			if (Object.op_Implicit((Object)(object)((EntityState)this).characterBody))
			{
				((EntityState)this).characterBody.SetAimTimer(1f);
			}
			((EntityState)this).PlayAnimation("Gesture, Override", "ChannelSpell", "Spell.playbackRate", duration * 0.5f);
			Util.PlaySound("PaladinCloth1", ((EntityState)this).gameObject);
			Util.PlaySound("PaladinCloth1", ((EntityState)this).gameObject);
		}

		public override InterruptPriority GetMinimumInterruptPriority()
		{
			//IL_0002: Unknown result type (might be due to invalid IL or missing references)
			//IL_0005: Unknown result type (might be due to invalid IL or missing references)
			return (InterruptPriority)1;
		}

		public override void FixedUpdate()
		{
			//IL_0039: Unknown result type (might be due to invalid IL or missing references)
			//IL_003e: Unknown result type (might be due to invalid IL or missing references)
			((EntityState)this).FixedUpdate();
			if (!(((EntityState)this).fixedAge < duration) && ((EntityState)this).isAuthority)
			{
				if (!hasFired)
				{
					aimRay = ((BaseState)this).GetAimRay();
					FireProjectile();
					hasFired = true;
				}
				((EntityState)this).outer.SetNextStateToMain();
			}
		}

		public void FireProjectile()
		{
			//IL_0040: 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_00a0: 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_00aa: Unknown result type (might be due to invalid IL or missing references)
			//IL_00c3: Unknown result type (might be due to invalid IL or missing references)
			//IL_00c8: Unknown result type (might be due to invalid IL or missing references)
			//IL_00cd: Unknown result type (might be due to invalid IL or missing references)
			//IL_00d2: Unknown result type (might be due to invalid IL or missing references)
			//IL_00d3: Unknown result type (might be due to invalid IL or missing references)
			//IL_00d9: Unknown result type (might be due to invalid IL or missing references)
			((BaseState)this).AddRecoil(7f, 7f, -2.5f, 2.5f);
			((EntityState)this).PlayAnimation("Gesture, Override", "ThrowSpell", "Spell.playbackRate", duration * 0.5f);
			FireProjectileInfo val = default(FireProjectileInfo);
			val.crit = ((BaseState)this).RollCrit();
			val.damage = base.damageStat * 7f;
			val.damageTypeOverride = (DamageType)128;
			val.owner = ((EntityState)this).gameObject;
			val.position = ((EntityState)this).characterBody.corePosition + new Vector3(0f, 4f, 0f);
			val.projectilePrefab = CruelSun.prefab;
			val.rotation = Util.QuaternionSafeLookRotation(((Ray)(ref aimRay)).direction);
			FireProjectileInfo val2 = val;
			ProjectileManager.instance.FireProjectile(val2);
			Util.PlaySound("Play_grandParent_attack3_sun_spawn", ((EntityState)this).gameObject);
		}

		public override void OnExit()
		{
			((EntityState)this).OnExit();
		}
	}
	public class DivineAxeRhittaState : BaseSkillState, IStepSetter
	{
		public static float baseDuration = 1.25f;

		public static float minimumSprintDuration = 0.4f;

		public SphereSearch sphereSearch;

		public List<HurtBox> hurtBoxes;

		public PaladinSwordController swordController;

		public bool hasFired = false;

		public OverlapAttack attack;

		public HitBoxGroup hitBoxGroup;

		public Transform modelTransform;

		public GameObject impact = DivineAxeRhitta.prefab;

		public int swingIndex;

		public bool inCombo;

		public Animator animator;

		public bool inHitPause;

		public bool hasHopped;

		public HitStopCachedState hitStopCachedState;

		public float hitPauseTimer;

		public Vector3 storedVelocity;

		public override void OnEnter()
		{
			((BaseState)this).OnEnter();
			swordController = ((EntityState)this).GetComponent<PaladinSwordController>();
			hitBoxGroup = null;
			modelTransform = ((EntityState)this).GetModelTransform();
			animator = ((EntityState)this).GetModelAnimator();
			((BaseState)this).StartAimMode(2.5f, false);
			if (Object.op_Implicit((Object)(object)modelTransform))
			{
				hitBoxGroup = Array.Find(((Component)modelTransform).GetComponents<HitBoxGroup>(), (HitBoxGroup x) => x.groupName == "SayGex");
			}
			Util.PlaySound("PaladinCloth2", ((EntityState)this).gameObject);
			string text = "Slash" + (1 + swingIndex);
			if (inCombo)
			{
				if (!animator.GetBool("isMoving") && animator.GetBool("isGrounded"))
				{
					((EntityState)this).PlayCrossfade("FullBody, Override", "SlashCombo1", "Slash.playbackRate", baseDuration, 0.05f);
				}
				((EntityState)this).PlayCrossfade("Gesture, Override", "SlashCombo1", "Slash.playbackRate", baseDuration, 0.05f);
			}
			else
			{
				if (!animator.GetBool("isMoving") && animator.GetBool("isGrounded"))
				{
					((EntityState)this).PlayCrossfade("FullBody, Override", text, "Slash.playbackRate", baseDuration, 0.05f);
				}
				((EntityState)this).PlayCrossfade("Gesture, Override", text, "Slash.playbackRate", baseDuration, 0.05f);
			}
		}

		public void Fire()
		{
			//IL_009a: Unknown result type (might be due to invalid IL or missing references)
			//IL_009f: 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_00b7: Unknown result type (might be due to invalid IL or missing references)
			//IL_00b9: Unknown result type (might be due to invalid IL or missing references)
			//IL_00be: Unknown result type (might be due to invalid IL or missing references)
			//IL_00c9: Unknown result type (might be due to invalid IL or missing references)
			//IL_00ee: Unknown result type (might be due to invalid IL or missing references)
			//IL_00f9: 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_010b: Unknown result type (might be due to invalid IL or missing references)
			//IL_0111: Unknown result type (might be due to invalid IL or missing references)
			//IL_0118: Unknown result type (might be due to invalid IL or missing references)
			//IL_011d: Unknown result type (might be due to invalid IL or missing references)
			//IL_0122: Unknown result type (might be due to invalid IL or missing references)
			//IL_0123: Unknown result type (might be due to invalid IL or missing references)
			//IL_0128: Unknown result type (might be due to invalid IL or missing references)
			//IL_012d: Unknown result type (might be due to invalid IL or missing references)
			//IL_0139: Unknown result type (might be due to invalid IL or missing references)
			//IL_014a: Expected O, but got Unknown
			((BaseState)this).AddRecoil(-3f, -6f, -1.5f, 1.5f);
			Util.PlayAttackSpeedSound("Play_loader_m1_swing", ((EntityState)this).gameObject, 0.5f);
			Util.PlaySound("Play_item_proc_armorReduction_hit", ((EntityState)this).gameObject);
			swordController.attacking = true;
			swordController.PlaySwingSound();
			if (((EntityState)this).isAuthority)
			{
				string text = ((swingIndex != 0) ? "SwingLeft" : "SwingRight");
				EffectManager.SimpleMuzzleFlash(DivineAxeRhittaJank.swingPrefab, ((EntityState)this).gameObject, text, true);
			}
			attack = new OverlapAttack
			{
				attacker = ((EntityState)this).gameObject,
				inflictor = ((EntityState)this).gameObject,
				attackerFiltering = (AttackerFiltering)2,
				pushAwayForce = 1500f,
				damage = ((BaseState)this).damageStat * (7f + (((BaseState)this).attackSpeedStat - 1f) * 4.6666665f),
				procCoefficient = 1f,
				isCrit = ((BaseState)this).RollCrit(),
				procChainMask = default(ProcChainMask),
				teamIndex = TeamComponent.GetObjectTeam(((EntityState)this).gameObject),
				forceVector = Vector3.zero,
				hitBoxGroup = hitBoxGroup,
				hitEffectPrefab = impact
			};
			if (((EntityState)this).isAuthority && attack.Fire((List<HurtBox>)null))
			{
				OnHit();
			}
		}

		public void OnHit()
		{
			//IL_0074: Unknown result type (might be due to invalid IL or missing references)
			//IL_0079: Unknown result type (might be due to invalid IL or missing references)
			//IL_00af: Unknown result type (might be due to invalid IL or missing references)
			//IL_00b4: Unknown result type (might be due to invalid IL or missing references)
			//IL_0091: Unknown result type (might be due to invalid IL or missing references)
			//IL_0096: Unknown result type (might be due to invalid IL or missing references)
			Util.PlaySound("Play_item_proc_armorReduction_shatter", ((EntityState)this).gameObject);
			if (!hasHopped)
			{
				if (Object.op_Implicit((Object)(object)((EntityState)this).characterMotor) && !((EntityState)this).characterMotor.isGrounded)
				{
					((BaseState)this).SmallHop(((EntityState)this).characterMotor, 6f);
				}
				hasHopped = true;
			}
			if (!inHitPause)
			{
				if (((EntityState)this).characterMotor.velocity != Vector3.zero)
				{
					storedVelocity = ((EntityState)this).characterMotor.velocity;
				}
				hitStopCachedState = ((BaseState)this).CreateHitStopCachedState(((EntityState)this).characterMotor, animator, "Slash.playbackRate");
				hitPauseTimer = 2f * GroundLight.hitPauseDuration;
				inHitPause = true;
			}
		}

		public void GroundNearby()
		{
			//IL_0020: Unknown result type (might be due to invalid IL or missing references)
			//IL_0025: Unknown result type (might be due to invalid IL or missing references)
			//IL_002c: Unknown result type (might be due to invalid IL or missing references)
			//IL_0031: Unknown result type (might be due to invalid IL or missing references)
			//IL_0036: Unknown result type (might be due to invalid IL or missing references)
			//IL_003c: 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_0046: Unknown result type (might be due to invalid IL or missing references)
			//IL_0056: Expected O, but got Unknown
			//IL_006e: 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_015c: 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_016d: Unknown result type (might be due to invalid IL or missing references)
			//IL_0174: 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_0186: Unknown result type (might be due to invalid IL or missing references)
			//IL_018c: 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_019c: 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_01b4: Unknown result type (might be due to invalid IL or missing references)
			//IL_01b9: Unknown result type (might be due to invalid IL or missing references)
			//IL_01c7: Expected O, but got Unknown
			//IL_01de: Unknown result type (might be due to invalid IL or missing references)
			//IL_01e3: Unknown result type (might be due to invalid IL or missing references)
			//IL_01e6: Unknown result type (might be due to invalid IL or missing references)
			//IL_01f1: Unknown result type (might be due to invalid IL or missing references)
			//IL_01f2: Unknown result type (might be due to invalid IL or missing references)
			//IL_01f7: Unknown result type (might be due to invalid IL or missing references)
			//IL_01fc: Unknown result type (might be due to invalid IL or missing references)
			//IL_0211: Expected O, but got Unknown
			if (!Object.op_Implicit((Object)(object)((EntityState)this).characterBody))
			{
				return;
			}
			hurtBoxes = new List<HurtBox>();
			sphereSearch = new SphereSearch
			{
				origin = ((EntityState)this).characterBody.corePosition,
				mask = ((LayerIndex)(ref LayerIndex.entityPrecise)).mask,
				radius = 24f
			};
			sphereSearch.RefreshCandidates();
			sphereSearch.FilterCandidatesByHurtBoxTeam(TeamMask.GetUnprotectedTeams(((EntityState)this).teamComponent.teamIndex));
			sphereSearch.FilterCandidatesByDistinctHurtBoxEntities();
			sphereSearch.OrderCandidatesByDistance();
			sphereSearch.GetHurtBoxes(hurtBoxes);
			sphereSearch.ClearCandidates();
			if (hurtBoxes.Count > 0)
			{
				Util.PlaySound("Play_item_proc_fireRingTornado_end", ((EntityState)this).gameObject);
			}
			for (int i = 0; i < hurtBoxes.Count; i++)
			{
				HurtBox val = hurtBoxes[i];
				HealthComponent healthComponent = val.healthComponent;
				CharacterBody body = healthComponent.body;
				RigidbodyMotor component = ((Component)body).GetComponent<RigidbodyMotor>();
				Rigidbody rigidbody = body.rigidbody;
				float num = 1f;
				if (Object.op_Implicit((Object)(object)component))
				{
					num = component.mass;
				}
				else if (Object.op_Implicit((Object)(object)rigidbody))
				{
					num = rigidbody.mass;
				}
				if (num < 100f)
				{
					num = 100f;
				}
				DamageInfo val2 = new DamageInfo
				{
					attacker = ((EntityState)this).gameObject,
					canRejectForce = false,
					crit = false,
					damage = 0f,
					damageType = (DamageType)2048,
					procCoefficient = 0f,
					force = new Vector3(0f, -25f * num, 0f),
					inflictor = ((EntityState)this).gameObject
				};
				if (NetworkServer.active)
				{
					healthComponent.TakeDamage(val2);
				}
				EffectData val3 = new EffectData
				{
					origin = body.corePosition,
					rotation = Quaternion.identity,
					scale = body.radius * 1.5f
				};
				val3.SetNetworkedObjectReference(((Component)body).gameObject);
				EffectManager.SpawnEffect(DivineAxeRhitta.groundPrefab, val3, true);
			}
		}

		public override InterruptPriority GetMinimumInterruptPriority()
		{
			//IL_0002: Unknown result type (might be due to invalid IL or missing references)
			//IL_0005: Unknown result type (might be due to invalid IL or missing references)
			return (InterruptPriority)1;
		}

		public override void FixedUpdate()
		{
			//IL_0037: Unknown result type (might be due to invalid IL or missing references)
			//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_0071: Unknown result type (might be due to invalid IL or missing references)
			//IL_0076: Unknown result type (might be due to invalid IL or missing references)
			((EntityState)this).FixedUpdate();
			hitPauseTimer -= Time.fixedDeltaTime;
			if (hitPauseTimer <= 0f && inHitPause)
			{
				((BaseState)this).ConsumeHitStopCachedState(hitStopCachedState, ((EntityState)this).characterMotor, animator);
				inHitPause = false;
				if (storedVelocity != Vector3.zero)
				{
					((EntityState)this).characterMotor.velocity = storedVelocity;
				}
			}
			if (((EntityState)this).fixedAge <= minimumSprintDuration)
			{
				((EntityState)this).characterBody.isSprinting = false;
			}
			if (((EntityState)this).fixedAge >= 0.25f && !hasFired)
			{
				Fire();
				if (Object.op_Implicit((Object)(object)((EntityState)this).characterBody) && Object.op_Implicit((Object)(object)swordController) && swordController.swordActive)
				{
					GroundNearby();
				}
				hasFired = true;
			}
			if (!(((EntityState)this).fixedAge < baseDuration) && ((EntityState)this).isAuthority)
			{
				((EntityState)this).outer.SetNextStateToMain();
			}
		}

		public override void OnExit()
		{
			//IL_0015: Unknown result type (might be due to invalid IL or missing references)
			((EntityState)this).OnExit();
			if (inHitPause)
			{
				((BaseState)this).ConsumeHitStopCachedState(hitStopCachedState, ((EntityState)this).characterMotor, animator);
				inHitPause = false;
			}
			if (Object.op_Implicit((Object)(object)swordController))
			{
				swordController.attacking = false;
			}
		}

		public override void OnSerialize(NetworkWriter writer)
		{
			((BaseSkillState)this).OnSerialize(writer);
			writer.Write((byte)swingIndex);
		}

		public override void OnDeserialize(NetworkReader reader)
		{
			((BaseSkillState)this).OnDeserialize(reader);
			swingIndex = reader.ReadByte();
		}

		public void SetStep(int i)
		{
			//IL_0021: Unknown result type (might be due to invalid IL or missing references)
			swingIndex = i;
			if (swingIndex > 1)
			{
				((InstanceData)((BaseSkillState)this).activatorSkillSlot.skillInstanceData).step = 0;
				swingIndex = 0;
				inCombo = true;
			}
		}
	}
	public class FlameOfLifeState : BaseState
	{
		public Transform modelTransform;

		public static float castAnimationDuration = 0.33f;

		public static float baseDuration = castAnimationDuration + 7f;

		public static float interval = 0.2f;

		public float timer;

		public bool hasAddedStuff;

		public override void OnEnter()
		{
			((BaseState)this).OnEnter();
			modelTransform = ((EntityState)this).GetModelTransform();
			((EntityState)this).PlayAnimation("FullBody, Override", "RageEnter", "Rage.playbackRate", 1.75f);
			Util.PlaySound("PaladinCastTorpor", ((EntityState)this).gameObject);
			Util.PlaySound("Play_item_use_hellfire_start", ((EntityState)this).gameObject);
		}

		public override InterruptPriority GetMinimumInterruptPriority()
		{
			//IL_0002: Unknown result type (might be due to invalid IL or missing references)
			//IL_0005: Unknown result type (might be due to invalid IL or missing references)
			return (InterruptPriority)1;
		}

		public override void FixedUpdate()
		{
			//IL_0080: Unknown result type (might be due to invalid IL or missing references)
			//IL_0085: Unknown result type (might be due to invalid IL or missing references)
			//IL_0096: Unknown result type (might be due to invalid IL or missing references)
			//IL_009b: Unknown result type (might be due to invalid IL or missing references)
			//IL_00ac: Unknown result type (might be due to invalid IL or missing references)
			//IL_00b1: 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_00c7: 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_00d6: Expected O, but got Unknown
			//IL_013a: Unknown result type (might be due to invalid IL or missing references)
			//IL_013f: Unknown result type (might be due to invalid IL or missing references)
			//IL_0150: Unknown result type (might be due to invalid IL or missing references)
			//IL_0155: Unknown result type (might be due to invalid IL or missing references)
			//IL_0166: Unknown result type (might be due to invalid IL or missing references)
			//IL_016b: Unknown result type (might be due to invalid IL or missing references)
			//IL_017c: Unknown result type (might be due to invalid IL or missing references)
			//IL_0181: Unknown result type (might be due to invalid IL or missing references)
			//IL_0186: Unknown result type (might be due to invalid IL or missing references)
			//IL_0190: Expected O, but got Unknown
			((EntityState)this).FixedUpdate();
			if (((EntityState)this).fixedAge >= castAnimationDuration && !hasAddedStuff)
			{
				if (Object.op_Implicit((Object)(object)modelTransform))
				{
					TemporaryOverlay val = ((Component)modelTransform).gameObject.AddComponent<TemporaryOverlay>();
					val.duration = baseDuration + 0.5f;
					val.animateShaderAlpha = true;
					val.alphaCurve = new AnimationCurve((Keyframe[])(object)new Keyframe[4]
					{
						new Keyframe(0f, 1f),
						new Keyframe(0.07f, 1f),
						new Keyframe(0.9f, 1f),
						new Keyframe(1f, 0f)
					});
					val.destroyComponentOnEnd = true;
					val.originalMaterial = FlameOfLife.prefab1;
					val.AddToCharacerModel(((Component)modelTransform).GetComponent<CharacterModel>());
					TemporaryOverlay val2 = ((Component)modelTransform).gameObject.AddComponent<TemporaryOverlay>();
					val2.duration = baseDuration + 1.5f;
					val2.animateShaderAlpha = true;
					val2.alphaCurve = new AnimationCurve((Keyframe[])(object)new Keyframe[4]
					{
						new Keyframe(0f, 1f),
						new Keyframe(0.1f, 1f),
						new Keyframe(0.85f, 1f),
						new Keyframe(1f, 0f)
					});
					val2.destroyComponentOnEnd = true;
					val2.originalMaterial = FlameOfLife.prefab2;
					val2.AddToCharacerModel(((Component)modelTransform).GetComponent<CharacterModel>());
				}
				if (Object.op_Implicit((Object)(object)((EntityState)this).characterBody) && NetworkServer.active)
				{
					if (((EntityState)this).characterBody.HasBuff(All.flameOfLifeHealingDebuff))
					{
						((EntityState)this).characterBody.RemoveBuff(All.flameOfLifeHealingDebuff);
					}
					((EntityState)this).characterBody.AddBuff(All.flameOfLifeHealingDebuff);
					((EntityState)this).characterBody.AddBuff(All.flameOfLifeBuff);
				}
				hasAddedStuff = true;
			}
			if (!(((EntityState)this).fixedAge < baseDuration + castAnimationDuration) && ((EntityState)this).isAuthority)
			{
				((EntityState)this).outer.SetNextStateToMain();
			}
		}

		public override void OnExit()
		{
			((EntityState)this).OnExit();
			Util.PlaySound("Play_mage_R_end", ((EntityState)this).gameObject);
			Util.PlaySound("Stop_item_use_hellfire_loop", ((EntityState)this).gameObject);
			if (Object.op_Implicit((Object)(object)((EntityState)this).characterBody) && NetworkServer.active)
			{
				((EntityState)this).characterBody.RemoveBuff(All.flameOfLifeHealingDebuff);
				((EntityState)this).characterBody.RemoveBuff(All.flameOfLifeBuff);
				((EntityState)this).characterBody.AddTimedBuff(All.flameOfLifeHealingDebuff, 2f);
			}
		}
	}
	public class SunfallState : BaseSkillState
	{
		public static float baseDuration = 3f;

		public bool hasFired = false;

		public bool hasPlayedSound = false;

		public Ray aimRay;

		public override void OnEnter()
		{
			((BaseState)this).OnEnter();
			((BaseState)this).StartAimMode(5f, false);
			Util.PlaySound("PaladinCloth1", ((EntityState)this).gameObject);
			Util.PlayAttackSpeedSound("Play_loader_m1_swing", ((EntityState)this).gameObject, 0.5f);
			((EntityState)this).PlayAnimation("Gesture, Override", "ThrowSpell", "Spell.playbackRate", baseDuration);
			if (Object.op_Implicit((Object)(object)((EntityState)this).characterBody) && NetworkServer.active)
			{
				((EntityState)this).characterBody.AddBuff(All.sunfallStunDebuff);
			}
		}

		public IEnumerator Fire()
		{
			Util.PlaySound("Play_grandParent_attack3_sun_spawn", ((EntityState)this).gameObject);
			((BaseState)this).AddRecoil(-4f, -4.5f, -2.75f, 2.75f);
			RaycastHit raycastInfo = default(RaycastHit);
			for (int i = 0; i < 20; i++)
			{
				yield return (object)new WaitForSeconds(0.06f);
				aimRay = new Ray(((EntityState)this).inputBank.aimOrigin + ((EntityState)this).inputBank.aimDirection * 1f, ((EntityState)this).inputBank.aimDirection);
				if (Physics.Raycast(aimRay, ref raycastInfo, 1000f, LayerMask.op_Implicit(CommonMasks.bullet), (QueryTriggerInteraction)1))
				{
					((BaseState)this).AddRecoil(-0.5f, 0.5f, -0.75f, 0.75f);
					FireProjectileInfo fpi = new FireProjectileInfo
					{
						crit = ((BaseState)this).RollCrit(),
						damage = ((BaseState)this).damageStat * (3.5f + (((BaseState)this).attackSpeedStat - 1f) * 2.3333333f),
						damageTypeOverride = (DamageType)0,
						owner = ((EntityState)this).gameObject,
						position = ((RaycastHit)(ref raycastInfo)).point + new Vector3(Main.rng.RangeFloat(-1.5f * (float)i, 1.5f * (float)i), 45f + Main.rng.RangeFloat(-1.1f * (float)i, 1.1f * (float)i), Main.rng.RangeFloat(-1.51f * (float)i, 1.51f * (float)i)),
						rotation = Util.QuaternionSafeLookRotation(new Vector3(Main.rng.RangeFloat(0f, 0.02f * (float)i), -1f, Main.rng.RangeFloat(0f, 0.021f * (float)i))),
						projectilePrefab = Sunfall.prefab
					};
					if (((EntityState)this).isAuthority)
					{
						ProjectileManager.instance.FireProjectile(fpi);
					}
				}
				raycastInfo = default(RaycastHit);
			}
		}

		public override InterruptPriority GetMinimumInterruptPriority()
		{
			//IL_0002: Unknown result type (might be due to invalid IL or missing references)
			//IL_0005: Unknown result type (might be due to invalid IL or missing references)
			return (InterruptPriority)1;
		}

		public override void FixedUpdate()
		{
			((EntityState)this).FixedUpdate();
			((EntityState)this).characterBody.isSprinting = false;
			if (((EntityState)this).fixedAge >= 0.5f && !hasPlayedSound)
			{
				Util.PlayAttackSpeedSound("Play_grandParent_spawn", ((EntityState)this).gameObject, 0.5f);
				hasPlayedSound = true;
			}
			if (((EntityState)this).fixedAge >= 1.5f && !hasFired)
			{
				((MonoBehaviour)((EntityState)this).outer).StartCoroutine(Fire());
				hasFired = true;
			}
			if (!(((EntityState)this).fixedAge < baseDuration) && ((EntityState)this).isAuthority)
			{
				((EntityState)this).outer.SetNextStateToMain();
			}
		}

		public override void OnExit()
		{
			((EntityState)this).OnExit();
			if (Object.op_Implicit((Object)(object)((EntityState)this).characterBody) && NetworkServer.active)
			{
				((EntityState)this).characterBody.RemoveBuff(All.sunfallStunDebuff);
			}
		}
	}
}
namespace EscanorPaladinSkills.States.Upgrades
{
	public class CruelSunUpgradedState : BaseState
	{
		public static float baseDuration = 1.25f;

		public float duration;

		public static string sound;

		public Ray aimRay;

		public bool hasFired = false;

		public bool hasPlayedSound = false;

		public static float barrierGain = 0.05f;

		public override void OnEnter()
		{
			((BaseState)this).OnEnter();
			duration = baseDuration / base.attackSpeedStat;
			if (Object.op_Implicit((Object)(object)((EntityState)this).characterBody))
			{
				((EntityState)this).characterBody.SetAimTimer(1f);
			}
			((EntityState)this).PlayAnimation("Gesture, Override", "ChannelSpell", "Spell.playbackRate", duration * 0.5f);
			Util.PlaySound("PaladinCloth1", ((EntityState)this).gameObject);
			Util.PlaySound("PaladinCloth1", ((EntityState)this).gameObject);
		}

		public override InterruptPriority GetMinimumInterruptPriority()
		{
			//IL_0002: Unknown result type (might be due to invalid IL or missing references)
			//IL_0005: Unknown result type (might be due to invalid IL or missing references)
			return (InterruptPriority)1;
		}

		public override void FixedUpdate()
		{
			//IL_0039: Unknown result type (might be due to invalid IL or missing references)
			//IL_003e: Unknown result type (might be due to invalid IL or missing references)
			((EntityState)this).FixedUpdate();
			if (!(((EntityState)this).fixedAge < duration) && ((EntityState)this).isAuthority)
			{
				if (!hasFired)
				{
					aimRay = ((BaseState)this).GetAimRay();
					FireProjectile();
					hasFired = true;
				}
				((EntityState)this).outer.SetNextStateToMain();
			}
		}

		public void FireProjectile()
		{
			//IL_0040: 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_00a0: 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_00aa: Unknown result type (might be due to invalid IL or missing references)
			//IL_00c3: Unknown result type (might be due to invalid IL or missing references)
			//IL_00c8: Unknown result type (might be due to invalid IL or missing references)
			//IL_00cd: Unknown result type (might be due to invalid IL or missing references)
			//IL_00d2: Unknown result type (might be due to invalid IL or missing references)
			//IL_00d3: Unknown result type (might be due to invalid IL or missing references)
			//IL_00d9: Unknown result type (might be due to invalid IL or missing references)
			((BaseState)this).AddRecoil(7f, 7f, -2.5f, 2.5f);
			((EntityState)this).PlayAnimation("Gesture, Override", "ThrowSpell", "Spell.playbackRate", duration * 0.5f);
			FireProjectileInfo val = default(FireProjectileInfo);
			val.crit = ((BaseState)this).RollCrit();
			val.damage = base.damageStat * 10f;
			val.damageTypeOverride = (DamageType)128;
			val.owner = ((EntityState)this).gameObject;
			val.position = ((EntityState)this).characterBody.corePosition + new Vector3(0f, 8f, 0f);
			val.projectilePrefab = CruelSunUpgraded.prefab;
			val.rotation = Util.QuaternionSafeLookRotation(((Ray)(ref aimRay)).direction);
			FireProjectileInfo val2 = val;
			ProjectileManager.instance.FireProjectile(val2);
			Util.PlaySound("Play_grandParent_attack3_sun_spawn", ((EntityState)this).gameObject);
		}

		public override void OnExit()
		{
			((EntityState)this).OnExit();
		}
	}
	public class DivineAxeRhittaUpgradedState : BaseSkillState, IStepSetter
	{
		public static float baseDuration = 1.25f;

		public static float minimumSprintDuration = 0.4f;

		public SphereSearch sphereSearch;

		public List<HurtBox> hurtBoxes;

		public PaladinSwordController swordController;

		public bool hasFired = false;

		public OverlapAttack attack;

		public HitBoxGroup hitBoxGroup;

		public Transform modelTransform;

		public GameObject impact = DivineAxeRhitta.prefab;

		public int swingIndex;

		public bool inCombo;

		public Animator animator;

		public bool inHitPause;

		public bool hasHopped;

		public HitStopCachedState hitStopCachedState;

		public float hitPauseTimer;

		public Vector3 storedVelocity;

		public override void OnEnter()
		{
			((BaseState)this).OnEnter();
			swordController = ((EntityState)this).GetComponent<PaladinSwordController>();
			hitBoxGroup = null;
			modelTransform = ((EntityState)this).GetModelTransform();
			animator = ((EntityState)this).GetModelAnimator();
			((BaseState)this).StartAimMode(2.5f, false);
			if (Object.op_Implicit((Object)(object)modelTransform))
			{
				hitBoxGroup = Array.Find(((Component)modelTransform).GetComponents<HitBoxGroup>(), (HitBoxGroup x) => x.groupName == "SayGex");
			}
			Util.PlaySound("PaladinCloth2", ((EntityState)this).gameObject);
			string text = "Slash" + (1 + swingIndex);
			if (inCombo)
			{
				if (!animator.GetBool("isMoving") && animator.GetBool("isGrounded"))
				{
					((EntityState)this).PlayCrossfade("FullBody, Override", "SlashCombo1", "Slash.playbackRate", baseDuration, 0.05f);
				}
				((EntityState)this).PlayCrossfade("Gesture, Override", "SlashCombo1", "Slash.playbackRate", baseDuration, 0.05f);
			}
			else
			{
				if (!animator.GetBool("isMoving") && animator.GetBool("isGrounded"))
				{
					((EntityState)this).PlayCrossfade("FullBody, Override", text, "Slash.playbackRate", baseDuration, 0.05f);
				}
				((EntityState)this).PlayCrossfade("Gesture, Override", text, "Slash.playbackRate", baseDuration, 0.05f);
			}
		}

		public void Fire()
		{
			//IL_009a: Unknown result type (might be due to invalid IL or missing references)
			//IL_009f: 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_00b7: Unknown result type (might be due to invalid IL or missing references)
			//IL_00b9: Unknown result type (might be due to invalid IL or missing references)
			//IL_00be: Unknown result type (might be due to invalid IL or missing references)
			//IL_00c9: Unknown result type (might be due to invalid IL or missing references)
			//IL_00ee: Unknown result type (might be due to invalid IL or missing references)
			//IL_00f9: 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_010b: Unknown result type (might be due to invalid IL or missing references)
			//IL_0111: Unknown result type (might be due to invalid IL or missing references)
			//IL_0118: Unknown result type (might be due to invalid IL or missing references)
			//IL_011d: Unknown result type (might be due to invalid IL or missing references)
			//IL_0122: Unknown result type (might be due to invalid IL or missing references)
			//IL_0123: Unknown result type (might be due to invalid IL or missing references)
			//IL_0128: Unknown result type (might be due to invalid IL or missing references)
			//IL_012d: Unknown result type (might be due to invalid IL or missing references)
			//IL_0139: Unknown result type (might be due to invalid IL or missing references)
			//IL_014a: Expected O, but got Unknown
			((BaseState)this).AddRecoil(-3f, -6f, -1.5f, 1.5f);
			Util.PlayAttackSpeedSound("Play_loader_m1_swing", ((EntityState)this).gameObject, 0.5f);
			Util.PlaySound("Play_item_proc_armorReduction_hit", ((EntityState)this).gameObject);
			swordController.attacking = true;
			swordController.PlaySwingSound();
			if (((EntityState)this).isAuthority)
			{
				string text = ((swingIndex != 0) ? "SwingLeft" : "SwingRight");
				EffectManager.SimpleMuzzleFlash(DivineAxeRhittaJank.swingPrefab, ((EntityState)this).gameObject, text, true);
			}
			attack = new OverlapAttack
			{
				attacker = ((EntityState)this).gameObject,
				inflictor = ((EntityState)this).gameObject,
				attackerFiltering = (AttackerFiltering)2,
				pushAwayForce = 1500f,
				damage = ((BaseState)this).damageStat * (7f + (((BaseState)this).attackSpeedStat - 1f) * 4.6666665f),
				procCoefficient = 1f,
				isCrit = ((BaseState)this).RollCrit(),
				procChainMask = default(ProcChainMask),
				teamIndex = TeamComponent.GetObjectTeam(((EntityState)this).gameObject),
				forceVector = Vector3.zero,
				hitBoxGroup = hitBoxGroup,
				hitEffectPrefab = impact
			};
			if (((EntityState)this).isAuthority && attack.Fire((List<HurtBox>)null))
			{
				OnHit();
			}
		}

		public void OnHit()
		{
			//IL_0074: Unknown result type (might be due to invalid IL or missing references)
			//IL_0079: Unknown result type (might be due to invalid IL or missing references)
			//IL_00af: Unknown result type (might be due to invalid IL or missing references)
			//IL_00b4: Unknown result type (might be due to invalid IL or missing references)
			//IL_0091: Unknown result type (might be due to invalid IL or missing references)
			//IL_0096: Unknown result type (might be due to invalid IL or missing references)
			Util.PlaySound("Play_item_proc_armorReduction_shatter", ((EntityState)this).gameObject);
			if (!hasHopped)
			{
				if (Object.op_Implicit((Object)(object)((EntityState)this).characterMotor) && !((EntityState)this).characterMotor.isGrounded)
				{
					((BaseState)this).SmallHop(((EntityState)this).characterMotor, 6f);
				}
				hasHopped = true;
			}
			if (!inHitPause)
			{
				if (((EntityState)this).characterMotor.velocity != Vector3.zero)
				{
					storedVelocity = ((EntityState)this).characterMotor.velocity;
				}
				hitStopCachedState = ((BaseState)this).CreateHitStopCachedState(((EntityState)this).characterMotor, animator, "Slash.playbackRate");
				hitPauseTimer = 2f * GroundLight.hitPauseDuration;
				inHitPause = true;
			}
		}

		public void GroundNearby()
		{
			//IL_0020: Unknown result type (might be due to invalid IL or missing references)
			//IL_0025: Unknown result type (might be due to invalid IL or missing references)
			//IL_002c: Unknown result type (might be due to invalid IL or missing references)
			//IL_0031: Unknown result type (might be due to invalid IL or missing references)
			//IL_0036: Unknown result type (might be due to invalid IL or missing references)
			//IL_003c: 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_0046: Unknown result type (might be due to invalid IL or missing references)
			//IL_0056: Expected O, but got Unknown
			//IL_006e: 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_015c: 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_016d: Unknown result type (might be due to invalid IL or missing references)
			//IL_0174: 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_0186: Unknown result type (might be due to invalid IL or missing references)
			//IL_018c: 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_019c: 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_01b4: Unknown result type (might be due to invalid IL or missing references)
			//IL_01b9: Unknown result type (might be due to invalid IL or missing references)
			//IL_01c7: Expected O, but got Unknown
			//IL_01de: Unknown result type (might be due to invalid IL or missing references)
			//IL_01e3: Unknown result type (might be due to invalid IL or missing references)
			//IL_01e6: Unknown result type (might be due to invalid IL or missing references)
			//IL_01f1: Unknown result type (might be due to invalid IL or missing references)
			//IL_01f2: Unknown result type (might be due to invalid IL or missing references)
			//IL_01f7: Unknown result type (might be due to invalid IL or missing references)
			//IL_01fc: Unknown result type (might be due to invalid IL or missing references)
			//IL_0211: Expected O, but got Unknown
			if (!Object.op_Implicit((Object)(object)((EntityState)this).characterBody))
			{
				return;
			}
			hurtBoxes = new List<HurtBox>();
			sphereSearch = new SphereSearch
			{
				origin = ((EntityState)this).characterBody.corePosition,
				mask = ((LayerIndex)(ref LayerIndex.entityPrecise)).mask,
				radius = 24f
			};
			sphereSearch.RefreshCandidates();
			sphereSearch.FilterCandidatesByHurtBoxTeam(TeamMask.GetUnprotectedTeams(((EntityState)this).teamComponent.teamIndex));
			sphereSearch.FilterCandidatesByDistinctHurtBoxEntities();
			sphereSearch.OrderCandidatesByDistance();
			sphereSearch.GetHurtBoxes(hurtBoxes);
			sphereSearch.ClearCandidates();
			if (hurtBoxes.Count > 0)
			{
				Util.PlaySound("Play_item_proc_fireRingTornado_end", ((EntityState)this).gameObject);
			}
			for (int i = 0; i < hurtBoxes.Count; i++)
			{
				HurtBox val = hurtBoxes[i];
				HealthComponent healthComponent = val.healthComponent;
				CharacterBody body = healthComponent.body;
				RigidbodyMotor component = ((Component)body).GetComponent<RigidbodyMotor>();
				Rigidbody rigidbody = body.rigidbody;
				float num = 1f;
				if (Object.op_Implicit((Object)(object)component))
				{
					num = component.mass;
				}
				else if (Object.op_Implicit((Object)(object)rigidbody))
				{
					num = rigidbody.mass;
				}
				if (num < 100f)
				{
					num = 100f;
				}
				DamageInfo val2 = new DamageInfo
				{
					attacker = ((EntityState)this).gameObject,
					canRejectForce = false,
					crit = false,
					damage = 0f,
					damageType = (DamageType)2048,
					procCoefficient = 0f,
					force = new Vector3(0f, -25f * num, 0f),
					inflictor = ((EntityState)this).gameObject
				};
				if (NetworkServer.active)
				{
					healthComponent.TakeDamage(val2);
				}
				EffectData val3 = new EffectData
				{
					origin = body.corePosition,
					rotation = Quaternion.identity,
					scale = body.radius * 1.5f
				};
				val3.SetNetworkedObjectReference(((Component)body).gameObject);
				EffectManager.SpawnEffect(DivineAxeRhitta.groundPrefab, val3, true);
			}
		}

		public override InterruptPriority GetMinimumInterruptPriority()
		{
			//IL_0002: Unknown result type (might be due to invalid IL or missing references)
			//IL_0005: Unknown result type (might be due to invalid IL or missing references)
			return (InterruptPriority)1;
		}

		public override void FixedUpdate()
		{
			//IL_0037: Unknown result type (might be due to invalid IL or missing references)
			//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_0071: Unknown result type (might be due to invalid IL or missing references)
			//IL_0076: Unknown result type (might be due to invalid IL or missing references)
			((EntityState)this).FixedUpdate();
			hitPauseTimer -= Time.fixedDeltaTime;
			if (hitPauseTimer <= 0f && inHitPause)
			{
				((BaseState)this).ConsumeHitStopCachedState(hitStopCachedState, ((EntityState)this).characterMotor, animator);
				inHitPause = false;
				if (storedVelocity != Vector3.zero)
				{
					((EntityState)this).characterMotor.velocity = storedVelocity;
				}
			}
			if (((EntityState)this).fixedAge <= minimumSprintDuration)
			{
				((EntityState)this).characterBody.isSprinting = false;
			}
			if (((EntityState)this).fixedAge >= 0.25f && !hasFired)
			{
				Fire();
				if (Object.op_Implicit((Object)(object)((EntityState)this).characterBody) && Object.op_Implicit((Object)(object)swordController) && swordController.swordActive)
				{
					GroundNearby();
				}
				hasFired = true;
			}
			if (!(((EntityState)this).fixedAge < baseDuration) && ((EntityState)this).isAuthority)
			{
				((EntityState)this).outer.SetNextStateToMain();
			}
		}

		public override void OnExit()
		{
			//IL_0015: Unknown result type (might be due to invalid IL or missing references)
			((EntityState)this).OnExit();
			if (inHitPause)
			{
				((BaseState)this).ConsumeHitStopCachedState(hitStopCachedState, ((EntityState)this).characterMotor, animator);
				inHitPause = false;
			}
			if (Object.op_Implicit((Object)(object)swordController))
			{
				swordController.attacking = false;
			}
		}

		public override void OnSerialize(NetworkWriter writer)
		{
			((BaseSkillState)this).OnSerialize(writer);
			writer.Write((byte)swingIndex);
		}

		public override void OnDeserialize(NetworkReader reader)
		{
			((BaseSkillState)this).OnDeserialize(reader);
			swingIndex = reader.ReadByte();
		}

		public void SetStep(int i)
		{
			//IL_0021: Unknown result type (might be due to invalid IL or missing references)
			swingIndex = i;
			if (swingIndex > 1)
			{
				((InstanceData)((BaseSkillState)this).activatorSkillSlot.skillInstanceData).step = 0;
				swingIndex = 0;
				inCombo = true;
			}
		}
	}
}
namespace EscanorPaladinSkills.States.Upgrades.SunlightSpear
{
	public class ChargeSunlightSpearUpgradedState : BaseChargeSpellState
	{
		private GameObject chargeEffect;

		private Vector3 originalScale;

		public override void OnEnter()
		{
			//IL_008c: Unknown result type (might be due to invalid IL or missing references)
			//IL_0091: Unknown result type (might be due to invalid IL or missing references)
			base.baseDuration = 1.25f;
			base.chargeEffectPrefab = null;
			base.chargeSoundString = "Play_mage_m2_charge";
			base.crosshairOverridePrefab = LegacyResourcesAPI.Load<GameObject>("Prefabs/Crosshair/ToolbotGrenadeLauncherCrosshair");
			base.maxBloomRadius = 0.2f;
			base.minBloomRadius = 2f;
			((BaseChargeSpellState)this).OnEnter();
			ChildLocator modelChildLocator = ((EntityState)this).GetModelChildLocator();
			if (Object.op_Implicit((Object)(object)modelChildLocator))
			{
				chargeEffect = ((Component)modelChildLocator.FindChild("SpearChargeEffect")).gameObject;
				chargeEffect.SetActive(true);
				originalScale = chargeEffect.transform.localScale;
			}
		}

		public override void FixedUpdate()
		{
			//IL_0014: 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_0029: Unknown result type (might be due to invalid IL or missing references)
			((BaseChargeSpellState)this).FixedUpdate();
			chargeEffect.transform.localScale = originalScale * 6f * ((BaseChargeSpellState)this).CalcCharge();
		}

		public override void OnExit()
		{
			//IL_0024: Unknown result type (might be due to invalid IL or missing references)
			((BaseChargeSpellState)this).OnExit();
			if (Object.op_Implicit((Object)(object)chargeEffect))
			{
				chargeEffect.transform.localScale = originalScale;
				chargeEffect.SetActive(false);
			}
		}

		public override BaseThrowSpellState GetNextState()
		{
			return (BaseThrowSpellState)(object)new ThrowSunlightSpearUpgradedState();
		}
	}
	public class ThrowSunlightSpearUpgradedState : BaseThrowSpellState
	{
		public override void OnEnter()
		{
			base.baseDuration = 0.8f;
			base.force = 4000f;
			base.minDamageCoefficient = 3f;
			base.maxDamageCoefficient = 8f;
			base.muzzleflashEffectPrefab = FirePistol2.muzzleEffectPrefab;
			base.projectilePrefab = SunlightSpearUpgraded.prefab;
			base.selfForce = 2500f;
			((BaseThrowSpellState)this).OnEnter();
		}
	}
}
namespace EscanorPaladinSkills.States.Upgrades.SpinningSlash
{
	public class SpinningSlashAirborneAltUpgradedState : BaseSkillState
	{
		public static float damageCoefficient = 10f;

		public static float leapDuration = 0.5f;

		public static float dropVelocity = 60f;

		public static float hopVelocity = 30f;

		private float duration;

		private bool hasFired;

		private bool hasLanded;

		private float hitPauseTimer;

		private OverlapAttack attack;

		private bool inHitPause;

		private float stopwatch;

		private Animator animator;

		private HitStopCachedState hitStopCachedState;

		private PaladinSwordController swordController;

		public override void OnEnter()
		{
			//IL_0065: 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_006e: 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_0090: Unknown result type (might be due to invalid IL or missing references)
			//IL_0095: Unknown result type (might be due to invalid IL or missing references)
			//IL_00e6: Unknown result type (might be due to invalid IL or missing references)
			//IL_00ec: Unknown result type (might be due to invalid IL or missing references)
			//IL_00ed: Unknown result type (might be due to invalid IL or missing references)
			//IL_00b8: 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_00c7: Unknown result type (might be due to invalid IL or missing references)
			//IL_018b: Unknown result type (might be due to invalid IL or missing references)
			//IL_0190: Unknown result type (might be due to invalid IL or missing references)
			//IL_0193: Unknown result type (might be due to invalid IL or missing references)
			//IL_0198: Unknown result type (might be due to invalid IL or missing references)
			//IL_01a4: Unknown result type (might be due to invalid IL or missing references)
			//IL_01b0: Unknown result type (might be due to invalid IL or missing references)
			//IL_01b2: Unknown result type (might be due to invalid IL or missing references)
			//IL_01b7: Unknown result type (might be due to invalid IL or missing references)
			//IL_01bc: Unknown result type (might be due to invalid IL or missing references)
			//IL_01e4: Unknown result type (might be due to invalid IL or missing references)
			//IL_01ef: Unknown result type (might be due to invalid IL or missing references)
			//IL_0200: Unknown result type (might be due to invalid IL or missing references)
			//IL_0201: Unknown result type (might be due to invalid IL or missing references)
			//IL_0206: Unknown result type (might be due to invalid IL or missing references)
			//IL_0210: Unknown result type (might be due to invalid IL or missing references)
			//IL_0215: Unknown result type (might be due to invalid IL or missing references)
			//IL_021a: Unknown result type (might be due to invalid IL or missing references)
			//IL_0225: Unknown result type (might be due to invalid IL or missing references)
			//IL_022c: Unknown result type (might be due to invalid IL or missing references)
			//IL_0238: Unknown result type (might be due to invalid IL or missing references)
			//IL_023e: Unknown result type (might be due to invalid IL or missing references)
			//IL_0243: Unknown result type (might be due to invalid IL or missing references)
			//IL_024d: Expected O, but got Unknown
			//IL_0269: Unknown result type (might be due to invalid IL or missing references)
			//IL_026e: Unknown result type (might be due to invalid IL or missing references)
			((BaseState)this).OnEnter();
			duration = leapDuration / (0.5f + 0.5f * ((BaseState)this).attackSpeedStat);
			hasFired = false;
			hasLanded = false;
			animator = ((EntityState)this).GetModelAnimator();
			swordController = ((EntityState)this).GetComponent<PaladinSwordController>();
			((EntityState)this).skillLocator.secondary.DeductStock(1);
			Ray aimRay = ((BaseState)this).GetAimRay();
			Vector3 direction = ((Ray)(ref aimRay)).direction;
			if (PaladinPlugin.IsLocalVRPlayer(((EntityState)this).characterBody))
			{
				direction = ((Component)Camera.main).transform.forward;
			}
			if (((EntityState)this).isAuthority)
			{
				((EntityState)this).characterBody.isSprinting = true;
				CharacterMotor characterMotor = ((EntityState)this).characterMotor;
				characterMotor.velocity *= 0.1f;
				((BaseState)this).SmallHop(((EntityState)this).characterMotor, hopVelocity);
			}
			CharacterBody characterBody = ((EntityState)this).characterBody;
			characterBody.bodyFlags = (BodyFlags)(characterBody.bodyFlags | 1);
			HitBoxGroup hitBoxGroup = null;
			Transform modelTransform = ((EntityState)this).GetModelTransform();
			string hitboxString = "LeapStrike";
			if (Object.op_Implicit((Object)(object)modelTransform))
			{
				hitBoxGroup = Array.Find(((Component)modelTransform).GetComponents<HitBoxGroup>(), (HitBoxGroup element) => element.groupName == hitboxString);
			}
			((EntityState)this).PlayAnimation("FullBody, Override", "LeapSlam2", "Whirlwind.playbackRate", duration * 1.5f);
			Util.PlaySound("PaladinLunge", ((EntityState)this).gameObject);
			Util.PlaySound("PaladinCloth2", ((EntityState)this).gameObject);
			PaladinSwordController obj = swordController;
			obj.airSlamStacks++;
			float num = damageCoefficient;
			attack = new OverlapAttack
			{
				damageType = (DamageType)32,
				attacker = ((EntityState)this).gameObject,
				inflictor = ((EntityState)this).gameObject,
				teamIndex = ((BaseState)this).GetTeam(),
				damage = (0.5f + 0.5f * (float)swordController.airSlamStacks) * num * ((BaseState)this).damageStat,
				procCoefficient = 1f,
				hitEffectPrefab = swordController.hitEffect,
				forceVector = -Vector3.up * 6000f,
				pushAwayForce = 500f,
				hitBoxGroup = hitBoxGroup,
				isCrit = ((BaseState)this).RollCrit(),
				impactSound = Assets.swordHitSoundEventL.index
			};
			if (swordController.isBlunt)
			{
				attack.impactSound = Assets.batHitSoundEventL.index;
			}
		}

		public override void OnExit()
		{
			//IL_0020: 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)
			((EntityState)this).OnExit();
			((EntityState)this).PlayAnimation("FullBody, Override", "BufferEmpty");
			CharacterBody characterBody = ((EntityState)this).characterBody;
			characterBody.bodyFlags = (BodyFlags)(characterBody.bodyFlags & -2);
		}

		public void FireAttack()
		{
			//IL_00d2: Unknown result type (might be due to invalid IL or missing references)
			//IL_00d7: 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_0094: Unknown result type (might be due to invalid IL or missing references)
			//IL_0099: 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_00aa: Unknown result type (might be due to invalid IL or missing references)
			//IL_00b5: Unknown result type (might be due to invalid IL or missing references)
			//IL_00ba: Unknown result type (might be due to invalid IL or missing references)
			//IL_00bf: Unknown result type (might be due to invalid IL or missing references)
			//IL_011a: Unknown result type (might be due to invalid IL or missing references)
			//IL_011f: Unknown result type (might be due to invalid IL or missing references)
			if (!hasFired)
			{
				hasFired = true;
				swordController.PlaySwingSound();
				if (((EntityState)this).isAuthority)
				{
					((BaseState)this).AddRecoil(-1f * GroundSweep.attackRecoil, -2f * GroundSweep.attackRecoil, -0.5f * GroundSweep.attackRecoil, 0.5f * GroundSweep.attackRecoil);
					EffectManager.SimpleMuzzleFlash(swordController.swingEffect, ((EntityState)this).gameObject, "SwingDown", true);
					CharacterMotor characterMotor = ((EntityState)this).characterMotor;
					characterMotor.velocity *= 0.1f;
					CharacterMotor characterMotor2 = ((EntityState)this).characterMotor;
					characterMotor2.velocity += Vector3.up * (0f - AirSlamAlt.dropVelocity);
				}
			}
			if (!((EntityState)this).isAuthority)
			{
				return;
			}
			Ray aimRay = ((BaseState)this).GetAimRay();
			if (attack.Fire((List<HurtBox>)null))
			{
				swordController.airSlamStacks = 1;
				if (!inHitPause)
				{
					hitStopCachedState = ((BaseState)this).CreateHitStopCachedState(((EntityState)this).characterMotor, animator, "Whirlwind.playbackRate");
					hitPauseTimer = 4f * GroundLight.hitPauseDuration / ((BaseState)this).attackSpeedStat;
					inHitPause = true;
				}
			}
		}

		public override void FixedUpdate()
		{
			//IL_007c: Unknown result type (might be due to invalid IL or missing references)
			//IL_0082: Expected O, but got Unknown
			((EntityState)this).FixedUpdate();
			((BaseState)this).StartAimMode(0.5f, false);
			stopwatch += Time.fixedDeltaTime;
			if (stopwatch >= duration)
			{
				FireAttack();
				if (((EntityState)this).isAuthority && ((EntityState)this).inputBank.skill2.down && ((EntityState)this).skillLocator.secondary.stock > 0)
				{
					EntityState nextState = (EntityState)new AirSlamAlt();
					((EntityState)this).outer.SetNextState(nextState);
					return;
				}
			}
			if (stopwatch >= duration && ((EntityState)this).isAuthority && ((EntityState)this).characterMotor.isGrounded)
			{
				GroundImpact();
				((EntityState)this).outer.SetNextStateToMain();
			}
		}

		private void FireShockwave()
		{
			//IL_0013: Unknown result type (might be due to invalid IL or missing references)
			//IL_0018: Unknown result type (might be due to invalid IL or missing references)
			//IL_001f: Unknown result type (might be due to invalid IL or missing references)
			//IL_0024: Unknown result type (might be due to invalid IL or missing references)
			//IL_002f: 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)
			//IL_0031: Unknown result type (might be due to invalid IL or missing references)
			Transform val = ((BaseState)this).FindModelChild("SwingCenter");
			Vector3 footPosition = ((EntityState)this).characterBody.footPosition;
			Vector3 forward = ((EntityState)this).characterDirection.forward;
			ProjectileManager.instance.FireProjectile(Projectiles.shockwave, footPosition, Util.QuaternionSafeLookRotation(forward), ((EntityState)this).gameObject, ((EntityState)this).characterBody.damage * 3f, WeaponSlam.waveProjectileForce, ((BaseState)this).RollCrit(), (DamageColorIndex)0, (GameObject)null, -1f);
		}

		private void GroundImpact()
		{
			//IL_006f: Unknown result type (might be due to invalid IL or missing references)
			//IL_0074: Unknown result type (might be due to invalid IL or missing references)
			//IL_007b: Unknown result type (might be due to invalid IL or missing references)
			//IL_0086: Unknown result type (might be due to invalid IL or missing references)
			//IL_0092: Expected O, but got Unknown
			if (!hasLanded)
			{
				hasLanded = true;
				if (Object.op_Implicit((Object)(object)swordController) && swordController.swordActive)
				{
					FireShockwave();
				}
				swordController.airSlamStacks = 1;
				Util.PlaySound("PaladinGroundImpact", ((EntityState)this).gameObject);
				Util.PlaySound("PaladinLeapSlam", ((EntityState)this).gameObject);
				EffectData val = new EffectData
				{
					origin = ((EntityState)this).characterBody.footPosition,
					scale = 2f
				};
				EffectManager.SpawnEffect(LegacyResourcesAPI.Load<GameObject>("Prefabs/Effects/ImpactEffects/ParentSlamEffect"), val, true);
			}
		}

		public override InterruptPriority GetMinimumInterruptPriority()
		{
			//IL_0002: Unknown result type (might be due to invalid IL or missing references)
			//IL_0005: Unknown result type (might be due to invalid IL or missing references)
			return (InterruptPriority)2;
		}
	}
	public class SpinningSlashAirborneUpgradedState : BaseSkillState
	{
		public static float damageCoefficient = 10f;

		public static float leapDuration = 0.6f;

		public static float dropVelocity = 36f;

		private float duration;

		private bool hasFired;

		private bool hasLanded;

		private float hitPauseTimer;

		private OverlapAttack attack;

		private bool inHitPause;

		private float stopwatch;

		private Animator animator;

		private HitStopCachedState hitStopCachedState;

		private PaladinSwordController swordController;

		private float previousAirControl;

		public override void OnEnter()
		{
			//IL_008a: 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_0093: Unknown result type (might be due to invalid IL or missing references)
			//IL_0098: Unknown result type (might be due to invalid IL or missing references)
			//IL_00b5: Unknown result type (might be due to invalid IL or missing references)
			//IL_00ba: Unknown result type (might be due to invalid IL or missing references)
			//IL_0199: Unknown result type (might be due to invalid IL or missing references)
			//IL_019a: Unknown result type (might be due to invalid IL or missing references)
			//IL_01a6: 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_01ad: 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_00f8: Unknown result type (might be due to invalid IL or missing references)
			//IL_0108: Unknown result type (might be due to invalid IL or missing references)
			//IL_0113: Unknown result type (might be due to invalid IL or missing references)
			//IL_0118: Unknown result type (might be due to invalid IL or missing references)
			//IL_011a: Unknown result type (might be due to invalid IL or missing references)
			//IL_0124: Unknown result type (might be due to invalid IL or missing references)
			//IL_012e: Unknown result type (might be due to invalid IL or missing references)
			//IL_0133: Unknown result type (might be due to invalid IL or missing references)
			//IL_0135: Unknown result type (might be due to invalid IL or missing references)
			//IL_0140: Unknown result type (might be due to invalid IL or missing references)
			//IL_0146: Unknown result type (might be due to invalid IL or missing references)
			//IL_014b: Unknown result type (might be due to invalid IL or missing references)
			//IL_014f: 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_0164: Unknown result type (might be due to invalid IL or missing references)
			//IL_017d: Unknown result type (might be due to invalid IL or missing references)
			//IL_017f: Unknown result type (might be due to invalid IL or missing references)
			//IL_0181: Unknown result type (might be due to invalid IL or missing references)
			//IL_0186: Unknown result type (might be due to invalid IL or missing references)
			//IL_0188: Unknown result type (might be due to invalid IL or missing references)
			//IL_018d: Unknown result type (might be due to invalid IL or missing references)
			//IL_0244: Unknown result type (might be due to invalid IL or missing references)
			//IL_0249: Unknown result type (might be due to invalid IL or missing references)
			//IL_024c: Unknown result type (might be due to invalid IL or missing references)
			//IL_0251: Unknown result type (might be due to invalid IL or missing references)
			//IL_025d: Unknown result type (might be due to invalid IL or missing references)
			//IL_0269: Unknown result type (might be due to invalid IL or missing references)
			//IL_026b: Unknown result type (might be due to invalid IL or missing references)
			//IL_0270: Unknown result type (might be due to invalid IL or missing references)
			//IL_0275: Unknown result type (might be due to invalid IL or missing references)
			//IL_0284: Unknown result type (might be due to invalid IL or missing references)
			//IL_028f: Unknown result type (might be due to invalid IL or missing references)
			//IL_02a0: Unknown result type (might be due to invalid IL or missing references)
			//IL_02a1: Unknown result type (might be due to invalid IL or missing references)
			//IL_02a6: Unknown result type (might be due to invalid IL or missing references)
			//IL_02b0: Unknown result type (might be due to invalid IL or missing references)
			//IL_02b5: Unknown result type (might be due to invalid IL or missing references)
			//IL_02ba: Unknown result type (might be due to invalid IL or missing references)
			//IL_02c5: Unknown result type (might be due to invalid IL or missing references)
			//IL_02cc: Unknown result type (might be due to invalid IL or missing references)
			//IL_02d8: Unknown result type (might be due to invalid IL or missing references)
			//IL_02de: Unknown result type (might be due to invalid IL or missing references)
			//IL_02e3: Unknown result type (might be due to invalid IL or missing references)
			//IL_02ed: Expected O, but got Unknown
			//IL_0309: Unknown result type (might be due to invalid IL or missing references)
			//IL_030e: Unknown result type (might be due to invalid IL or missing references)
			((BaseState)this).OnEnter();
			duration = leapDuration / (0.75f + 0.25f * ((BaseState)this).attackSpeedStat);
			hasFired = false;
			hasLanded = false;
			animator = ((EntityState)this).GetModelAnimator();
			swordController = ((EntityState)this).GetComponent<PaladinSwordController>();
			((EntityState)this).characterMotor.jumpCount = ((EntityState)this).characterBody.maxJumpCount;
			previousAirControl = ((EntityState)this).characterMotor.airControl;
			((EntityState)this).characterMotor.airControl = BaseLeap.airControl;
			Ray aimRay = ((BaseState)this).GetAimRay();
			Vector3 val = ((Ray)(ref aimRay)).direction;
			if (PaladinPlugin.IsLocalVRPlayer(((EntityState)this).characterBody))
			{
				val = ((Component)Camera.main).transform.forward;
			}
			if (((EntityState)this).isAuthority)
			{
				((EntityState)this).characterBody.isSprinting = true;
				val.y = Mathf.Max(val.y, 2.5f * BaseLeap.minimumY);
				Vector3 val2 = ((Vector3)(ref val)).normalized * (1.5f * BaseLeap.aimVelocity) * ((BaseState)this).moveSpeedStat;
				Vector3 val3 = Vector3.up * 1.9f * BaseLeap.upwardVelocity;
				Vector3 val4 = new Vector3(val.x, 0f, val.z);
				Vector3 val5 = ((Vector3)(ref val4)).normalized * (3f * BaseLeap.forwardVelocity);
				((BaseCharacterController)((EntityState)this).characterMotor).Motor.ForceUnground();
				((EntityState)this).characterMotor.velocity = val2 + val3 + val5;
			}
			((EntityState)this).characterDirection.moveVector = val;
			CharacterBody characterBody = ((EntityState)this).characterBody;
			characterBody.bodyFlags = (BodyFlags)(characterBody.bodyFlags | 1);
			HitBoxGroup hitBoxGroup = null;
			Transform modelTransform = ((EntityState)this).GetModelTransform();
			string hitboxString = "LeapStrike";
			if (Object.op_Implicit((Object)(object)modelTransform))
			{
				hitBoxGroup = Array.Find(((Component)modelTransform).GetComponents<HitBoxGroup>(), (HitBoxGroup element) => element.groupName == hitboxString);
			}
			swordController.airSlamStacks = 1;
			((EntityState)this).PlayAnimation("FullBody, Override", "LeapSlam", "Whirlwind.playbackRate", duration * 1.5f);
			Util.PlaySound("PaladinLunge", ((EntityState)this).gameObject);
			Util.PlaySound("PaladinCloth2", ((EntityState)this).gameObject);
			float num = damageCoefficient;
			attack = new OverlapAttack
			{
				damageType = (DamageType)32,
				attacker = ((EntityState)this).gameObject,
				inflictor = ((EntityState)this).gameObject,
				teamIndex = ((BaseState)this).GetTeam(),
				damage = num * ((BaseState)this).damageStat,
				procCoefficient = 1f,
				hitEffectPrefab = swordController.hitEffect,
				forceVector = -Vector3.up * 6000f,
				pushAwayForce = 500f,
				hitBoxGroup = hitBoxGroup,
				isCrit = ((BaseState)this).RollCrit(),
				impactSound = Assets.swordHitSoundEventL.index
			};
			if (swordController.isBlunt)
			{
				attack.impactSound = Assets.batHitSoundEventL.index;
			}
		}

		public override void OnExit()
		{
			//IL_0020: 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)
			((EntityState)this).OnExit();
			((EntityState)this).PlayAnimation("FullBody, Override", "BufferEmpty");
			CharacterBody characterBody = ((EntityState)this).characterBody;
			characterBody.bodyFlags = (BodyFlags)(characterBody.bodyFlags & -2);
			((EntityState)this).characterMotor.airControl = previousAirControl;
		}

		public void FireAttack()
		{
			//IL_00d1: Unknown result type (might be due to invalid IL or missing references)
			//IL_00d6: 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_0094: Unknown result type (might be due to invalid IL or missing references)
			//IL_0099: 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_00aa: Unknown result type (might be due to invalid IL or missing references)
			//IL_00b4: Unknown result type (might be due to invalid IL or missing references)
			//IL_00b9: Unknown result type (might be due to invalid IL or missing references)
			//IL_00be: Unknown result type (might be due to invalid IL or missing references)
			//IL_010d: Unknown result type (might be due to invalid IL or missing references)
			//IL_0112: Unknown result type (might be due to invalid IL or missing references)
			if (!hasFired)
			{
				hasFired = true;
				swordController.PlaySwingSound();
				if (((EntityState)this).isAuthority)
				{
					((BaseState)this).AddRecoil(-1f * GroundSweep.attackRecoil, -2f * GroundSweep.attackRecoil, -0.5f * GroundSweep.attackRecoil, 0.5f * GroundSweep.attackRecoil);
					EffectManager.SimpleMuzzleFlash(swordController.swingEffect, ((EntityState)this).gameObject, "SwingDown", true);
					CharacterMotor characterMotor = ((EntityState)this).characterMotor;
					characterMotor.velocity *= 0.25f;
					CharacterMotor characterMotor2 = ((EntityState)this).characterMotor;
					characterMotor2.velocity += Vector3.up * dropVelocity;
				}
			}
			if (((EntityState)this).isAuthority)
			{
				Ray aimRay = ((BaseState)this).GetAimRay();
				if (attack.Fire((List<HurtBox>)null) && !inHitPause)
				{
					hitStopCachedState = ((BaseState)this).CreateHitStopCachedState(((EntityState)this).characterMotor, animator, "Whirlwind.playbackRate");
					hitPauseTimer = 4f * GroundLight.hitPauseDuration / ((BaseState)this).attackSpeedStat;
					inHitPause = true;
				}
			}
		}

		public override void FixedUpdate()
		{
			((EntityState)this).FixedUpdate();
			((BaseState)this).StartAimMode(0.5f, false);
			stopwatch += Time.fixedDeltaTime;
			if (stopwatch >= duration)
			{
				FireAttack();
				if (((EntityState)this).isAuthority && ((EntityState)this).inputBank.skill2.down && ((EntityState)this).skillLocator.secondary.stock > 0)
				{
					EntityState nextState = (EntityState)(object)new SpinningSlashAirborneAltUpgradedState();
					((EntityState)this).outer.SetNextState(nextState);
					return;
				}
			}
			if (stopwatch >= duration && ((EntityState)this).isAuthority && ((EntityState)this).characterMotor.isGrounded)
			{
				GroundImpact();
				((EntityState)this).outer.SetNextStateToMain();
			}
		}

		private void FireShockwave()
		{
			//IL_0013: Unknown result type (might be due to invalid IL or missing references)
			//IL_0018: Unknown result type (might be due to invalid IL or missing references)
			//IL_001f: Unknown result type (might be due to invalid IL or missing references)
			//IL_0024: Unknown result type (might be due to invalid IL or missing references)
			//IL_002f: 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)
			//IL_0031: Unknown result type (might be due to invalid IL or missing references)
			Transform val = ((BaseState)this).FindModelChild("SwingCenter");
			Vector3 footPosition = ((EntityState)this).characterBody.footPosition;
			Vector3 forward = ((EntityState)this).characterDirection.forward;
			ProjectileManager.instance.FireProjectile(Projectiles.shockwave, footPosition, Util.QuaternionSafeLookRotation(forward), ((EntityState)this).gameObject, ((EntityState)this).characterBody.damage * 3f, WeaponSlam.waveProjectileForce, ((BaseState)this).RollCrit(), (DamageColorIndex)0, (GameObject)null, -1f);
		}

		private void GroundImpact()
		{
			//IL_0063: 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)
			//IL_006f: 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_0086: Expected O, but got Unknown
			if (!hasLanded)
			{
				hasLanded = true;
				if (Object.op_Implicit((Object)(object)swordController) && swordController.swordActive)
				{
					FireShockwave();
				}
				Util.PlaySound("PaladinGroundImpact", ((EntityState)this).gameObject);
				Util.PlaySound("PaladinLeapSlam", ((EntityState)this).gameObject);
				EffectData val = new EffectData
				{
					origin = ((EntityState)this).characterBody.footPosition,
					scale = 2f
				};
				EffectManager.SpawnEffect(LegacyResourcesAPI.Load<GameObject>("Prefabs/Effects/ImpactEffects/ParentSlamEffect"), val, true);
			}
		}

		public override InterruptPriority GetMinimumInterruptPriority()
		{
			//IL_0002: Unknown result type (might be due to invalid IL or missing references)
			//IL_0005: Unknown result type (might be due to invalid IL or missing references)
			return (InterruptPriority)2;
		}
	}
	public class SpinningSlashEntryUpgradedState : BaseState
	{
		public override void OnEnter()
		{
			((BaseState)this).OnEnter();
			if (((EntityState)this).isAuthority)
			{
				EntityState nextState = (EntityState)(object)new SpinningSlashAirborneUpgradedState();
				if (((EntityState)this).characterMotor.isGrounded)
				{
					nextState = (EntityState)(object)new SpinningSlashGroundedUpgradedState();
				}
				((EntityState)this).outer.SetNextState(nextState);
			}
		}
	}
	public class SpinningSlashGroundedAltUpgradedState : BaseSkillState
	{
		public static float damageCoefficient = 10f;

		public float baseDuration = 0.6f;

		public static float attackRecoil = 3f;

		private float duration;

		private bool hasFired;

		private float hitPauseTimer;

		private OverlapAttack attack;

		private bool inHitPause;

		private float stopwatch;

		private Animator animator;

		private HitStopCachedState hitStopCachedState;

		private PaladinSwordController swordController;

		private Vector3 storedVelocity;

		public override void OnEnter()
		{
			//IL_0144: Unknown result type (might be due to invalid IL or missing references)
			//IL_0149: Unknown result type (might be due to invalid IL or missing references)
			//IL_014c: Unknown result type (might be due to invalid IL or missing references)
			//IL_0151: Unknown result type (might be due to invalid IL or missing references)
			//IL_015d: Unknown result type (might be due to invalid IL or missing references)
			//IL_0169: Unknown result type (might be due to invalid IL or missing references)
			//IL_016b: Unknown result type (might be due to invalid IL or missing references)
			//IL_0170: Unknown result type (might be due to invalid IL or missing references)
			//IL_0175: Unknown result type (might be due to invalid IL or missing references)
			//IL_0187: Unknown result type (might be due to invalid IL or missing references)
			//IL_0192: Unknown result type (might be due to invalid IL or missing references)
			//IL_01a3: Unknown result type (might be due to invalid IL or missing references)
			//IL_01a4: Unknown result type (might be due to invalid IL or missing references)
			//IL_01ae: 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_01c3: Unknown result type (might be due to invalid IL or missing references)
			//IL_01ca: Unknown result type (might be due to invalid IL or missing references)
			//IL_01d6: Unknown result type (might be due to invalid IL or missing references)
			//IL_01dc: Unknown result type (might be due to invalid IL or missing references)
			//IL_01e1: Unknown result type (might be due to invalid IL or missing references)
			//IL_01eb: Expected O, but got Unknown
			//IL_0207: Unknown result type (might be due to invalid IL or missing references)
			//IL_020c: Unknown result type (might be due to invalid IL or missing references)
			((BaseState)this).OnEnter();
			duration = baseDuration / ((BaseState)this).attackSpeedStat;
			hasFired = false;
			animator = ((EntityState)this).GetModelAnimator();
			swordController = ((EntityState)this).GetComponent<PaladinSwordController>();
			((BaseState)this).StartAimMode(0.5f + duration, false);
			((EntityState)this).characterBody.isSprinting = false;
			((EntityState)this).skillLocator.secondary.DeductStock(1);
			if (Object.op_Implicit((Object)(object)swordController))
			{
				swordController.attacking = true;
			}
			HitBoxGroup hitBoxGroup = null;
			Transform modelTransform = ((EntityState)this).GetModelTransform();
			if (NetworkServer.active)
			{
				((EntityState)this).characterBody.AddBuff(Buffs.Slow50);
			}
			string hitboxString = "SpinSlash";
			if (Object.op_Implicit((Object)(object)swordController) && swordController.swordActive)
			{
				hitboxString = "SpinSlashLarge";
			}
			if (Object.op_Implicit((Object)(object)modelTransform))
			{
				hitBoxGroup = Array.Find(((Component)modelTransform).GetComponents<HitBoxGroup>(), (HitBoxGroup element) => element.groupName == hitboxString);
			}
			((EntityState)this).PlayAnimation("FullBody, Override", "GroundSweepContinuous", "Whirlwind.playbackRate", duration * 1.1f);
			Util.PlaySound("PaladinCloth3", ((EntityState)this).gameObject);
			attack = new OverlapAttack
			{
				damageType = (DamageType)32,
				attacker = ((EntityState)this).gameObject,
				inflictor = ((EntityState)this).gameObject,
				teamIndex = ((BaseState)this).GetTeam(),
				damage = damageCoefficient * ((BaseState)this).damageStat,
				procCoefficient = 1f,
				hitEffectPrefab = swordController.hitEffect,
				forceVector = Vector3.up * 1600f,
				pushAwayForce = -1500f,
				hitBoxGroup = hitBoxGroup,
				isCrit = ((BaseState)this).RollCrit(),
				impactSound = Assets.swordHitSoundEventM.index
			};
			if (swordController.isBlunt)
			{
				attack.impactSound = Assets.batHitSoundEventM.index;
			}
		}

		public override void OnExit()
		{
			((EntityState)this).OnExit();
			if (NetworkServer.active)
			{
				((EntityState)this).characterBody.RemoveBuff(Buffs.Slow50);
			}
			if (Object.op_Implicit((Object)(object)swordController))
			{
				swordController.attacking = false;
			}
		}

		public IEnumerator FireAttack()
		{
			if (!hasFired)
			{
				hasFired = true;
				for (int j = 0; j < 2; j++)
				{
					swordController.PlaySwingSound();
					if (((EntityState)this).isAuthority)
					{
						((BaseState)this).AddRecoil(-1f * attackRecoil, -2f * attackRecoil, -0.5f * attackRecoil, 0.5f * attackRecoil);
						if (swordController.swordActive)
						{
							EffectManager.SimpleMuzzleFlash(swordController.empoweredSpinSlashEffect, ((EntityState)this).gameObject, "SwingCenter", true);
						}
						else
						{
							EffectManager.SimpleMuzzleFlash(swordController.spinSlashEffect, ((EntityState)this).gameObject, "SwingCenter", true);
						}
						((BaseState)this).GetAimRay();
						Vector3 forwardDirection = ((EntityState)this).characterDirection.forward;
						if (PaladinPlugin.IsLocalVRPlayer(((EntityState)this).characterBody))
						{
							forwardDirection = ((Component)Camera.main).transform.forward;
							forwardDirection.y = 0f;
							forwardDirection = ((Vector3)(ref forwardDirection)).normalized;
						}
						CharacterMotor characterMotor = ((EntityState)this).characterMotor;
						characterMotor.velocity += forwardDirection * 25f;
						forwardDirection = default(Vector3);
					}
					yield return (object)new WaitForSeconds(duration * 0.3f);
				}
			}
			for (int i = 0; i < 2; i++)
			{
				if (attack.Fire((List<HurtBox>)null) && !inHitPause)
				{
					if (((EntityState)this).characterMotor.velocity != Vector3.zero)
					{
						storedVelocity = ((EntityState)this).characterMotor.velocity;
					}
					hitStopCachedState = ((BaseState)this).CreateHitStopCachedState(((EntityState)this).characterMotor, animator, "Whirlwind.playbackRate");
					hitPauseTimer = 4f * GroundLight.hitPauseDuration / ((BaseState)this).attackSpeedStat;
					inHitPause = true;
				}
				yield return (object)new WaitForSeconds(duration * 0.3f);
			}
		}

		public override void FixedUpdate()
		{
			//IL_0037: Unknown result type (might be due to invalid IL or missing references)
			//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_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)
			//IL_00b8: Unknown result type (might be due to invalid IL or missing references)
			//IL_00bd: Unknown result type (might be due to invalid IL or missing references)
			//IL_011c: 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)
			((EntityState)this).FixedUpdate();
			hitPauseTimer -= Time.fixedDeltaTime;
			if (hitPauseTimer <= 0f && inHitPause)
			{
				((BaseState)this).ConsumeHitStopCachedState(hitStopCachedState, ((EntityState)this).characterMotor, animator);
				inHitPause = false;
				if (storedVelocity != Vector3.zero)
				{
					((EntityState)this).characterMotor.velocity = storedVelocity;
				}
			}
			if (!inHitPause)
			{
				stopwatch += Time.fixedDeltaTime;
			}
			else
			{
				if (Object.op_Implicit((Object)(object)((EntityState)this).characterMotor))
				{
					((EntityState)this).characterMotor.velocity = Vector3.zero;
				}
				if (Object.op_Implicit((Object)(object)animator))
				{
					animat