Decompiled source of Arsonist Mod v2.1.8
ArsonistMod.dll
Decompiled a week ago
The result has been truncated due to the large size, download it to view full contents!
using System; using System.Collections; using System.Collections.Generic; using System.Diagnostics; using System.IO; using System.Linq; using System.Reflection; using System.Runtime.CompilerServices; using System.Runtime.Versioning; using System.Security; using System.Security.Permissions; using ArsonistMod.Content.Controllers; using ArsonistMod.Modules; using ArsonistMod.Modules.Achievements; using ArsonistMod.Modules.Characters; using ArsonistMod.Modules.Networking; using ArsonistMod.Modules.ProjectileControllers; using ArsonistMod.Modules.Survivors; using ArsonistMod.SkillStates; using ArsonistMod.SkillStates.Arsonist.Secondary; using ArsonistMod.SkillStates.BaseStates; using ArsonistMod.SkillStates.EmoteStates; using ArsonistMod.SkillStates.ZeroPointBlast; using BepInEx; using BepInEx.Bootstrap; using BepInEx.Configuration; using BepInEx.Logging; using EmotesAPI; using EntityStates; using EntityStates.Commando.CommandoWeapon; using EntityStates.LemurianMonster; using EntityStates.Mage.Weapon; using EntityStates.Missions.BrotherEncounter; using EntityStates.VoidRaidCrab; using HG; using HG.BlendableTypes; using Inferno; using Moonstorm.Starstorm2; using On.EntityStates.Missions.BrotherEncounter; using On.EntityStates.VoidRaidCrab; using On.RoR2; using R2API; using R2API.Networking; using R2API.Networking.Interfaces; using R2API.Utils; using RiskOfOptions; using RiskOfOptions.OptionConfigs; using RiskOfOptions.Options; using RoR2; using RoR2.Achievements; using RoR2.Audio; using RoR2.CharacterAI; using RoR2.ContentManagement; using RoR2.Projectile; using RoR2.Skills; using RoR2.UI; using TMPro; using UnityEngine; using UnityEngine.AddressableAssets; using UnityEngine.Networking; using UnityEngine.Rendering; using UnityEngine.UI; [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("ArsonistMod")] [assembly: AssemblyConfiguration("Debug")] [assembly: AssemblyFileVersion("1.0.0.0")] [assembly: AssemblyInformationalVersion("1.0.0+ed248ae7eddbc1c6419b7c8dcb12f3e7200a1f3c")] [assembly: AssemblyProduct("ArsonistMod")] [assembly: AssemblyTitle("ArsonistMod")] [assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)] [assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)] [assembly: AssemblyVersion("1.0.0.0")] [module: UnverifiableCode] [module: UnverifiableCode] namespace ArsonistMod { [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [NetworkCompatibility(/*Could not decode attribute arguments.*/)] [BepInPlugin("com.PopcornFactory.Arsonist", "Arsonist", "2.1.8")] public class ArsonistPlugin : BaseUnityPlugin { public const string MODUID = "com.PopcornFactory.Arsonist"; public const string MODNAME = "Arsonist"; public const string MODVERSION = "2.1.8"; public const string DEVELOPER_PREFIX = "POPCORN"; public static bool starstormAvailable; public static bool infernoAvailable; public static ArsonistPlugin instance; public static AkGameObj akGameObject; private void Awake() { instance = this; Log.Init(((BaseUnityPlugin)this).Logger); Config.ReadConfig(); Config.OnChangeHooks(); Assets.Initialize(); if (Chainloader.PluginInfos.ContainsKey("com.rune580.riskofoptions")) { Config.SetupRiskOfOptions(); } if (Chainloader.PluginInfos.ContainsKey("com.TeamMoonstorm.Starstorm2")) { starstormAvailable = true; } if (Chainloader.PluginInfos.ContainsKey("HIFU.Inferno")) { infernoAvailable = true; } States.RegisterStates(); Buffs.RegisterBuffs(); Projectiles.RegisterProjectiles(); Tokens.AddTokens(); ItemDisplays.PopulateDisplays(); Damage.SetupModdedDamage(); new Arsonist().Initialize(); NetworkRequestSetup(); new ContentPacks().Initialize(); Hook(); } private void NetworkRequestSetup() { NetworkingAPI.RegisterMessageType<BurnNetworkRequest>(); NetworkingAPI.RegisterMessageType<PlaySoundNetworkRequest>(); NetworkingAPI.RegisterMessageType<TakeDamageNetworkRequest>(); NetworkingAPI.RegisterMessageType<AttachFlareNetworkRequest>(); NetworkingAPI.RegisterMessageType<FlamethrowerDotNetworkRequest>(); NetworkingAPI.RegisterMessageType<ToggleMasochismEffectNetworkRequest>(); NetworkingAPI.RegisterMessageType<KillAllEffectsNetworkRequest>(); NetworkingAPI.RegisterMessageType<PlayCleanseBlastNetworkRequest>(); } private void Hook() { //IL_0008: Unknown result type (might be due to invalid IL or missing references) //IL_0012: Expected O, but got Unknown //IL_001a: Unknown result type (might be due to invalid IL or missing references) //IL_0024: Expected O, but got Unknown //IL_002c: Unknown result type (might be due to invalid IL or missing references) //IL_0036: Expected O, but got Unknown //IL_003e: Unknown result type (might be due to invalid IL or missing references) //IL_0048: Expected O, but got Unknown //IL_0050: Unknown result type (might be due to invalid IL or missing references) //IL_005a: Expected O, but got Unknown //IL_0062: Unknown result type (might be due to invalid IL or missing references) //IL_006c: Expected O, but got Unknown //IL_0089: Unknown result type (might be due to invalid IL or missing references) //IL_0093: Expected O, but got Unknown CharacterBody.RecalculateStats += new hook_RecalculateStats(CharacterBody_RecalculateStats); HealthComponent.TakeDamage += new hook_TakeDamage(HealthComponent_TakeDamage); CharacterModel.UpdateOverlays += new hook_UpdateOverlays(CharacterModel_UpdateOverlays); CharacterModel.Start += new hook_Start(CharacterModel_Start); CharacterBody.OnDeathStart += new hook_OnDeathStart(CharacterBody_OnDeathStart); DotController.InflictDot_refInflictDotInfo += new hook_InflictDot_refInflictDotInfo(DotController_InflictDot_refInflictDotInfo); if (Chainloader.PluginInfos.ContainsKey("com.weliveinasociety.CustomEmotesAPI")) { SurvivorCatalog.Init += new hook_Init(SurvivorCatalog_Init); } } private void DotController_InflictDot_refInflictDotInfo(orig_InflictDot_refInflictDotInfo orig, ref InflictDotInfo inflictDotInfo) { //IL_0044: Unknown result type (might be due to invalid IL or missing references) //IL_004a: Invalid comparison between Unknown and I4 //IL_004d: Unknown result type (might be due to invalid IL or missing references) //IL_0053: Invalid comparison between Unknown and I4 //IL_0056: Unknown result type (might be due to invalid IL or missing references) //IL_005c: Invalid comparison between Unknown and I4 if (Object.op_Implicit((Object)(object)inflictDotInfo.victimObject)) { CharacterBody component = inflictDotInfo.victimObject.GetComponent<CharacterBody>(); if (Object.op_Implicit((Object)(object)component) && component.baseNameToken == "POPCORN_ARSONIST_BODY_NAME" && ((int)inflictDotInfo.dotIndex == 1 || (int)inflictDotInfo.dotIndex == 2 || (int)inflictDotInfo.dotIndex == 7)) { inflictDotInfo.totalDamage *= StaticValues.igniteDamageReduction; } } orig.Invoke(ref inflictDotInfo); } private void CharacterBody_OnDeathStart(orig_OnDeathStart orig, CharacterBody self) { //IL_001f: 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_0049: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self); if (self.baseNameToken == "POPCORN_ARSONIST_BODY_NAME") { NetMessageExtensions.Send((INetMessage)(object)new PlaySoundNetworkRequest(((NetworkBehaviour)self).netId, 2176930590u), (NetworkDestination)1); NetMessageExtensions.Send((INetMessage)(object)new KillAllEffectsNetworkRequest(((NetworkBehaviour)self).netId, killMaso: true), (NetworkDestination)1); NetMessageExtensions.Send((INetMessage)(object)new ToggleMasochismEffectNetworkRequest(((NetworkBehaviour)self).netId, toggleOn: false), (NetworkDestination)1); } } private void SurvivorCatalog_Init(orig_Init orig) { orig.Invoke(); foreach (SurvivorDef allSurvivorDef in SurvivorCatalog.allSurvivorDefs) { if (((Object)allSurvivorDef.bodyPrefab).name == "ArsonistBody") { CustomEmotesAPI.ImportArmature(allSurvivorDef.bodyPrefab, Assets.mainAssetBundle.LoadAsset<GameObject>("HumanoidArsonist"), 0, true); } } } private void CharacterBody_RecalculateStats(orig_RecalculateStats orig, CharacterBody self) { if (!Object.op_Implicit((Object)(object)self.healthComponent)) { return; } orig.Invoke(self); if (Object.op_Implicit((Object)(object)self) && self.baseNameToken == "POPCORN_ARSONIST_BODY_NAME") { EnergySystem component = ((Component)self).gameObject.GetComponent<EnergySystem>(); if (self.HasBuff(Buffs.blueBuff)) { self.damage *= StaticValues.blueDamageMultiplier; } if (self.HasBuff(Buffs.lowerBuff)) { self.damage *= StaticValues.lowerDamageMultiplier; } if (self.HasBuff(Buffs.cleanseSpeedBoost)) { self.moveSpeed += 5f; } if (self.HasBuff(Buffs.masochismBuff)) { self.attackSpeed *= StaticValues.igniteAttackSpeedMultiplier; } if (self.HasBuff(Buffs.overheatDebuff) && !self.HasBuff(Buffs.masochismDeactivatedDebuff) && !self.HasBuff(Buffs.masochismDeactivatedNonDebuff)) { self.attackSpeed *= StaticValues.overheatAttackSpeedDebuff; } if (self.skillLocator.secondary.cooldownRemaining > 0f && component.hasOverheatedSecondary) { GenericSkill secondary = self.skillLocator.secondary; secondary.cooldownScale *= 1f; } else if (self.skillLocator.secondary.cooldownRemaining > 0f && !component.hasOverheatedSecondary) { GenericSkill secondary2 = self.skillLocator.secondary; secondary2.cooldownScale *= StaticValues.secondaryCooldownMultiplier; } if (self.skillLocator.utility.cooldownRemaining > 0f && component.hasOverheatedUtility) { GenericSkill utility = self.skillLocator.utility; utility.cooldownScale *= 1f; } else if (self.skillLocator.utility.cooldownRemaining > 0f && !component.hasOverheatedUtility) { GenericSkill utility2 = self.skillLocator.utility; utility2.cooldownScale *= StaticValues.utilityCooldownMultiplier; } if (self.skillLocator.special.cooldownRemaining > 0f && component.hasOverheatedSpecial) { GenericSkill special = self.skillLocator.special; special.cooldownScale *= 1f; } else if (self.skillLocator.special.cooldownRemaining > 0f && !component.hasOverheatedSpecial) { GenericSkill special2 = self.skillLocator.special; special2.cooldownScale *= StaticValues.specialCooldownMultiplier; } } } private void HealthComponent_TakeDamage(orig_TakeDamage orig, HealthComponent self, DamageInfo damageInfo) { //IL_0023: Unknown result type (might be due to invalid IL or missing references) //IL_0029: Invalid comparison between Unknown and I4 //IL_002c: Unknown result type (might be due to invalid IL or missing references) //IL_0032: Invalid comparison between Unknown and I4 //IL_0042: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Invalid comparison between Unknown and I4 //IL_0050: Unknown result type (might be due to invalid IL or missing references) //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003b: Invalid comparison between Unknown and I4 //IL_008d: 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_0077: Unknown result type (might be due to invalid IL or missing references) //IL_00ca: Unknown result type (might be due to invalid IL or missing references) //IL_00a4: 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_0109: Unknown result type (might be due to invalid IL or missing references) //IL_0110: 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_00f1: 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_012a: Unknown result type (might be due to invalid IL or missing references) //IL_012f: Unknown result type (might be due to invalid IL or missing references) //IL_0134: Unknown result type (might be due to invalid IL or missing references) //IL_01a2: Unknown result type (might be due to invalid IL or missing references) //IL_01a7: Unknown result type (might be due to invalid IL or missing references) //IL_01e7: Unknown result type (might be due to invalid IL or missing references) //IL_0232: Unknown result type (might be due to invalid IL or missing references) if (Object.op_Implicit((Object)(object)self) && Object.op_Implicit((Object)(object)self.body)) { bool flag = (int)damageInfo.dotIndex == 1 || (int)damageInfo.dotIndex == 2 || (int)damageInfo.dotIndex == 7; bool flag2 = (int)damageInfo.damageType == 128; if (DamageAPI.HasModdedDamageType(damageInfo, Damage.arsonistStickyDamageType)) { NetMessageExtensions.Send((INetMessage)(object)new AttachFlareNetworkRequest(((NetworkBehaviour)self.body).netId, ((NetworkBehaviour)damageInfo.attacker.GetComponent<CharacterBody>()).netId, AttachFlareNetworkRequest.FlareType.STRONG), (NetworkDestination)1); } else if (DamageAPI.HasModdedDamageType(damageInfo, Damage.arsonistWeakStickyDamageType)) { NetMessageExtensions.Send((INetMessage)(object)new AttachFlareNetworkRequest(((NetworkBehaviour)self.body).netId, ((NetworkBehaviour)damageInfo.attacker.GetComponent<CharacterBody>()).netId, AttachFlareNetworkRequest.FlareType.WEAK), (NetworkDestination)1); } else if (DamageAPI.HasModdedDamageType(damageInfo, Damage.arsonistChildExplosionDamageType)) { NetMessageExtensions.Send((INetMessage)(object)new AttachFlareNetworkRequest(((NetworkBehaviour)self.body).netId, ((NetworkBehaviour)damageInfo.attacker.GetComponent<CharacterBody>()).netId, AttachFlareNetworkRequest.FlareType.CHILD_STRONG), (NetworkDestination)1); } DamageType val = (DamageType)2097153; DamageType val2 = (DamageType)2359296; if (self.body.HasBuff(Buffs.fallDamageReductionBuff) && (damageInfo.damageType == val || damageInfo.damageType == val2) && damageInfo.damage >= 20f) { damageInfo.damage = 20f; } if (self.body.baseNameToken == "POPCORN_ARSONIST_BODY_NAME" && damageInfo.damage > self.fullHealth * Config.passiveHealthPercentageTriggerIgnite.Value && damageInfo.damageType != val && !self.body.HasBuff(Buffs.BearVoidReady) && !flag) { damageInfo.damage *= StaticValues.igniteDamageReduction; InflictDotInfo val3 = default(InflictDotInfo); val3.totalDamage = damageInfo.damage; val3.attackerObject = ((Component)self.body).gameObject; val3.victimObject = ((Component)self.body).gameObject; val3.duration = StaticValues.passiveIgniteLength; val3.dotIndex = (DotIndex)1; DotController.InflictDot(ref val3); } } orig.Invoke(self, damageInfo); } private void CharacterModel_UpdateOverlays(orig_UpdateOverlays orig, CharacterModel self) { orig.Invoke(self); if (Object.op_Implicit((Object)(object)self) && Object.op_Implicit((Object)(object)self.body)) { ArsonistController component = ((Component)self.body).GetComponent<ArsonistController>(); if (Object.op_Implicit((Object)(object)component)) { overlayFunction(component.overheatingMaterial, Object.op_Implicit((Object)(object)component) && self.body.hasEffectiveAuthority, self); } } } private void CharacterModel_Start(orig_Start orig, CharacterModel self) { orig.Invoke(self); if (((Object)((Component)self).gameObject).name.Contains("ArsonistDisplay")) { ArsonistDisplayController component = ((Component)self).gameObject.GetComponent<ArsonistDisplayController>(); if (!Object.op_Implicit((Object)(object)component)) { component = ((Component)self).gameObject.AddComponent<ArsonistDisplayController>(); } } } private void Inventory_GiveItem_ItemIndex_int(orig_GiveItem_ItemIndex_int orig, Inventory self, ItemIndex itemIndex, int count) { //IL_0003: Unknown result type (might be due to invalid IL or missing references) //IL_006d: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self, itemIndex, count); if (!NetworkServer.active || !Object.op_Implicit((Object)(object)self) || !Object.op_Implicit((Object)(object)((Component)self).GetComponent<CharacterMaster>())) { return; } CharacterBody body = ((Component)self).GetComponent<CharacterMaster>().GetBody(); if (Object.op_Implicit((Object)(object)body) && body.baseNameToken == "POPCORN_ARSONIST_BODY_NAME") { switch (ItemCatalog.GetItemDef(itemIndex).nameToken) { case "ITEM_EXPLODEONDEATH_NAME": break; case "ITEM_STRENGTHENBURN_NAME": break; case "ITEM_ICERING_NAME": break; case "ITEM_FIRERING_NAME": break; case "ITEM_EXPLODEONDEATHVOID_NAME": break; } } } private void Inventory_SetEquipmentIndexForSlot(orig_SetEquipmentIndexForSlot orig, Inventory self, EquipmentIndex newEquipmentIndex, uint slot) { //IL_0003: Unknown result type (might be due to invalid IL or missing references) //IL_0066: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self, newEquipmentIndex, slot); if (!NetworkServer.active || !Object.op_Implicit((Object)(object)self) || !Object.op_Implicit((Object)(object)((Component)self).GetComponent<CharacterMaster>())) { return; } CharacterBody body = ((Component)self).gameObject.GetComponent<CharacterMaster>().GetBody(); if (Object.op_Implicit((Object)(object)body) && body.baseNameToken == "POPCORN_ARSONIST_BODY_NAME") { string nameToken = EquipmentCatalog.GetEquipmentDef(newEquipmentIndex).nameToken; if (!(nameToken == "EQUIPMENT_BURNNEARBY_NAME")) { } } } private void BrotherEncounter_BossDeath_OnEnter(orig_OnEnter orig, BossDeath self) { orig.Invoke(self); foreach (NetworkUser instances in NetworkUser.instancesList) { if (Object.op_Implicit((Object)(object)instances.master) && Object.op_Implicit((Object)(object)instances.master.GetBody())) { string baseNameToken = instances.master.GetBody().baseNameToken; if (!(baseNameToken == "POPCORN_ARSONIST_BODY_NAME")) { } } } } private void BrotherEncounter_Phase1_OnEnter(orig_OnEnter orig, Phase1 self) { orig.Invoke(self); foreach (NetworkUser instances in NetworkUser.instancesList) { if (Object.op_Implicit((Object)(object)instances.master) && Object.op_Implicit((Object)(object)instances.master.GetBody())) { string baseNameToken = instances.master.GetBody().baseNameToken; if (!(baseNameToken == "POPCORN_ARSONIST_BODY_NAME")) { } } } } private void VoidRaidCrab_DeathState_OnEnter(orig_OnEnter orig, DeathState self) { orig.Invoke(self); if (!NetworkServer.active) { return; } foreach (NetworkUser instances in NetworkUser.instancesList) { if (Object.op_Implicit((Object)(object)instances.master) && Object.op_Implicit((Object)(object)instances.master.GetBody())) { string baseNameToken = instances.master.GetBody().baseNameToken; if (!(baseNameToken == "POPCORN_ARSONIST_BODY_NAME")) { } } } } private void ScriptedCombatEncounter_BeginEncounter(orig_BeginEncounter orig, ScriptedCombatEncounter self) { orig.Invoke(self); if (!NetworkServer.active) { return; } foreach (NetworkUser instances in NetworkUser.instancesList) { if (Object.op_Implicit((Object)(object)instances.master) && Object.op_Implicit((Object)(object)instances.master.GetBody())) { string baseNameToken = instances.master.GetBody().baseNameToken; if (!(baseNameToken == "POPCORN_ARSONIST_BODY_NAME")) { } } } } private void IdleState_OnInteractionBegin(orig_OnInteractionBegin orig, BaseState self, Interactor activator) { orig.Invoke(self, activator); if (!NetworkServer.active) { return; } foreach (NetworkUser instances in NetworkUser.instancesList) { if (Object.op_Implicit((Object)(object)instances.master) && Object.op_Implicit((Object)(object)instances.master.GetBody())) { string baseNameToken = instances.master.GetBody().baseNameToken; if (!(baseNameToken == "POPCORN_ARSONIST_BODY_NAME")) { } } } } private void overlayFunction(Material overlayMaterial, bool condition, CharacterModel model) { if (model.activeOverlayCount < CharacterModel.maxOverlays && condition) { Material[] currentOverlays = model.currentOverlays; int activeOverlayCount = model.activeOverlayCount; model.activeOverlayCount = activeOverlayCount + 1; currentOverlays[activeOverlayCount] = overlayMaterial; } } } internal static class Log { internal 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); } } } namespace ArsonistMod.SkillStates { public class Cleanse : BaseSkillState { public ArsonistController arsonistController; public EnergySystem energySystem; public float baseDuration = 1f; public float duration; public bool isStrong; public override void OnEnter() { //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0102: 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_016c: Unknown result type (might be due to invalid IL or missing references) //IL_0171: Unknown result type (might be due to invalid IL or missing references) //IL_017d: 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_0193: 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_01ad: Unknown result type (might be due to invalid IL or missing references) //IL_01b8: Expected O, but got Unknown //IL_01c4: Unknown result type (might be due to invalid IL or missing references) //IL_0271: 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) ((BaseState)this).OnEnter(); energySystem = ((Component)((EntityState)this).characterBody).gameObject.GetComponent<EnergySystem>(); arsonistController = ((Component)((EntityState)this).characterBody).gameObject.GetComponent<ArsonistController>(); Ray aimRay = ((BaseState)this).GetAimRay(); duration = baseDuration; isStrong = false; ((EntityState)this).characterBody.SetAimTimer(duration); if (NetworkServer.active) { Util.CleanseBody(((EntityState)this).characterBody, true, false, false, true, true, false); } ((EntityState)this).PlayCrossfade("Gesture, Override", "Cleanse", "Attack.playbackRate", duration, 0.1f); if (energySystem.currentOverheat < energySystem.maxOverheat && ((EntityState)this).isAuthority) { energySystem.LowerHeat(energySystem.maxOverheat * StaticValues.cleanseHeatReductionMultiplier); energySystem.hasOverheatedUtility = false; ApplyBurn(); if (((EntityState)this).characterBody.HasBuff(Buffs.OnFire.buffIndex)) { isStrong = true; } NetMessageExtensions.Send((INetMessage)(object)new PlayCleanseBlastNetworkRequest(((NetworkBehaviour)((EntityState)this).characterBody).netId, strong: true), (NetworkDestination)1); if (!((EntityState)this).characterBody.characterMotor.isGrounded) { ((BaseState)this).SmallHop(((EntityState)this).characterBody.characterMotor, 3f); } EffectManager.SpawnEffect(Assets.explosionPrefab, new EffectData { origin = ((EntityState)this).characterBody.transform.position, scale = StaticValues.cleanseBlastRadius, rotation = new Quaternion(0f, 0f, 0f, 0f) }, false); NetworkingHelpers.ApplyBuff(((EntityState)this).characterBody, Buffs.cleanseSpeedBoost.buffIndex, 1, duration * 2.5f); } else if (energySystem.currentOverheat >= energySystem.maxOverheat && ((EntityState)this).isAuthority) { if (!((EntityState)this).characterBody.characterMotor.isGrounded) { ((BaseState)this).SmallHop(((EntityState)this).characterBody.characterMotor, 3f); } NetMessageExtensions.Send((INetMessage)(object)new PlayCleanseBlastNetworkRequest(((NetworkBehaviour)((EntityState)this).characterBody).netId, strong: false), (NetworkDestination)1); energySystem.isAcceleratedCooling = true; } if (((EntityState)this).isAuthority) { NetMessageExtensions.Send((INetMessage)(object)new PlaySoundNetworkRequest(((NetworkBehaviour)((EntityState)this).characterBody).netId, 1924783034u), (NetworkDestination)1); } } public void ApplyBurn() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0007: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Unknown result type (might be due to invalid IL or missing references) //IL_000d: Unknown result type (might be due to invalid IL or missing references) //IL_000f: Unknown result type (might be due to invalid IL or missing references) //IL_0014: Unknown result type (might be due to invalid IL or missing references) //IL_0019: Unknown result type (might be due to invalid IL or missing references) //IL_001e: 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_0037: 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_0043: Unknown result type (might be due to invalid IL or missing references) //IL_0048: Unknown result type (might be due to invalid IL or missing references) //IL_0053: Unknown result type (might be due to invalid IL or missing references) //IL_0060: Expected O, but got Unknown //IL_00d6: 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) Ray aimRay = ((BaseState)this).GetAimRay(); BullseyeSearch val = new BullseyeSearch { teamMaskFilter = TeamMask.GetEnemyTeams(((BaseState)this).GetTeam()), filterByLoS = false, searchOrigin = ((EntityState)this).characterBody.footPosition, searchDirection = Random.onUnitSphere, sortMode = (SortMode)1, maxDistanceFilter = StaticValues.cleanseBlastRadius, maxAngleFilter = 360f }; val.RefreshCandidates(); val.FilterOutGameObject(((EntityState)this).gameObject); List<HurtBox> list = val.GetResults().ToList(); foreach (HurtBox item in list) { if (Object.op_Implicit((Object)(object)item) && Object.op_Implicit((Object)(object)item.healthComponent) && Object.op_Implicit((Object)(object)item.healthComponent.body)) { NetMessageExtensions.Send((INetMessage)(object)new BurnNetworkRequest(((NetworkBehaviour)((EntityState)this).characterBody.master).netId, ((NetworkBehaviour)item.healthComponent.body.master).netId), (NetworkDestination)1); } } } public override void OnExit() { ((EntityState)this).OnExit(); ((EntityState)this).PlayAnimation("Gesture, Override", "BufferEmpty"); if (!isStrong) { } } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); if (((EntityState)this).fixedAge >= duration && ((EntityState)this).isAuthority) { ((EntityState)this).outer.SetNextStateToMain(); } } 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)6; } } public class FireSpray : BaseSkillState { public EnergySystem energySystem; public float baseDuration = 0.5f; public float duration; public static GameObject effectPrefab; private string muzzleString = "GunMuzzle"; private Transform muzzlePos; private Animator animator; private float damageCoefficient = StaticValues.firesprayWeakDamageCoefficient; private float altDamageCoefficient = StaticValues.altFiresprayWeakDamageCoefficient; private float strongdamageCoefficient = StaticValues.firesprayStrongDamageCoefficient; private float altStrongDamageCoefficient = StaticValues.altFiresprayStrongDamageCoefficient; public static float spreadBloomValue = 10f; private float force = 400f; private float strongforce = 1000f; private float speedOverride = 100f; private float strongspeedOverride = 100f; private GameObject chargeVfxInstance; private ArsonistPassive passive; private bool isBlue; public float Energy = StaticValues.firesprayEnergyCost; private float energyCost; private float energyflatCost; public override void OnEnter() { //IL_0053: Unknown result type (might be due to invalid IL or missing references) //IL_0058: Unknown result type (might be due to invalid IL or missing references) //IL_0190: Unknown result type (might be due to invalid IL or missing references) //IL_01de: Unknown result type (might be due to invalid IL or missing references) ((BaseState)this).OnEnter(); energySystem = ((Component)((EntityState)this).characterBody).gameObject.GetComponent<EnergySystem>(); passive = ((Component)((EntityState)this).characterBody).gameObject.GetComponent<ArsonistPassive>(); isBlue = passive.isBlueGauge(); ((EntityState)this).characterBody.isSprinting = false; Ray aimRay = ((BaseState)this).GetAimRay(); duration = baseDuration / ((BaseState)this).attackSpeedStat; ((EntityState)this).characterBody.SetAimTimer(duration); animator = ((EntityState)this).GetModelAnimator(); animator.SetBool("attacking", true); ((EntityState)this).GetModelAnimator().SetFloat("Attack.playbackRate", ((BaseState)this).attackSpeedStat); ((EntityState)this).PlayCrossfade("Gesture, Override", "FireSpray", "Attack.playbackRate", duration, 0.1f); ChildLocator modelChildLocator = ((EntityState)this).GetModelChildLocator(); muzzlePos = modelChildLocator.FindChild(muzzleString); energyflatCost = Energy; if (energyflatCost < 0f) { energyflatCost = 1f; } energyCost = energySystem.costmultiplierOverheat * energyflatCost; if (energyCost < 0f) { energyCost = 1f; } if (energySystem.currentOverheat < energySystem.maxOverheat && ((EntityState)this).isAuthority) { FireBolt(); energySystem.AddHeat(energyCost); NetMessageExtensions.Send((INetMessage)(object)new PlaySoundNetworkRequest(((NetworkBehaviour)((EntityState)this).characterBody).netId, 470984906u), (NetworkDestination)1); } else if (energySystem.currentOverheat >= energySystem.maxOverheat && ((EntityState)this).isAuthority) { FireBall(); NetMessageExtensions.Send((INetMessage)(object)new PlaySoundNetworkRequest(((NetworkBehaviour)((EntityState)this).characterBody).netId, 2300744954u), (NetworkDestination)1); } ((EntityState)this).characterBody.AddSpreadBloom(spreadBloomValue); } public void FireBall() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0007: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_0021: Unknown result type (might be due to invalid IL or missing references) //IL_0026: 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_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) Ray aimRay = ((BaseState)this).GetAimRay(); float num = (isBlue ? altDamageCoefficient : damageCoefficient); Vector3 displacedOrigin = GetDisplacedOrigin(aimRay); if (((EntityState)this).isAuthority) { ProjectileManager.instance.FireProjectile(Projectiles.lemurianFireBall, displacedOrigin, Util.QuaternionSafeLookRotation(((Ray)(ref aimRay)).direction), ((EntityState)this).gameObject, ((BaseState)this).damageStat * num, force, Util.CheckRoll(((BaseState)this).critStat, ((EntityState)this).characterBody.master), (DamageColorIndex)0, (GameObject)null, speedOverride); } } public void FireBolt() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0007: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_0021: Unknown result type (might be due to invalid IL or missing references) //IL_0026: 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_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) Ray aimRay = ((BaseState)this).GetAimRay(); float num = (isBlue ? altStrongDamageCoefficient : strongdamageCoefficient); Vector3 displacedOrigin = GetDisplacedOrigin(aimRay); if (((EntityState)this).isAuthority) { ProjectileManager.instance.FireProjectile(Projectiles.artificerFirebolt, displacedOrigin, Util.QuaternionSafeLookRotation(((Ray)(ref aimRay)).direction), ((EntityState)this).gameObject, ((BaseState)this).damageStat * num, strongforce, Util.CheckRoll(((BaseState)this).critStat, ((EntityState)this).characterBody.master), (DamageColorIndex)0, (GameObject)null, strongspeedOverride); } } public Vector3 GetDisplacedOrigin(Ray aimRay) { //IL_003a: 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_004a: Unknown result type (might be due to invalid IL or missing references) //IL_004f: Unknown result type (might be due to invalid IL or missing references) //IL_0054: Unknown result type (might be due to invalid IL or missing references) //IL_0017: 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_0027: 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_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005c: Unknown result type (might be due to invalid IL or missing references) float num = 2.5f; float num2 = 1.25f; Vector3 direction; Vector3 result; if (!CheckLookingDown()) { Vector3 origin = ((Ray)(ref aimRay)).origin; direction = ((Ray)(ref aimRay)).direction; result = origin + num2 * ((Vector3)(ref direction)).normalized; } else { Vector3 origin2 = ((Ray)(ref aimRay)).origin; direction = ((Ray)(ref aimRay)).direction; result = origin2 + num * ((Vector3)(ref direction)).normalized; } return result; } public override void OnExit() { ((EntityState)this).OnExit(); animator.SetBool("attacking", false); ((EntityState)this).PlayAnimation("Gesture, Override", "BufferEmpty"); if (Object.op_Implicit((Object)(object)chargeVfxInstance)) { EntityState.Destroy((Object)(object)chargeVfxInstance); } } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); if (((EntityState)this).fixedAge >= duration && ((EntityState)this).isAuthority && ((BaseSkillState)this).IsKeyDownAuthority()) { ((EntityState)this).outer.SetNextState((EntityState)(object)new FireSpray()); } else if (((EntityState)this).fixedAge >= duration && ((EntityState)this).isAuthority) { ((EntityState)this).outer.SetNextStateToMain(); } } private bool CheckLookingDown() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0007: 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_000f: Unknown result type (might be due to invalid IL or missing references) Ray aimRay = ((BaseState)this).GetAimRay(); if (Vector3.Dot(((Ray)(ref aimRay)).direction, Vector3.down) > 0.6f) { return true; } return false; } 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; } } internal class Flamethrower : BaseSkillState { public int tickRate; public int baseTickRate = StaticValues.flamethrowerBaseTickRate; public float weakCoefficient = StaticValues.flamethrowerWeakDamageCoefficient; public float strongCoefficient = StaticValues.flamethrowerStrongDamageCoefficient; public float altWeakCoefficient = StaticValues.altFlamethrowerWeakDamageCoefficient; public float altStrongCoefficient = StaticValues.altFlamethrowerStrongDamageCoefficient; internal BulletAttack bulletAttack; public float flamethrowerRange = StaticValues.flamethrowerRange; public float procCoefficient = StaticValues.flamethrowerProcCoefficient; public float radius = StaticValues.flamethowerRadius; public static float spreadBloomValue = 10f; private string muzzleString = "GunMuzzle"; private float baseDuration = 0.5f; private float duration; private float interval; private float stopwatch = 0f; private EnergySystem energySystem; private ArsonistPassive passive; private ArsonistController controller; private bool isBlue; private float energyFlatCost; public float Energy = StaticValues.flamethrowerEnergyCost; private float energyCost; public override void OnEnter() { //IL_0137: Unknown result type (might be due to invalid IL or missing references) //IL_013c: Unknown result type (might be due to invalid IL or missing references) //IL_0143: 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_0158: 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_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_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_0178: 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_0189: Unknown result type (might be due to invalid IL or missing references) //IL_018e: 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_019e: 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_01b4: 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) //IL_01cc: Unknown result type (might be due to invalid IL or missing references) //IL_01d8: Unknown result type (might be due to invalid IL or missing references) //IL_01df: Unknown result type (might be due to invalid IL or missing references) //IL_01e5: Unknown result type (might be due to invalid IL or missing references) //IL_01eb: 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_0203: Unknown result type (might be due to invalid IL or missing references) //IL_020a: 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_0221: 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_0237: Unknown result type (might be due to invalid IL or missing references) //IL_0239: 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_0246: Unknown result type (might be due to invalid IL or missing references) //IL_0250: Expected O, but got Unknown //IL_0255: Expected O, but got Unknown //IL_034c: Unknown result type (might be due to invalid IL or missing references) ((BaseState)this).OnEnter(); energySystem = ((Component)((EntityState)this).characterBody).gameObject.GetComponent<EnergySystem>(); passive = ((Component)((EntityState)this).characterBody).gameObject.GetComponent<ArsonistPassive>(); controller = ((Component)((EntityState)this).characterBody).gameObject.GetComponent<ArsonistController>(); isBlue = passive.isBlueGauge(); ((EntityState)this).characterBody.isSprinting = false; energyFlatCost = Energy; if (energyFlatCost < 0f) { energyFlatCost = 1f; } energyCost = energySystem.costmultiplierOverheat * energyFlatCost; if (energyCost < 0f) { energyCost = 1f; } duration = baseDuration / ((BaseState)this).attackSpeedStat; if (duration < 0.1f) { duration = 0.1f; } tickRate = (int)((float)baseTickRate * ((BaseState)this).attackSpeedStat); interval = duration / (float)tickRate; ((EntityState)this).characterBody.SetAimTimer(duration * 2f); bulletAttack = new BulletAttack { bulletCount = 1u, damage = strongCoefficient * ((BaseState)this).damageStat, damageColorIndex = (DamageColorIndex)0, damageType = (DamageType)0, falloffModel = (FalloffModel)0, maxDistance = flamethrowerRange, force = 0f, hitMask = ((LayerIndex)(ref LayerIndex.entityPrecise)).mask, hitEffectPrefab = Flamethrower.impactEffectPrefab, minSpread = 1f, maxSpread = 4f, isCrit = ((BaseState)this).RollCrit(), owner = ((EntityState)this).gameObject, muzzleName = muzzleString, smartCollision = true, procChainMask = default(ProcChainMask), procCoefficient = procCoefficient, radius = radius, sniper = false, stopperMask = ((LayerIndex)(ref LayerIndex.noCollision)).mask, weapon = null, spreadPitchScale = 0f, spreadYawScale = 0f, queryTriggerInteraction = (QueryTriggerInteraction)0, hitCallback = new HitCallback(flamethrowerFlameChanceHitCallback) }; if (energySystem.ifOverheatMaxed) { controller.weakFlamethrower.Play(); } else { controller.flamethrower.Play(); if (Object.op_Implicit((Object)(object)controller.flamethrowerHeatHaze) && Config.enableNonAggressiveHeatHaze.Value != controller.flamethrowerHeatHaze.isPlaying) { if (Config.enableNonAggressiveHeatHaze.Value) { controller.flamethrowerHeatHaze.Play(); } else { controller.flamethrowerHeatHaze.Stop(); } } } if (Object.op_Implicit((Object)(object)controller) && !controller.playingFlamethrower) { controller.playingFlamethrower = true; if (((EntityState)this).isAuthority) { NetMessageExtensions.Send((INetMessage)(object)new PlaySoundNetworkRequest(((NetworkBehaviour)((EntityState)this).characterBody).netId, 934132236u), (NetworkDestination)1); controller.flamethrowerPlayingID = AkSoundEngine.PostEvent(587096102u, ((Component)((EntityState)this).characterBody).gameObject); } } if (Object.op_Implicit((Object)(object)energySystem) && ((EntityState)this).isAuthority) { energySystem.ifOverheatRegenAllowed = false; energySystem.regenPreventionDuration = 0.2f; energySystem.regenPreventionStopwatch = 0f; } } public override void OnExit() { ((EntityState)this).OnExit(); if (Object.op_Implicit((Object)(object)controller.flamethrower)) { controller.flamethrower.Stop(); } if (Object.op_Implicit((Object)(object)controller.weakFlamethrower)) { controller.weakFlamethrower.Stop(); } } public override void FixedUpdate() { //IL_00d7: 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_00e5: 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_00fd: Unknown result type (might be due to invalid IL or missing references) ((EntityState)this).FixedUpdate(); stopwatch += Time.fixedDeltaTime; if (stopwatch >= interval && ((EntityState)this).isAuthority) { float num = strongCoefficient; float maxDistance = flamethrowerRange; if (energySystem.currentOverheat < energySystem.maxOverheat && ((EntityState)this).isAuthority) { num = (isBlue ? altStrongCoefficient : strongCoefficient); } else if (energySystem.currentOverheat >= energySystem.maxOverheat && ((EntityState)this).isAuthority) { num = (isBlue ? altWeakCoefficient : weakCoefficient); maxDistance = flamethrowerRange * 0.66f; } Ray aimRay = ((BaseState)this).GetAimRay(); bulletAttack.aimVector = ((Ray)(ref aimRay)).direction; bulletAttack.origin = ((Ray)(ref aimRay)).origin; bulletAttack.damage = num * ((BaseState)this).damageStat; bulletAttack.maxDistance = maxDistance; bulletAttack.Fire(); ((EntityState)this).characterBody.AddSpreadBloom(spreadBloomValue); stopwatch = 0f; } if (((EntityState)this).fixedAge <= duration && ((EntityState)this).isAuthority && Object.op_Implicit((Object)(object)energySystem)) { energySystem.AddHeat(energyCost * Time.fixedDeltaTime); energySystem.ifOverheatRegenAllowed = false; energySystem.regenPreventionDuration = 0.1f; energySystem.regenPreventionStopwatch = 0f; } if (((EntityState)this).fixedAge >= duration && ((EntityState)this).isAuthority) { if (((EntityState)this).inputBank.skill1.down) { ((EntityState)this).outer.SetState((EntityState)(object)new Flamethrower()); return; } controller.flamethrower.Stop(); controller.weakFlamethrower.Stop(); ((EntityState)this).outer.SetNextStateToMain(); } } public bool flamethrowerFlameChanceHitCallback(BulletAttack bulletRef, ref BulletHit hitInfo) { //IL_00c0: Unknown result type (might be due to invalid IL or missing references) //IL_00c6: Invalid comparison between Unknown and I4 //IL_00fe: 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) BulletAttack.defaultHitCallback.Invoke(bulletRef, ref hitInfo); if (Object.op_Implicit((Object)(object)hitInfo.hitHurtBox)) { float num = hitInfo.distance / StaticValues.flamethrowerRange; float num2 = -1f * Mathf.Pow(num, 0.8f) + 1.2f; num2 = Mathf.Clamp(num2, 0f, 1f); float num3 = Random.Range(1f, 100f); float num4 = ((EntityState)this).characterBody.master.luck; if (num4 < 1f) { num4 = 1f; } if (num3 * num4 * num2 >= StaticValues.flamethrowerFireChance && (int)hitInfo.hitHurtBox.healthComponent.body.teamComponent.teamIndex != 1) { if (Object.op_Implicit((Object)(object)hitInfo.hitHurtBox.healthComponent.body.master)) { NetMessageExtensions.Send((INetMessage)(object)new FlamethrowerDotNetworkRequest(((NetworkBehaviour)((EntityState)this).characterBody.master).netId, ((NetworkBehaviour)hitInfo.hitHurtBox.healthComponent.body.master).netId, 5f), (NetworkDestination)1); } return true; } return true; } return false; } 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 Flare : BaseSkillState { public EnergySystem energySystem; private Ray aimRay; public float baseDuration = 1f; public float duration; public float fireTime; public float recoil = 1f; private bool hasFired; private bool isStrong; private Animator animator; private string muzzleString = "FlareMuzzle"; private float energyCost; private float energyflatCost; private float speedOverride = StaticValues.flareSpeedCoefficient; private BulletAttack bulletAttack; private BlastAttack blastAttack; public override void OnEnter() { //IL_0027: 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_0129: Unknown result type (might be due to invalid IL or missing references) //IL_0177: Unknown result type (might be due to invalid IL or missing references) //IL_022b: Unknown result type (might be due to invalid IL or missing references) //IL_0242: Unknown result type (might be due to invalid IL or missing references) //IL_020a: Unknown result type (might be due to invalid IL or missing references) ((BaseState)this).OnEnter(); hasFired = false; energySystem = ((Component)((EntityState)this).characterBody).gameObject.GetComponent<EnergySystem>(); aimRay = ((BaseState)this).GetAimRay(); duration = baseDuration / ((BaseState)this).attackSpeedStat; fireTime = duration * 0.35f; ((EntityState)this).characterBody.SetAimTimer(duration); animator = ((EntityState)this).GetModelAnimator(); animator.SetBool("attacking", true); ((EntityState)this).GetModelAnimator().SetFloat("Attack.playbackRate", ((BaseState)this).attackSpeedStat); ((EntityState)this).PlayCrossfade("Gesture, Override", "Flare", "Attack.playbackRate", duration, 0.1f); ChildLocator modelChildLocator = ((EntityState)this).GetModelChildLocator(); Transform val = modelChildLocator.FindChild(muzzleString); if (energySystem.currentOverheat < energySystem.maxOverheat && ((EntityState)this).isAuthority) { energySystem.LowerHeat(energySystem.currentOverheat * StaticValues.flareHeatReductionMultiplier); energySystem.hasOverheatedSecondary = false; NetMessageExtensions.Send((INetMessage)(object)new PlaySoundNetworkRequest(((NetworkBehaviour)((EntityState)this).characterBody).netId, 3747272580u), (NetworkDestination)1); isStrong = true; } else if (energySystem.currentOverheat >= energySystem.maxOverheat && ((EntityState)this).isAuthority) { NetMessageExtensions.Send((INetMessage)(object)new PlaySoundNetworkRequest(((NetworkBehaviour)((EntityState)this).characterBody).netId, 1608533803u), (NetworkDestination)1); isStrong = false; } if (((EntityState)this).isAuthority && Config.shouldHaveVoice.Value) { float num = Random.Range(1, 101); if ((float)Config.flareVoicelineChance.Value >= num && Config.flareVoicelineChance.Value != 0) { uint soundNum = ((((EntityState)this).characterBody.skinIndex == ArsonistMod.Modules.Survivors.Arsonist.FirebugSkinIndex) ? 2058064724u : 2767633755u); NetMessageExtensions.Send((INetMessage)(object)new PlaySoundNetworkRequest(((NetworkBehaviour)((EntityState)this).characterBody).netId, soundNum), (NetworkDestination)1); } } ModdedDamageTypeHolderComponent val2 = Projectiles.strongFlare.AddComponent<ModdedDamageTypeHolderComponent>(); val2.Add(Damage.arsonistStickyDamageType); ModdedDamageTypeHolderComponent val3 = Projectiles.weakFlare.AddComponent<ModdedDamageTypeHolderComponent>(); val3.Add(Damage.arsonistWeakStickyDamageType); } public override void OnExit() { ((EntityState)this).OnExit(); animator.SetBool("attacking", false); ((EntityState)this).PlayAnimation("Gesture, Override", "BufferEmpty"); } public void StrongFlare() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0007: 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_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) Ray val = ((BaseState)this).GetAimRay(); if (((EntityState)this).isAuthority) { ((EntityState)this).characterBody.AddSpreadBloom(1f); ((BaseState)this).AddRecoil(-1f * recoil, -2f * recoil, -0.5f * recoil, 0.5f * recoil); ProjectileManager.instance.FireProjectile(Projectiles.strongFlare, ((Ray)(ref val)).origin, Util.QuaternionSafeLookRotation(((Ray)(ref val)).direction), ((EntityState)this).gameObject, ((BaseState)this).damageStat, 0f, Util.CheckRoll(((BaseState)this).critStat, ((EntityState)this).characterBody.master), (DamageColorIndex)13, (GameObject)null, speedOverride); } } public void WeakFlare() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0007: 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_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) Ray val = ((BaseState)this).GetAimRay(); if (((EntityState)this).isAuthority) { ((EntityState)this).characterBody.AddSpreadBloom(1f); ((BaseState)this).AddRecoil(-1f * recoil, -2f * recoil, -0.5f * recoil, 0.5f * recoil); ProjectileManager.instance.FireProjectile(Projectiles.weakFlare, ((Ray)(ref val)).origin, Util.QuaternionSafeLookRotation(((Ray)(ref val)).direction), ((EntityState)this).gameObject, ((BaseState)this).damageStat, 0f, Util.CheckRoll(((BaseState)this).critStat, ((EntityState)this).characterBody.master), (DamageColorIndex)13, (GameObject)null, speedOverride); } } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); if (!hasFired && ((EntityState)this).fixedAge > fireTime && ((EntityState)this).isAuthority) { hasFired = true; if (isStrong) { StrongFlare(); } else if (!isStrong) { WeakFlare(); } } if (((EntityState)this).fixedAge >= duration && ((EntityState)this).isAuthority) { ((EntityState)this).outer.SetNextStateToMain(); } } 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)3; } } internal class Masochism : BaseSkillState { internal static float giveBuffFraction = 0.3f; internal static float baseDuration = 0.5f; internal float duration; internal bool buffGiven; internal EnergySystem energySystem; public float Energy = StaticValues.masochismEnergyCost; private float energyCost; private float energyflatCost; public override void OnEnter() { //IL_012c: 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) ((BaseState)this).OnEnter(); energySystem = ((EntityState)this).gameObject.GetComponent<EnergySystem>(); duration = baseDuration / ((BaseState)this).attackSpeedStat; buffGiven = false; energyflatCost = Energy; if (energyflatCost < 0f) { energyflatCost = 1f; } energyCost = energySystem.costmultiplierOverheat * energyflatCost; if (energyCost < 0f) { energyCost = 1f; } if (energySystem.currentOverheat < energySystem.maxOverheat && ((EntityState)this).isAuthority) { energySystem.hasOverheatedSpecial = false; energySystem.currentOverheat += energyCost; } else if (energySystem.currentOverheat >= energySystem.maxOverheat && !((EntityState)this).isAuthority) { } if (((EntityState)this).isAuthority) { if (!Config.shouldHaveVoice.Value) { NetMessageExtensions.Send((INetMessage)(object)new PlaySoundNetworkRequest(((NetworkBehaviour)((EntityState)this).characterBody).netId, 1840962711u), (NetworkDestination)1); return; } uint soundNum = ((((EntityState)this).characterBody.HasBuff(Buffs.masochismBuff) || ((EntityState)this).characterBody.HasBuff(Buffs.fallDamageReductionBuff)) ? 1840962711u : 3831238989u); NetMessageExtensions.Send((INetMessage)(object)new PlaySoundNetworkRequest(((NetworkBehaviour)((EntityState)this).characterBody).netId, soundNum), (NetworkDestination)1); } } public override void OnExit() { //IL_0032: Unknown result type (might be due to invalid IL or missing references) ((EntityState)this).OnExit(); if (!buffGiven) { buffGiven = true; if (NetworkServer.active) { ((EntityState)this).characterBody.AddTimedBuff(Buffs.masochismBuff.buffIndex, StaticValues.masochismBuffDuration); } } } public override void FixedUpdate() { //IL_004b: Unknown result type (might be due to invalid IL or missing references) ((EntityState)this).FixedUpdate(); if (((EntityState)this).fixedAge > duration * giveBuffFraction && !buffGiven) { buffGiven = true; if (NetworkServer.active) { ((EntityState)this).characterBody.AddTimedBuff(Buffs.masochismBuff.buffIndex, StaticValues.masochismBuffDuration); } } if (((EntityState)this).fixedAge > duration) { ((EntityState)this).outer.SetNextStateToMain(); } } 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)4; } } internal class NeoMasochism : BaseSkillState { public MasochismController maso; public ArsonistController arsonistCon; public float stopwatch; public static float baseActivationTime = 0.16f; public static float baseDuration = 3.1f; public float duration; public float originalFOV; public float targetFOV; public float originalLerpTime; public static float tempLerpTime = 0.25f; public float multiplier = 1.1f; public EnergySystem energySystem; private CameraParamsOverrideHandle handle; public override void OnEnter() { //IL_00b1: Unknown result type (might be due to invalid IL or missing references) //IL_00b6: 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_00c4: Unknown result type (might be due to invalid IL or missing references) //IL_00cb: 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_00d4: 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_00e7: Unknown result type (might be due to invalid IL or missing references) //IL_0106: 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) //IL_0117: 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_0214: Unknown result type (might be due to invalid IL or missing references) ((BaseState)this).OnEnter(); maso = ((EntityState)this).gameObject.GetComponent<MasochismController>(); arsonistCon = ((EntityState)this).gameObject.GetComponent<ArsonistController>(); energySystem = ((EntityState)this).gameObject.GetComponent<EnergySystem>(); duration = baseDuration; if (Object.op_Implicit((Object)(object)energySystem)) { energySystem.SetCurrentHeatToLowerBound(); } if (Object.op_Implicit((Object)(object)arsonistCon.cameraRigController)) { originalFOV = arsonistCon.cameraRigController.baseFov; targetFOV = originalFOV * multiplier; } CameraTargetParams cameraTargetParams = ((EntityState)this).cameraTargetParams; CharacterCameraParamsData currentCameraParamsData = cameraTargetParams.currentCameraParamsData; currentCameraParamsData.fov = BlendableFloat.op_Implicit(targetFOV); CameraParamsOverrideRequest val = default(CameraParamsOverrideRequest); val.cameraParamsData = currentCameraParamsData; val.priority = 0f; CameraParamsOverrideRequest val2 = val; if (((EntityState)this).isAuthority && Config.ToggleMasochismFOVWarp.Value) { handle = cameraTargetParams.AddParamsOverride(val2, baseDuration * baseActivationTime); } if (Object.op_Implicit((Object)(object)maso) && Object.op_Implicit((Object)(object)maso)) { maso.masoRecentlyActivated = true; } if (Object.op_Implicit((Object)(object)maso) && maso.masochismActive && ((EntityState)this).isAuthority) { maso.TriggerMasochismAndEXOverheat(applyDebuff: false); ((EntityState)this).outer.SetNextStateToMain(); } else if (((EntityState)this).isAuthority) { NetMessageExtensions.Send((INetMessage)(object)new PlaySoundNetworkRequest(((NetworkBehaviour)((EntityState)this).characterBody).netId, 974780206u), (NetworkDestination)1); if (Config.shouldHaveVoice.Value && !((EntityState)this).characterBody.HasBuff(Buffs.masochismBuff)) { uint soundNum = ((((EntityState)this).characterBody.skinIndex == ArsonistMod.Modules.Survivors.Arsonist.FirebugSkinIndex) ? 1951821374u : 2881057417u); NetMessageExtensions.Send((INetMessage)(object)new PlaySoundNetworkRequest(((NetworkBehaviour)((EntityState)this).characterBody).netId, soundNum), (NetworkDestination)1); } } } public override void OnExit() { //IL_000f: Unknown result type (might be due to invalid IL or missing references) //IL_0019: Unknown result type (might be due to invalid IL or missing references) ((EntityState)this).OnExit(); ((EntityState)this).cameraTargetParams.RemoveParamsOverride(handle, 0.2f); } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); stopwatch += Time.fixedDeltaTime; if (stopwatch >= duration * baseActivationTime && ((EntityState)this).isAuthority) { if (Object.op_Implicit((Object)(object)maso) && !maso.masochismActive) { maso.ActivateMaso(); } ((EntityState)this).outer.SetNextStateToMain(); } } 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)4; } } } namespace ArsonistMod.SkillStates.ZeroPointBlast { public class ZeroPointBlastEnd : BaseSkillState { public ArsonistController arsonistCon; public float stopwatch; public float duration; public static float baseDuration = 0.6f; public static float earlyExitFrac = 0.48f; public static float unlockVelocity = 0.2f; public BlastAttack blastAttack; protected float pushForce = 500f; public float damageCoefficient; public float radius = 5f; public Animator animator; private string muzzleString = "GunMuzzle"; public Transform muzzlePos; public override void OnEnter() { //IL_0043: 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_0189: 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_0199: 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) //IL_01a9: Expected O, but got Unknown //IL_01d6: Unknown result type (might be due to invalid IL or missing references) //IL_01db: Unknown result type (might be due to invalid IL or missing references) //IL_023b: Unknown result type (might be due to invalid IL or missing references) //IL_0262: Unknown result type (might be due to invalid IL or missing references) //IL_0267: Unknown result type (might be due to invalid IL or missing references) //IL_0274: Unknown result type (might be due to invalid IL or missing references) //IL_0280: Unknown result type (might be due to invalid IL or missing references) //IL_028b: Unknown result type (might be due to invalid IL or missing references) //IL_0296: Unknown result type (might be due to invalid IL or missing references) //IL_029b: Unknown result type (might be due to invalid IL or missing references) //IL_02a2: Unknown result type (might be due to invalid IL or missing references) //IL_02ad: Unknown result type (might be due to invalid IL or missing references) //IL_02be: Expected O, but got Unknown //IL_00a8: Unknown result type (might be due to invalid IL or missing references) ((BaseState)this).OnEnter(); ChildLocator modelChildLocator = ((EntityState)this).GetModelChildLocator(); muzzlePos = modelChildLocator.FindChild(muzzleString); if (((EntityState)this).isAuthority && ((EntityState)this).isAuthority) { NetMessageExtensions.Send((INetMessage)(object)new PlaySoundNetworkRequest(((NetworkBehaviour)((EntityState)this).characterBody).netId, 1486446844u), (NetworkDestination)1); if (Config.shouldHaveVoice.Value && !((EntityState)this).characterBody.HasBuff(Buffs.masochismBuff)) { uint soundNum = ((((EntityState)this).characterBody.skinIndex == ArsonistMod.Modules.Survivors.Arsonist.FirebugSkinIndex) ? 2370694900u : 2004274107u); NetMessageExtensions.Send((INetMessage)(object)new PlaySoundNetworkRequest(((NetworkBehaviour)((EntityState)this).characterBody).netId, soundNum), (NetworkDestination)1); } } animator = ((EntityState)this).GetModelAnimator(); stopwatch = 0f; duration = baseDuration; animator.SetBool("attacking", true); animator.SetFloat("Attack.playbackRate", 1f); if (((BaseState)this).isGrounded) { ((EntityState)this).PlayAnimation("UpperBody, Override", "BufferEmpty"); ((EntityState)this).PlayCrossfade("FullBody, Override", "ZPBHit", "Attack.playbackRate", duration, 0.02f); } else { ((EntityState)this).PlayAnimation("FullBody, Override", "BufferEmpty"); ((EntityState)this).PlayCrossfade("UpperBody, Override", "ZPBHit", "Attack.playbackRate", duration, 0.02f); } ((EntityState)this).characterMotor.velocity = Vector3.zero; ((EntityState)this).characterMotor.lastVelocity = Vector3.zero; blastAttack = new BlastAttack(); blastAttack.radius = radius; blastAttack.procCoefficient = 0.5f; blastAttack.position = ((EntityState)this).characterBody.corePosition; blastAttack.attacker = ((EntityState)this).gameObject; blastAttack.crit = Util.CheckRoll(((EntityState)this).characterBody.crit, ((EntityState)this).characterBody.master); blastAttack.baseDamage = ((EntityState)this).characterBody.damage * damageCoefficient; blastAttack.falloffModel = (FalloffModel)0; blastAttack.baseForce = pushForce; blastAttack.teamIndex = TeamComponent.GetObjectTeam(blastAttack.attacker); blastAttack.damageType = (DamageType)32; blastAttack.attackerFiltering = (AttackerFiltering)2; blastAttack.Fire(); EffectManager.SpawnEffect(Assets.elderlemurianexplosionEffect, new EffectData { origin = ((EntityState)this).characterBody.corePosition, scale = 3f }, true); arsonistCon = ((EntityState)this).gameObject.GetComponent<ArsonistController>(); arsonistCon.steamDownParticle.Stop(); arsonistCon.fireBeamForward.Play(); } public override void OnExit() { ((EntityState)this).OnExit(); animator.SetBool("attacking", false); arsonistCon.fireBeam.Stop(); arsonistCon.fireBeamForward.Stop(); ((EntityState)this).PlayAnimation("UpperBody, Override", "BufferEmpty"); } public override void FixedUpdate() { //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_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0051: Unknown result type (might be due to invalid IL or missing references) ((EntityState)this).FixedUpdate(); stopwatch += Time.fixedDeltaTime; if (stopwatch <= duration * unlockVelocity) { ((EntityState)this).characterMotor.velocity = Vector3.zero; ((EntityState)this).characterMotor.lastVelocity = Vector3.zero; } if (stopwatch >= duration) { ((EntityState)this).outer.SetNextStateToMain(); } } public override void OnSerialize(NetworkWriter writer) { ((BaseSkillState)this).OnSerialize(writer); writer.Write(damageCoefficient); } public override void OnDeserialize(NetworkReader reader) { ((BaseSkillState)this).OnDeserialize(reader); damageCoefficient = reader.ReadSingle(); } public override InterruptPriority GetMinimumInterruptPriority() { //IL_0022: 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_0025: Unknown result type (might be due to invalid IL or missing references) if (stopwatch >= duration * earlyExitFrac) { return (InterruptPriority)0; } return (InterruptPriority)2; } } public class ZeroPointBlastStart : BaseSkillState { public ArsonistController arsonistController; public EnergySystem energySystem; private OverlapAttack detector; private OverlapAttack attack; protected float procCoefficient = 1f; protected DamageType damageType = (DamageType)128; private float damageCoefficient; private Vector3 direction; protected float pushForce = 500f; protected Vector3 bonusForce = new Vector3(10f, 400f, 0f); protected string hitboxName = "ZeroPoint"; private BlastAttack blastAttack; public float radius = 5f; private Transform muzzlePos; private string muzzleString = "GunMuzzle"; private float hitPauseTimer; protected bool inHitPause; private HitStopCachedState hitStopCachedState; private Vector3 storedVelocity; private Vector3 bounceVector; public bool hasHit; public float stopwatch; public Animator animator; private Vector3 aimRayDir; private Ray aimRay; public static float baseduration = 0.8f; public static float duration; public static float initialSpeedCoefficient = 7f; public float SpeedCoefficient; public static float finalSpeedCoefficient = 4f; private float extraDuration; private static float startupFrac = 0.2f; private static float freezeFrac = 0.58f; private static float blastFrac = 0.3f; private static float stopFlameFrac = 0.35f; private bool hasFired = false; public static float hitExtraDuration = 0.44f; public static float minExtraDuration = 0.2f; private Transform modelTransform; private CharacterModel characterModel; private float rollSpeed; public override void OnEnter() { //IL_0029: 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) //IL_01f6: 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_02d0: Unknown result type (might be due to invalid IL or missing references) //IL_02da: Expected O, but got Unknown //IL_02e1: 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_0314: Unknown result type (might be due to invalid IL or missing references) //IL_0319: Unknown result type (might be due to invalid IL or missing references) //IL_035c: Unknown result type (might be due to invalid IL or missing references) //IL_0361: Unknown result type (might be due to invalid IL or missing references) //IL_0395: Unknown result type (might be due to invalid IL or missing references) //IL_039f: Expected O, but got Unknown //IL_03a6: Unknown result type (might be due to invalid IL or missing references) //IL_03ab: Unknown result type (might be due to invalid IL or missing references) //IL_03d9: Unknown result type (might be due to invalid IL or missing references) //IL_03de: Unknown result type (might be due to invalid IL or missing references) //IL_0415: Unknown result type (might be due to invalid IL or missing references) //IL_041a: Unknown result type (might be due to invalid IL or missing references) //IL_044a: Unknown result type (might be due to invalid IL or missing references) //IL_044f: Unknown result type (might be due to invalid IL or missing references) //IL_0453: Unknown result type (might be due to invalid IL or missing references) //IL_0458: Unknown result type (might be due to invalid IL or missing references) //IL_045c: Unknown result type (might be due to invalid IL or missing references) //IL_0461: Unknown result type (might be due to invalid IL or missing references) //IL_0477: Unknown result type (might be due to invalid IL or missing references) //IL_04ba: Unknown result type (might be due to invalid IL or missing references) //IL_04c4: Expected O, but got Unknown //IL_04f1: Unknown result type (might be due to invalid IL or missing references) //IL_04f6: Unknown result type (might be due to invalid IL or missing references) //IL_0556: Unknown result type (might be due to invalid IL or missing references) //IL_057d: Unknown result type (might be due to invalid IL or missing references) //IL_0582: Unknown result type (might be due to invalid IL or missing references) //IL_058f: Unknown result type (might be due to invalid IL or missing references) //IL_059b: Unknown result type (might be due to invalid IL or missing references) //IL_064a: Unknown result type (might be due to invalid IL or missing references) ((BaseState)this).OnEnter(); stopwatch = 0f; if (((EntityState)this).isAuthority) { NetMessageExtensions.Send((INetMessage)(object)new PlaySoundNetworkRequest(((NetworkBehaviour)((EntityState)this).characterBody).netId, 3585665340u), (NetworkDestination)1); if (Config.shouldHaveVoice.Value && !((EntityState)this).characterBody.HasBuff(Buffs.masochismBuff)) { uint soundNum = ((((EntityState)this).characterBody.skinIndex == ArsonistMod.Modules.Survivors.Arsonist.FirebugSkinIndex) ? 2370694900u : 2004274107u); NetMessageExtensions.Send((INetMessage)(object)new PlaySoundNetworkRequest(((NetworkBehaviour)((EntityState)this).characterBody).netId, soundNum), (NetworkDestination)1); } } energySystem = ((Component)((EntityState)this).characterBody).gameObject.GetComponent<EnergySystem>(); if (energySystem.currentOverheat < energySystem.maxOverheat && ((EntityState)this).isAuthority) { energySystem.LowerHeat(energySystem.currentOverheat * StaticValues.zeropointHeatReductionMultiplier); damageCoefficient = StaticValues.zeropointpounchDamageCoefficient; energySystem.hasOverheatedSecondary = false; } else if (energySystem.currentOverheat >= energySystem.maxOverheat && ((EntityState)this).isAuthority) { energySystem.hasOverheatedSecondary = false; damageCoefficient = StaticValues.zeropointpounchDamageCoefficient * 0.5f; } hasHit = false; aimRayDir = ((Ray)(ref aimRay)).direction; duration = baseduration; float num = ((BaseState)this).moveSpeedStat; if (((EntityState)this).characterBody.isSprinting) { num /= ((EntityState)this).characterBody.sprintingSpeedMultiplier; } float num2 = num / (((EntityState)this).characterBody.baseMoveSpeed - 1f); SpeedCoefficient = initialSpeedCoefficient * num2; extraDuration = Math.Max(hitExtraDuration / (num2 + 1f), minExtraDuration); ((EntityState)this).characterBody.AddTimedBuffAuthority(Buffs.HiddenInvincibility.buffIndex, duration / 2f); animator = ((EntityState)this).GetModelAnimator(); animator.SetBool("attacking", true); ((EntityState)this).characterBody.SetAimTimer(duration); HitBoxGroup hitBoxGroup = null; HitBoxGroup hitBoxGroup2 = null; Transform val = ((EntityState)this).GetModelTransform(); modelTransform = ((EntityState)this).GetModelTransform(); if (Object.op_Implicit((Object)(object)modelTransform)) { animator = ((Component)modelTransform).GetComponent<Animator>(); characterModel = ((Component)modelTransform).GetComponent<CharacterModel>(); } if (Object.op_Implicit((Object)(object)val)) { hitBoxGroup = Array.Find(((Component)val).GetComponents<HitBoxGroup>(), (HitBoxGroup element) => element.groupName == hitboxName); hitBoxGroup2 = Array.Find(((Component)val).GetComponents<HitBoxGroup>(), (HitBoxGroup element) => element.groupName == hitboxName); } attack = new OverlapAttack(); attack.damageType = damageType; attack.attacker = ((EntityState)this).gameObject; attack.inflictor = ((EntityState)this).gameObject; attack.teamIndex = ((BaseState)this).GetTeam(); attack.damage = ((EntityState)this).characterBody.damage; attack.procCoefficient = procCoefficient; attack.hitEffectPrefab = FireBarrage.hitEffectPrefab; attack.forceVector = bonusForce; attack.pushAwayForce = pushForce; attack.hitBoxGroup = hitBoxGroup; attack.isCrit = ((BaseState)this).RollCrit(); detector = new OverlapAttack(); detector.damageType = damageType; detector.attacker = ((EntityState)this).gameObject; detector.inflictor = ((EntityState)this).gameObject; detector.teamIndex = ((BaseState)this).GetTeam(); detector.damage = 0f; detector.procCoefficient = 0f; detector.hitEffectPrefab = null; detector.forceVector = Vector3.zero; detector.pushAwayForce = 0f; detector.hitBoxGroup = hitBoxGroup2; detector.isCrit = false; Ray val2 = ((BaseState)this).GetAimRay(); Vector3 val3 = ((Ray)(ref val2)).direction; direction = ((Vector3)(ref val3)).normalized; ((EntityState)this).characterDirection.forward = ((Vector3)(ref ((EntityState)this).characterMotor.velocity)).normalized; animator.SetFloat("Attack.playbackRate", ((BaseState)this).attackSpeedStat); ((EntityState)this).PlayCrossfade("FullBody, Override", "ZPBStart", "Attack.playbackRate", duration, 0.1f); blastAttack = new BlastAttack(); blastAttack.radius = radius; blastAttack.procCoefficient = 0.5f; blastAttack.position = ((EntityState)this).characterBody.corePosition; blastAttack.attacker = ((EntityState)this).gameObject; blastAttack.crit = Util.CheckRoll(((EntityState)this).characterBody.crit, ((EntityState)this).characterBody.master); blastAttack.baseDamage = ((EntityState)this).characterBody.damage * damageCoefficient; blastAttack.falloffModel = (FalloffModel)0; blastAttack.baseForce = pushForce; blastAttack.teamIndex = TeamComponent.GetObjectTeam(blastAttack.attacker); blastAttack.damageType = (DamageType)32; blastAttack.attackerFiltering = (AttackerFiltering)2; arsonistController = ((EntityState)this).gameObject.GetComponent<ArsonistController>(); if (Object.op_Implicit((Object)(object)arsonistController)) { arsonistController.steamDownParticle.Play(); arsonistController.hasZPBedRecently = true; } ChildLocator modelChildLocator = ((EntityState)this).GetModelChildLocator(); muzzlePos = modelChildLocator.FindChild(muzzleString); if (((BaseState)this).isGrounded) { ((BaseState)this).SmallHop(((EntityState)this).characterMotor, 6f); } else { ((BaseState)this).SmallHop(((EntityState)this).characterMotor, 4f); } if (((EntityState)this).isAuthority) { NetworkingHelpers.ApplyBuff(((EntityState)this).characterBody, Buffs.fallDamageReductionBuff.buffIndex, 1, 3f); } } private bool CheckLookingTowardsVector(Vector3 dir) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0007: 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_000f: Unknown result type (might be due to invalid IL or missing references) Ray val = ((BaseState)this).GetAimRay(); if (Vector3.Dot(((Ray)(ref val)).direction, dir) > 0.866f) { return true; } return false; } private void RecalculateRollSpeed() { float num = ((BaseState)this).moveSpeedStat; if (((EntityState)this).characterBody.isSprinting) { num /= ((EntityState)this).characterBody.sprintingSpeedMultiplier; } if (num >= 12f) { num = Mathf.Log10(num - 11f) + 12f; } rollSpeed = num * Mathf.Lerp(SpeedCoefficient, finalSpeedCoefficient, (stopwatch - duration * blastFrac) / (duration * freezeFrac - duration * blastFrac)); } private void FireAttack() { if (((EntityState)this).isAuthority) { List<HurtBox> list = new List<HurtBox>(); if (detector.Fire(list)) { OnHitEnemyAuthority(); } } } protected virtual void OnHitEnemyAuthority() { //IL_0012: Unknown result type (might be due to invalid IL or missing references) //IL_0017: Unknown result type (might be due to invalid IL or missing references) if (((EntityState)this).isAuthority) { ((EntityState)this).characterMotor.velocity = Vector3.zero; ((EntityState)this).outer.SetState((EntityState)(object)new ZeroPointBlastEnd { damageCoefficient = damageCoefficient }); } } public override void OnExit() { ((EntityState)this).OnExit(); ((EntityState)this).PlayAnimation("FullBody, Override", "BufferEmpty"); } public override void FixedUpdate() { //IL_003c: Unknown result type (might be due to invalid IL or missing references) //IL_0084: Unknown result type (might be due to invalid IL or missing references) //IL_0089: 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_00b0: 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_00bc: 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_00d8: Expected O, but got Unknown //IL_0124: Unknown result type (might be due to invalid IL or missing references) //IL_0152: 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_0162: 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_0167: 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_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_0192: 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) ((EntityState)this).FixedUpdate(); stopwatch += Time.fixedDeltaTime; if (stopwatch <= duration * startupFrac) { ((EntityState)this).characterDirection.forward = direction; } if (stopwatch >= duration * blastFrac && !hasFired) { hasFired = true; blastAttack.position = muzzlePos.position; blastAttack.Fire(); arsonistController.fireBeam.Play(); EffectManager.SpawnEffect(Assets.elderlemurianexplosionEffect, new EffectData { origin = ((EntityState)this).characterBody.corePosition, scale = 1.5f }, true); } if (stopwatch >= duration * blastFrac && stopwatch <= duration * freezeFrac) { RecalculateRollSpeed(); FireAttack(); ((EntityState)this).characterDirection.forward = direction; if (Object.op_Implicit((Object)(object)((EntityState)this).characterMotor) && Object.op_Implicit((Object)(object)((EntityState)this).characterDirection)) { Vector3 val = direction * rollSpeed; float num = Mathf.Max(Vector3.Dot(val, direction), 0f); val = direction * num; ((EntityState)this).characterMotor.velocity = val; } } if (stopwatch >= duration * freezeFrac && ((EntityState)this).isAuthority) { ((EntityState)this).outer.SetState((EntityState)(object)new ZeroPointBlastWhiff { damageCoefficient = damageCoefficient }); } } public override void OnSerialize(NetworkWriter writer) { ((BaseSkillState)this).OnSerialize(writer); writer.Write(damageCoefficient); } public override void OnDeserialize(NetworkReader reader) { ((BaseSkillState)this).OnDeserialize(reader); damageCoefficient = reader.ReadSingle(); } 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)4; } } public class ZeroPointBlastWhiff : BaseSkillState { public ArsonistController arsonistCon; public float stopwatch; public float duration; public static float baseDuration = 0.6f; public static float earlyExitFrac = 0.48f; public static float stopFiringFrac = 0.24f; public Animator anim; public OverlapAttack detector; protected DamageType damageType = (DamageType)128; protected string hitboxName = "ZeroPoint"; public float damageCoefficient; public override void OnEnter() { //IL_009c: Unknown result type (might be due to invalid IL or missing references) //IL_00a6: Expected O, but got Unknown //IL_00ad: Unknown result type (might be due to invalid IL or missing references) //IL_00b2: Unknown result type (might be due to invalid IL or missing references) //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_011c: Unknown result type (might be due to invalid IL or missing references) //IL_0121: Unknown result type (might be due to invalid IL or missing references) ((BaseState)this).OnEnter(); stopwatch = 0f; duration = baseDuration; anim = ((EntityState)this).GetModelAnimator(); anim.SetBool("attacking", true); ((EntityState)this).PlayAnimation("FullBody, Override", "BufferEmpty"); ((EntityState)this).PlayCrossfade("UpperBody, Override", "ZPBWhiff", "Attack.playbackRate", duration, 0.02f); Transform modelTransform = ((EntityState)this).GetModelTransform(); HitBoxGroup hitBoxGroup = null; if (Object.op_Implicit((Object)(object)modelTransform)) { hitBoxGroup = Array.Find(((Component)modelTransform).GetComponents<HitBoxGroup>(), (HitBoxGroup element) => element.groupName == hitboxName); } detector = new OverlapAttack(); detector.damageType = damageType; detector.attacker = ((EntityState)this).gameObject; detector.inflictor = ((EntityState)this).gameObject; detector.teamIndex = ((BaseState)this).GetTeam(); detector.damage = 0f; detector.procCoefficient = 0f; detector.hitEffectPrefab = null; detector.forceVector = Vector3.zero; detector.pushAwayForce = 0f; detector.hitBoxGroup = hitBoxGroup; detector.isCrit = false; arsonistCon = ((EntityState)this).gameObject.GetComponent<ArsonistController>(); arsonistCon.steamDownParticle.Stop(); arsonistCon.fireBeam.Stop(); } public override void OnExit() { ((EntityState)this).OnExit(); anim.SetBool("attacking", false); ((EntityState)this).PlayAnimation("UpperBody, Override", "BufferEmpty"); } private void FireAttack() { if (((EntityState)this).isAuthority) { List<HurtBox> list = new List<HurtBox>(); if (detector.Fire(list)) { OnHitEnemyAuthority(); } } } protected virtual void OnHitEnemyAuthority() { //IL_0012: Unknown result type (might be due to invalid IL or missing references) //IL_0017: Unknown result type (might be due to invalid IL or missing references) if (((EntityState)this).isAuthority) { ((EntityState)this).characterMotor.velocity = Vector3.zero; ((EntityState)this).outer.SetState((EntityState)(object)new ZeroPointBlastEnd { damageCoefficient = damageCoefficient }); } } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); stopwatch += Time.fixedDeltaTime; if (stopwatch <= duration * stopFiringFrac) { FireAttack(); } if (stopwatch >= duration) { ((EntityState)this).outer.SetNextStateToMain(); } } public override void OnSerialize(NetworkWriter writer) { ((BaseSkillState)this).OnSerialize(writer); writer.Write(damageCoefficient); } public override void OnDeserialize(NetworkReader reader) { ((BaseSkillState)this).OnDeserialize(reader); damageCoefficient = reader.ReadSingle(); } public override InterruptPriority GetMinimumInterruptPriority() { //IL_0022: 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_0025: Unknown result type (might be due to invalid IL or missing references) if (stopwatch >= duration * earlyExitFrac) { return (InterruptPriority)0; } return (InterruptPriority)2; } } } namespace ArsonistMod.SkillStates.Unused { internal class FlareEffectControllerStrongWorld : MonoBehaviour { public CharacterBody arsonistBody; public GameObject effectObj; public GameObject gameObj; public Vector3 worldPos; private int timesFired; private float timer; private void Start() { //IL_004d: Unknown result type (might be due to invalid IL or missing references) //IL_0053: Unknown result type (might be due to invalid IL or missing references) //IL_0058: Unknown result type (might be due to invalid IL or missing references) timer = 0f; timesFired = 0; gameObj = ((Component)this).gameObject.GetComponent<GameObject>(); Vector3 val = default(Vector3); ((Vector3)(ref val))..ctor((float)Random.Range(-2, 2), (float)Random.Range(-2, 2), (float)Random.Range(-2, 2)); effectObj = Object.Instantiate<GameObject>(Assets.arsonistFlareAttached, worldPos, Quaternion.LookRotation(worldPos)); } private void FixedUpdate() { //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_0091: 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_00a7: 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_00cc: Expected O, but got Unknown if (timer > StaticValues.flareInterval) { if (timesFired < StaticValues.flareTickNum) { timesFired++; timer = 0f; FireExplosion(StaticValues.flareBlastRadius / 2f); AkSoundEngine.PostEvent(3747272580u, gameObj); return; } FireExplosion(StaticValues.flareBlastRadius); AkSoundEngine.PostEvent(3061346618u, gameObj); EffectManager.SpawnEffect(Assets.explosionPrefab, new EffectData { origin = worldPos, scale = StaticValues.flareBlastRadius, rotation = new Quaternion(0f, 0f, 0f, 0f) }, true); Object.Destroy((Object)(object)this); Object.Destroy((Object)(object)effectObj); } else { timer += Time.deltaTime; } } private void FireExplosion(float radius) { //IL_0001: Unknown result type (might be due to invalid IL or missing references) //IL_0007: Expected O, but got Unknown //IL_001b: Unknown result type (might be due to invalid IL or missing references) //IL_0022: Unknown result type (might be due to invalid IL or missing references) //IL_0027: 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_007f: Unknown result type (might be due to invalid IL or missing references) BlastAttack val = new BlastAttack(); val.radius = radius; val.procCoefficient = 1f; val.teamIndex = (TeamIndex)1; val.position = worldPos; val.attacker = ((Component)arsonistBody).gameObject; val.crit = arsonistBody.RollCrit(); val.baseDamage = arsonistBody.baseDamage * StaticValues.flareStrongDamageCoefficient; val.falloffModel = (FalloffModel)0; val.baseForce = 1f; val.damageType = (DamageType)0; val.Fire(); } private void OnDestroy() { Object.Destroy((Object)(object)effectObj); } } internal class FlareEffectControllerWeakWorld : MonoBehaviour { public CharacterBody arsonistBody; public GameObject effectObj; public GameObject gameObj; public Vector3 worldPos; private int timesFired; private float timer; private void Start() { //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_005d: Unknown result type (might be due to invalid IL or missing references) //IL_0062: Unknown result type (might be due to invalid IL or missing references) timer = 0f; timesFired = 0; gameObj = ((Component)this).gameObject.GetComponent<GameObject>(); Vector3 val = default(Vector3); ((Vector3)(ref val))..ctor((float)Random.Range(-2, 2), (float)Random.Range(-2, 2), (float)Random.Range(-2, 2)); effectObj = Object.Instantiate<GameObject>(Assets.mainAssetBundle.LoadAsset<GameObject>("flareAttached"), worldPos, Quaternion.LookRotation(worldPos)); } private void FixedUpdate() { //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_0091: 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_00a7: 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_00cc: Expected O, but got Unknown if (timer > StaticValues.flareInterval) { if (timesFired < StaticValues.flareTickNum) { timesFired++; timer = 0f; FireExplosion(StaticValues.flareBlastRadius / 2f); AkSoundEngine.PostEvent(3747272580u, gameObj); return; } FireExplosion(StaticValues.flareBlastRadius); AkSoundEngine.PostEvent(3061346618u, gameObj); EffectManager.SpawnEffect(Assets.explosionPrefab, new EffectData { origin = worldPos, scale = StaticValues.flareBlastRadius, rotation = new Quaternion(0f, 0f, 0f, 0f) }, true); Object.Destroy((Object)(object)this); Object.Destroy((Object)(object)effectObj); } else { timer += Time.deltaTime; } } private void FireExplosion(float radius) { //IL_0001: Unknown result type (might be due to invalid IL or missing references) //IL_0007: Expected O, but got Unknown //IL_001b: Unknown result type (might be due to invalid IL or missing references) //IL_0022: Unknown result type (might be due to invalid IL or missing references) //IL_0027: 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_007f: Unknown result type (might be due to invalid IL or missing references) BlastAttack val = new BlastAttack(); val.radius = radius; val.procCoefficient = 1f; val.teamIndex = (TeamIndex)1; val.position = worldPos; val.attacker = ((Component)arsonistBody).gameObject; val.crit = arsonistBody.RollCrit(); val.baseDamage = arsonistBody.baseDamage * StaticValues.flareWeakDamageCoefficient; val.falloffModel = (FalloffModel)0; val.baseForce = 1f; val.damageType = (DamageType)0; val.Fire(); } private void OnDestroy() { Object.Destroy((Object)(object)effectObj); } } } namespace ArsonistMod.SkillStates.Arsonist.Secondary { internal class FlareEffectControllerStrong : MonoBehaviour { public CharacterBody arsonistBody; public CharacterBody charbody; public GameObject effectObj; private int timesFired; private float timer; private bool hasFired; public uint burningSound; private void Start() { //IL_0030: Unknown result type (might be due to invalid IL or missing references) //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) timer = 0f; timesFired = 0; charbody = ((Component)this).gameObject.GetComponent<CharacterBody>(); effectObj = Object.Instantiate<GameObject>(Assets.arsonistFlareAttached, charbody.corePosition, Quaternion.LookRotation(Vector3.forward)); effectObj.transform.parent = ((Component)charbody).gameObject.transform; Util.PlaySound("Arsonist_Secondary_Flare_Projectile_Impact", ((Component)this).gameObject); burningSound = Util.PlaySound("Arsonist_Secondary_Flare_Projectile_Burning", ((Component)this).gameObject); } private void FixedUpdate() {