Decompiled source of Jakaka Skills v2.0.0

JakakaSkills.dll

Decompiled 8 hours ago
using System;
using System.Diagnostics;
using System.IO;
using System.Reflection;
using System.Runtime.CompilerServices;
using System.Runtime.Versioning;
using System.Security;
using System.Security.Permissions;
using BepInEx;
using BepInEx.Logging;
using EntityStates;
using EntityStates.Bandit2.Weapon;
using EntityStates.Commando.CommandoWeapon;
using JakakaSkills.MyEntityStates;
using Microsoft.CodeAnalysis;
using R2API;
using R2API.Utils;
using RoR2;
using RoR2.Projectile;
using RoR2.Skills;
using RoR2.UI;
using UnityEngine;
using UnityEngine.AddressableAssets;

[assembly: CompilationRelaxations(8)]
[assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)]
[assembly: Debuggable(DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints)]
[assembly: TargetFramework(".NETStandard,Version=v2.1", FrameworkDisplayName = ".NET Standard 2.1")]
[assembly: AssemblyCompany("JakakaSkills")]
[assembly: AssemblyConfiguration("Release")]
[assembly: AssemblyFileVersion("1.0.0.0")]
[assembly: AssemblyInformationalVersion("1.0.0+51a44f09434386980ceb5c09df7a0e9882d7906d")]
[assembly: AssemblyProduct("JakakaSkills")]
[assembly: AssemblyTitle("JakakaSkills")]
[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 JakakaSkills
{
	[BepInDependency(/*Could not decode attribute arguments.*/)]
	[NetworkCompatibility(/*Could not decode attribute arguments.*/)]
	[BepInPlugin("com.Mephy.Jakaka_Skills", "Jakaka Skills", "2.0.0")]
	public class Main : BaseUnityPlugin
	{
		public const string PluginGUID = "com.Mephy.Jakaka_Skills";

		public const string PluginName = "Jakaka Skills";

		public const string PluginVersion = "2.0.0";

		private AssetBundle jakakaassets;

		public void Awake()
		{
			//IL_007a: Unknown result type (might be due to invalid IL or missing references)
			LoadAssetBundle();
			AddKeywords();
			AddVendettaSkill();
			AddBlunderbussSkill();
			AddMolotovSkill();
			AddSwitchbackSkill();
			Assembly assembly = typeof(Main).Assembly;
			bool flag = false;
			Type[] types = assembly.GetTypes();
			foreach (Type type in types)
			{
				if (type.Namespace != null && type.Namespace.StartsWith("JakakaSkills.MyEntityStates") && type.IsSubclassOf(typeof(EntityState)) && !type.IsAbstract)
				{
					ContentAddition.AddEntityState(type, ref flag);
				}
			}
		}

		private void LoadAssetBundle()
		{
			string text = Path.Combine(Path.GetDirectoryName(((BaseUnityPlugin)this).Info.Location), "jakakaassets");
			if (!File.Exists(text))
			{
				((BaseUnityPlugin)this).Logger.LogError((object)("Asset bundle not found at path: " + text));
				return;
			}
			jakakaassets = AssetBundle.LoadFromFile(text);
			if ((Object)(object)jakakaassets == (Object)null)
			{
				((BaseUnityPlugin)this).Logger.LogError((object)"Failed to load asset bundle!");
			}
			else
			{
				((BaseUnityPlugin)this).Logger.LogInfo((object)"Asset bundle loaded successfully.");
			}
		}

		public void AddKeywords()
		{
			LanguageAPI.Add("KEYWORD_RELOADABLE", "<style=cKeywordName>Reloadable</style><style=cSub>Cooldown can be manually triggered by pressing <style=cIsDamage>fire</style> and <style=cIsUtility>interact</style> at the same time.</style>");
			LanguageAPI.Add("KEYWORD_VENDETTA_ATK_EFFECT", "<style=cKeywordName><style=cDeath>Vendetta</style></style><style=cSub><style=cIsUtility>Attack speed doesn't apply normally</style>, it instead increases <style=cDeath>Vendetta</style> damage at <style=cIsDamage>50% effectiveness</style>.</style>");
			LanguageAPI.Add("KEYWORD_BLUNDERBUSS_ATK_EFFECT", "<style=cKeywordName><style=cDeath>Blunderbuss</style></style><style=cSub><style=cIsUtility>Attack speed doesn't apply normally</style>, it instead increases <style=cDeath>Blunderbuss</style> projectile count at <style=cIsDamage>100% effectiveness</style>.</style>");
			LanguageAPI.Add("KEYWORD_MOLOTOV_ATK_EFFECT", "<style=cKeywordName><style=cDeath>Molotov</style></style><style=cSub><style=cIsUtility>Attack speed</style> is <style=cIsDamage>67% as effective</style>, and also increases <style=cDeath>Molotov</style> radius at <style=cIsDamage>100% effectiveness</style>.</style>");
			LanguageAPI.Add("KEYWORD_SWITCHBACK_SHOTGUN_ATK_EFFECT", "<style=cKeywordName><style=cDeath>Shotgun</style></style><style=cSub><style=cIsUtility>Attack speed doesn't apply normally</style>, it instead increases <style=cDeath>Shotgun</style> projectile count at <style=cIsDamage>33% effectiveness</style>.</style>");
			LanguageAPI.Add("KEYWORD_SWITCHBACK_AUTO_ATK_EFFECT", "<style=cKeywordName><style=cDeath>Full Auto</style></style><style=cSub><style=cIsUtility>Attack speed</style> applies to <style=cDeath>Full Auto</style> at <style=cIsDamage>100% effectiveness</style>.</style>");
		}

		public void AddVendettaSkill()
		{
			//IL_0005: Unknown result type (might be due to invalid IL or missing references)
			//IL_000a: Unknown result type (might be due to invalid IL or missing references)
			//IL_0042: Unknown result type (might be due to invalid IL or missing references)
			//IL_0047: 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_0161: 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_018b: Expected O, but got Unknown
			//IL_018b: 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)
			GameObject val = Addressables.LoadAssetAsync<GameObject>((object)"RoR2/Base/Bandit2/Bandit2Body.prefab").WaitForCompletion();
			LanguageAPI.Add("REVOLVER_NAME", "Vendetta");
			LanguageAPI.Add("REVOLVER_DESCRIPTION", "<style=cDeath>Vendetta</style>. <style=cIsUtility>Reloadable</style>. Tap to fire a single shot for <style=cIsDamage>450% damage</style>. Hold down to blindly fire every remaining bullet in the gun for <style=cIsDamage>300% damage each</style>.");
			SkillDef val2 = ScriptableObject.CreateInstance<SkillDef>();
			val2.activationState = new SerializableEntityStateType(typeof(Vendetta));
			val2.activationStateMachineName = "Weapon";
			val2.baseMaxStock = 6;
			val2.rechargeStock = 9999;
			val2.baseRechargeInterval = 0.85f;
			val2.dontAllowPastMaxStocks = true;
			val2.isCooldownBlockedUntilManuallyReset = true;
			val2.beginSkillCooldownOnSkillEnd = true;
			val2.resetCooldownTimerOnUse = true;
			val2.canceledFromSprinting = true;
			val2.cancelSprintingOnActivation = true;
			val2.fullRestockOnAssign = true;
			val2.interruptPriority = (InterruptPriority)0;
			val2.isCombatSkill = true;
			val2.mustKeyPress = false;
			val2.requiredStock = 1;
			val2.stockToConsume = 0;
			val2.autoHandleLuminousShot = true;
			val2.icon = jakakaassets.LoadAsset<Sprite>("Vendetta.png");
			val2.skillDescriptionToken = "REVOLVER_DESCRIPTION";
			val2.skillName = "Vendetta";
			val2.skillNameToken = "REVOLVER_NAME";
			val2.keywordTokens = new string[2] { "KEYWORD_VENDETTA_ATK_EFFECT", "KEYWORD_RELOADABLE" };
			ContentAddition.AddSkillDef(val2);
			SkillFamily skillFamily = val.GetComponent<SkillLocator>().primary.skillFamily;
			Array.Resize(ref skillFamily.variants, skillFamily.variants.Length + 1);
			Variant[] variants = skillFamily.variants;
			int num = skillFamily.variants.Length - 1;
			Variant val3 = new Variant
			{
				skillDef = val2,
				unlockableDef = null
			};
			((Variant)(ref val3)).viewableNode = new Node(val2.skillNameToken, false, (Node)null);
			variants[num] = val3;
		}

		private void AddBlunderbussSkill()
		{
			//IL_0005: Unknown result type (might be due to invalid IL or missing references)
			//IL_000a: Unknown result type (might be due to invalid IL or missing references)
			//IL_0042: Unknown result type (might be due to invalid IL or missing references)
			//IL_0047: Unknown result type (might be due to invalid IL or missing references)
			//IL_00a3: Unknown result type (might be due to invalid IL or missing references)
			//IL_0155: 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_017f: Expected O, but got Unknown
			//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)
			GameObject val = Addressables.LoadAssetAsync<GameObject>((object)"RoR2/Base/Bandit2/Bandit2Body.prefab").WaitForCompletion();
			LanguageAPI.Add("SHOTGUN_NAME", "Blunderbuss");
			LanguageAPI.Add("SHOTGUN_DESCRIPTION", "<style=cDeath>Blunderbuss</style>. Fire a powerful blunderbuss that gets more projectiles per stock for <style=cIsDamage>3-7-14-24x65% damage</style>.");
			SkillDef val2 = ScriptableObject.CreateInstance<SkillDef>();
			val2.activationState = new SerializableEntityStateType(typeof(Blunderbuss));
			val2.activationStateMachineName = "Weapon";
			val2.baseMaxStock = 4;
			val2.rechargeStock = 1;
			val2.baseRechargeInterval = 0.5f;
			val2.dontAllowPastMaxStocks = true;
			val2.beginSkillCooldownOnSkillEnd = true;
			val2.resetCooldownTimerOnUse = true;
			val2.canceledFromSprinting = false;
			val2.cancelSprintingOnActivation = true;
			val2.hideStockCount = false;
			val2.fullRestockOnAssign = true;
			val2.interruptPriority = (InterruptPriority)0;
			val2.isCombatSkill = true;
			val2.mustKeyPress = true;
			val2.autoHandleLuminousShot = true;
			val2.requiredStock = 1;
			val2.stockToConsume = 4;
			val2.icon = jakakaassets.LoadAsset<Sprite>("Blunder.png");
			val2.skillDescriptionToken = "SHOTGUN_DESCRIPTION";
			val2.skillName = "Blunderbuss";
			val2.skillNameToken = "SHOTGUN_NAME";
			val2.keywordTokens = new string[1] { "KEYWORD_BLUNDERBUSS_ATK_EFFECT" };
			ContentAddition.AddSkillDef(val2);
			SkillFamily skillFamily = val.GetComponent<SkillLocator>().primary.skillFamily;
			Array.Resize(ref skillFamily.variants, skillFamily.variants.Length + 1);
			Variant[] variants = skillFamily.variants;
			int num = skillFamily.variants.Length - 1;
			Variant val3 = new Variant
			{
				skillDef = val2,
				unlockableDef = null
			};
			((Variant)(ref val3)).viewableNode = new Node(val2.skillNameToken, false, (Node)null);
			variants[num] = val3;
		}

		private void AddMolotovSkill()
		{
			//IL_0005: Unknown result type (might be due to invalid IL or missing references)
			//IL_000a: Unknown result type (might be due to invalid IL or missing references)
			//IL_0042: Unknown result type (might be due to invalid IL or missing references)
			//IL_0047: Unknown result type (might be due to invalid IL or missing references)
			//IL_009c: Unknown result type (might be due to invalid IL or missing references)
			//IL_0156: Unknown result type (might be due to invalid IL or missing references)
			//IL_0176: Unknown result type (might be due to invalid IL or missing references)
			//IL_0180: Expected O, but got Unknown
			//IL_0180: 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)
			GameObject val = Addressables.LoadAssetAsync<GameObject>((object)"RoR2/Base/Bandit2/Bandit2Body.prefab").WaitForCompletion();
			LanguageAPI.Add("MOLOTOV_NAME", "Molotov");
			LanguageAPI.Add("MOLOTOV_DESCRIPTION", "<style=cDeath>Molotov</style>. Throw a molotov that shatters on the ground for <style=cIsDamage>350% damage</style>, creating a pool of fire that <style=cIsDamage>Ignites</style> enemies and deals <style=cIsDamage>175% damage per second</style>.");
			SkillDef val2 = ScriptableObject.CreateInstance<SkillDef>();
			val2.activationState = new SerializableEntityStateType(typeof(Molotov));
			val2.activationStateMachineName = "Weapon";
			val2.baseMaxStock = 3;
			val2.rechargeStock = 1;
			val2.baseRechargeInterval = 6f;
			val2.beginSkillCooldownOnSkillEnd = true;
			val2.resetCooldownTimerOnUse = true;
			val2.canceledFromSprinting = false;
			val2.cancelSprintingOnActivation = false;
			val2.hideStockCount = false;
			val2.fullRestockOnAssign = false;
			val2.interruptPriority = (InterruptPriority)0;
			val2.isCombatSkill = true;
			val2.mustKeyPress = true;
			val2.autoHandleLuminousShot = true;
			val2.requiredStock = 1;
			val2.stockToConsume = 1;
			val2.icon = jakakaassets.LoadAsset<Sprite>("Molotov.png");
			val2.skillDescriptionToken = "MOLOTOV_DESCRIPTION";
			val2.skillName = "Molotov";
			val2.skillNameToken = "MOLOTOV_NAME";
			val2.keywordTokens = new string[2] { "KEYWORD_MOLOTOV_ATK_EFFECT", "KEYWORD_IGNITE" };
			ContentAddition.AddSkillDef(val2);
			SkillFamily skillFamily = val.GetComponent<SkillLocator>().secondary.skillFamily;
			Array.Resize(ref skillFamily.variants, skillFamily.variants.Length + 1);
			Variant[] variants = skillFamily.variants;
			int num = skillFamily.variants.Length - 1;
			Variant val3 = new Variant
			{
				skillDef = val2,
				unlockableDef = null
			};
			((Variant)(ref val3)).viewableNode = new Node(val2.skillNameToken, false, (Node)null);
			variants[num] = val3;
		}

		private void AddSwitchbackSkill()
		{
			//IL_0005: Unknown result type (might be due to invalid IL or missing references)
			//IL_000a: Unknown result type (might be due to invalid IL or missing references)
			//IL_0042: Unknown result type (might be due to invalid IL or missing references)
			//IL_0047: Unknown result type (might be due to invalid IL or missing references)
			//IL_00a8: Unknown result type (might be due to invalid IL or missing references)
			//IL_016a: Unknown result type (might be due to invalid IL or missing references)
			//IL_018a: Unknown result type (might be due to invalid IL or missing references)
			//IL_0194: Expected O, but got Unknown
			//IL_0194: Unknown result type (might be due to invalid IL or missing references)
			//IL_0196: Unknown result type (might be due to invalid IL or missing references)
			GameObject val = Addressables.LoadAssetAsync<GameObject>((object)"RoR2/Base/Commando/CommandoBody.prefab").WaitForCompletion();
			LanguageAPI.Add("SWITCHBACK_NAME", "Switchback");
			LanguageAPI.Add("SWITCHBACK_DESCRIPTION", "<style=cDeath>Shotgun</style>. <style=cDeath>Full Auto</style>. <style=cIsUtility>Reloadable</style>. Tap to fire a shotgun blast that deals <style=cIsDamage>2x6x50% damage</style>. Hold down to rapidly fire at full auto for <style=cIsDamage>65% damage</style> a shot.");
			SkillDef val2 = ScriptableObject.CreateInstance<SkillDef>();
			val2.activationState = new SerializableEntityStateType(typeof(Switchback));
			val2.activationStateMachineName = "Weapon";
			val2.baseMaxStock = 48;
			val2.rechargeStock = 9999;
			val2.baseRechargeInterval = 1.15f;
			val2.isCooldownBlockedUntilManuallyReset = true;
			val2.dontAllowPastMaxStocks = true;
			val2.beginSkillCooldownOnSkillEnd = true;
			val2.resetCooldownTimerOnUse = true;
			val2.canceledFromSprinting = false;
			val2.cancelSprintingOnActivation = true;
			val2.fullRestockOnAssign = true;
			val2.interruptPriority = (InterruptPriority)0;
			val2.isCombatSkill = true;
			val2.mustKeyPress = false;
			val2.requiredStock = 1;
			val2.stockToConsume = 0;
			val2.autoHandleLuminousShot = true;
			val2.icon = jakakaassets.LoadAsset<Sprite>("Switchback.png");
			val2.skillDescriptionToken = "SWITCHBACK_DESCRIPTION";
			val2.skillName = "Switchback";
			val2.skillNameToken = "SWITCHBACK_NAME";
			val2.keywordTokens = new string[3] { "KEYWORD_SWITCHBACK_SHOTGUN_ATK_EFFECT", "KEYWORD_SWITCHBACK_AUTO_ATK_EFFECT", "KEYWORD_RELOADABLE" };
			ContentAddition.AddSkillDef(val2);
			SkillFamily skillFamily = val.GetComponent<SkillLocator>().primary.skillFamily;
			Array.Resize(ref skillFamily.variants, skillFamily.variants.Length + 1);
			Variant[] variants = skillFamily.variants;
			int num = skillFamily.variants.Length - 1;
			Variant val3 = new Variant
			{
				skillDef = val2,
				unlockableDef = null
			};
			((Variant)(ref val3)).viewableNode = new Node(val2.skillNameToken, false, (Node)null);
			variants[num] = val3;
		}
	}
}
namespace JakakaSkills.MyEntityStates
{
	public class Blunderbuss : BaseSkillState
	{
		public float BaseDuration = 0.25f;

		private float Duration;

		private float SpreadMult;

		private float RecoilMult;

		private uint BulletAmount;

		public GameObject HitEffectPrefab = Addressables.LoadAssetAsync<GameObject>((object)"RoR2/Base/Bandit2/HitsparkBandit.prefab").WaitForCompletion();

		public GameObject TracerEffectPrefab = Addressables.LoadAssetAsync<GameObject>((object)"RoR2/Base/Bandit2/TracerBandit2Shotgun.prefab").WaitForCompletion();

		public GameObject MuzzleFlash = Addressables.LoadAssetAsync<GameObject>((object)"RoR2/Base/Bandit2/MuzzleflashBandit2.prefab").WaitForCompletion();

		public override void OnEnter()
		{
			//IL_003f: Unknown result type (might be due to invalid IL or missing references)
			//IL_0044: Unknown result type (might be due to invalid IL or missing references)
			//IL_0057: Unknown result type (might be due to invalid IL or missing references)
			//IL_00bb: Unknown result type (might be due to invalid IL or missing references)
			//IL_00c0: 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_00d8: Unknown result type (might be due to invalid IL or missing references)
			//IL_00db: Unknown result type (might be due to invalid IL or missing references)
			//IL_00e0: Unknown result type (might be due to invalid IL or missing references)
			//IL_00e5: Unknown result type (might be due to invalid IL or missing references)
			//IL_00e8: Unknown result type (might be due to invalid IL or missing references)
			//IL_00f2: Unknown result type (might be due to invalid IL or missing references)
			//IL_00fd: Unknown result type (might be due to invalid IL or missing references)
			//IL_011b: Unknown result type (might be due to invalid IL or missing references)
			//IL_0127: Unknown result type (might be due to invalid IL or missing references)
			//IL_0132: 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_0154: Unknown result type (might be due to invalid IL or missing references)
			//IL_0156: Unknown result type (might be due to invalid IL or missing references)
			//IL_015b: Unknown result type (might be due to invalid IL or missing references)
			//IL_0167: Unknown result type (might be due to invalid IL or missing references)
			//IL_0172: Unknown result type (might be due to invalid IL or missing references)
			//IL_017e: Unknown result type (might be due to invalid IL or missing references)
			//IL_018a: 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_0192: Unknown result type (might be due to invalid IL or missing references)
			//IL_0197: 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_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_01a9: 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)
			((BaseState)this).OnEnter();
			GetStock();
			Duration = BaseDuration / ((BaseState)this).attackSpeedStat;
			((EntityState)this).PlayAnimation("Gesture, Additive", "FireMainWeapon", "FireMainWeapon.playbackRate", 0.65f, 0f);
			Ray aimRay = ((BaseState)this).GetAimRay();
			Util.PlaySound("Play_bandit2_m1_rifle", ((EntityState)this).gameObject);
			((BaseState)this).StartAimMode(aimRay, 2f, false);
			((BaseState)this).AddRecoil(-24f * RecoilMult, -32f * RecoilMult, -12f * RecoilMult, 12f * RecoilMult);
			if (((EntityState)this).isAuthority)
			{
				EffectManager.SimpleMuzzleFlash(MuzzleFlash, ((EntityState)this).gameObject, "MuzzleShotgun", false);
				new BulletAttack
				{
					owner = ((EntityState)this).gameObject,
					weapon = ((EntityState)this).gameObject,
					origin = ((Ray)(ref aimRay)).origin,
					aimVector = ((Ray)(ref aimRay)).direction,
					minSpread = 0f,
					maxSpread = (((EntityState)this).characterBody.spreadBloomAngle + 2.2f) * SpreadMult,
					bulletCount = BulletAmount,
					procCoefficient = 0.15f,
					damage = ((EntityState)this).characterBody.damage * 0.65f,
					force = 32f,
					falloffModel = (FalloffModel)1,
					tracerEffectPrefab = TracerEffectPrefab,
					muzzleName = "MuzzleShotgun",
					hitEffectPrefab = HitEffectPrefab,
					isCrit = ((BaseState)this).RollCrit(),
					HitEffectNormal = false,
					stopperMask = CommonMasks.bullet,
					smartCollision = true,
					damageType = DamageTypeCombo.GenericPrimary,
					maxDistance = 800f
				}.Fire();
			}
		}

		private void GetStock()
		{
			switch (((BaseSkillState)this).activatorSkillSlot.stock)
			{
			case -3:
				SpreadMult = 0.2f;
				RecoilMult = 0.33f;
				BulletAmount = (uint)(((BaseState)this).attackSpeedStat * 3f);
				break;
			case -2:
				SpreadMult = 0.45f;
				RecoilMult = 0.5f;
				BulletAmount = (uint)(((BaseState)this).attackSpeedStat * 7f);
				break;
			case -1:
				SpreadMult = 0.8f;
				RecoilMult = 0.8f;
				BulletAmount = (uint)(((BaseState)this).attackSpeedStat * 14f);
				break;
			default:
				SpreadMult = 1f;
				RecoilMult = 1f;
				BulletAmount = (uint)(((BaseState)this).attackSpeedStat * 24f);
				break;
			}
		}

		public override void OnExit()
		{
			if (((BaseSkillState)this).activatorSkillSlot.stock <= 0)
			{
				((BaseSkillState)this).activatorSkillSlot.stock = 0;
			}
			((EntityState)this).OnExit();
		}

		public override void FixedUpdate()
		{
			((EntityState)this).FixedUpdate();
			if (((EntityState)this).isAuthority && ((EntityState)this).fixedAge >= Duration)
			{
				((EntityState)this).outer.SetNextStateToMain();
			}
		}

		public override InterruptPriority GetMinimumInterruptPriority()
		{
			return (InterruptPriority)1;
		}
	}
	public class Molotov : BaseSkillState
	{
		public float BaseDuration = 0.25f;

		public float Duration;

		public override void OnEnter()
		{
			//IL_0048: Unknown result type (might be due to invalid IL or missing references)
			//IL_004d: Unknown result type (might be due to invalid IL or missing references)
			//IL_004f: Unknown result type (might be due to invalid IL or missing references)
			//IL_0131: Unknown result type (might be due to invalid IL or missing references)
			//IL_0136: Unknown result type (might be due to invalid IL or missing references)
			//IL_0142: Unknown result type (might be due to invalid IL or missing references)
			//IL_014d: Unknown result type (might be due to invalid IL or missing references)
			//IL_0167: Unknown result type (might be due to invalid IL or missing references)
			//IL_016e: Unknown result type (might be due to invalid IL or missing references)
			//IL_0173: Unknown result type (might be due to invalid IL or missing references)
			((BaseState)this).OnEnter();
			GameObject obj = LegacyResourcesAPI.Load<GameObject>("Prefabs/Projectiles/MolotovSingleProjectile");
			GameObject val = LegacyResourcesAPI.Load<GameObject>("Prefabs/Projectiles/MolotovProjectileDotZone");
			GameObject val2 = PrefabAPI.InstantiateClone(obj, "BanditMolotov", true);
			GameObject val3 = PrefabAPI.InstantiateClone(val, "BanditMolotovPool", true);
			Duration = BaseDuration / ((BaseState)this).attackSpeedStat;
			Ray aimRay = ((BaseState)this).GetAimRay();
			((BaseState)this).StartAimMode(aimRay, 2f, false);
			((EntityState)this).PlayAnimation("Gesture, Additive", "SlashBlade", "SlashBlade.playbackRate", 0.5f, 0f);
			Util.PlaySound("bandit_shift_land_01", ((EntityState)this).gameObject);
			val2.GetComponent<ProjectileSimple>().lifetime = 12f;
			ProjectileImpactExplosion component = val2.GetComponent<ProjectileImpactExplosion>();
			((ProjectileExplosion)component).blastDamageCoefficient = 3.5f;
			((ProjectileExplosion)component).blastProcCoefficient = 1f;
			((ProjectileExplosion)component).blastRadius = ((ProjectileExplosion)component).blastRadius * ((BaseState)this).attackSpeedStat;
			((ProjectileExplosion)component).childrenProjectilePrefab = val3;
			((ProjectileExplosion)component).childrenCount = 1;
			ProjectileDotZone component2 = val3.GetComponent<ProjectileDotZone>();
			component2.damageCoefficient = 0.25f;
			component2.overlapProcCoefficient = 0.5f;
			component2.lifetime = 8f;
			component2.fireFrequency = ((BaseState)this).attackSpeedStat * 2f / 3f * 10.5f;
			component2.resetFrequency = -0f;
			val3.GetComponent<ProjectileDamage>().damageType = DamageTypeCombo.op_Implicit((DamageType)128);
			Transform transform = val3.transform;
			transform.localScale *= ((BaseState)this).attackSpeedStat;
			if (((EntityState)this).isAuthority)
			{
				ProjectileManager.instance.FireProjectile(val2, ((Ray)(ref aimRay)).origin, Quaternion.LookRotation(((Ray)(ref aimRay)).direction), ((Component)((EntityState)this).characterBody).gameObject, ((EntityState)this).characterBody.damage, 0f, Util.CheckRoll(((EntityState)this).characterBody.crit, ((EntityState)this).characterBody.master), (DamageColorIndex)0, (GameObject)null, 80f, (DamageTypeCombo?)null);
			}
		}

		public override void OnExit()
		{
			((EntityState)this).OnExit();
		}

		public override void FixedUpdate()
		{
			((EntityState)this).FixedUpdate();
			if (((EntityState)this).fixedAge >= Duration && ((EntityState)this).isAuthority)
			{
				((EntityState)this).outer.SetNextStateToMain();
			}
		}

		public override InterruptPriority GetMinimumInterruptPriority()
		{
			return (InterruptPriority)1;
		}
	}
	public class Switchback : BaseSkillState
	{
		private float Duration = 0.15f;

		private int Shots;

		private float Threshold = 0.185f;

		private float FireInt = 0.0375f;

		private float Timer;

		private bool Magdump;

		private bool AllTheSingleLadies;

		private float FireRate;

		public GameObject ShottyFlash = Addressables.LoadAssetAsync<GameObject>((object)"RoR2/Base/Commando/MuzzleflashFMJ.prefab").WaitForCompletion();

		public GameObject SmgFlash = Addressables.LoadAssetAsync<GameObject>((object)"RoR2/Base/Common/VFX/MuzzleflashBarrage.prefab").WaitForCompletion();

		public GameObject HitEffectPrefab = Addressables.LoadAssetAsync<GameObject>((object)"RoR2/Base/Common/VFX/Hitspark1.prefab").WaitForCompletion();

		public GameObject TracerEffectPrefab = Addressables.LoadAssetAsync<GameObject>((object)"RoR2/Base/Commando/TracerCommandoDefault.prefab").WaitForCompletion();

		public GameObject ShotgunHitSpark = Addressables.LoadAssetAsync<GameObject>((object)"RoR2/Base/Commando/HitsparkCommandoShotgun.prefab").WaitForCompletion();

		public GameObject ShotgunTracerEffectPrefab = Addressables.LoadAssetAsync<GameObject>((object)"RoR2/Base/Commando/TracerCommandoShotgun.prefab").WaitForCompletion();

		public override void OnEnter()
		{
			((BaseState)this).OnEnter();
			FireRate = FireInt / ((BaseState)this).attackSpeedStat;
			((EntityState)this).skillLocator.primary.isCooldownBlocked = true;
		}

		public override void FixedUpdate()
		{
			((EntityState)this).FixedUpdate();
			if (((EntityState)this).inputBank.interact.down)
			{
				((EntityState)this).skillLocator.primary.stock = 0;
			}
			if (!Magdump && !((EntityState)this).inputBank.skill1.down && ((EntityState)this).fixedAge < Threshold && ((BaseSkillState)this).activatorSkillSlot.stock >= 12)
			{
				FireMulti();
			}
			if (((BaseSkillState)this).activatorSkillSlot.stock < 12)
			{
				Threshold = 0f;
			}
			if (!Magdump && ((EntityState)this).fixedAge >= Threshold && ((EntityState)this).inputBank.skill1.down)
			{
				Magdump = true;
				Timer = 0f;
			}
			if (Magdump)
			{
				Timer += Time.fixedDeltaTime;
				if (Timer >= FireRate && ((BaseSkillState)this).activatorSkillSlot.stock > 0)
				{
					Timer = 0f;
					FireSmg();
					((EntityState)this).skillLocator.primary.DeductStock(1);
				}
			}
			if (((BaseSkillState)this).activatorSkillSlot.stock <= 0)
			{
				((EntityState)this).skillLocator.primary.isCooldownBlocked = false;
				((EntityState)this).outer.SetNextState((EntityState)(object)new SwitchbackReload());
			}
			if (((EntityState)this).fixedAge >= Duration && !((EntityState)this).inputBank.skill1.down)
			{
				((EntityState)this).outer.SetNextStateToMain();
			}
		}

		private void FireMulti()
		{
			if (!AllTheSingleLadies)
			{
				AllTheSingleLadies = true;
				if (((EntityState)this).skillLocator.primary.stock > 0)
				{
					((EntityState)this).skillLocator.primary.DeductStock(12);
				}
				FireMultiBullet("MuzzleRight");
				FireMultiBullet("MuzzleLeft");
			}
		}

		private void FireMultiBullet(string ShottyMuzzle)
		{
			//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_0032: 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_00ac: 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_00c4: 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_00d1: Unknown result type (might be due to invalid IL or missing references)
			//IL_00d4: Unknown result type (might be due to invalid IL or missing references)
			//IL_00de: Unknown result type (might be due to invalid IL or missing references)
			//IL_00e9: Unknown result type (might be due to invalid IL or missing references)
			//IL_0100: Unknown result type (might be due to invalid IL or missing references)
			//IL_0119: 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_013b: 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_0148: Unknown result type (might be due to invalid IL or missing references)
			//IL_014d: Unknown result type (might be due to invalid IL or missing references)
			//IL_0159: Unknown result type (might be due to invalid IL or missing references)
			//IL_0160: Unknown result type (might be due to invalid IL or missing references)
			//IL_016c: Unknown result type (might be due to invalid IL or missing references)
			//IL_0178: 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_0180: Unknown result type (might be due to invalid IL or missing references)
			//IL_0185: Unknown result type (might be due to invalid IL or missing references)
			//IL_018a: 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_0192: Unknown result type (might be due to invalid IL or missing references)
			//IL_0197: 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)
			if (((EntityState)this).characterBody.isSprinting)
			{
				((EntityState)this).characterBody.isSprinting = false;
			}
			Util.PlaySound(FirePistol2.firePistolSoundString, ((EntityState)this).gameObject);
			Ray aimRay = ((BaseState)this).GetAimRay();
			((BaseState)this).StartAimMode(aimRay, 2f, false);
			((EntityState)this).PlayAnimation("Gesture Additive, Right", FirePistol2.FirePistolRightStateHash);
			((EntityState)this).PlayAnimation("Gesture Additive, Left", FirePistol2.FirePistolLeftStateHash);
			EffectManager.SimpleMuzzleFlash(ShottyFlash, ((EntityState)this).gameObject, ShottyMuzzle, false);
			Util.PlaySound(FirePistol2.firePistolSoundString, ((EntityState)this).gameObject);
			((BaseState)this).AddRecoil(-7f, -12f, -7f, 9f);
			if (((EntityState)this).isAuthority)
			{
				new BulletAttack
				{
					owner = ((EntityState)this).gameObject,
					weapon = ((EntityState)this).gameObject,
					origin = ((Ray)(ref aimRay)).origin,
					aimVector = ((Ray)(ref aimRay)).direction,
					minSpread = 0f,
					maxSpread = ((EntityState)this).characterBody.spreadBloomAngle + 1.85f,
					bulletCount = (uint)(((BaseState)this).attackSpeedStat / 3f * 18f),
					procCoefficient = 0.275f,
					damage = ((EntityState)this).characterBody.damage * 0.5f,
					force = 16f,
					falloffModel = (FalloffModel)2,
					tracerEffectPrefab = ShotgunTracerEffectPrefab,
					muzzleName = ShottyMuzzle,
					hitEffectPrefab = ShotgunHitSpark,
					isCrit = ((BaseState)this).RollCrit(),
					HitEffectNormal = true,
					stopperMask = CommonMasks.bullet,
					smartCollision = true,
					damageType = DamageTypeCombo.GenericPrimary,
					maxDistance = 250f
				}.Fire();
			}
		}

		private void FireSmg()
		{
			//IL_0028: Unknown result type (might be due to invalid IL or missing references)
			//IL_002d: Unknown result type (might be due to invalid IL or missing references)
			//IL_002f: Unknown result type (might be due to invalid IL or missing references)
			//IL_00bc: 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_00cd: 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)
			//IL_00dc: Unknown result type (might be due to invalid IL or missing references)
			//IL_00e1: 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_00e9: Unknown result type (might be due to invalid IL or missing references)
			//IL_00f3: Unknown result type (might be due to invalid IL or missing references)
			//IL_00fe: Unknown result type (might be due to invalid IL or missing references)
			//IL_0115: 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_0127: Unknown result type (might be due to invalid IL or missing references)
			//IL_013e: 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_014b: 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_015c: 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_016f: 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_0182: Unknown result type (might be due to invalid IL or missing references)
			//IL_0183: 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_0194: Unknown result type (might be due to invalid IL or missing references)
			//IL_0195: 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_019f: Unknown result type (might be due to invalid IL or missing references)
			Shots++;
			if (((EntityState)this).characterBody.isSprinting)
			{
				((EntityState)this).characterBody.isSprinting = false;
			}
			Ray aimRay = ((BaseState)this).GetAimRay();
			((BaseState)this).StartAimMode(aimRay, 2f, false);
			string text;
			if (Shots % 2 == 0)
			{
				text = "MuzzleRight";
				((EntityState)this).PlayAnimation("Gesture Additive, Right", FirePistol2.FirePistolRightStateHash);
			}
			else
			{
				text = "MuzzleLeft";
				((EntityState)this).PlayAnimation("Gesture Additive, Left", FirePistol2.FirePistolLeftStateHash);
			}
			EffectManager.SimpleMuzzleFlash(SmgFlash, ((EntityState)this).gameObject, text, false);
			Util.PlaySound(FireBarrage.fireBarrageSoundString, ((EntityState)this).gameObject);
			((BaseState)this).AddRecoil(-1.25f, -3f, -1.25f, 2f);
			if (((EntityState)this).isAuthority)
			{
				new BulletAttack
				{
					owner = ((EntityState)this).gameObject,
					weapon = ((EntityState)this).gameObject,
					origin = ((Ray)(ref aimRay)).origin,
					aimVector = ((Ray)(ref aimRay)).direction,
					minSpread = 0f,
					maxSpread = ((EntityState)this).characterBody.spreadBloomAngle + 1.2f,
					bulletCount = 1u,
					procCoefficient = 0.5f,
					damage = ((EntityState)this).characterBody.damage * 0.65f,
					force = 4f,
					falloffModel = (FalloffModel)0,
					tracerEffectPrefab = TracerEffectPrefab,
					muzzleName = text,
					hitEffectPrefab = HitEffectPrefab,
					isCrit = ((BaseState)this).RollCrit(),
					HitEffectNormal = true,
					stopperMask = CommonMasks.bullet,
					smartCollision = true,
					damageType = DamageTypeCombo.GenericPrimary,
					maxDistance = 1500f
				}.Fire();
			}
		}

		public override void OnExit()
		{
			((EntityState)this).OnExit();
		}

		public override InterruptPriority GetMinimumInterruptPriority()
		{
			return (InterruptPriority)1;
		}
	}
	public class SwitchbackReload : GenericReload
	{
		private static int ReloadPistolsStateHash = Animator.StringToHash("ReloadPistols");

		private static int ReloadPistolsParamHash = Animator.StringToHash("ReloadPistols.playbackRate");

		private static int ReloadPistolsExitStateHash = Animator.StringToHash("ReloadPistolsExit");

		public override void OnEnter()
		{
			((GenericReload)this).OnEnter();
			Util.PlaySound("Play_bandit2_R_load", ((EntityState)this).gameObject);
			((EntityState)this).PlayAnimation("Gesture, Override", ReloadPistolsStateHash, ReloadPistolsParamHash, 1.15f);
			((EntityState)this).PlayAnimation("Gesture, Additive", ReloadPistolsStateHash, ReloadPistolsParamHash, 1.15f);
			((Component)((BaseState)this).FindModelChild("GunMeshL")).gameObject.SetActive(false);
			((Component)((BaseState)this).FindModelChild("GunMeshR")).gameObject.SetActive(false);
		}

		public override void OnExit()
		{
			((Component)((BaseState)this).FindModelChild("ReloadFXL")).gameObject.SetActive(false);
			((Component)((BaseState)this).FindModelChild("ReloadFXR")).gameObject.SetActive(false);
			((Component)((BaseState)this).FindModelChild("GunMeshL")).gameObject.SetActive(true);
			((Component)((BaseState)this).FindModelChild("GunMeshR")).gameObject.SetActive(true);
			((EntityState)this).PlayAnimation("Gesture, Override", ReloadPistolsExitStateHash);
			((EntityState)this).PlayAnimation("Gesture, Additive", ReloadPistolsExitStateHash);
			((GenericReload)this).OnExit();
		}
	}
	public class Vendetta : BaseSkillState
	{
		private float Duration = 0.45f;

		private Animator Animator;

		private int BodySideWeaponLayerIndex;

		private float Threshold = 0.8f;

		private float FireInt = 0.05f;

		private float Timer;

		private bool Magdump;

		private bool AllTheSingleLadies;

		public GameObject MuzzleFlash = Addressables.LoadAssetAsync<GameObject>((object)"RoR2/Base/Bandit2/MuzzleflashBandit2.prefab").WaitForCompletion();

		public GameObject CrosshairOverridePrefab = Addressables.LoadAssetAsync<GameObject>((object)"RoR2/Base/Bandit2/Bandit2CrosshairPrepRevolverFire.prefab").WaitForCompletion();

		public GameObject HitEffectPrefab = Addressables.LoadAssetAsync<GameObject>((object)"RoR2/Base/Bandit2/HitsparkBandit2Pistol.prefab").WaitForCompletion();

		public GameObject TracerEffectPrefab = Addressables.LoadAssetAsync<GameObject>((object)"RoR2/Base/Bandit2/TracerBanditPistol.prefab").WaitForCompletion();

		public override void OnEnter()
		{
			((BaseState)this).OnEnter();
			((EntityState)this).skillLocator.primary.isCooldownBlocked = true;
			Animator = ((EntityState)this).GetModelAnimator();
			BodySideWeaponLayerIndex = Animator.GetLayerIndex("Body, SideWeapon");
			Animator.SetLayerWeight(BodySideWeaponLayerIndex, 1f);
			CrosshairUtils.RequestOverrideForBody(((EntityState)this).characterBody, CrosshairOverridePrefab, (OverridePriority)1);
		}

		public override void FixedUpdate()
		{
			((EntityState)this).FixedUpdate();
			if (((EntityState)this).inputBank.interact.down)
			{
				((EntityState)this).skillLocator.primary.stock = 0;
			}
			if (!Magdump && !((EntityState)this).inputBank.skill1.down && ((EntityState)this).fixedAge < Threshold)
			{
				FireNormalShot();
			}
			if (!Magdump && ((EntityState)this).fixedAge >= Threshold && ((EntityState)this).inputBank.skill1.down)
			{
				Magdump = true;
				Timer = 0f;
			}
			if (!Magdump && ((EntityState)this).fixedAge == 0.15f && ((EntityState)this).skillLocator.primary.stock > 0)
			{
				((EntityState)this).PlayAnimation("Gesture, Additive", "MainToSide", "MainToSide.playbackRate", 0.65f, 0f);
				Util.PlaySound("Play_bandit2_R_load", ((EntityState)this).gameObject);
			}
			if (Magdump)
			{
				if (((EntityState)this).skillLocator.primary.stock <= 0)
				{
					((EntityState)this).PlayAnimation("Gesture, Additive", "MainToSide", "MainToSide.playbackRate", 0.85f, 0f);
					Util.PlaySound("Play_bandit2_R_load", ((EntityState)this).gameObject);
					((EntityState)this).skillLocator.primary.isCooldownBlocked = false;
					((EntityState)this).outer.SetNextState((EntityState)(object)new VendettaExit());
				}
				Timer += Time.fixedDeltaTime;
				if (Timer >= FireInt && ((EntityState)this).skillLocator.primary.stock > 0)
				{
					Timer = 0f;
					FireDumpShot();
					GenericSkill primary = ((EntityState)this).skillLocator.primary;
					int stock = primary.stock;
					primary.stock = stock - 1;
				}
			}
			if (((EntityState)this).skillLocator.primary.stock <= 0)
			{
				((EntityState)this).PlayAnimation("Gesture, Additive", "MainToSide", "MainToSide.playbackRate", 0.85f, 0f);
				Util.PlaySound("Play_bandit2_R_load", ((EntityState)this).gameObject);
				((EntityState)this).skillLocator.primary.isCooldownBlocked = false;
				((EntityState)this).outer.SetNextState((EntityState)(object)new VendettaExit());
			}
			if (((EntityState)this).fixedAge >= Duration && !((EntityState)this).inputBank.skill1.down)
			{
				((EntityState)this).outer.SetNextState((EntityState)(object)new VendettaExit());
			}
		}

		private void FireNormalShot()
		{
			if (!AllTheSingleLadies)
			{
				AllTheSingleLadies = true;
				if (((EntityState)this).skillLocator.primary.stock > 0)
				{
					GenericSkill primary = ((EntityState)this).skillLocator.primary;
					int stock = primary.stock;
					primary.stock = stock - 1;
				}
				FireBulletSingle();
			}
		}

		private void FireDumpShot()
		{
			DumpBullet();
		}

		private void DumpBullet()
		{
			//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_0033: 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_00d1: Unknown result type (might be due to invalid IL or missing references)
			//IL_00dd: Unknown result type (might be due to invalid IL or missing references)
			//IL_00e9: 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_00f1: Unknown result type (might be due to invalid IL or missing references)
			//IL_00f6: 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_0103: Unknown result type (might be due to invalid IL or missing references)
			//IL_010e: Unknown result type (might be due to invalid IL or missing references)
			//IL_0125: Unknown result type (might be due to invalid IL or missing references)
			//IL_012c: Unknown result type (might be due to invalid IL or missing references)
			//IL_0137: Unknown result type (might be due to invalid IL or missing references)
			//IL_015b: 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_0168: 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_0179: Unknown result type (might be due to invalid IL or missing references)
			//IL_0184: 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_019c: 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_01a9: 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_01b5: Unknown result type (might be due to invalid IL or missing references)
			//IL_01b6: Unknown result type (might be due to invalid IL or missing references)
			//IL_01bb: Unknown result type (might be due to invalid IL or missing references)
			//IL_01c0: Unknown result type (might be due to invalid IL or missing references)
			if (((EntityState)this).isAuthority)
			{
				((Component)((BaseState)this).FindModelChild("SpinningPistolFX")).gameObject.SetActive(false);
				Ray aimRay = ((BaseState)this).GetAimRay();
				Animator = ((EntityState)this).GetModelAnimator();
				((BaseState)this).StartAimMode(aimRay, 2f, false);
				BodySideWeaponLayerIndex = Animator.GetLayerIndex("Body, SideWeapon");
				Animator.SetLayerWeight(BodySideWeaponLayerIndex, 1f);
				((EntityState)this).PlayAnimation("Gesture, Additive", "FireSideWeapon", "FireSideWeapon.playbackRate", 1f, 0f);
				Util.PlaySound("Play_bandit2_R_fire", ((EntityState)this).gameObject);
				((BaseState)this).AddRecoil(-2f, -6f, -2f, 3f);
				EffectManager.SimpleMuzzleFlash(MuzzleFlash, ((EntityState)this).gameObject, "MuzzlePistol", false);
				new BulletAttack
				{
					owner = ((EntityState)this).gameObject,
					weapon = ((EntityState)this).gameObject,
					origin = ((Ray)(ref aimRay)).origin,
					aimVector = ((Ray)(ref aimRay)).direction,
					minSpread = 0f,
					maxSpread = ((EntityState)this).characterBody.spreadBloomAngle * 1.85f,
					bulletCount = 1u,
					procCoefficient = 0.65f,
					damage = ((EntityState)this).characterBody.damage * (((BaseState)this).attackSpeedStat / 2f * 6f),
					force = 4f,
					falloffModel = (FalloffModel)1,
					tracerEffectPrefab = TracerEffectPrefab,
					muzzleName = "MuzzlePistol",
					hitEffectPrefab = HitEffectPrefab,
					isCrit = ((BaseState)this).RollCrit(),
					HitEffectNormal = false,
					stopperMask = CommonMasks.bullet,
					smartCollision = true,
					damageType = DamageTypeCombo.GenericPrimary,
					maxDistance = 450f
				}.Fire();
			}
		}

		private void FireBulletSingle()
		{
			//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_0033: 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_00d1: Unknown result type (might be due to invalid IL or missing references)
			//IL_00dd: Unknown result type (might be due to invalid IL or missing references)
			//IL_00e9: 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_00f1: Unknown result type (might be due to invalid IL or missing references)
			//IL_00f6: 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_0103: Unknown result type (might be due to invalid IL or missing references)
			//IL_010e: 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)
			//IL_0126: Unknown result type (might be due to invalid IL or missing references)
			//IL_0131: 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_0160: Unknown result type (might be due to invalid IL or missing references)
			//IL_0162: Unknown result type (might be due to invalid IL or missing references)
			//IL_0167: Unknown result type (might be due to invalid IL or missing references)
			//IL_0173: Unknown result type (might be due to invalid IL or missing references)
			//IL_017e: Unknown result type (might be due to invalid IL or missing references)
			//IL_018a: Unknown result type (might be due to invalid IL or missing references)
			//IL_0196: Unknown result type (might be due to invalid IL or missing references)
			//IL_019d: Unknown result type (might be due to invalid IL or missing references)
			//IL_019e: 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_01a8: 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_01b0: Unknown result type (might be due to invalid IL or missing references)
			//IL_01b5: Unknown result type (might be due to invalid IL or missing references)
			//IL_01ba: Unknown result type (might be due to invalid IL or missing references)
			if (((EntityState)this).isAuthority)
			{
				((Component)((BaseState)this).FindModelChild("SpinningPistolFX")).gameObject.SetActive(false);
				Ray aimRay = ((BaseState)this).GetAimRay();
				Animator = ((EntityState)this).GetModelAnimator();
				((BaseState)this).StartAimMode(aimRay, 2f, false);
				BodySideWeaponLayerIndex = Animator.GetLayerIndex("Body, SideWeapon");
				Animator.SetLayerWeight(BodySideWeaponLayerIndex, 1f);
				((EntityState)this).PlayAnimation("Gesture, Additive", "FireSideWeapon", "FireSideWeapon.playbackRate", 1f, 0f);
				Util.PlaySound("Play_bandit2_R_fire", ((EntityState)this).gameObject);
				((BaseState)this).AddRecoil(-2f, -6f, -2f, 3f);
				EffectManager.SimpleMuzzleFlash(MuzzleFlash, ((EntityState)this).gameObject, "MuzzlePistol", false);
				new BulletAttack
				{
					owner = ((EntityState)this).gameObject,
					weapon = ((EntityState)this).gameObject,
					origin = ((Ray)(ref aimRay)).origin,
					aimVector = ((Ray)(ref aimRay)).direction,
					minSpread = 0f,
					maxSpread = ((EntityState)this).characterBody.spreadBloomAngle,
					bulletCount = 1u,
					procCoefficient = 1.5f,
					damage = ((EntityState)this).characterBody.damage * (((BaseState)this).attackSpeedStat / 2f * 9f),
					force = 4f,
					falloffModel = (FalloffModel)0,
					tracerEffectPrefab = TracerEffectPrefab,
					muzzleName = "MuzzlePistol",
					hitEffectPrefab = HitEffectPrefab,
					isCrit = ((BaseState)this).RollCrit(),
					HitEffectNormal = false,
					stopperMask = CommonMasks.bullet,
					smartCollision = true,
					damageType = DamageTypeCombo.GenericPrimary,
					maxDistance = 3000f
				}.Fire();
			}
		}

		public override void OnExit()
		{
			if ((Object)(object)Animator != (Object)null)
			{
				Animator.SetLayerWeight(BodySideWeaponLayerIndex, 0f);
			}
			((EntityState)this).OnExit();
		}

		public override InterruptPriority GetMinimumInterruptPriority()
		{
			return (InterruptPriority)1;
		}
	}
	public class VendettaExit : BaseSidearmState
	{
		public override void OnEnter()
		{
			((BaseSidearmState)this).OnEnter();
		}

		public override void FixedUpdate()
		{
			((BaseSidearmState)this).FixedUpdate();
		}

		public override InterruptPriority GetMinimumInterruptPriority()
		{
			return (InterruptPriority)0;
		}
	}
}
namespace ExamplePlugin
{
	internal static class Log
	{
		private static ManualLogSource _logSource;

		internal static void Init(ManualLogSource logSource)
		{
			_logSource = logSource;
		}

		internal static void Debug(object data)
		{
			_logSource.LogDebug(data);
		}

		internal static void Error(object data)
		{
			_logSource.LogError(data);
		}

		internal static void Fatal(object data)
		{
			_logSource.LogFatal(data);
		}

		internal static void Info(object data)
		{
			_logSource.LogInfo(data);
		}

		internal static void Message(object data)
		{
			_logSource.LogMessage(data);
		}

		internal static void Warning(object data)
		{
			_logSource.LogWarning(data);
		}
	}
}