using System; using System.Collections.Generic; using System.Collections.ObjectModel; 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 AncientScepter; using BepInEx; using BepInEx.Bootstrap; using BepInEx.Configuration; using EntityStates; using EntityStates.Bandit2; using EntityStates.Captain.Weapon; using EntityStates.Commando; using EntityStates.Commando.CommandoWeapon; using EntityStates.Croco; using EntityStates.Drone; using EntityStates.Engi.EngiWeapon; using EntityStates.FalseSon; using EntityStates.Huntress; using EntityStates.Huntress.HuntressWeapon; using EntityStates.Huntress.Weapon; using EntityStates.Loader; using EntityStates.Mage.Weapon; using EntityStates.Merc; using EntityStates.Merc.Weapon; using EntityStates.Railgunner.Backpack; using EntityStates.Railgunner.Weapon; using EntityStates.Seeker; using EntityStates.Toolbot; using HG; using KinematicCharacterController; using On.RoR2; using R2API; using R2API.Utils; using Rewired.ComponentControls.Effects; using RoR2; using RoR2.Audio; using RoR2.CharacterAI; using RoR2.Navigation; using RoR2.Networking; using RoR2.Orbs; using RoR2.Projectile; using RoR2.Skills; using RoR2.UI; using UnityEngine; using UnityEngine.AddressableAssets; using UnityEngine.Events; using UnityEngine.Networking; using UnityEngine.Rendering; using UnityEngine.Rendering.PostProcessing; using UnityEngine.UI; [assembly: Debuggable(DebuggableAttribute.DebuggingModes.Default | DebuggableAttribute.DebuggingModes.DisableOptimizations | DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints | DebuggableAttribute.DebuggingModes.EnableEditAndContinue)] [assembly: TargetFramework(".NETStandard,Version=v2.1", FrameworkDisplayName = "")] [assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)] [assembly: CompilationRelaxations(8)] [assembly: AssemblyCompany("AerosSkills")] [assembly: AssemblyProduct("AerosSkills")] [assembly: AssemblyTitle("AerosSkills")] [assembly: AssemblyInformationalVersion("1.0.0")] [assembly: AssemblyConfiguration("Debug")] [assembly: AssemblyFileVersion("1.0.0.0")] [assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)] [assembly: AssemblyVersion("1.0.0.0")] [module: UnverifiableCode] namespace AerosSkills; internal class Assets { public static AssetBundle MainAssetBundle; public static T Load(string name) where T : Object { return MainAssetBundle.LoadAsset(name); } public static void PopulateAssets() { Assembly executingAssembly = Assembly.GetExecutingAssembly(); if ((Object)(object)MainAssetBundle == (Object)null) { using Stream stream = executingAssembly.GetManifestResourceStream("AerosSkills.AssetBundle." + "AerosSkills".ToLower() + "assets"); MainAssetBundle = AssetBundle.LoadFromStream(stream); } using Stream stream2 = executingAssembly.GetManifestResourceStream("AerosSkills.AerosSkills.bnk"); byte[] array = new byte[stream2.Length]; stream2.Read(array, 0, array.Length); SoundBanks.Add(array); } } internal class CrosshairSwap : MonoBehaviour { private CharacterBody body; private void Awake() { body = ((Component)this).GetComponent(); } private void Start() { if (body.skillLocator.primary.skillNameToken == "AEROS__M1") { body.spreadBloomCurve = Prefabs.spreadBloomCurve; body._defaultCrosshairPrefab = Prefabs.Load("RoR2/Base/UI/StandardCrosshair.prefab"); } } } internal class DebugHelper : MonoBehaviour { } [DefaultExecutionOrder(100)] internal class eee : MonoBehaviour { private Tracer tracer; public float zPos = 13f; private void Start() { //IL_001d: 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_0025: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_0031: Unknown result type (might be due to invalid IL or missing references) tracer = ((Component)this).GetComponent(); Vector3 localPosition = tracer.beamObject.transform.localPosition; Vector3 val = default(Vector3); ((Vector3)(ref val))..ctor(localPosition.x, localPosition.y, localPosition.z + zPos); } } internal class ForcePos : MonoBehaviour { private void LateUpdate() { //IL_0007: Unknown result type (might be due to invalid IL or missing references) //IL_0011: Unknown result type (might be due to invalid IL or missing references) ((Component)this).transform.localPosition = Vector3.up * 4f; } } internal class MercHitboxScale : MonoBehaviour { private bool scaled; public void Scale() { //IL_0034: Unknown result type (might be due to invalid IL or missing references) //IL_0039: Unknown result type (might be due to invalid IL or missing references) //IL_003e: Unknown result type (might be due to invalid IL or missing references) //IL_004b: Unknown result type (might be due to invalid IL or missing references) //IL_0050: Unknown result type (might be due to invalid IL or missing references) //IL_005a: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Unknown result type (might be due to invalid IL or missing references) if (!scaled) { scaled = true; Transform transform = ((Component)((Component)((Component)this).GetComponent().modelTransform).GetComponent().hitBoxes[0]).transform; transform.localPosition += Vector3.up; transform.localScale += Vector3.up * 2f; } } } internal class MissileSearchTweak : MonoBehaviour { public float maxAngle = 75f; private MissileController missile; private void Start() { missile = ((Component)this).GetComponent(); missile.search.maxAngleFilter = 20f; } } internal class MultDroneBehaviour : NetworkBehaviour { public CharacterBody body; public CharacterMaster master; public MultTracker tracker; public AISkillDriver hover; public bool setMat; public GameObject owner; public CharacterBody ownerBody; private bool init; private static int kRpcRpcSetOwner; private void Awake() { master = ((Component)this).GetComponent(); } private void Start() { } public void SetFollowState() { //IL_0026: Unknown result type (might be due to invalid IL or missing references) //IL_002c: Expected O, but got Unknown if (Object.op_Implicit((Object)(object)body) && body.hasEffectiveAuthority) { Follow val = new Follow(); val.target = owner; val.occupySpace = false; EntityStateMachine component = ((Component)body).GetComponent(); component.SetNextState((EntityState)(object)val); } } [ClientRpc] public void RpcSetOwner(GameObject ownerObject) { owner = ownerObject; ownerBody = owner.GetComponent(); tracker = owner.GetComponent(); tracker.droneMaster = master; } private void FixedUpdate() { if (!Object.op_Implicit((Object)(object)body)) { body = master.GetBody(); return; } if (!init && Object.op_Implicit((Object)(object)ownerBody)) { init = true; tracker.droneAI = ((Component)master).GetComponent(); tracker.droneSkill = body.skillLocator.primary; SetFollowState(); } if (!setMat && Object.op_Implicit((Object)(object)tracker) && Object.op_Implicit((Object)(object)tracker.baseMat)) { setMat = true; ((Component)((Component)body.modelLocator.modelTransform).GetComponent().FindChild("drone")).GetComponent().material = tracker.baseMat; } } public void EndScan() { if (Object.op_Implicit((Object)(object)tracker)) { tracker.endScanning = true; } } private void UNetVersion() { } protected static void InvokeRpcRpcSetOwner(NetworkBehaviour obj, NetworkReader reader) { if (!NetworkClient.active) { Debug.LogError((object)"RPC RpcSetOwner called on server."); } else { ((MultDroneBehaviour)(object)obj).RpcSetOwner(reader.ReadGameObject()); } } public void CallRpcSetOwner(GameObject ownerObject) { //IL_0016: Unknown result type (might be due to invalid IL or missing references) //IL_001c: Expected O, but got Unknown //IL_0041: Unknown result type (might be due to invalid IL or missing references) if (!NetworkServer.active) { Debug.LogError((object)"RPC Function RpcSetOwner called on client."); return; } NetworkWriter val = new NetworkWriter(); val.Write((short)0); val.Write((short)2); val.WritePackedUInt32((uint)kRpcRpcSetOwner); val.Write(((Component)this).GetComponent().netId); val.Write(ownerObject); ((NetworkBehaviour)this).SendRPCInternal(val, 0, "RpcSetOwner"); } static MultDroneBehaviour() { //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002a: Expected O, but got Unknown kRpcRpcSetOwner = 2031436444; NetworkBehaviour.RegisterRpcDelegate(typeof(MultDroneBehaviour), kRpcRpcSetOwner, new CmdDelegate(InvokeRpcRpcSetOwner)); NetworkCRC.RegisterBehaviour("MultDroneBehaviour", 0); } public override bool OnSerialize(NetworkWriter writer, bool forceAll) { bool result = default(bool); return result; } public override void OnDeserialize(NetworkReader reader, bool initialState) { } } internal class MultTracker : HuntressTracker { public BaseAI droneAI; public GenericSkill droneSkill; public bool enable; public bool endScanning; public CharacterMaster droneMaster; public Material baseMat; public CharacterModel model; private float stopwatch; public bool exitSkill { get; set; } public void SelectTarget() { if (Object.op_Implicit((Object)(object)base.trackingTarget) && Object.op_Implicit((Object)(object)droneAI) && Object.op_Implicit((Object)(object)droneSkill)) { droneAI.currentEnemy.gameObject = ((Component)base.trackingTarget.healthComponent).gameObject; CharacterBody body = droneMaster.GetBody(); if (Object.op_Implicit((Object)(object)body) && body.hasEffectiveAuthority) { ((Component)body).GetComponent().SetNextStateToMain(); droneSkill.ExecuteIfReady(); } } } public void DisableScanning() { endScanning = true; } private void Start() { //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_0052: 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_005f: Unknown result type (might be due to invalid IL or missing references) //IL_0064: Unknown result type (might be due to invalid IL or missing references) //IL_0069: 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_006f: Unknown result type (might be due to invalid IL or missing references) //IL_0074: Unknown result type (might be due to invalid IL or missing references) //IL_0080: Unknown result type (might be due to invalid IL or missing references) //IL_0088: Expected O, but got Unknown ((HuntressTracker)this).Start(); enable = base.characterBody.skillLocator.secondary.skillNameToken == "AEROS_MULT_SEC"; if (enable && NetworkServer.active) { MasterSummon val = new MasterSummon { masterPrefab = Prefabs.droneMaster, position = Utils.FindNearestNodePosition(((Component)this).transform.position, (GraphType)0), rotation = Quaternion.identity, summonerBodyObject = ((Component)this).gameObject, ignoreTeamMemberLimit = true }; CharacterMaster val2 = val.Perform(); ((Component)val2).GetComponent().CallRpcSetOwner(((Component)this).gameObject); } model = ((Component)base.characterBody.modelLocator.modelTransform).GetComponent(); AkBankManager.LoadBankAsync("char_captain", (BankCallback)null); } private void FixedUpdate() { //IL_00ad: Unknown result type (might be due to invalid IL or missing references) //IL_00b8: Unknown result type (might be due to invalid IL or missing references) //IL_00d6: Unknown result type (might be due to invalid IL or missing references) //IL_00db: Unknown result type (might be due to invalid IL or missing references) //IL_00e8: Unknown result type (might be due to invalid IL or missing references) //IL_00ed: Unknown result type (might be due to invalid IL or missing references) //IL_00f9: Unknown result type (might be due to invalid IL or missing references) if (!Object.op_Implicit((Object)(object)baseMat) && Object.op_Implicit((Object)(object)model) && model.baseRendererInfos.Length > 1) { baseMat = model.baseRendererInfos[1].defaultMaterial; } if (!enable) { base.indicator.active = false; return; } stopwatch += Time.fixedDeltaTime; if (stopwatch >= 0.1f) { stopwatch = 0f; Ray val = default(Ray); ((Ray)(ref val))..ctor(base.inputBank.aimOrigin, base.inputBank.aimDirection); base.search.filterByLoS = true; base.search.searchOrigin = ((Ray)(ref val)).origin; base.search.searchDirection = ((Ray)(ref val)).direction; base.search.sortMode = (SortMode)1; base.search.maxDistanceFilter = base.maxTrackingDistance; base.search.maxAngleFilter = base.maxTrackingAngle; base.search.RefreshCandidates(); base.search.FilterOutGameObject(((Component)this).gameObject); base.trackingTarget = base.search.GetResults().FirstOrDefault(); base.indicator.targetTransform = (Object.op_Implicit((Object)(object)base.trackingTarget) ? ((Component)base.trackingTarget).transform : null); } } private void OnDestroy() { if (Object.op_Implicit((Object)(object)droneMaster)) { droneMaster.DestroyBody(); Object.Destroy((Object)(object)((Component)droneMaster).gameObject); } } } internal class RadialBuff : MonoBehaviour { private TeamFilter teamFilter; private void OnCollisionEnter(Collision collision) { //IL_00ce: 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_001f: Expected O, but got Unknown //IL_0026: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_003d: 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_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_0102: Unknown result type (might be due to invalid IL or missing references) //IL_010e: Unknown result type (might be due to invalid IL or missing references) //IL_024c: Unknown result type (might be due to invalid IL or missing references) //IL_0251: Unknown result type (might be due to invalid IL or missing references) //IL_0258: Unknown result type (might be due to invalid IL or missing references) //IL_0263: Unknown result type (might be due to invalid IL or missing references) //IL_0270: Expected O, but got Unknown float value = MainPlugin.radius.Value; if (NetworkServer.active) { SphereSearch val = new SphereSearch(); val.origin = ((Component)this).transform.position; val.radius = value; val.mask = ((LayerIndex)(ref LayerIndex.entityPrecise)).mask; HurtBox[] hurtBoxes = val.RefreshCandidates().FilterCandidatesByHurtBoxTeam(TeamMask.GetEnemyTeams(teamFilter.teamIndex)).FilterCandidatesByDistinctHurtBoxEntities() .GetHurtBoxes(); HurtBox[] array = hurtBoxes; foreach (HurtBox val2 in array) { if (Object.op_Implicit((Object)(object)val2.healthComponent)) { SetStateOnHurt component = ((Component)val2.healthComponent).GetComponent(); if (Object.op_Implicit((Object)(object)component)) { component.SetPain(); } } } } foreach (TeamComponent teamMember in TeamComponent.GetTeamMembers(teamFilter.teamIndex)) { if (!Object.op_Implicit((Object)(object)teamMember.body) || !(Vector3.Distance(((Component)this).transform.position, ((Component)teamMember).transform.position) <= value)) { continue; } float value2 = MainPlugin.duration.Value; if (Object.op_Implicit((Object)(object)teamMember.body.modelLocator) && Object.op_Implicit((Object)(object)teamMember.body.modelLocator.modelTransform)) { CharacterModel component2 = ((Component)teamMember.body.modelLocator.modelTransform).GetComponent(); if (Object.op_Implicit((Object)(object)component2)) { TemporaryOverlayInstance val3 = TemporaryOverlayManager.AddOverlay(((Component)component2).gameObject); val3.duration = value2; val3.animateShaderAlpha = true; val3.alphaCurve = AnimationCurve.EaseInOut(0f, 1f, 1f, 0f); val3.alphaCurve.AddKey(0.85f, 1f); val3.destroyComponentOnEnd = true; val3.originalMaterial = Prefabs.overlay; val3.AddToCharacterModel(component2); } } if (NetworkServer.active) { teamMember.body.AddTimedBuff(Prefabs.overclock, value2); } } EffectManager.SpawnEffect(Prefabs.buffProjectileExplosion, new EffectData { origin = ((Component)this).transform.position, scale = value }, false); } private void Awake() { teamFilter = ((Component)this).GetComponent(); } } internal class RailgunnerScreenBehaviour : NetworkBehaviour, IProjectileImpactBehavior { private ProjectileController controller; public GameObject screenMesh; private static int kRpcRpcCollision; private void Awake() { controller = ((Component)this).GetComponentInParent(); } public void OnProjectileImpact(ProjectileImpactInfo impactInfo) { //IL_0001: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) if (Object.op_Implicit((Object)(object)impactInfo.collider) && !Object.op_Implicit((Object)(object)((Component)impactInfo.collider).GetComponent())) { CallRpcCollision(); } } [ClientRpc] public void RpcCollision() { screenMesh.SetActive(true); } private void FixedUpdate() { } private void UNetVersion() { } protected static void InvokeRpcRpcCollision(NetworkBehaviour obj, NetworkReader reader) { if (!NetworkClient.active) { Debug.LogError((object)"RPC RpcCollision called on server."); } else { ((RailgunnerScreenBehaviour)(object)obj).RpcCollision(); } } public void CallRpcCollision() { //IL_0016: Unknown result type (might be due to invalid IL or missing references) //IL_001c: Expected O, but got Unknown //IL_0041: Unknown result type (might be due to invalid IL or missing references) if (!NetworkServer.active) { Debug.LogError((object)"RPC Function RpcCollision called on client."); return; } NetworkWriter val = new NetworkWriter(); val.Write((short)0); val.Write((short)2); val.WritePackedUInt32((uint)kRpcRpcCollision); val.Write(((Component)this).GetComponent().netId); ((NetworkBehaviour)this).SendRPCInternal(val, 0, "RpcCollision"); } static RailgunnerScreenBehaviour() { //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002a: Expected O, but got Unknown kRpcRpcCollision = -1880999976; NetworkBehaviour.RegisterRpcDelegate(typeof(RailgunnerScreenBehaviour), kRpcRpcCollision, new CmdDelegate(InvokeRpcRpcCollision)); NetworkCRC.RegisterBehaviour("RailgunnerScreenBehaviour", 0); } public override bool OnSerialize(NetworkWriter writer, bool forceAll) { bool result = default(bool); return result; } public override void OnDeserialize(NetworkReader reader, bool initialState) { } } internal class RailgunnerScreenCollision : MonoBehaviour { private void OnTriggerEnter(Collider collider) { //IL_002d: Unknown result type (might be due to invalid IL or missing references) ProjectileDamage component = ((Component)collider).GetComponent(); if (Object.op_Implicit((Object)(object)component)) { component.damage *= MainPlugin.railgunnerUtilityDamageMult.Value; component.damageColorIndex = (DamageColorIndex)12; } } } internal class ReplaceableSkill : MonoBehaviour { private CharacterBody body; private float stopwatch; public bool active = true; public float cooldown = 0.5f; private float rechargeStopwatch; private void Awake() { body = ((Component)this).GetComponent(); } private void FixedUpdate() { if (!active) { stopwatch += Time.fixedDeltaTime; if (stopwatch >= cooldown) { stopwatch = 0f; active = true; } } rechargeStopwatch += Time.fixedDeltaTime; } public void ClearOverride() { body.skillLocator.secondary.UnsetSkillOverride((object)((Component)this).gameObject, MainPlugin.seekerSecondary, (SkillOverridePriority)4); body.skillLocator.secondary.RechargeBaseSkill(rechargeStopwatch); rechargeStopwatch = 0f; } public void ReplaceSkill() { rechargeStopwatch = 0f; body.skillLocator.secondary.SetSkillOverride((object)((Component)this).gameObject, MainPlugin.seekerSecondary, (SkillOverridePriority)4); } } internal class SeekerGenkidamaProjectile : NetworkBehaviour { private ProjectileController controller; private ProjectileDamage projectileDamage; private ProjectileSimple simple; private Collider collider; private ProjectileImpactExplosion impact; private SkillLocator skillLocator; private CharacterBody ownerBody; private SeekerController seekerController; private EntityStateMachine weapon; public float upPos = 4f; private float damage; private int inputCount; private int tranquilityCount; private static int kCmdCmdUpdateInput; private void Awake() { controller = ((Component)this).GetComponent(); simple = ((Component)this).GetComponent(); projectileDamage = ((Component)this).GetComponent(); impact = ((Component)this).GetComponent(); collider = ((Component)this).GetComponent(); } private void Start() { if (Object.op_Implicit((Object)(object)controller.owner)) { GameObject owner = controller.owner; skillLocator = owner.GetComponent(); ownerBody = owner.GetComponent(); seekerController = owner.GetComponent(); weapon = Array.Find(owner.GetComponents(), (EntityStateMachine x) => x.customName == "Weapon"); } } private void Update() { //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) if (!((Behaviour)simple).enabled && Object.op_Implicit((Object)(object)controller.owner)) { ((Component)this).transform.position = controller.owner.transform.position + Vector3.up * upPos; } } [Command] private void CmdUpdateInput(int input) { inputCount = input; } private void FixedUpdate() { //IL_000d: Unknown result type (might be due to invalid IL or missing references) //IL_0012: 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_0030: 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) ((Component)this).transform.localScale = Vector3.Lerp(((Component)this).transform.localScale, Vector3.one * (float)(inputCount + 1), 1.5f * Time.fixedDeltaTime); if (Object.op_Implicit((Object)(object)ownerBody)) { ((Component)this).transform.forward = ownerBody.inputBank.aimDirection; damage = ownerBody.damage; tranquilityCount = ownerBody.GetBuffCount(Buffs.ChakraBuff); } if (!((Behaviour)simple).enabled && Object.op_Implicit((Object)(object)seekerController) && Util.HasEffectiveAuthority(controller.owner)) { CallCmdUpdateInput(seekerController.meditationInputStep); } if ((!((Behaviour)simple).enabled && !Object.op_Implicit((Object)(object)ownerBody)) || (Object.op_Implicit((Object)(object)weapon) && !(weapon.state is Genkidama))) { ((Behaviour)simple).enabled = true; ((Behaviour)impact).enabled = true; ((ProjectileExplosion)impact).blastRadius = 5 * (inputCount + 1); collider.enabled = true; projectileDamage.damage = (MainPlugin.genkidamaBaseDamage.Value + MainPlugin.genkidamaAddDamage.Value * (float)tranquilityCount) * damage; } } private void UNetVersion() { } protected static void InvokeCmdCmdUpdateInput(NetworkBehaviour obj, NetworkReader reader) { if (!NetworkServer.active) { Debug.LogError((object)"Command CmdUpdateInput called on client."); } else { ((SeekerGenkidamaProjectile)(object)obj).CmdUpdateInput((int)reader.ReadPackedUInt32()); } } public void CallCmdUpdateInput(int input) { //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0058: Unknown result type (might be due to invalid IL or missing references) if (!NetworkClient.active) { Debug.LogError((object)"Command function CmdUpdateInput called on server."); return; } if (((NetworkBehaviour)this).isServer) { CmdUpdateInput(input); return; } NetworkWriter val = new NetworkWriter(); val.Write((short)0); val.Write((short)5); val.WritePackedUInt32((uint)kCmdCmdUpdateInput); val.Write(((Component)this).GetComponent().netId); val.WritePackedUInt32((uint)input); ((NetworkBehaviour)this).SendCommandInternal(val, 0, "CmdUpdateInput"); } static SeekerGenkidamaProjectile() { //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002a: Expected O, but got Unknown kCmdCmdUpdateInput = -1960028162; NetworkBehaviour.RegisterCommandDelegate(typeof(SeekerGenkidamaProjectile), kCmdCmdUpdateInput, new CmdDelegate(InvokeCmdCmdUpdateInput)); NetworkCRC.RegisterBehaviour("SeekerGenkidamaProjectile", 0); } public override bool OnSerialize(NetworkWriter writer, bool forceAll) { bool result = default(bool); return result; } public override void OnDeserialize(NetworkReader reader, bool initialState) { } } internal class SimpleUpdate : MonoBehaviour { private ProjectileSimple simple; private ProjectileTargetComponent target; private void Awake() { simple = ((Component)this).GetComponent(); target = ((Component)this).GetComponent(); } private void FixedUpdate() { simple.updateAfterFiring = Object.op_Implicit((Object)(object)target.target); } } [DefaultExecutionOrder(100)] internal class TurretChargeBehaviour : MonoBehaviour { private CharacterBody body; private CharacterModel model; private Material mat; public bool firing; public float stopwatch = 3f; public bool addstock; private void Awake() { model = ((Component)this).GetComponent(); } private void Start() { body = model.body; UpdateMaterial(); } public void UpdateMaterial() { //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003f: Expected O, but got Unknown //IL_00a5: Unknown result type (might be due to invalid IL or missing references) if (Object.op_Implicit((Object)(object)mat)) { Object.Destroy((Object)(object)mat); } mat = new Material(model.baseRendererInfos[3].defaultMaterial); model.baseRendererInfos[3].defaultMaterial = mat; model.baseRendererInfos[3].renderer.material = mat; if (!Object.op_Implicit((Object)(object)body)) { mat.SetTextureScale("_MainTex", new Vector2(2.07f, 1f)); mat.SetFloat("_EmPower", 2f); } } private void FixedUpdate() { //IL_00f3: Unknown result type (might be due to invalid IL or missing references) if (!Object.op_Implicit((Object)(object)body) || !Object.op_Implicit((Object)(object)model) || !Object.op_Implicit((Object)(object)mat)) { return; } if (firing) { if (stopwatch <= 0f) { stopwatch = 3f; } stopwatch -= Time.fixedDeltaTime; } else { stopwatch = 3f; } GenericSkill primary = body.skillLocator.primary; mat.SetTextureScale("_MainTex", new Vector2(primary.CanExecute() ? 2.07f : (firing ? 2.07f : Util.Remap(Math.Min(1f, primary.rechargeStopwatch / primary.finalRechargeInterval), 0f, 1f, 0.66f, 2.07f)), 1f)); } } [DefaultExecutionOrder(100)] internal class TurretSkinBehaviour : NetworkBehaviour { private CharacterBody body; private CharacterBody ownerBody; private NetworkLoadout networkLoadout; private BodyIndex bodyIndex; private ModelSkinController skinController; private TurretChargeBehaviour chargeBehaviour; private CharacterSelectSurvivorPreviewDisplayController displayController; private CharacterModel characterModel; private Renderer renderer; public Material mat; public bool applySkin = true; public float timer = 0.06f; private float stopwatch; private void Awake() { skinController = ((Component)this).GetComponent(); chargeBehaviour = ((Component)this).GetComponent(); characterModel = ((Component)this).GetComponent(); renderer = characterModel.baseRendererInfos[0].renderer; mat = renderer.material; } private void Start() { //IL_0018: Unknown result type (might be due to invalid IL or missing references) //IL_001d: Unknown result type (might be due to invalid IL or missing references) //IL_0071: Unknown result type (might be due to invalid IL or missing references) //IL_007b: Expected O, but got Unknown //IL_0099: Unknown result type (might be due to invalid IL or missing references) //IL_00a3: Expected O, but got Unknown //IL_00c1: Unknown result type (might be due to invalid IL or missing references) //IL_00cb: Expected O, but got Unknown body = ((Component)this).GetComponent().body; bodyIndex = BodyCatalog.FindBodyIndex("EngiBody"); if (!Object.op_Implicit((Object)(object)body)) { displayController = ((Component)this).GetComponentInParent(); if (Object.op_Implicit((Object)(object)displayController)) { displayController.skinChangeResponses[0].response.AddListener((UnityAction)delegate { UpdateModel(0); }); displayController.skinChangeResponses[1].response.AddListener((UnityAction)delegate { UpdateModel(1); }); displayController.skinChangeResponses[2].response.AddListener((UnityAction)delegate { UpdateModel(2); }); } } else if (Object.op_Implicit((Object)(object)body.master) && Object.op_Implicit((Object)(object)body.master.minionOwnership) && Object.op_Implicit((Object)(object)body.master.minionOwnership.ownerMaster)) { ownerBody = body.master.minionOwnership.ownerMaster.GetBody(); if (Object.op_Implicit((Object)(object)ownerBody)) { body.skinIndex = ownerBody.skinIndex; UpdateModel((int)ownerBody.skinIndex); } } } private void FixedUpdate() { if (Object.op_Implicit((Object)(object)body)) { stopwatch += Time.fixedDeltaTime; if (applySkin && stopwatch >= timer) { applySkin = false; UpdateModel((int)body.skinIndex); } } } private void UpdateModel(int skinIndex) { if (Object.op_Implicit((Object)(object)skinController) && Object.op_Implicit((Object)(object)chargeBehaviour)) { ((Behaviour)skinController.characterModel).enabled = true; skinController.ApplySkin(skinIndex); chargeBehaviour.UpdateMaterial(); } } private void UNetVersion() { } public override bool OnSerialize(NetworkWriter writer, bool forceAll) { bool result = default(bool); return result; } public override void OnDeserialize(NetworkReader reader, bool initialState) { } } internal class TurretSpawner : NetworkBehaviour { private CharacterBody body; private static int kCmdCmdSpawn; private void Awake() { body = ((Component)this).GetComponent(); } [Command] public void CmdSpawn(Vector3 pos, Quaternion rot) { //IL_0001: Unknown result type (might be due to invalid IL or missing references) //IL_0006: Unknown result type (might be due to invalid IL or missing references) //IL_0011: Unknown result type (might be due to invalid IL or missing references) //IL_0012: Unknown result type (might be due to invalid IL or missing references) //IL_0013: Unknown result type (might be due to invalid IL or missing references) //IL_0018: Unknown result type (might be due to invalid IL or missing references) //IL_0019: Unknown result type (might be due to invalid IL or missing references) //IL_001a: Unknown result type (might be due to invalid IL or missing references) //IL_001f: Unknown result type (might be due to invalid IL or missing references) //IL_0030: 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_0048: 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_0076: Unknown result type (might be due to invalid IL or missing references) //IL_0080: Expected O, but got Unknown //IL_008d: Unknown result type (might be due to invalid IL or missing references) //IL_0097: Expected O, but got Unknown //IL_00a4: Unknown result type (might be due to invalid IL or missing references) CharacterMaster val = new MasterSummon { masterPrefab = Prefabs.turretMaster, position = pos, rotation = rot, summonerBodyObject = ((Component)body).gameObject, ignoreTeamMemberLimit = true, inventoryToCopy = body.inventory, teamIndexOverride = body.teamComponent.teamIndex }.Perform(); Deployable val2 = ((Component)val).gameObject.AddComponent(); val2.onUndeploy = new UnityEvent(); val2.onUndeploy.AddListener(new UnityAction(val.TrueKill)); body.master.AddDeployable(val2, Prefabs.bigTurret); } private void UNetVersion() { } protected static void InvokeCmdCmdSpawn(NetworkBehaviour obj, NetworkReader reader) { //IL_001d: Unknown result type (might be due to invalid IL or missing references) //IL_0023: Unknown result type (might be due to invalid IL or missing references) if (!NetworkServer.active) { Debug.LogError((object)"Command CmdSpawn called on client."); } else { ((TurretSpawner)(object)obj).CmdSpawn(reader.ReadVector3(), reader.ReadQuaternion()); } } public void CallCmdSpawn(Vector3 pos, Quaternion rot) { //IL_0031: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Expected O, but got Unknown //IL_005c: 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_0071: 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_0026: Unknown result type (might be due to invalid IL or missing references) if (!NetworkClient.active) { Debug.LogError((object)"Command function CmdSpawn called on server."); return; } if (((NetworkBehaviour)this).isServer) { CmdSpawn(pos, rot); return; } NetworkWriter val = new NetworkWriter(); val.Write((short)0); val.Write((short)5); val.WritePackedUInt32((uint)kCmdCmdSpawn); val.Write(((Component)this).GetComponent().netId); val.Write(pos); val.Write(rot); ((NetworkBehaviour)this).SendCommandInternal(val, 0, "CmdSpawn"); } static TurretSpawner() { //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002a: Expected O, but got Unknown kCmdCmdSpawn = -274844957; NetworkBehaviour.RegisterCommandDelegate(typeof(TurretSpawner), kCmdCmdSpawn, new CmdDelegate(InvokeCmdCmdSpawn)); NetworkCRC.RegisterBehaviour("TurretSpawner", 0); } public override bool OnSerialize(NetworkWriter writer, bool forceAll) { bool result = default(bool); return result; } public override void OnDeserialize(NetworkReader reader, bool initialState) { } } internal class ViendUncorruptAlt : MonoBehaviour { private CharacterBody body; public GenericSkill secondary; public GenericSkill utility; public VoidSurvivorController controller; public bool hasAlt; public bool secondaryAlt; public bool utilityAlt; public float angle = 25f; private void Awake() { body = ((Component)this).GetComponent(); controller = ((Component)this).GetComponent(); } private void Start() { secondary = body.skillLocator.secondary; utility = body.skillLocator.utility; if (secondary.skillNameToken == "AEROS_VIEND_SECONDARY") { hasAlt = true; secondaryAlt = true; } if (utility.skillNameToken == "AEROS_VIEND_UTIL") { hasAlt = true; utilityAlt = true; } } } internal class Hook { internal static void Hooks() { //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_0074: Unknown result type (might be due to invalid IL or missing references) //IL_007e: Expected O, but got Unknown //IL_0086: Unknown result type (might be due to invalid IL or missing references) //IL_0090: Expected O, but got Unknown //IL_0098: Unknown result type (might be due to invalid IL or missing references) //IL_00a2: Expected O, but got Unknown RecalculateStatsAPI.GetStatCoefficients += new StatHookEventHandler(RecalculateStatsAPI_GetStatCoefficients); HealthComponent.TakeDamage += new hook_TakeDamage(HealthComponent_TakeDamage); GenericSkill.SetSkillOverride += new hook_SetSkillOverride(GenericSkill_SetSkillOverride); GenericSkill.UnsetSkillOverride += new hook_UnsetSkillOverride(GenericSkill_UnsetSkillOverride); SeekerController.CmdIncrementChakraGate += new hook_CmdIncrementChakraGate(SeekerController_CmdIncrementChakraGate); BulletAttack.Fire += new hook_Fire(BulletAttack_Fire); CharacterBody.AddTimedBuff_BuffDef_float += new hook_AddTimedBuff_BuffDef_float(CharacterBody_AddTimedBuff_BuffDef_float); DotController.InflictDot_refInflictDotInfo += new hook_InflictDot_refInflictDotInfo(DotController_InflictDot_refInflictDotInfo); CharacterBody.AddBuff_BuffIndex += new hook_AddBuff_BuffIndex(CharacterBody_AddBuff_BuffIndex); } private static void DotController_InflictDot_refInflictDotInfo(orig_InflictDot_refInflictDotInfo orig, ref InflictDotInfo inflictDotInfo) { if (Object.op_Implicit((Object)(object)inflictDotInfo.victimObject)) { CharacterBody component = inflictDotInfo.victimObject.GetComponent(); if (Object.op_Implicit((Object)(object)component) && component.HasBuff(Prefabs.debuffImmune)) { return; } } orig.Invoke(ref inflictDotInfo); } private static void CharacterBody_AddBuff_BuffIndex(orig_AddBuff_BuffIndex orig, CharacterBody self, BuffIndex buffType) { //IL_0001: 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) BuffDef buffDef = BuffCatalog.GetBuffDef(buffType); if (!Object.op_Implicit((Object)(object)self) || !Object.op_Implicit((Object)(object)buffDef) || !buffDef.isDebuff || !self.HasBuff(Prefabs.debuffImmune)) { orig.Invoke(self, buffType); } } private static void CharacterBody_AddTimedBuff_BuffDef_float(orig_AddTimedBuff_BuffDef_float orig, CharacterBody self, BuffDef buffDef, float duration) { if (!Object.op_Implicit((Object)(object)self) || !Object.op_Implicit((Object)(object)buffDef) || !buffDef.isDebuff || !self.HasBuff(Prefabs.debuffImmune)) { orig.Invoke(self, buffDef, duration); } } private static void BulletAttack_Fire(orig_Fire orig, BulletAttack self) { //IL_0002: 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_003c: Unknown result type (might be due to invalid IL or missing references) if (Physics.Raycast(self.origin, self.aimVector, self.maxDistance, 536870912)) { self.damage *= MainPlugin.railgunnerUtilityDamageMult.Value; self.damageColorIndex = (DamageColorIndex)12; } orig.Invoke(self); } private static void SeekerController_CmdIncrementChakraGate(orig_CmdIncrementChakraGate orig, SeekerController self) { orig.Invoke(self); if (Object.op_Implicit((Object)(object)self.specialSkillSlot) && (Object)(object)self.specialSkillSlot.skillDef == (Object)(object)MainPlugin.seekerGenkidama) { self.UnlockGateEffects(self.characterBody.master.seekerChakraGate); } } private static void GenericSkill_UnsetSkillOverride(orig_UnsetSkillOverride orig, GenericSkill self, object source, SkillDef skillDef, SkillOverridePriority priority) { //IL_0018: Unknown result type (might be due to invalid IL or missing references) //IL_001b: Invalid comparison between Unknown and I4 //IL_00ae: Unknown result type (might be due to invalid IL or missing references) //IL_006e: Unknown result type (might be due to invalid IL or missing references) //IL_0070: Unknown result type (might be due to invalid IL or missing references) //IL_0077: Expected O, but got Unknown ViendUncorruptAlt component = ((Component)self).GetComponent(); if (Object.op_Implicit((Object)(object)component) && component.hasAlt && (int)priority == 2) { bool flag = (Object)(object)self == (Object)(object)component.secondary; if ((component.secondaryAlt && flag) || (component.utilityAlt && (Object)(object)self == (Object)(object)component.utility)) { SkillOverride val = new SkillOverride(source, flag ? MainPlugin.viendSecondaryCorrupted : MainPlugin.viendUtilCorrupted, priority); int num = self.FindSkillOverrideIndex(ref val); if (num != -1) { ArrayUtils.ArrayRemoveAtAndResize(ref self.skillOverrides, num, 1); self.PickCurrentOverride(); } return; } } orig.Invoke(self, source, skillDef, priority); } private static void GenericSkill_SetSkillOverride(orig_SetSkillOverride orig, GenericSkill self, object source, SkillDef skillDef, SkillOverridePriority priority) { //IL_0018: Unknown result type (might be due to invalid IL or missing references) //IL_001b: Invalid comparison between Unknown and I4 //IL_00b8: Unknown result type (might be due to invalid IL or missing references) //IL_0080: Unknown result type (might be due to invalid IL or missing references) //IL_0082: Unknown result type (might be due to invalid IL or missing references) //IL_0089: Expected O, but got Unknown ViendUncorruptAlt component = ((Component)self).GetComponent(); if (Object.op_Implicit((Object)(object)component) && component.hasAlt && (int)priority == 2 && component.controller.corruption >= 100f) { bool flag = (Object)(object)self == (Object)(object)component.secondary; if ((component.secondaryAlt && flag) || (component.utilityAlt && (Object)(object)self == (Object)(object)component.utility)) { SkillOverride val = new SkillOverride(source, flag ? MainPlugin.viendSecondaryCorrupted : MainPlugin.viendUtilCorrupted, priority); if (self.FindSkillOverrideIndex(ref val) == -1) { ArrayUtils.ArrayAppend(ref self.skillOverrides, ref val); self.PickCurrentOverride(); } return; } } orig.Invoke(self, source, skillDef, priority); } private static void HealthComponent_TakeDamage(orig_TakeDamage orig, HealthComponent self, DamageInfo damageInfo) { //IL_001c: 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_002b: Unknown result type (might be due to invalid IL or missing references) //IL_0030: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Invalid comparison between Unknown and I4 //IL_0077: Unknown result type (might be due to invalid IL or missing references) //IL_0081: Unknown result type (might be due to invalid IL or missing references) //IL_0097: Unknown result type (might be due to invalid IL or missing references) //IL_009d: Unknown result type (might be due to invalid IL or missing references) //IL_00a2: Unknown result type (might be due to invalid IL or missing references) //IL_00a7: Unknown result type (might be due to invalid IL or missing references) //IL_00c6: Unknown result type (might be due to invalid IL or missing references) //IL_00c8: Unknown result type (might be due to invalid IL or missing references) //IL_0123: Unknown result type (might be due to invalid IL or missing references) //IL_0146: Unknown result type (might be due to invalid IL or missing references) //IL_0150: Unknown result type (might be due to invalid IL or missing references) //IL_0151: Unknown result type (might be due to invalid IL or missing references) //IL_0299: Unknown result type (might be due to invalid IL or missing references) //IL_033b: Unknown result type (might be due to invalid IL or missing references) //IL_0351: Unknown result type (might be due to invalid IL or missing references) //IL_039c: Unknown result type (might be due to invalid IL or missing references) //IL_03b2: Unknown result type (might be due to invalid IL or missing references) //IL_03b4: Unknown result type (might be due to invalid IL or missing references) //IL_02c6: Unknown result type (might be due to invalid IL or missing references) //IL_02cb: Unknown result type (might be due to invalid IL or missing references) //IL_02d2: Unknown result type (might be due to invalid IL or missing references) //IL_02d7: Unknown result type (might be due to invalid IL or missing references) //IL_02dc: Unknown result type (might be due to invalid IL or missing references) //IL_02e9: Unknown result type (might be due to invalid IL or missing references) //IL_0305: Unknown result type (might be due to invalid IL or missing references) //IL_0307: Unknown result type (might be due to invalid IL or missing references) //IL_030c: Unknown result type (might be due to invalid IL or missing references) //IL_0317: Unknown result type (might be due to invalid IL or missing references) //IL_0325: Expected O, but got Unknown //IL_043c: Unknown result type (might be due to invalid IL or missing references) //IL_045d: Unknown result type (might be due to invalid IL or missing references) //IL_046e: Unknown result type (might be due to invalid IL or missing references) //IL_0475: Expected O, but got Unknown //IL_0478: Unknown result type (might be due to invalid IL or missing references) //IL_047d: Unknown result type (might be due to invalid IL or missing references) if (Object.op_Implicit((Object)(object)damageInfo.attacker) && damageInfo.procCoefficient > 0f && (int)DamageTypeCombo.op_Implicit(damageInfo.damageType & DamageTypeCombo.op_Implicit((DamageType)67108864)) != 67108864 && (Object)(object)MainPlugin.banditPassive != (Object)null && self.body.canReceiveBackstab) { CharacterBody component = damageInfo.attacker.GetComponent(); if (Object.op_Implicit((Object)(object)component) && component.bodyIndex == BodyCatalog.FindBodyIndex("Bandit2Body")) { Vector3 val = component.corePosition - damageInfo.position; if (!component.HasBuff(Prefabs.lacerationCD) && (((ProcChainMask)(ref damageInfo.procChainMask)).HasProc((ProcType)17) || (BackstabManager.IsBackstab(-val, self.body) && Object.op_Implicit((Object)(object)Array.Find(damageInfo.attacker.GetComponents(), (GenericSkill x) => (Object)(object)x.skillDef == (Object)(object)MainPlugin.banditPassive))))) { if (((Enum)component.bodyFlags).HasFlag((Enum)(object)(BodyFlags)128)) { component.bodyFlags = (BodyFlags)(component.bodyFlags & -129); component.canPerformBackstab = false; } DotController.InflictDot(((Component)self).gameObject, damageInfo.attacker, damageInfo.inflictedHurtbox, (DotIndex)6, 15f * damageInfo.procCoefficient, 1f, (uint?)2147483647u); component.AddTimedBuff(Prefabs.lacerationCD, 0.05f); } } } if (self.body.HasBuff(Prefabs.multDroneDebuff)) { damageInfo.damage *= MainPlugin.multSecondaryDamageIncrease.Value; } bool flag = Object.op_Implicit((Object)(object)self.body) && self.body.HasBuff(Prefabs.block); float damage = damageInfo.damage; float num = Math.Clamp(MainPlugin.blockAmount.Value, 0.01f, 1f); if (flag) { damageInfo.damage *= 1f - num; } orig.Invoke(self, damageInfo); if (flag) { self.AddBarrier(damage * num); } if (!Object.op_Implicit((Object)(object)damageInfo.attacker) || !(damageInfo.procCoefficient > 0f)) { return; } CharacterBody component2 = damageInfo.attacker.GetComponent(); if (!Object.op_Implicit((Object)(object)component2)) { return; } if (DamageAPI.HasModdedDamageType(damageInfo, Prefabs.crocoSecondaryDamage)) { int num2 = Utils.DebuffCount(self.body); if (num2 > 0) { DamageInfo val2 = new DamageInfo { position = self.body.corePosition, attacker = ((Component)component2).gameObject, damage = component2.damage * MainPlugin.crocoSecondaryAddDamage.Value * (float)num2, damageColorIndex = (DamageColorIndex)5, procCoefficient = 0f, crit = damageInfo.crit }; self.body.healthComponent.TakeDamage(val2); } } if (DamageAPI.HasModdedDamageType(damageInfo, Prefabs.flameSwordHit)) { InflictDotInfo val3 = default(InflictDotInfo); val3.attackerObject = damageInfo.attacker; val3.victimObject = ((Component)self).gameObject; val3.totalDamage = 5.875f * MainPlugin.mageFlameSwordBurnDuration.Value; val3.damageMultiplier = 1f; val3.dotIndex = (DotIndex)1; val3.maxStacksFromAttacker = 2147483647u; InflictDotInfo val4 = val3; StrengthenBurnUtils.CheckDotForUpgrade(component2.inventory, ref val4); DotController.InflictDot(ref val4); } if ((Object)(object)MainPlugin.seekerPassive != (Object)null && Object.op_Implicit((Object)(object)component2) && Object.op_Implicit((Object)(object)((Component)component2).GetComponent()) && Object.op_Implicit((Object)(object)Array.Find(((Component)component2).GetComponents(), (GenericSkill x) => (Object)(object)x.skillDef == (Object)(object)MainPlugin.seekerPassive))) { Utils.ProcSeekerPassive(self.body, component2); } if (DamageAPI.HasModdedDamageType(damageInfo, Prefabs.seekerPrimaryDamage)) { Utils.ProcSeekerPassive(self.body, component2); } if (DamageAPI.HasModdedDamageType(damageInfo, Prefabs.seekerSecondaryDamage)) { HealOrb val5 = new HealOrb(); ((Orb)val5).origin = damageInfo.position; ((Orb)val5).target = component2.mainHurtBox; val5.healValue = component2.healthComponent.fullHealth * (MainPlugin.seekerSecondaryHealPercentage.Value + MainPlugin.seekerSecondaryAddHealPercentage.Value * (float)component2.GetBuffCount(Buffs.ChakraBuff)); val5.overrideDuration = 0.3f; OrbManager.instance.AddOrb((Orb)(object)val5); } } private static void RecalculateStatsAPI_GetStatCoefficients(CharacterBody sender, StatHookEventArgs args) { if (sender.HasBuff(Prefabs.latchBuff)) { args.armorAdd += 200f; } if (sender.HasBuff(Prefabs.multDroneRegenBuff)) { args.baseRegenAdd += sender.healthComponent.fullHealth * MainPlugin.multSecondaryHeal.Value; args.attackSpeedMultAdd += 0.3f; args.damageMultAdd += 0.3f; } if (sender.HasBuff(Prefabs.viendSpeedBuff)) { args.moveSpeedMultAdd += MainPlugin.viendSpeedBuff.Value; } if (sender.HasBuff(Prefabs.block)) { args.moveSpeedReductionMultAdd += MainPlugin.blockSpeedReduction.Value; } if (sender.HasBuff(Prefabs.overclock)) { args.baseRegenAdd += MainPlugin.regen.Value; args.baseAttackSpeedAdd += MainPlugin.atkspd.Value; args.baseMoveSpeedAdd += MainPlugin.movspd.Value; args.allSkills.cooldownMultAdd += 0f - MainPlugin.cooldown.Value; } if (sender.HasBuff(Prefabs.falseSonAuraBuff)) { float num = (float)sender.master.money * 0.01f; args.baseDamageAdd += num; args.armorAdd += num; } } } internal class Language { internal static void AddTranslations() { LanguageAPI.Add("AEROS_MULT_DRONE_NAME", "Ремонтный дрон", "RU"); LanguageAPI.Add("AEROS_CAP_M1", "Вулкан-повторитель", "RU"); LanguageAPI.Add("AEROS_CAP_M1_DESCRIPTION", "Выстреливает быстрой очередью из дробовика 3 раза, наносящей 3x165% урона.", "RU"); LanguageAPI.Add("AEROS_CAP_M2", "Разгон", "RU"); LanguageAPI.Add("AEROS_CAP_M2_DESCRIPTION", "Выстреливает не наносящим урона снарядом, который усиливает ближайших союзников при попадании, давая +5 ОЗ/сек, +0.6 к скорости атаки, +5 к скорости передвижения и 50% сокращение времени перезарядки на 5 секунд.", "RU"); LanguageAPI.Add("AEROS_ENGI_M1", "Искатель", "RU"); LanguageAPI.Add("AEROS_ENGI_M1_DESCRIPTION", "Зарядите до 8 ракет, наносящих 140% урона каждая.", "RU"); LanguageAPI.Add("AEROS_ENGI_SPEC2", "Турель-рельсотрон TR90", "RU"); LanguageAPI.Add("AEROS_ENGI_SPEC", "Турель-рельсотрон TR90", "RU"); LanguageAPI.Add("AEROS_ENGI_SPEC_DESCRIPTION", "Устанавливает турель, которая заряжается в течение 8 секунд и выстреливает, нанося 3000% урона. Использует все ваши предметы.", "RU"); LanguageAPI.Add("AEROS_LOADER_UTIL", "Заряженный град", "RU"); LanguageAPI.Add("AEROS_LOADER_UTIL_DESCRIPTION", "Удерживайте, чтобы ринуться вперёд, нанося 600%-2700% урона, и выполните серию ударов при попадании на 5x350% урона.", "RU"); LanguageAPI.Add("AEROS_LOADER_SPEC", "Блок", "RU"); LanguageAPI.Add("AEROS_LOADER_SPEC_DESCRIPTION", "Примите боевую стойку до 10 секунд, блокируя 50% урона от всего входящего урона. Выпустите вокруг себя взрыв молнии на 450% урона, увеличивающийся в уроне и размере, в зависимости от количества вашего текущего барьера. Даёт неуязвимость на 0.5 секунд после отпускания.", "RU"); LanguageAPI.Add("AEROS_SEEKER_PASSIVE0", "Нет пассивки.", "RU"); LanguageAPI.Add("AEROS_SEEKER_PASSIVE", "Вмешательство души", "RU"); LanguageAPI.Add("AEROS_SEEKER_PASSIVE_DESCRIPTION", "Накладывает вмешательство при попадании. При 3 стаках заставляет врага взорваться на 50% урона.", "RU"); LanguageAPI.Add("AEROS_SEEKER_LOADOUT", "Пассивное", "RU"); LanguageAPI.Add("AEROS_SEEKER_SPEC", "Взрыв душ", "RU"); LanguageAPI.Add("AEROS_SEEKER_SPEC_DESCRIPTION", "Зарядите взрывающуюся сферу души, сосредотачивая свою душу, получая спокойствие, которая наносит 500%-1400% урона.", "RU"); LanguageAPI.Add("AEROS_VIEND_SECONDARY", "『 Б?зд?а 」", "RU"); LanguageAPI.Add("AEROS_VIEND_SECONDARY_DESCRIPTION", "Выпускает дальнобойный луч, наносящий 280% урона в секунду и притягивающий поражённых врагов.", "RU"); LanguageAPI.Add("AEROS_VIEND_SECONDARY_CORRUPT", "『 Б?зд?а 」 осквернённый", "RU"); LanguageAPI.Add("AEROS_VIEND_SECONDARY_DESCRIPTION_CORRUPT", "Выпускает мгновенный дальнобойный луч, наносящий 420% урона. Поражённые враги телепортируются к вам.", "RU"); LanguageAPI.Add("AEROS_VIEND_UTIL", "「 По?груже?ние?? 】", "RU"); LanguageAPI.Add("AEROS_VIEND_UTIL_DESCRIPTION", "Входит в 「 по?руж?н?? 】, становясь неспособным наносить урон врагам и получать урон от них, при этом, получает 5% урона в секунду. Увеличивает урон со временем.", "RU"); LanguageAPI.Add("AEROS_VIEND_UTIL_CORRUPT", "「 По?руж?н?? 】 осквернённый", "RU"); LanguageAPI.Add("AEROS_VIEND_UTIL_DESCRIPTION_CORRUPT", "Получите 40% скорости передвижения. Входит в 「 по?руж?н?? 】, становясь неспособным наносить урон врагам и получать урон от них, при этом, получает 5% урона в секунду. Увеличивает урон со временем.", "RU"); LanguageAPI.Add("AEROS_MAGE_SEC", "Нано-клинок", "RU"); LanguageAPI.Add("AEROS_MAGE_SEC_DESCRIPTION", "Воспламенение. Заряжает пылающий меч, наносящий 1000%-2000% урона. При максимальном заряде, выстреливает пробивающим снарядом.", "RU"); LanguageAPI.Add("AEROS_MAGE_SPEC", "Ледяной выброс", "RU"); LanguageAPI.Add("AEROS_MAGE_SPEC_DESCRIPTION", "Замораживание. Отбрасывает вас в направлении движения, нанося 800% урона ближайшим врагам.", "RU"); LanguageAPI.Add("AEROS_MULT_SEC", "Ремонтный дрон", "RU"); LanguageAPI.Add("AEROS_MULT_SEC_DESCRIPTION", "Получите уникального дрона. Активируйте, чтобы выбрать цель; вражеские цели будут получать увеличенный урон на 30%. Если выбранная цель — дрон-союзник, он будет лечиться на 5 ОЗ/сек и увеличит урон на 30% и скорость атаки. При повторной активации - отменяет действие.", "RU"); LanguageAPI.Add("AEROS_MULT_UTIL", "Режим транспортировки, рывок", "RU"); LanguageAPI.Add("AEROS_MULT_UTIL_DESCRIPTION", "Скользите вперёд на короткое расстояние.", "RU"); LanguageAPI.Add("AEROS_COMMANDO_SPEC", "Снайпер", "RU"); LanguageAPI.Add("AEROS_COMMANDO_SPEC_DESCRIPTION", "Зарядитесь, чтобы выстрелить двумя пробивающими пулями на 2x250%-1200% урона. Выстрел, при максимальном заряде заставляет пули рикошетить в ближайших врагов.", "RU"); LanguageAPI.Add("AEROS_MERC_M1", "Световой меч", "RU"); LanguageAPI.Add("AEROS_MERC_M1_DESCRIPTION", "Режьте впереди себя, нанося 3x110% урона.", "RU"); LanguageAPI.Add("AEROS_MERC_SPEC", "Рассечение", "RU"); LanguageAPI.Add("AEROS_MERC_SPEC_DESCRIPTION", "Рывок вперёд, наносит 200% урона. Если вы попали во врага, вы можете обрушиться вниз на 320% урона и ударить по земле, нанося дополнительные 420% урона.", "RU"); } } [BepInPlugin("com.Dragonyck.AerosSkills", "AerosSkills", "2.5.1")] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [NetworkCompatibility(/*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.*/)] public class MainPlugin : BaseUnityPlugin { public const string MODUID = "com.Dragonyck.AerosSkills"; public const string MODNAME = "AerosSkills"; public const string VERSION = "2.5.1"; public const string MODKEY = "AEROS_"; internal static ConfigFile captainCfg; internal static ConfigEntry enableCap; internal static ConfigEntry enableCapPrimary; internal static ConfigEntry enableCapSecondary; internal static ConfigEntry burstDMG; internal static ConfigEntry radius; internal static ConfigEntry regen; internal static ConfigEntry atkspd; internal static ConfigEntry movspd; internal static ConfigEntry cooldown; internal static ConfigEntry duration; internal static ConfigEntry CD; internal static ConfigFile engiCfg; internal static ConfigEntry enableEngi; internal static ConfigEntry enableEngiPrimary; internal static ConfigEntry enableEngiSpecial; internal static ConfigEntry missileDamageCoefficient; internal static ConfigEntry missileTracking; internal static ConfigEntry turretDamageCoefficient; internal static ConfigFile loaderCfg; internal static ConfigEntry enableLoader; internal static ConfigEntry enableLoaderUtility; internal static ConfigEntry enableLoaderSpecial; internal static ConfigEntry enableLoaderOldSkills; internal static ConfigEntry blockDuration; internal static ConfigEntry blockInvincibilityDuration; internal static ConfigEntry blockSpeedReduction; internal static ConfigEntry blockAmount; internal static ConfigEntry blockAmountOld; internal static ConfigEntry blockWaveDamage; internal static ConfigEntry maxPunchCount; internal static ConfigEntry punchDamageCoefficient; internal static ConfigEntry punchMinDamageCoefficient; internal static ConfigEntry punchMaxDamageCoefficient; internal static ConfigEntry punchChargeTime; internal static ConfigEntry punchVelocity; internal static ConfigEntry punchSpeed; internal static ConfigEntry punchComboBackForce; internal static ConfigEntry punchComboUpForce; internal static ConfigEntry punchComboFirstHitDamageCoefficient; internal static ConfigFile seekerCfg; internal static ConfigEntry enableSeeker; internal static ConfigEntry enableSeekerPassive; internal static ConfigEntry enableSeekerSpecial; internal static ConfigEntry genkidamaBaseDamage; internal static ConfigEntry genkidamaAddDamage; internal static ConfigEntry passiveBaseDamage; internal static ConfigEntry passiveAddDamage; internal static ConfigEntry passiveMaxStacks; internal static ConfigEntry seekerPrimaryDamage; internal static ConfigEntry seekerPrimaryAddDamage; internal static ConfigEntry seekerSecondaryDamage; internal static ConfigEntry seekerSecondaryExplosionDamage; internal static ConfigEntry seekerSecondaryHealPercentage; internal static ConfigEntry seekerSecondaryAddHealPercentage; internal static ConfigEntry seekerSecondaryCooldown; internal static ConfigFile viendCfg; internal static ConfigEntry enableViend; internal static ConfigEntry enableViendSecondary; internal static ConfigEntry enableViendUtility; internal static ConfigEntry viendSpeedBuff; internal static ConfigEntry viendSelfDMG; internal static ConfigEntry beamFireFrequency; internal static ConfigEntry beamDMG; internal static ConfigEntry beamForce; internal static ConfigEntry beamDMGCorrupted; internal static ConfigEntry beamDuration; internal static ConfigFile mageCfg; internal static ConfigEntry enableMage; internal static ConfigEntry enableMageSecondary; internal static ConfigEntry enableMageSpecial; internal static ConfigEntry mageSpecialDamage; internal static ConfigEntry mageFlameSwordMinDamage; internal static ConfigEntry mageFlameSwordMaxDamage; internal static ConfigEntry mageFlameSwordMaxChargeTime; internal static ConfigEntry mageFlameSwordBurnDuration; internal static ConfigFile multCfg; internal static ConfigEntry enableMult; internal static ConfigEntry multUtilitySpeed; internal static ConfigEntry multSecondaryDamage; internal static ConfigEntry multSecondaryDamageIncrease; internal static ConfigEntry multSecondaryHeal; internal static ConfigFile commandoCfg; internal static ConfigEntry enableCommando; internal static ConfigEntry commandoSpecialChargeTime; internal static ConfigEntry commandoSpecialMinDamage; internal static ConfigEntry commandoSpecialMaxDamage; internal static ConfigEntry commandoUtilityDamage; internal static ConfigFile mercCfg; internal static ConfigEntry enableMerc; internal static ConfigEntry mercPrimaryBaseDuration; internal static ConfigEntry mercPrimaryDamage; internal static ConfigEntry mercSpecialDashDamage; internal static ConfigEntry mercSpecialUppercutDamage; internal static ConfigEntry mercSpecialSlamDamage; internal static ConfigEntry mercSpecialSlamImpactDamage; internal static ConfigEntry mercSpecialRecastTime; internal static ConfigFile huntressCfg; internal static ConfigEntry enableHuntress; internal static ConfigEntry huntressSecondaryRadius; internal static ConfigEntry huntressSecondaryDamage; internal static ConfigEntry huntressSpecialDamage; internal static ConfigEntry huntressSpecialRange; internal static ConfigFile railgunnerCfg; internal static ConfigEntry enableRailgunner; internal static ConfigEntry railgunnerUtilityDamageMult; internal static ConfigEntry railgunnerSpecialDamage; internal static ConfigEntry railgunnerSpecialRadius; internal static ConfigEntry railgunnerSpecialLightningRadius; internal static ConfigEntry railgunnerSpecialLightningFireRate; internal static ConfigEntry railgunnerSpecialLightningDamage; internal static ConfigFile falseSonCfg; internal static ConfigEntry enableFalseSon; internal static ConfigEntry falseSonUtilityBarrier; internal static ConfigEntry falseSonUtilityRadius; internal static ConfigEntry falseSonUtilityDuration; internal static ConfigEntry falseSonUtilityBuffMult; internal static ConfigEntry falseSonSpecialDamage; internal static ConfigEntry falseSonSpecialDuration; internal static ConfigEntry falseSonSpecialFinalDuration; internal static ConfigEntry falseSonSpecialFireRate; internal static ConfigEntry falseSonSpecialMaxDistance; internal static ConfigFile banditCfg; internal static ConfigEntry enableBandit; internal static ConfigEntry banditUtilityDamage; internal static ConfigEntry banditUtilityAngle; internal static ConfigFile crocoCfg; internal static ConfigEntry enableCroco; internal static ConfigEntry crocoSecondaryDamage; internal static ConfigEntry crocoSecondaryAddDamage; internal static ConfigEntry crocoSpecialLatchDamage; internal static ConfigEntry crocoSpecialLatchTicks; internal static ConfigEntry crocoSpecialLatchTickDamage; internal static ConfigEntry crocoSpecialTargetDamage; internal static ConfigEntry crocoSpecialExplosionDamage; internal static ConfigEntry crocoSpecialDebuffDuration; internal static BepInPlugin Metadata; internal static string Location; internal static SkillDef banditPassive; internal static SkillDef engiScepter; internal static SkillDef viendSecondary; internal static SkillDef viendSecondaryCorrupted; internal static SkillDef viendUtil; internal static SkillDef viendUtilCorrupted; internal static SkillDef seekerPassive; internal static SkillDef seekerGenkidama; internal static SkillDef seekerSecondary; internal static SkillDef mercSpecial; internal static SkillDef huntressPrimaryOverride; internal static SkillDef railgunnerSpecial; internal static SkillDef railgunnerPrimaryOverride; private void Awake() { //IL_0382: Unknown result type (might be due to invalid IL or missing references) //IL_0389: Expected O, but got Unknown //IL_03c9: Unknown result type (might be due to invalid IL or missing references) //IL_03e9: Unknown result type (might be due to invalid IL or missing references) //IL_03eb: Unknown result type (might be due to invalid IL or missing references) //IL_0406: 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_05e8: Unknown result type (might be due to invalid IL or missing references) //IL_05fc: Unknown result type (might be due to invalid IL or missing references) Location = ((BaseUnityPlugin)this).Info.Location; Metadata = ((BaseUnityPlugin)this).Info.Metadata; CreateConfigs(); Language.AddTranslations(); Assets.PopulateAssets(); Prefabs.CreatePrefabs(); GameObject val = null; SkillLocator val2 = null; if (enableCap.Value) { val = Prefabs.Load("RoR2/Base/Captain/CaptainBody.prefab"); val2 = val.GetComponent(); val.AddComponent(); Prefabs.spreadBloomCurve = Prefabs.Load("RoR2/Base/Commando/CommandoBody.prefab").GetComponent().spreadBloomCurve; if (enableCapPrimary.Value) { CaptainPrimarySetup(val2); } if (enableCapSecondary.Value) { CaptainSecondarySetup(val2); } } if (enableEngi.Value) { val = Prefabs.Load("RoR2/Base/Engi/EngiBody.prefab"); val.AddComponent(); val2 = val.GetComponent(); if (enableEngiPrimary.Value) { EngiPrimarySetup(val2); } if (enableEngiSpecial.Value) { EngiSpecialSetup(val2); } if (ModCompat.AncientScepterEnabled) { ModCompat.AddScepterSupport(); } } if (enableLoader.Value) { val = Prefabs.Load("RoR2/Base/Loader/LoaderBody.prefab"); val2 = val.GetComponent(); if (enableLoaderOldSkills.Value) { if (enableLoaderUtility.Value) { LoaderUtilitySetupOld(val2); } if (enableLoaderSpecial.Value) { LoaderSpecialSetupOld(val2); } } else { LoaderUtilitySetup(val2); LoaderSpecialSetup(val2); } } if (enableSeeker.Value) { val = Prefabs.Load("RoR2/DLC2/Seeker/SeekerBody.prefab"); val.AddComponent().cooldown = seekerSecondaryCooldown.Value; val2 = val.GetComponent(); if (enableSeekerPassive.Value) { SeekerPassiveSetup(val2); } SeekerPrimarySetup(val2); if (enableSeekerSpecial.Value) { SeekerSpecialSetup(val2); } } if (enableViend.Value) { val = Prefabs.Load("RoR2/DLC1/VoidSurvivor/VoidSurvivorBody.prefab"); val.gameObject.AddComponent(); val2 = val.GetComponent(); if (enableViendSecondary.Value) { ViendSecondarySetup(val2); } if (enableViendUtility.Value) { ViendUtilitySetup(val2); } } if (enableMage.Value) { val = Prefabs.Load("RoR2/Base/Mage/MageBody.prefab"); val2 = val.GetComponent(); if (enableMageSecondary.Value) { MageSecondarySetup(val2); } if (enableMageSpecial.Value) { MageSpecialSetup(val2); } } if (enableMult.Value) { val = Prefabs.Load("RoR2/Base/Toolbot/ToolbotBody.prefab"); ((HuntressTracker)val.gameObject.AddComponent()).maxTrackingDistance = 50f; val2 = val.GetComponent(); Utils.NewStateMachine(val.gameObject, "Drone"); NetworkStateMachine component = val.GetComponent(); component.stateMachines = val.GetComponents(); MultSecondarySetup(val2); MultUtilitySetup(val2); } if (enableCommando.Value) { val = Prefabs.Load("RoR2/Base/Commando/CommandoBody.prefab"); val2 = val.GetComponent(); Transform modelTransform = val.GetComponent().modelTransform; ChildLocator component2 = ((Component)modelTransform).GetComponent(); GameObject val3 = new GameObject("MuzzleMuzzle"); val3.transform.parent = ((Component)component2).transform; Array.Resize(ref component2.transformPairs, component2.transformPairs.Length + 1); component2.transformPairs[component2.transformPairs.Length - 1] = new NameTransformPair { name = "MuzzleMuzzle", transform = val3.transform }; Utils.CreateHitbox("AerosDash", modelTransform, new Vector3(5f, 5f, 5f), new Vector3(0f, 1f, 0f)); CommandoUtilitySetup(val2); CommandoSpecialSetup(val2); } if (enableMerc.Value) { val = Prefabs.Load("RoR2/Base/Merc/MercBody.prefab"); val2 = val.GetComponent(); val.AddComponent(); Utils.NewStateMachine(val.gameObject, "SkillOverride"); Utils.NewStateMachine(val.gameObject, "Dash"); NetworkStateMachine component3 = val.GetComponent(); component3.stateMachines = val.GetComponents(); MercPrimarySetup(val2); MercSpecialSetup(val2); } if (enableHuntress.Value) { val = Prefabs.Load("RoR2/Base/Huntress/HuntressBody.prefab"); val2 = val.GetComponent(); HuntressSecondarySetup(val2); HuntressSpecialSetup(val2); } if (enableRailgunner.Value) { val = Prefabs.Load("RoR2/DLC1/Railgunner/RailgunnerBody.prefab"); val2 = val.GetComponent(); RailgunnerUtilitySetup(val2); RailgunnerSpecialSetup(val2); } if (enableFalseSon.Value) { val = Prefabs.Load("RoR2/DLC2/FalseSon/FalseSonBody.prefab"); val2 = val.GetComponent(); Utils.NewStateMachine(val.gameObject, "BuffWard"); NetworkStateMachine component4 = val.GetComponent(); component4.stateMachines = val.GetComponents(); FalseSonUtilitySetup(val2); FalseSonSpecialSetup(val2); } if (enableBandit.Value) { val = Prefabs.Load("RoR2/Base/Bandit2/Bandit2Body.prefab"); val2 = val.GetComponent(); val2.passiveSkill.enabled = false; BanditPassiveSetup(val2); BanditUtilitySetup(val2); } if (enableCroco.Value) { val = Prefabs.Load("RoR2/Base/Croco/CrocoBody.prefab"); val2 = val.GetComponent(); Transform modelTransform2 = val.GetComponent().modelTransform; Utils.CreateHitbox("AerosSlash", modelTransform2, new Vector3(40f, 40f, 55f), new Vector3(0f, 10f, 22f)); CrocoSecondarySetup(val2); CrocoSpecialSetup(val2); } RegisterStates(); Hook.Hooks(); } private void CreateConfigs() { //IL_0011: Unknown result type (might be due to invalid IL or missing references) //IL_001b: Expected O, but got Unknown //IL_0174: Unknown result type (might be due to invalid IL or missing references) //IL_017e: Expected O, but got Unknown //IL_0238: Unknown result type (might be due to invalid IL or missing references) //IL_0242: Expected O, but got Unknown //IL_04aa: Unknown result type (might be due to invalid IL or missing references) //IL_04b4: Expected O, but got Unknown //IL_0685: Unknown result type (might be due to invalid IL or missing references) //IL_068f: Expected O, but got Unknown //IL_07c9: Unknown result type (might be due to invalid IL or missing references) //IL_07d3: Expected O, but got Unknown //IL_08cf: Unknown result type (might be due to invalid IL or missing references) //IL_08d9: Expected O, but got Unknown //IL_0980: Unknown result type (might be due to invalid IL or missing references) //IL_098a: Expected O, but got Unknown //IL_0a31: Unknown result type (might be due to invalid IL or missing references) //IL_0a3b: Expected O, but got Unknown //IL_0b3f: Unknown result type (might be due to invalid IL or missing references) //IL_0b49: Expected O, but got Unknown //IL_0bf0: Unknown result type (might be due to invalid IL or missing references) //IL_0bfa: Expected O, but got Unknown //IL_0cdf: Unknown result type (might be due to invalid IL or missing references) //IL_0ce9: Expected O, but got Unknown //IL_0e2b: Unknown result type (might be due to invalid IL or missing references) //IL_0e35: Expected O, but got Unknown //IL_0e9e: Unknown result type (might be due to invalid IL or missing references) //IL_0ea8: Expected O, but got Unknown captainCfg = new ConfigFile(Paths.ConfigPath + "\\AerosSkills\\Captain.cfg", true); enableCap = captainCfg.Bind("General", "Enable Captain Skills", true, (ConfigDescription)null); enableCapPrimary = captainCfg.Bind("General", "Enable Captain Primary Skill", true, (ConfigDescription)null); enableCapSecondary = captainCfg.Bind("General", "Enable Captain Secondary Skill", true, (ConfigDescription)null); burstDMG = captainCfg.Bind("VulcanRepeater", "Damage Coefficient", 1.65f, (ConfigDescription)null); radius = captainCfg.Bind("Overclock", "Explosion Radius", 12f, (ConfigDescription)null); regen = captainCfg.Bind("Overclock", "Base Health Regen Add", 5f, (ConfigDescription)null); atkspd = captainCfg.Bind("Overclock", "Base Attack Speed Add", 0.6f, (ConfigDescription)null); movspd = captainCfg.Bind("Overclock", "Base Movement Speed Add", 5f, (ConfigDescription)null); cooldown = captainCfg.Bind("Overclock", "Cooldown Reduction Mult", 0.5f, (ConfigDescription)null); duration = captainCfg.Bind("Overclock", "Buff Duration", 5f, (ConfigDescription)null); CD = captainCfg.Bind("Overclock", "Skill Cooldown", 8f, (ConfigDescription)null); engiCfg = new ConfigFile(Paths.ConfigPath + "\\AerosSkills\\Engineer.cfg", true); enableEngi = engiCfg.Bind("General", "Enable Engineer Skills", true, (ConfigDescription)null); enableEngiPrimary = engiCfg.Bind("General", "Enable Engineer Primary Skill", true, (ConfigDescription)null); enableEngiSpecial = engiCfg.Bind("General", "Enable Engineer Special Skill", true, (ConfigDescription)null); missileDamageCoefficient = engiCfg.Bind("Missiles", "Damage Coefficient", 1.4f, (ConfigDescription)null); missileTracking = engiCfg.Bind("Seekers", "Enable Tracking", true, (ConfigDescription)null); turretDamageCoefficient = engiCfg.Bind("TR90 Railgun Turret", "Damage Coefficient", 30f, (ConfigDescription)null); loaderCfg = new ConfigFile(Paths.ConfigPath + "\\AerosSkills\\Loader.cfg", true); enableLoader = loaderCfg.Bind("General", "Enable Loader Skills", true, (ConfigDescription)null); enableLoaderUtility = loaderCfg.Bind("General", "Enable Loader Utility Skill", true, (ConfigDescription)null); enableLoaderSpecial = loaderCfg.Bind("General", "Enable Loader Special Skill", true, (ConfigDescription)null); blockDuration = loaderCfg.Bind("Block", "Duration", 10f, (ConfigDescription)null); blockInvincibilityDuration = loaderCfg.Bind("Block", "Invincibility Duration", 0.5f, (ConfigDescription)null); blockSpeedReduction = loaderCfg.Bind("Block", "Speed Reduction", 0.6f, (ConfigDescription)null); blockAmount = loaderCfg.Bind("Block", "Block Coefficient", 0.5f, (ConfigDescription)null); blockAmountOld = loaderCfg.Bind("Block", "Old Block Coefficient", 0.8f, (ConfigDescription)null); blockWaveDamage = loaderCfg.Bind("Block", "Block Wave Damage Coefficient", 4.5f, (ConfigDescription)null); maxPunchCount = loaderCfg.Bind("Gauntlet Barrage", "Max Punch Count", 5, (ConfigDescription)null); punchMinDamageCoefficient = loaderCfg.Bind("Gauntlet Barrage", "Charge Min Damage Coefficient", 1.7f, (ConfigDescription)null); punchMaxDamageCoefficient = loaderCfg.Bind("Gauntlet Barrage", "Charge Max Damage Coefficient", 5f, (ConfigDescription)null); punchDamageCoefficient = loaderCfg.Bind("Gauntlet Barrage", "Damage Coefficient", 3.5f, (ConfigDescription)null); punchChargeTime = loaderCfg.Bind("Gauntlet Barrage", "Charge Time Required Per Punch", 0.15f, (ConfigDescription)null); punchVelocity = loaderCfg.Bind("Gauntlet Barrage", "Added Velocity After Charge", 5f, (ConfigDescription)null); punchSpeed = loaderCfg.Bind("Gauntlet Barrage", "Swing Duration", 0.2f, (ConfigDescription)null); punchComboBackForce = loaderCfg.Bind("Gauntlet Barrage", "Backwards Force", 4400f, (ConfigDescription)null); punchComboUpForce = loaderCfg.Bind("Gauntlet Barrage", "Upwards Force", 2700f, (ConfigDescription)null); punchComboFirstHitDamageCoefficient = loaderCfg.Bind("Gauntlet Barrage", "First Hit Damage Coefficient", 2f, (ConfigDescription)null); enableLoaderOldSkills = loaderCfg.Bind("General", "Enable Old Skills", false, (ConfigDescription)null); seekerCfg = new ConfigFile(Paths.ConfigPath + "\\AerosSkills\\Seeker.cfg", true); enableSeeker = seekerCfg.Bind("General", "Enable Seeker Skills", true, (ConfigDescription)null); enableSeekerPassive = seekerCfg.Bind("General", "Enable Seeker Old Passive Skill", false, (ConfigDescription)null); enableSeekerSpecial = seekerCfg.Bind("General", "Enable Seeker Special Skill", true, (ConfigDescription)null); genkidamaBaseDamage = seekerCfg.Bind("Soul Detonation", "Base Damage", 5f, (ConfigDescription)null); genkidamaAddDamage = seekerCfg.Bind("Soul Detonation", "Additional Damage Per Tranquility", 2f, (ConfigDescription)null); passiveBaseDamage = seekerCfg.Bind("Soul Stack", "Base Damage", 0.5f, (ConfigDescription)null); passiveAddDamage = seekerCfg.Bind("Soul Stack", "Additional Damage Per Tranquility", 0.3f, (ConfigDescription)null); passiveMaxStacks = seekerCfg.Bind("Soul Stack", "Max Stacks", 3, (ConfigDescription)null); seekerPrimaryDamage = seekerCfg.Bind("Primary", "Damage", 2.5f, (ConfigDescription)null); seekerPrimaryAddDamage = seekerCfg.Bind("Primary", "Additional Damage Per Tranquility", 0.2f, (ConfigDescription)null); seekerSecondaryDamage = seekerCfg.Bind("Secondary", "Palm Travel Damage", 4.5f, (ConfigDescription)null); seekerSecondaryExplosionDamage = seekerCfg.Bind("Secondary", "Center Explosion Damage", 4f, (ConfigDescription)null); seekerSecondaryHealPercentage = seekerCfg.Bind("Secondary", "Heal Max Health Percentage", 0.03f, (ConfigDescription)null); seekerSecondaryAddHealPercentage = seekerCfg.Bind("Secondary", "Additional Heal Per Tranquility", 0.02f, (ConfigDescription)null); seekerSecondaryCooldown = seekerCfg.Bind("Secondary", "Cooldown", 0.5f, (ConfigDescription)null); viendCfg = new ConfigFile(Paths.ConfigPath + "\\AerosSkills\\Viend.cfg", true); enableViend = viendCfg.Bind("General", "Enable Viend Skills", true, (ConfigDescription)null); enableViendSecondary = viendCfg.Bind("General", "Enable Viend Secondary Skill", true, (ConfigDescription)null); enableViendUtility = viendCfg.Bind("General", "Enable Viend Utility Skill", true, (ConfigDescription)null); viendSpeedBuff = viendCfg.Bind("「 Sub?merge?? 】", "Corrupted Speed Mult", 0.4f, (ConfigDescription)null); viendSelfDMG = viendCfg.Bind("「 Sub?merge?? 】", "MaxHP Self Damage Mult", 0.01f, (ConfigDescription)null); beamDuration = viendCfg.Bind("『 P??luck 」", "Max Duration", 3f, (ConfigDescription)null); beamFireFrequency = viendCfg.Bind("『 P??luck 」", "Fire Frequency", 0.25f, (ConfigDescription)null); beamDMG = viendCfg.Bind("『 P??luck 」", "Damage", 0.7f, (ConfigDescription)null); beamForce = viendCfg.Bind("『 P??luck 」", "Pull Force", -1700f, (ConfigDescription)null); beamDMGCorrupted = viendCfg.Bind("『 P??luck 」 Corrupted", "Damage", 4.2f, (ConfigDescription)null); mageCfg = new ConfigFile(Paths.ConfigPath + "\\AerosSkills\\Artificer.cfg", true); enableMage = mageCfg.Bind("General", "Enable Artificer Skills", true, (ConfigDescription)null); enableMageSecondary = mageCfg.Bind("General", "Enable Artificer Secondary Skill", true, (ConfigDescription)null); enableMageSpecial = mageCfg.Bind("General", "Enable Artificer Special Skill", true, (ConfigDescription)null); mageSpecialDamage = mageCfg.Bind("Frigid Outburst", "Damage Coefficient", 8f, (ConfigDescription)null); mageFlameSwordMaxChargeTime = mageCfg.Bind("Conjure Nano-Blade", "Charge Time", 2f, (ConfigDescription)null); mageFlameSwordMinDamage = mageCfg.Bind("Conjure Nano-Blade", "Min Damage Coefficient", 10f, (ConfigDescription)null); mageFlameSwordMaxDamage = mageCfg.Bind("Conjure Nano-Blade", "Max Damage Coefficient", 20f, (ConfigDescription)null); mageFlameSwordBurnDuration = mageCfg.Bind("Conjure Nano-Blade", "Burn Duration", 8f, (ConfigDescription)null); multCfg = new ConfigFile(Paths.ConfigPath + "\\AerosSkills\\MulT.cfg", true); enableMult = multCfg.Bind("General", "Enable Mul-T Skills", true, (ConfigDescription)null); multSecondaryDamage = multCfg.Bind("Secondary", "Drone Nail Damage", 0.2f, (ConfigDescription)null); multSecondaryDamageIncrease = multCfg.Bind("Secondary", "Drone Target Damage Increase", 1.3f, (ConfigDescription)null); multSecondaryHeal = multCfg.Bind("Secondary", "Heal Percentage Per Sec", 0.05f, (ConfigDescription)null); multUtilitySpeed = multCfg.Bind("Utility", "Speed", 85f, (ConfigDescription)null); commandoCfg = new ConfigFile(Paths.ConfigPath + "\\AerosSkills\\Commando.cfg", true); enableCommando = commandoCfg.Bind("General", "Enable Commando Skills", true, (ConfigDescription)null); commandoSpecialChargeTime = commandoCfg.Bind("Special", "Max Charge Time", 1.2f, (ConfigDescription)null); commandoSpecialMinDamage = commandoCfg.Bind("Special", "Min Damage", 2.5f, (ConfigDescription)null); commandoSpecialMaxDamage = commandoCfg.Bind("Special", "Max Damage", 12f, (ConfigDescription)null); commandoUtilityDamage = commandoCfg.Bind("Utility", "Damage", 3.2f, (ConfigDescription)null); mercCfg = new ConfigFile(Paths.ConfigPath + "\\AerosSkills\\Mercenary.cfg", true); enableMerc = mercCfg.Bind("General", "Enable Mercenary Skills", true, (ConfigDescription)null); mercPrimaryBaseDuration = mercCfg.Bind("Primary", "Primary Base Duration", 0.95f, (ConfigDescription)null); mercPrimaryDamage = mercCfg.Bind("Primary", "Damage", 1.1f, (ConfigDescription)null); mercSpecialDashDamage = mercCfg.Bind("Special", "Dash Damage", 2f, (ConfigDescription)null); mercSpecialUppercutDamage = mercCfg.Bind("Special", "Uppercut Damage", 2.8f, (ConfigDescription)null); mercSpecialSlamDamage = mercCfg.Bind("Special", "Slam Damage", 3.2f, (ConfigDescription)null); mercSpecialSlamImpactDamage = mercCfg.Bind("Special", "Slam Impact Damage", 4.2f, (ConfigDescription)null); mercSpecialRecastTime = mercCfg.Bind("Special", "Recast Time", 2f, (ConfigDescription)null); huntressCfg = new ConfigFile(Paths.ConfigPath + "\\AerosSkills\\Huntress.cfg", true); enableHuntress = huntressCfg.Bind("General", "Enable Huntress Skills", true, (ConfigDescription)null); huntressSecondaryRadius = huntressCfg.Bind("Cyclone Glaive", "Radius", 20f, (ConfigDescription)null); huntressSecondaryDamage = huntressCfg.Bind("Cyclone Glaive", "Damage Coefficient", 3.75f, (ConfigDescription)null); huntressSpecialDamage = huntressCfg.Bind("Warp Shot", "Damage Coefficient", 11f, (ConfigDescription)null); huntressSpecialRange = huntressCfg.Bind("Warp Shot", "Range", 120f, (ConfigDescription)null); railgunnerCfg = new ConfigFile(Paths.ConfigPath + "\\AerosSkills\\Railgunner.cfg", true); enableRailgunner = railgunnerCfg.Bind("General", "Enable Railgunner Skills", true, (ConfigDescription)null); railgunnerUtilityDamageMult = railgunnerCfg.Bind("Augmentation Screen Device", "Damage Mult", 1.5f, (ConfigDescription)null); railgunnerSpecialDamage = railgunnerCfg.Bind("Electrocharge", "Damage Coefficient", 30f, (ConfigDescription)null); railgunnerSpecialRadius = railgunnerCfg.Bind("Electrocharge", "Impact Radius", 15f, (ConfigDescription)null); railgunnerSpecialLightningRadius = railgunnerCfg.Bind("Electrocharge", "Lightning Radius", 15f, (ConfigDescription)null); railgunnerSpecialLightningDamage = railgunnerCfg.Bind("Electrocharge", "Lightning Damage", 2f, (ConfigDescription)null); railgunnerSpecialLightningFireRate = railgunnerCfg.Bind("Electrocharge", "Lightning Fire Rate", 0.25f, (ConfigDescription)null); falseSonCfg = new ConfigFile(Paths.ConfigPath + "\\AerosSkills\\FalseSon.cfg", true); enableFalseSon = falseSonCfg.Bind("General", "Enable FalseSon Skills", true, (ConfigDescription)null); falseSonUtilityDuration = falseSonCfg.Bind("Sororal Embrace", "Duration", 1.5f, (ConfigDescription)null); falseSonUtilityBarrier = falseSonCfg.Bind("Sororal Embrace", "Health Percentage Barrier Per Sec", 0.2f, (ConfigDescription)null); falseSonUtilityRadius = falseSonCfg.Bind("Sororal Embrace", "Radius", 8f, (ConfigDescription)null); falseSonUtilityBuffMult = falseSonCfg.Bind("Sororal Embrace", "Money Multiplier", 0.01f, (ConfigDescription)null); falseSonSpecialDamage = falseSonCfg.Bind("Crown of the Father", "Damage Per Sec Per Laser", 0.25f, (ConfigDescription)null); falseSonSpecialDuration = falseSonCfg.Bind("Crown of the Father", "Duration", 4f, (ConfigDescription)null); falseSonSpecialFinalDuration = falseSonCfg.Bind("Crown of the Father", "Final Laser Burst Duration", 3.5f, (ConfigDescription)null); falseSonSpecialFireRate = falseSonCfg.Bind("Crown of the Father", "Fire Rate", 0.25f, (ConfigDescription)null); falseSonSpecialMaxDistance = falseSonCfg.Bind("Crown of the Father", "Max Distance", 120f, (ConfigDescription)null); banditCfg = new ConfigFile(Paths.ConfigPath + "\\AerosSkills\\Bandit.cfg", true); enableBandit = banditCfg.Bind("General", "Enable Bandit Skills", true, (ConfigDescription)null); banditUtilityDamage = banditCfg.Bind("Utility", "Damage", 2.5f, (ConfigDescription)null); banditUtilityAngle = banditCfg.Bind("Utility", "Backjump Angle", 30f, (ConfigDescription)null); crocoCfg = new ConfigFile(Paths.ConfigPath + "\\AerosSkills\\Acrid.cfg", true); enableCroco = crocoCfg.Bind("General", "Enable Acrid Skills", true, (ConfigDescription)null); crocoSecondaryDamage = crocoCfg.Bind("Secondary", "Damage", 4.5f, (ConfigDescription)null); crocoSecondaryAddDamage = crocoCfg.Bind("Secondary", "Additional Damage Per Debuff", 0.5f, (ConfigDescription)null); crocoSpecialLatchDamage = crocoCfg.Bind("Special", "Latch Damage", 4f, (ConfigDescription)null); crocoSpecialLatchTicks = crocoCfg.Bind("Special", "Latch Ticks Per Second", 2f, (ConfigDescription)null); crocoSpecialLatchTickDamage = crocoCfg.Bind("Special", "Latch Tick Damage Coefficient", 0.5f, (ConfigDescription)null); crocoSpecialTargetDamage = crocoCfg.Bind("Special", "Target Damage", 6.5f, (ConfigDescription)null); crocoSpecialExplosionDamage = crocoCfg.Bind("Special", "Explosion Damage", 2f, (ConfigDescription)null); crocoSpecialDebuffDuration = crocoCfg.Bind("Special", "Debuff Duration", 8f, (ConfigDescription)null); } private void RegisterStates() { //IL_0003: Unknown result type (might be due to invalid IL or missing references) //IL_000b: Unknown result type (might be due to invalid IL or missing references) //IL_0013: Unknown result type (might be due to invalid IL or missing references) //IL_001b: Unknown result type (might be due to invalid IL or missing references) //IL_0023: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Unknown result type (might be due to invalid IL or missing references) //IL_003b: 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_004b: 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_005b: Unknown result type (might be due to invalid IL or missing references) //IL_0063: Unknown result type (might be due to invalid IL or missing references) //IL_006b: Unknown result type (might be due to invalid IL or missing references) //IL_0073: Unknown result type (might be due to invalid IL or missing references) //IL_007b: Unknown result type (might be due to invalid IL or missing references) //IL_0083: Unknown result type (might be due to invalid IL or missing references) //IL_008b: Unknown result type (might be due to invalid IL or missing references) //IL_0093: Unknown result type (might be due to invalid IL or missing references) //IL_009b: Unknown result type (might be due to invalid IL or missing references) //IL_00a3: Unknown result type (might be due to invalid IL or missing references) //IL_00ab: Unknown result type (might be due to invalid IL or missing references) //IL_00b3: Unknown result type (might be due to invalid IL or missing references) //IL_00bb: Unknown result type (might be due to invalid IL or missing references) //IL_00c3: 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_00db: Unknown result type (might be due to invalid IL or missing references) //IL_00e3: Unknown result type (might be due to invalid IL or missing references) //IL_00eb: Unknown result type (might be due to invalid IL or missing references) //IL_00f3: Unknown result type (might be due to invalid IL or missing references) //IL_00fb: Unknown result type (might be due to invalid IL or missing references) //IL_0103: Unknown result type (might be due to invalid IL or missing references) //IL_010b: Unknown result type (might be due to invalid IL or missing references) //IL_0113: Unknown result type (might be due to invalid IL or missing references) //IL_011b: 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_012b: Unknown result type (might be due to invalid IL or missing references) //IL_0133: Unknown result type (might be due to invalid IL or missing references) //IL_013b: 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_014b: Unknown result type (might be due to invalid IL or missing references) //IL_0153: Unknown result type (might be due to invalid IL or missing references) //IL_015b: Unknown result type (might be due to invalid IL or missing references) //IL_0163: 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_0173: Unknown result type (might be due to invalid IL or missing references) //IL_017b: Unknown result type (might be due to invalid IL or missing references) //IL_0183: Unknown result type (might be due to invalid IL or missing references) //IL_018b: Unknown result type (might be due to invalid IL or missing references) //IL_0193: Unknown result type (might be due to invalid IL or missing references) //IL_019b: Unknown result type (might be due to invalid IL or missing references) //IL_01a3: Unknown result type (might be due to invalid IL or missing references) //IL_01ab: Unknown result type (might be due to invalid IL or missing references) //IL_01b3: Unknown result type (might be due to invalid IL or missing references) //IL_01bb: Unknown result type (might be due to invalid IL or missing references) //IL_01c3: Unknown result type (might be due to invalid IL or missing references) bool flag = default(bool); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); ContentAddition.AddEntityState(ref flag); } internal static void CrocoSecondarySetup(SkillLocator skillLocator) { string text = "CROCO_M2"; LanguageAPI.Add("AEROS_" + text, "Exacerbate"); LanguageAPI.Add("AEROS_" + text + "_DESCRIPTION", "Tear through an enemy for " + crocoSecondaryDamage.Value * 100f + "% damage, dealing an additional " + crocoSecondaryAddDamage.Value * 100f + "% damage for every debuff the enemy has."); SkillDef skillDef = Utils.NewSkillDef(typeof(CrocoSecondary), "Weapon", 1, 5f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: false, (InterruptPriority)2, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: false, 1, 1, 1, Assets.MainAssetBundle.LoadAsset("crocoSecondary"), "AEROS_" + text + "_DESCRIPTION", "AEROS_" + text, Array.Empty()); Utils.AddAlt(skillLocator.secondary._skillFamily, skillDef); } internal static void CrocoSpecialSetup(SkillLocator skillLocator) { string text = "CROCO_SPEC"; LanguageAPI.Add("AEROS_" + text, "Latch"); LanguageAPI.Add("AEROS_" + text + "_DESCRIPTION", "Leap in the air, dealing " + crocoSpecialLatchDamage.Value * 100f + "% damage and latching to the first enemy on contact for up to 5s. Activating the ability or after the duration, deal " + crocoSpecialTargetDamage.Value * 100f + "% damage to the latched target, and explode dealing " + crocoSpecialExplosionDamage.Value * 100f + "% damage to nearby targets and inflicting them with the same debuffs the latched target had."); SkillDef skillDef = Utils.NewSkillDef(typeof(CrocoSpecial), "Body", 1, 10f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: false, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: false, 1, 1, 1, Assets.MainAssetBundle.LoadAsset("crocoSpecial"), "AEROS_" + text + "_DESCRIPTION", "AEROS_" + text, Array.Empty()); Utils.AddAlt(skillLocator.special._skillFamily, skillDef); } private void BanditPassiveSetup(SkillLocator skillLocator) { LanguageAPI.Add("AEROS_BANDIT_PASSIVE", "Laceration"); LanguageAPI.Add("AEROS_BANDIT_PASSIVE_DESCRIPTION", "All attacks from behind inflict hemorrhage."); LanguageAPI.Add("AEROS_BANDIT_LOADOUT", "Passive"); SkillDef skill = Utils.NewSkillDef(typeof(Idle), "Weapon", 0, 0f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: true, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: true, 0, 0, 0, skillLocator.passiveSkill.icon, "BANDIT2_PASSIVE_DESCRIPTION", "BANDIT2_PASSIVE_NAME", Array.Empty()); GenericSkill val = Utils.NewGenericSkill(((Component)skillLocator).gameObject, skill); SkillsAPI.SetOrderPriority(val, -1); SkillsAPI.SetLoadoutTitleTokenOverride(val, "AEROS_BANDIT_LOADOUT"); skill = Utils.NewSkillDef(typeof(Idle), "Weapon", 0, 0f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: true, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: true, 0, 0, 0, Assets.MainAssetBundle.LoadAsset("banditpassive"), "AEROS_BANDIT_PASSIVE_DESCRIPTION", "AEROS_BANDIT_PASSIVE", new string[1] { "KEYWORD_SUPERBLEED" }); Utils.AddAlt(val.skillFamily, skill); banditPassive = skill; } internal static void BanditUtilitySetup(SkillLocator skillLocator) { string text = "BANDIT_UTIL"; LanguageAPI.Add("AEROS_" + text, "Concussion Grenade"); LanguageAPI.Add("AEROS_" + text + "_DESCRIPTION", "Stunning. Jump backwards then throw a grenade that explodes for " + banditUtilityDamage.Value * 100f + "% damage."); SkillDef skillDef = Utils.NewSkillDef(typeof(BanditUtility), "Weapon", 1, 4f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: false, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: false, 1, 1, 1, Assets.MainAssetBundle.LoadAsset("banditUtility"), "AEROS_" + text + "_DESCRIPTION", "AEROS_" + text, new string[1] { "KEYWORD_STUNNING" }); Utils.AddAlt(skillLocator.utility._skillFamily, skillDef); } internal static void FalseSonUtilitySetup(SkillLocator skillLocator) { string text = "FALSESON_UTIL"; LanguageAPI.Add("AEROS_" + text, "Sororal Embrace"); LanguageAPI.Add("AEROS_" + text + "_DESCRIPTION", "Release a cleansing aura around you for 1s, granting all nearby allies " + falseSonUtilityBarrier.Value * 100f + "% barrier and cleanses all negative effects. Triple your passive's benefits for 4s. Additionally, grants " + falseSonUtilityBuffMult.Value * 100f + "% of your gold as bonus damage and armor."); SkillDef skillDef = Utils.NewSkillDef(typeof(FalseSonUtility), "BuffWard", 1, 8f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: false, (InterruptPriority)1, isCombatSkill: false, mustKeyPress: true, cancelSprintingOnActivation: false, 1, 1, 1, Assets.MainAssetBundle.LoadAsset("falseSonUtility"), "AEROS_" + text + "_DESCRIPTION", "AEROS_" + text, Array.Empty()); Utils.AddAlt(skillLocator.utility._skillFamily, skillDef); } internal static void FalseSonSpecialSetup(SkillLocator skillLocator) { string text = "FALSESON_SPEC"; LanguageAPI.Add("AEROS_" + text, "Crown of the Father"); LanguageAPI.Add("AEROS_" + text + "_DESCRIPTION", "Charge up 10 piercing lasers firing at random directions, dealing 10x" + falseSonSpecialDamage.Value * 100f + "% damage per second. Near the end of its duration, they center in the aim direction for a an additional " + falseSonSpecialFinalDuration.Value + "s."); SkillDef skillDef = Utils.NewSkillDef(typeof(FalseSonSpecial), "Weapon", 1, 20f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: false, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: true, 1, 1, 1, Assets.MainAssetBundle.LoadAsset("falseSOnSpecial"), "AEROS_" + text + "_DESCRIPTION", "AEROS_" + text, Array.Empty()); Utils.AddAlt(skillLocator.special._skillFamily, skillDef); } internal static void RailgunnerUtilitySetup(SkillLocator skillLocator) { string text = "RAILGUNNER_UTIL"; LanguageAPI.Add("AEROS_" + text, "Augmentation Screen Device"); LanguageAPI.Add("AEROS_" + text + "_DESCRIPTION", "Throw out a device that projects a hologram. Any projectiles that go through it, have their damage multiplied by " + railgunnerUtilityDamageMult.Value * 100f + "%."); SkillDef skillDef = Utils.NewSkillDef(typeof(RailgunnerUtility), "Weapon", 1, 15f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: false, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: false, 1, 1, 1, Assets.MainAssetBundle.LoadAsset("railgunnerUtility"), "AEROS_" + text + "_DESCRIPTION", "AEROS_" + text, Array.Empty()); Utils.AddAlt(skillLocator.utility._skillFamily, skillDef); } internal static void RailgunnerSpecialSetup(SkillLocator skillLocator) { string text = "RAILGUNNER_SPEC"; LanguageAPI.Add("AEROS_" + text, "Electrocharge"); LanguageAPI.Add("AEROS_" + text + "_DESCRIPTION", "During charge, zap nearby enemies for " + railgunnerSpecialLightningDamage.Value * 100f + "% damage. Fire a detonating round for " + railgunnerSpecialDamage.Value * 100f + "% damage. Afterwards, all your weapons are disabled for 5 seconds."); railgunnerSpecial = Utils.NewSkillDef(typeof(RailgunnerSpecial), "Weapon", 1, 15f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: false, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: true, 1, 1, 1, Assets.MainAssetBundle.LoadAsset("railgunnerSpecial"), "AEROS_" + text + "_DESCRIPTION", "AEROS_" + text, Array.Empty()); Utils.AddAlt(skillLocator.special._skillFamily, railgunnerSpecial); text = "RAILGUNNER_SPEC_PRIMARY"; LanguageAPI.Add("AEROS_" + text, "Electrocharged Railgun"); LanguageAPI.Add("AEROS_" + text + "_DESCRIPTION", "Launch a super-energized projectile for " + railgunnerSpecialDamage.Value * 100f + "% damage."); railgunnerPrimaryOverride = Utils.NewSkillDef(typeof(RailgunnerSpecialFire), "Weapon", 1, 0f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: true, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: true, 0, 1, 1, Assets.MainAssetBundle.LoadAsset("railgunnerSpecialFire"), "AEROS_" + text + "_DESCRIPTION", "AEROS_" + text, Array.Empty()); } internal static void HuntressSecondarySetup(SkillLocator skillLocator) { string text = "HUNTRESS_M2"; LanguageAPI.Add("AEROS_" + text, "Cyclone Glaive"); LanguageAPI.Add("AEROS_" + text + "_DESCRIPTION", "Throw a glaive that draws enemies to its center, dealing " + huntressSecondaryDamage.Value * 100f + "% damage per second. It detonates at the end of its duration, dealing " + huntressSecondaryDamage.Value * 100f + "% damage."); SkillDef skillDef = Utils.NewSkillDef(typeof(HuntressSecondary), "Weapon", 1, 7f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: false, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: false, 1, 1, 1, Assets.MainAssetBundle.LoadAsset("huntressSecondary"), "AEROS_" + text + "_DESCRIPTION", "AEROS_" + text, Array.Empty()); Utils.AddAlt(skillLocator.secondary._skillFamily, skillDef); } internal static void HuntressSpecialSetup(SkillLocator skillLocator) { string text = "HUNTRESS_SPEC"; LanguageAPI.Add("AEROS_" + text, "Warp Shot"); LanguageAPI.Add("AEROS_" + text + "_DESCRIPTION", "Teleport backwards into the sky. Target an area to fire an energy bolt, teleporting to it's impact location, and detonating in a large area for " + huntressSpecialDamage.Value * 100f + "% damage."); SkillDef skillDef = Utils.NewSkillDef(typeof(HuntressSpecial), "Body", 1, 12f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: false, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: false, 1, 1, 1, Assets.MainAssetBundle.LoadAsset("huntressSpecial"), "AEROS_" + text + "_DESCRIPTION", "AEROS_" + text, Array.Empty()); Utils.AddAlt(skillLocator.special._skillFamily, skillDef); text = "HUNTRESS_SPEC"; LanguageAPI.Add("AEROS_" + text, "Warp Shot"); LanguageAPI.Add("AEROS_" + text + "_DESCRIPTION", "Target an area to fire an energy bolt, teleporting to it's impact location, and detonating in a large area for " + huntressSpecialDamage.Value * 100f + "% damage."); huntressPrimaryOverride = Utils.NewSkillDef(typeof(HuntressSpecialFire), "Weapon", 1, 0f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: true, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: true, 0, 1, 1, Assets.MainAssetBundle.LoadAsset("huntressSpecialFire"), "AEROS_" + text + "_DESCRIPTION", "AEROS_" + text, Array.Empty()); } private void MercPrimarySetup(SkillLocator skillLocator) { LanguageAPI.Add("AEROS_MERC_M1", "Beam Sword"); LanguageAPI.Add("AEROS_MERC_M1_DESCRIPTION", "Agile. Slice in front for 3x" + mercPrimaryDamage.Value * 100f + "% damage."); SkillDef skillDef = Utils.NewSkillDef(typeof(MercPrimary), "Weapon", 0, 0f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: true, (InterruptPriority)0, isCombatSkill: true, mustKeyPress: false, cancelSprintingOnActivation: false, 0, 0, 0, Assets.MainAssetBundle.LoadAsset("mercPrimary"), "AEROS_MERC_M1_DESCRIPTION", "AEROS_MERC_M1", Array.Empty()); Utils.AddAlt(skillLocator.primary._skillFamily, skillDef); } private void MercSpecialSetup(SkillLocator skillLocator) { LanguageAPI.Add("AEROS_MERC_SPEC", "Rend"); LanguageAPI.Add("AEROS_MERC_SPEC_DESCRIPTION", "Dash forward, dealing " + mercSpecialDashDamage.Value * 100f + "% damage. If you hit an enemy, you can plunge for " + mercSpecialSlamDamage.Value * 100f + "% damage, and slam the ground on impact for an additional " + mercSpecialSlamImpactDamage.Value * 100f + "% damage."); SkillDef skillDef = Utils.NewSkillDef(typeof(MercSpecial), "Dash", 1, 8f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: false, (InterruptPriority)0, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: false, 1, 1, 1, Assets.MainAssetBundle.LoadAsset("mercSpecial"), "AEROS_MERC_SPEC_DESCRIPTION", "AEROS_MERC_SPEC", Array.Empty()); Utils.AddAlt(skillLocator.special._skillFamily, skillDef); mercSpecial = Utils.NewSkillDef(typeof(MercSpecialSlam), "Weapon", 1, 8f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: true, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: false, 1, 1, 1, Assets.MainAssetBundle.LoadAsset("mercSpecial2"), "AEROS_MERC_SPEC_DESCRIPTION", "AEROS_MERC_SPEC", Array.Empty()); } internal static void CommandoUtilitySetup(SkillLocator skillLocator) { string text = "COMMANDO_UTIL"; LanguageAPI.Add("AEROS_" + text, "Bullet Dash"); LanguageAPI.Add("AEROS_" + text + "_DESCRIPTION", "Dash forward, becoming invulnerable, ramming the first nearby enemy for " + commandoUtilityDamage.Value * 100f + "% damage."); SkillDef skillDef = Utils.NewSkillDef(typeof(CommandoUtility), "Body", 3, 5f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: false, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: false, 1, 1, 1, Assets.MainAssetBundle.LoadAsset("commandoUtility"), "AEROS_" + text + "_DESCRIPTION", "AEROS_" + text, Array.Empty()); Utils.AddAlt(skillLocator.utility._skillFamily, skillDef); } private void CommandoSpecialSetup(SkillLocator skillLocator) { LanguageAPI.Add("AEROS_COMMANDO_SPEC", "Sharpshooter"); LanguageAPI.Add("AEROS_COMMANDO_SPEC_DESCRIPTION", "Charge up to shoot two piercing bullets for 2x" + commandoSpecialMinDamage.Value * 100f + "%-" + commandoSpecialMaxDamage.Value * 100f + "% damage. Firing at max charge causes the bullets to ricochet towards the nearby enemies."); SkillDef skillDef = Utils.NewSkillDef(typeof(CommandoSpecial), "Weapon", 1, 8f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: true, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: true, 1, 1, 1, Assets.MainAssetBundle.LoadAsset("commandoSpecial"), "AEROS_COMMANDO_SPEC_DESCRIPTION", "AEROS_COMMANDO_SPEC", Array.Empty()); Utils.AddAlt(skillLocator.special._skillFamily, skillDef); } private void MultSecondarySetup(SkillLocator skillLocator) { LanguageAPI.Add("AEROS_MULT_SEC", "Repair Drone"); LanguageAPI.Add("AEROS_MULT_SEC_DESCRIPTION", "Gain a unique drone. Activate to select a target, enemy targets will take an increased " + (multSecondaryDamageIncrease.Value - 1f) * 100f + "% damage. If the selected target is an ally drone, it will heal " + multSecondaryHeal.Value * 100f + "% health per second, gain 30% damage and attack speed, and share items. Activate again to disengage."); SkillDef skillDef = Utils.NewSkillDef(typeof(MultSecondary), "Drone", 1, 1f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: true, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: false, 1, 1, 1, Assets.MainAssetBundle.LoadAsset("multSecondary"), "AEROS_MULT_SEC_DESCRIPTION", "AEROS_MULT_SEC", Array.Empty()); Utils.AddAlt(skillLocator.secondary._skillFamily, skillDef); } private void MultUtilitySetup(SkillLocator skillLocator) { LanguageAPI.Add("AEROS_MULT_UTIL", "Transport Mode: Burst"); LanguageAPI.Add("AEROS_MULT_UTIL_DESCRIPTION", "Slide forward for a short distance, gaining 200 armor."); SkillDef skillDef = Utils.NewSkillDef(typeof(MultUtility), "Body", 4, 4f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: true, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: false, 1, 1, 1, Prefabs.Load("RoR2/Base/Commando/CommandoBodyRoll.asset").icon, "AEROS_MULT_UTIL_DESCRIPTION", "AEROS_MULT_UTIL", Array.Empty()); Utils.AddAlt(skillLocator.utility._skillFamily, skillDef); } private void MageSecondarySetup(SkillLocator skillLocator) { LanguageAPI.Add("AEROS_MAGE_SEC", "Conjure Nano-Blade"); LanguageAPI.Add("AEROS_MAGE_SEC_DESCRIPTION", "Ignite. Charge up a flaming sword that deals " + mageFlameSwordMinDamage.Value * 100f + "%-" + mageFlameSwordMaxDamage.Value * 100f + "% damage. At max charge, fire a piercing projectile instead."); SkillDef skillDef = Utils.NewSkillDef(typeof(FireSwordCharge), "Weapon", 1, 5f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: true, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: true, 1, 1, 1, Assets.MainAssetBundle.LoadAsset("mageSecondary"), "AEROS_MAGE_SEC_DESCRIPTION", "AEROS_MAGE_SEC", Array.Empty()); Utils.AddAlt(skillLocator.secondary._skillFamily, skillDef); } private void MageSpecialSetup(SkillLocator skillLocator) { LanguageAPI.Add("AEROS_MAGE_SPEC", "Frigid Outburst"); LanguageAPI.Add("AEROS_MAGE_SPEC_DESCRIPTION", "Freezing. Launches you in the direction you are moving, dealing " + mageSpecialDamage.Value * 100f + "% damage to nearby enemies."); SkillDef skillDef = Utils.NewSkillDef(typeof(MageSpecial), "Body", 1, 12f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: true, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: true, 1, 1, 1, Assets.MainAssetBundle.LoadAsset("mageSpecial"), "AEROS_MAGE_SPEC_DESCRIPTION", "AEROS_MAGE_SPEC", Array.Empty()); Utils.AddAlt(skillLocator.special._skillFamily, skillDef); } private void LoaderUtilitySetup(SkillLocator skillLocator) { LanguageAPI.Add("AEROS_LOADER_UTIL", "Gauntlet Barrage"); LanguageAPI.Add("AEROS_LOADER_UTIL_DESCRIPTION", "Charge up to dash forward, dealing " + punchMinDamageCoefficient.Value * 100f + "%-" + punchMaxDamageCoefficient.Value * 100f + "% damage and perform a series of punches on hit for 5x" + punchDamageCoefficient.Value * 100f + "% damage."); SkillDef skillDef = Utils.NewSkillDef(typeof(ChargeFist), "Weapon", 1, 8f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: true, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: true, 1, 1, 1, Assets.MainAssetBundle.LoadAsset("loaderutility"), "AEROS_LOADER_UTIL_DESCRIPTION", "AEROS_LOADER_UTIL", Array.Empty()); Utils.AddAlt(skillLocator.utility._skillFamily, skillDef); } private void LoaderSpecialSetup(SkillLocator skillLocator) { LanguageAPI.Add("AEROS_LOADER_SPEC", "Block"); LanguageAPI.Add("AEROS_LOADER_SPEC_DESCRIPTION", "Enter a block stance for up to " + blockDuration.Value + "s, blocking " + blockAmount.Value * 100f + "% damage of all incoming damage. Release a lightning explosion around you for " + blockWaveDamage.Value * 100f + "% damage, increasing in damage and size based on the amount of barrier you currently have. Grants invincibility for 0.5s after releasing."); SkillDef skillDef = Utils.NewSkillDef(typeof(Block), "Weapon", 1, 8f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: true, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: true, 1, 1, 1, Assets.MainAssetBundle.LoadAsset("loaderspecial"), "AEROS_LOADER_SPEC_DESCRIPTION", "AEROS_LOADER_SPEC", Array.Empty()); Utils.AddAlt(skillLocator.special._skillFamily, skillDef); } private void LoaderUtilitySetupOld(SkillLocator skillLocator) { LanguageAPI.Add("AEROS_LOADER_UTIL", "Charged Barrage"); LanguageAPI.Add("AEROS_LOADER_UTIL_DESCRIPTION", "Charge up to perform a series of punches for " + punchDamageCoefficient.Value * 100f + "% damage each, increasing in count with charge time."); SkillDef skillDef = Utils.NewSkillDef(typeof(ChargePunchesOld), "Weapon", 1, 8f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: true, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: true, 1, 1, 1, Assets.MainAssetBundle.LoadAsset("loaderutility"), "AEROS_LOADER_UTIL_DESCRIPTION", "AEROS_LOADER_UTIL", Array.Empty()); Utils.AddAlt(skillLocator.utility._skillFamily, skillDef); } private void LoaderSpecialSetupOld(SkillLocator skillLocator) { LanguageAPI.Add("AEROS_LOADER_SPEC", "Block"); LanguageAPI.Add("AEROS_LOADER_SPEC_DESCRIPTION", "Enter a block stance for up to " + blockDuration.Value + "s, blocking " + blockAmountOld.Value * 100f + "% damage of all incoming damage and turning it into barrier. Finishes by consuming all barrier and releasing a lightning wave for " + blockWaveDamage.Value * 100f + "% damage, increasing in damage and size based on the amount of barrier consumed."); SkillDef skillDef = Utils.NewSkillDef(typeof(BlockOld), "Weapon", 1, 8f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: true, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: true, 1, 1, 1, Assets.MainAssetBundle.LoadAsset("loaderspecial"), "AEROS_LOADER_SPEC_DESCRIPTION", "AEROS_LOADER_SPEC", Array.Empty()); Utils.AddAlt(skillLocator.special._skillFamily, skillDef); } private void ViendSecondarySetup(SkillLocator skillLocator) { LanguageAPI.Add("AEROS_VIEND_SECONDARY", "『 P??luck 」"); LanguageAPI.Add("AEROS_VIEND_SECONDARY_DESCRIPTION", "Fire a long-range beam for " + beamDMG.Value * 100f * (1f / beamFireFrequency.Value) + "% damage per second, pulling enemies hit."); SkillDef skillDef = Utils.NewSkillDef(typeof(Beam), "Weapon", 1, 5f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: true, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: true, 1, 1, 1, Prefabs.viendSecondary, "AEROS_VIEND_SECONDARY_DESCRIPTION", "AEROS_VIEND_SECONDARY", Array.Empty()); Utils.AddAlt(skillLocator.secondary._skillFamily, skillDef); viendSecondary = skillDef; LanguageAPI.Add("AEROS_VIEND_SECONDARY_CORRUPT", "『 P??luck 」 Corrupted"); LanguageAPI.Add("AEROS_VIEND_SECONDARY_DESCRIPTION_CORRUPT", "Fire an instant long-range beam for " + beamDMGCorrupted.Value * 100f + "% damage. Enemies hit are nullified and teleported to you."); skillDef = Utils.NewSkillDef(typeof(BeamCorrupted), "Weapon", 1, 5f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: true, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: true, 1, 1, 1, Prefabs.viendSecondaryCorrupted, "AEROS_VIEND_SECONDARY_DESCRIPTION_CORRUPT", "AEROS_VIEND_SECONDARY_CORRUPT", Array.Empty()); viendSecondaryCorrupted = skillDef; } private void ViendUtilitySetup(SkillLocator skillLocator) { LanguageAPI.Add("AEROS_VIEND_UTIL", "「 Sub?merge?? 】"); LanguageAPI.Add("AEROS_VIEND_UTIL_DESCRIPTION", "Enter a 「 Sub?merge?? 】, being unable to damage or be damaged by enemies, and receive " + viendSelfDMG.Value * 5f * 100f + "% damage per second, that increases over time."); SkillDef skillDef = Utils.NewSkillDef(typeof(Dimension), "Body", 1, 5f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: true, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: false, 1, 1, 1, Prefabs.viendUtility, "AEROS_VIEND_UTIL_DESCRIPTION", "AEROS_VIEND_UTIL", Array.Empty()); Utils.AddAlt(skillLocator.utility._skillFamily, skillDef); viendUtil = skillDef; LanguageAPI.Add("AEROS_VIEND_UTIL_CORRUPT", "「 Sub?merge?? 】 Corrupted"); LanguageAPI.Add("AEROS_VIEND_UTIL_DESCRIPTION_CORRUPT", "Gain " + viendSpeedBuff.Value * 100f + "% movement speed. Enter a 「 Sub?merge?? 】, being unable to damage or be damaged by enemies, and receive " + viendSelfDMG.Value * 5f * 100f + "% damage per second, that increases over time."); skillDef = Utils.NewSkillDef(typeof(DimensionCorrupted), "Body", 1, 5f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: true, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: false, 1, 1, 1, Prefabs.viendUtilityCorrupted, "AEROS_VIEND_UTIL_DESCRIPTION_CORRUPT", "AEROS_VIEND_UTIL_CORRUPT", Array.Empty()); viendUtilCorrupted = skillDef; } internal static void SeekerPrimarySetup(SkillLocator skillLocator) { //IL_0018: Unknown result type (might be due to invalid IL or missing references) //IL_001d: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) Variant[] variants = Prefabs.Load("RoR2/DLC2/Seeker/SeekerBodySecondaryFamily.asset").variants; foreach (Variant val in variants) { val.skillDef.fullRestockOnAssign = false; } string text = "SEEKER_M1"; LanguageAPI.Add("AEROS_" + text, "Spirit Fist"); LanguageAPI.Add("AEROS_" + text + "_DESCRIPTION", "Fire detonating fists at enemies for " + seekerPrimaryDamage.Value * 100f + "% damage, applying a stack of Soul Stack on hit. Reaching " + passiveMaxStacks.Value + " stacks will cause the enemy to detonate for " + passiveBaseDamage.Value * 100f + "% damage. Press the primary and secondary skills to use Unseen Clap."); SkillDef skillDef = Utils.NewSkillDef(typeof(SeekerPrimary), "Weapon", 0, 0f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: false, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: false, cancelSprintingOnActivation: true, 0, 0, 0, Assets.MainAssetBundle.LoadAsset("seekerPrimary"), "AEROS_" + text + "_DESCRIPTION", "AEROS_" + text, Array.Empty()); Utils.AddAlt(skillLocator.primary._skillFamily, skillDef); text = "SEEKER_M2"; LanguageAPI.Add("AEROS_" + text, "Unseen Clap"); LanguageAPI.Add("AEROS_" + text + "_DESCRIPTION", "Launch 2 piercing spectral hands against eachother for " + seekerSecondaryDamage.Value * 100f + "% damage, exploding when they collide for " + seekerSecondaryExplosionDamage.Value * 100f + "% damage. The explosion heals for " + seekerSecondaryHealPercentage.Value * 100f + "% health on hit."); seekerSecondary = Utils.NewSkillDef(typeof(Idle), "W", 0, 0f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: false, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: false, 0, 0, 0, Assets.MainAssetBundle.LoadAsset("seekerSecondary"), "AEROS_" + text + "_DESCRIPTION", "AEROS_" + text, Array.Empty()); } private void SeekerPassiveSetup(SkillLocator skillLocator) { LanguageAPI.Add("AEROS_SEEKER_PASSIVE0", "No passive."); LanguageAPI.Add("AEROS_SEEKER_PASSIVE", "Soul Stack"); LanguageAPI.Add("AEROS_SEEKER_PASSIVE_DESCRIPTION", "Apply a stack of Soul Stack on hit. Reaching " + passiveMaxStacks.Value + " stacks will cause the enemy to detonate for " + passiveBaseDamage.Value * 100f + "% damage."); LanguageAPI.Add("AEROS_SEEKER_LOADOUT", "Passive"); SkillDef skill = Utils.NewSkillDef(typeof(Idle), "Weapon", 0, 0f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: true, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: true, 0, 0, 0, Prefabs.Load("RoR2/Base/UI/texUIHighlightBoxOutlineThickIcon.png"), "", "AEROS_SEEKER_PASSIVE0", Array.Empty()); GenericSkill val = Utils.NewGenericSkill(((Component)skillLocator).gameObject, skill); SkillsAPI.SetOrderPriority(val, -1); SkillsAPI.SetLoadoutTitleTokenOverride(val, "AEROS_SEEKER_LOADOUT"); skill = Utils.NewSkillDef(typeof(Idle), "Weapon", 0, 0f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: true, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: true, 0, 0, 0, Assets.MainAssetBundle.LoadAsset("seekerpassive"), "AEROS_SEEKER_PASSIVE_DESCRIPTION", "AEROS_SEEKER_PASSIVE", Array.Empty()); Utils.AddAlt(val.skillFamily, skill); seekerPassive = skill; } private void SeekerSpecialSetup(SkillLocator skillLocator) { LanguageAPI.Add("AEROS_SEEKER_SPEC", "Soul Detonation"); LanguageAPI.Add("AEROS_SEEKER_SPEC_DESCRIPTION", "Charge up a exploding soul orb by executing timed sequences, gaining size and Tranquility, that deals " + genkidamaBaseDamage.Value * 100f + "%-" + genkidamaAddDamage.Value * 7f * 100f + "% damage."); Utils.AddAlt(SkillDef: seekerGenkidama = Utils.NewSkillDef(typeof(Genkidama), "Weapon", 1, 12f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: true, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: true, 1, 1, 1, Assets.MainAssetBundle.LoadAsset("seekerspecial"), "AEROS_SEEKER_SPEC_DESCRIPTION", "AEROS_SEEKER_SPEC", Array.Empty()), skillFamily: skillLocator.special._skillFamily); } private void EngiSpecialSetup(SkillLocator skillLocator) { LanguageAPI.Add("AEROS_ENGI_SPEC2", "TR90 Railgun Turret"); LanguageAPI.Add("AEROS_ENGI_SPEC", "TR90 Railgun Turret"); LanguageAPI.Add("AEROS_ENGI_SPEC_DESCRIPTION", "Drop a turret that charges up over 8s and fires for " + turretDamageCoefficient.Value * 100f + "% damage, inheriting all of your items."); SkillDef skillDef = Utils.NewSkillDef(typeof(EngiSpecial), "Weapon", 1, 25f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: true, (InterruptPriority)0, isCombatSkill: true, mustKeyPress: false, cancelSprintingOnActivation: true, 1, 1, 1, Assets.MainAssetBundle.LoadAsset("engispecial"), "AEROS_ENGI_SPEC_DESCRIPTION", "AEROS_ENGI_SPEC", Array.Empty()); Utils.AddAlt(skillLocator.special._skillFamily, skillDef); skillDef = Utils.NewSkillDef(typeof(EngiSpecial), "Weapon", 1, 25f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: true, (InterruptPriority)0, isCombatSkill: true, mustKeyPress: false, cancelSprintingOnActivation: true, 1, 1, 1, Assets.MainAssetBundle.LoadAsset("engispecial2"), "AEROS_ENGI_SPEC_DESCRIPTION", "AEROS_ENGI_SPEC2", Array.Empty()); engiScepter = skillDef; } private void EngiPrimarySetup(SkillLocator skillLocator) { LanguageAPI.Add("AEROS_ENGI_M1", "Seekers"); LanguageAPI.Add("AEROS_ENGI_M1_DESCRIPTION", "Charge up to 8 missiles that deal " + missileDamageCoefficient.Value * 100f + "% damage each."); SkillDef skillDef = Utils.NewSkillDef(typeof(EngiPrimaryCharge), "Weapon", 0, 0f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: true, (InterruptPriority)0, isCombatSkill: true, mustKeyPress: false, cancelSprintingOnActivation: true, 0, 0, 0, Assets.MainAssetBundle.LoadAsset("engiprimary"), "AEROS_ENGI_M1_DESCRIPTION", "AEROS_ENGI_M1", Array.Empty()); Utils.AddAlt(skillLocator.primary._skillFamily, skillDef); } private void CaptainPrimarySetup(SkillLocator skillLocator) { LanguageAPI.Add("AEROS_CAP_M1", "Vulcan Repeater"); LanguageAPI.Add("AEROS_CAP_M1_DESCRIPTION", "Fire a quick burst of 3 pellets that deal 3x" + burstDMG.Value * 100f + "% damage."); SkillDef skillDef = Utils.NewSkillDef(typeof(CaptainPrimary), "Weapon", 0, 0f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: true, (InterruptPriority)0, isCombatSkill: true, mustKeyPress: false, cancelSprintingOnActivation: true, 0, 0, 0, Assets.MainAssetBundle.LoadAsset("capprimary"), "AEROS_CAP_M1_DESCRIPTION", "AEROS_CAP_M1", Array.Empty()); Utils.AddAlt(skillLocator.primary._skillFamily, skillDef); } private void CaptainSecondarySetup(SkillLocator skillLocator) { LanguageAPI.Add("AEROS_CAP_M2", "Overclock"); LanguageAPI.Add("AEROS_CAP_M2_DESCRIPTION", "Fire a non damaging projectile that buffs nearby allies on impact with +" + regen.Value + " hp/s health regen, +" + atkspd.Value + " attack speed, +" + movspd.Value + " movement speed and " + cooldown.Value * 100f + "% cooldown reduction for " + duration.Value + "s."); SkillDef skillDef = Utils.NewSkillDef(typeof(CaptainSecondary), "Weapon", 1, CD.Value, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: false, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: false, 1, 1, 1, Assets.MainAssetBundle.LoadAsset("capsecondary"), "AEROS_CAP_M2_DESCRIPTION", "AEROS_CAP_M2", Array.Empty()); Utils.AddAlt(skillLocator.secondary.skillFamily, skillDef); } } public static class ModCompat { private static bool? ancientEnabled; public static bool AncientScepterEnabled { get { if (!ancientEnabled.HasValue) { ancientEnabled = Chainloader.PluginInfos.ContainsKey("com.DestroyedClone.AncientScepter"); } return ancientEnabled.Value; } } public static void AddScepterSupport() { ItemBase.instance.RegisterScepterSkill(MainPlugin.engiScepter, "EngiBody", (SkillSlot)3, 3); } } internal class Prefabs { internal static GameObject hitbox; internal static GameObject buffProjectileGhost; internal static GameObject buffProjectile; internal static GameObject buffProjectileExplosion; internal static GameObject tracer; internal static GameObject missileProjectile; internal static GameObject shieldEffect; internal static GameObject loaderImpact; internal static GameObject slamProjectile; internal static GameObject turret; internal static GameObject turretMaster; internal static GameObject turretBlueprint; internal static GameObject turretMuzzleFlash; internal static GameObject turretTracer; internal static GameObject turretBigTracer; internal static GameObject seekerGenkidamaProjectileGhost; internal static GameObject seekerGenkidamaProjectile; internal static GameObject viendPP; internal static GameObject viendPPCorrupted; internal static GameObject viendContinuousBeam; internal static GameObject viendBeamTracer; internal static GameObject viendBeamCharge; internal static GameObject mageMuzzleTrail; internal static GameObject fireSwordProjectile; internal static GameObject fireSwordProjectileDotZone; internal static GameObject fireSwordChargeEffect; internal static GameObject droneBody; internal static GameObject droneMaster; internal static GameObject gunSpinEffect; internal static GameObject gunSpinTracerEffect; internal static GameObject huntressGravityProjectile; internal static GameObject huntressExplosion; internal static GameObject railgunnerProjectile; internal static GameObject railgunnerChargeUI; internal static GameObject railgunnerChargeUIReady; internal static GameObject railgunnerChargeCrosshair; internal static GameObject railgunnerTracer; internal static GameObject railgunnerNova; internal static GameObject falseSonBuffWardEffect; internal static GameObject falseSonLaserMuzzles; internal static GameObject banditGrenadeGhost; internal static GameObject banditGrenade; internal static GameObject afterImageMesh; internal static GameObject commandoDashMuzzleflash; internal static GameObject fistProjectileGhost; internal static GameObject fistProjectile; internal static GameObject fistProjectileImpact; internal static GameObject crocoSlash; internal static GameObject palmProjectileGhost; internal static GameObject palmProjectile; internal static GameObject palmExplosionProjectile; internal static GameObject palmAreaIndicator; internal static GameObject crocoSlashHit; internal static GameObject crocoExplosionEffect; internal static GameObject crocoGasHitEffect; internal static GameObject posMuzzle; internal static GameObject fwGuide; internal static ModdedDamageType flameSwordHit; internal static ModdedDamageType seekerPrimaryDamage; internal static ModdedDamageType seekerSecondaryDamage; internal static ModdedDamageType crocoSecondaryDamage; internal static ModdedDamageType crocoSpecialDamage; internal static Sprite viendSecondary; internal static Sprite viendSecondaryCorrupted; internal static Sprite viendUtility; internal static Sprite viendUtilityCorrupted; internal static DeployableSlot bigTurret; internal static Material overlay; internal static Material droneTargetOverlay; internal static Material crocoSlashMat; internal static BuffDef seekerPassiveBuff; internal static BuffDef overclock; internal static BuffDef block; internal static BuffDef viendSpeedBuff; internal static BuffDef multDroneDebuff; internal static BuffDef multDroneRegenBuff; internal static BuffDef debuffImmune; internal static BuffDef falseSonAuraBuff; internal static BuffDef latchBuff; internal static BuffDef lacerationCD; internal static AnimationCurve spreadBloomCurve; internal static AnimationClip clip; internal static T Load(string path) { //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) return Addressables.LoadAssetAsync((object)path).WaitForCompletion(); } internal static GameObject Instantiate(string path, string name, bool registerNetwork = false) { return PrefabAPI.InstantiateClone(Load(path), name, registerNetwork); } internal static GameObject Instantiate(GameObject obj, string name, bool registerNetwork = false) { return PrefabAPI.InstantiateClone(obj, name, registerNetwork); } internal static int BigTurretDeployableCount(CharacterMaster master, int count) { //IL_001e: Unknown result type (might be due to invalid IL or missing references) int num = 1; if (Object.op_Implicit((Object)(object)master.inventory)) { if (master.inventory.GetItemCount(ItemCatalog.FindItemIndex("ITEM_ANCIENT_SCEPTER")) > 0) { num++; } if (master.inventory.GetItemCount(Items.EquipmentMagazineVoid) > 0) { num++; } } return num; } internal static void CreatePrefabs() { //IL_0045: Unknown result type (might be due to invalid IL or missing references) //IL_004a: Unknown result type (might be due to invalid IL or missing references) //IL_006f: Unknown result type (might be due to invalid IL or missing references) //IL_009d: Unknown result type (might be due to invalid IL or missing references) //IL_00a2: Unknown result type (might be due to invalid IL or missing references) //IL_00cd: Unknown result type (might be due to invalid IL or missing references) //IL_00d2: Unknown result type (might be due to invalid IL or missing references) //IL_00f8: Unknown result type (might be due to invalid IL or missing references) //IL_0127: Unknown result type (might be due to invalid IL or missing references) //IL_013e: Unknown result type (might be due to invalid IL or missing references) //IL_016d: Unknown result type (might be due to invalid IL or missing references) //IL_0195: Unknown result type (might be due to invalid IL or missing references) //IL_019a: Unknown result type (might be due to invalid IL or missing references) //IL_01c2: Unknown result type (might be due to invalid IL or missing references) //IL_01c7: 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) //IL_0209: Unknown result type (might be due to invalid IL or missing references) //IL_0213: Expected O, but got Unknown //IL_021d: Unknown result type (might be due to invalid IL or missing references) //IL_1186: Unknown result type (might be due to invalid IL or missing references) //IL_1190: Unknown result type (might be due to invalid IL or missing references) //IL_1195: Unknown result type (might be due to invalid IL or missing references) //IL_11b7: Unknown result type (might be due to invalid IL or missing references) //IL_11bc: Unknown result type (might be due to invalid IL or missing references) //IL_11f7: Unknown result type (might be due to invalid IL or missing references) //IL_11fc: Unknown result type (might be due to invalid IL or missing references) //IL_1218: Unknown result type (might be due to invalid IL or missing references) //IL_1222: Expected O, but got Unknown //IL_06d1: Unknown result type (might be due to invalid IL or missing references) //IL_06db: Unknown result type (might be due to invalid IL or missing references) //IL_06f2: Unknown result type (might be due to invalid IL or missing references) //IL_06fc: Expected O, but got Unknown //IL_0713: Unknown result type (might be due to invalid IL or missing references) //IL_072a: Unknown result type (might be due to invalid IL or missing references) //IL_076c: Unknown result type (might be due to invalid IL or missing references) //IL_0773: Expected O, but got Unknown //IL_07f7: Unknown result type (might be due to invalid IL or missing references) //IL_0804: Unknown result type (might be due to invalid IL or missing references) //IL_080e: Unknown result type (might be due to invalid IL or missing references) //IL_082c: Unknown result type (might be due to invalid IL or missing references) //IL_0836: Unknown result type (might be due to invalid IL or missing references) //IL_0857: Unknown result type (might be due to invalid IL or missing references) //IL_036a: Unknown result type (might be due to invalid IL or missing references) //IL_0393: Unknown result type (might be due to invalid IL or missing references) //IL_039d: Expected O, but got Unknown //IL_03b8: Unknown result type (might be due to invalid IL or missing references) //IL_03bd: Unknown result type (might be due to invalid IL or missing references) //IL_03f9: Unknown result type (might be due to invalid IL or missing references) //IL_0403: Expected O, but got Unknown //IL_0410: 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_047c: Unknown result type (might be due to invalid IL or missing references) //IL_0503: Unknown result type (might be due to invalid IL or missing references) //IL_0508: Unknown result type (might be due to invalid IL or missing references) //IL_145e: Unknown result type (might be due to invalid IL or missing references) //IL_1463: Unknown result type (might be due to invalid IL or missing references) //IL_1468: Unknown result type (might be due to invalid IL or missing references) //IL_146d: Unknown result type (might be due to invalid IL or missing references) //IL_1472: Unknown result type (might be due to invalid IL or missing references) //IL_1477: Unknown result type (might be due to invalid IL or missing references) //IL_147b: Unknown result type (might be due to invalid IL or missing references) //IL_14f9: Unknown result type (might be due to invalid IL or missing references) //IL_14fb: Unknown result type (might be due to invalid IL or missing references) //IL_15a8: Unknown result type (might be due to invalid IL or missing references) //IL_15ad: Unknown result type (might be due to invalid IL or missing references) //IL_1652: Unknown result type (might be due to invalid IL or missing references) //IL_165c: Unknown result type (might be due to invalid IL or missing references) //IL_02ab: Unknown result type (might be due to invalid IL or missing references) //IL_02b5: Expected O, but got Unknown //IL_02e0: Unknown result type (might be due to invalid IL or missing references) //IL_02ec: Unknown result type (might be due to invalid IL or missing references) //IL_1971: Unknown result type (might be due to invalid IL or missing references) //IL_1981: Expected O, but got Unknown //IL_19ee: Unknown result type (might be due to invalid IL or missing references) //IL_19f5: Expected O, but got Unknown //IL_1a21: Unknown result type (might be due to invalid IL or missing references) //IL_1a26: Unknown result type (might be due to invalid IL or missing references) //IL_1a2b: Unknown result type (might be due to invalid IL or missing references) //IL_1aa5: Unknown result type (might be due to invalid IL or missing references) //IL_1aac: Expected O, but got Unknown //IL_1ac2: Unknown result type (might be due to invalid IL or missing references) //IL_1ad2: Expected O, but got Unknown //IL_1b3f: Unknown result type (might be due to invalid IL or missing references) //IL_1b46: Expected O, but got Unknown //IL_1b72: Unknown result type (might be due to invalid IL or missing references) //IL_1b77: Unknown result type (might be due to invalid IL or missing references) //IL_1b7c: Unknown result type (might be due to invalid IL or missing references) //IL_1bf6: Unknown result type (might be due to invalid IL or missing references) //IL_1bfd: Expected O, but got Unknown //IL_1c2d: Unknown result type (might be due to invalid IL or missing references) //IL_1c37: Unknown result type (might be due to invalid IL or missing references) //IL_1c8c: Unknown result type (might be due to invalid IL or missing references) //IL_13b0: Unknown result type (might be due to invalid IL or missing references) //IL_13b5: Unknown result type (might be due to invalid IL or missing references) //IL_13ec: Unknown result type (might be due to invalid IL or missing references) //IL_13f6: Unknown result type (might be due to invalid IL or missing references) //IL_21c3: Unknown result type (might be due to invalid IL or missing references) //IL_21ca: Expected O, but got Unknown //IL_1683: Unknown result type (might be due to invalid IL or missing references) //IL_1688: Unknown result type (might be due to invalid IL or missing references) //IL_16b7: Unknown result type (might be due to invalid IL or missing references) //IL_16bc: Unknown result type (might be due to invalid IL or missing references) //IL_16c0: Unknown result type (might be due to invalid IL or missing references) //IL_16d5: Unknown result type (might be due to invalid IL or missing references) //IL_16d7: Unknown result type (might be due to invalid IL or missing references) //IL_08d7: Unknown result type (might be due to invalid IL or missing references) //IL_27c8: Unknown result type (might be due to invalid IL or missing references) //IL_27d2: Expected O, but got Unknown //IL_27dc: Unknown result type (might be due to invalid IL or missing references) //IL_2870: Unknown result type (might be due to invalid IL or missing references) //IL_2882: Unknown result type (might be due to invalid IL or missing references) //IL_28a0: Unknown result type (might be due to invalid IL or missing references) //IL_28a7: Expected O, but got Unknown //IL_28ae: Unknown result type (might be due to invalid IL or missing references) //IL_28c0: Unknown result type (might be due to invalid IL or missing references) //IL_2965: Unknown result type (might be due to invalid IL or missing references) //IL_29dc: Unknown result type (might be due to invalid IL or missing references) //IL_29e1: Unknown result type (might be due to invalid IL or missing references) //IL_2a53: Unknown result type (might be due to invalid IL or missing references) //IL_2a75: Unknown result type (might be due to invalid IL or missing references) //IL_2a8d: Unknown result type (might be due to invalid IL or missing references) //IL_2ac7: Unknown result type (might be due to invalid IL or missing references) //IL_2aed: Unknown result type (might be due to invalid IL or missing references) //IL_2b05: Unknown result type (might be due to invalid IL or missing references) //IL_2b47: Unknown result type (might be due to invalid IL or missing references) //IL_2b51: Unknown result type (might be due to invalid IL or missing references) //IL_2b5b: Unknown result type (might be due to invalid IL or missing references) //IL_1ce8: Unknown result type (might be due to invalid IL or missing references) //IL_1ced: Unknown result type (might be due to invalid IL or missing references) //IL_091c: Unknown result type (might be due to invalid IL or missing references) //IL_0926: Unknown result type (might be due to invalid IL or missing references) //IL_0957: Unknown result type (might be due to invalid IL or missing references) //IL_097d: Unknown result type (might be due to invalid IL or missing references) //IL_0987: Expected O, but got Unknown //IL_09da: Unknown result type (might be due to invalid IL or missing references) //IL_0a10: Unknown result type (might be due to invalid IL or missing references) //IL_0a32: Unknown result type (might be due to invalid IL or missing references) //IL_0afa: Unknown result type (might be due to invalid IL or missing references) //IL_0b28: Unknown result type (might be due to invalid IL or missing references) //IL_0b3d: Unknown result type (might be due to invalid IL or missing references) //IL_0b3f: Unknown result type (might be due to invalid IL or missing references) //IL_0b90: Unknown result type (might be due to invalid IL or missing references) //IL_0bb2: Unknown result type (might be due to invalid IL or missing references) //IL_0bd4: Unknown result type (might be due to invalid IL or missing references) //IL_0c84: Unknown result type (might be due to invalid IL or missing references) //IL_0c89: Unknown result type (might be due to invalid IL or missing references) //IL_0ccd: Unknown result type (might be due to invalid IL or missing references) //IL_0cee: Unknown result type (might be due to invalid IL or missing references) //IL_0d00: Unknown result type (might be due to invalid IL or missing references) //IL_0d0a: Unknown result type (might be due to invalid IL or missing references) //IL_0d32: Unknown result type (might be due to invalid IL or missing references) //IL_0d37: Unknown result type (might be due to invalid IL or missing references) //IL_0d55: Unknown result type (might be due to invalid IL or missing references) //IL_0de1: Unknown result type (might be due to invalid IL or missing references) //IL_0df8: Unknown result type (might be due to invalid IL or missing references) //IL_0e02: Expected O, but got Unknown //IL_0dfd: Unknown result type (might be due to invalid IL or missing references) //IL_0e02: Unknown result type (might be due to invalid IL or missing references) //IL_2369: Unknown result type (might be due to invalid IL or missing references) //IL_23a3: Unknown result type (might be due to invalid IL or missing references) //IL_23c4: Unknown result type (might be due to invalid IL or missing references) //IL_240b: Unknown result type (might be due to invalid IL or missing references) //IL_241d: Unknown result type (might be due to invalid IL or missing references) //IL_2427: Unknown result type (might be due to invalid IL or missing references) //IL_242c: Unknown result type (might be due to invalid IL or missing references) //IL_244d: Unknown result type (might be due to invalid IL or missing references) //IL_247f: Unknown result type (might be due to invalid IL or missing references) //IL_2484: Unknown result type (might be due to invalid IL or missing references) //IL_2488: Unknown result type (might be due to invalid IL or missing references) //IL_249d: Unknown result type (might be due to invalid IL or missing references) //IL_249f: Unknown result type (might be due to invalid IL or missing references) //IL_2588: Unknown result type (might be due to invalid IL or missing references) //IL_259a: Unknown result type (might be due to invalid IL or missing references) //IL_25a4: Unknown result type (might be due to invalid IL or missing references) //IL_25a9: Unknown result type (might be due to invalid IL or missing references) //IL_25ef: Unknown result type (might be due to invalid IL or missing references) //IL_2601: Unknown result type (might be due to invalid IL or missing references) //IL_260b: Unknown result type (might be due to invalid IL or missing references) //IL_2610: Unknown result type (might be due to invalid IL or missing references) //IL_2631: Unknown result type (might be due to invalid IL or missing references) //IL_268e: Unknown result type (might be due to invalid IL or missing references) //IL_2690: Unknown result type (might be due to invalid IL or missing references) //IL_1d17: Unknown result type (might be due to invalid IL or missing references) //IL_1d21: Expected O, but got Unknown //IL_1761: Unknown result type (might be due to invalid IL or missing references) //IL_1766: Unknown result type (might be due to invalid IL or missing references) //IL_18d0: Unknown result type (might be due to invalid IL or missing references) //IL_18e5: Unknown result type (might be due to invalid IL or missing references) //IL_0aa9: Unknown result type (might be due to invalid IL or missing references) //IL_0ab3: Unknown result type (might be due to invalid IL or missing references) //IL_225f: Unknown result type (might be due to invalid IL or missing references) //IL_2269: Expected O, but got Unknown //IL_1d59: Unknown result type (might be due to invalid IL or missing references) //IL_1d63: Expected O, but got Unknown //IL_1d7d: Unknown result type (might be due to invalid IL or missing references) //IL_1d82: Unknown result type (might be due to invalid IL or missing references) //IL_0e4b: Unknown result type (might be due to invalid IL or missing references) //IL_0e55: Expected O, but got Unknown //IL_0ec1: Unknown result type (might be due to invalid IL or missing references) //IL_0ed5: Unknown result type (might be due to invalid IL or missing references) //IL_31f2: Unknown result type (might be due to invalid IL or missing references) //IL_31f9: Expected O, but got Unknown //IL_3236: Unknown result type (might be due to invalid IL or missing references) //IL_323d: Expected O, but got Unknown //IL_3292: Unknown result type (might be due to invalid IL or missing references) //IL_3297: Unknown result type (might be due to invalid IL or missing references) //IL_2c82: Unknown result type (might be due to invalid IL or missing references) //IL_2c89: Expected O, but got Unknown //IL_2c9e: Unknown result type (might be due to invalid IL or missing references) //IL_2ca3: Unknown result type (might be due to invalid IL or missing references) //IL_2dbf: Unknown result type (might be due to invalid IL or missing references) //IL_2dc9: Expected O, but got Unknown //IL_1da8: Unknown result type (might be due to invalid IL or missing references) //IL_1db2: Unknown result type (might be due to invalid IL or missing references) //IL_3836: Unknown result type (might be due to invalid IL or missing references) //IL_3840: Expected O, but got Unknown //IL_3875: Unknown result type (might be due to invalid IL or missing references) //IL_387a: Unknown result type (might be due to invalid IL or missing references) //IL_38a2: Unknown result type (might be due to invalid IL or missing references) //IL_38ac: Expected O, but got Unknown //IL_38c8: Unknown result type (might be due to invalid IL or missing references) //IL_38cd: Unknown result type (might be due to invalid IL or missing references) //IL_2e4e: Unknown result type (might be due to invalid IL or missing references) //IL_2e53: Unknown result type (might be due to invalid IL or missing references) //IL_2ec0: Unknown result type (might be due to invalid IL or missing references) //IL_2eca: Unknown result type (might be due to invalid IL or missing references) //IL_1df3: Unknown result type (might be due to invalid IL or missing references) //IL_1dfd: Unknown result type (might be due to invalid IL or missing references) //IL_1e14: Unknown result type (might be due to invalid IL or missing references) //IL_1e1e: Expected O, but got Unknown //IL_1e38: Unknown result type (might be due to invalid IL or missing references) //IL_1e3d: Unknown result type (might be due to invalid IL or missing references) //IL_1f72: Unknown result type (might be due to invalid IL or missing references) //IL_1f7c: Expected O, but got Unknown //IL_1f96: Unknown result type (might be due to invalid IL or missing references) //IL_1f9b: Unknown result type (might be due to invalid IL or missing references) //IL_20cc: Unknown result type (might be due to invalid IL or missing references) //IL_20d2: Expected O, but got Unknown //IL_210a: Unknown result type (might be due to invalid IL or missing references) //IL_0f3c: Unknown result type (might be due to invalid IL or missing references) //IL_0f46: Expected O, but got Unknown //IL_0fcd: Unknown result type (might be due to invalid IL or missing references) //IL_0fd7: Expected O, but got Unknown //IL_3a99: Unknown result type (might be due to invalid IL or missing references) //IL_3a9e: Unknown result type (might be due to invalid IL or missing references) //IL_3ab8: Unknown result type (might be due to invalid IL or missing references) //IL_3abd: Unknown result type (might be due to invalid IL or missing references) //IL_3ad2: Unknown result type (might be due to invalid IL or missing references) //IL_3adb: Expected O, but got Unknown //IL_3ae8: Unknown result type (might be due to invalid IL or missing references) //IL_3b38: Unknown result type (might be due to invalid IL or missing references) //IL_3b3f: Unknown result type (might be due to invalid IL or missing references) //IL_3b44: Unknown result type (might be due to invalid IL or missing references) //IL_3b49: Unknown result type (might be due to invalid IL or missing references) //IL_33df: Unknown result type (might be due to invalid IL or missing references) //IL_33e4: Unknown result type (might be due to invalid IL or missing references) //IL_33ee: Unknown result type (might be due to invalid IL or missing references) //IL_33f3: Unknown result type (might be due to invalid IL or missing references) //IL_33f8: Unknown result type (might be due to invalid IL or missing references) //IL_3415: Unknown result type (might be due to invalid IL or missing references) //IL_341f: Unknown result type (might be due to invalid IL or missing references) //IL_34a7: Unknown result type (might be due to invalid IL or missing references) //IL_34ac: Unknown result type (might be due to invalid IL or missing references) //IL_34b1: Unknown result type (might be due to invalid IL or missing references) //IL_1fe3: Unknown result type (might be due to invalid IL or missing references) //IL_1ff7: Unknown result type (might be due to invalid IL or missing references) //IL_2001: Expected O, but got Unknown //IL_0f8c: Unknown result type (might be due to invalid IL or missing references) //IL_0f91: Unknown result type (might be due to invalid IL or missing references) //IL_0f95: Unknown result type (might be due to invalid IL or missing references) //IL_0f9a: Unknown result type (might be due to invalid IL or missing references) //IL_3bab: Unknown result type (might be due to invalid IL or missing references) //IL_3bb0: Unknown result type (might be due to invalid IL or missing references) //IL_3bb5: Unknown result type (might be due to invalid IL or missing references) //IL_3bba: Unknown result type (might be due to invalid IL or missing references) //IL_3bc9: Unknown result type (might be due to invalid IL or missing references) //IL_3bd3: Expected O, but got Unknown //IL_3c01: Unknown result type (might be due to invalid IL or missing references) //IL_3c24: Unknown result type (might be due to invalid IL or missing references) //IL_3c29: Unknown result type (might be due to invalid IL or missing references) //IL_3cc4: Unknown result type (might be due to invalid IL or missing references) //IL_3cc9: Unknown result type (might be due to invalid IL or missing references) //IL_3920: Unknown result type (might be due to invalid IL or missing references) //IL_3925: Unknown result type (might be due to invalid IL or missing references) //IL_392e: Unknown result type (might be due to invalid IL or missing references) //IL_3939: Unknown result type (might be due to invalid IL or missing references) //IL_393e: Unknown result type (might be due to invalid IL or missing references) //IL_3943: Unknown result type (might be due to invalid IL or missing references) //IL_32f1: Unknown result type (might be due to invalid IL or missing references) //IL_32f8: Expected O, but got Unknown //IL_2782: Unknown result type (might be due to invalid IL or missing references) //IL_2787: Unknown result type (might be due to invalid IL or missing references) //IL_2141: Unknown result type (might be due to invalid IL or missing references) //IL_214b: Expected O, but got Unknown //IL_217e: Unknown result type (might be due to invalid IL or missing references) //IL_3596: Unknown result type (might be due to invalid IL or missing references) //IL_359b: Unknown result type (might be due to invalid IL or missing references) //IL_35d4: Unknown result type (might be due to invalid IL or missing references) //IL_35d9: Unknown result type (might be due to invalid IL or missing references) //IL_3d4a: Unknown result type (might be due to invalid IL or missing references) //IL_3d4f: Unknown result type (might be due to invalid IL or missing references) //IL_3d8b: Unknown result type (might be due to invalid IL or missing references) //IL_3d95: Unknown result type (might be due to invalid IL or missing references) //IL_3df4: Unknown result type (might be due to invalid IL or missing references) //IL_3e04: Expected O, but got Unknown //IL_39b4: Unknown result type (might be due to invalid IL or missing references) //IL_39da: Unknown result type (might be due to invalid IL or missing references) //IL_39e9: Unknown result type (might be due to invalid IL or missing references) //IL_3524: Unknown result type (might be due to invalid IL or missing references) //IL_2fe2: Unknown result type (might be due to invalid IL or missing references) //IL_2fe7: Unknown result type (might be due to invalid IL or missing references) //IL_303d: Unknown result type (might be due to invalid IL or missing references) //IL_3078: Unknown result type (might be due to invalid IL or missing references) //IL_307d: Unknown result type (might be due to invalid IL or missing references) //IL_308c: Unknown result type (might be due to invalid IL or missing references) //IL_315b: Unknown result type (might be due to invalid IL or missing references) //IL_3162: Expected O, but got Unknown //IL_107d: Unknown result type (might be due to invalid IL or missing references) //IL_1087: Expected O, but got Unknown //IL_1129: Unknown result type (might be due to invalid IL or missing references) //IL_10cc: Unknown result type (might be due to invalid IL or missing references) //IL_10d1: Unknown result type (might be due to invalid IL or missing references) //IL_10f2: Unknown result type (might be due to invalid IL or missing references) //IL_3544: Unknown result type (might be due to invalid IL or missing references) //IL_3549: Unknown result type (might be due to invalid IL or missing references) //IL_3684: Unknown result type (might be due to invalid IL or missing references) //IL_368b: Expected O, but got Unknown //IL_369c: Unknown result type (might be due to invalid IL or missing references) //IL_3773: Unknown result type (might be due to invalid IL or missing references) //IL_377a: Expected O, but got Unknown hitbox = Instantiate(Assets.Load("hitbox"), "hitbox"); hitbox.AddComponent().duration = 0.05f; Sprite sprite = Load("RoR2/Junk/Common/texBuffBodyArmorIcon.tif"); Sprite sprite2 = Load("RoR2/Base/Common/texBuffGenericShield.tif"); flameSwordHit = DamageAPI.ReserveDamageType(); seekerPassiveBuff = Utils.NewBuffDef("Orb", stack: true, hidden: false, Assets.Load("seekerPassiveBuff"), new Color(0.855f, 0.698f, 0.314f)); overclock = Utils.NewBuffDef("Overclock", stack: false, hidden: false, Load("RoR2/Base/Croco/texBuffRegenBoostIcon.tif"), Color32.op_Implicit(new Color32((byte)226, (byte)81, (byte)65, byte.MaxValue))); block = Utils.NewBuffDef("Block", stack: false, hidden: false, sprite, Color32.op_Implicit(new Color32((byte)239, (byte)245, (byte)140, byte.MaxValue))); latchBuff = Utils.NewBuffDef("Latched", stack: false, hidden: false, sprite, new Color(0.788f, 0.949f, 0.302f)); multDroneDebuff = Utils.NewBuffDef("Weakened", stack: false, hidden: false, Load("RoR2/Base/Common/texBuffSlow50Icon.tif"), new Color(0.827f, 0.769f, 0.314f)); multDroneRegenBuff = Utils.NewBuffDef("Regen", stack: false, hidden: true, null, Color.clear); viendSpeedBuff = Utils.NewBuffDef("Speed", stack: false, hidden: false, Load("RoR2/Base/Common/texMovespeedBuffIcon.tif"), new Color(0.724f, 0.071f, 0.929f)); debuffImmune = Utils.NewBuffDef("Debuff Immunity", stack: false, hidden: false, sprite2, Color32.op_Implicit(new Color32((byte)37, (byte)150, (byte)190, byte.MaxValue))); falseSonAuraBuff = Utils.NewBuffDef("Gilded Aura", stack: false, hidden: false, sprite2, Color32.op_Implicit(new Color32((byte)240, (byte)222, (byte)86, byte.MaxValue))); lacerationCD = Utils.NewBuffDef("LacerationCD", stack: false, hidden: true, null, Color.clear); if (MainPlugin.enableCap.Value) { overlay = new Material(Load("RoR2/Base/Common/matEnergyShield.mat")); overlay.SetColor("_TintColor", Color.red); overlay.SetFloat("_OffsetAmount", 0.025f); buffProjectileExplosion = Instantiate("RoR2/Base/FusionCellDestructible/FusionCellExplosion.prefab", "BuffExplosion"); buffProjectileExplosion.GetComponent().soundName = "Play_roboBall_attack1_explode"; ParticleSystemRenderer[] componentsInChildren = buffProjectileExplosion.GetComponentsInChildren(); foreach (ParticleSystemRenderer val in componentsInChildren) { string name = ((Object)val).name; if (name == "Ring") { ((Renderer)val).material = new Material(Load("RoR2/Base/RoboBallBoss/matRoboBallParticleRing.mat")); ((Renderer)val).material.SetTexture("_RemapTex", (Texture)(object)Load("RoR2/Base/Common/ColorRamps/texRampHuntressSoftCrit.png")); Object.Instantiate(((Component)val).gameObject, ((Component)val).transform.position, ((Component)val).transform.rotation, ((Component)val).transform.parent); } } ContentAddition.AddEffect(buffProjectileExplosion); buffProjectileGhost = Instantiate("RoR2/Base/Captain/CaptainTazerGhost.prefab", "BuffProjectileGhost"); Transform child = buffProjectileGhost.transform.GetChild(1); ((Component)child.GetChild(1)).gameObject.SetActive(false); Transform child2 = child.GetChild(0); ((Component)child2).transform.localPosition = Vector3.zero; TrailRenderer component = ((Component)child2).GetComponent(); component.textureMode = (LineTextureMode)0; ((Renderer)component).material = new Material(Load("RoR2/Base/Bandit2/matBandit2SplatterOpaqueTrailAlt.mat")); ((Renderer)component).material.SetColor("_TintColor", Color32.op_Implicit(new Color32(byte.MaxValue, (byte)44, (byte)44, byte.MaxValue))); ((Renderer)component).material.SetTexture("_RemapTex", (Texture)(object)Load("RoR2/Base/Common/ColorRamps/texRampParentEyes.png")); ParticleSystemRenderer componentInChildren = ((Component)child2).GetComponentInChildren(); ((Renderer)componentInChildren).material = new Material(Load("RoR2/Base/Common/VFX/matArcaneCircleProvi.mat")); ((Renderer)componentInChildren).material.SetColor("_TintColor", Color.red); ((Renderer)componentInChildren).material.SetFloat("_Boost", 6f); buffProjectile = Instantiate("RoR2/Base/Captain/CaptainTazer.prefab", "BuffProjectile", registerNetwork: true); buffProjectile.GetComponent().collisionDetectionMode = (CollisionDetectionMode)2; buffProjectile.GetComponent().ghostPrefab = buffProjectileGhost; buffProjectile.GetComponent().damageType = DamageTypeCombo.op_Implicit((DamageType)0); buffProjectile.GetComponent().desiredForwardSpeed = 110f; Object.Destroy((Object)(object)buffProjectile.GetComponent()); ProjectileSingleTargetImpact val2 = buffProjectile.AddComponent(); val2.destroyOnWorld = true; val2.destroyWhenNotAlive = true; buffProjectile.AddComponent(); ContentAddition.AddProjectile(buffProjectile); tracer = Instantiate("RoR2/Base/Bandit2/TracerBanditPistol.prefab", "Tracer"); tracer.GetComponent().endColor = Color32.op_Implicit(new Color32(byte.MaxValue, (byte)31, (byte)0, byte.MaxValue)); ContentAddition.AddEffect(tracer); } if (MainPlugin.enableEngi.Value) { missileProjectile = Instantiate("RoR2/Base/Engi/EngiHarpoon.prefab", "AerosMissileProjectile", registerNetwork: true); Object.Destroy((Object)(object)missileProjectile.GetComponent()); Object.Destroy((Object)(object)missileProjectile.GetComponent()); Rigidbody component2 = missileProjectile.GetComponent(); component2.useGravity = false; component2.collisionDetectionMode = (CollisionDetectionMode)2; ProjectileSimple val3 = missileProjectile.AddComponent(); val3.desiredForwardSpeed = 60f; val3.lifetime = 8f; ProjectileDirectionalTargetFinder val4 = missileProjectile.AddComponent(); val4.lookRange = 45f; val4.lookCone = 35f; val4.allowTargetLoss = false; val4.onlySearchIfNoTarget = true; val4.testLoS = false; val4.targetSearchInterval = 0.1f; val4.ignoreAir = false; ((Behaviour)val4).enabled = MainPlugin.missileTracking.Value; ProjectileSteerTowardTarget val5 = missileProjectile.AddComponent(); val5.rotationSpeed = 220f; ProjectileController component3 = missileProjectile.GetComponent(); ProjectileSingleTargetImpact component4 = missileProjectile.GetComponent(); GameObject val6 = Instantiate(component4.impactEffect, "AerosMissileImpact"); val6.GetComponent().soundName = "Play_engi_M1_explo"; ContentAddition.AddEffect(val6); component4.impactEffect = val6; if (MainPlugin.missileTracking.Value) { missileProjectile.AddComponent(); } GameObject val7 = Instantiate(component3.ghostPrefab, "AerosMissileGhost"); ((Component)val7.GetComponentsInChildren()[^1]).gameObject.SetActive(false); TrailRenderer componentInChildren2 = val7.GetComponentInChildren(); ((Component)componentInChildren2).transform.localPosition = Vector3.forward * 0.1f; ((Renderer)componentInChildren2).material = new Material(Load("RoR2/DLC1/EliteEarth/matAffixEarthTrailBloblets.mat")); ((Renderer)componentInChildren2).material.SetTextureScale("_Cloud2Tex", new Vector2(0.7f, 1f)); ((Renderer)componentInChildren2).material.SetVector("_CutoffScroll", Vector4.zero); component3.ghostPrefab = val7; ContentAddition.AddProjectile(missileProjectile); GameObject val8 = Assets.Load("turretMdl"); GameObject val9 = val8; MeshRenderer[] componentsInChildren2 = val9.GetComponentsInChildren(); Material val10 = new Material(Load("RoR2/Base/Engi/matEngiTurret.mat")); val10.SetFloat("_PrintOn", 0f); val10.SetFloat("_EmPower", 5f); turret = Instantiate("RoR2/Base/Engi/EngiTurretBody.prefab", "AerosBigTurretBody", registerNetwork: true); ((Component)turret.GetComponentInChildren()).gameObject.SetActive(false); ChildLocator component5 = ((Component)turret.GetComponent().modelTransform).GetComponent(); Transform val11 = component5.FindChild("Muzzle"); val11.localPosition = new Vector3(0f, 3.5f, 9.6f); val11.localScale = Vector3.one * 2f; HurtBox componentInChildren3 = turret.GetComponentInChildren(); ((Component)componentInChildren3).transform.localPosition = Vector3.up * 2f; ((Component)componentInChildren3).transform.localScale = new Vector3(3f, 7f, 3f); List list = new List(); Transform[] componentsInChildren3 = turret.GetComponentsInChildren(); foreach (Transform val12 in componentsInChildren3) { string name2 = ((Object)val12).name; if (name2 == "Base") { GameObject val13 = Object.Instantiate(((Component)componentsInChildren2[0]).gameObject); val13.transform.parent = val12; ((Renderer)val13.GetComponent()).material = val10; val13.transform.localPosition = Vector3.zero; list.Add((Renderer)(object)val13.GetComponent()); } if (name2 == "Head") { ((Component)val12).gameObject.AddComponent(); ((Component)val12).transform.localPosition = Vector3.up * 4f; GameObject val14 = Object.Instantiate(((Component)componentsInChildren2[1]).gameObject); val14.transform.parent = val12; val14.transform.localPosition = Vector3.zero; MeshRenderer[] componentsInChildren4 = val14.GetComponentsInChildren(); ((Renderer)componentsInChildren4[0]).material = val10; ((Renderer)componentsInChildren4[1]).material = new Material(val10); Texture2D val15 = Assets.Load("chargeindicator"); Texture2D val16 = Assets.Load("chargeindicator_e"); ((Renderer)componentsInChildren4[1]).material.SetTexture("_MainTex", (Texture)(object)val15); ((Renderer)componentsInChildren4[1]).material.SetTexture("_EmTex", (Texture)(object)val16); ((Renderer)componentsInChildren4[1]).material.SetTextureScale("_MainTex", Vector2.zero); ((Renderer)componentsInChildren4[1]).material.SetFloat("_EmPower", 10f); List list2 = component5.transformPairs.ToList(); list2.Add(new NameTransformPair { name = "Charge", transform = ((Component)componentsInChildren4[1]).transform }); component5.transformPairs = list2.ToArray(); list.Add((Renderer)(object)componentsInChildren4[0]); list.Add((Renderer)(object)componentsInChildren4[1]); } if (name2 == "Neck") { GameObject val17 = Object.Instantiate(((Component)componentsInChildren2[3]).gameObject); val17.transform.parent = val12; ((Renderer)val17.GetComponent()).material = val10; val17.transform.localPosition = Vector3.up * -1.4f; list.Add((Renderer)(object)val17.GetComponent()); } } RendererInfo[] array = (RendererInfo[])(object)new RendererInfo[list.Count]; for (int k = 0; k < array.Length; k++) { array[k] = new RendererInfo { renderer = list[k], defaultMaterial = list[k].material, defaultShadowCastingMode = (ShadowCastingMode)0, hideOnDeath = false, ignoreOverlays = false }; } CharacterModel component6 = ((Component)component5).GetComponent(); component6.baseRendererInfos = array.ToArray(); ModelSkinController component7 = ((Component)component5).GetComponent(); component7.skins = (SkinDef[])(object)new SkinDef[3] { Skins.CreateNewSkinDef(Utils.CreateNewSkinDefInfo(list, ((Component)component5).gameObject, array, val10)), Skins.CreateNewSkinDef(Utils.CreateNewSkinDefInfo(list, ((Component)component5).gameObject, array, Load("RoR2/Base/Engi/matEngiAlt.mat"))), Skins.CreateNewSkinDef(Utils.CreateNewSkinDefInfo(list, ((Component)component5).gameObject, array, Load("RoR2/Base/Engi/matEngiAltColossusTool.mat"))) }; component7.currentSkinIndex = 0; Utils.AddMinionSkin(Load("RoR2/Base/Engi/skinEngiDefault.asset"), turret, component7.skins[0]); Utils.AddMinionSkin(Load("RoR2/Base/Engi/skinEngiAlt.asset"), turret, component7.skins[1]); Utils.AddMinionSkin(Load("RoR2/Base/Engi/skinEngiAltColossus.asset"), turret, component7.skins[2]); ((Behaviour)component6).enabled = false; ((Component)component5).gameObject.AddComponent(); ((Component)component5).gameObject.AddComponent(); GameObject val18 = Load("RoR2/Base/Engi/EngiDisplay.prefab"); GameObject val19 = Object.Instantiate(((Component)component5).gameObject, val18.transform.position, Quaternion.identity); ((Behaviour)val19.GetComponent()).enabled = false; val19.transform.parent = val18.transform; val19.transform.localPosition = new Vector3(0.3f, 0f, -3.5f); val19.transform.localRotation = Quaternion.Euler(0f, 20f, 0f); val19.transform.localScale = Vector3.one * 0.36f; ((Behaviour)component6).enabled = true; turret.GetComponent().initialStateType = new SerializableEntityStateType(typeof(TurretSpawn)); turret.GetComponent().primary = Utils.NewGenericSkill(turret, Utils.NewSkillDef(new SerializableEntityStateType(typeof(EngiTurretPrimary)), "Weapon", 1, 8f, beginSkillCooldownOnSkillEnd: false, canceledFromSprinting: false, fullRestockOnAssign: true, (InterruptPriority)0, isCombatSkill: true, mustKeyPress: false, cancelSprintingOnActivation: true, 1, 1, 1, (Sprite)null, "AEROS_ENGI_SPEC_DESCRIPTION", "AEROS_ENGI_SPEC", Array.Empty())); ContentAddition.AddBody(turret); turretMaster = Instantiate("RoR2/Base/Engi/EngiTurretMaster.prefab", "AerosBigTurretMaster", registerNetwork: true); turretMaster.GetComponent().bodyPrefab = turret; AISkillDriver[] components = turretMaster.GetComponents(); components[0].maxDistance = 250f; components[1].moveTargetType = (TargetType)0; ContentAddition.AddMaster(turretMaster); bigTurret = DeployableAPI.RegisterDeployableSlot(new GetDeployableSameSlotLimit(BigTurretDeployableCount)); Texture2D val20 = Load("RoR2/Base/Common/ColorRamps/texRampEngi.png"); turretMuzzleFlash = Instantiate("RoR2/Base/Engi/MuzzleflashEngiTurret.prefab", "AerosTurretMuzzleFlash"); ParticleSystemRenderer[] componentsInChildren5 = turretMuzzleFlash.GetComponentsInChildren(); foreach (ParticleSystemRenderer val21 in componentsInChildren5) { ((Renderer)val21).material = new Material(((Renderer)val21).material); ((Renderer)val21).material.SetTexture("_RemapTex", (Texture)(object)val20); } ContentAddition.AddEffect(turretMuzzleFlash); turretBlueprint = Instantiate("RoR2/Base/Engi/EngiTurretBlueprints.prefab", "AerosBigTurretBlueprint"); ((Component)turretBlueprint.transform.GetChild(1)).gameObject.SetActive(false); GameObject val22 = Object.Instantiate(val8, turretBlueprint.transform.position, Quaternion.Euler(0f, 180f, 0f), turretBlueprint.transform); turretBlueprint.GetComponent().renderers = val22.GetComponentsInChildren(); turretTracer = Instantiate("RoR2/DLC1/VoidSurvivor/VoidSurvivorBeamCorrupt.prefab", "AerosTurretTracer"); ParticleSystemRenderer[] componentsInChildren6 = turretTracer.GetComponentsInChildren(); foreach (ParticleSystemRenderer val23 in componentsInChildren6) { ((Renderer)val23).material = new Material(((Renderer)val23).material); ((Renderer)val23).material.SetTexture("_RemapTex", (Texture)(object)val20); ((Renderer)val23).material.DisableKeyword("VERTEXCOLOR"); if (((Object)val23).name == "Glows") { MainModule main = ((Component)val23).GetComponent().main; ((MainModule)(ref main)).startColor = MinMaxGradient.op_Implicit(Color.green); } } MeshRenderer componentInChildren4 = turretTracer.GetComponentInChildren(); ((Renderer)componentInChildren4).material = new Material(((Renderer)componentInChildren4).material); ((Renderer)componentInChildren4).material.SetTexture("_RemapTex", (Texture)(object)val20); turretBigTracer = PrefabAPI.InstantiateClone(Load("RoR2/DLC1/VoidRaidCrab/TracerVoidRaidCrabTripleBeam.prefab"), "BigTurretBeamTracer", false); turretBigTracer.GetComponent().soundName = ""; turretBigTracer.AddComponent(); LineRenderer[] componentsInChildren7 = turretBigTracer.GetComponentsInChildren(); foreach (LineRenderer val24 in componentsInChildren7) { ((Renderer)val24).enabled = false; } ParticleSystemRenderer[] componentsInChildren8 = turretBigTracer.GetComponentsInChildren(); foreach (ParticleSystemRenderer val25 in componentsInChildren8) { ((Renderer)val25).material = new Material(((Renderer)val25).material); ((Renderer)val25).material.DisableKeyword("VERTEXCOLOR"); if (((Object)val25).name == "BeamParticles, Rings") { ((Renderer)val25).material.SetColor("_TintColor", Color32.op_Implicit(new Color32((byte)10, (byte)189, (byte)10, byte.MaxValue))); ((Renderer)val25).material.SetTextureScale("_MainTex", new Vector2(1f, 0.7f)); ((Renderer)val25).material.SetTexture("_RemapTex", (Texture)(object)Load("RoR2/Base/Common/ColorRamps/texRampHealingVariant.png")); } else { ((Renderer)val25).material.SetColor("_TintColor", Color.green); } } ContentAddition.AddEffect(turretBigTracer); } if (MainPlugin.enableLoader.Value) { slamProjectile = Instantiate("RoR2/Base/Brother/BrotherSunderWave.prefab", "SlamProjectile"); slamProjectile.GetComponent().forceVector = Vector3.up * 2500f; ProjectileController component8 = slamProjectile.GetComponent(); GameObject val26 = Object.Instantiate(component8.ghostPrefab, slamProjectile.transform.position, Quaternion.identity, slamProjectile.transform); Object.Destroy((Object)(object)val26.GetComponent()); Object.Destroy((Object)(object)val26.GetComponent()); slamProjectile.GetComponent().damageType = DamageTypeCombo.op_Implicit((DamageType)0); MeshRenderer component9 = ((Component)val26.GetComponentInChildren()).GetComponent(); ((Renderer)component9).material = new Material(((Renderer)component9).material); ((Renderer)component9).material.SetTexture("_RemapTex", (Texture)(object)Load("RoR2/Base/Common/ColorRamps/texRampLightningYellowOffset.png")); ParticleSystemRenderer[] componentsInChildren9 = val26.GetComponentsInChildren(); foreach (ParticleSystemRenderer val27 in componentsInChildren9) { string name3 = ((Object)val27).name; if (name3 == "Infection, World") { ((Renderer)val27).material = Load("RoR2/Base/Loader/matLoaderTrailImpact.mat"); } if (name3 == "Dust") { ((Renderer)val27).material = Load("RoR2/Base/Loader/matLoaderLightningLarge.mat"); } if (name3 == "Water") { ((Renderer)val27).material = Load("RoR2/Base/Loader/matLoaderLightningTile.mat"); } } component8.ghostPrefab = null; Object.Destroy((Object)(object)slamProjectile.GetComponent()); Object.Destroy((Object)(object)slamProjectile.GetComponent()); ProjectileSimple val28 = slamProjectile.AddComponent(); val28.desiredForwardSpeed = 90f; val28.lifetime = 3f; ContentAddition.AddProjectile(slamProjectile); loaderImpact = Instantiate("RoR2/Base/Loader/OmniImpactVFXLoader.prefab", "LoaderImpact"); Utils.RegisterEffect(loaderImpact, -1f, "Play_loader_m1_impact"); shieldEffect = Instantiate(Assets.Load("ReflectShield"), "ShieldEffect"); Material val29 = Object.Instantiate(Load("RoR2/Base/Engi/matDefenseMatrix.mat")); val29.SetColor("_TintColor", Color32.op_Implicit(new Color32(byte.MaxValue, byte.MaxValue, (byte)158, byte.MaxValue))); val29.SetTexture("_RemapTex", (Texture)(object)Assets.Load("shieldRamp")); val29.SetTexture("_Cloud1Tex", (Texture)null); val29.SetTextureScale("_Cloud1Tex", Vector2.one * 10f); val29.SetFloat("_SoftPower", 0f); val29.SetFloat("_Boost", 0.6f); val29.SetFloat("_RimPower", 2.4f); ((Renderer)shieldEffect.GetComponentInChildren()).material = val29; } if (MainPlugin.enableSeeker.Value) { seekerPrimaryDamage = DamageAPI.ReserveDamageType(); seekerSecondaryDamage = DamageAPI.ReserveDamageType(); DamageTypeCombo genericSecondary = DamageTypeCombo.GenericSecondary; DamageAPI.AddModdedDamageType(ref genericSecondary, seekerSecondaryDamage); palmAreaIndicator = Instantiate(Assets.Load("PalmGuide"), "PalmAreaIndicator"); ((Renderer)palmAreaIndicator.GetComponent()).material = Load("RoR2/DLC2/Seeker/matUnseenHandAreaIndicator.mat"); palmExplosionProjectile = Instantiate("RoR2/DLC2/Seeker/SpiritPunchFinisherProjectile.prefab", "PalmExplosionProjectile", registerNetwork: true); Object.Destroy((Object)(object)palmExplosionProjectile.GetComponent()); Object.Destroy((Object)(object)palmExplosionProjectile.GetComponent()); palmExplosionProjectile.GetComponent().damageType = genericSecondary; ProjectileImpactExplosion component10 = palmExplosionProjectile.GetComponent(); component10.lifetime = 0.4f; component10.explodeOnLifeTimeExpiration = false; palmExplosionProjectile.GetComponent().ghostPrefab = null; ContentAddition.AddProjectile(palmExplosionProjectile); palmProjectileGhost = Instantiate("RoR2/DLC2/Seeker/PalmBlastMovingGhost.prefab", "PalmProjectileGhost"); palmProjectileGhost.GetComponentInChildren().speed = 5f; palmProjectile = Instantiate("RoR2/DLC2/Seeker/PalmBlastProjectile.prefab", "PalmProjectile", registerNetwork: true); Object.Destroy((Object)(object)palmProjectile.GetComponent()); palmProjectile.GetComponent().damageCoefficient = 1f; palmProjectile.GetComponent().damageType = DamageTypeCombo.GenericSecondary; palmProjectile.GetComponent().ghostPrefab = palmProjectileGhost; ProjectileSimple component11 = palmProjectile.GetComponent(); component11.lifetime = 0.4f; component11.desiredForwardSpeed = 27f; ((Behaviour)palmProjectile.GetComponent()).enabled = false; ContentAddition.AddProjectile(palmProjectile); fistProjectileImpact = Instantiate("RoR2/DLC2/Seeker/SpiritPunchDissipateVFX.prefab", "FistProjectileImpact"); Utils.RegisterEffect(fistProjectileImpact, -1f, "Play_mage_m1_impact"); fistProjectileGhost = Instantiate("RoR2/DLC2/Seeker/UnseenHandMovingGhost.prefab", "FistProjectileGhost"); fistProjectileGhost.transform.localScale = Vector3.one * 0.15f; ParticleSystem[] componentsInChildren10 = fistProjectileGhost.GetComponentsInChildren(); foreach (ParticleSystem val30 in componentsInChildren10) { MainModule main2 = val30.main; ((MainModule)(ref main2)).scalingMode = (ParticleSystemScalingMode)0; } fistProjectile = Instantiate("RoR2/Base/Mage/MageFireboltBasic.prefab", "FistProjectile", registerNetwork: true); genericSecondary = DamageTypeCombo.GenericPrimary; DamageAPI.AddModdedDamageType(ref genericSecondary, seekerPrimaryDamage); fistProjectile.GetComponent().damageType = genericSecondary; fistProjectile.GetComponent().ghostPrefab = fistProjectileGhost; ProjectileImpactExplosion component12 = fistProjectile.GetComponent(); component12.impactEffect = Load("RoR2/DLC2/Seeker/SpiritPunchOmniImpactVFX.prefab"); component12.lifetime = 0.5f; ContentAddition.AddProjectile(fistProjectile); seekerGenkidamaProjectileGhost = Instantiate("RoR2/DLC2/Seeker/SpiritPunchFinisherGhost.prefab", "SeekerGenkidamaProjectileGhost"); ParticleSystem[] componentsInChildren11 = seekerGenkidamaProjectileGhost.GetComponentsInChildren(); foreach (ParticleSystem val31 in componentsInChildren11) { string name4 = ((Object)val31).name; MainModule main3 = val31.main; ((MainModule)(ref main3)).scalingMode = (ParticleSystemScalingMode)0; ((MainModule)(ref main3)).loop = true; if (name4 == "Sphere. Waves") { ((Component)val31).gameObject.SetActive(false); } ParticleSystemRenderer component13 = ((Component)val31).GetComponent(); if (name4 == "Sphere") { Material material = ((Renderer)component13).material; ((Renderer)component13).materials = (Material[])(object)new Material[3] { material, default(Material), Load("RoR2/DLC2/Seeker/matSpiritPunchFist.mat") }; } } Object.Destroy((Object)(object)seekerGenkidamaProjectileGhost.GetComponent()); seekerGenkidamaProjectile = Instantiate("RoR2/DLC2/Seeker/SpiritPunchFinisherProjectile.prefab", "SeekerGenkidamaProjectile", registerNetwork: true); seekerGenkidamaProjectile.AddComponent(); seekerGenkidamaProjectile.GetComponent().ghostPrefab = null; SphereCollider component14 = seekerGenkidamaProjectile.GetComponent(); ((Collider)component14).enabled = false; component14.radius = 0.5f; ProjectileSimple component15 = seekerGenkidamaProjectile.GetComponent(); ((Behaviour)component15).enabled = false; component15.lifetime = 8f; component15.desiredForwardSpeed = 100f; component15.updateAfterFiring = true; ProjectileImpactExplosion component16 = seekerGenkidamaProjectile.GetComponent(); ((Behaviour)component16).enabled = false; component16.lifetime = 8f; seekerGenkidamaProjectileGhost.transform.parent = seekerGenkidamaProjectile.transform; seekerGenkidamaProjectileGhost.transform.localPosition = Vector3.zero; seekerGenkidamaProjectileGhost.transform.localScale = Vector3.one; ContentAddition.AddProjectile(seekerGenkidamaProjectile); } if (MainPlugin.enableViend.Value) { viendSecondary = Assets.MainAssetBundle.LoadAsset("viendSecondary"); viendSecondaryCorrupted = Assets.MainAssetBundle.LoadAsset("viendSecondaryCorrupted"); viendUtility = Assets.MainAssetBundle.LoadAsset("viendUtility"); viendUtilityCorrupted = Assets.MainAssetBundle.LoadAsset("viendUtilityCorrupted"); PostProcessProfile val32 = Load("RoR2/Base/title/PostProcessing/ppLocalDoppelganger.asset"); viendPP = PrefabAPI.InstantiateClone(new GameObject("ViendPP"), "ViendPP", false); viendPP.layer = 20; PostProcessVolume val33 = viendPP.AddComponent(); val33.profile = Object.Instantiate(val32); val33.sharedProfile = val33.profile; val33.weight = 1f; val33.priority = 99f; val33.isGlobal = true; ColorGrading val34 = (ColorGrading)val33.profile.settings[1]; ((ParameterOverride)val34.tint).overrideState = false; ((ParameterOverride)val34.colorFilter).overrideState = true; ((ParameterOverride)(object)val34.colorFilter).value = Color32.op_Implicit(new Color32((byte)28, (byte)69, (byte)97, byte.MaxValue)); ((ParameterOverride)(object)val34.mixerRedOutRedIn).value = 300f; PostProcessDuration val35 = viendPP.AddComponent(); ((Behaviour)val35).enabled = false; val35.ppVolume = val33; val35.ppWeightCurve = AnimationCurve.Linear(0f, 1f, 1f, 0f); val35.maxDuration = 0.5f; val35.destroyOnEnd = true; Vignette val36 = (Vignette)val33.profile.settings[3]; ((ParameterOverride)(object)val36.intensity).value = 0.346f; viendPPCorrupted = PrefabAPI.InstantiateClone(new GameObject("ViendPPCorrupted"), "ViendPPCorrupted", false); viendPPCorrupted.layer = 20; PostProcessVolume val37 = viendPPCorrupted.AddComponent(); val37.profile = Object.Instantiate(val32); val37.sharedProfile = val37.profile; val37.weight = 1f; val37.priority = 99f; val37.isGlobal = true; ColorGrading val38 = (ColorGrading)val37.profile.settings[1]; ((ParameterOverride)val38.tint).overrideState = false; ((ParameterOverride)val38.colorFilter).overrideState = true; ((ParameterOverride)(object)val38.colorFilter).value = Color32.op_Implicit(new Color32((byte)97, (byte)28, (byte)97, byte.MaxValue)); ((ParameterOverride)(object)val38.mixerRedOutRedIn).value = 300f; PostProcessDuration val39 = viendPPCorrupted.AddComponent(); ((Behaviour)val39).enabled = false; val39.ppVolume = val37; val39.ppWeightCurve = AnimationCurve.Linear(0f, 1f, 1f, 0f); val39.maxDuration = 0.5f; val39.destroyOnEnd = true; Vignette val40 = (Vignette)val37.profile.settings[3]; ((ParameterOverride)(object)val40.intensity).value = 0.346f; viendContinuousBeam = Instantiate("RoR2/DLC1/MajorAndMinorConstruct/LaserMajorConstruct.prefab", "ViendContinuousBeam"); viendContinuousBeam.transform.localScale = Vector3.one * 0.12f; ((Component)viendContinuousBeam.GetComponentInChildren()).gameObject.SetActive(false); LineRenderer componentInChildren5 = viendContinuousBeam.GetComponentInChildren(); componentInChildren5.widthMultiplier = 0.7f; ((Renderer)componentInChildren5).material = ((Renderer)componentInChildren5).material; ((Renderer)componentInChildren5).material.SetColor("_TintColor", Color.white); Texture2D val41 = Load("RoR2/Base/Common/ColorRamps/texRampNullifierSmooth.png"); ((Renderer)componentInChildren5).material.SetTexture("_RemapTex", (Texture)(object)val41); ParticleSystemRenderer[] componentsInChildren12 = viendContinuousBeam.GetComponentsInChildren(); foreach (ParticleSystemRenderer val42 in componentsInChildren12) { string name5 = ((Object)val42).name; ParticleSystem component17 = ((Component)val42).GetComponent(); MainModule main4 = component17.main; ((MainModule)(ref main4)).scalingMode = (ParticleSystemScalingMode)0; if (name5 == "Hexagon") { ((Renderer)val42).material = new Material(Load("RoR2/DLC1/MissileVoid/matMissileVoidFlare.mat")); ((Renderer)val42).material.SetFloat("_Boost", 6.3f); } if (name5 == "SoftGlowFlash") { ((Renderer)val42).material = new Material(Load("RoR2/Base/Enigma/matArtifactEnigmaGlow.mat")); ((Renderer)val42).material.SetColor("_TintColor", Color32.op_Implicit(new Color32((byte)54, (byte)0, (byte)193, byte.MaxValue))); } if (name5 == "Flare") { ((Component)val42).transform.localScale = Vector3.one * 4f; ((Renderer)val42).material = Load("RoR2/DLC1/VoidRaidCrab/matVoidRaidCrabParticle.mat"); ((MainModule)(ref main4)).simulationSpace = (ParticleSystemSimulationSpace)0; } if (name5 == "LightShafts") { ((Component)val42).transform.localScale = Vector3.one * 7f; ((Renderer)val42).material = new Material(Load("RoR2/DLC1/Common/VFX/matOmniHitspark1GenericAdditive.mat")); ((Renderer)val42).material.SetColor("_TintColor", Color32.op_Implicit(new Color32((byte)127, (byte)0, byte.MaxValue, byte.MaxValue))); ((Renderer)val42).material.SetTexture("_RemapTex", (Texture)(object)val41); } switch (name5) { default: if (!(name5 == "Fire, Electric")) { continue; } break; case "AreaIndicator": case "Debris": case "SmokeKickup": break; } ((Component)val42).gameObject.SetActive(false); } Texture2D val43 = Load("RoR2/DLC1/VoidSurvivor/texRampVoidSurvivorCorrupted1.png"); viendBeamTracer = Instantiate("RoR2/DLC1/VoidRaidCrab/TracerVoidRaidCrabTripleBeam.prefab", "ViendBeamTracer"); ((Component)viendBeamTracer.transform.GetChild(1)).gameObject.SetActive(false); viendBeamTracer.GetComponent().soundName = ""; viendBeamTracer.AddComponent(); LineRenderer[] componentsInChildren13 = viendBeamTracer.GetComponentsInChildren(); foreach (LineRenderer val44 in componentsInChildren13) { ((Renderer)val44).enabled = false; } ParticleSystemRenderer[] componentsInChildren14 = viendBeamTracer.GetComponentsInChildren(); foreach (ParticleSystemRenderer val45 in componentsInChildren14) { ((Renderer)val45).material = new Material(((Renderer)val45).material); ((Renderer)val45).material.DisableKeyword("VERTEXCOLOR"); MainModule main5 = ((Component)val45).GetComponent().main; ((MainModule)(ref main5)).simulationSpeed = ((MainModule)(ref main5)).simulationSpeed * 0.7f; string name6 = ((Object)val45).name; if (name6 == "BeamParticles, Rings") { ((Component)val45).transform.localScale = new Vector3(1f, 0.35f, 0.35f); ((Renderer)val45).material = new Material(((Renderer)val45).material); ((Renderer)val45).material.SetTexture("_RemapTex", (Texture)(object)val43); ((Renderer)val45).material.SetFloat("_Boost", 1f); } if (name6 == "BeamParticles, Small") { ((Renderer)val45).material = Load("RoR2/DLC1/VoidSurvivor/matVoidSurvivorBlasterCoreCorrupted.mat"); } } ContentAddition.AddEffect(viendBeamTracer); viendBeamCharge = Instantiate("RoR2/DLC1/VoidSurvivor/VoidSurvivorChargeCrushHealth.prefab", "ViendBeamCharge"); ScaleParticleSystemDuration val46 = viendBeamCharge.AddComponent(); val46.particleSystems = viendBeamCharge.GetComponentsInChildren(); val46.initialDuration = 0.5f; MeshRenderer componentInChildren6 = viendBeamCharge.GetComponentInChildren(); ((Renderer)componentInChildren6).materials[1] = new Material(((Renderer)componentInChildren6).materials[1]); ((Renderer)componentInChildren6).materials[1].DisableKeyword("VERTEXCOLOR"); ((Renderer)componentInChildren6).materials[1].SetTexture("_RemapTex", (Texture)(object)val43); ((Renderer)componentInChildren6).materials[1].SetColor("_TintColor", Color.white); ParticleSystemRenderer[] componentsInChildren15 = viendBeamCharge.GetComponentsInChildren(); foreach (ParticleSystemRenderer val47 in componentsInChildren15) { string name7 = ((Object)val47).name; ((Renderer)val47).material = new Material(((Renderer)val47).material); ((Renderer)val47).material.DisableKeyword("VERTEXCOLOR"); ((Renderer)val47).material.SetTexture("_RemapTex", (Texture)(object)val43); ((Renderer)val47).material.SetColor("_TintColor", Color.white); } } if (MainPlugin.enableMage.Value) { Texture2D val48 = Load("RoR2/Base/Common/ColorRamps/texRampHuntressSoft.png"); Material val49 = new Material(Load("RoR2/Base/Huntress/matHuntressArrowTrail.mat")); val49.SetTexture("_RemapTex", (Texture)(object)val48); mageMuzzleTrail = Instantiate("RoR2/Base/Mage/MuzzleflashMageLightningLargeWithTrail.prefab", "MageMuzzleTrail"); ((Renderer)mageMuzzleTrail.GetComponentInChildren()).material = val49; Object.Destroy((Object)(object)mageMuzzleTrail.GetComponent()); Object.Destroy((Object)(object)mageMuzzleTrail.GetComponent()); ParticleSystemRenderer[] componentsInChildren16 = mageMuzzleTrail.GetComponentsInChildren(); foreach (ParticleSystemRenderer val50 in componentsInChildren16) { string name8 = ((Object)val50).name; if (name8 == "Matrix, Mesh") { ((Renderer)val50).material = new Material(((Renderer)val50).material); ((Renderer)val50).material.SetTexture("_RemapTex", (Texture)(object)val48); } else if (name8 == "Smoke") { ((Renderer)val50).material = Load("RoR2/Junk/Mage/matMageIceLaser.mat"); } } GameObject obj = Load("RoR2/DLC1/Molotov/MolotovProjectileDotZone.prefab"); fireSwordProjectileDotZone = Instantiate(obj, "FireSwordProjectileDotZone", registerNetwork: true); ((Component)fireSwordProjectileDotZone.transform.GetChild(0).GetChild(0)).gameObject.SetActive(false); fireSwordProjectileDotZone.GetComponent().ghostPrefab = null; Object.Destroy((Object)(object)fireSwordProjectileDotZone.GetComponent()); ProjectileDotZone val51 = fireSwordProjectileDotZone.AddComponent(); val51.resetFrequency = 0.0001f; val51.fireFrequency = 999f; val51.lifetime = 1f; val51.damageCoefficient = 1f; val51.impactEffect = Load("RoR2/Base/Common/VFX/OmniExplosionVFXQuick.prefab"); val51.attackerFiltering = (AttackerFiltering)2; GameObject val52 = Instantiate(Assets.Load("fireSword"), "FireSwordProjectileDotZoneEffect"); val52.transform.parent = fireSwordProjectileDotZone.transform; val52.transform.localPosition = Vector3.zero; val52.transform.localRotation = Quaternion.Euler(0f, 180f, 180f); ChildLocator component18 = val52.GetComponent(); HitBox val53 = fireSwordProjectileDotZone.GetComponent().hitBoxes[0]; ((Component)val53).transform.parent = component18.FindChild("hitbox"); ((Component)val53).transform.localPosition = Vector3.zero; ((Component)val53).transform.localRotation = Quaternion.Euler(Vector3.up * -90f); ((Component)val53).transform.localScale = new Vector3(15f, 10f, 5f); RotateAroundAxis val54 = Utils.AddRotationComponent(((Component)component18.FindChild("scaler")).gameObject, 375f, (RotationAxis)1); val54.relativeTo = (Space)1; DamageTypeCombo generic = DamageTypeCombo.Generic; DamageAPI.AddModdedDamageType(ref generic, flameSwordHit); fireSwordProjectileDotZone.GetComponent().damageType = generic; ContentAddition.AddProjectile(fireSwordProjectileDotZone); fireSwordProjectile = Instantiate(obj, "FireSwordProjectile", registerNetwork: true); ((Component)fireSwordProjectile.transform.GetChild(0).GetChild(0)).gameObject.SetActive(false); fireSwordProjectile.GetComponent().ghostPrefab = null; val51 = fireSwordProjectile.GetComponent(); val51.resetFrequency = 0.0001f; val51.fireFrequency = 999f; val51.lifetime = 10f; val51.damageCoefficient = 1f; ProjectileSimple val55 = fireSwordProjectile.AddComponent(); val55.desiredForwardSpeed = 100f; val55.lifetime = 6f; val52 = Instantiate(Assets.Load("fireSwordProjectile"), "FireSwordProjectileEffect"); val52.transform.parent = fireSwordProjectile.transform; val52.transform.localPosition = Vector3.zero; val52.transform.localRotation = Quaternion.Euler(Vector3.up * 12f); Utils.AddScaleComponent(((Component)val52.GetComponent().FindChild("scaler")).gameObject, 0.15f); val53 = fireSwordProjectile.GetComponent().hitBoxes[0]; ((Component)val53).transform.localPosition = Vector3.up; ((Component)val53).transform.localRotation = Quaternion.Euler(Vector3.right * 90f); ((Component)val53).transform.localScale = new Vector3(1.5f, 0.5f, 3f); fireSwordProjectile.AddComponent(); Rigidbody val56 = fireSwordProjectile.AddComponent(); val56.useGravity = false; val56.detectCollisions = false; fireSwordProjectile.AddComponent(); fireSwordProjectile.AddComponent().duration = 6f; fireSwordProjectile.GetComponent().damageType = generic; ContentAddition.AddProjectile(fireSwordProjectile); fireSwordChargeEffect = Instantiate("RoR2/Base/Mage/MageFlamethrowerEffect.prefab", "FireSwordChargeEffect"); Object.Destroy((Object)(object)fireSwordChargeEffect.GetComponent()); Object.Destroy((Object)(object)fireSwordChargeEffect.GetComponent()); ((Component)fireSwordChargeEffect.transform.GetChild(0)).gameObject.SetActive(false); ((Component)fireSwordChargeEffect.transform.GetChild(3)).gameObject.SetActive(false); ParticleSystem[] componentsInChildren17 = fireSwordChargeEffect.GetComponentsInChildren(true); foreach (ParticleSystem val57 in componentsInChildren17) { string name9 = ((Object)val57).name; bool active = name9 != "FireForward" && name9 != "FireForward (1)" && name9 != "Matrix, Dynamic"; ((Component)val57).gameObject.SetActive(active); if (name9 != "Donut") { MainModule main6 = val57.main; ((MainModule)(ref main6)).simulationSpeed = 0.45f; } } } if (MainPlugin.enableMult.Value) { droneTargetOverlay = new Material(Load("RoR2/Junk/Common/VFX/matShield.mat")); droneTargetOverlay.SetColor("_TintColor", Color.red); droneTargetOverlay.SetFloat("_AlphaBoost", 20f); LanguageAPI.Add("AEROS_MULT_DRONE_NAME", "Repair Drone"); droneBody = Instantiate("RoR2/Base/Drones/Drone2Body.prefab", "AEROS_MulTDroneBody", registerNetwork: true); ModelLocator component19 = droneBody.GetComponent(); Object.Destroy((Object)(object)((Component)component19.modelTransform).gameObject); GameObject val58 = Object.Instantiate(Assets.MainAssetBundle.LoadAsset("multDroneMdl")); val58.transform.SetParent(component19.modelBaseTransform); val58.transform.localPosition = Vector3.zero; val58.transform.localRotation = Quaternion.identity; ChildLocator component20 = val58.GetComponent(); Material val59 = new Material(Load("RoR2/Base/ExplodeOnDeath/matGlassJarLid.mat")); val59.SetColor("_Color", Color.black); val59.SetColor("_EmColor", Color.red); val59.SetFloat("_EmPower", 10f); ((Component)component20.FindChild("glass")).GetComponent().material = val59; droneBody.GetComponent().godMode = true; droneBody.GetComponent().modelTransform = val58.transform; CharacterBody component21 = droneBody.GetComponent(); ((Object)component21).name = "AEROS_MulTDroneBody"; component21.baseNameToken = "AEROS_MULT_DRONE_NAME"; component21.portraitIcon = (Texture)(object)Assets.MainAssetBundle.LoadAsset("dronePortrait").texture; component21.bodyFlags = (BodyFlags)2840; SkillDef skill = Utils.NewSkillDef(typeof(MultDronePrimary), "Weapon", 0, 0f, beginSkillCooldownOnSkillEnd: true, canceledFromSprinting: false, fullRestockOnAssign: true, (InterruptPriority)1, isCombatSkill: true, mustKeyPress: true, cancelSprintingOnActivation: true, 0, 0, 0, (Sprite)null, "AEROS_MULT_DRONE_SKILL", "AEROS_MULT_DRONE_SKILL", Array.Empty()); SkillLocator component22 = droneBody.GetComponent(); component22.primary = Utils.NewGenericSkill(droneBody, skill); DroneCommandReceiver val60 = droneBody.AddComponent(); val60.followPosition = new Vector3(-2f, 1f, 0f); ContentAddition.AddBody(droneBody); droneMaster = Instantiate("RoR2/Base/Drones/Drone2Master.prefab", "AEROS_MulTDroneMaster", registerNetwork: true); Object.Destroy((Object)(object)droneMaster.GetComponent()); droneMaster.GetComponent().isHealer = false; AISkillDriver[] components2 = droneMaster.GetComponents(); components2[0].minDistance = 10f; components2[0].driverUpdateTimerOverride = -1f; components2[0].aimType = (AimType)3; components2[0].shouldSprint = true; components2[1].customName = "ScanEnemy"; components2[1].moveTargetType = (TargetType)0; components2[1].maxDistance = 0f; components2[1].aimType = (AimType)2; components2[1].maxTargetHealthFraction = float.PositiveInfinity; components2[1].driverUpdateTimerOverride = -1f; components2[1].requireSkillReady = true; components2[1].selectionRequiresTargetLoS = true; components2[1].movementType = (MovementType)1; components2[1].moveInputScale = 150f; components2[7].maxDistance = 10f; components2[7].movementType = (MovementType)0; components2[7].driverUpdateTimerOverride = -1f; components2[7].aimType = (AimType)3; components2[6].minDistance = 1f; components2[6].maxDistance = 1f; components2[6].customName = "HoverEnemies"; components2[6].maxTargetHealthFraction = float.PositiveInfinity; components2[6].moveTargetType = (TargetType)0; components2[6].movementType = (MovementType)2; components2[6].aimType = (AimType)2; components2[6].moveInputScale = 1f; droneMaster.AddComponent().hover = components2[6]; Object.Destroy((Object)(object)components2[2]); Object.Destroy((Object)(object)components2[3]); Object.Destroy((Object)(object)components2[4]); Object.Destroy((Object)(object)components2[5]); Object.Destroy((Object)(object)components2[8]); droneMaster.GetComponent().bodyPrefab = droneBody; ContentAddition.AddMaster(droneMaster); } if (MainPlugin.enableCommando.Value) { commandoDashMuzzleflash = Instantiate("RoR2/Base/Commando/CommandoDashJets.prefab", "CommandoDashMuzzleflash"); ParticleSystemRenderer[] componentsInChildren18 = commandoDashMuzzleflash.GetComponentsInChildren(); foreach (ParticleSystemRenderer val61 in componentsInChildren18) { if (((Renderer)val61).material.HasProperty("_RemapTex")) { Material material2 = ((Renderer)val61).material; material2.SetTexture("_RemapTex", (Texture)(object)Load("RoR2/Base/Common/ColorRamps/texRampArtifactShellSoft.png")); } } afterImageMesh = Instantiate(Assets.Load("MeshVFX"), "AfterImageMesh"); Material val62 = new Material(Load("RoR2/DLC2/Items/DelayedDamage/matDelayedDamageShieldShatter.mat")); val62.SetColor("_TintColor", Color32.op_Implicit(new Color32(byte.MaxValue, (byte)11, (byte)54, byte.MaxValue))); val62.SetFloat("_Boost", 5f); ((Renderer)afterImageMesh.GetComponent()).material = val62; AnimateShaderAlpha val63 = afterImageMesh.AddComponent(); val63.alphaCurve = AnimationCurve.EaseInOut(0f, 1f, 1f, 0f); val63.destroyOnEnd = true; val63.timeMax = 0.45f; val63.alphaCurve.AddKey(0.65f, 0f); gunSpinEffect = Instantiate(Assets.Load("CommandoGunMesh"), "GunSpinEffect"); MeshRenderer componentInChildren7 = gunSpinEffect.GetComponentInChildren(); ((Renderer)componentInChildren7).material = Load("RoR2/Base/Commando/matCommandoDualies.mat"); Utils.AddRotationComponent(((Component)componentInChildren7).gameObject, 1440f, (RotationAxis)1); gunSpinTracerEffect = Instantiate("RoR2/Base/Commando/TracerCommandoShotgun.prefab", "GunSpinTracerEffect"); gunSpinTracerEffect.GetComponent().speed = 360f; LineRenderer component23 = gunSpinTracerEffect.GetComponent(); component23.widthMultiplier = 5f; ((Renderer)component23).material = new Material(((Renderer)component23).material); ((Renderer)component23).material.SetFloat("_Boost", 15f); VFXAttributes val64 = gunSpinTracerEffect.AddComponent(); val64.DoNotCullPool = true; val64.DoNotPool = true; ContentAddition.AddEffect(gunSpinTracerEffect); } if (MainPlugin.enableHuntress.Value) { huntressExplosion = Instantiate("RoR2/Base/Huntress/HuntressFireArrowRain.prefab", "HuntressExplosion"); ParticleSystem[] componentsInChildren19 = huntressExplosion.GetComponentsInChildren(); foreach (ParticleSystem val65 in componentsInChildren19) { MainModule main7 = val65.main; ((MainModule)(ref main7)).scalingMode = (ParticleSystemScalingMode)0; } Utils.RegisterEffect(huntressExplosion, -1f, "Play_huntress_R_snipe_shoot", applyScale: true); GameObject val66 = Instantiate("RoR2/Base/Huntress/HuntressGlaiveOrbEffect.prefab", "HuntressGravityProjectileGhost"); Object.Destroy((Object)(object)val66.GetComponent()); Object.Destroy((Object)(object)val66.GetComponent()); val66.AddComponent(); val66.transform.localScale = Vector3.one * 6f; TrailRenderer[] componentsInChildren20 = val66.GetComponentsInChildren(); foreach (TrailRenderer val67 in componentsInChildren20) { val67.widthMultiplier = 0.6f; val67.time = 0.3f; } GameObject val68 = Instantiate("RoR2/Base/Blackhole/GravSphereTether.prefab", "HuntressTether"); ((Renderer)val68.GetComponent()).material = Load("RoR2/Base/Huntress/matHuntressArrowTrail.mat"); huntressGravityProjectile = Instantiate("RoR2/Base/Blackhole/GravSphere.prefab", "HuntressGravityProjectile", registerNetwork: true); huntressGravityProjectile.GetComponent().ghostPrefab = val66; EnumerableExtensions.ForEachTry((IEnumerable)huntressGravityProjectile.GetComponents(), (Action)delegate(AkEvent x) { Object.DestroyImmediate((Object)(object)x); }, (IDictionary)null); EnumerableExtensions.ForEachTry((IEnumerable)huntressGravityProjectile.GetComponents(), (Action)delegate(DetachParticleOnDestroyAndEndEmission x) { Object.DestroyImmediate((Object)(object)x); }, (IDictionary)null); huntressGravityProjectile.GetComponentInChildren().color = Color32.op_Implicit(new Color32((byte)165, byte.MaxValue, (byte)251, byte.MaxValue)); ProjectileSimple component24 = huntressGravityProjectile.GetComponent(); component24.lifetime = 5f; component24.desiredForwardSpeed = 25f; ProjectileImpactExplosion val69 = huntressGravityProjectile.AddComponent(); val69.lifetime = 4f; ((ProjectileExplosion)val69).blastDamageCoefficient = 1f; ((ProjectileExplosion)val69).falloffModel = (FalloffModel)0; ((ProjectileExplosion)val69).blastRadius = 15f; ((ProjectileExplosion)val69).explosionEffect = huntressExplosion; Utils.CreateHitbox("Overlap", huntressGravityProjectile.transform, new Vector3(15f, 5f, 15f), Vector3.zero).transform.localRotation = Quaternion.identity; ProjectileOverlapAttack val70 = huntressGravityProjectile.AddComponent(); val70.damageCoefficient = 0.2f; val70.impactEffect = Load("RoR2/Base/Huntress/OmniImpactVFXHuntress.prefab"); val70.resetInterval = 0.2f; val70.overlapProcCoefficient = 1f; ((Behaviour)huntressGravityProjectile.GetComponent()).enabled = false; ((Component)huntressGravityProjectile.transform.GetChild(2)).gameObject.SetActive(false); ((Component)huntressGravityProjectile.transform.GetChild(4)).gameObject.SetActive(false); ((Component)huntressGravityProjectile.transform.GetChild(6)).gameObject.SetActive(false); ParticleSystemRenderer component25 = ((Component)huntressGravityProjectile.transform.GetChild(1)).GetComponent(); Material val72 = (((Renderer)component25).material = new Material(((Renderer)component25).material)); val72.DisableKeyword("VERTEXCOLOR"); val72.SetTexture("_RemapTex", (Texture)(object)Load("RoR2/Base/Common/ColorRamps/texRampHuntress.png")); RadialForce component26 = huntressGravityProjectile.GetComponent(); component26.tetherVfxOrigin = null; component26.forceCoefficientAtEdge = 0.9f; component26.forceMagnitude = -12000f; ContentAddition.AddProjectile(huntressGravityProjectile); } if (MainPlugin.enableRailgunner.Value) { Texture2D val73 = Load("RoR2/DLC1/Common/ColorRamps/texRampConstructLaserTypeB.png"); Material val74 = new Material(Load("RoR2/DLC3/SolusWing/matGravPulseHoloWall.mat")); val74.SetTexture("_RemapTex", (Texture)(object)val73); val74.SetFloat("_AlphaBoost", 0.15f); val74.SetFloat("_AlphaBias", 0.15f); Material val75 = new Material(Load("RoR2/DLC3/Drone Tech/matDT_SheildSRT75GlowCrosshair.mat")); val75.SetFloat("_AlphaBoost", 0.2f); val75.SetFloat("_AlphaBias", 0f); railgunnerProjectile = Instantiate("RoR2/DLC1/Railgunner/RailgunnerMine.prefab", "RailgunnerProjectile", registerNetwork: true); railgunnerProjectile.GetComponentInChildren(true).color = Color32.op_Implicit(new Color32(byte.MaxValue, (byte)160, (byte)90, byte.MaxValue)); ParticleSystemRenderer[] componentsInChildren21 = railgunnerProjectile.GetComponentsInChildren(true); foreach (ParticleSystemRenderer val76 in componentsInChildren21) { string name10 = ((Object)val76).name; if (name10 == "Pulse") { ((Component)val76).gameObject.SetActive(true); Material val78 = (((Renderer)val76).material = new Material(((Renderer)val76).material)); val78.DisableKeyword("VERTEXCOLOR"); val78.SetTexture("_RemapTex", (Texture)(object)val73); } else { ((Component)val76).gameObject.SetActive(false); } } Object.Destroy((Object)(object)railgunnerProjectile.GetComponent()); Object.Destroy((Object)(object)railgunnerProjectile.GetComponent()); ProjectileImpactExplosion val79 = railgunnerProjectile.AddComponent(); ((ProjectileExplosion)val79).blastRadius = 0f; val79.impactEffect = null; ((ProjectileExplosion)val79).blastDamageCoefficient = 0f; val79.lifetime = 999f; val79.lifetimeAfterImpact = 12f; val79.timerAfterImpact = true; val79.destroyOnEnemy = false; railgunnerProjectile.GetComponent().lifetime = 999f; GameObject val80 = Object.Instantiate(Assets.Load("railgunnerScreen"), railgunnerProjectile.transform.position + Vector3.forward * 3f, Quaternion.identity, railgunnerProjectile.transform); val80.transform.localPosition = Vector3.forward * 3f; Transform child3 = val80.transform.GetChild(0); ((Component)child3).gameObject.AddComponent(); railgunnerProjectile.AddComponent().screenMesh = val80; ((Renderer)((Component)val80.transform.GetChild(1)).GetComponent()).materials = (Material[])(object)new Material[2] { val74, val75 }; val80.SetActive(false); ContentAddition.AddProjectile(railgunnerProjectile); Color color = Color32.op_Implicit(new Color32((byte)169, (byte)189, (byte)231, byte.MaxValue)); railgunnerChargeUI = Instantiate("RoR2/DLC1/Railgunner/RailgunnerCryochargeUI.prefab", "RailgunnerChargeUI"); Image[] componentsInChildren22 = railgunnerChargeUI.GetComponentsInChildren(); foreach (Image val81 in componentsInChildren22) { switch (((Object)val81).name) { case "FillBar": case "SpinnySquare": ((Graphic)val81).color = color; break; case "Outer": ((Graphic)val81).color = Color32.op_Implicit(new Color32((byte)157, (byte)181, (byte)226, (byte)186)); break; } } railgunnerChargeCrosshair = Instantiate("RoR2/DLC1/Railgunner/RailgunnerCryochargeCrosshair.prefab", "RailgunnerChargeCrosshair"); Utils.RecolorUI(railgunnerChargeCrosshair, Color32.op_Implicit(new Color32((byte)169, (byte)189, (byte)231, byte.MaxValue))); railgunnerChargeUIReady = Instantiate("RoR2/DLC1/Railgunner/RailgunnerOverchargeUIReady.prefab", "RailgunnerChargeUIReady"); Utils.RecolorUI(railgunnerChargeUIReady, Color32.op_Implicit(new Color32((byte)169, (byte)189, (byte)231, byte.MaxValue))); Material material3 = Load("RoR2/Base/EliteLightning/matEliteLightningPickup.mat"); railgunnerTracer = Instantiate("RoR2/DLC1/Railgunner/TracerRailgunCryo.prefab", "RailgunnerTracer"); Renderer[] componentsInChildren23 = railgunnerTracer.GetComponentsInChildren(true); foreach (Renderer val82 in componentsInChildren23) { switch (((Object)val82).name) { case "Beam, Linger": val82.material = material3; break; case "BeamParticles, Rings": { Material val84 = (val82.material = new Material(Load("RoR2/DLC3/SolusAmalgamator/matSolusAmalgamatorLightning.mat"))); val84.SetColor("_TintColor", Color.white); val84.SetTexture("_RemapTex", (Texture)(object)Load("RoR2/Base/Common/ColorRamps/texRampLightning2.png")); break; } case "BeamParticles, Small": val82.enabled = false; break; case "mdlRailgunnerBeamMesh": val82.material = Load("RoR2/DLC3/Items/JumpDamageStrike/matJumpDamageStrikeLightning.mat"); break; } } ContentAddition.AddEffect(railgunnerTracer); railgunnerNova = Instantiate("RoR2/Base/Jellyfish/JellyfishNova.prefab", "RailgunnerNova"); Renderer[] componentsInChildren24 = railgunnerNova.GetComponentsInChildren(true); foreach (Renderer val85 in componentsInChildren24) { switch (((Object)val85).name) { case "Nova Sphere": { Material val86 = new Material(val85.material); val86.SetFloat("_Boost", 5f); val86.SetFloat("_RimPower", 1.1f); val85.material = val86; break; } case "Big Splash": val85.material = Load("RoR2/Base/Common/VFX/matJellyfishLightningLarge.mat"); break; case "Sparks, Collision": val85.material = material3; break; } } ContentAddition.AddEffect(railgunnerNova); } if (MainPlugin.enableFalseSon.Value) { Texture2D val87 = Load("RoR2/DLC1/Common/ColorRamps/texRampConstructLaserTypeB.png"); falseSonBuffWardEffect = Instantiate("RoR2/Base/Huntress/HuntressArrowRainIndicator.prefab", "FalseSonBuffWardEffect"); MeshRenderer componentInChildren8 = falseSonBuffWardEffect.GetComponentInChildren(false); ((Renderer)componentInChildren8).material = new Material(Load("RoR2/Base/Captain/matCaptainAirstrikeAreaIndicator.mat")); ((Renderer)componentInChildren8).material.SetTexture("_RemapTex", (Texture)(object)val87); GameObject val88 = Object.Instantiate(((Component)Load("RoR2/Base/Mushroom/MushroomWard.prefab").GetComponentsInChildren()[1]).gameObject, falseSonBuffWardEffect.transform.position, Quaternion.identity, falseSonBuffWardEffect.transform); ParticleSystemRenderer component27 = val88.GetComponent(); ((Renderer)component27).material = new Material(((Renderer)component27).material); ((Renderer)component27).material.SetTexture("_RemapTex", (Texture)(object)val87); MainModule main8 = ((Component)component27).GetComponent().main; ((MainModule)(ref main8)).simulationSpeed = 5f; GameObject val89 = Load("RoR2/DLC2/FalseSon/FalseSonChargedLaser.prefab"); falseSonLaserMuzzles = Instantiate(Assets.Load("laserMuzzles"), "FalseSonLaserMuzzles"); NameTransformPair[] transformPairs = falseSonLaserMuzzles.GetComponent().transformPairs; foreach (NameTransformPair val90 in transformPairs) { GameObject val91 = Object.Instantiate(val89, val90.transform.position, Quaternion.identity, val90.transform); DetachParticleOnDestroyAndEndEmission[] componentsInChildren25 = val91.GetComponentsInChildren(true); foreach (DetachParticleOnDestroyAndEndEmission val92 in componentsInChildren25) { Object.DestroyImmediate((Object)(object)val92); } Transform val93 = ((Component)val90.transform).GetComponentInChildren().FindChild("LaserEnd"); val93.position = Vector3.forward * MainPlugin.falseSonSpecialMaxDistance.Value; } } if (MainPlugin.enableBandit.Value) { fwGuide = Instantiate(Assets.Load("FwGuide"), "FwGuide"); banditGrenadeGhost = Instantiate("RoR2/Base/Commando/CommandoGrenadeGhost.prefab", "BanditGrenadeGhost"); banditGrenadeGhost.GetComponentInChildren().mesh = Load("RoR2/Base/StunChanceOnHit/DisplayStunGrenade.prefab").GetComponentInChildren().mesh; TrailRenderer componentInChildren9 = banditGrenadeGhost.GetComponentInChildren(); componentInChildren9.startColor = Color32.op_Implicit(new Color32(byte.MaxValue, (byte)55, (byte)0, byte.MaxValue)); componentInChildren9.endColor = Color32.op_Implicit(new Color32(byte.MaxValue, (byte)0, (byte)0, (byte)100)); Material val94 = new Material(Load("RoR2/Base/Bandit2/matBandit2SplatterOpaqueTrailAlt.mat")); val94.SetColor("_EmColor", Color.white); ((Renderer)componentInChildren9).material = val94; banditGrenade = Instantiate("RoR2/Base/Commando/CommandoGrenadeProjectile.prefab", "BanditGrenade", registerNetwork: true); banditGrenade.GetComponent().ghostPrefab = banditGrenadeGhost; banditGrenade.GetComponent().damageType = DamageTypeCombo.GenericUtility | DamageTypeCombo.op_Implicit((DamageType)32); ProjectileImpactExplosion component28 = banditGrenade.GetComponent(); component28.lifetimeAfterImpact = 0.1f; component28.impactEffect = Load("RoR2/Base/StunChanceOnHit/ImpactStunGrenade.prefab"); ContentAddition.AddProjectile(banditGrenade); } if (MainPlugin.enableCroco.Value) { crocoSecondaryDamage = DamageAPI.ReserveDamageType(); crocoSpecialDamage = DamageAPI.ReserveDamageType(); crocoSlashMat = new Material(Load("RoR2/Base/Croco/matCrocoSlashDiseasedBright.mat")); crocoSlashMat.SetTexture("_MainTex", (Texture)(object)Load("RoR2/Base/Common/VFX/texOmniHitspark3Mask.png")); crocoSlashMat.SetTextureScale("_MainTex", new Vector2(2f, 2f)); crocoSlashMat.SetColor("_TintColor", Color32.op_Implicit(new Color32(byte.MaxValue, (byte)59, (byte)53, byte.MaxValue))); crocoSlash = Instantiate("RoR2/Base/Croco/CrocoComboFinisherSlash.prefab", "CrocoSlash"); ((Renderer)crocoSlash.GetComponentInChildren()).material = crocoSlashMat; Object.Destroy((Object)(object)crocoSlash.GetComponent()); crocoSlashHit = Instantiate("RoR2/Base/Common/VFX/OmniImpactVFXLarge.prefab", "CrocoSlashHit"); Utils.RegisterEffect(crocoSlashHit, -1f, "Play_acrid_m2_bite_hit"); crocoExplosionEffect = Instantiate("RoR2/Base/Croco/CrocoDiseaseImpactEffect.prefab", "CrocoExplosionEffect"); GameObject val95 = Object.Instantiate(Load("RoR2/Base/MiniMushroom/SporeGrenadeGasImpact.prefab"), crocoExplosionEffect.transform.position, Quaternion.identity, crocoExplosionEffect.transform); Object.Destroy((Object)(object)val95.GetComponent()); Object.Destroy((Object)(object)val95.GetComponent()); Object.Destroy((Object)(object)val95.GetComponent()); ParticleSystem[] componentsInChildren26 = crocoExplosionEffect.GetComponentsInChildren(); foreach (ParticleSystem val96 in componentsInChildren26) { MainModule main9 = val96.main; ((MainModule)(ref main9)).scalingMode = (ParticleSystemScalingMode)0; } crocoExplosionEffect.transform.localScale = Vector3.one * 4f; ContentAddition.AddEffect(crocoExplosionEffect); crocoGasHitEffect = Instantiate("RoR2/Base/MiniMushroom/SporeGrenadeGasImpact.prefab", "CrocoGasHitEffect"); ((Component)crocoGasHitEffect.transform.GetChild(0)).gameObject.SetActive(false); Utils.RegisterEffect(crocoGasHitEffect, 0.4f, "Play_acrid_m2_explode"); posMuzzle = Instantiate(new GameObject(), "PosMuzzle"); } } } internal class BanditUtility : BaseSkillState { private float duration = 0.3f; public override void OnEnter() { //IL_008f: 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_0098: Unknown result type (might be due to invalid IL or missing references) //IL_009d: Unknown result type (might be due to invalid IL or missing references) //IL_00a2: Unknown result type (might be due to invalid IL or missing references) //IL_00a3: Unknown result type (might be due to invalid IL or missing references) //IL_00a4: 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_00df: Unknown result type (might be due to invalid IL or missing references) //IL_00eb: Unknown result type (might be due to invalid IL or missing references) //IL_00f0: Unknown result type (might be due to invalid IL or missing references) //IL_00fe: Unknown result type (might be due to invalid IL or missing references) //IL_00ff: 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_010e: Unknown result type (might be due to invalid IL or missing references) //IL_0130: Unknown result type (might be due to invalid IL or missing references) //IL_0135: Unknown result type (might be due to invalid IL or missing references) //IL_0136: 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) ((BaseState)this).OnEnter(); ((BaseState)this).StartAimMode(1f, false); ((EntityState)this).characterBody.isSprinting = true; ((EntityState)this).PlayAnimation("Body", "Dash", "Utility", duration, 0f); AkSoundEngine.PostEvent(StealthMode.exitStealthSound, ((EntityState)this).gameObject); AkSoundEngine.PostEvent("Play_commando_M2_grenade_throw", ((EntityState)this).gameObject); ((EntityState)this).characterBody.SetSpreadBloom(0f, false); EffectManager.SimpleMuzzleFlash(StealthMode.smokeBombEffectPrefab, ((EntityState)this).gameObject, StealthMode.smokeBombMuzzleString, false); Ray aimRay = ((BaseState)this).GetAimRay(); Vector3 forwardDirection = Utils.GetForwardDirection(((Ray)(ref aimRay)).direction); Vector3 forward = forwardDirection; GameObject val = Object.Instantiate(Prefabs.fwGuide); val.transform.forward = forward; Transform child = val.transform.GetChild(0); child.localRotation = Quaternion.Euler(MainPlugin.banditUtilityAngle.Value, 0f, 0f); forward = child.forward; EntityState.Destroy((Object)(object)val); ((EntityState)this).characterMotor.velocity = -forward * 42f; if (((EntityState)this).isAuthority) { ProjectileManager.instance.FireProjectile(Prefabs.banditGrenade, ((EntityState)this).characterBody.corePosition, Quaternion.LookRotation(forward), ((EntityState)this).gameObject, ((BaseState)this).damageStat * MainPlugin.banditUtilityDamage.Value, 1000f, ((BaseState)this).RollCrit(), (DamageColorIndex)0, (GameObject)null, -1f, (DamageTypeCombo?)DamageTypeCombo.GenericUtility); } if (NetworkServer.active) { ((EntityState)this).characterBody.AddBuff(Buffs.HiddenInvincibility); } } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); if (((EntityState)this).isAuthority && ((EntityState)this).fixedAge >= duration) { ((EntityState)this).outer.SetNextStateToMain(); } } public override void OnExit() { if (NetworkServer.active) { ((EntityState)this).characterBody.RemoveBuff(Buffs.HiddenInvincibility); } ((EntityState)this).OnExit(); } 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 CaptainPrimary : BaseSkillState { private float duration; private float baseDuration = 0.95f; private float delay = 0.095f; private float stopwatch; private int maxShots = 3; private int shotCount; public override void OnEnter() { ((BaseState)this).OnEnter(); ((BaseState)this).StartAimMode(2f, false); duration = baseDuration / Math.Min(((BaseState)this).attackSpeedStat, 5.85f); delay /= Math.Min(((BaseState)this).attackSpeedStat, 5.85f); } public override void FixedUpdate() { //IL_00ee: Unknown result type (might be due to invalid IL or missing references) //IL_00f3: Unknown result type (might be due to invalid IL or missing references) //IL_00fb: Unknown result type (might be due to invalid IL or missing references) //IL_0100: Unknown result type (might be due to invalid IL or missing references) //IL_0107: Unknown result type (might be due to invalid IL or missing references) //IL_010a: Unknown result type (might be due to invalid IL or missing references) //IL_0115: Unknown result type (might be due to invalid IL or missing references) //IL_0118: Unknown result type (might be due to invalid IL or missing references) //IL_011d: Unknown result type (might be due to invalid IL or missing references) //IL_0122: Unknown result type (might be due to invalid IL or missing references) //IL_0139: Unknown result type (might be due to invalid IL or missing references) //IL_013b: Unknown result type (might be due to invalid IL or missing references) //IL_0140: Unknown result type (might be due to invalid IL or missing references) //IL_0141: Unknown result type (might be due to invalid IL or missing references) //IL_0146: Unknown result type (might be due to invalid IL or missing references) //IL_014b: Unknown result type (might be due to invalid IL or missing references) //IL_014d: 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_015e: Unknown result type (might be due to invalid IL or missing references) //IL_0169: Unknown result type (might be due to invalid IL or missing references) //IL_016a: Unknown result type (might be due to invalid IL or missing references) //IL_016f: Unknown result type (might be due to invalid IL or missing references) //IL_0174: 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_0185: Unknown result type (might be due to invalid IL or missing references) //IL_0191: Unknown result type (might be due to invalid IL or missing references) //IL_019d: Unknown result type (might be due to invalid IL or missing references) //IL_01a8: Unknown result type (might be due to invalid IL or missing references) //IL_01af: Unknown result type (might be due to invalid IL or missing references) //IL_01b5: Unknown result type (might be due to invalid IL or missing references) //IL_01bb: Unknown result type (might be due to invalid IL or missing references) //IL_01c6: Unknown result type (might be due to invalid IL or missing references) //IL_01d1: 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_01d9: 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) //IL_01e3: Unknown result type (might be due to invalid IL or missing references) //IL_01ea: Unknown result type (might be due to invalid IL or missing references) //IL_01fa: Unknown result type (might be due to invalid IL or missing references) //IL_0205: 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) ((EntityState)this).FixedUpdate(); stopwatch += Time.fixedDeltaTime; if (stopwatch >= delay && shotCount < maxShots) { stopwatch = 0f; shotCount++; ((EntityState)this).PlayAnimation("Gesture, Additive", FireCaptainShotgun.FireCaptainShotgunStateHash); ((EntityState)this).PlayAnimation("Gesture, Override", FireCaptainShotgun.FireCaptainShotgunStateHash); AkSoundEngine.PostEvent(FireBarrage.fireBarrageSoundString, ((EntityState)this).gameObject); EffectManager.SimpleMuzzleFlash(Prefabs.Load("RoR2/Base/Common/VFX/Muzzleflash1.prefab"), ((EntityState)this).gameObject, ChargeCaptainShotgun.muzzleName, false); if (((EntityState)this).isAuthority) { float num = 0.8f; ((EntityState)this).characterBody.AddSpreadBloom(num); ((BaseState)this).AddRecoil(-1f * num, -1.5f * num, -0.25f * num, 0.25f * num); Ray aimRay = ((BaseState)this).GetAimRay(); float num2 = 0.0425f; new BulletAttack { bulletCount = 1u, aimVector = ((Ray)(ref aimRay)).direction, origin = ((Ray)(ref aimRay)).origin, damage = ((BaseState)this).damageStat * MainPlugin.burstDMG.Value, damageColorIndex = (DamageColorIndex)0, damageType = DamageTypeCombo.GenericPrimary, falloffModel = (FalloffModel)0, maxDistance = 250f, force = 20f, hitMask = CommonMasks.bullet, minSpread = 0f - num2, maxSpread = num2, isCrit = ((BaseState)this).RollCrit(), owner = ((EntityState)this).gameObject, muzzleName = ChargeCaptainShotgun.muzzleName, smartCollision = false, procChainMask = default(ProcChainMask), procCoefficient = 0.6f, radius = 0.08f, sniper = false, stopperMask = CommonMasks.bullet, weapon = null, tracerEffectPrefab = Prefabs.Load("RoR2/Base/Captain/TracerCaptainShotgun.prefab"), spreadPitchScale = 1f, spreadYawScale = 1f, hitEffectPrefab = Prefabs.Load("RoR2/Base/Captain/HitsparkCaptainShotgun.prefab") }.Fire(); } } if (((EntityState)this).fixedAge >= duration && ((EntityState)this).isAuthority) { ((EntityState)this).outer.SetNextStateToMain(); } } public override void OnExit() { ((EntityState)this).OnExit(); } public override InterruptPriority GetMinimumInterruptPriority() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (InterruptPriority)1; } } internal class CaptainSecondary : BaseSkillState { private float duration; private float baseDuration = 0.35f; public override void OnEnter() { //IL_00b4: Unknown result type (might be due to invalid IL or missing references) //IL_00b9: Unknown result type (might be due to invalid IL or missing references) //IL_00c6: Unknown result type (might be due to invalid IL or missing references) //IL_00cd: Unknown result type (might be due to invalid IL or missing references) //IL_00d2: Unknown result type (might be due to invalid IL or missing references) //IL_00ef: Unknown result type (might be due to invalid IL or missing references) ((BaseState)this).OnEnter(); duration = baseDuration / ((BaseState)this).attackSpeedStat; ((EntityState)this).PlayAnimation("Gesture, Additive", FireTazer.FireTazerStateHash, FireTazer.FireTazerParamHash, duration); ((EntityState)this).PlayAnimation("Gesture, Override", FireTazer.FireTazerStateHash, FireTazer.FireTazerParamHash, duration); EffectManager.SimpleMuzzleFlash(Prefabs.Load("RoR2/Base/Common/VFX/Muzzleflash1.prefab"), ((EntityState)this).gameObject, ChargeCaptainShotgun.muzzleName, false); if (((EntityState)this).isAuthority) { float num = 0.8f; ((EntityState)this).characterBody.AddSpreadBloom(num); ((BaseState)this).AddRecoil(-1f * num, -1.5f * num, -0.25f * num, 0.25f * num); Ray aimRay = ((BaseState)this).GetAimRay(); ProjectileManager.instance.FireProjectile(Prefabs.buffProjectile, ((Ray)(ref aimRay)).origin, Util.QuaternionSafeLookRotation(((Ray)(ref aimRay)).direction), ((EntityState)this).gameObject, 0f, 1220f, false, (DamageColorIndex)0, (GameObject)null, -1f, (DamageTypeCombo?)DamageTypeCombo.GenericSecondary); } AkSoundEngine.PostEvent(FireCaptainShotgun.tightSoundString, ((EntityState)this).gameObject); } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); if (((EntityState)this).fixedAge >= duration && ((EntityState)this).isAuthority) { ((EntityState)this).outer.SetNextStateToMain(); } } public override void OnExit() { ((EntityState)this).OnExit(); } 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 CommandoSpecial : BaseSkillState { private float duration = MainPlugin.commandoSpecialChargeTime.Value; private float charge; private GameObject effectR; private GameObject effectL; private GameObject gunL; private GameObject gunR; private GameObject reloadFXR; private GameObject reloadFXL; private uint ID; public override void OnEnter() { ((BaseState)this).OnEnter(); ((BaseState)this).StartAimMode(2f, false); duration /= ((BaseState)this).attackSpeedStat; ChildLocator modelChildLocator = ((EntityState)this).GetModelChildLocator(); gunR = ((Component)modelChildLocator.FindChild("GunMeshR")).gameObject; gunR.SetActive(false); gunL = ((Component)modelChildLocator.FindChild("GunMeshL")).gameObject; gunL.SetActive(false); reloadFXR = ((Component)modelChildLocator.FindChild("ReloadFXR")).gameObject; reloadFXR.SetActive(true); reloadFXL = ((Component)modelChildLocator.FindChild("ReloadFXL")).gameObject; reloadFXL.SetActive(true); ID = AkSoundEngine.PostEvent("Play_AerosSkills_GunSpin_Start", ((EntityState)this).gameObject); } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); ((BaseState)this).StartAimMode(2f, false); charge = Mathf.Clamp01(((EntityState)this).fixedAge / duration); if (((EntityState)this).isAuthority && !((BaseSkillState)this).IsKeyDownAuthority()) { ((EntityState)this).outer.SetNextState((EntityState)(object)new CommandoSpecialFire { charge = charge }); } } public override void OnExit() { AkSoundEngine.StopPlayingID(ID); AkSoundEngine.PostEvent("Play_AerosSkills_GunSpin_End", ((EntityState)this).gameObject); ((EntityState)this).PlayAnimation("Gesture Override", "ReloadPistolsExit"); if (Object.op_Implicit((Object)(object)gunR)) { gunR.SetActive(true); } if (Object.op_Implicit((Object)(object)gunL)) { gunL.SetActive(true); } if (Object.op_Implicit((Object)(object)reloadFXR)) { reloadFXR.SetActive(false); } if (Object.op_Implicit((Object)(object)reloadFXL)) { reloadFXL.SetActive(false); } if (Object.op_Implicit((Object)(object)effectR)) { EntityState.Destroy((Object)(object)effectR); } if (Object.op_Implicit((Object)(object)effectL)) { EntityState.Destroy((Object)(object)effectL); } ((EntityState)this).OnExit(); } 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 CommandoSpecialFire : BaseSkillState { public float charge; private int fireCount; private float minDamage = MainPlugin.commandoSpecialMinDamage.Value; private float maxDamage = MainPlugin.commandoSpecialMaxDamage.Value; private float fireInterval; private bool maxCharge => charge >= 1f; private GameObject tracerEffect => Prefabs.gunSpinTracerEffect; private GameObject hitEffect => Prefabs.Load("RoR2/Base/Commando/HitsparkCommandoShotgun.prefab"); private GameObject muzzleflash => Prefabs.Load("RoR2/Base/Commando/MuzzleflashFMJ.prefab"); public override void OnSerialize(NetworkWriter writer) { ((BaseSkillState)this).OnSerialize(writer); writer.Write((byte)charge); } public override void OnDeserialize(NetworkReader reader) { ((BaseSkillState)this).OnDeserialize(reader); charge = (int)reader.ReadByte(); } public override void OnEnter() { ((BaseState)this).OnEnter(); fireInterval = 0.125f / ((BaseState)this).attackSpeedStat; Fire(); } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); if (((EntityState)this).fixedAge >= fireInterval) { ((EntityState)this).fixedAge = 0f; Fire(); } if (((EntityState)this).isAuthority && fireCount >= 2) { ((EntityState)this).outer.SetNextStateToMain(); } } private void Fire() { //IL_00ac: Unknown result type (might be due to invalid IL or missing references) //IL_00b1: Unknown result type (might be due to invalid IL or missing references) //IL_00b2: 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_00f9: Unknown result type (might be due to invalid IL or missing references) //IL_0119: Unknown result type (might be due to invalid IL or missing references) //IL_011e: Unknown result type (might be due to invalid IL or missing references) //IL_013f: Unknown result type (might be due to invalid IL or missing references) //IL_014d: Unknown result type (might be due to invalid IL or missing references) //IL_0154: Unknown result type (might be due to invalid IL or missing references) //IL_015b: Unknown result type (might be due to invalid IL or missing references) //IL_0160: Unknown result type (might be due to invalid IL or missing references) //IL_0165: Unknown result type (might be due to invalid IL or missing references) fireCount++; bool flag = fireCount == 2; EffectManager.SimpleMuzzleFlash(muzzleflash, ((EntityState)this).gameObject, flag ? "MuzzleLeft" : "MuzzleRight", false); float num = 2.3f; ((BaseState)this).AddRecoil(-1f * num, -1.5f * num, -0.25f * num, 0.25f * num); ((EntityState)this).characterBody.AddSpreadBloom(1f); AkSoundEngine.PostEvent("Play_AerosSkills_GunSpin_Fire", ((EntityState)this).gameObject); ((EntityState)this).PlayAnimation(flag ? "Gesture Additive, Left" : "Gesture Additive, Right", flag ? FirePistol2.FirePistolLeftStateHash : FirePistol2.FirePistolRightStateHash); Ray aimRay = ((BaseState)this).GetAimRay(); RaycastHit val = default(RaycastHit); if (Physics.Raycast(aimRay, ref val, 350f, LayerMask.op_Implicit(((LayerIndex)(ref LayerIndex.world)).mask))) { Prefabs.gunSpinTracerEffect.GetComponent().speed = 360f + ((RaycastHit)(ref val)).distance * 2.22f; } NewBulletAttack(aimRay, flag ? "MuzzleLeft" : "MuzzleRight"); if (maxCharge && ((RaycastHit)(ref val)).point != Vector3.zero) { ((BaseState)this).FindModelChild("MuzzleMuzzle").position = ((RaycastHit)(ref val)).point; NewBulletAttack(new Ray(((RaycastHit)(ref val)).point, Vector3.Reflect(((Ray)(ref aimRay)).direction, ((RaycastHit)(ref val)).normal)), "MuzzleMuzzle"); } } public void NewBulletAttack(Ray aimRay, string muzzle) { //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_001a: Unknown result type (might be due to invalid IL or missing references) //IL_0021: Unknown result type (might be due to invalid IL or missing references) //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002f: Unknown result type (might be due to invalid IL or missing references) //IL_0032: 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_006a: Unknown result type (might be due to invalid IL or missing references) //IL_006c: Unknown result type (might be due to invalid IL or missing references) //IL_0071: Unknown result type (might be due to invalid IL or missing references) //IL_0072: Unknown result type (might be due to invalid IL or missing references) //IL_0077: Unknown result type (might be due to invalid IL or missing references) //IL_007c: Unknown result type (might be due to invalid IL or missing references) //IL_007e: Unknown result type (might be due to invalid IL or missing references) //IL_0083: 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_00b4: Unknown result type (might be due to invalid IL or missing references) //IL_00b5: Unknown result type (might be due to invalid IL or missing references) //IL_00ba: Unknown result type (might be due to invalid IL or missing references) //IL_00bf: Unknown result type (might be due to invalid IL or missing references) //IL_00c7: Unknown result type (might be due to invalid IL or missing references) //IL_00ce: Unknown result type (might be due to invalid IL or missing references) //IL_00da: Unknown result type (might be due to invalid IL or missing references) //IL_00e6: Unknown result type (might be due to invalid IL or missing references) //IL_00ed: Unknown result type (might be due to invalid IL or missing references) //IL_00f4: Unknown result type (might be due to invalid IL or missing references) //IL_00fa: Unknown result type (might be due to invalid IL or missing references) //IL_0100: Unknown result type (might be due to invalid IL or missing references) //IL_010b: Unknown result type (might be due to invalid IL or missing references) //IL_0116: Unknown result type (might be due to invalid IL or missing references) //IL_011d: Unknown result type (might be due to invalid IL or missing references) //IL_0123: Unknown result type (might be due to invalid IL or missing references) //IL_0128: Unknown result type (might be due to invalid IL or missing references) //IL_012d: Unknown result type (might be due to invalid IL or missing references) //IL_0134: Unknown result type (might be due to invalid IL or missing references) //IL_0140: Unknown result type (might be due to invalid IL or missing references) //IL_014b: 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) if (((EntityState)this).isAuthority) { float num = 0.1425f; new BulletAttack { bulletCount = 1u, aimVector = ((Ray)(ref aimRay)).direction, origin = ((Ray)(ref aimRay)).origin, damage = ((BaseState)this).damageStat * Util.Remap(charge, 0f, 1f, minDamage, maxDamage), damageColorIndex = (DamageColorIndex)0, damageType = DamageTypeCombo.GenericSpecial, falloffModel = (FalloffModel)0, maxDistance = 350f, force = Util.Remap(charge, 0f, 1f, 500f, 2500f), hitMask = CommonMasks.bullet, minSpread = 0f - num, maxSpread = num, isCrit = ((BaseState)this).RollCrit(), owner = ((EntityState)this).gameObject, muzzleName = muzzle, smartCollision = false, procChainMask = default(ProcChainMask), procCoefficient = 1f, radius = 0.68f, sniper = false, stopperMask = ((LayerIndex)(ref LayerIndex.world)).mask, weapon = null, tracerEffectPrefab = tracerEffect, spreadPitchScale = 1f, spreadYawScale = 1f, hitEffectPrefab = hitEffect }.Fire(); } } } internal class CommandoUtility : BaseSkillState { private float duration = 0.3f; private AnimationCurve curve = AnimationCurve.EaseInOut(0f, 1f, 1f, 0f); private float speed; private float stopwatch = 1f; private float afterImageInterval; private SkinnedMeshRenderer mesh; private OverlapAttack attack; private Vector3 direction; private Transform modelTransform; public override void OnEnter() { //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_0177: Unknown result type (might be due to invalid IL or missing references) //IL_017c: Unknown result type (might be due to invalid IL or missing references) //IL_0188: Unknown result type (might be due to invalid IL or missing references) //IL_018d: Unknown result type (might be due to invalid IL or missing references) ((BaseState)this).OnEnter(); afterImageInterval = 0.01f; speed = (float)(((BaseState)this).isGrounded ? 100 : 130) * Math.Max(1f, ((EntityState)this).characterBody.moveSpeed / ((EntityState)this).characterBody.baseMoveSpeed); ((EntityState)this).characterBody.isSprinting = true; ((EntityState)this).PlayAnimation("Body", "Dash", "Utility", duration, 0f); AkSoundEngine.PostEvent(SlideState.soundString, ((EntityState)this).gameObject); modelTransform = ((EntityState)this).GetModelTransform(); attack = ((BaseState)this).InitMeleeOverlap(MainPlugin.commandoUtilityDamage.Value, Prefabs.Load("RoR2/Base/Common/VFX/OmniImpactVFXMedium.prefab"), modelTransform, "AerosDash"); mesh = ((Component)modelTransform).GetComponentInChildren(); Transform val = ((BaseState)this).FindModelChild("LeftJet"); Transform val2 = ((BaseState)this).FindModelChild("RightJet"); if (Object.op_Implicit((Object)(object)val)) { Object.Instantiate(Prefabs.commandoDashMuzzleflash, val); } if (Object.op_Implicit((Object)(object)val2)) { Object.Instantiate(Prefabs.commandoDashMuzzleflash, val2); } ((EntityState)this).characterBody.SetSpreadBloom(0f, false); if (((BaseState)this).isGrounded) { ((EntityState)this).PlayAnimation("Body", SlideState.SlideForwardStateHash, SlideState.SlideForwardParamHash, SlideState.slideDuration); } else { ((EntityState)this).PlayAnimation("Body", SlideState.JumpStateHash); } Ray aimRay = ((BaseState)this).GetAimRay(); direction = ((Ray)(ref aimRay)).direction; ((EntityState)this).characterDirection.forward = Utils.GetForwardDirection(direction); } public override void FixedUpdate() { //IL_0046: 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) //IL_0085: Unknown result type (might be due to invalid IL or missing references) //IL_008a: Unknown result type (might be due to invalid IL or missing references) //IL_0096: 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_00c4: Unknown result type (might be due to invalid IL or missing references) //IL_00ce: 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_00d8: Unknown result type (might be due to invalid IL or missing references) ((EntityState)this).FixedUpdate(); stopwatch += Time.fixedDeltaTime; if (stopwatch >= afterImageInterval) { stopwatch = 0f; GameObject val = Object.Instantiate(Prefabs.afterImageMesh, modelTransform.position, modelTransform.rotation); mesh.BakeMesh(val.GetComponent().mesh); } if (((EntityState)this).isAuthority) { ((EntityState)this).characterMotor.velocity = Vector3.zero; CharacterMotor characterMotor = ((EntityState)this).characterMotor; characterMotor.rootMotion += direction * speed * curve.Evaluate(((EntityState)this).fixedAge / duration) * Time.fixedDeltaTime; } if ((((EntityState)this).isAuthority && ((EntityState)this).fixedAge >= duration) || attack.Fire((List)null)) { ((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)2; } } internal class CrocoSecondary : Slash { private GameObject effectInstance; public override void OnEnter() { //IL_0098: Unknown result type (might be due to invalid IL or missing references) //IL_009d: Unknown result type (might be due to invalid IL or missing references) //IL_00a0: Unknown result type (might be due to invalid IL or missing references) //IL_00b1: Unknown result type (might be due to invalid IL or missing references) //IL_00b2: Unknown result type (might be due to invalid IL or missing references) ((BasicMeleeAttack)this).baseDuration = 0.65f; base.hasGrantedBuff = true; base.step = 2; ((BasicMeleeAttack)this).hitBoxGroupName = "AerosSlash"; ((BasicMeleeAttack)this).mecanimHitboxActiveParameter = "Slash3.hitBoxActive"; ((BasicMeleeAttack)this).hitPauseDuration = 0.07f; ((BasicMeleeAttack)this).swingEffectPrefab = null; ((BasicMeleeAttack)this).hitEffectPrefab = Prefabs.crocoSlashHit; ((BasicMeleeAttack)this).swingEffectMuzzleString = "Slash3"; ((BasicMeleeAttack)this).procCoefficient = 1f; ((Slash)this).OnEnter(); ((BaseState)this).StartAimMode(2f, false); base.durationBeforeInterruptable = 9f; Slash.comboFinisherDamageCoefficient = MainPlugin.crocoSecondaryDamage.Value; base.hasGrantedBuff = true; DamageTypeCombo genericSecondary = DamageTypeCombo.GenericSecondary; DamageAPI.AddModdedDamageType(ref genericSecondary, Prefabs.crocoSecondaryDamage); ((BasicMeleeAttack)this).overlapAttack.damageType = genericSecondary; ((BasicMeleeAttack)this).overlapAttack.procCoefficient = 1f; } public override void FixedUpdate() { //IL_0084: Unknown result type (might be due to invalid IL or missing references) ((BasicMeleeAttack)this).FixedUpdate(); if (!((BasicMeleeAttack)this).forceFire && ((EntityState)this).fixedAge >= ((BasicMeleeAttack)this).duration * 0.25f) { ((BasicMeleeAttack)this).forceFire = true; if (!Object.op_Implicit((Object)(object)effectInstance)) { effectInstance = Object.Instantiate(Prefabs.crocoSlash, ((BaseState)this).FindModelChild("Slash3")); effectInstance.transform.localScale = new Vector3(-2.5f, 2.5f, 2.5f); ScaleParticleSystemDuration component = effectInstance.GetComponent(); component.initialDuration = ((BasicMeleeAttack)this).duration - ((BasicMeleeAttack)this).duration * 0.25f; component.newDuration = ((BasicMeleeAttack)this).duration - ((BasicMeleeAttack)this).duration * 0.25f; } } } public override void AuthorityModifyOverlapAttack(OverlapAttack overlapAttack) { } public override void OnExit() { if (Object.op_Implicit((Object)(object)effectInstance)) { EntityState.Destroy((Object)(object)effectInstance); } ((Slash)this).OnExit(); } 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 CrocoSpecial : Leap { private HurtBox target; private Transform hitMuzzle; private int layer; private Vector3 hitPos; private Vector3 hitNormal; private bool hasFired; public override void OnEnter() { //IL_002f: Unknown result type (might be due to invalid IL or missing references) //IL_0039: Unknown result type (might be due to invalid IL or missing references) //IL_003e: Unknown result type (might be due to invalid IL or missing references) //IL_004a: Unknown result type (might be due to invalid IL or missing references) //IL_0050: Unknown result type (might be due to invalid IL or missing references) //IL_0055: Unknown result type (might be due to invalid IL or missing references) //IL_0058: 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) //IL_0067: Unknown result type (might be due to invalid IL or missing references) //IL_006c: Unknown result type (might be due to invalid IL or missing references) //IL_0089: Unknown result type (might be due to invalid IL or missing references) //IL_0093: Expected O, but got Unknown //IL_00a1: Unknown result type (might be due to invalid IL or missing references) //IL_00ab: Expected O, but got Unknown ((BaseLeap)this).fistEffectPrefab = Prefabs.Load("RoR2/Base/Croco/CrocoChainableFistEffect.prefab"); ((BaseLeap)this).blastEffectPrefab = Prefabs.Load("RoR2/Base/Croco/CrocoChainableLeapExplosion.prefab"); ((BaseLeap)this).OnEnter(); CharacterMotor characterMotor = ((EntityState)this).characterMotor; characterMotor.velocity *= 0.7f; CharacterMotor characterMotor2 = ((EntityState)this).characterMotor; Vector3 velocity = characterMotor2.velocity; Ray aimRay = ((BaseState)this).GetAimRay(); characterMotor2.velocity = velocity + ((Ray)(ref aimRay)).direction * 22f; if (((EntityState)this).isAuthority) { ((EntityState)this).characterMotor.onMovementHit += new MovementHitDelegate(CharacterMotor_onMovementHit); ((EntityState)this).characterMotor.onMovementHit -= new MovementHitDelegate(((BaseLeap)this).OnMovementHit); } layer = ((EntityState)this).gameObject.layer; } private void CharacterMotor_onMovementHit(ref MovementHitInfo movementHitInfo) { //IL_009d: Unknown result type (might be due to invalid IL or missing references) //IL_00a2: Unknown result type (might be due to invalid IL or missing references) //IL_00a9: Unknown result type (might be due to invalid IL or missing references) //IL_00ae: Unknown result type (might be due to invalid IL or missing references) //IL_00c5: 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_00d1: Unknown result type (might be due to invalid IL or missing references) //IL_00d6: Unknown result type (might be due to invalid IL or missing references) //IL_00dd: Unknown result type (might be due to invalid IL or missing references) //IL_00e2: Unknown result type (might be due to invalid IL or missing references) ((BaseLeap)this).DoImpactAuthority(); HurtBox val = null; CharacterBody component = ((Component)movementHitInfo.hitCollider).GetComponent(); if (Object.op_Implicit((Object)(object)((Component)movementHitInfo.hitCollider).GetComponent())) { component = ((Component)((Component)movementHitInfo.hitCollider).transform.root).GetComponent(); } if (Object.op_Implicit((Object)(object)component) && component.healthComponent.alive && Object.op_Implicit((Object)(object)component.mainHurtBox)) { val = component.mainHurtBox; } if (Object.op_Implicit((Object)(object)val) && val.healthComponent.alive) { target = component.mainHurtBox; hitPos = movementHitInfo.hitPoint; hitNormal = movementHitInfo.hitNormal; ((EntityState)this).outer.SetNextState((EntityState)(object)new CrocoSpecialLatch { targetReference = HurtBoxReference.FromHurtBox(target), hitPos = hitPos, hitNormal = hitNormal }); } } public override void Update() { ((BaseCharacterMain)this).Update(); } public override void FixedUpdate() { ((BaseLeap)this).FixedUpdate(); if (hasFired && !Object.op_Implicit((Object)(object)target)) { ((EntityState)this).outer.SetNextStateToMain(); } } public override void DoImpactAuthority() { //IL_001e: Unknown result type (might be due to invalid IL or missing references) //IL_0023: Unknown result type (might be due to invalid IL or missing references) //IL_002a: Unknown result type (might be due to invalid IL or missing references) //IL_002f: Unknown result type (might be due to invalid IL or missing references) //IL_0030: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Unknown result type (might be due to invalid IL or missing references) //IL_0048: Expected O, but got Unknown //IL_0049: Unknown result type (might be due to invalid IL or missing references) //IL_004e: Unknown result type (might be due to invalid IL or missing references) //IL_005a: 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_007d: 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) //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_0095: Unknown result type (might be due to invalid IL or missing references) //IL_0097: 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_00a1: Unknown result type (might be due to invalid IL or missing references) //IL_00a3: Unknown result type (might be due to invalid IL or missing references) //IL_00a8: Unknown result type (might be due to invalid IL or missing references) //IL_00b3: Unknown result type (might be due to invalid IL or missing references) //IL_00be: Unknown result type (might be due to invalid IL or missing references) //IL_00bf: Unknown result type (might be due to invalid IL or missing references) //IL_00c0: Unknown result type (might be due to invalid IL or missing references) //IL_00c5: Unknown result type (might be due to invalid IL or missing references) //IL_00c7: Unknown result type (might be due to invalid IL or missing references) //IL_00cc: Unknown result type (might be due to invalid IL or missing references) //IL_00d3: Unknown result type (might be due to invalid IL or missing references) //IL_00d8: Unknown result type (might be due to invalid IL or missing references) //IL_00dd: Unknown result type (might be due to invalid IL or missing references) //IL_00e4: Unknown result type (might be due to invalid IL or missing references) //IL_00e9: Unknown result type (might be due to invalid IL or missing references) //IL_00ef: Expected O, but got Unknown //IL_00f0: Unknown result type (might be due to invalid IL or missing references) //IL_00fc: Unknown result type (might be due to invalid IL or missing references) if (!hasFired) { hasFired = true; Vector3 footPosition = ((EntityState)this).characterBody.footPosition; EffectManager.SpawnEffect(((BaseLeap)this).blastEffectPrefab, new EffectData { origin = footPosition, scale = BaseLeap.blastRadius }, true); BlastAttack val = new BlastAttack { attacker = ((EntityState)this).gameObject, baseDamage = ((BaseState)this).damageStat * MainPlugin.crocoSpecialLatchDamage.Value, baseForce = ((BaseLeap)this).blastForce, bonusForce = ((BaseLeap)this).blastBonusForce, crit = ((BaseLeap)this).isCritAuthority, damageType = ((BaseLeap)this).GetBlastDamageType(), falloffModel = (FalloffModel)0, procCoefficient = BaseLeap.blastProcCoefficient, radius = BaseLeap.blastRadius, position = footPosition, attackerFiltering = (AttackerFiltering)2, impactEffect = EffectCatalog.FindEffectIndexFromPrefab(((BaseLeap)this).blastImpactEffectPrefab), teamIndex = ((EntityState)this).teamComponent.teamIndex }; DamageAPI.AddModdedDamageType(val, Prefabs.crocoSpecialDamage); val.Fire(); } } public override DamageTypeCombo GetBlastDamageType() { //IL_0001: Unknown result type (might be due to invalid IL or missing references) //IL_0006: Unknown result type (might be due to invalid IL or missing references) //IL_0009: Unknown result type (might be due to invalid IL or missing references) return DamageTypeCombo.GenericSpecial; } public override void OnExit() { //IL_0019: Unknown result type (might be due to invalid IL or missing references) //IL_0023: Expected O, but got Unknown if (((EntityState)this).isAuthority) { ((EntityState)this).characterMotor.onMovementHit -= new MovementHitDelegate(CharacterMotor_onMovementHit); } ((BaseLeap)this).OnExit(); } public override InterruptPriority GetMinimumInterruptPriority() { //IL_0003: Unknown result type (might be due to invalid IL or missing references) //IL_0006: Unknown result type (might be due to invalid IL or missing references) return (InterruptPriority)9; } } internal class CrocoSpecialLatch : BaseState { private float duration = 5f; private GameObject posMuzzle; public HurtBoxReference targetReference; public Vector3 hitPos; public Vector3 hitNormal; private Animator animator; private HurtBox target; private int layer; private bool input; private float stopwatch; private float tickInterval; private Transform muzzle; public override void OnSerialize(NetworkWriter writer) { //IL_000b: Unknown result type (might be due to invalid IL or missing references) //IL_0018: Unknown result type (might be due to invalid IL or missing references) //IL_0025: Unknown result type (might be due to invalid IL or missing references) ((EntityState)this).OnSerialize(writer); NetworkExtensions.Write(writer, targetReference); writer.Write(hitPos); writer.Write(hitNormal); } public override void OnDeserialize(NetworkReader reader) { //IL_000b: Unknown result type (might be due to invalid IL or missing references) //IL_0010: Unknown result type (might be due to invalid IL or missing references) //IL_0017: Unknown result type (might be due to invalid IL or missing references) //IL_001c: Unknown result type (might be due to invalid IL or missing references) //IL_0023: Unknown result type (might be due to invalid IL or missing references) //IL_0028: Unknown result type (might be due to invalid IL or missing references) ((EntityState)this).OnDeserialize(reader); targetReference = NetworkExtensions.ReadHurtBoxReference(reader); hitPos = reader.ReadVector3(); hitNormal = reader.ReadVector3(); } public override void OnEnter() { //IL_012b: Unknown result type (might be due to invalid IL or missing references) //IL_0131: Unknown result type (might be due to invalid IL or missing references) //IL_0136: Unknown result type (might be due to invalid IL or missing references) //IL_013b: Unknown result type (might be due to invalid IL or missing references) ((BaseState)this).OnEnter(); ((EntityState)this).PlayCrossfade("Gesture, AdditiveHigh", "Leap", 0.1f); ((EntityState)this).PlayCrossfade("Gesture, Override", "Leap", 0.1f); target = ((HurtBoxReference)(ref targetReference)).ResolveHurtBox(); if (!Object.op_Implicit((Object)(object)target) || (Object.op_Implicit((Object)(object)target) && !target.healthComponent.alive)) { target = null; if (((EntityState)this).isAuthority) { ((EntityState)this).outer.SetNextStateToMain(); } } animator = ((EntityState)this).GetModelAnimator(); animator.SetLayerWeight(animator.GetLayerIndex("Impact"), 2f); ((EntityState)this).PlayAnimation("Impact", BaseLeap.LightImpactStateHash); animator.speed = 0f; layer = ((EntityState)this).gameObject.layer; ((EntityState)this).gameObject.layer = LayerIndex.fakeActor.intVal; ((BaseCharacterController)((EntityState)this).characterMotor).Motor.RebuildCollidableLayers(); posMuzzle = Object.Instantiate(Prefabs.posMuzzle, hitPos, Quaternion.LookRotation(-hitNormal), ((Component)target).transform); ((EntityState)this).modelLocator.autoUpdateModelTransform = false; tickInterval = 1f / MainPlugin.crocoSpecialLatchTicks.Value; muzzle = ((BaseState)this).FindModelChild("MouthMuzzle"); if (NetworkServer.active) { ((EntityState)this).characterBody.AddBuff(Prefabs.latchBuff); } } public override void Update() { //IL_002e: Unknown result type (might be due to invalid IL or missing references) //IL_0050: Unknown result type (might be due to invalid IL or missing references) //IL_0060: Unknown result type (might be due to invalid IL or missing references) //IL_0065: Unknown result type (might be due to invalid IL or missing references) ((EntityState)this).Update(); if (Object.op_Implicit((Object)(object)posMuzzle)) { ((BaseCharacterController)((EntityState)this).characterMotor).Motor.SetPosition(posMuzzle.transform.position, true); ((EntityState)this).modelLocator.modelTransform.SetPositionAndRotation(((EntityState)this).modelLocator.modelParentTransform.position, Quaternion.LookRotation(posMuzzle.transform.forward)); } } public override void FixedUpdate() { //IL_00dd: Unknown result type (might be due to invalid IL or missing references) //IL_00e8: Unknown result type (might be due to invalid IL or missing references) //IL_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_014f: Unknown result type (might be due to invalid IL or missing references) //IL_0154: Unknown result type (might be due to invalid IL or missing references) //IL_0165: Unknown result type (might be due to invalid IL or missing references) //IL_016a: Unknown result type (might be due to invalid IL or missing references) //IL_016f: Unknown result type (might be due to invalid IL or missing references) //IL_017b: Unknown result type (might be due to invalid IL or missing references) //IL_0192: 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_01a0: Unknown result type (might be due to invalid IL or missing references) //IL_01a5: Unknown result type (might be due to invalid IL or missing references) //IL_01ac: Expected O, but got Unknown ((EntityState)this).FixedUpdate(); if (Object.op_Implicit((Object)(object)target)) { stopwatch += Time.fixedDeltaTime; if (stopwatch >= tickInterval) { stopwatch = 0f; float num = Bite.recoilAmplitude / 3f; ((BaseState)this).AddRecoil(0.9f * num, 1.1f * num, -0.1f * num, 0.1f * num); AkSoundEngine.PostEvent(Bite.biteSound, ((EntityState)this).gameObject); AkSoundEngine.PostEvent("Play_acrid_m2_bite_hit", ((Component)target.healthComponent).gameObject); ((EntityState)this).PlayCrossfade("Gesture, Additive", "Bite", "Bite.playbackRate", duration, 0.05f); GameObject val = Object.Instantiate(Prefabs.Load("RoR2/Base/Croco/CrocoBiteEffect.prefab"), muzzle.position, muzzle.rotation, muzzle); val.GetComponent().newDuration = 0.25f; val.AddComponent().duration = 0.25f; EffectManager.SimpleEffect(Prefabs.Load("RoR2/Base/Treebot/OmniImpactVFXSlashSyringe.prefab"), ((Component)target).transform.position, Quaternion.identity, false); if (NetworkServer.active) { DamageInfo val2 = new DamageInfo { position = target.healthComponent.body.corePosition, attacker = ((EntityState)this).gameObject, damage = base.damageStat * MainPlugin.crocoSpecialLatchTickDamage.Value, crit = ((BaseState)this).RollCrit(), damageType = DamageTypeCombo.op_Implicit((DamageType)0) }; target.healthComponent.TakeDamage(val2); DotController.InflictDot(((Component)target.healthComponent).gameObject, ((EntityState)this).gameObject, target, (DotIndex)5, 5f, 1f, (uint?)uint.MaxValue); } } } if (!input && ((ButtonState)(ref ((EntityState)this).inputBank.skill4)).justPressed) { input = true; ((EntityState)this).fixedAge = 4.75f; } if ((((EntityState)this).isAuthority && ((EntityState)this).fixedAge >= duration) || !Object.op_Implicit((Object)(object)target) || (Object.op_Implicit((Object)(object)target) && !target.healthComponent.alive)) { ((EntityState)this).outer.SetNextStateToMain(); } } public override void OnExit() { //IL_0070: Unknown result type (might be due to invalid IL or missing references) //IL_0075: Unknown result type (might be due to invalid IL or missing references) //IL_0079: Unknown result type (might be due to invalid IL or missing references) //IL_007e: Unknown result type (might be due to invalid IL or missing references) //IL_0083: 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_0085: Unknown result type (might be due to invalid IL or missing references) //IL_0097: Unknown result type (might be due to invalid IL or missing references) //IL_00ac: Unknown result type (might be due to invalid IL or missing references) //IL_00b6: Unknown result type (might be due to invalid IL or missing references) //IL_00bb: Unknown result type (might be due to invalid IL or missing references) //IL_00c7: Unknown result type (might be due to invalid IL or missing references) //IL_00cc: Unknown result type (might be due to invalid IL or missing references) //IL_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_00de: Unknown result type (might be due to invalid IL or missing references) //IL_00e3: Unknown result type (might be due to invalid IL or missing references) //IL_0163: Unknown result type (might be due to invalid IL or missing references) //IL_0168: Unknown result type (might be due to invalid IL or missing references) //IL_017b: Unknown result type (might be due to invalid IL or missing references) //IL_017d: 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_018f: Unknown result type (might be due to invalid IL or missing references) //IL_0191: Unknown result type (might be due to invalid IL or missing references) //IL_0196: 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_01b9: Unknown result type (might be due to invalid IL or missing references) //IL_01c1: 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_01cd: Unknown result type (might be due to invalid IL or missing references) //IL_01d2: Unknown result type (might be due to invalid IL or missing references) //IL_01d7: Unknown result type (might be due to invalid IL or missing references) //IL_01d8: 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) //IL_01e3: Unknown result type (might be due to invalid IL or missing references) //IL_01ea: Expected O, but got Unknown //IL_0207: Unknown result type (might be due to invalid IL or missing references) //IL_020c: Unknown result type (might be due to invalid IL or missing references) //IL_0211: Unknown result type (might be due to invalid IL or missing references) //IL_0213: Unknown result type (might be due to invalid IL or missing references) //IL_0218: Unknown result type (might be due to invalid IL or missing references) //IL_0219: Unknown result type (might be due to invalid IL or missing references) //IL_021b: Unknown result type (might be due to invalid IL or missing references) //IL_0220: Unknown result type (might be due to invalid IL or missing references) //IL_022b: Unknown result type (might be due to invalid IL or missing references) //IL_0231: Unknown result type (might be due to invalid IL or missing references) //IL_0236: Unknown result type (might be due to invalid IL or missing references) //IL_023d: Expected O, but got Unknown //IL_0247: Unknown result type (might be due to invalid IL or missing references) //IL_02aa: Unknown result type (might be due to invalid IL or missing references) //IL_02af: Unknown result type (might be due to invalid IL or missing references) //IL_02b6: Unknown result type (might be due to invalid IL or missing references) //IL_02b8: Unknown result type (might be due to invalid IL or missing references) //IL_02c4: Unknown result type (might be due to invalid IL or missing references) //IL_02c9: Unknown result type (might be due to invalid IL or missing references) //IL_02ca: Unknown result type (might be due to invalid IL or missing references) //IL_02cc: Unknown result type (might be due to invalid IL or missing references) //IL_02d1: Unknown result type (might be due to invalid IL or missing references) //IL_02dd: Unknown result type (might be due to invalid IL or missing references) //IL_02f4: Unknown result type (might be due to invalid IL or missing references) //IL_02fc: Unknown result type (might be due to invalid IL or missing references) //IL_0307: Unknown result type (might be due to invalid IL or missing references) //IL_0308: Unknown result type (might be due to invalid IL or missing references) //IL_030d: Unknown result type (might be due to invalid IL or missing references) //IL_0312: Unknown result type (might be due to invalid IL or missing references) //IL_031a: Unknown result type (might be due to invalid IL or missing references) //IL_031f: Unknown result type (might be due to invalid IL or missing references) //IL_0321: Unknown result type (might be due to invalid IL or missing references) //IL_0326: Unknown result type (might be due to invalid IL or missing references) //IL_032a: Unknown result type (might be due to invalid IL or missing references) //IL_0334: Unknown result type (might be due to invalid IL or missing references) //IL_0339: Unknown result type (might be due to invalid IL or missing references) //IL_0340: Expected O, but got Unknown //IL_038a: Unknown result type (might be due to invalid IL or missing references) ((EntityState)this).PlayAnimation("Gesture, Override", BaseLeap.BufferEmptyStateHash); ((EntityState)this).PlayAnimation("Gesture, AdditiveHigh", BaseLeap.BufferEmptyStateHash); animator.speed = 1f; ((EntityState)this).PlayAnimation("Body", "Jump"); if (NetworkServer.active) { ((EntityState)this).characterBody.RemoveBuff(Prefabs.latchBuff); } ((EntityState)this).modelLocator.autoUpdateModelTransform = true; Ray aimRay = ((BaseState)this).GetAimRay(); Vector3 forwardDirection = Utils.GetForwardDirection(((Ray)(ref aimRay)).direction); Vector3 forward = forwardDirection; GameObject val = Object.Instantiate(Prefabs.fwGuide); val.transform.forward = forward; Transform child = val.transform.GetChild(0); child.localRotation = Quaternion.Euler(Vector3.right * 45f); forward = child.forward; ((EntityState)this).characterMotor.velocity = -forward * 30f; EntityState.Destroy((Object)(object)val); ((EntityState)this).gameObject.layer = layer; ((BaseCharacterController)((EntityState)this).characterMotor).Motor.RebuildCollidableLayers(); if (Object.op_Implicit((Object)(object)target)) { AkSoundEngine.PostEvent("Play_acrid_m2_bite_hit", ((EntityState)this).gameObject); if (NetworkServer.active) { bool crit = ((BaseState)this).RollCrit(); CharacterBody body = target.healthComponent.body; Vector3 corePosition = body.corePosition; float value = MainPlugin.crocoSpecialDebuffDuration.Value; EffectManager.SimpleEffect(Prefabs.crocoExplosionEffect, corePosition, Quaternion.identity, true); DamageInfo val2 = new DamageInfo { position = corePosition, attacker = ((EntityState)this).gameObject, damage = base.damageStat * MainPlugin.crocoSpecialTargetDamage.Value, crit = crit, procCoefficient = 1f, damageType = DamageTypeCombo.GenericSpecial, force = forwardDirection * 1000f }; target.healthComponent.TakeDamage(val2); List> debufflist = Utils.GetDebufflist(body); TeamMask enemyTeams = TeamMask.GetEnemyTeams(((BaseState)this).GetTeam()); SphereSearch val3 = new SphereSearch { origin = corePosition, radius = 12f, mask = ((LayerIndex)(ref LayerIndex.entityPrecise)).mask }; val3.RefreshCandidates(); val3.FilterCandidatesByHurtBoxTeam(enemyTeams); val3.FilterCandidatesByDistinctHurtBoxEntities(); HurtBox[] hurtBoxes = val3.GetHurtBoxes(); HurtBox[] array = hurtBoxes; foreach (HurtBox val4 in array) { if (!((Object)(object)((Component)val4.healthComponent).gameObject != (Object)(object)((Component)body).gameObject) || !val4.healthComponent.alive) { continue; } corePosition = body.corePosition; EffectManager.SimpleEffect(Prefabs.crocoGasHitEffect, corePosition, Quaternion.identity, true); DamageInfo val5 = new DamageInfo { position = corePosition, attacker = ((EntityState)this).gameObject, damage = base.damageStat * MainPlugin.crocoSpecialExplosionDamage.Value, crit = crit, procCoefficient = 1f, damageType = DamageTypeCombo.GenericSpecial }; Vector3 val6 = ((Component)val4).transform.position - corePosition; val5.force = ((Vector3)(ref val6)).normalized * 500f; val2 = val5; val4.healthComponent.TakeDamage(val2); if (debufflist.Count <= 0) { continue; } foreach (KeyValuePair item in debufflist) { for (int j = 0; j < item.Value; j++) { val4.healthComponent.body.AddTimedBuff(item.Key, value); } } } } } if (Object.op_Implicit((Object)(object)posMuzzle)) { EntityState.Destroy((Object)(object)posMuzzle); } ((EntityState)this).OnExit(); } public override InterruptPriority GetMinimumInterruptPriority() { //IL_0003: Unknown result type (might be due to invalid IL or missing references) //IL_0006: Unknown result type (might be due to invalid IL or missing references) return (InterruptPriority)9; } } internal class EngiPrimaryCharge : ChargeGrenades { private float stopwatch; public override void FixedUpdate() { stopwatch += Time.fixedDeltaTime; if (((EntityState)this).isAuthority && (stopwatch >= base.totalDuration || !((EntityState)this).inputBank.skill1.down)) { EngiPrimaryFire engiPrimaryFire = new EngiPrimaryFire(); ((FireGrenades)engiPrimaryFire).grenadeCountMax = Mathf.FloorToInt(Mathf.Lerp((float)ChargeGrenades.minGrenadeCount, (float)ChargeGrenades.maxGrenadeCount, (float)base.charge / (float)ChargeGrenades.maxCharges)); ((EntityState)this).outer.SetNextState((EntityState)(object)engiPrimaryFire); } else { ((ChargeGrenades)this).FixedUpdate(); } } } internal class EngiPrimaryFire : FireGrenades { private float stopwatch = 1f; private GameObject ogPrefab; private float ogDamage; public override void OnEnter() { ((FireGrenades)this).OnEnter(); ogPrefab = FireGrenades.projectilePrefab; ogDamage = FireGrenades.damageCoefficient; } public override void FixedUpdate() { base.fireTimer = 1f; ((FireGrenades)this).FixedUpdate(); stopwatch += Time.fixedDeltaTime; if (stopwatch >= FireGrenades.fireDuration / ((BaseState)this).attackSpeedStat / (float)base.grenadeCountMax && base.grenadeCount < base.grenadeCountMax) { stopwatch = 0f; string text = ((base.grenadeCount % 2 == 0) ? "Left" : "Right"); ((EntityState)this).PlayCrossfade("Gesture " + text + " Cannon, Additive", "FireGrenade" + text, 0.1f); if (((EntityState)this).isAuthority) { FireGrenades.damageCoefficient = MainPlugin.missileDamageCoefficient.Value; FireGrenades.projectilePrefab = Prefabs.missileProjectile; } ((FireGrenades)this).FireGrenade("Muzzle" + text); if (((EntityState)this).isAuthority) { FireGrenades.projectilePrefab = ogPrefab; FireGrenades.damageCoefficient = ogDamage; } base.grenadeCount++; } } } internal class EngiSpecial : PlaceTurret { private CharacterMaster master; public override void OnEnter() { base.wristDisplayPrefab = Prefabs.Load("RoR2/Base/Engi/EngiTurretWristDisplay.prefab"); base.blueprintPrefab = Prefabs.turretBlueprint; ((PlaceTurret)this).OnEnter(); master = ((EntityState)this).characterBody.master; ((EntityState)this).outer.commonComponents.characterBody = null; } public override void OnExit() { ((EntityState)this).outer.commonComponents.characterBody = ((EntityState)this).GetComponent(); if (base.currentPlacementInfo.ok) { Summon(); } ((PlaceTurret)this).OnExit(); } private void Summon() { //IL_001c: 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) if (NetworkServer.active) { ((EntityState)this).GetComponent().CallCmdSpawn(base.currentPlacementInfo.position, base.currentPlacementInfo.rotation); } } } internal class EngiTurretPrimary : BaseSkillState { private float duration = 3f; private float damageCoefficient; private TurretChargeBehaviour chargeBehaviour; private bool hasFired; private BaseAI ai; public override void OnEnter() { ((BaseState)this).OnEnter(); ai = ((Component)((EntityState)this).characterBody.master).GetComponent(); damageCoefficient = MainPlugin.turretDamageCoefficient.Value * ((BaseState)this).attackSpeedStat; chargeBehaviour = ((EntityState)this).GetComponent(); } public override void FixedUpdate() { //IL_0076: Unknown result type (might be due to invalid IL or missing references) ((EntityState)this).FixedUpdate(); if (!hasFired && Object.op_Implicit((Object)(object)ai) && ai.hasAimConfirmation && ai.hasAimTarget && ai.currentEnemy != null && Object.op_Implicit((Object)(object)ai.currentEnemy.bestHurtBox) && ai.HasLOS(((Component)ai.currentEnemy.bestHurtBox).transform.position)) { hasFired = true; AkSoundEngine.PostEvent("Play_voidDevastator_death_vortex_explode", ((EntityState)this).gameObject); Fire(); } if ((((EntityState)this).isAuthority && ((EntityState)this).fixedAge >= duration) || hasFired) { ((EntityState)this).outer.SetNextStateToMain(); } } private void Fire() { //IL_0010: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0016: Unknown result type (might be due to invalid IL or missing references) //IL_001b: Unknown result type (might be due to invalid IL or missing references) //IL_0027: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0032: 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_0039: Unknown result type (might be due to invalid IL or missing references) //IL_003e: Unknown result type (might be due to invalid IL or missing references) //IL_0049: Unknown result type (might be due to invalid IL or missing references) //IL_0055: Unknown result type (might be due to invalid IL or missing references) //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_0064: Unknown result type (might be due to invalid IL or missing references) //IL_0069: Unknown result type (might be due to invalid IL or missing references) //IL_006e: Unknown result type (might be due to invalid IL or missing references) //IL_0071: Unknown result type (might be due to invalid IL or missing references) //IL_007c: Unknown result type (might be due to invalid IL or missing references) //IL_0087: Unknown result type (might be due to invalid IL or missing references) //IL_0092: Unknown result type (might be due to invalid IL or missing references) //IL_0099: Unknown result type (might be due to invalid IL or missing references) //IL_00ac: Unknown result type (might be due to invalid IL or missing references) //IL_00be: Unknown result type (might be due to invalid IL or missing references) //IL_00c9: Unknown result type (might be due to invalid IL or missing references) //IL_00d4: Unknown result type (might be due to invalid IL or missing references) //IL_00df: Unknown result type (might be due to invalid IL or missing references) //IL_00eb: Unknown result type (might be due to invalid IL or missing references) //IL_00f6: Unknown result type (might be due to invalid IL or missing references) //IL_00fd: Unknown result type (might be due to invalid IL or missing references) //IL_00fe: Unknown result type (might be due to invalid IL or missing references) //IL_0103: Unknown result type (might be due to invalid IL or missing references) if (((EntityState)this).isAuthority) { Ray aimRay = ((BaseState)this).GetAimRay(); new BulletAttack { maxDistance = 250f, stopperMask = ((LayerIndex)(ref LayerIndex.world)).mask, falloffModel = (FalloffModel)0, radius = 2f, owner = ((EntityState)this).gameObject, weapon = ((EntityState)this).gameObject, origin = ((Ray)(ref aimRay)).origin, aimVector = ((Ray)(ref aimRay)).direction, minSpread = 0f, maxSpread = 0f, bulletCount = 1u, damage = ((BaseState)this).damageStat * damageCoefficient, force = damageCoefficient * 100f, tracerEffectPrefab = Prefabs.turretBigTracer, muzzleName = "Muzzle", hitEffectPrefab = Prefabs.turretMuzzleFlash, isCrit = ((BaseState)this).RollCrit(), procCoefficient = 1f, smartCollision = true, damageType = DamageTypeCombo.GenericPrimary }.Fire(); } } public override void OnExit() { ((EntityState)this).OnExit(); } public override InterruptPriority GetMinimumInterruptPriority() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (InterruptPriority)1; } } internal class EngiTurretPrimaryOld : BaseSkillState { private float duration = 3f; private float fireFrequency = 0.2f; private float damageCoefficient; private float stopwatch; private GameObject tracer; private TurretChargeBehaviour chargeBehaviour; private uint ID; private MeshRenderer tracerMesh; public override void OnEnter() { //IL_004a: Unknown result type (might be due to invalid IL or missing references) //IL_0050: Unknown result type (might be due to invalid IL or missing references) ((BaseState)this).OnEnter(); damageCoefficient = MainPlugin.turretDamageCoefficient.Value * fireFrequency; chargeBehaviour = ((EntityState)this).GetComponent(); chargeBehaviour.firing = true; Transform val = ((BaseState)this).FindModelChild("Muzzle"); tracer = Object.Instantiate(Prefabs.turretTracer, val.position, val.rotation, val); tracerMesh = tracer.GetComponentInChildren(); ID = AkSoundEngine.PostEvent("Play_voidman_m1_corrupted_start", ((EntityState)this).gameObject); } public override void Update() { //IL_001c: 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_0028: 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_0044: Unknown result type (might be due to invalid IL or missing references) //IL_00f2: Unknown result type (might be due to invalid IL or missing references) //IL_00f7: Unknown result type (might be due to invalid IL or missing references) //IL_00fb: Unknown result type (might be due to invalid IL or missing references) //IL_007b: Unknown result type (might be due to invalid IL or missing references) //IL_0081: Unknown result type (might be due to invalid IL or missing references) //IL_008b: Unknown result type (might be due to invalid IL or missing references) //IL_00a1: Unknown result type (might be due to invalid IL or missing references) //IL_00a6: Unknown result type (might be due to invalid IL or missing references) //IL_00b3: Unknown result type (might be due to invalid IL or missing references) //IL_00ba: Unknown result type (might be due to invalid IL or missing references) //IL_00c8: 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_0064: Unknown result type (might be due to invalid IL or missing references) ((EntityState)this).Update(); if (Object.op_Implicit((Object)(object)tracerMesh)) { Ray aimRay = ((BaseState)this).GetAimRay(); float num = 250f; RaycastHit val = default(RaycastHit); if (Physics.Raycast(aimRay, ref val, 250f, LayerMask.op_Implicit(((LayerIndex)(ref LayerIndex.entityPrecise)).mask) | LayerMask.op_Implicit(((LayerIndex)(ref LayerIndex.world)).mask))) { num = Vector3.Distance(((RaycastHit)(ref val)).point, ((Ray)(ref aimRay)).origin); } ((Component)tracerMesh).transform.localPosition = Vector3.forward * num * 0.488f; Vector3 localScale = ((Component)tracerMesh).transform.localScale; ((Component)tracerMesh).transform.localScale = new Vector3(localScale.x, localScale.y, num * 0.0288f); } if (Object.op_Implicit((Object)(object)tracer)) { Transform transform = tracer.transform; Ray aimRay2 = ((BaseState)this).GetAimRay(); transform.forward = ((Ray)(ref aimRay2)).direction; } } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); stopwatch += Time.fixedDeltaTime; if (stopwatch >= fireFrequency / ((BaseState)this).attackSpeedStat) { stopwatch = 0f; Fire(); } if (((EntityState)this).isAuthority && ((EntityState)this).fixedAge >= duration) { ((EntityState)this).outer.SetNextStateToMain(); } } private void Fire() { //IL_0010: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0016: Unknown result type (might be due to invalid IL or missing references) //IL_001b: Unknown result type (might be due to invalid IL or missing references) //IL_0027: Unknown result type (might be due to invalid IL or missing references) //IL_0028: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0034: Unknown result type (might be due to invalid IL or missing references) //IL_0039: Unknown result type (might be due to invalid IL or missing references) //IL_0044: Unknown result type (might be due to invalid IL or missing references) //IL_0050: 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) //IL_005f: Unknown result type (might be due to invalid IL or missing references) //IL_0064: Unknown result type (might be due to invalid IL or missing references) //IL_0069: Unknown result type (might be due to invalid IL or missing references) //IL_006c: Unknown result type (might be due to invalid IL or missing references) //IL_0077: Unknown result type (might be due to invalid IL or missing references) //IL_0082: Unknown result type (might be due to invalid IL or missing references) //IL_008d: 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_00a7: Unknown result type (might be due to invalid IL or missing references) //IL_00b9: Unknown result type (might be due to invalid IL or missing references) //IL_00c0: 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_00d6: Unknown result type (might be due to invalid IL or missing references) //IL_00e2: Unknown result type (might be due to invalid IL or missing references) //IL_00ed: Unknown result type (might be due to invalid IL or missing references) //IL_00f4: Unknown result type (might be due to invalid IL or missing references) //IL_00f6: Unknown result type (might be due to invalid IL or missing references) //IL_00fb: Unknown result type (might be due to invalid IL or missing references) if (((EntityState)this).isAuthority) { Ray aimRay = ((BaseState)this).GetAimRay(); new BulletAttack { maxDistance = 250f, stopperMask = BulletAttack.defaultStopperMask, falloffModel = (FalloffModel)0, radius = 0.25f, owner = ((EntityState)this).gameObject, weapon = ((EntityState)this).gameObject, origin = ((Ray)(ref aimRay)).origin, aimVector = ((Ray)(ref aimRay)).direction, minSpread = 0f, maxSpread = 0f, bulletCount = 1u, damage = ((BaseState)this).damageStat * damageCoefficient, force = damageCoefficient * 100f, tracerEffectPrefab = null, muzzleName = "Muzzle", hitEffectPrefab = Prefabs.turretMuzzleFlash, isCrit = ((BaseState)this).RollCrit(), procCoefficient = 1f, smartCollision = true, damageType = DamageTypeCombo.op_Implicit((DamageType)0) }.Fire(); } } public override void OnExit() { AkSoundEngine.StopPlayingID(ID); AkSoundEngine.PostEvent("Play_voidman_m1_corrupted_end", ((EntityState)this).gameObject); chargeBehaviour.firing = false; if (Object.op_Implicit((Object)(object)tracer)) { EntityState.Destroy((Object)(object)tracer); } ((EntityState)this).OnExit(); } public override InterruptPriority GetMinimumInterruptPriority() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (InterruptPriority)1; } } internal class TurretSpawn : BaseState { public override void OnEnter() { ((BaseState)this).OnEnter(); if (((EntityState)this).isAuthority) { ((EntityState)this).outer.SetNextStateToMain(); } } } internal class FalseSonSpecial : LaserFather { public override EntityState GetNextStateAuthority() { return (EntityState)(object)new FalseSonSpecialFire(); } public override bool ShouldKeepChargingAuthority() { return ((LaserFather)this).charge < 1f; } public override void ModifyNextState(EntityState nextState) { } } internal class FalseSonSpecialFire : BaseSkillState { private struct laser { public Transform origin; public Transform endTransform; public BulletAttack bulletAttack; } private struct laserDirection { public int currentDirection; public Vector3[] directions; public Vector3 direction => directions[currentDirection]; public static implicit operator laserDirection(Transform origin) { //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_002a: 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_004c: Unknown result type (might be due to invalid IL or missing references) //IL_005b: Unknown result type (might be due to invalid IL or missing references) //IL_0060: Unknown result type (might be due to invalid IL or missing references) Vector3[] array = (Vector3[])(object)new Vector3[10]; Xoroshiro128Plus rng = RoR2Application.rng; for (int i = 0; i < 10; i++) { origin.Rotate(Vector3.up * rng.RangeFloat(0f, 360f), (Space)1); origin.Rotate(Vector3.right * rng.RangeFloat(-25f, 26f), (Space)1); array[i] = origin.forward; } laserDirection result = default(laserDirection); result.directions = array; return result; } } private float duration; private float baseDuration = MainPlugin.falseSonSpecialDuration.Value; private float damageCoefficient = MainPlugin.falseSonSpecialDamage.Value; private float fireRate = MainPlugin.falseSonSpecialFireRate.Value; private float maxDistance = MainPlugin.falseSonSpecialMaxDistance.Value; private GameObject muzzles; private laser[] lasers = new laser[10]; private laserDirection[] laserDirections = new laserDirection[10]; private float stopwatch = 1f; private Transform muzzleTransform; private RotateAroundAxis rot; public override void OnEnter() { //IL_0076: Unknown result type (might be due to invalid IL or missing references) //IL_007b: Unknown result type (might be due to invalid IL or missing references) //IL_00d5: Unknown result type (might be due to invalid IL or missing references) //IL_0114: Unknown result type (might be due to invalid IL or missing references) //IL_0119: Unknown result type (might be due to invalid IL or missing references) //IL_0120: Unknown result type (might be due to invalid IL or missing references) //IL_012c: Unknown result type (might be due to invalid IL or missing references) //IL_0146: Unknown result type (might be due to invalid IL or missing references) //IL_0148: Unknown result type (might be due to invalid IL or missing references) //IL_014d: Unknown result type (might be due to invalid IL or missing references) //IL_014e: Unknown result type (might be due to invalid IL or missing references) //IL_0153: 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_015a: 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_016c: 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_0183: Unknown result type (might be due to invalid IL or missing references) //IL_018f: Unknown result type (might be due to invalid IL or missing references) //IL_019a: Unknown result type (might be due to invalid IL or missing references) //IL_01a1: 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_01ad: Unknown result type (might be due to invalid IL or missing references) //IL_01b8: Unknown result type (might be due to invalid IL or missing references) //IL_01c3: Unknown result type (might be due to invalid IL or missing references) //IL_01c9: Unknown result type (might be due to invalid IL or missing references) //IL_01ce: Unknown result type (might be due to invalid IL or missing references) //IL_01d3: Unknown result type (might be due to invalid IL or missing references) //IL_01d4: Unknown result type (might be due to invalid IL or missing references) //IL_01d9: Unknown result type (might be due to invalid IL or missing references) //IL_01e3: Expected O, but got Unknown ((EntityState)this).inputBank.skill1.down = false; ((BaseState)this).OnEnter(); duration = baseDuration + MainPlugin.falseSonSpecialFinalDuration.Value; ((BaseState)this).StartAimMode(2f, false); muzzleTransform = ((BaseState)this).FindModelChild("LaserOriginStanding"); Transform val = (Object.op_Implicit((Object)(object)muzzleTransform) ? muzzleTransform : ((EntityState)this).characterBody.coreTransform); muzzles = Object.Instantiate(Prefabs.falseSonLaserMuzzles, val.position, Quaternion.identity); ChildLocator component = muzzles.GetComponent(); for (int i = 0; i < component.transformPairs.Length; i++) { Transform transform = component.transformPairs[i].transform; laserDirections[i] = transform; transform.forward = laserDirections[i].directions[0]; Transform endTransform = ((Component)transform).GetComponentInChildren().FindChild("LaserEnd"); lasers[i] = new laser { origin = transform, endTransform = endTransform, bulletAttack = new BulletAttack { bulletCount = 1u, weapon = ((EntityState)this).gameObject, damage = ((BaseState)this).damageStat * damageCoefficient * fireRate, damageColorIndex = (DamageColorIndex)0, damageType = DamageTypeCombo.GenericSpecial, falloffModel = (FalloffModel)1, maxDistance = maxDistance, force = 20f, isCrit = ((BaseState)this).RollCrit(), owner = ((EntityState)this).gameObject, muzzleName = "LaserOriginStanding", smartCollision = true, procChainMask = default(ProcChainMask), procCoefficient = 0.5f, radius = 1f, stopperMask = ((LayerIndex)(ref LayerIndex.world)).mask, hitMask = CommonMasks.bullet } }; } Util.PlaySound("Play_falseson_skill4_laser_start", ((EntityState)this).gameObject); ((EntityState)this).PlayCrossfade("Gesture, Head, Override", "FireLaserLoop", 0.25f); ((EntityState)this).PlayCrossfade("Gesture, Head, Additive", "FireLaserLoop", 0.25f); } public override void Update() { //IL_003e: Unknown result type (might be due to invalid IL or missing references) ((EntityState)this).Update(); if (Object.op_Implicit((Object)(object)muzzles) && Object.op_Implicit((Object)(object)muzzleTransform)) { muzzles.transform.position = muzzleTransform.position; } } public override void FixedUpdate() { //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_00a5: Unknown result type (might be due to invalid IL or missing references) //IL_00aa: Unknown result type (might be due to invalid IL or missing references) //IL_00be: Unknown result type (might be due to invalid IL or missing references) //IL_00c3: Unknown result type (might be due to invalid IL or missing references) //IL_00e9: Unknown result type (might be due to invalid IL or missing references) //IL_00ee: Unknown result type (might be due to invalid IL or missing references) //IL_00fb: 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_0108: Unknown result type (might be due to invalid IL or missing references) //IL_0056: Unknown result type (might be due to invalid IL or missing references) //IL_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) //IL_0072: Unknown result type (might be due to invalid IL or missing references) //IL_01c2: Unknown result type (might be due to invalid IL or missing references) //IL_01c7: Unknown result type (might be due to invalid IL or missing references) //IL_01da: Unknown result type (might be due to invalid IL or missing references) ((EntityState)this).FixedUpdate(); ((BaseState)this).StartAimMode(2f, false); if (((EntityState)this).fixedAge >= baseDuration) { Ray aimRay = ((BaseState)this).GetAimRay(); laser[] array = lasers; for (int i = 0; i < array.Length; i++) { laser laser = array[i]; laser.origin.rotation = Quaternion.Lerp(laser.origin.rotation, Quaternion.LookRotation(((Ray)(ref aimRay)).direction), Time.fixedDeltaTime * 5f); } } else { for (int j = 0; j < lasers.Length; j++) { Vector3 direction = laserDirections[j].direction; Vector3 forward = lasers[j].origin.forward; lasers[j].origin.forward = Vector3.Lerp(lasers[j].origin.forward, direction, Time.fixedDeltaTime * 1f); if (Vector3.Angle(forward, direction) <= 2f) { laserDirections[j].currentDirection++; } } } if (((EntityState)this).isAuthority) { stopwatch += Time.fixedDeltaTime; if (stopwatch >= fireRate) { stopwatch = 0f; laser[] array2 = lasers; for (int k = 0; k < array2.Length; k++) { laser laser2 = array2[k]; laser2.bulletAttack.origin = laser2.origin.position; laser2.bulletAttack.aimVector = laser2.origin.forward; laser2.bulletAttack.Fire(); } } } if (((ButtonState)(ref ((EntityState)this).inputBank.skill4)).justPressed) { ((EntityState)this).outer.SetNextState((EntityState)(object)new FalseSonSpecialEnd()); } if (((EntityState)this).isAuthority && ((EntityState)this).fixedAge >= duration) { ((EntityState)this).outer.SetNextStateToMain(); } } public override void OnExit() { Util.PlaySound("Stop_falseson_skill4_laser_loop", ((EntityState)this).gameObject); Util.PlaySound("Stop_falseson_skill4_laser_charge_loop", ((EntityState)this).gameObject); Util.PlaySound("Play_falseson_skill4_laser_end", ((EntityState)this).gameObject); ((EntityState)this).PlayAnimation("Gesture, Head, Override", "FireLaserLoopEnd"); ((EntityState)this).PlayAnimation("Gesture, Head, Additive", "FireLaserLoopEnd"); if (Object.op_Implicit((Object)(object)muzzles)) { EntityState.Destroy((Object)(object)muzzles); } ((EntityState)this).OnExit(); } 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)5; } } internal class FalseSonSpecialEnd : BaseSkillState { private float duration = 0.25f; public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); if (((EntityState)this).isAuthority && ((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)5; } } internal class FalseSonUtility : BaseSkillState { private float duration = MainPlugin.falseSonUtilityDuration.Value; private float stopwatch = 1f; private Vector3 pos; private GameObject effect; private float radius = MainPlugin.falseSonUtilityRadius.Value; private uint ID; public override void OnEnter() { //IL_002f: Unknown result type (might be due to invalid IL or missing references) //IL_0034: Unknown result type (might be due to invalid IL or missing references) //IL_0072: Unknown result type (might be due to invalid IL or missing references) //IL_0077: Unknown result type (might be due to invalid IL or missing references) //IL_00aa: Unknown result type (might be due to invalid IL or missing references) //IL_00af: Unknown result type (might be due to invalid IL or missing references) ((BaseState)this).OnEnter(); ((EntityState)this).PlayAnimation("Gesture, Override", "HoldGauntletsUp", "LunarSpike.playbackRate", 0.35f, 0f); pos = ((EntityState)this).transform.position; if (!((BaseState)this).isGrounded) { ((EntityState)this).characterMotor.velocity = new Vector3(((EntityState)this).characterMotor.velocity.x, StealthMode.shortHopVelocity, ((EntityState)this).characterMotor.velocity.z); } if (NetworkServer.active) { ((EntityState)this).characterBody.AddTimedBuff(Buffs.EnergizedCore, 4f); } effect = Object.Instantiate(Prefabs.falseSonBuffWardEffect, ((EntityState)this).transform.position, Quaternion.identity); effect.transform.parent = ((EntityState)this).transform; AkSoundEngine.PostEvent("Play_falseson_skill3_dash", ((EntityState)this).gameObject); ID = AkSoundEngine.PostEvent("Play_healing_drone_heal_loop", ((EntityState)this).gameObject); } public override void FixedUpdate() { //IL_0050: Unknown result type (might be due to invalid IL or missing references) //IL_0078: Unknown result type (might be due to invalid IL or missing references) //IL_0083: Unknown result type (might be due to invalid IL or missing references) ((EntityState)this).FixedUpdate(); if (NetworkServer.active) { stopwatch += Time.fixedDeltaTime; if (stopwatch >= 0.1f) { stopwatch = 0f; ReadOnlyCollection teamMembers = TeamComponent.GetTeamMembers(((EntityState)this).teamComponent.teamIndex); foreach (TeamComponent item in teamMembers) { if (Vector3.Distance(((Component)item).transform.position, ((EntityState)this).transform.position) <= radius) { HealthComponent healthComponent = item.body.healthComponent; healthComponent.AddBarrier(healthComponent.fullHealth * MainPlugin.falseSonUtilityBarrier.Value * 0.1f); CleanseSystem.CleanseBodyServer(item.body, true, false, false, true, true, false); item.body.AddTimedBuff(Prefabs.debuffImmune, 3f); item.body.AddTimedBuff(Prefabs.falseSonAuraBuff, 8f); } } } } if (((EntityState)this).fixedAge >= duration && ((EntityState)this).isAuthority) { ((EntityState)this).outer.SetNextStateToMain(); } } public override void OnExit() { AkSoundEngine.StopPlayingID(ID); if (Object.op_Implicit((Object)(object)effect)) { EntityState.Destroy((Object)(object)effect); } ((EntityState)this).OnExit(); } public override InterruptPriority GetMinimumInterruptPriority() { //IL_0003: Unknown result type (might be due to invalid IL or missing references) //IL_0006: Unknown result type (might be due to invalid IL or missing references) return (InterruptPriority)9; } } internal class HuntressSecondary : BaseSkillState { private float duration; private float baseDuration = 1.1f; private float damageCoefficient = MainPlugin.huntressSecondaryDamage.Value; private GameObject chargeEffect; private bool hasFired; private Animator animator; public override void OnEnter() { //IL_00a8: Unknown result type (might be due to invalid IL or missing references) //IL_00ae: Unknown result type (might be due to invalid IL or missing references) ((BaseState)this).OnEnter(); duration = baseDuration / ((BaseState)this).attackSpeedStat; ((BaseState)this).StartAimMode(2f, false); Util.PlayAttackSpeedSound("Play_huntress_m2_throw", ((EntityState)this).gameObject, ((BaseState)this).attackSpeedStat); if (Object.op_Implicit((Object)(object)((EntityState)this).characterMotor) && ThrowGlaive.smallHopStrength != 0f) { ((EntityState)this).characterMotor.velocity.y = ThrowGlaive.smallHopStrength; } ((EntityState)this).PlayAnimation("FullBody, Override", ThrowGlaive.ThrowGlaiveStateHash, ThrowGlaive.ThrowGlaiveParamHash, duration); Transform val = ((BaseState)this).FindModelChild("HandR"); chargeEffect = Object.Instantiate(ThrowGlaive.chargePrefab, val.position, val.rotation, val); animator = ((EntityState)this).GetModelAnimator(); } public override void FixedUpdate() { //IL_0079: Unknown result type (might be due to invalid IL or missing references) //IL_007e: Unknown result type (might be due to invalid IL or missing references) //IL_008c: Unknown result type (might be due to invalid IL or missing references) //IL_0093: Unknown result type (might be due to invalid IL or missing references) //IL_0098: Unknown result type (might be due to invalid IL or missing references) //IL_00c2: Unknown result type (might be due to invalid IL or missing references) ((EntityState)this).FixedUpdate(); if (!hasFired && animator.GetFloat("ThrowGlaive.fire") > 0f) { hasFired = true; if (Object.op_Implicit((Object)(object)chargeEffect)) { EntityState.Destroy((Object)(object)chargeEffect); } EffectManager.SimpleMuzzleFlash(ThrowGlaive.muzzleFlashPrefab, ((EntityState)this).gameObject, "HandR", false); if (((EntityState)this).isAuthority) { Ray aimRay = ((BaseState)this).GetAimRay(); ProjectileManager.instance.FireProjectile(Prefabs.huntressGravityProjectile, ((Ray)(ref aimRay)).origin, Quaternion.LookRotation(((Ray)(ref aimRay)).direction), ((EntityState)this).gameObject, ((BaseState)this).damageStat * damageCoefficient, 0f, ((BaseState)this).RollCrit(), (DamageColorIndex)0, (GameObject)null, -1f, (DamageTypeCombo?)DamageTypeCombo.GenericSecondary); } } CharacterMotor characterMotor = ((EntityState)this).characterMotor; characterMotor.velocity.y = characterMotor.velocity.y + ThrowGlaive.antigravityStrength * ((EntityState)this).GetDeltaTime() * (1f - ((EntityState)this).fixedAge / duration); if (((EntityState)this).isAuthority && ((EntityState)this).fixedAge >= duration) { ((EntityState)this).outer.SetNextStateToMain(); } } public override void OnExit() { if (Object.op_Implicit((Object)(object)chargeEffect)) { EntityState.Destroy((Object)(object)chargeEffect); } ((EntityState)this).OnExit(); } 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 HuntressSpecial : BeginArrowSnipe { public override void OnEnter() { //IL_0032: 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) ((BaseBeginArrowBarrage)this).basePrepDuration = 0.25f; ((BaseBeginArrowBarrage)this).blinkDuration = 0.3f; ((BaseBeginArrowBarrage)this).jumpCoefficient = 3f; ((BaseBeginArrowBarrage)this).blinkVector = new Vector3(0f, 0.6f, -0.6f); ((BaseBeginArrowBarrage)this).OnEnter(); } public override EntityState InstantiateNextState() { return (EntityState)(object)new HuntressSpecialAim(); } } internal class HuntressSpecialAim : AimArrowSnipe { private float radius = MainPlugin.huntressSecondaryRadius.Value; private GameObject areaEffect; public override void OnEnter() { //IL_0064: Unknown result type (might be due to invalid IL or missing references) //IL_006f: Unknown result type (might be due to invalid IL or missing references) ((BaseArrowBarrage)this).maxDuration = 4f; ((BaseArrowBarrage)this).beginLoopSoundString = "Play_huntress_R_snipe_readyBow"; ((AimArrowSnipe)this).OnEnter(); base.primarySkillSlot.UnsetSkillOverride((object)this, AimArrowSnipe.primarySkillDef, (SkillOverridePriority)4); base.primarySkillSlot.SetSkillOverride((object)((EntityState)this).gameObject, MainPlugin.huntressPrimaryOverride, (SkillOverridePriority)4); areaEffect = Object.Instantiate(ArrowRain.areaIndicatorPrefab); areaEffect.transform.localScale = Vector3.one * radius; UpdateAreaPosition(); } private void UpdateAreaPosition() { //IL_0017: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_005b: Unknown result type (might be due to invalid IL or missing references) if (Object.op_Implicit((Object)(object)areaEffect)) { RaycastHit val = default(RaycastHit); if (Physics.Raycast(((BaseState)this).GetAimRay(), ref val, MainPlugin.huntressSpecialRange.Value, LayerMask.op_Implicit(((LayerIndex)(ref LayerIndex.world)).mask))) { areaEffect.SetActive(true); areaEffect.transform.position = ((RaycastHit)(ref val)).point; } else { areaEffect.SetActive(false); } } } public override void Update() { ((EntityState)this).Update(); UpdateAreaPosition(); } public override void OnExit() { if (Object.op_Implicit((Object)(object)areaEffect)) { EntityState.Destroy((Object)(object)areaEffect); } ((AimArrowSnipe)this).OnExit(); } } internal class HuntressSpecialFire : BaseSkillState { private float duration = 0.35f; private float damageCoefficient = MainPlugin.huntressSpecialDamage.Value; private Vector3 hitPos; private bool effectSpawned; private GameObject effectPrefab = Prefabs.Load("RoR2/Base/Huntress/HuntressBlinkEffect.prefab"); private CharacterModel characterModel; private float radius = MainPlugin.huntressSecondaryRadius.Value; public override void OnEnter() { //IL_006a: Unknown result type (might be due to invalid IL or missing references) //IL_006f: Unknown result type (might be due to invalid IL or missing references) //IL_0077: Unknown result type (might be due to invalid IL or missing references) //IL_007c: Unknown result type (might be due to invalid IL or missing references) //IL_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_00b6: Unknown result type (might be due to invalid IL or missing references) //IL_00bd: Unknown result type (might be due to invalid IL or missing references) //IL_00c0: Unknown result type (might be due to invalid IL or missing references) //IL_00c5: Unknown result type (might be due to invalid IL or missing references) //IL_00cb: Expected O, but got Unknown //IL_00f5: Unknown result type (might be due to invalid IL or missing references) //IL_0107: 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_009b: Unknown result type (might be due to invalid IL or missing references) //IL_0120: 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) ((BaseState)this).OnEnter(); ((EntityState)this).characterBody.SetSpreadBloom(0.2f, false); ((BaseState)this).AddRecoil(-0.6f * FireArrowSnipe.recoilAmplitude, -0.8f * FireArrowSnipe.recoilAmplitude, -0.1f * FireArrowSnipe.recoilAmplitude, 0.1f * FireArrowSnipe.recoilAmplitude); ((EntityState)this).PlayAnimation("Body", FireArrowSnipe.FireArrowSnipeStateHash, FireArrowSnipe.FireArrowSnipeParamHash, duration); Ray aimRay = ((BaseState)this).GetAimRay(); Vector3 point = ((Ray)(ref aimRay)).GetPoint(999f); if (NetworkServer.active) { ((EntityState)this).healthComponent.TakeDamageForce(((Ray)(ref aimRay)).direction * -400f, true, false); } ChildLocator modelChildLocator = ((EntityState)this).GetModelChildLocator(); EffectData val = new EffectData { origin = point, start = ((Ray)(ref aimRay)).origin }; val.SetChildLocatorTransformReference(((Component)modelChildLocator).gameObject, modelChildLocator.FindChildIndex("Muzzle")); EffectManager.SpawnEffect(Prefabs.Load("RoR2/Base/Huntress/TracerHuntressSnipe.prefab"), val, true); RaycastHit val2 = default(RaycastHit); if (Physics.Raycast(aimRay, ref val2, MainPlugin.huntressSpecialRange.Value, LayerMask.op_Implicit(((LayerIndex)(ref LayerIndex.world)).mask))) { hitPos = ((RaycastHit)(ref val2)).point; } AkSoundEngine.PostEvent("Play_huntress_R_snipe_shoot", ((EntityState)this).gameObject); characterModel = ((Component)((EntityState)this).GetModelTransform()).GetComponent(); TemporaryOverlayInstance val3 = TemporaryOverlayManager.AddOverlay(((Component)characterModel).gameObject); val3.duration = 0.2f; val3.animateShaderAlpha = true; val3.alphaCurve = AnimationCurve.EaseInOut(0f, 1f, 1f, 0f); val3.destroyComponentOnEnd = true; val3.originalMaterial = Prefabs.Load("RoR2/Base/Huntress/matHuntressFlashBright.mat"); val3.AddToCharacterModel(characterModel); } public override void FixedUpdate() { //IL_003b: Unknown result type (might be due to invalid IL or missing references) //IL_0040: Unknown result type (might be due to invalid IL or missing references) ((EntityState)this).FixedUpdate(); if (!effectSpawned && ((EntityState)this).fixedAge >= 0.2f) { effectSpawned = true; EffectManager.SimpleEffect(effectPrefab, ((EntityState)this).characterBody.corePosition, Quaternion.identity, false); AkSoundEngine.PostEvent("Play_huntress_shift_start", ((EntityState)this).gameObject); } if (((EntityState)this).isAuthority && ((EntityState)this).fixedAge >= duration) { ((EntityState)this).outer.SetNextStateToMain(); } } public override void OnExit() { //IL_0068: Unknown result type (might be due to invalid IL or missing references) //IL_006d: Unknown result type (might be due to invalid IL or missing references) //IL_014a: Unknown result type (might be due to invalid IL or missing references) //IL_014f: Unknown result type (might be due to invalid IL or missing references) //IL_015b: Unknown result type (might be due to invalid IL or missing references) //IL_0160: Unknown result type (might be due to invalid IL or missing references) //IL_0162: Unknown result type (might be due to invalid IL or missing references) //IL_016d: Unknown result type (might be due to invalid IL or missing references) //IL_017a: Expected O, but got Unknown //IL_0094: Unknown result type (might be due to invalid IL or missing references) //IL_0099: Unknown result type (might be due to invalid IL or missing references) //IL_00a3: Unknown result type (might be due to invalid IL or missing references) //IL_00a8: Unknown result type (might be due to invalid IL or missing references) //IL_00b4: Unknown result type (might be due to invalid IL or missing references) //IL_00b9: Unknown result type (might be due to invalid IL or missing references) //IL_00bb: Unknown result type (might be due to invalid IL or missing references) //IL_00c0: Unknown result type (might be due to invalid IL or missing references) //IL_00c5: Unknown result type (might be due to invalid IL or missing references) //IL_00d1: Unknown result type (might be due to invalid IL or missing references) //IL_00d3: Unknown result type (might be due to invalid IL or missing references) //IL_00d8: Unknown result type (might be due to invalid IL or missing references) //IL_00eb: Unknown result type (might be due to invalid IL or missing references) //IL_00f7: Unknown result type (might be due to invalid IL or missing references) //IL_0102: Unknown result type (might be due to invalid IL or missing references) //IL_0103: Unknown result type (might be due to invalid IL or missing references) //IL_0108: Unknown result type (might be due to invalid IL or missing references) //IL_010d: Unknown result type (might be due to invalid IL or missing references) //IL_0118: Unknown result type (might be due to invalid IL or missing references) //IL_0124: Unknown result type (might be due to invalid IL or missing references) //IL_012b: Unknown result type (might be due to invalid IL or missing references) //IL_0130: Unknown result type (might be due to invalid IL or missing references) //IL_0135: Unknown result type (might be due to invalid IL or missing references) //IL_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) TemporaryOverlayInstance val = TemporaryOverlayManager.AddOverlay(((Component)characterModel).gameObject); val.duration = 0.7f; val.animateShaderAlpha = true; val.alphaCurve = AnimationCurve.EaseInOut(0f, 1f, 1f, 0f); val.destroyComponentOnEnd = true; val.originalMaterial = Prefabs.Load("RoR2/Base/Huntress/matHuntressFlashExpanded.mat"); val.AddToCharacterModel(characterModel); if (hitPos != Vector3.zero) { if (((EntityState)this).isAuthority) { TeleportHelper.TeleportBody(((EntityState)this).characterBody, hitPos + Vector3.up * 1.5f, true); new BlastAttack { position = hitPos, attacker = ((EntityState)this).gameObject, attackerFiltering = (AttackerFiltering)2, baseDamage = ((BaseState)this).damageStat * damageCoefficient, crit = ((BaseState)this).RollCrit(), baseForce = 2500f, damageType = DamageTypeCombo.GenericSpecial, procCoefficient = 1f, radius = radius, teamIndex = ((EntityState)this).teamComponent.teamIndex, falloffModel = (FalloffModel)0 }.Fire(); } EffectManager.SimpleEffect(effectPrefab, hitPos, Quaternion.identity, false); EffectData val2 = new EffectData { origin = hitPos, scale = radius }; EffectManager.SpawnEffect(Prefabs.huntressExplosion, val2, false); } AkSoundEngine.PostEvent("Play_falseson_skill1_impact_full", ((EntityState)this).gameObject); ((EntityState)this).skillLocator.primary.UnsetSkillOverride((object)((EntityState)this).gameObject, MainPlugin.huntressPrimaryOverride, (SkillOverridePriority)4); ((EntityState)this).OnExit(); } 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 Block : BaseSkillState { private float animDuration = 0.45f; private float animStopTime = 0.65f; private bool stopped; private Animator animator; private GameObject effect; public override void OnEnter() { //IL_008f: 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_00b4: Unknown result type (might be due to invalid IL or missing references) //IL_00be: Unknown result type (might be due to invalid IL or missing references) ((BaseState)this).OnEnter(); if (NetworkServer.active) { ((EntityState)this).characterBody.AddBuff(Prefabs.block); } animator = ((EntityState)this).GetModelAnimator(); ((EntityState)this).PlayAnimation("Grapple", FireHook.FireHookIntroStateHash); ((EntityState)this).PlayCrossfade("Gesture, Additive", "SwingFistRight", "SwingFist.playbackRate", animDuration, 0.1f); ((EntityState)this).PlayCrossfade("Gesture, Override", "SwingFistRight", "SwingFist.playbackRate", animDuration, 0.1f); effect = Object.Instantiate(Prefabs.shieldEffect, ((EntityState)this).transform.position, Quaternion.identity, ((EntityState)this).transform); effect.transform.localScale = Vector3.one * 1.6f; AkSoundEngine.PostEvent("Play_loader_m1_shield", ((EntityState)this).gameObject); } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); if (!stopped && ((EntityState)this).fixedAge >= animDuration * animStopTime) { stopped = true; animator.SetFloat("SwingFist.playbackRate", 0f); } if ((((EntityState)this).isAuthority && !((BaseSkillState)this).IsKeyDownAuthority()) || ((EntityState)this).fixedAge >= MainPlugin.blockDuration.Value) { if (((EntityState)this).healthComponent.barrier > 0f) { ((EntityState)this).outer.SetNextState((EntityState)(object)new Detonate()); } else { ((EntityState)this).outer.SetNextStateToMain(); } } } public override void OnExit() { ((EntityState)this).PlayAnimation("Grapple", FireHook.FireHookExitStateHash); if (Object.op_Implicit((Object)(object)effect)) { EntityState.Destroy((Object)(object)effect); } animator.SetFloat("SwingFist.playbackRate", 1f); ((EntityState)this).PlayAnimation("Gesture, Additive", "BufferEmpty"); ((EntityState)this).PlayAnimation("Gesture, Override", "BufferEmpty"); if (NetworkServer.active) { ((EntityState)this).characterBody.RemoveBuff(Prefabs.block); } ((EntityState)this).OnExit(); } 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 Detonate : BaseSkillState { public override void OnEnter() { //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_0055: Unknown result type (might be due to invalid IL or missing references) //IL_005a: Unknown result type (might be due to invalid IL or missing references) //IL_005b: Unknown result type (might be due to invalid IL or missing references) //IL_0062: Unknown result type (might be due to invalid IL or missing references) //IL_0073: Expected O, but got Unknown //IL_00af: Unknown result type (might be due to invalid IL or missing references) //IL_00b6: Expected O, but got Unknown //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_00fb: Unknown result type (might be due to invalid IL or missing references) //IL_0100: Unknown result type (might be due to invalid IL or missing references) //IL_0108: Unknown result type (might be due to invalid IL or missing references) //IL_0127: Unknown result type (might be due to invalid IL or missing references) //IL_0128: Unknown result type (might be due to invalid IL or missing references) //IL_0130: Unknown result type (might be due to invalid IL or missing references) //IL_013c: Unknown result type (might be due to invalid IL or missing references) //IL_0141: Unknown result type (might be due to invalid IL or missing references) //IL_014e: Unknown result type (might be due to invalid IL or missing references) //IL_0153: Unknown result type (might be due to invalid IL or missing references) //IL_0160: Unknown result type (might be due to invalid IL or missing references) //IL_0167: Unknown result type (might be due to invalid IL or missing references) ((BaseState)this).OnEnter(); ((EntityState)this).PlayCrossfade("Body", "GroundSlam", 0.2f); if (NetworkServer.active) { ((EntityState)this).characterBody.AddTimedBuff(Buffs.HiddenInvincibility, MainPlugin.blockInvincibilityDuration.Value); } Vector3 footPosition = ((EntityState)this).characterBody.footPosition; EffectManager.SpawnEffect(GroundSlam.blastEffectPrefab, new EffectData { origin = footPosition, scale = GroundSlam.blastRadius }, false); float num = 1f + ((EntityState)this).healthComponent.barrier / ((EntityState)this).healthComponent.fullBarrier; float num2 = MainPlugin.blockWaveDamage.Value * num; if (((EntityState)this).isAuthority) { BlastAttack val = new BlastAttack(); val.attacker = ((EntityState)this).gameObject; val.baseDamage = ((BaseState)this).damageStat * num2; val.baseForce = GroundSlam.blastForce; val.bonusForce = GroundSlam.blastBonusForce; val.crit = ((BaseState)this).RollCrit(); val.damageType = DamageTypeCombo.op_Implicit((DamageType)32); val.falloffModel = (FalloffModel)0; val.procCoefficient = GroundSlam.blastProcCoefficient; val.radius = GroundSlam.blastRadius; val.position = footPosition; val.attackerFiltering = (AttackerFiltering)2; val.impactEffect = EffectCatalog.FindEffectIndexFromPrefab(GroundSlam.blastImpactEffectPrefab); val.teamIndex = ((EntityState)this).teamComponent.teamIndex; val.damageType.damageSource = (DamageSource)8; val.Fire(); } if (NetworkServer.active) { ((EntityState)this).healthComponent.SetBarrier(0f); } } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); if (((EntityState)this).isAuthority && ((EntityState)this).fixedAge >= 0.25f) { ((EntityState)this).outer.SetNextStateToMain(); } } public override void OnExit() { ((EntityState)this).PlayCrossfade("Body", "Jump", 0.2f); if (NetworkServer.active) { } if (((EntityState)this).isAuthority) { ((EntityState)this).characterMotor.velocity.y = GroundSlam.exitVerticalVelocity; } ((EntityState)this).OnExit(); } 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 BlockOld : BaseSkillState { private float animDuration = 0.45f; private float animStopTime = 0.65f; private bool stopped; private Animator animator; private GameObject effect; public override void OnEnter() { //IL_008f: 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_00b4: Unknown result type (might be due to invalid IL or missing references) //IL_00be: Unknown result type (might be due to invalid IL or missing references) ((BaseState)this).OnEnter(); if (NetworkServer.active) { ((EntityState)this).characterBody.AddBuff(Prefabs.block); } animator = ((EntityState)this).GetModelAnimator(); ((EntityState)this).PlayAnimation("Grapple", FireHook.FireHookIntroStateHash); ((EntityState)this).PlayCrossfade("Gesture, Additive", "SwingFistRight", "SwingFist.playbackRate", animDuration, 0.1f); ((EntityState)this).PlayCrossfade("Gesture, Override", "SwingFistRight", "SwingFist.playbackRate", animDuration, 0.1f); effect = Object.Instantiate(Prefabs.shieldEffect, ((EntityState)this).transform.position, Quaternion.identity, ((EntityState)this).transform); effect.transform.localScale = Vector3.one * 1.6f; AkSoundEngine.PostEvent("Play_loader_m1_shield", ((EntityState)this).gameObject); } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); if (!stopped && ((EntityState)this).fixedAge >= animDuration * animStopTime) { stopped = true; animator.SetFloat("SwingFist.playbackRate", 0f); } if ((((EntityState)this).isAuthority && !((BaseSkillState)this).IsKeyDownAuthority()) || ((EntityState)this).fixedAge >= MainPlugin.blockDuration.Value) { if (((EntityState)this).healthComponent.barrier > 0f) { ((EntityState)this).outer.SetNextState((EntityState)(object)new SlamOld()); } else { ((EntityState)this).outer.SetNextStateToMain(); } } } public override void OnExit() { ((EntityState)this).PlayAnimation("Grapple", FireHook.FireHookExitStateHash); if (Object.op_Implicit((Object)(object)effect)) { EntityState.Destroy((Object)(object)effect); } animator.SetFloat("SwingFist.playbackRate", 1f); if (NetworkServer.active) { ((EntityState)this).characterBody.RemoveBuff(Prefabs.block); } ((EntityState)this).OnExit(); } 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 SlamOld : GroundSlam { private float stopwatch; private float damageCoefficient; private float barrierPercentage; public override void OnEnter() { ((EntityState)this).PlayAnimation("Body", PreGroundSlam.PreGroundSlamStateHash, PreGroundSlam.GroundSlamParamHash, 0.25f); ((BaseCharacterController)((EntityState)this).characterMotor).Motor.ForceUnground(0.1f); ((EntityState)this).characterMotor.disableAirControlUntilCollision = false; ((GroundSlam)this).OnEnter(); barrierPercentage = 1f + ((EntityState)this).healthComponent.barrier / ((EntityState)this).healthComponent.fullBarrier; damageCoefficient = MainPlugin.blockWaveDamage.Value * barrierPercentage; if (NetworkServer.active) { ((EntityState)this).healthComponent.SetBarrier(0f); } } public override void FixedUpdate() { //IL_0030: 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_0045: Unknown result type (might be due to invalid IL or missing references) //IL_0098: Unknown result type (might be due to invalid IL or missing references) //IL_009d: Unknown result type (might be due to invalid IL or missing references) //IL_00aa: Unknown result type (might be due to invalid IL or missing references) //IL_00af: 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_00c3: Unknown result type (might be due to invalid IL or missing references) //IL_00c8: Unknown result type (might be due to invalid IL or missing references) ((GroundSlam)this).FixedUpdate(); ((EntityState)this).fixedAge = 0f; stopwatch += Time.fixedDeltaTime; Prefabs.slamProjectile.transform.localScale = Vector3.one * 0.5f * barrierPercentage; if (stopwatch >= GroundSlam.minimumDuration && (base.detonateNextFrame || ((BaseCharacterController)((EntityState)this).characterMotor).Motor.GroundingStatus.IsStableOnGround)) { EffectManager.SimpleEffect(Prefabs.Load("RoR2/Base/Loader/LoaderGroundSlam.prefab"), ((EntityState)this).characterBody.footPosition, Quaternion.identity, true); Ray aimRay = ((BaseState)this).GetAimRay(); ProjectileManager.instance.FireProjectile(Prefabs.slamProjectile, ((Ray)(ref aimRay)).origin, Quaternion.LookRotation(((Ray)(ref aimRay)).direction), ((EntityState)this).gameObject, ((BaseState)this).damageStat * damageCoefficient, 10f, ((BaseState)this).RollCrit(), (DamageColorIndex)0, (GameObject)null, -1f, (DamageTypeCombo?)null); ((EntityState)this).outer.SetNextStateToMain(); } } public override void OnExit() { ((EntityState)this).PlayAnimation("Body", "Jump"); ((GroundSlam)this).OnExit(); } public override InterruptPriority GetMinimumInterruptPriority() { //IL_0003: Unknown result type (might be due to invalid IL or missing references) //IL_0006: Unknown result type (might be due to invalid IL or missing references) return (InterruptPriority)9; } } internal class ChargeFist : BaseChargeFist { public override void OnEnter() { base.baseChargeDuration = 2.5f; BaseChargeFist.minChargeForChargedAttack = 0f; BaseChargeFist.chargeVfxChildLocatorName = "MechHandR"; BaseChargeFist.walkSpeedCoefficient = 0.75f; BaseChargeFist.startChargeLoopSFXString = "Play_loader_shift_charge_loop"; BaseChargeFist.endChargeLoopSFXString = "Stop_loader_shift_charge_loop"; BaseChargeFist.enterSFXString = "Play_loader_shift_activate"; ((BaseChargeFist)this).OnEnter(); } public override EntityState GetNextStateAuthority() { return (EntityState)(object)new FireFist { charge = ((BaseChargeFist)this).charge }; } } internal class FireFist : BaseSwingChargedFist { public override void OnEnter() { //IL_0070: Unknown result type (might be due to invalid IL or missing references) //IL_007a: Unknown result type (might be due to invalid IL or missing references) //IL_007f: Unknown result type (might be due to invalid IL or missing references) base.minLungeSpeed = 20f; base.maxLungeSpeed = 90f; base.minPunchForce = 1000f; base.maxPunchForce = 3000f; base.minDuration = 0.3f; base.maxDuration = 0.5f; ((BasicMeleeAttack)this).baseDuration = 0.5f; ((BasicMeleeAttack)this).hitBoxGroupName = "Punch"; ((BasicMeleeAttack)this).procCoefficient = 1f; ((BasicMeleeAttack)this).pushAwayForce = 1200f; ((BasicMeleeAttack)this).forceVector = Vector3.forward * 2400f; ((BasicMeleeAttack)this).hitPauseDuration = 0.2f; ((BasicMeleeAttack)this).swingEffectMuzzleString = "MechHandR"; ((BasicMeleeAttack)this).shorthopVelocityFromHit = 0f; ((BasicMeleeAttack)this).beginStateSoundString = "Play_loader_shift_release"; ((BasicMeleeAttack)this).forceForwardVelocity = false; ((BasicMeleeAttack)this).scaleHitPauseDurationAndVelocityWithAttackSpeed = false; ((BasicMeleeAttack)this).ignoreAttackSpeed = false; BaseSwingChargedFist.disableAirControlUntilCollision = false; BaseSwingChargedFist.speedCoefficientOnExit = 0.5f; BaseSwingChargedFist.velocityDamageCoefficient = 0.3f; ((BasicMeleeAttack)this).damageCoefficient = 0f; ((BaseSwingChargedFist)this).OnEnter(); base.bonusDamage = 0f; } public override void OnMeleeHitAuthority() { //IL_0007: Unknown result type (might be due to invalid IL or missing references) //IL_000c: Unknown result type (might be due to invalid IL or missing references) ((EntityState)this).characterMotor.velocity = Vector3.zero; ((EntityState)this).outer.SetNextState((EntityState)(object)new PunchCombo()); } public override void AuthorityModifyOverlapAttack(OverlapAttack overlapAttack) { //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) ((BaseSwingChargedFist)this).AuthorityModifyOverlapAttack(overlapAttack); overlapAttack.damageType = DamageTypeCombo.GenericUtility; } } internal class PunchCombo : BaseSkillState { private float duration; private float basePunchDuration; private int punchCount = 5; private int punches; private float stopwatch = 1f; private bool left = true; private OverlapAttack attack; private Animator animator; private Transform modelTransform; private GameObject effectLeft; private GameObject effectRight; private GameObject chargePrefab = Prefabs.Load("RoR2/Base/Loader/LoaderFistLoop.prefab"); public override void OnEnter() { //IL_0093: Unknown result type (might be due to invalid IL or missing references) //IL_0098: Unknown result type (might be due to invalid IL or missing references) ((BaseState)this).OnEnter(); animator = ((EntityState)this).GetModelAnimator(); modelTransform = ((Component)animator).transform; basePunchDuration = MainPlugin.punchSpeed.Value / ((BaseState)this).attackSpeedStat; duration = (float)punchCount * basePunchDuration; Transform muzzle = ((BaseState)this).FindModelChild("MechHandL"); effectLeft = InstantiateChargeFX(muzzle); muzzle = ((BaseState)this).FindModelChild("MechHandR"); effectRight = InstantiateChargeFX(muzzle); if (((EntityState)this).isAuthority) { ((EntityState)this).characterMotor.velocity = Vector3.zero; } } private GameObject InstantiateChargeFX(Transform muzzle) { //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) GameObject val = Object.Instantiate(chargePrefab, muzzle.position, Quaternion.identity, muzzle); val.GetComponent().newDuration = duration; return val; } private void Punch() { //IL_0013: 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_0021: Unknown result type (might be due to invalid IL or missing references) //IL_0030: Unknown result type (might be due to invalid IL or missing references) //IL_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_0107: Unknown result type (might be due to invalid IL or missing references) //IL_010a: Unknown result type (might be due to invalid IL or missing references) //IL_010f: Unknown result type (might be due to invalid IL or missing references) //IL_013d: Unknown result type (might be due to invalid IL or missing references) //IL_0142: Unknown result type (might be due to invalid IL or missing references) Ray aimRay; if (((EntityState)this).isAuthority) { CharacterMotor characterMotor = ((EntityState)this).characterMotor; Vector3 velocity = characterMotor.velocity; aimRay = ((BaseState)this).GetAimRay(); characterMotor.velocity = velocity + ((Ray)(ref aimRay)).direction * MainPlugin.punchVelocity.Value; } left = !left; punches++; AkSoundEngine.PostEvent("Play_loader_shift_release", ((EntityState)this).gameObject); if (!left) { ((EntityState)this).PlayAnimation("Grapple", FireHook.FireHookExitStateHash); ((EntityState)this).PlayCrossfade("FullBody, Override", BaseSwingChargedFist.ChargePunchStateHash, BaseSwingChargedFist.ChargePunchParamHash, basePunchDuration, 0.1f); } else { ((EntityState)this).PlayAnimation("Grapple", FireHook.FireHookIntroStateHash); ((EntityState)this).PlayCrossfade("Gesture, Override", "SwingFistLeft", "SwingFist.playbackRate", basePunchDuration, 0.1f); } AkSoundEngine.PostEvent("Play_loader_m1_swing", ((EntityState)this).gameObject); if (((EntityState)this).isAuthority) { aimRay = ((BaseState)this).GetAimRay(); Vector3 direction = ((Ray)(ref aimRay)).direction; attack = ((BaseState)this).InitMeleeOverlap(MainPlugin.punchDamageCoefficient.Value, Prefabs.loaderImpact, ((EntityState)this).GetModelTransform(), "Punch"); attack.damageType = DamageTypeCombo.GenericUtility; } } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); ((BaseState)this).StartAimMode(2f, false); if (((BaseState)this).isGrounded) { ((BaseCharacterController)((EntityState)this).characterMotor).Motor.ForceUnground(0.1f); ((BaseState)this).SmallHop(((EntityState)this).characterMotor, 5f); } stopwatch += Time.fixedDeltaTime; if (stopwatch >= basePunchDuration) { stopwatch = 0f; Punch(); } if (attack != null && attack.Fire((List)null) && !((BaseState)this).isGrounded) { ((BaseState)this).SmallHop(((EntityState)this).characterMotor, 7f); } ((EntityState)this).skillLocator.utility.rechargeStopwatch = 0f; if ((((EntityState)this).isAuthority && ((EntityState)this).fixedAge >= duration) || punches >= punchCount) { ((EntityState)this).outer.SetNextStateToMain(); } } public override void OnExit() { //IL_000b: Unknown result type (might be due to invalid IL or missing references) //IL_001a: Unknown result type (might be due to invalid IL or missing references) //IL_001f: Unknown result type (might be due to invalid IL or missing references) //IL_0026: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_003a: 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_0046: 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_0048: 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) if (NetworkServer.active) { Vector3 val = Vector3.up * MainPlugin.punchComboUpForce.Value; Vector3 val2 = -((EntityState)this).characterDirection.forward * MainPlugin.punchComboBackForce.Value; ((EntityState)this).healthComponent.TakeDamageForce(val2 + val, false, false); } if (left) { ((EntityState)this).PlayAnimation("Grapple", FireHook.FireHookExitStateHash); } if (Object.op_Implicit((Object)(object)effectLeft)) { EntityState.Destroy((Object)(object)effectLeft); } if (Object.op_Implicit((Object)(object)effectRight)) { EntityState.Destroy((Object)(object)effectRight); } ((Component)modelTransform).transform.localScale = Vector3.one; ((EntityState)this).OnExit(); } 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 ChargePunchesOld : BaseSkillState { private float chargePerPunch; private float maxChargeTime; private GameObject effectLeft; private GameObject effectRight; private GameObject chargePrefab = Prefabs.Load("RoR2/Base/Loader/ChargeLoaderFist.prefab"); private uint ID; public override void OnEnter() { ((BaseState)this).OnEnter(); chargePerPunch = MainPlugin.punchChargeTime.Value; maxChargeTime = (float)MainPlugin.maxPunchCount.Value * chargePerPunch; Transform muzzle = ((BaseState)this).FindModelChild("MechHandL"); effectLeft = InstantiateChargeFX(muzzle); muzzle = ((BaseState)this).FindModelChild("MechHandR"); effectRight = InstantiateChargeFX(muzzle); Util.PlaySound(BaseChargeFist.enterSFXString, ((EntityState)this).gameObject); ID = AkSoundEngine.PostEvent("Play_loader_shift_charge_loop", ((EntityState)this).gameObject); } private GameObject InstantiateChargeFX(Transform muzzle) { //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) GameObject val = Object.Instantiate(chargePrefab, muzzle.position, Quaternion.identity, muzzle); val.GetComponent().newDuration = maxChargeTime; return val; } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); if (((EntityState)this).isAuthority && !((BaseSkillState)this).IsKeyDownAuthority()) { ((EntityState)this).outer.SetNextState((EntityState)(object)new PunchesOld { punchCount = Mathf.Clamp(Mathf.FloorToInt(((EntityState)this).fixedAge / chargePerPunch), 2, MainPlugin.maxPunchCount.Value) }); } } public override void OnExit() { Util.PlaySound(BaseChargeFist.endChargeLoopSFXString, ((EntityState)this).gameObject); AkSoundEngine.StopPlayingID(ID); if (Object.op_Implicit((Object)(object)effectLeft)) { EntityState.Destroy((Object)(object)effectLeft); } if (Object.op_Implicit((Object)(object)effectRight)) { EntityState.Destroy((Object)(object)effectRight); } ((EntityState)this).OnExit(); } 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 PunchesOld : BaseSkillState { private float duration; private float basePunchDuration; public int punchCount; private int punches; private float stopwatch = 1f; private bool left = true; private OverlapAttack attack; private Animator animator; private Transform modelTransform; private GameObject effectLeft; private GameObject effectRight; private GameObject chargePrefab = Prefabs.Load("RoR2/Base/Loader/LoaderFistLoop.prefab"); public override void OnSerialize(NetworkWriter writer) { ((BaseSkillState)this).OnSerialize(writer); writer.Write((byte)punchCount); } public override void OnDeserialize(NetworkReader reader) { ((BaseSkillState)this).OnDeserialize(reader); punchCount = reader.ReadByte(); } public override void OnEnter() { //IL_0094: Unknown result type (might be due to invalid IL or missing references) //IL_009a: Unknown result type (might be due to invalid IL or missing references) //IL_009f: Unknown result type (might be due to invalid IL or missing references) //IL_00a2: Unknown result type (might be due to invalid IL or missing references) //IL_00b1: Unknown result type (might be due to invalid IL or missing references) //IL_00b6: Unknown result type (might be due to invalid IL or missing references) //IL_00bb: Unknown result type (might be due to invalid IL or missing references) ((BaseState)this).OnEnter(); animator = ((EntityState)this).GetModelAnimator(); modelTransform = ((Component)animator).transform; basePunchDuration = MainPlugin.punchSpeed.Value / ((BaseState)this).attackSpeedStat; duration = (float)punchCount * basePunchDuration; Transform muzzle = ((BaseState)this).FindModelChild("MechHandL"); effectLeft = InstantiateChargeFX(muzzle); muzzle = ((BaseState)this).FindModelChild("MechHandR"); effectRight = InstantiateChargeFX(muzzle); if (((EntityState)this).isAuthority) { CharacterMotor characterMotor = ((EntityState)this).characterMotor; Vector3 velocity = characterMotor.velocity; Ray aimRay = ((BaseState)this).GetAimRay(); characterMotor.velocity = velocity + ((Ray)(ref aimRay)).direction * MainPlugin.punchVelocity.Value; } } private GameObject InstantiateChargeFX(Transform muzzle) { //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) GameObject val = Object.Instantiate(chargePrefab, muzzle.position, Quaternion.identity, muzzle); val.GetComponent().newDuration = duration; return val; } private void Punch() { //IL_00c3: Unknown result type (might be due to invalid IL or missing references) //IL_00c8: Unknown result type (might be due to invalid IL or missing references) //IL_00cb: Unknown result type (might be due to invalid IL or missing references) //IL_00d0: Unknown result type (might be due to invalid IL or missing references) //IL_00fd: 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) left = !left; punches++; AkSoundEngine.PostEvent("Play_loader_shift_release", ((EntityState)this).gameObject); if (!left) { ((EntityState)this).PlayAnimation("Grapple", FireHook.FireHookExitStateHash); ((EntityState)this).PlayCrossfade("FullBody, Override", BaseSwingChargedFist.ChargePunchStateHash, BaseSwingChargedFist.ChargePunchParamHash, basePunchDuration, 0.1f); } else { ((EntityState)this).PlayAnimation("Grapple", FireHook.FireHookIntroStateHash); ((EntityState)this).PlayCrossfade("Gesture, Override", "SwingFistLeft", "SwingFist.playbackRate", basePunchDuration, 0.1f); } AkSoundEngine.PostEvent("Play_loader_m1_swing", ((EntityState)this).gameObject); if (((EntityState)this).isAuthority) { Ray aimRay = ((BaseState)this).GetAimRay(); Vector3 direction = ((Ray)(ref aimRay)).direction; attack = ((BaseState)this).InitMeleeOverlap(MainPlugin.punchDamageCoefficient.Value, Prefabs.loaderImpact, ((EntityState)this).GetModelTransform(), "Punch"); attack.damageType = DamageTypeCombo.GenericPrimary; } } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); ((BaseState)this).StartAimMode(2f, false); if (((BaseState)this).isGrounded) { ((BaseCharacterController)((EntityState)this).characterMotor).Motor.ForceUnground(0.1f); ((BaseState)this).SmallHop(((EntityState)this).characterMotor, 5f); } stopwatch += Time.fixedDeltaTime; if (stopwatch >= basePunchDuration) { stopwatch = 0f; Punch(); } if (attack != null && attack.Fire((List)null)) { ((BaseState)this).SmallHop(((EntityState)this).characterMotor, 7f); ((EntityState)this).healthComponent.AddBarrierAuthority(LoaderMeleeAttack.barrierPercentagePerHit * ((EntityState)this).healthComponent.fullBarrier); } ((EntityState)this).skillLocator.utility.rechargeStopwatch = 0f; if ((((EntityState)this).isAuthority && ((EntityState)this).fixedAge >= duration) || punches >= MainPlugin.maxPunchCount.Value) { ((EntityState)this).outer.SetNextStateToMain(); } } public override void OnExit() { //IL_0063: Unknown result type (might be due to invalid IL or missing references) if (left) { ((EntityState)this).PlayAnimation("Grapple", FireHook.FireHookExitStateHash); } if (Object.op_Implicit((Object)(object)effectLeft)) { EntityState.Destroy((Object)(object)effectLeft); } if (Object.op_Implicit((Object)(object)effectRight)) { EntityState.Destroy((Object)(object)effectRight); } ((Component)modelTransform).transform.localScale = Vector3.one; ((EntityState)this).OnExit(); } 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 FireSwordCharge : BaseSkillState { private float duration = 2f; private float charge; private GameObject chargeEffect; private uint ID; private OverrideRequest crosshairOverrideRequest; private AimRequest request; public override void OnEnter() { //IL_004b: Unknown result type (might be due to invalid IL or missing references) //IL_0050: Unknown result type (might be due to invalid IL or missing references) ((BaseState)this).OnEnter(); ((BaseState)this).StartAimMode(duration + 2f, false); ((EntityState)this).PlayAnimation("Gesture, Additive", BaseChargeBombState.ChargeNovaBombStateHash, BaseChargeBombState.ChargeNovaBombParamHash, duration); Transform val = ((BaseState)this).FindModelChild("MuzzleBetween"); chargeEffect = Object.Instantiate(Prefabs.fireSwordChargeEffect, val.position, Quaternion.identity, val); ID = Util.PlayAttackSpeedSound("Play_mage_m2_charge", ((EntityState)this).gameObject, ((BaseState)this).attackSpeedStat); request = ((EntityState)this).cameraTargetParams.RequestAimType((AimType)2); } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); charge = Mathf.Clamp01(((EntityState)this).fixedAge / duration); if (((EntityState)this).isAuthority && ((!((BaseSkillState)this).IsKeyDownAuthority() && ((EntityState)this).fixedAge >= 0.5f) || ((EntityState)this).fixedAge >= duration)) { ((EntityState)this).outer.SetNextState((EntityState)(object)new FireSword { charge = charge }); } } public override void Update() { ((EntityState)this).Update(); ((EntityState)this).characterBody.SetSpreadBloom(Util.Remap(charge, 0f, 1f, 0.1f, 0.5f), true); } public override void OnExit() { request.Dispose(); AkSoundEngine.StopPlayingID(ID); if (Object.op_Implicit((Object)(object)chargeEffect)) { EntityState.Destroy((Object)(object)chargeEffect); } ((EntityState)this).PlayAnimation("Gesture, Additive", BaseChargeBombState.EmptyStateHash); ((EntityState)this).OnExit(); } 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)5; } } internal class FireSword : BaseSkillState { public float charge; private float duration = 0.45f; private bool stopped; private float stopTime; public override void OnSerialize(NetworkWriter writer) { ((BaseSkillState)this).OnSerialize(writer); writer.Write((byte)charge); } public override void OnDeserialize(NetworkReader reader) { ((BaseSkillState)this).OnDeserialize(reader); charge = (int)reader.ReadByte(); } public override void OnEnter() { //IL_004f: Unknown result type (might be due to invalid IL or missing references) //IL_0054: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_005c: Unknown result type (might be due to invalid IL or missing references) //IL_0073: Unknown result type (might be due to invalid IL or missing references) //IL_007a: 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_008e: Unknown result type (might be due to invalid IL or missing references) //IL_00d8: Unknown result type (might be due to invalid IL or missing references) //IL_00db: Unknown result type (might be due to invalid IL or missing references) //IL_00e0: Unknown result type (might be due to invalid IL or missing references) //IL_010c: Unknown result type (might be due to invalid IL or missing references) ((BaseState)this).OnEnter(); EffectManager.SimpleMuzzleFlash(Prefabs.Load("RoR2/Base/Mage/MuzzleflashMageFire.prefab"), ((EntityState)this).gameObject, "MuzzleBetween", false); ((EntityState)this).PlayAnimation("Gesture, Additive", BaseThrowBombState.FireNovaBombStateHash, BaseThrowBombState.FireNovaBombParamHash, duration); if (((EntityState)this).isAuthority) { Ray aimRay = ((BaseState)this).GetAimRay(); Vector3 val = ((Ray)(ref aimRay)).origin; if (charge < 1f) { val = ((Ray)(ref aimRay)).origin + ((Ray)(ref aimRay)).direction * 5f; } float num = Util.Remap(charge, 0f, 1f, MainPlugin.mageFlameSwordMinDamage.Value, MainPlugin.mageFlameSwordMaxDamage.Value); ProjectileManager.instance.FireProjectile((charge >= 1f) ? Prefabs.fireSwordProjectile : Prefabs.fireSwordProjectileDotZone, val, Util.QuaternionSafeLookRotation(((Ray)(ref aimRay)).direction), ((EntityState)this).gameObject, ((BaseState)this).damageStat * num, charge * 8000f, ((BaseState)this).RollCrit(), (DamageColorIndex)0, (GameObject)null, -1f, (DamageTypeCombo?)DamageTypeCombo.GenericSecondary); } AkSoundEngine.PostEvent("Play_mage_R_start", ((EntityState)this).gameObject); stopTime = ((charge >= 1f) ? 0.15f : 0.3f); } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); if (!stopped && ((EntityState)this).fixedAge >= stopTime) { stopped = true; AkSoundEngine.PostEvent("Play_mage_R_end", ((EntityState)this).gameObject); } if (((EntityState)this).isAuthority && ((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)2; } } internal class MageSpecial : BaseSkillState { private float duration = 0.4f; private GameObject effectL; private GameObject effectR; public override void OnEnter() { //IL_001b: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_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_0109: Unknown result type (might be due to invalid IL or missing references) //IL_010e: Unknown result type (might be due to invalid IL or missing references) //IL_0115: Unknown result type (might be due to invalid IL or missing references) //IL_0120: Unknown result type (might be due to invalid IL or missing references) //IL_012d: Expected O, but got Unknown //IL_006b: Unknown result type (might be due to invalid IL or missing references) //IL_0070: Unknown result type (might be due to invalid IL or missing references) //IL_016f: Unknown result type (might be due to invalid IL or missing references) //IL_0174: Unknown result type (might be due to invalid IL or missing references) //IL_0180: Unknown result type (might be due to invalid IL or missing references) //IL_0182: Unknown result type (might be due to invalid IL or missing references) //IL_0187: 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_01a5: Unknown result type (might be due to invalid IL or missing references) //IL_01b1: Unknown result type (might be due to invalid IL or missing references) //IL_01b2: Unknown result type (might be due to invalid IL or missing references) //IL_01bc: Unknown result type (might be due to invalid IL or missing references) //IL_01c1: Unknown result type (might be due to invalid IL or missing references) //IL_01c6: Unknown result type (might be due to invalid IL or missing references) //IL_01cb: Unknown result type (might be due to invalid IL or missing references) //IL_01ce: Unknown result type (might be due to invalid IL or missing references) //IL_01d3: 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_01ea: Unknown result type (might be due to invalid IL or missing references) //IL_01f1: Unknown result type (might be due to invalid IL or missing references) //IL_01f8: Unknown result type (might be due to invalid IL or missing references) //IL_01fd: Unknown result type (might be due to invalid IL or missing references) //IL_0202: Unknown result type (might be due to invalid IL or missing references) //IL_0209: Unknown result type (might be due to invalid IL or missing references) //IL_020e: Unknown result type (might be due to invalid IL or missing references) //IL_0213: Unknown result type (might be due to invalid IL or missing references) //IL_00a2: Unknown result type (might be due to invalid IL or missing references) //IL_0087: 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_00c6: 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_00d9: Unknown result type (might be due to invalid IL or missing references) //IL_00e3: Unknown result type (might be due to invalid IL or missing references) //IL_00e8: Unknown result type (might be due to invalid IL or missing references) //IL_00ea: Unknown result type (might be due to invalid IL or missing references) ((BaseState)this).OnEnter(); Transform val = ((BaseState)this).FindModelChild("MuzzleLeft"); effectL = Object.Instantiate(Prefabs.mageMuzzleTrail, val.position, Quaternion.identity, val); val = ((BaseState)this).FindModelChild("MuzzleRight"); effectR = Object.Instantiate(Prefabs.mageMuzzleTrail, val.position, Quaternion.identity, val); if (NetworkServer.active) { if (((EntityState)this).inputBank.moveVector == Vector3.zero) { ((EntityState)this).healthComponent.TakeDamageForce(Vector3.up * 2400f, false, false); } else { Vector3 val2 = Vector3.up * (float)(((EntityState)this).inputBank.jump.down ? 3000 : 1600); ((EntityState)this).healthComponent.TakeDamageForce(((EntityState)this).inputBank.moveVector * 2700f + val2, false, false); } } float num = 12f; EffectManager.SpawnEffect(Prefabs.Load("RoR2/Base/EliteIce/AffixWhiteExplosion.prefab"), new EffectData { origin = ((EntityState)this).transform.position, scale = num }, false); GameObject val3 = Prefabs.Load("RoR2/Junk/Mage/MuzzleflashMageIce.prefab"); EffectManager.SimpleMuzzleFlash(val3, ((EntityState)this).gameObject, "MuzzleLeft", false); EffectManager.SimpleMuzzleFlash(val3, ((EntityState)this).gameObject, "MuzzleRight", false); if (((EntityState)this).isAuthority) { new BlastAttack { attacker = ((EntityState)this).gameObject, attackerFiltering = (AttackerFiltering)2, falloffModel = (FalloffModel)0, baseDamage = ((BaseState)this).damageStat * MainPlugin.mageSpecialDamage.Value, crit = ((BaseState)this).RollCrit(), damageType = (DamageTypeCombo.GenericSpecial | DamageTypeCombo.op_Implicit((DamageType)256)), damageColorIndex = (DamageColorIndex)10, inflictor = ((EntityState)this).gameObject, procCoefficient = 0.25f, radius = num, teamIndex = ((EntityState)this).teamComponent.teamIndex, position = ((EntityState)this).transform.position }.Fire(); } ((EntityState)this).PlayAnimation("Gesture, Additive", PrepWall.FireWallStateHash); } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); if ((((EntityState)this).isAuthority && ((EntityState)this).fixedAge >= duration) || (((EntityState)this).fixedAge >= 0.25f && ((BaseState)this).isGrounded)) { ((EntityState)this).outer.SetNextStateToMain(); } } public override void OnExit() { if (Object.op_Implicit((Object)(object)effectL)) { EntityState.Destroy((Object)(object)effectL); } if (Object.op_Implicit((Object)(object)effectR)) { EntityState.Destroy((Object)(object)effectR); } ((EntityState)this).OnExit(); } public override InterruptPriority GetMinimumInterruptPriority() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (InterruptPriority)1; } } internal class MercPrimary : BaseSkillState { private float duration; private float baseDuration = MainPlugin.mercPrimaryBaseDuration.Value; private float attackInterval; private float stopwatch; private Animator animator; public int attackIndex = 1; private OverlapAttack attack; private float damageCoefficient = MainPlugin.mercPrimaryDamage.Value; private Transform modelTransform; private bool fire; private int attackCount; private bool hasHit; private float earlyExitDuration; private bool spawnEffect = true; private string animationStateName; private GameObject swingEffectInstance; private GameObject impactEffect => Prefabs.Load("RoR2/Base/Merc/OmniImpactVFXSlashMerc.prefab"); private GameObject swingEffect => Prefabs.Load("RoR2/Base/Merc/MercSwordFinisherSlash.prefab"); public override void OnSerialize(NetworkWriter writer) { ((BaseSkillState)this).OnSerialize(writer); writer.Write(attackIndex); } public override void OnDeserialize(NetworkReader reader) { ((BaseSkillState)this).OnDeserialize(reader); attackIndex = reader.ReadInt32(); } public override void OnEnter() { ((BaseState)this).OnEnter(); ((BaseState)this).StartAimMode(2f, false); duration = baseDuration / ((BaseState)this).attackSpeedStat; earlyExitDuration = duration * 0.85f; attackInterval = duration * 0.09f; modelTransform = ((EntityState)this).GetModelTransform(); animationStateName = "GroundLight" + attackIndex; animator = ((EntityState)this).GetModelAnimator(); if (!animator.GetBool("isMoving") && animator.GetBool("isGrounded")) { ((EntityState)this).PlayCrossfade("FullBody, Override", animationStateName, "GroundLight.playbackRate", duration, 0.05f); } else { ((EntityState)this).PlayCrossfade("Gesture, Additive", animationStateName, "GroundLight.playbackRate", duration, 0.05f); ((EntityState)this).PlayCrossfade("Gesture, Override", animationStateName, "GroundLight.playbackRate", duration, 0.05f); } ((BaseState)this).AddRecoil(-0.1f * GroundLight2.recoilAmplitude, 0.1f * GroundLight2.recoilAmplitude, -1f * GroundLight2.recoilAmplitude, 1f * GroundLight2.recoilAmplitude); ((EntityState)this).GetComponent().Scale(); NewAttack(); } private void NewAttack() { //IL_002a: Unknown result type (might be due to invalid IL or missing references) //IL_002f: Unknown result type (might be due to invalid IL or missing references) attack = ((BaseState)this).InitMeleeOverlap(damageCoefficient, impactEffect, modelTransform, "SwordLarge"); attack.damageType = DamageTypeCombo.GenericPrimary; attackCount++; } public override void FixedUpdate() { //IL_0071: 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) ((EntityState)this).FixedUpdate(); if (!fire && animator.GetFloat("Sword.active") >= 0.09f) { fire = true; if (spawnEffect) { spawnEffect = false; AkSoundEngine.PostEvent(GroundLight2.slash1Sound, ((EntityState)this).gameObject); Transform val = ((BaseState)this).FindModelChild(animationStateName); swingEffectInstance = Object.Instantiate(swingEffect, val.position, val.rotation, val); } } if (fire) { stopwatch += Time.fixedDeltaTime; if (stopwatch >= attackInterval) { stopwatch = 0f; NewAttack(); } if (((EntityState)this).isAuthority && attack != null) { hasHit = attack.Fire((List)null) || hasHit; if (hasHit) { hasHit = false; ((BaseState)this).SmallHop(((EntityState)this).characterMotor, 0f); } } if (attackCount >= 5) { fire = false; } } if (((EntityState)this).isAuthority) { if (((EntityState)this).fixedAge >= earlyExitDuration && ((EntityState)this).inputBank.skill1.down) { ((EntityState)this).outer.SetNextState((EntityState)(object)new MercPrimary { attackIndex = ((attackIndex == 2) ? 1 : 2) }); } else if (((EntityState)this).fixedAge >= duration) { ((EntityState)this).outer.SetNextStateToMain(); } } } public override void OnExit() { if (Object.op_Implicit((Object)(object)swingEffectInstance)) { EntityState.Destroy((Object)(object)swingEffectInstance); } ((EntityState)this).OnExit(); } 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 MercSpecial : Assaulter2 { public override bool allowExitFire => false; public override void OnEnter() { ((BasicMeleeAttack)this).baseDuration = 0.15f; ((BasicMeleeAttack)this).hitBoxGroupName = "Assaulter"; ((BasicMeleeAttack)this).hitEffectPrefab = Prefabs.Load("RoR2/Base/Merc/OmniImpactVFXSlashMerc.prefab"); ((BasicMeleeAttack)this).hitPauseDuration = 0.1f; ((BasicMeleeAttack)this).swingEffectPrefab = Prefabs.Load("RoR2/Base/Merc/MercAssaulterEffect.prefab"); ((BasicMeleeAttack)this).swingEffectMuzzleString = "DashCenter"; ((BasicMeleeAttack)this).forceForwardVelocity = false; ((BasicMeleeAttack)this).damageCoefficient = MainPlugin.mercSpecialDashDamage.Value; ((Assaulter2)this).OnEnter(); } public override void OnMeleeHitAuthority() { ((Assaulter2)this).OnMeleeHitAuthority(); ((EntityState)this).outer.SetNextState((EntityState)(object)new MercSpecialFollowUp()); } } internal class MercSpecialFollowUp : Uppercut { private bool stoppedAnim; public override void OnEnter() { //IL_0057: Unknown result type (might be due to invalid IL or missing references) ((Uppercut)this).OnEnter(); if (((EntityState)this).isAuthority) { EntityStateMachine.FindByCustomName(((EntityState)this).gameObject, "SkillOverride").SetNextState((EntityState)(object)new SkillOverride()); } base.overlapAttack.damage = ((BaseState)this).damageStat * MainPlugin.mercSpecialSlamDamage.Value; base.overlapAttack.damageType.damageSource = (DamageSource)8; } public override void FixedUpdate() { ((EntityState)this).skillLocator.special.rechargeStopwatch = 0f; if (((EntityState)this).fixedAge >= base.duration - Time.fixedDeltaTime) { if (!stoppedAnim) { stoppedAnim = true; ((EntityState)this).PlayAnimation("FullBody, Override", Uppercut.UppercutExitStateHash); } } else { ((Uppercut)this).FixedUpdate(); if (!base.isInHitPause) { ((EntityState)this).characterMotor.velocity.y += Uppercut.yVelocityCurve.Evaluate(((EntityState)this).fixedAge / base.duration) * 0.5f; } } } public override void OnExit() { } } internal class MercSpecialSlam : WhirlwindAir { private bool slam; public override void OnEnter() { //IL_005c: 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_0071: Unknown result type (might be due to invalid IL or missing references) //IL_007b: Unknown result type (might be due to invalid IL or missing references) //IL_0080: Unknown result type (might be due to invalid IL or missing references) ((WhirlwindBase)this).baseDuration = 0.5f; ((WhirlwindBase)this).baseDamageCoefficient = MainPlugin.mercSpecialSlamDamage.Value; ((WhirlwindBase)this).slashChildName = "WhirlwindAir"; ((WhirlwindBase)this).moveSpeedBonusCoefficient = 3f; ((WhirlwindBase)this).smallHopVelocity = 0f; ((WhirlwindBase)this).hitboxString = ((WhirlwindBase)this).slashChildName; ((WhirlwindBase)this).OnEnter(); ((WhirlwindBase)this).overlapAttack.damageType.damageSource = (DamageSource)8; ((WhirlwindBase)this).overlapAttack.forceVector = Vector3.down * Uppercut.upwardForceStrength * 2f; if (((BaseState)this).isGrounded) { slam = true; if (((EntityState)this).isAuthority) { ((EntityState)this).outer.SetNextStateToMain(); } } } public override void FixedUpdate() { //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_001e: Unknown result type (might be due to invalid IL or missing references) //IL_0028: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0032: Unknown result type (might be due to invalid IL or missing references) ((WhirlwindBase)this).FixedUpdate(); CharacterMotor characterMotor = ((EntityState)this).characterMotor; characterMotor.rootMotion += Vector3.down * 105f * Time.fixedDeltaTime; if (((BaseState)this).isGrounded) { slam = true; if (((EntityState)this).isAuthority) { ((EntityState)this).outer.SetNextStateToMain(); } } } public override void OnExit() { //IL_009f: 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_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_00b6: Unknown result type (might be due to invalid IL or missing references) //IL_00be: Unknown result type (might be due to invalid IL or missing references) //IL_00cf: Expected O, but got Unknown //IL_00e0: Unknown result type (might be due to invalid IL or missing references) //IL_00e7: Expected O, but got Unknown //IL_0129: Unknown result type (might be due to invalid IL or missing references) //IL_012e: Unknown result type (might be due to invalid IL or missing references) //IL_0136: Unknown result type (might be due to invalid IL or missing references) //IL_0155: Unknown result type (might be due to invalid IL or missing references) //IL_0157: 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_016b: Unknown result type (might be due to invalid IL or missing references) //IL_0170: Unknown result type (might be due to invalid IL or missing references) //IL_017d: Unknown result type (might be due to invalid IL or missing references) //IL_0182: Unknown result type (might be due to invalid IL or missing references) //IL_018f: Unknown result type (might be due to invalid IL or missing references) //IL_0196: Unknown result type (might be due to invalid IL or missing references) if (((EntityState)this).isAuthority) { EntityStateMachine val = EntityStateMachine.FindByCustomName(((EntityState)this).gameObject, "SkillOverride"); if (val.state is SkillOverride) { val.SetNextStateToMain(); } } if (slam) { string text = "GroundLight3"; ((EntityState)this).PlayCrossfade("Gesture, Additive", text, "GroundLight.playbackRate", 0.5f, 0.05f); ((EntityState)this).PlayCrossfade("Gesture, Override", text, "GroundLight.playbackRate", 0.5f, 0.05f); AkSoundEngine.PostEvent(GroundLight2.slash3Sound, ((EntityState)this).gameObject); Vector3 footPosition = ((EntityState)this).characterBody.footPosition; EffectManager.SpawnEffect(Prefabs.Load("RoR2/Base/Parent/ParentSlamEffect.prefab"), new EffectData { origin = footPosition, scale = GroundSlam.blastRadius }, false); if (((EntityState)this).isAuthority) { BlastAttack val2 = new BlastAttack(); val2.attacker = ((EntityState)this).gameObject; val2.baseDamage = ((BaseState)this).damageStat * MainPlugin.mercSpecialSlamImpactDamage.Value; val2.baseForce = 1400f; val2.crit = ((BaseState)this).RollCrit(); val2.damageType = DamageTypeCombo.op_Implicit((DamageType)32); val2.falloffModel = (FalloffModel)0; val2.procCoefficient = 1f; val2.radius = GroundSlam.blastRadius; val2.position = footPosition; val2.attackerFiltering = (AttackerFiltering)2; val2.impactEffect = EffectCatalog.FindEffectIndexFromPrefab(GroundSlam.blastImpactEffectPrefab); val2.teamIndex = ((EntityState)this).teamComponent.teamIndex; val2.damageType.damageSource = (DamageSource)8; val2.Fire(); } } ((WhirlwindAir)this).OnExit(); } 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 SkillOverride : BaseSkillState { private float duration = MainPlugin.mercSpecialRecastTime.Value; private EntityStateMachine machine; public override void OnEnter() { ((BaseState)this).OnEnter(); ((EntityState)this).skillLocator.special.SetSkillOverride((object)this, MainPlugin.mercSpecial, (SkillOverridePriority)4); machine = EntityStateMachine.FindByCustomName(((EntityState)this).gameObject, "Dash"); } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); if (((EntityState)this).isAuthority && ((EntityState)this).fixedAge >= duration) { ((EntityState)this).outer.SetNextStateToMain(); } } public override void OnExit() { if (((EntityState)this).isAuthority && machine.state is MercSpecialFollowUp) { machine.SetNextStateToMain(); } ((EntityState)this).skillLocator.special.UnsetSkillOverride((object)this, MainPlugin.mercSpecial, (SkillOverridePriority)4); ((EntityState)this).OnExit(); } 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)5; } } internal class MultDronePrimary : BaseSkillState { private BaseAI ai; private Transform muzzle; private GameObject lineObject; private LineRenderer line; private MultDroneBehaviour behaviour; private Transform target; private CharacterBody targetBody; private HealthComponent targetHealth; private CharacterBody ownerBody; public BullseyeSearch search = new BullseyeSearch(); private TemporaryOverlayInstance overlay; private float damageCoefficient = MainPlugin.multSecondaryDamage.Value; private GameObject tracerEffectPrefab = Prefabs.Load("RoR2/Base/Toolbot/TracerToolbotNails.prefab"); private GameObject hitEffectPrefab = Prefabs.Load("RoR2/Base/Common/VFX/OmniImpactVFX.prefab"); private float fireInterval; private float fireStopwatch = 1f; private bool enemy; private ItemIndex[] blacklist = (ItemIndex[])(object)new ItemIndex[17] { (ItemIndex)(int)Items.LunarPrimaryReplacement.itemIndex, (ItemIndex)(int)Items.LunarSecondaryReplacement.itemIndex, (ItemIndex)(int)Items.LunarUtilityReplacement.itemIndex, (ItemIndex)(int)Items.LunarSpecialReplacement.itemIndex, (ItemIndex)(int)Items.LunarSpecialReplacement.itemIndex, (ItemIndex)(int)Items.TreasureCache.itemIndex, (ItemIndex)(int)Items.ScrapGreen.itemIndex, (ItemIndex)(int)Items.ScrapRed.itemIndex, (ItemIndex)(int)Items.ScrapWhite.itemIndex, (ItemIndex)(int)Items.ScrapYellow.itemIndex, (ItemIndex)(int)Items.BeetleGland.itemIndex, (ItemIndex)(int)Items.RoboBallBuddy.itemIndex, (ItemIndex)(int)Items.TreasureCacheVoid.itemIndex, (ItemIndex)(int)Items.LunarSun.itemIndex, (ItemIndex)(int)Items.DroneWeapons.itemIndex, (ItemIndex)(int)Items.PhysicsProjectile.itemIndex, (ItemIndex)(int)Items.DronesDropDynamite.itemIndex }; private Dictionary addedItems = new Dictionary(); private Highlight highlight; public override void OnEnter() { //IL_00a0: Unknown result type (might be due to invalid IL or missing references) //IL_00a5: Unknown result type (might be due to invalid IL or missing references) //IL_00aa: Unknown result type (might be due to invalid IL or missing references) //IL_00b8: Unknown result type (might be due to invalid IL or missing references) //IL_00fa: Unknown result type (might be due to invalid IL or missing references) //IL_0142: Unknown result type (might be due to invalid IL or missing references) //IL_01a3: Unknown result type (might be due to invalid IL or missing references) //IL_01a8: Unknown result type (might be due to invalid IL or missing references) //IL_01c0: Unknown result type (might be due to invalid IL or missing references) //IL_02ce: Unknown result type (might be due to invalid IL or missing references) //IL_01f1: Unknown result type (might be due to invalid IL or missing references) //IL_01f6: Unknown result type (might be due to invalid IL or missing references) //IL_01fa: Unknown result type (might be due to invalid IL or missing references) //IL_034b: Unknown result type (might be due to invalid IL or missing references) //IL_03da: Unknown result type (might be due to invalid IL or missing references) //IL_03e1: Invalid comparison between Unknown and I4 //IL_0353: Unknown result type (might be due to invalid IL or missing references) //IL_035e: Unknown result type (might be due to invalid IL or missing references) //IL_0364: Invalid comparison between Unknown and I4 //IL_0368: Unknown result type (might be due to invalid IL or missing references) //IL_036e: Invalid comparison between Unknown and I4 //IL_0372: Unknown result type (might be due to invalid IL or missing references) //IL_0378: Invalid comparison between Unknown and I4 //IL_03d3: Unknown result type (might be due to invalid IL or missing references) //IL_03d6: Unknown result type (might be due to invalid IL or missing references) //IL_03d7: Unknown result type (might be due to invalid IL or missing references) //IL_03a4: Unknown result type (might be due to invalid IL or missing references) //IL_03b3: Unknown result type (might be due to invalid IL or missing references) //IL_03c8: Unknown result type (might be due to invalid IL or missing references) //IL_0380: Unknown result type (might be due to invalid IL or missing references) ((BaseState)this).OnEnter(); ai = ((Component)((EntityState)this).characterBody.master).GetComponent(); behaviour = ((Component)ai).GetComponent(); behaviour.tracker.endScanning = false; if (Object.op_Implicit((Object)(object)ai) && Object.op_Implicit((Object)(object)ai.currentEnemy.gameObject)) { targetHealth = ai.currentEnemy.healthComponent; targetBody = ai.currentEnemy.characterBody; TeamMask enemyTeams = TeamMask.GetEnemyTeams(((EntityState)this).teamComponent.teamIndex); enemy = ((TeamMask)(ref enemyTeams)).HasTeam(targetBody.teamComponent.teamIndex); target = ((Component)ai.currentEnemy.mainHurtBox).transform; ai.skillDriverUpdateTimer = 0.1f; ai.BeginSkillDriver(new SkillDriverEvaluation { dominantSkillDriver = behaviour.hover, target = ai.currentEnemy, aimTarget = ai.currentEnemy, separationSqrMagnitude = float.PositiveInfinity }); muzzle = ((BaseState)this).FindModelChild("LaserMuzzle"); lineObject = Object.Instantiate(Assets.Load("LaserLine")); line = lineObject.GetComponent(); highlight = ((Component)targetBody).gameObject.AddComponent(); highlight.CustomColor = line.startColor; highlight.isOn = true; highlight.highlightColor = (HighlightColor)3; List list = new List(); RendererInfo[] baseRendererInfos = ((Component)((Component)targetBody).GetComponent().modelTransform).GetComponent().baseRendererInfos; foreach (RendererInfo val in baseRendererInfos) { list.Add(val.renderer); } highlight.SetTargetRendererList(list); if (NetworkServer.active && enemy) { targetBody.AddBuff(Prefabs.multDroneDebuff); } CharacterModel component = ((Component)targetBody.modelLocator.modelTransform).GetComponent(); overlay = TemporaryOverlayManager.AddOverlay(((Component)component).gameObject); overlay.originalMaterial = Prefabs.droneTargetOverlay; overlay.animateShaderAlpha = false; overlay.destroyComponentOnEnd = false; overlay.AddToCharacterModel(component); } fireInterval = 0.2f / ((BaseState)this).attackSpeedStat; if (!Object.op_Implicit((Object)(object)targetBody) || !((Enum)targetBody.bodyFlags).HasFlag((Enum)(object)(BodyFlags)2) || !targetBody.baseNameToken.Contains("DRONE") || !NetworkServer.active) { return; } if (Object.op_Implicit((Object)(object)targetBody.inventory) && Object.op_Implicit((Object)(object)behaviour.ownerBody.inventory)) { for (ItemIndex val2 = (ItemIndex)0; (int)val2 < ItemCatalog.itemCount; val2 = (ItemIndex)(val2 + 1)) { ItemDef itemDef = ItemCatalog.GetItemDef(val2); if ((int)itemDef.tier != 6 && (int)itemDef.tier != 7 && (int)itemDef.tier != 8 && !blacklist.Contains(val2)) { int itemCountPermanent = behaviour.ownerBody.inventory.GetItemCountPermanent(val2); addedItems.Add(val2, itemCountPermanent); targetBody.inventory.GiveItemPermanent(val2, itemCountPermanent); } } } if (!enemy) { targetBody.AddBuff(Prefabs.multDroneRegenBuff); } } private void Fire() { //IL_004b: Unknown result type (might be due to invalid IL or missing references) //IL_0050: Unknown result type (might be due to invalid IL or missing references) //IL_0066: Unknown result type (might be due to invalid IL or missing references) //IL_006b: Unknown result type (might be due to invalid IL or missing references) //IL_0072: Unknown result type (might be due to invalid IL or missing references) //IL_0075: Unknown result type (might be due to invalid IL or missing references) //IL_0080: Unknown result type (might be due to invalid IL or missing references) //IL_0083: Unknown result type (might be due to invalid IL or missing references) //IL_0088: Unknown result type (might be due to invalid IL or missing references) //IL_008d: Unknown result type (might be due to invalid IL or missing references) //IL_00a0: Unknown result type (might be due to invalid IL or missing references) //IL_00a2: Unknown result type (might be due to invalid IL or missing references) //IL_00a7: Unknown result type (might be due to invalid IL or missing references) //IL_00a8: Unknown result type (might be due to invalid IL or missing references) //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_00b4: Unknown result type (might be due to invalid IL or missing references) //IL_00b9: Unknown result type (might be due to invalid IL or missing references) //IL_00c5: Unknown result type (might be due to invalid IL or missing references) //IL_00d0: Unknown result type (might be due to invalid IL or missing references) //IL_00d1: Unknown result type (might be due to invalid IL or missing references) //IL_00d6: Unknown result type (might be due to invalid IL or missing references) //IL_00db: Unknown result type (might be due to invalid IL or missing references) //IL_00e3: Unknown result type (might be due to invalid IL or missing references) //IL_00ea: Unknown result type (might be due to invalid IL or missing references) //IL_00f6: Unknown result type (might be due to invalid IL or missing references) //IL_0102: Unknown result type (might be due to invalid IL or missing references) //IL_010d: Unknown result type (might be due to invalid IL or missing references) //IL_0114: Unknown result type (might be due to invalid IL or missing references) //IL_011a: Unknown result type (might be due to invalid IL or missing references) //IL_0120: Unknown result type (might be due to invalid IL or missing references) //IL_012b: Unknown result type (might be due to invalid IL or missing references) //IL_0136: Unknown result type (might be due to invalid IL or missing references) //IL_013d: Unknown result type (might be due to invalid IL or missing references) //IL_013e: Unknown result type (might be due to invalid IL or missing references) //IL_0143: Unknown result type (might be due to invalid IL or missing references) //IL_0148: Unknown result type (might be due to invalid IL or missing references) //IL_014f: Unknown result type (might be due to invalid IL or missing references) //IL_015b: Unknown result type (might be due to invalid IL or missing references) //IL_0166: Unknown result type (might be due to invalid IL or missing references) //IL_0171: Unknown result type (might be due to invalid IL or missing references) if (enemy) { AkSoundEngine.PostEvent(BaseNailgunState.fireSoundString, ((EntityState)this).gameObject); EffectManager.SimpleMuzzleFlash(BaseNailgunState.muzzleFlashPrefab, ((EntityState)this).gameObject, BaseNailgunState.muzzleName, false); if (((EntityState)this).isAuthority) { Ray aimRay = ((BaseState)this).GetAimRay(); float num = RoR2Application.rng.RangeFloat(0.4425f, 1f); new BulletAttack { bulletCount = 1u, aimVector = ((Ray)(ref aimRay)).direction, origin = ((Ray)(ref aimRay)).origin, damage = ((BaseState)this).damageStat * damageCoefficient, damageColorIndex = (DamageColorIndex)0, damageType = DamageTypeCombo.GenericSecondary, falloffModel = (FalloffModel)0, maxDistance = BaseNailgunState.maxDistance, force = 0f, hitMask = CommonMasks.bullet, minSpread = 0f - num, maxSpread = num, isCrit = ((BaseState)this).RollCrit(), owner = ((EntityState)this).gameObject, muzzleName = "Muzzle", smartCollision = true, procChainMask = default(ProcChainMask), procCoefficient = 1f, radius = 0.08f, sniper = false, stopperMask = CommonMasks.bullet, weapon = null, tracerEffectPrefab = tracerEffectPrefab, spreadPitchScale = 1f, spreadYawScale = 1f, hitEffectPrefab = hitEffectPrefab }.Fire(); } } } public override void Update() { //IL_005c: Unknown result type (might be due to invalid IL or missing references) //IL_0074: Unknown result type (might be due to invalid IL or missing references) ((EntityState)this).Update(); if (Object.op_Implicit((Object)(object)lineObject) && Object.op_Implicit((Object)(object)target) && Object.op_Implicit((Object)(object)targetHealth) && targetHealth.alive && Object.op_Implicit((Object)(object)muzzle)) { line.SetPosition(1, muzzle.position); line.SetPosition(0, target.position); } } public override void FixedUpdate() { //IL_001b: 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) ((EntityState)this).FixedUpdate(); if (Object.op_Implicit((Object)(object)target) && Vector3.Distance(((EntityState)this).transform.position, target.position) <= BaseNailgunState.maxDistance + 1f) { fireStopwatch += Time.fixedDeltaTime; if (fireStopwatch >= fireInterval) { fireStopwatch = 0f; Fire(); } } if (Object.op_Implicit((Object)(object)ai) && Object.op_Implicit((Object)(object)target)) { ai.skillDriverUpdateTimer = 0.1f; } if ((((EntityState)this).isAuthority && !Object.op_Implicit((Object)(object)target)) || (Object.op_Implicit((Object)(object)targetHealth) && !targetHealth.alive) || (Object.op_Implicit((Object)(object)behaviour.tracker) && behaviour.tracker.endScanning)) { ((EntityState)this).outer.SetNextStateToMain(); } } public override void OnExit() { //IL_0074: Unknown result type (might be due to invalid IL or missing references) if (Object.op_Implicit((Object)(object)highlight)) { EntityState.Destroy((Object)(object)highlight); } if (NetworkServer.active && Object.op_Implicit((Object)(object)targetBody)) { if (addedItems.Count > 0) { foreach (KeyValuePair addedItem in addedItems) { targetBody.inventory.RemoveItemPermanent(addedItem.Key, addedItem.Value); } } if (enemy && targetBody.HasBuff(Prefabs.multDroneDebuff)) { targetBody.RemoveBuff(Prefabs.multDroneDebuff); } if (targetBody.HasBuff(Prefabs.multDroneRegenBuff)) { targetBody.RemoveBuff(Prefabs.multDroneRegenBuff); } } if (overlay != null) { overlay.Destroy(); } if (Object.op_Implicit((Object)(object)lineObject)) { EntityState.Destroy((Object)(object)lineObject); } if (Object.op_Implicit((Object)(object)behaviour) && Object.op_Implicit((Object)(object)behaviour.tracker)) { behaviour.tracker.exitSkill = true; if (behaviour.tracker.endScanning) { } behaviour.tracker.endScanning = false; } ((Component)((EntityState)this).characterBody.master).GetComponent().SetFollowState(); ((EntityState)this).OnExit(); } public override InterruptPriority GetMinimumInterruptPriority() { //IL_0003: Unknown result type (might be due to invalid IL or missing references) //IL_0006: Unknown result type (might be due to invalid IL or missing references) return (InterruptPriority)9; } } internal class MultSecondary : BaseSkillState { private MultTracker tracker; public override void OnEnter() { ((BaseState)this).OnEnter(); tracker = ((EntityState)this).GetComponent(); tracker.SelectTarget(); tracker.exitSkill = false; AkSoundEngine.PostEvent("Play_captain_shift_confirm", ((EntityState)this).gameObject); } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); if ((((EntityState)this).isAuthority && tracker.exitSkill) || (((EntityState)this).fixedAge >= 0.45f && ((ButtonState)(ref ((EntityState)this).inputBank.skill2)).justPressed)) { ((EntityState)this).outer.SetNextStateToMain(); } } public override void OnExit() { AkSoundEngine.PostEvent("Play_captain_shift_confirm", ((EntityState)this).gameObject); tracker.exitSkill = false; tracker.DisableScanning(); ((EntityState)this).OnExit(); } 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 MultUtility : BaseSkillState { private float duration = 0.35f; private float speedMult; private Animator animator; private uint ID; private AnimationCurve curve = AnimationCurve.EaseInOut(0f, 1f, 1f, 0f); private float speedCoefficient = MainPlugin.multUtilitySpeed.Value; private AimRequest request; private Vector3 forward; public override void OnEnter() { //IL_008b: 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_0092: Unknown result type (might be due to invalid IL or missing references) //IL_00e9: Unknown result type (might be due to invalid IL or missing references) //IL_00ee: Unknown result type (might be due to invalid IL or missing references) //IL_010d: Unknown result type (might be due to invalid IL or missing references) //IL_0100: 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) ((BaseState)this).OnEnter(); speedMult = Math.Max(1f, ((BaseState)this).moveSpeedStat / ((EntityState)this).characterBody.baseMoveSpeed); ((EntityState)this).PlayCrossfade("Body", "BoxModeEnter", 0.1f); ((EntityState)this).PlayCrossfade("Stance, Override", "PutAwayGun", 0.1f); animator = ((EntityState)this).GetModelAnimator(); animator.SetFloat("aimWeight", 0f); ((EntityState)this).modelLocator.normalizeToFloor = true; CharacterBody characterBody = ((EntityState)this).characterBody; characterBody.bodyFlags = (BodyFlags)(characterBody.bodyFlags | 1); ID = AkSoundEngine.PostEvent(ToolbotDash.startSoundString, ((EntityState)this).gameObject); AkSoundEngine.PostEvent(AimStunDrone.enterSoundString, ((EntityState)this).gameObject); request = ((EntityState)this).cameraTargetParams.RequestAimType((AimType)2); ((BaseState)this).SmallHop(((EntityState)this).characterMotor, 0f); forward = ((((EntityState)this).inputBank.moveVector == Vector3.zero) ? ((EntityState)this).characterDirection.forward : ((EntityState)this).inputBank.moveVector); if (NetworkServer.active) { ((EntityState)this).characterBody.AddBuff(Buffs.ArmorBoost); } if (((EntityState)this).isAuthority) { EntityStateMachine val = Array.Find(((EntityState)this).gameObject.GetComponents(), (EntityStateMachine x) => x.customName == "Weapon"); val.SetNextStateToMain(); } } public override void FixedUpdate() { //IL_0032: 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_0049: Unknown result type (might be due to invalid IL or missing references) //IL_004e: Unknown result type (might be due to invalid IL or missing references) //IL_0050: Unknown result type (might be due to invalid IL or missing references) //IL_005a: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Unknown result type (might be due to invalid IL or missing references) //IL_0064: Unknown result type (might be due to invalid IL or missing references) ((EntityState)this).FixedUpdate(); float num = curve.Evaluate(((EntityState)this).fixedAge / duration); float num2 = speedCoefficient * speedMult * num; Vector3 val = forward + Vector3.down; CharacterMotor characterMotor = ((EntityState)this).characterMotor; characterMotor.rootMotion += val * num2 * Time.fixedDeltaTime; if (((EntityState)this).fixedAge >= duration && ((EntityState)this).isAuthority) { ((EntityState)this).outer.SetNextStateToMain(); } } public override void OnExit() { //IL_005e: Unknown result type (might be due to invalid IL or missing references) //IL_0065: 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) if (NetworkServer.active) { ((EntityState)this).characterBody.RemoveBuff(Buffs.ArmorBoost); } if (Object.op_Implicit((Object)(object)((EntityState)this).cameraTargetParams)) { request.Dispose(); } AkSoundEngine.StopPlayingID(ID); AkSoundEngine.PostEvent(AimStunDrone.exitSoundString, ((EntityState)this).gameObject); CharacterBody characterBody = ((EntityState)this).characterBody; characterBody.bodyFlags = (BodyFlags)(characterBody.bodyFlags & -2); ((EntityState)this).modelLocator.normalizeToFloor = false; ((EntityState)this).PlayAnimation("Body", ToolbotDash.BoxModeExitStateHash); ((EntityState)this).PlayCrossfade("Stance, Override", ToolbotDash.EmptyStateHash, 0.1f); animator.SetFloat(ToolbotDash.aimWeightStateHash, 1f); ((EntityState)this).OnExit(); } 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 RailgunnerSpecial : BaseChargeSnipe { public override void OnEnter() { base.baseDuration = 2f; base.animationStateName = "ChargeSuper"; base.animationPlaybackRateParam = "Super.playbackRate"; base.animationLayerName = "Gesture, Override"; ((BaseChargeSnipe)this).OnEnter(); } public override EntityState InstantiateBackpackState() { return (EntityState)(object)new RailgunnerChargingSpecial(); } } internal class RailgunnerChargingSpecial : BaseCharging { public override void OnEnter() { ((BaseBackpack)this).mecanimBoolName = "isBackpackActive"; ((BaseBackpack)this).enterSoundString = "Play_railgunner_R_gun_swap"; base.baseDuration = 2f; base.animationStateName = "Charging"; base.animationPlaybackRateParam = "Backpack.playbackRate"; base.animationLayerName = "Backpack"; base.overlayChildLocatorEntry = "CrosshairExtras"; ((BaseBackpack)this).loopSoundDef = Prefabs.Load("RoR2/DLC1/Railgunner/lsdRailgunnerBackpackCharging.asset"); base.crosshairOverridePrefab = Prefabs.Load("RoR2/Base/UI/SimpleDotCrosshair.prefab"); base.overlayPrefab = Prefabs.railgunnerChargeUI; ((BaseCharging)this).OnEnter(); } public override EntityState InstantiateChargedState() { return (EntityState)(object)new RailgunnerChargedSpecial(); } } internal class RailgunnerChargedSpecial : BaseCharged { private float stopwatch; private float fireRate = MainPlugin.railgunnerSpecialLightningFireRate.Value; private float damageCoefficient = MainPlugin.railgunnerSpecialLightningDamage.Value; private SphereSearch search = new SphereSearch(); private TeamMask mask; public override void OnEnter() { //IL_0091: Unknown result type (might be due to invalid IL or missing references) //IL_0096: Unknown result type (might be due to invalid IL or missing references) //IL_00b7: 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) base.animationStateName = "Charged"; base.animationPlaybackRateParam = "Backpack.playbackRate"; base.animationLayerName = "Backpack"; base.overlayChildLocatorEntry = "CrosshairExtras"; ((BaseBackpack)this).mecanimBoolName = "isBackpackActive"; ((BaseBackpack)this).enterSoundString = "Play_railgunner_R_gun_ready"; base.duration = 3f; base.crosshairOverridePrefab = Prefabs.railgunnerChargeCrosshair; ((BaseBackpack)this).loopSoundDef = Prefabs.Load("RoR2/DLC1/Railgunner/lsdRailgunnerBackpackCharged.asset"); base.overlayPrefab = Prefabs.railgunnerChargeUIReady; base.primaryOverride = MainPlugin.railgunnerPrimaryOverride; ((BaseCharged)this).OnEnter(); search.mask = ((LayerIndex)(ref LayerIndex.entityPrecise)).mask; search.radius = MainPlugin.railgunnerSpecialLightningRadius.Value; mask = TeamMask.GetEnemyTeams(((EntityState)this).teamComponent.teamIndex); } public override void FixedUpdate() { //IL_0057: 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) //IL_006d: 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_009b: Expected O, but got Unknown //IL_00a3: Unknown result type (might be due to invalid IL or missing references) //IL_00a8: Unknown result type (might be due to invalid IL or missing references) //IL_00de: Unknown result type (might be due to invalid IL or missing references) //IL_00e3: Unknown result type (might be due to invalid IL or missing references) //IL_00fc: Unknown result type (might be due to invalid IL or missing references) //IL_011e: 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_012b: Unknown result type (might be due to invalid IL or missing references) //IL_0133: Unknown result type (might be due to invalid IL or missing references) ((BaseCharged)this).FixedUpdate(); if (!NetworkServer.active) { return; } stopwatch += Time.fixedDeltaTime; if (stopwatch >= fireRate) { stopwatch = 0f; search.origin = ((EntityState)this).transform.position; HurtBox[] hurtBoxes = search.RefreshCandidates().FilterCandidatesByHurtBoxTeam(mask).FilterCandidatesByDistinctHurtBoxEntities() .GetHurtBoxes(); HurtBox[] array = hurtBoxes; foreach (HurtBox target in array) { LightningOrb val = new LightningOrb(); ((Orb)val).origin = search.origin; val.damageValue = ((BaseState)this).damageStat * damageCoefficient; val.isCrit = ((BaseState)this).RollCrit(); val.bouncesRemaining = 0; val.teamIndex = ((EntityState)this).teamComponent.teamIndex; val.attacker = ((EntityState)this).gameObject; val.procChainMask = default(ProcChainMask); ((ProcChainMask)(ref val.procChainMask)).AddProc((ProcType)3); val.procCoefficient = 0.2f; val.damageType = DamageTypeCombo.GenericSpecial; val.lightningType = (LightningType)0; val.damageColorIndex = (DamageColorIndex)3; ((Orb)val).target = target; OrbManager.instance.AddOrb((Orb)(object)val); } } } public override EntityState InstantiateExpiredState() { return (EntityState)(object)new RailgunnerExpiredSpecial(); } } internal class RailgunnerExpiredSpecial : BaseExpired { public override void OnEnter() { base.animationStateName = "Expired"; base.animationPlaybackRateParam = "Backpack.playbackRate"; base.animationLayerName = "Backpack"; base.forceShieldRegen = true; ((BaseBackpack)this).enterSoundString = "Play_item_proc_shocknearby_stop"; base.duration = 0.5f; ((BaseExpired)this).OnEnter(); } public override EntityState InstantiateNextState() { return (EntityState)(object)new RailgunnerOnlineSpecial(); } } internal class RailgunnerOnlineSpecial : BaseOnline { public override void OnEnter() { base.cooldownParamName = "SpecialCooldown"; base.animationStateName = "Idle"; base.animationLayerName = "Backpack"; base.requiredSkillDef = MainPlugin.railgunnerSpecial; ((BaseOnline)this).OnEnter(); } } internal class RailgunnerSpecialFire : BaseFireSnipe { public override void OnEnter() { ((GenericBulletBaseState)this).muzzleFlashPrefab = Prefabs.Load("RoR2/Base/Common/VFX/Muzzleflash1.prefab"); ((GenericBulletBaseState)this).tracerEffectPrefab = Prefabs.railgunnerTracer; base.headshotSoundString = "Play_railgunner_m2_headshot"; ((GenericBulletBaseState)this).force = 4000f; ((GenericBulletBaseState)this).fireSoundString = "Play_railgunner_R_fire"; ((GenericBulletBaseState)this).damageCoefficient = 0f; ((GenericBulletBaseState)this).bulletRadius = 2f; ((GenericBulletBaseState)this).bulletCount = 1; ((GenericBulletBaseState)this).baseDuration = 1f; base.animationStateName = "FireSuper"; base.animationPlaybackRateParam = "Super.playbackRate"; base.animationLayerName = "Gesture, Override"; ((GenericBulletBaseState)this).recoilAmplitudeY = 6f; ((GenericBulletBaseState)this).recoilAmplitudeX = 1f; ((GenericBulletBaseState)this).procCoefficient = 3f; base.piercingDamageCoefficientPerTarget = 1f; ((GenericBulletBaseState)this).muzzleName = "MuzzleRight"; ((GenericBulletBaseState)this).maxDistance = 9999f; base.isPiercing = false; ((GenericBulletBaseState)this).useSmartCollision = true; base.selfKnockbackForce = 3000f; ((BaseFireSnipe)this).OnEnter(); } public override void ModifyBullet(BulletAttack bulletAttack) { //IL_000b: Unknown result type (might be due to invalid IL or missing references) //IL_0010: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_001a: Unknown result type (might be due to invalid IL or missing references) //IL_003d: Unknown result type (might be due to invalid IL or missing references) //IL_0047: Expected O, but got Unknown ((BaseFireSnipe)this).ModifyBullet(bulletAttack); bulletAttack.damageType |= DamageTypeCombo.GenericSpecial; bulletAttack.damage = 0f; bulletAttack.procCoefficient = 0f; bulletAttack.hitCallback = (HitCallback)delegate(BulletAttack _bulletAttack, ref BulletHit info) { //IL_0003: 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_0025: Unknown result type (might be due to invalid IL or missing references) //IL_002a: 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_0038: Unknown result type (might be due to invalid IL or missing references) //IL_003d: 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_0076: 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_007c: Unknown result type (might be due to invalid IL or missing references) //IL_0081: Unknown result type (might be due to invalid IL or missing references) //IL_0083: Unknown result type (might be due to invalid IL or missing references) //IL_0088: Unknown result type (might be due to invalid IL or missing references) //IL_008b: Unknown result type (might be due to invalid IL or missing references) //IL_0090: Unknown result type (might be due to invalid IL or missing references) //IL_0095: Unknown result type (might be due to invalid IL or missing references) //IL_00a0: 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_00ae: Unknown result type (might be due to invalid IL or missing references) //IL_00b3: Unknown result type (might be due to invalid IL or missing references) //IL_00b8: Unknown result type (might be due to invalid IL or missing references) //IL_00c6: Unknown result type (might be due to invalid IL or missing references) //IL_00cc: Expected O, but got Unknown //IL_00cd: 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_00da: Unknown result type (might be due to invalid IL or missing references) //IL_00df: Unknown result type (might be due to invalid IL or missing references) //IL_00e4: Unknown result type (might be due to invalid IL or missing references) //IL_00e8: Unknown result type (might be due to invalid IL or missing references) //IL_00ee: Unknown result type (might be due to invalid IL or missing references) //IL_00f5: 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_0128: Unknown result type (might be due to invalid IL or missing references) //IL_0183: Unknown result type (might be due to invalid IL or missing references) //IL_0188: Unknown result type (might be due to invalid IL or missing references) //IL_018b: Unknown result type (might be due to invalid IL or missing references) //IL_0196: Unknown result type (might be due to invalid IL or missing references) //IL_01a3: Expected O, but got Unknown //IL_014f: Unknown result type (might be due to invalid IL or missing references) //IL_0154: Unknown result type (might be due to invalid IL or missing references) //IL_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) if (info.point != Vector3.zero) { float value = MainPlugin.railgunnerSpecialRadius.Value; BlastAttack val = new BlastAttack { attacker = ((EntityState)this).gameObject, attackerFiltering = (AttackerFiltering)2, baseDamage = ((BaseState)this).damageStat * MainPlugin.railgunnerSpecialDamage.Value * (info.isSniperHit ? 1.5f : 1f), crit = ((BaseState)this).RollCrit(), damageType = DamageTypeCombo.GenericSpecial, falloffModel = (FalloffModel)0, position = info.point, procCoefficient = 1f, radius = value, teamIndex = ((EntityState)this).teamComponent.teamIndex, damageColorIndex = (DamageColorIndex)(info.isSniperHit ? 5 : 0) }; Vector3 origin = _bulletAttack.origin; Vector3 val2 = info.point - _bulletAttack.origin; if (Physics.Raycast(origin, ((Vector3)(ref val2)).normalized, Vector3.Distance(_bulletAttack.origin, info.point), 536870912)) { val.baseDamage *= MainPlugin.railgunnerUtilityDamageMult.Value; val.damageColorIndex = (DamageColorIndex)12; } val.Fire(); if (info.isSniperHit) { EffectManager.SimpleEffect(Prefabs.Load("RoR2/Base/Common/VFX/CritsparkHeavy.prefab"), info.point, Quaternion.identity, true); EffectManager.SimpleEffect(Prefabs.Load("RoR2/DLC1/Railgunner/ImpactRailgun.prefab"), info.point, Quaternion.identity, true); } EffectManager.SpawnEffect(Prefabs.railgunnerNova, new EffectData { origin = info.point, scale = value }, true); } return BulletAttack.defaultHitCallback.Invoke(_bulletAttack, ref info); }; } public override EntityState InstantiateBackpackState() { //IL_0001: Unknown result type (might be due to invalid IL or missing references) //IL_0007: Expected O, but got Unknown return (EntityState)new Offline(); } } internal class RailgunnerUtility : BaseFireMine { public override void OnEnter() { base.baseCrossfadeDuration = 0.05f; base.animationStateName = "ThrowMine"; base.animationPlaybackRateParam = "ThrowMine.playbackRate"; base.animationLayerName = "Gesture, Override"; base.muzzleName = "MuzzlePistol"; base.enterSoundString = "Play_railgunner_shift_throw"; base.baseDuration = 0.23f; base.projectilePrefab = Prefabs.railgunnerProjectile; ((BaseFireMine)this).OnEnter(); } } internal class Genkidama : Meditate { public override void OnEnter() { //IL_003e: 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_017a: Unknown result type (might be due to invalid IL or missing references) //IL_017f: Unknown result type (might be due to invalid IL or missing references) //IL_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_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_019c: Unknown result type (might be due to invalid IL or missing references) //IL_01a1: 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) base.damageCoefficient = 0f; base.crosshairOverridePrefab = Prefabs.Load("RoR2/Base/UI/SimpleDotCrosshair.prefab"); base.blastRadius = -1f; base.blastProcCoefficient = 0f; base.blastForce = 0f; base.blastBonusForce = Vector3.zero; base.animDuration = 0.25f; base.percentPerGate = 1f; base.overShieldPercent = 0.2f; base.lotusPrefab = Prefabs.Load("RoR2/DLC2/Seeker/MeditateLotusVFX.prefab"); base.inputFailSoundString = "Play_seeker_skill4_combo_wrong"; base.inputCorrectSoundString = "Play_seeker_skill4_combo_correct"; base.healingOverShield = -1f; base.healingExplosionAmount = -1f; base.explosionHealingMod = -1f; base.failureCooldownPenalty = 5f; base.duration = 5f; base.wrapUpDuration = 0.35f; base.timeoutSoundString = "Play_seeker_skill4_timeout"; base.timePenalty = 1f; base.successSoundString = "Play_seeker_skill4_win"; base.successEffectPrefab = Prefabs.Load("RoR2/DLC2/Seeker/Meditate7thGateVFX.prefab"); base.chakra7SuccessEffectPrefab = base.successEffectPrefab; base.stopSoundString = "Stop_seeker_skill4_start"; base.startingOverShieldPercentage = 0.25f; base.startSoundString = "Play_seeker_skill4_start"; base.smallHopVelocity = 9f; base.scopeOverlayPrefab = Prefabs.Load("RoR2/DLC2/Seeker/SeekerMeditateUI.prefab"); ((Meditate)this).OnEnter(); base.explosionHealingMod = -1f; if (((EntityState)this).isAuthority) { ProjectileManager instance = ProjectileManager.instance; GameObject seekerGenkidamaProjectile = Prefabs.seekerGenkidamaProjectile; Vector3 val = ((EntityState)this).transform.position + Vector3.up * 4f; Ray aimRay = ((BaseState)this).GetAimRay(); instance.FireProjectile(seekerGenkidamaProjectile, val, Quaternion.LookRotation(((Ray)(ref aimRay)).direction), ((EntityState)this).gameObject, (MainPlugin.genkidamaBaseDamage.Value + MainPlugin.genkidamaAddDamage.Value) * ((BaseState)this).damageStat, (float)(400 * base.seekerController.meditationInputStep), ((BaseState)this).RollCrit(), (DamageColorIndex)0, (GameObject)null, -1f, (DamageTypeCombo?)DamageTypeCombo.GenericSpecial); } ((EntityState)this).characterBody.master.seekerRevivedOnce = true; } public override void OnExit() { if (!((EntityState)this).isAuthority || base.meditationSuccess) { } ((Meditate)this).OnExit(); } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); if (((EntityState)this).isAuthority && ((ButtonState)(ref ((EntityState)this).inputBank.skill1)).justReleased) { ((EntityState)this).outer.SetNextStateToMain(); } } } internal class SeekerPrimary : BaseSkillState { private float duration = 0.65f; private float earlyExitDuration = 0.9f; private float damageCoefficient = MainPlugin.seekerPrimaryDamage.Value; private float chakraAddDamage = MainPlugin.seekerPrimaryAddDamage.Value; public int attackIndex = 1; private Transform muzzleTransform; private bool hasFired; private bool canOverride = true; private bool overridden; private bool cast; private ReplaceableSkill skill; public override void OnSerialize(NetworkWriter writer) { ((BaseSkillState)this).OnSerialize(writer); writer.Write(attackIndex); } public override void OnDeserialize(NetworkReader reader) { ((BaseSkillState)this).OnDeserialize(reader); attackIndex = reader.ReadInt32(); } public override void OnEnter() { ((BaseState)this).OnEnter(); ((BaseState)this).StartAimMode(2f, false); skill = ((EntityState)this).GetComponent(); duration /= ((BaseState)this).attackSpeedStat; earlyExitDuration = duration * earlyExitDuration; chakraAddDamage *= ((EntityState)this).characterBody.GetBuffCount(Buffs.ChakraBuff); if (attackIndex > 2) { attackIndex = 1; } Animator modelAnimator = ((EntityState)this).GetModelAnimator(); bool @bool = modelAnimator.GetBool("isMoving"); bool bool2 = modelAnimator.GetBool("isGrounded"); string text = ((attackIndex == 1) ? "Cast1Right" : "Cast1Left"); if (!@bool && bool2) { ((EntityState)this).PlayCrossfade("FullBody, Override", text, "FireGauntlet.playbackRate", duration, 0.025f); } else { ((EntityState)this).PlayCrossfade("Gesture, Additive", text, "FireGauntlet.playbackRate", duration, 0.025f); ((EntityState)this).PlayCrossfade("Gesture, Override", text, "FireGauntlet.playbackRate", duration, 0.025f); } muzzleTransform = ((BaseState)this).FindModelChild((attackIndex == 1) ? "MuzzleRight" : "MuzzleLeft"); } private void Fire() { //IL_0057: 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) //IL_00c3: 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_00cf: Unknown result type (might be due to invalid IL or missing references) AkSoundEngine.PostEvent("Play_seeker_skill1_fire", ((EntityState)this).gameObject); ((EntityState)this).characterBody.AddSpreadBloom(0.8f); ((BaseState)this).AddRecoil(-0.1f * SpiritPunch.recoilAmplitude, 0.1f * SpiritPunch.recoilAmplitude, -1f * SpiritPunch.recoilAmplitude, 1f * SpiritPunch.recoilAmplitude); Ray aimRay = ((BaseState)this).GetAimRay(); string text = ((attackIndex == 1) ? "MuzzleRight" : "MuzzleLeft"); EffectManager.SimpleMuzzleFlash(Prefabs.Load("RoR2/DLC2/Seeker/SpiritPunchMuzzleFlashVFX.prefab"), ((EntityState)this).gameObject, text, false); TrajectoryAimAssist.ApplyTrajectoryAimAssist(ref aimRay, Prefabs.Load("RoR2/Base/Lemurian/Fireball.prefab"), ((EntityState)this).gameObject, 1f); if (((EntityState)this).isAuthority) { ProjectileManager.instance.FireProjectile(Prefabs.fistProjectile, muzzleTransform.position, Quaternion.LookRotation(((Ray)(ref aimRay)).direction), ((EntityState)this).gameObject, ((BaseState)this).damageStat * (damageCoefficient + chakraAddDamage), 500f, ((BaseState)this).RollCrit(), (DamageColorIndex)0, (GameObject)null, 70f + ((BaseState)this).attackSpeedStat * 2f, (DamageTypeCombo?)null); } } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); if (!hasFired && ((EntityState)this).fixedAge >= duration * 0.75f) { hasFired = true; Fire(); } if (!((EntityState)this).isAuthority) { return; } if (canOverride && skill.active) { if (!overridden) { overridden = true; skill.ReplaceSkill(); } if (overridden && !((EntityState)this).inputBank.skill1.down) { canOverride = false; } } if (overridden && ((ButtonState)(ref ((EntityState)this).inputBank.skill2)).justPressed) { cast = true; ((EntityState)this).outer.SetNextState((EntityState)(object)new SeekerSecondary()); } else if (((EntityState)this).inputBank.skill1.down && ((EntityState)this).fixedAge >= earlyExitDuration) { ((EntityState)this).outer.SetNextState((EntityState)(object)new SeekerPrimary { attackIndex = attackIndex + 1 }); } else if (((EntityState)this).fixedAge >= duration) { ((EntityState)this).outer.SetNextStateToMain(); } } public override void OnExit() { if (((EntityState)this).isAuthority && overridden && !cast) { skill.ClearOverride(); } ((EntityState)this).OnExit(); } 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)5; } } internal class SeekerSecondary : BaseSkillState { private GameObject areaIndicator; private bool valid; public override void OnEnter() { ((BaseState)this).OnEnter(); ((BaseState)this).StartAimMode(2f, false); areaIndicator = Object.Instantiate(Prefabs.palmAreaIndicator); Util.PlaySound(UnseenHand.prepFistSoundString, ((EntityState)this).gameObject); Util.PlaySound(UnseenHand.startTargetingLoopSoundString, ((EntityState)this).gameObject); } public override void Update() { //IL_001c: 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_002f: Unknown result type (might be due to invalid IL or missing references) //IL_0034: 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_004c: Unknown result type (might be due to invalid IL or missing references) //IL_007a: Unknown result type (might be due to invalid IL or missing references) ((EntityState)this).Update(); if (Object.op_Implicit((Object)(object)areaIndicator)) { Ray aimRay = ((BaseState)this).GetAimRay(); areaIndicator.transform.forward = Utils.GetForwardDirection(((Ray)(ref aimRay)).direction); RaycastHit val = default(RaycastHit); if (Physics.Raycast(aimRay, ref val, 9999f, LayerMask.op_Implicit(((LayerIndex)(ref LayerIndex.world)).mask))) { areaIndicator.SetActive(true); areaIndicator.transform.position = ((RaycastHit)(ref val)).point; valid = true; } else { valid = false; areaIndicator.SetActive(false); } } } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); ((BaseState)this).StartAimMode(1f, false); if (((EntityState)this).isAuthority && !((EntityState)this).inputBank.skill2.down) { if (valid) { ((EntityState)this).outer.SetNextState((EntityState)(object)new SeekerSecondaryFire()); } else { ((EntityState)this).outer.SetNextStateToMain(); } } } public override void OnExit() { //IL_0084: Unknown result type (might be due to invalid IL or missing references) //IL_008e: Unknown result type (might be due to invalid IL or missing references) //IL_0093: Unknown result type (might be due to invalid IL or missing references) //IL_00a0: Unknown result type (might be due to invalid IL or missing references) //IL_00a5: Unknown result type (might be due to invalid IL or missing references) //IL_00a7: Unknown result type (might be due to invalid IL or missing references) //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_010d: Unknown result type (might be due to invalid IL or missing references) //IL_0112: Unknown result type (might be due to invalid IL or missing references) //IL_0114: Unknown result type (might be due to invalid IL or missing references) //IL_011a: Unknown result type (might be due to invalid IL or missing references) //IL_011f: Unknown result type (might be due to invalid IL or missing references) //IL_0172: 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_0179: 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) if (valid) { ProjectileSimple component = Prefabs.palmProjectile.GetComponent(); component.lifetime = 0.4f / ((BaseState)this).attackSpeedStat; component.desiredForwardSpeed = 27f * ((BaseState)this).attackSpeedStat; Prefabs.palmExplosionProjectile.GetComponent().lifetime = 0.4f / ((BaseState)this).attackSpeedStat; if (((EntityState)this).isAuthority && valid) { Transform child = areaIndicator.transform.GetChild(0); Vector3 val = Vector3.up * 2.5f; ProjectileManager.instance.FireProjectile(Prefabs.palmProjectile, child.position + val, Quaternion.LookRotation(child.forward), ((EntityState)this).gameObject, ((BaseState)this).damageStat * MainPlugin.seekerSecondaryDamage.Value, 2500f, ((BaseState)this).RollCrit(), (DamageColorIndex)0, (GameObject)null, -1f, (DamageTypeCombo?)null); child = areaIndicator.transform.GetChild(1); ProjectileManager.instance.FireProjectile(Prefabs.palmProjectile, child.position + val, Quaternion.LookRotation(child.forward), ((EntityState)this).gameObject, ((BaseState)this).damageStat * MainPlugin.seekerSecondaryDamage.Value, 2500f, ((BaseState)this).RollCrit(), (DamageColorIndex)0, (GameObject)null, -1f, (DamageTypeCombo?)null); ProjectileManager.instance.FireProjectile(Prefabs.palmExplosionProjectile, areaIndicator.transform.position + val, Quaternion.LookRotation(areaIndicator.transform.forward), ((EntityState)this).gameObject, ((BaseState)this).damageStat * MainPlugin.seekerSecondaryExplosionDamage.Value, 500f, ((BaseState)this).RollCrit(), (DamageColorIndex)0, (GameObject)null, -1f, (DamageTypeCombo?)null); } } else { ((EntityState)this).skillLocator.secondary.UnsetSkillOverride((object)((EntityState)this).gameObject, MainPlugin.seekerSecondary, (SkillOverridePriority)4); } if (Object.op_Implicit((Object)(object)areaIndicator)) { EntityState.Destroy((Object)(object)areaIndicator); } ((EntityState)this).OnExit(); } public override InterruptPriority GetMinimumInterruptPriority() { //IL_0003: Unknown result type (might be due to invalid IL or missing references) //IL_0006: Unknown result type (might be due to invalid IL or missing references) return (InterruptPriority)9; } } internal class SeekerSecondaryFire : BaseSkillState { private float duration = 0.4f; public override void OnEnter() { ((BaseState)this).OnEnter(); duration /= ((BaseState)this).attackSpeedStat; Animator modelAnimator = ((EntityState)this).GetModelAnimator(); bool @bool = modelAnimator.GetBool("isMoving"); bool bool2 = modelAnimator.GetBool("isGrounded"); string text = "SpiritPunchFinisher"; if (!@bool && bool2) { ((EntityState)this).PlayCrossfade("FullBody, Override", text, "FireGauntlet.playbackRate", duration, 0.025f); } else { ((EntityState)this).PlayCrossfade("Gesture, Additive", text, "FireGauntlet.playbackRate", duration, 0.025f); ((EntityState)this).PlayCrossfade("Gesture, Override", text, "FireGauntlet.playbackRate", duration, 0.025f); } Util.PlaySound(UnseenHand.fireSoundString, ((EntityState)this).gameObject); Util.PlaySound(UnseenHand.endFistSoundString, ((EntityState)this).gameObject); Util.PlaySound(UnseenHand.stopTargetingLoopSoundString, ((EntityState)this).gameObject); } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); if (((EntityState)this).isAuthority && ((EntityState)this).fixedAge >= duration) { ((EntityState)this).outer.SetNextStateToMain(); } } public override void OnExit() { ReplaceableSkill component = ((EntityState)this).GetComponent(); component.active = false; component.ClearOverride(); ((EntityState)this).OnExit(); } public override InterruptPriority GetMinimumInterruptPriority() { //IL_0003: Unknown result type (might be due to invalid IL or missing references) //IL_0006: Unknown result type (might be due to invalid IL or missing references) return (InterruptPriority)9; } } internal class TempState : BaseSkillState { private float duration; private float baseDuration = 0.35f; public override void OnEnter() { ((BaseState)this).OnEnter(); duration = baseDuration / ((BaseState)this).attackSpeedStat; } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); if (((EntityState)this).fixedAge >= duration && ((EntityState)this).isAuthority) { ((EntityState)this).outer.SetNextStateToMain(); } } public override void OnExit() { ((EntityState)this).OnExit(); } 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 BeamCorrupted : BaseSkillState { private float duration = 0.85f; private float startup = 0.5f; private bool hasFired; private GameObject chargeEffectInstance; public override void OnEnter() { //IL_008c: Unknown result type (might be due to invalid IL or missing references) //IL_0097: Unknown result type (might be due to invalid IL or missing references) ((BaseState)this).OnEnter(); startup /= ((BaseState)this).attackSpeedStat; duration /= ((BaseState)this).attackSpeedStat; ((BaseState)this).StartAimMode(1f, false); ((EntityState)this).PlayAnimation("LeftArm, Override", "CrushCorruption", "CrushCorruption.playbackRate", startup, 0f); Util.PlayAttackSpeedSound("Play_voidRaid_snipe_chargeUp", ((EntityState)this).gameObject, ((BaseState)this).attackSpeedStat * 2.3f); Transform val = ((BaseState)this).FindModelChild("MuzzleHandBeam"); chargeEffectInstance = Object.Instantiate(Prefabs.viendBeamCharge, val.position, ((EntityState)this).transform.rotation); chargeEffectInstance.transform.parent = val; ScaleParticleSystemDuration component = chargeEffectInstance.GetComponent(); ObjectScaleCurve component2 = chargeEffectInstance.GetComponent(); component.newDuration = startup; component2.timeMax = startup; } private void Fire() { //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_0030: Unknown result type (might be due to invalid IL or missing references) //IL_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_0039: Unknown result type (might be due to invalid IL or missing references) //IL_003e: Unknown result type (might be due to invalid IL or missing references) //IL_0043: Unknown result type (might be due to invalid IL or missing references) //IL_0055: Unknown result type (might be due to invalid IL or missing references) //IL_005c: Unknown result type (might be due to invalid IL or missing references) //IL_005e: Unknown result type (might be due to invalid IL or missing references) //IL_0063: Unknown result type (might be due to invalid IL or missing references) //IL_006a: Unknown result type (might be due to invalid IL or missing references) //IL_0075: Unknown result type (might be due to invalid IL or missing references) //IL_0078: Unknown result type (might be due to invalid IL or missing references) //IL_007d: Unknown result type (might be due to invalid IL or missing references) //IL_0082: Unknown result type (might be due to invalid IL or missing references) //IL_0083: Unknown result type (might be due to invalid IL or missing references) //IL_0088: Unknown result type (might be due to invalid IL or missing references) //IL_008e: Expected O, but got Unknown //IL_009a: Unknown result type (might be due to invalid IL or missing references) //IL_0258: Unknown result type (might be due to invalid IL or missing references) //IL_025d: Unknown result type (might be due to invalid IL or missing references) //IL_0260: Unknown result type (might be due to invalid IL or missing references) //IL_0265: Unknown result type (might be due to invalid IL or missing references) //IL_026a: Unknown result type (might be due to invalid IL or missing references) //IL_0272: Unknown result type (might be due to invalid IL or missing references) //IL_027e: Expected O, but got Unknown //IL_0130: Unknown result type (might be due to invalid IL or missing references) //IL_013b: Unknown result type (might be due to invalid IL or missing references) //IL_0145: Unknown result type (might be due to invalid IL or missing references) //IL_014a: Unknown result type (might be due to invalid IL or missing references) //IL_014f: Unknown result type (might be due to invalid IL or missing references) //IL_0159: Unknown result type (might be due to invalid IL or missing references) //IL_015e: 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_01a1: Unknown result type (might be due to invalid IL or missing references) //IL_01a6: Unknown result type (might be due to invalid IL or missing references) //IL_01ab: Unknown result type (might be due to invalid IL or missing references) //IL_01b7: Unknown result type (might be due to invalid IL or missing references) //IL_01c3: Unknown result type (might be due to invalid IL or missing references) //IL_01da: 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_01e0: 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_01f2: Expected O, but got Unknown hasFired = true; ((EntityState)this).PlayAnimation("LeftArm, Override", "FireCorruptHandBeam"); AkSoundEngine.PostEvent("Play_voidRaid_snipe_shoot", ((EntityState)this).gameObject); Ray aimRay = ((BaseState)this).GetAimRay(); BullseyeSearch val = new BullseyeSearch { searchOrigin = ((Ray)(ref aimRay)).origin, maxAngleFilter = ((EntityState)this).GetComponent().angle, filterByLoS = true, sortMode = (SortMode)3, filterByDistinctEntity = true, maxDistanceFilter = 150f, searchDirection = ((Ray)(ref aimRay)).direction, teamMaskFilter = TeamMask.all }; ((TeamMask)(ref val.teamMaskFilter)).RemoveTeam(((EntityState)this).teamComponent.teamIndex); val.RefreshCandidates(); foreach (HurtBox result in val.GetResults()) { if (Object.op_Implicit((Object)(object)result.healthComponent) && Object.op_Implicit((Object)(object)result.healthComponent.body) && !result.healthComponent.body.isBoss && !result.healthComponent.body.isChampion) { TeleportHelper.TeleportGameObject(((Component)result.healthComponent).gameObject, ((EntityState)this).transform.position + ((EntityState)this).characterDirection.forward * 5f + Vector3.up * 2f); if (NetworkServer.active) { result.healthComponent.body.AddTimedBuff(Buffs.Nullified, 3f); DamageInfo val2 = new DamageInfo { position = ((Component)result).transform.position, attacker = ((EntityState)this).gameObject, crit = ((BaseState)this).RollCrit(), damage = ((BaseState)this).damageStat * MainPlugin.beamDMGCorrupted.Value, damageType = DamageTypeCombo.GenericSecondary, procCoefficient = 1f }; result.healthComponent.TakeDamage(val2); GlobalEventManager.instance.OnHitEnemy(val2, ((Component)result.healthComponent).gameObject); GlobalEventManager.instance.OnHitAll(val2, ((Component)result.healthComponent).gameObject); } } } ChildLocator modelChildLocator = ((EntityState)this).GetModelChildLocator(); EffectData val3 = new EffectData { start = ((Ray)(ref aimRay)).origin, origin = ((Ray)(ref aimRay)).GetPoint(150f) }; val3.SetChildLocatorTransformReference(((Component)modelChildLocator).gameObject, modelChildLocator.FindChildIndex("MuzzleHandBeam")); EffectManager.SpawnEffect(Prefabs.viendBeamTracer, val3, false); if (Object.op_Implicit((Object)(object)chargeEffectInstance)) { EntityState.Destroy((Object)(object)chargeEffectInstance); } } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); ((BaseState)this).StartAimMode(1f, false); if (((EntityState)this).fixedAge >= startup && !hasFired) { Fire(); } if (((EntityState)this).isAuthority && ((EntityState)this).fixedAge >= duration) { ((EntityState)this).outer.SetNextStateToMain(); } } public override void OnExit() { if (!hasFired) { Fire(); } ((EntityState)this).PlayAnimation("LeftArm, Override", "ExitHandBeam"); ((EntityState)this).OnExit(); } 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 Beam : BaseSkillState { private float duration = MainPlugin.beamDuration.Value; private float stopwatch = 1f; private GameObject beam; private Transform startPoint; private Transform endPoint; private Transform muzzle; public override void OnEnter() { //IL_0054: 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) ((BaseState)this).OnEnter(); ((BaseState)this).StartAimMode(1f, false); ((EntityState)this).PlayAnimation("LeftArm, Override", "FireCorruptHandBeam"); AkSoundEngine.PostEvent("Play_voidman_m1_corrupted_start", ((EntityState)this).gameObject); muzzle = ((BaseState)this).FindModelChild("MuzzleHandBeam"); beam = Object.Instantiate(Prefabs.viendContinuousBeam, muzzle.position, Quaternion.identity); startPoint = beam.transform.GetChild(0); endPoint = beam.GetComponent().FindChild("LaserEnd"); SetBeamPos(); } public override void Update() { ((EntityState)this).Update(); SetBeamPos(); } private void SetBeamPos() { //IL_0025: 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_003d: Unknown result type (might be due to invalid IL or missing references) //IL_0046: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_0068: Unknown result type (might be due to invalid IL or missing references) //IL_00a7: Unknown result type (might be due to invalid IL or missing references) //IL_00ae: Unknown result type (might be due to invalid IL or missing references) //IL_00b8: Unknown result type (might be due to invalid IL or missing references) //IL_00bd: Unknown result type (might be due to invalid IL or missing references) //IL_0087: Unknown result type (might be due to invalid IL or missing references) if (Object.op_Implicit((Object)(object)beam)) { startPoint.position = muzzle.position; Ray aimRay = ((BaseState)this).GetAimRay(); float num = 0f; RaycastHit val = default(RaycastHit); if (Physics.Raycast(CameraRigController.ModifyAimRayIfApplicable(aimRay, ((EntityState)this).gameObject, ref num), ref val, 120f + num, LayerMask.op_Implicit(((LayerIndex)(ref LayerIndex.world)).mask) | LayerMask.op_Implicit(((LayerIndex)(ref LayerIndex.entityPrecise)).mask))) { endPoint.position = ((RaycastHit)(ref val)).point; } else { endPoint.position = ((Component)muzzle).transform.position + ((Ray)(ref aimRay)).direction * 120f; } } } public override void FixedUpdate() { //IL_0065: Unknown result type (might be due to invalid IL or missing references) //IL_006a: Unknown result type (might be due to invalid IL or missing references) //IL_006b: Unknown result type (might be due to invalid IL or missing references) //IL_0070: Unknown result type (might be due to invalid IL or missing references) //IL_0077: Unknown result type (might be due to invalid IL or missing references) //IL_007a: Unknown result type (might be due to invalid IL or missing references) //IL_0085: Unknown result type (might be due to invalid IL or missing references) //IL_0088: Unknown result type (might be due to invalid IL or missing references) //IL_008d: Unknown result type (might be due to invalid IL or missing references) //IL_0092: Unknown result type (might be due to invalid IL or missing references) //IL_00a9: Unknown result type (might be due to invalid IL or missing references) //IL_00ab: Unknown result type (might be due to invalid IL or missing references) //IL_00b0: Unknown result type (might be due to invalid IL or missing references) //IL_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_00bb: Unknown result type (might be due to invalid IL or missing references) //IL_00bd: Unknown result type (might be due to invalid IL or missing references) //IL_00c2: Unknown result type (might be due to invalid IL or missing references) //IL_00ce: Unknown result type (might be due to invalid IL or missing references) //IL_00de: Unknown result type (might be due to invalid IL or missing references) //IL_00df: Unknown result type (might be due to invalid IL or missing references) //IL_00e4: Unknown result type (might be due to invalid IL or missing references) //IL_00e9: Unknown result type (might be due to invalid IL or missing references) //IL_00f4: Unknown result type (might be due to invalid IL or missing references) //IL_00ff: Unknown result type (might be due to invalid IL or missing references) //IL_010b: Unknown result type (might be due to invalid IL or missing references) //IL_0117: Unknown result type (might be due to invalid IL or missing references) //IL_0122: Unknown result type (might be due to invalid IL or missing references) //IL_0129: 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_0135: Unknown result type (might be due to invalid IL or missing references) //IL_0140: Unknown result type (might be due to invalid IL or missing references) //IL_014b: 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_0153: 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_0164: Unknown result type (might be due to invalid IL or missing references) //IL_016f: Unknown result type (might be due to invalid IL or missing references) //IL_017a: Unknown result type (might be due to invalid IL or missing references) ((EntityState)this).FixedUpdate(); ((BaseState)this).StartAimMode(1f, false); if (((EntityState)this).isAuthority) { stopwatch += Time.fixedDeltaTime; if (stopwatch >= 0.25f / ((BaseState)this).attackSpeedStat) { stopwatch = 0f; Ray aimRay = ((BaseState)this).GetAimRay(); new BulletAttack { bulletCount = 1u, aimVector = ((Ray)(ref aimRay)).direction, origin = ((Ray)(ref aimRay)).origin, damage = ((BaseState)this).damageStat * MainPlugin.burstDMG.Value, damageColorIndex = (DamageColorIndex)0, damageType = DamageTypeCombo.GenericSecondary, falloffModel = (FalloffModel)0, maxDistance = 150f, force = MainPlugin.beamForce.Value, hitMask = CommonMasks.bullet, minSpread = 0f, maxSpread = 0f, isCrit = ((BaseState)this).RollCrit(), owner = ((EntityState)this).gameObject, muzzleName = "MuzzleHandBeam", smartCollision = false, procChainMask = default(ProcChainMask), procCoefficient = 0.6f, radius = 0.7f, sniper = false, stopperMask = CommonMasks.bullet, weapon = null, spreadPitchScale = 1f, spreadYawScale = 1f, hitEffectPrefab = Prefabs.Load("RoR2/DLC1/VoidSurvivor/VoidSurvivorBeamImpact.prefab") }.Fire(); } if (((EntityState)this).fixedAge >= duration || !((EntityState)this).inputBank.skill2.down) { ((EntityState)this).outer.SetNextStateToMain(); } } } public override void OnExit() { AkSoundEngine.PostEvent("Play_voidman_m1_corrupted_end", ((EntityState)this).gameObject); ((EntityState)this).PlayAnimation("LeftArm, Override", "ExitHandBeam"); if (Object.op_Implicit((Object)(object)beam)) { EntityState.Destroy((Object)(object)beam); } ((EntityState)this).OnExit(); } 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 DimensionCorrupted : Dimension { public override GameObject ppObjPrefab => Prefabs.viendPPCorrupted; public override string vfx => "RoR2/DLC1/VoidSurvivor/VoidBlinkMuzzleflashCorrupted.prefab"; public override string overlayMat => "RoR2/DLC1/VoidSurvivor/matVoidBlinkBodyOverlayCorrupted.mat"; public override void OnEnter() { base.OnEnter(); if (NetworkServer.active) { ((EntityState)this).characterBody.AddBuff(Prefabs.viendSpeedBuff); } } public override void OnExit() { if (NetworkServer.active) { ((EntityState)this).characterBody.RemoveBuff(Prefabs.viendSpeedBuff); } base.OnExit(); } } internal class Dimension : GenericCharacterMain { private HurtBoxGroup hurtboxGroup; private GameObject ppObj; private GameObject fogEffect; private List models = new List(); private TeamMask mask; private VoidSurvivorController controller; private float corruptionFractionPerSecondWhileCorrupted; private float corruptionPerSecondOutOfCombat; private float corruptionPerSecondInCombat; private float corruptionForFullHeal; private float corruptionPerCrit; private float corruptionForFullDamage; private float stopwatch; private float tickPeriodSeconds = 0.2f; private float healthFractionPerSecond = MainPlugin.viendSelfDMG.Value; private float healthFractionRampCoefficientPerSecond = 0.1f; private TemporaryOverlayInstance overlay; private int stacks = -1; public virtual GameObject ppObjPrefab => Prefabs.viendPP; public virtual string vfx => "RoR2/DLC1/VoidSurvivor/VoidBlinkMuzzleflash.prefab"; public virtual string overlayMat => "RoR2/DLC1/VoidSurvivor/matVoidBlinkBodyOverlay.mat"; public override void OnEnter() { //IL_01b0: Unknown result type (might be due to invalid IL or missing references) //IL_01bb: Unknown result type (might be due to invalid IL or missing references) //IL_01c0: Unknown result type (might be due to invalid IL or missing references) //IL_032f: Unknown result type (might be due to invalid IL or missing references) //IL_0335: Unknown result type (might be due to invalid IL or missing references) //IL_0336: Unknown result type (might be due to invalid IL or missing references) //IL_006d: Unknown result type (might be due to invalid IL or missing references) //IL_0072: Unknown result type (might be due to invalid IL or missing references) //IL_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_00bb: Unknown result type (might be due to invalid IL or missing references) //IL_00f6: Unknown result type (might be due to invalid IL or missing references) ((GenericCharacterMain)this).OnEnter(); controller = ((EntityState)this).GetComponent(); Transform modelTransform = ((EntityState)this).GetModelTransform(); hurtboxGroup = ((Component)modelTransform).GetComponent(); HurtBoxGroup obj = hurtboxGroup; int hurtBoxesDeactivatorCounter = obj.hurtBoxesDeactivatorCounter; obj.hurtBoxesDeactivatorCounter = hurtBoxesDeactivatorCounter + 1; if (((EntityState)this).isAuthority) { ppObj = Object.Instantiate(ppObjPrefab); fogEffect = Object.Instantiate(Prefabs.Load("RoR2/DLC1/VoidRaidCrab/VoidRaidCrabWardWipeFogEffect.prefab"), ((EntityState)this).characterBody.corePosition, Quaternion.identity); fogEffect.transform.parent = ((EntityState)this).transform; ((Behaviour)fogEffect.GetComponent()).enabled = false; mask = TeamMask.GetEnemyTeams(((EntityState)this).teamComponent.teamIndex); foreach (CharacterBody instances in CharacterBody.instancesList) { if (Object.op_Implicit((Object)(object)instances.teamComponent) && ((TeamMask)(ref mask)).HasTeam(instances.teamComponent.teamIndex) && Object.op_Implicit((Object)(object)instances.modelLocator) && Object.op_Implicit((Object)(object)instances.modelLocator.modelTransform)) { CharacterModel component = ((Component)instances.modelLocator.modelTransform).GetComponent(); if (Object.op_Implicit((Object)(object)component)) { hurtBoxesDeactivatorCounter = component.invisibilityCount; component.invisibilityCount = hurtBoxesDeactivatorCounter + 1; models.Add(component); } } } CharacterBody.onBodyStartGlobal += CharacterBody_onBodyStartGlobal; } EffectManager.SimpleEffect(Prefabs.Load(vfx), ((EntityState)this).characterBody.corePosition, Quaternion.LookRotation(((EntityState)this).characterDirection.forward), false); overlay = TemporaryOverlayManager.AddOverlay(((Component)modelTransform).gameObject); overlay.duration = 0.5f; overlay.animateShaderAlpha = false; overlay.alphaCurve = AnimationCurve.EaseInOut(0f, 1f, 1f, 0f); overlay.destroyComponentOnEnd = false; overlay.originalMaterial = Prefabs.Load(overlayMat); overlay.AddToCharacterModel(((Component)modelTransform).GetComponent()); corruptionFractionPerSecondWhileCorrupted = controller.corruptionFractionPerSecondWhileCorrupted; corruptionPerSecondOutOfCombat = controller.corruptionPerSecondOutOfCombat; corruptionPerSecondInCombat = controller.corruptionPerSecondInCombat; corruptionForFullHeal = controller.corruptionForFullHeal; corruptionPerCrit = controller.corruptionPerCrit; corruptionForFullDamage = controller.corruptionForFullDamage; controller.corruptionFractionPerSecondWhileCorrupted = 0f; controller.corruptionPerSecondOutOfCombat = 0f; controller.corruptionPerSecondInCombat = 0f; controller.corruptionForFullHeal = 0f; controller.corruptionPerCrit = 0f; controller.corruptionForFullDamage = 0f; AkSoundEngine.PostEvent("Play_voidman_shift_start", ((EntityState)this).gameObject); CharacterBody characterBody = ((EntityState)this).characterBody; characterBody.bodyFlags = (BodyFlags)(characterBody.bodyFlags | 1); } public override void PerformSkill(GenericSkill skillSlot, ref ButtonState buttonState) { } private void CharacterBody_onBodyStartGlobal(CharacterBody b) { //IL_001a: Unknown result type (might be due to invalid IL or missing references) if (Object.op_Implicit((Object)(object)b.teamComponent) && ((TeamMask)(ref mask)).HasTeam(b.teamComponent.teamIndex) && Object.op_Implicit((Object)(object)b.modelLocator) && Object.op_Implicit((Object)(object)b.modelLocator.modelTransform)) { CharacterModel component = ((Component)b.modelLocator.modelTransform).GetComponent(); if (Object.op_Implicit((Object)(object)component)) { models.Add(component); int invisibilityCount = component.invisibilityCount; component.invisibilityCount = invisibilityCount + 1; } } } public override void FixedUpdate() { //IL_005f: Unknown result type (might be due to invalid IL or missing references) //IL_0064: Unknown result type (might be due to invalid IL or missing references) //IL_009f: Unknown result type (might be due to invalid IL or missing references) //IL_00a6: Unknown result type (might be due to invalid IL or missing references) //IL_00ab: Unknown result type (might be due to invalid IL or missing references) //IL_00b0: Unknown result type (might be due to invalid IL or missing references) //IL_00b3: Unknown result type (might be due to invalid IL or missing references) //IL_00b8: Unknown result type (might be due to invalid IL or missing references) //IL_00bd: Unknown result type (might be due to invalid IL or missing references) //IL_00c0: Unknown result type (might be due to invalid IL or missing references) //IL_00ca: Expected O, but got Unknown ((GenericCharacterMain)this).FixedUpdate(); if (NetworkServer.active) { stopwatch += Time.fixedDeltaTime; if (stopwatch >= tickPeriodSeconds) { stopwatch = 0f; stacks++; ((EntityState)this).healthComponent.TakeDamage(new DamageInfo { damage = healthFractionPerSecond * (1f + (float)stacks * healthFractionRampCoefficientPerSecond * tickPeriodSeconds) * tickPeriodSeconds * ((EntityState)this).healthComponent.fullCombinedHealth, position = ((EntityState)this).characterBody.corePosition, damageType = DamageTypeCombo.op_Implicit((DamageType)66), damageColorIndex = (DamageColorIndex)9 }); } } if (((EntityState)this).isAuthority && ((EntityState)this).fixedAge >= 0.25f && ((ButtonState)(ref ((EntityState)this).inputBank.skill3)).justPressed) { ((EntityState)this).outer.SetNextStateToMain(); } } public override void OnExit() { //IL_0008: 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_0010: 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_00f0: Unknown result type (might be due to invalid IL or missing references) //IL_00f5: Unknown result type (might be due to invalid IL or missing references) //IL_00fa: Unknown result type (might be due to invalid IL or missing references) CharacterBody characterBody = ((EntityState)this).characterBody; characterBody.bodyFlags = (BodyFlags)(characterBody.bodyFlags & -2); AkSoundEngine.PostEvent("Play_voidman_shift_end", ((EntityState)this).gameObject); if (overlay != null) { overlay.stopwatch = 0f; overlay.animateShaderAlpha = true; overlay.destroyComponentOnEnd = true; } if (Object.op_Implicit((Object)(object)controller)) { controller.corruptionFractionPerSecondWhileCorrupted = corruptionFractionPerSecondWhileCorrupted; controller.corruptionPerSecondOutOfCombat = corruptionPerSecondOutOfCombat; controller.corruptionPerSecondInCombat = corruptionPerSecondInCombat; controller.corruptionForFullHeal = corruptionForFullHeal; controller.corruptionPerCrit = corruptionPerCrit; controller.corruptionForFullDamage = corruptionForFullDamage; } EffectManager.SimpleEffect(Prefabs.Load(vfx), ((EntityState)this).characterBody.corePosition, Quaternion.LookRotation(-((EntityState)this).characterDirection.forward), false); if (((EntityState)this).isAuthority) { CharacterBody.onBodyStartGlobal -= CharacterBody_onBodyStartGlobal; foreach (CharacterModel model in models) { int invisibilityCount = model.invisibilityCount; model.invisibilityCount = invisibilityCount - 1; } } if (Object.op_Implicit((Object)(object)ppObj)) { ((Behaviour)ppObj.GetComponent()).enabled = true; } if (Object.op_Implicit((Object)(object)fogEffect)) { EntityState.Destroy((Object)(object)fogEffect); } if (Object.op_Implicit((Object)(object)hurtboxGroup)) { HurtBoxGroup obj = hurtboxGroup; int invisibilityCount = obj.hurtBoxesDeactivatorCounter; obj.hurtBoxesDeactivatorCounter = invisibilityCount - 1; } ((GenericCharacterMain)this).OnExit(); } public override InterruptPriority GetMinimumInterruptPriority() { //IL_0003: Unknown result type (might be due to invalid IL or missing references) //IL_0006: Unknown result type (might be due to invalid IL or missing references) return (InterruptPriority)9; } } internal class Sounds { public static readonly uint Sound1; public static readonly uint Sound2; public static readonly uint Sound3; public static readonly uint Sound4; } internal static class Extensions { public static GameObject NewSyringe(this GameObject g, params Material[] m) { ((Renderer)g.GetComponentsInChildren(false)[0]).material = m[0]; ((Renderer)g.GetComponent()).material = m[1]; ((Renderer)g.GetComponent()).material = m[2]; return g; } public static Material SwapTexture(this Material m, Texture2D t) { m.mainTexture = (Texture)(object)t; return m; } public static GameObject SwapMaterials(this GameObject g, Material[] m) { Renderer[] componentsInChildren = g.GetComponentsInChildren(); for (int i = 0; i < componentsInChildren.Length; i++) { if (Object.op_Implicit((Object)(object)m[i])) { componentsInChildren[i].material = m[i]; } } return g; } public static float Mult(this float f, float mult = 100f) { return f * mult; } public static Color ToRGB255(this Color c, string title, string body) { //IL_0001: 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_0019: 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_002a: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) return new Color(c.r / 255f, c.g / 255f, c.b / 255f); } public static void SetStrings(this TooltipProvider t, string title, string body) { t.overrideTitleText = title; t.overrideBodyText = body; } } internal class Utils { public static List> GetDebufflist(CharacterBody body) { //IL_0008: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_006e: Unknown result type (might be due to invalid IL or missing references) //IL_006f: Unknown result type (might be due to invalid IL or missing references) //IL_0013: Unknown result type (might be due to invalid IL or missing references) //IL_0069: Unknown result type (might be due to invalid IL or missing references) //IL_006b: Unknown result type (might be due to invalid IL or missing references) //IL_006c: Unknown result type (might be due to invalid IL or missing references) //IL_0025: Unknown result type (might be due to invalid IL or missing references) //IL_005a: Unknown result type (might be due to invalid IL or missing references) List> list = new List>(); BuffIndex val = (BuffIndex)0; for (BuffIndex val2 = (BuffIndex)BuffCatalog.buffCount; val < val2; val = (BuffIndex)(val + 1)) { int buffCount = body.GetBuffCount(val); if (buffCount > 0) { BuffDef buffDef = BuffCatalog.GetBuffDef(val); if ((!buffDef.isCooldown && !buffDef.isHidden && buffDef.isDebuff) || buffDef.isDOT) { list.Add(new KeyValuePair(val, buffCount)); } } } return list; } public static int DebuffCount(CharacterBody body) { //IL_0004: 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_004e: 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_000f: 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) //IL_004b: 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_0021: Unknown result type (might be due to invalid IL or missing references) int num = 0; BuffIndex val = (BuffIndex)0; for (BuffIndex val2 = (BuffIndex)BuffCatalog.buffCount; val < val2; val = (BuffIndex)(val + 1)) { int buffCount = body.GetBuffCount(val); if (buffCount > 0) { BuffDef buffDef = BuffCatalog.GetBuffDef(val); if (buffDef.isDebuff || buffDef.isDOT) { num += buffCount; } } } return num; } public static void ProcSeekerPassive(CharacterBody victim, CharacterBody attackerBody) { //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_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005e: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Unknown result type (might be due to invalid IL or missing references) //IL_0066: Unknown result type (might be due to invalid IL or missing references) //IL_0073: Expected O, but got Unknown //IL_008f: 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_00a0: Unknown result type (might be due to invalid IL or missing references) //IL_00a2: Unknown result type (might be due to invalid IL or missing references) //IL_00a7: Unknown result type (might be due to invalid IL or missing references) //IL_00a9: Unknown result type (might be due to invalid IL or missing references) //IL_00ae: Unknown result type (might be due to invalid IL or missing references) //IL_00c8: Unknown result type (might be due to invalid IL or missing references) //IL_00d4: Unknown result type (might be due to invalid IL or missing references) //IL_00d5: Unknown result type (might be due to invalid IL or missing references) //IL_00da: Unknown result type (might be due to invalid IL or missing references) //IL_00df: Unknown result type (might be due to invalid IL or missing references) //IL_00e2: 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_00f3: Unknown result type (might be due to invalid IL or missing references) //IL_00fe: Unknown result type (might be due to invalid IL or missing references) //IL_0105: Unknown result type (might be due to invalid IL or missing references) //IL_010c: Unknown result type (might be due to invalid IL or missing references) //IL_0111: Unknown result type (might be due to invalid IL or missing references) //IL_0116: 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_0118: Unknown result type (might be due to invalid IL or missing references) //IL_011d: Unknown result type (might be due to invalid IL or missing references) victim.AddTimedBuff(Prefabs.seekerPassiveBuff, 8f); int buffCount = victim.GetBuffCount(Prefabs.seekerPassiveBuff); if (buffCount >= MainPlugin.passiveMaxStacks.Value) { victim.ClearTimedBuffs(Prefabs.seekerPassiveBuff); Vector3 corePosition = victim.corePosition; float num = 3f; EffectManager.SpawnEffect(Prefabs.Load("RoR2/DLC2/Seeker/SoulSearchExplosionVFX.prefab"), new EffectData { origin = corePosition, scale = num }, true); float num2 = (float)(1 + attackerBody.GetBuffCount(Buffs.ChakraBuff)) * MainPlugin.passiveAddDamage.Value; new BlastAttack { attacker = ((Component)attackerBody).gameObject, attackerFiltering = (AttackerFiltering)2, falloffModel = (FalloffModel)0, baseDamage = attackerBody.damage * MainPlugin.passiveBaseDamage.Value + num2, crit = attackerBody.RollCrit(), damageType = DamageTypeCombo.Generic, damageColorIndex = (DamageColorIndex)10, inflictor = ((Component)attackerBody).gameObject, procCoefficient = 0f, radius = num, teamIndex = attackerBody.teamComponent.teamIndex, position = corePosition }.Fire(); } } public static void RecolorUI(GameObject target, Color targetColor) { //IL_000e: 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_0034: Unknown result type (might be due to invalid IL or missing references) //IL_0039: Unknown result type (might be due to invalid IL or missing references) //IL_0040: Unknown result type (might be due to invalid IL or missing references) //IL_0052: Unknown result type (might be due to invalid IL or missing references) Image[] componentsInChildren = target.GetComponentsInChildren(true); float num = default(float); float num2 = default(float); float num3 = default(float); float num4 = default(float); float num5 = default(float); float num6 = default(float); for (int i = 0; i < componentsInChildren.Length; i++) { Color.RGBToHSV(targetColor, ref num, ref num2, ref num3); Color.RGBToHSV(((Graphic)componentsInChildren[i]).color, ref num4, ref num5, ref num6); Color color = Color.HSVToRGB(num, num5, num6); color.a = ((Graphic)componentsInChildren[i]).color.a; ((Graphic)componentsInChildren[i]).color = color; } } public static Vector3 FindNearestNodePosition(Vector3 targetPosition, GraphType nodeGraphType) { //IL_0009: 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_0010: 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_0026: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0034: Unknown result type (might be due to invalid IL or missing references) //IL_0039: 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_003b: Unknown result type (might be due to invalid IL or missing references) //IL_004a: Expected O, but got Unknown //IL_0045: Unknown result type (might be due to invalid IL or missing references) //IL_004f: Expected O, but got Unknown //IL_0061: 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) //IL_0084: Unknown result type (might be due to invalid IL or missing references) //IL_0085: Unknown result type (might be due to invalid IL or missing references) //IL_0089: Unknown result type (might be due to invalid IL or missing references) SpawnCard val = ScriptableObject.CreateInstance(); val.hullSize = (HullClassification)1; val.nodeGraphType = nodeGraphType; val.prefab = Prefabs.Load("RoR2/Base/Common/DirectorSpawnProbeHelperPrefab.prefab"); Vector3 result = targetPosition; GameObject val2 = DirectorCore.instance.TrySpawnObject(new DirectorSpawnRequest(val, new DirectorPlacementRule { placementMode = (PlacementMode)3, position = targetPosition }, RoR2Application.rng)); if (Object.op_Implicit((Object)(object)val2)) { result = val2.transform.position; } if (Object.op_Implicit((Object)(object)val2)) { Object.Destroy((Object)(object)val2); } Object.Destroy((Object)(object)val); return result; } public static Vector3 GetForwardDirection(Vector3 dir) { //IL_0001: Unknown result type (might be due to invalid IL or missing references) //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_0009: 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_0042: 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_002b: 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_0039: Unknown result type (might be due to invalid IL or missing references) //IL_003e: Unknown result type (might be due to invalid IL or missing references) //IL_0045: Unknown result type (might be due to invalid IL or missing references) Vector2 val = Util.Vector3XZToVector2XY(dir); if (val != Vector2.zero) { ((Vector2)(ref val)).Normalize(); Vector3 val2 = new Vector3(val.x, 0f, val.y); return ((Vector3)(ref val2)).normalized; } return dir; } public static void PlayAnimation(GameObject g, string layerName, string animationStateName) { Animator component = g.GetComponent(); if (Object.op_Implicit((Object)(object)component)) { int layerIndex = component.GetLayerIndex(layerName); component.speed = 1f; component.Update(0f); component.PlayInFixedTime(animationStateName, layerIndex, 0f); } } public static void PlayAnimation(GameObject g, string layerName, string animationStateName, string playbackRateParam, float duration) { //IL_005c: Unknown result type (might be due to invalid IL or missing references) //IL_0061: Unknown result type (might be due to invalid IL or missing references) Animator component = g.GetComponent(); if (Object.op_Implicit((Object)(object)component)) { component.speed = 1f; component.Update(0f); int layerIndex = component.GetLayerIndex(layerName); component.SetFloat(playbackRateParam, 1f); component.PlayInFixedTime(animationStateName, layerIndex, 0f); component.Update(0f); AnimatorStateInfo currentAnimatorStateInfo = component.GetCurrentAnimatorStateInfo(layerIndex); float length = ((AnimatorStateInfo)(ref currentAnimatorStateInfo)).length; component.SetFloat(playbackRateParam, length / duration); } } public static void AnimatorPlayAnimation(Animator modelAnimator, string layerName, string animationStateName) { int layerIndex = modelAnimator.GetLayerIndex(layerName); modelAnimator.speed = 1f; modelAnimator.Update(0f); modelAnimator.PlayInFixedTime(animationStateName, layerIndex, 0f); } public static void AnimatorPlayAnimation(Animator modelAnimator, string layerName, string animationStateName, string playbackRateParam, float duration) { //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) modelAnimator.speed = 1f; modelAnimator.Update(0f); int layerIndex = modelAnimator.GetLayerIndex(layerName); modelAnimator.SetFloat(playbackRateParam, 1f); modelAnimator.PlayInFixedTime(animationStateName, layerIndex, 0f); modelAnimator.Update(0f); AnimatorStateInfo currentAnimatorStateInfo = modelAnimator.GetCurrentAnimatorStateInfo(layerIndex); float length = ((AnimatorStateInfo)(ref currentAnimatorStateInfo)).length; modelAnimator.SetFloat(playbackRateParam, length / duration); } public static SkillDef NewSkillDef(SerializableEntityStateType activationState, string activationStateMachineName, int baseMaxStock, float baseRechargeInterval, bool beginSkillCooldownOnSkillEnd, bool canceledFromSprinting, bool fullRestockOnAssign, InterruptPriority interruptPriority, bool isCombatSkill, bool mustKeyPress, bool cancelSprintingOnActivation, int rechargeStock, int requiredStock, int stockToConsume, Sprite icon, string skillDescriptionToken, string skillName, params string[] keywordTokens) where T : SkillDef { //IL_000d: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0064: Unknown result type (might be due to invalid IL or missing references) //IL_0066: Unknown result type (might be due to invalid IL or missing references) T val = ScriptableObject.CreateInstance(); ((SkillDef)val).activationState = activationState; ((SkillDef)val).activationStateMachineName = activationStateMachineName; ((SkillDef)val).baseMaxStock = baseMaxStock; ((SkillDef)val).baseRechargeInterval = baseRechargeInterval; ((SkillDef)val).beginSkillCooldownOnSkillEnd = beginSkillCooldownOnSkillEnd; ((SkillDef)val).canceledFromSprinting = canceledFromSprinting; ((SkillDef)val).fullRestockOnAssign = fullRestockOnAssign; ((SkillDef)val).interruptPriority = interruptPriority; ((SkillDef)val).isCombatSkill = isCombatSkill; ((SkillDef)val).mustKeyPress = mustKeyPress; ((SkillDef)val).cancelSprintingOnActivation = cancelSprintingOnActivation; ((SkillDef)val).rechargeStock = rechargeStock; ((SkillDef)val).requiredStock = requiredStock; ((SkillDef)val).stockToConsume = stockToConsume; ((SkillDef)val).icon = icon; ((SkillDef)val).skillDescriptionToken = skillDescriptionToken; ((SkillDef)val).skillName = skillName; ((SkillDef)val).skillNameToken = ((SkillDef)val).skillName; ((SkillDef)val).keywordTokens = keywordTokens; ContentAddition.AddSkillDef((SkillDef)(object)val); return (SkillDef)(object)val; } public static SkillDef NewSkillDef(Type activationState, string activationStateMachineName, int baseMaxStock, float baseRechargeInterval, bool beginSkillCooldownOnSkillEnd, bool canceledFromSprinting, bool fullRestockOnAssign, InterruptPriority interruptPriority, bool isCombatSkill, bool mustKeyPress, bool cancelSprintingOnActivation, int rechargeStock, int requiredStock, int stockToConsume, Sprite icon, string skillDescriptionToken, string skillName, params string[] keywordTokens) where T : SkillDef { //IL_000e: Unknown result type (might be due to invalid IL or missing references) //IL_0013: Unknown result type (might be due to invalid IL or missing references) //IL_0069: Unknown result type (might be due to invalid IL or missing references) //IL_006b: Unknown result type (might be due to invalid IL or missing references) T val = ScriptableObject.CreateInstance(); ((SkillDef)val).activationState = new SerializableEntityStateType(activationState); ((SkillDef)val).activationStateMachineName = activationStateMachineName; ((SkillDef)val).baseMaxStock = baseMaxStock; ((SkillDef)val).baseRechargeInterval = baseRechargeInterval; ((SkillDef)val).beginSkillCooldownOnSkillEnd = beginSkillCooldownOnSkillEnd; ((SkillDef)val).canceledFromSprinting = canceledFromSprinting; ((SkillDef)val).fullRestockOnAssign = fullRestockOnAssign; ((SkillDef)val).interruptPriority = interruptPriority; ((SkillDef)val).isCombatSkill = isCombatSkill; ((SkillDef)val).mustKeyPress = mustKeyPress; ((SkillDef)val).cancelSprintingOnActivation = cancelSprintingOnActivation; ((SkillDef)val).rechargeStock = rechargeStock; ((SkillDef)val).requiredStock = requiredStock; ((SkillDef)val).stockToConsume = stockToConsume; ((SkillDef)val).icon = icon; ((SkillDef)val).skillDescriptionToken = skillDescriptionToken; ((SkillDef)val).skillName = skillName; ((SkillDef)val).skillNameToken = ((SkillDef)val).skillName; ((SkillDef)val).keywordTokens = keywordTokens; ContentAddition.AddSkillDef((SkillDef)(object)val); return (SkillDef)(object)val; } public static Color HexTo10(string hexColor) { //IL_0025: Unknown result type (might be due to invalid IL or missing references) //IL_002f: Unknown result type (might be due to invalid IL or missing references) //IL_0034: 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_0036: Unknown result type (might be due to invalid IL or missing references) //IL_0039: Unknown result type (might be due to invalid IL or missing references) char[] array = hexColor.ToCharArray(); return new Color((float)(array[0] + array[1]), (float)(array[2] + array[3]), (float)(array[4] + array[5]), 255f) / 255f; } public static EntityStateMachine NewStateMachine(GameObject obj, string customName) where T : EntityState { //IL_0021: 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_0028: Unknown result type (might be due to invalid IL or missing references) //IL_0029: Unknown result type (might be due to invalid IL or missing references) SerializableEntityStateType val = default(SerializableEntityStateType); ((SerializableEntityStateType)(ref val))..ctor(typeof(T)); EntityStateMachine val2 = obj.AddComponent(); val2.customName = customName; val2.initialStateType = val; val2.mainStateType = val; return val2; } public static GenericSkill NewGenericSkill(GameObject obj, SkillDef skill) { //IL_0031: 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) //IL_0053: Expected O, but got Unknown //IL_0054: Unknown result type (might be due to invalid IL or missing references) //IL_0055: Unknown result type (might be due to invalid IL or missing references) GenericSkill val = obj.AddComponent(); SkillFamily val2 = ScriptableObject.CreateInstance(); val2.variants = (Variant[])(object)new Variant[1]; val._skillFamily = val2; SkillFamily skillFamily = val.skillFamily; Variant[] variants = skillFamily.variants; Variant val3 = new Variant { skillDef = skill }; ((Variant)(ref val3)).viewableNode = new Node(skill.skillNameToken, false, (Node)null); variants[0] = val3; ContentAddition.AddSkillFamily(skillFamily); return val; } public static void AddAlt(SkillFamily skillFamily, SkillDef SkillDef) { //IL_0029: 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_004b: Expected O, but got Unknown //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_004d: Unknown result type (might be due to invalid IL or missing references) Array.Resize(ref skillFamily.variants, skillFamily.variants.Length + 1); Variant[] variants = skillFamily.variants; int num = skillFamily.variants.Length - 1; Variant val = new Variant { skillDef = SkillDef }; ((Variant)(ref val)).viewableNode = new Node(SkillDef.skillNameToken, false, (Node)null); variants[num] = val; } public static BuffDef NewBuffDef(string name, bool stack, bool hidden, Sprite sprite, Color color) { //IL_0025: 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) BuffDef val = ScriptableObject.CreateInstance(); ((Object)val).name = name; val.canStack = stack; val.isHidden = hidden; val.iconSprite = sprite; val.buffColor = color; ContentAddition.AddBuffDef(val); return val; } public static ObjectScaleCurve AddScaleComponent(GameObject target, float timeMax) { ObjectScaleCurve val = target.AddComponent(); val.useOverallCurveOnly = true; val.timeMax = timeMax; val.overallCurve = AnimationCurve.Linear(0f, 0f, 1f, 1f); return val; } public static RotateAroundAxis AddRotationComponent(GameObject target, float speed, RotationAxis axis) { //IL_0019: Unknown result type (might be due to invalid IL or missing references) RotateAroundAxis val = target.AddComponent(); val.speed = (Speed)2; val.fastRotationSpeed = speed; val.rotateAroundAxis = axis; return val; } public static GameObject NewDisplayModel(GameObject model, string name) { //IL_0046: Unknown result type (might be due to invalid IL or missing references) //IL_0050: Expected O, but got Unknown GameObject val = PrefabAPI.InstantiateClone(model, name, false); val.GetComponentInChildren().runtimeAnimatorController = Assets.Load("displayAnimator"); ((Behaviour)val.GetComponentInChildren()).enabled = false; SkinnedMeshRenderer[] componentsInChildren = val.GetComponentsInChildren(true); foreach (SkinnedMeshRenderer val2 in componentsInChildren) { ((Renderer)val2).material = new Material(((Renderer)val2).material); ((Renderer)val2).material.DisableKeyword("DITHER"); } return val; } public static AnimateShaderAlpha AddShaderAlphaComponent(GameObject target, float timeMax, AnimationCurve curve, bool destroyOnEnd = true, bool disableOnEnd = false) { AnimateShaderAlpha val = target.AddComponent(); val.timeMax = timeMax; val.alphaCurve = curve; val.destroyOnEnd = destroyOnEnd; val.disableOnEnd = disableOnEnd; return val; } internal static Sprite CreateSprite(Texture2D tex) { //IL_001a: Unknown result type (might be due to invalid IL or missing references) //IL_0029: Unknown result type (might be due to invalid IL or missing references) return Sprite.Create(tex, new Rect(0f, 0f, (float)((Texture)tex).width, (float)((Texture)tex).height), new Vector2(0.5f, 0.5f), 128f); } internal static void AddMinionSkin(SkinDef skinDef, GameObject prefab, SkinDef minionSkin) { //IL_0029: 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_0040: Unknown result type (might be due to invalid IL or missing references) Array.Resize(ref skinDef.minionSkinReplacements, skinDef.minionSkinReplacements.Length + 1); skinDef.minionSkinReplacements[skinDef.minionSkinReplacements.Length - 1] = new MinionSkinReplacement { minionBodyPrefab = prefab, minionSkin = minionSkin }; } internal static SkinDefInfo CreateNewSkinDefInfo(List childList, GameObject rootObject, RendererInfo[] rendererInfos, Material mat) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0009: Expected O, but got Unknown //IL_0028: 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_01a0: Unknown result type (might be due to invalid IL or missing references) //IL_0137: Unknown result type (might be due to invalid IL or missing references) //IL_0140: 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_0174: Unknown result type (might be due to invalid IL or missing references) //IL_0176: Unknown result type (might be due to invalid IL or missing references) //IL_00db: Unknown result type (might be due to invalid IL or missing references) //IL_00e1: Expected O, but got Unknown //IL_0103: Unknown result type (might be due to invalid IL or missing references) //IL_012b: Unknown result type (might be due to invalid IL or missing references) //IL_01a4: Unknown result type (might be due to invalid IL or missing references) mat = new Material(mat); mat.DisableKeyword("PRINT_CUTOFF"); mat.SetFloat("_PrintOn", 0f); SkinDefInfo val = default(SkinDefInfo); val.BaseSkins = Array.Empty(); val.MinionSkinReplacements = (MinionSkinReplacement[])(object)new MinionSkinReplacement[0]; val.ProjectileGhostReplacements = (ProjectileGhostReplacement[])(object)new ProjectileGhostReplacement[0]; val.GameObjectActivations = (GameObjectActivation[])(object)new GameObjectActivation[0]; val.Icon = null; val.MeshReplacements = (MeshReplacement[])(object)new MeshReplacement[0]; val.Name = ""; val.NameToken = ""; val.RendererInfos = (RendererInfo[])(object)new RendererInfo[rendererInfos.Length]; for (int i = 0; i < rendererInfos.Length; i++) { Material val2 = mat; if (((Object)childList[i]).name == "HeadCharge") { Texture2D val3 = Assets.Load("chargeindicator"); Texture2D val4 = Assets.Load("chargeindicator_e"); val2 = new Material(mat); val2.SetTexture("_MainTex", (Texture)(object)val3); val2.SetTexture("_EmTex", (Texture)(object)val4); val2.SetTextureScale("_MainTex", Vector2.zero); val2.SetFloat("_EmPower", 10f); val2.SetColor("_EmColor", mat.GetColor("_EmColor")); } val.RendererInfos[i] = new RendererInfo { renderer = childList[i], defaultMaterial = val2, defaultShadowCastingMode = (ShadowCastingMode)1, hideOnDeath = false, ignoreOverlays = false }; } val.RootObject = rootObject; val.UnlockableDef = null; return val; } internal static SkinDefInfo CreateNewSkinDefInfo(Renderer[] childList, GameObject rootObject, string skinName, string objectToEnable, RendererInfo[] rendererInfos, UnlockableDef unlockableDef = null) { //IL_0003: Unknown result type (might be due to invalid IL or missing references) //IL_0085: Unknown result type (might be due to invalid IL or missing references) //IL_0086: 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) SkinDefInfo result = default(SkinDefInfo); result.BaseSkins = Array.Empty(); result.MinionSkinReplacements = (MinionSkinReplacement[])(object)new MinionSkinReplacement[0]; result.ProjectileGhostReplacements = (ProjectileGhostReplacement[])(object)new ProjectileGhostReplacement[0]; result.GameObjectActivations = (GameObjectActivation[])(object)new GameObjectActivation[0]; result.Icon = Assets.MainAssetBundle.LoadAsset(objectToEnable); result.MeshReplacements = (MeshReplacement[])(object)new MeshReplacement[0]; result.Name = skinName; result.NameToken = skinName; result.RendererInfos = rendererInfos; result.RootObject = rootObject; result.UnlockableDef = unlockableDef; return result; } internal static T CopyComponent(T original, GameObject destination) where T : Component { Type type = ((object)original).GetType(); Component val = destination.AddComponent(type); FieldInfo[] fields = type.GetFields(); FieldInfo[] array = fields; foreach (FieldInfo fieldInfo in array) { fieldInfo.SetValue(val, fieldInfo.GetValue(original)); } return (T)(object)((val is T) ? val : null); } public static Sprite CreateSpriteFromTexture(Texture2D texture) { //IL_0025: Unknown result type (might be due to invalid IL or missing references) //IL_0034: Unknown result type (might be due to invalid IL or missing references) if (Object.op_Implicit((Object)(object)texture)) { return Sprite.Create(texture, new Rect(0f, 0f, (float)((Texture)texture).width, (float)((Texture)texture).height), new Vector2(0.5f, 0.5f)); } return null; } public static GameObject FindInActiveObjectByName(string name) { //IL_000f: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Invalid comparison between Unknown and I4 Transform[] array = Resources.FindObjectsOfTypeAll(); for (int i = 0; i < array.Length; i++) { if ((int)((Object)array[i]).hideFlags == 0 && ((Object)array[i]).name == name) { return ((Component)array[i]).gameObject; } } return null; } public static void CreateHitboxes(string name, Transform parent, Vector3[] sizes, Vector3[] positions) { //IL_0034: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Expected O, but got Unknown //IL_004f: Unknown result type (might be due to invalid IL or missing references) //IL_0060: Unknown result type (might be due to invalid IL or missing references) //IL_006a: Unknown result type (might be due to invalid IL or missing references) //IL_006f: Unknown result type (might be due to invalid IL or missing references) //IL_0082: Unknown result type (might be due to invalid IL or missing references) HitBoxGroup val = ((Component)parent).gameObject.AddComponent(); val.groupName = name; List list = new List(); for (int i = 0; i < sizes.Length; i++) { GameObject val2 = new GameObject(name + (i + 1)); val2.transform.SetParent(parent); val2.transform.localPosition = positions[i]; val2.transform.localRotation = Quaternion.Euler(Vector3.forward * 45f); val2.transform.localScale = sizes[i]; HitBox item = val2.AddComponent(); val2.layer = LayerIndex.projectile.intVal; list.Add(item); } val.hitBoxes = list.ToArray(); } public static GameObject CreateHitbox(string name, Transform parent, Vector3 scale, Vector3 localPosition) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown //IL_001b: Unknown result type (might be due to invalid IL or missing references) //IL_0028: Unknown result type (might be due to invalid IL or missing references) //IL_0032: 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_0048: Unknown result type (might be due to invalid IL or missing references) GameObject val = new GameObject(name); val.transform.SetParent(parent); val.transform.localPosition = localPosition; val.transform.localRotation = Quaternion.Euler(Vector3.forward * 45f); val.transform.localScale = scale; HitBoxGroup val2 = ((Component)parent).gameObject.AddComponent(); HitBox val3 = val.AddComponent(); val.layer = LayerIndex.projectile.intVal; val2.hitBoxes = (HitBox[])(object)new HitBox[1] { val3 }; val2.groupName = name; return val; } internal static EffectComponent RegisterEffect(GameObject effect, float duration, string soundName = "", bool applyScale = false, bool parentToReferencedTransform = true, bool positionAtReferencedTransform = true) { //IL_00a6: Unknown result type (might be due to invalid IL or missing references) //IL_0097: Unknown result type (might be due to invalid IL or missing references) EffectComponent val = effect.GetComponent(); if (!Object.op_Implicit((Object)(object)val)) { val = effect.AddComponent(); } if (duration != -1f) { DestroyOnTimer component = effect.GetComponent(); if (!Object.op_Implicit((Object)(object)component)) { effect.AddComponent().duration = duration; } else { component.duration = duration; } } if (!Object.op_Implicit((Object)(object)effect.GetComponent())) { effect.AddComponent(); } if (!Object.op_Implicit((Object)(object)effect.GetComponent())) { effect.AddComponent().vfxPriority = (VFXPriority)2; } val.applyScale = applyScale; val.effectIndex = (EffectIndex)(-1); val.parentToReferencedTransform = parentToReferencedTransform; val.positionAtReferencedTransform = positionAtReferencedTransform; val.soundName = soundName; ContentAddition.AddEffect(effect); return val; } public static Material InstantiateMaterial(Texture tex) { //IL_0022: Unknown result type (might be due to invalid IL or missing references) //IL_0040: Unknown result type (might be due to invalid IL or missing references) Material val = Object.Instantiate(Prefabs.Load("RoR2/Base/Commando/matCommandoDualies.mat")); if (Object.op_Implicit((Object)(object)val)) { val.SetColor("_Color", Color.white); val.SetTexture("_MainTex", tex); val.SetColor("_EmColor", Color.black); val.SetFloat("_EmPower", 0f); val.SetTexture("_EmTex", (Texture)null); val.SetFloat("_NormalStrength", 1f); val.SetTexture("_NormalTex", (Texture)null); return val; } return val; } public static Material InstantiateMaterial(Color color, Texture tex, Color emColor, float emPower, Texture emTex, float normStr, Texture normTex) { //IL_0037: 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) Material val = Object.Instantiate(LegacyResourcesAPI.Load("Prefabs/CharacterBodies/CommandoBody").GetComponentInChildren().baseRendererInfos[0].defaultMaterial); if (Object.op_Implicit((Object)(object)val)) { val.SetColor("_Color", color); val.SetTexture("_MainTex", tex); val.SetColor("_EmColor", emColor); val.SetFloat("_EmPower", emPower); val.SetTexture("_EmTex", emTex); val.SetFloat("_NormalStrength", 1f); val.SetTexture("_NormalTex", normTex); return val; } return val; } public static Material FindMaterial(string name) { //IL_000f: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Invalid comparison between Unknown and I4 Material[] array = Resources.FindObjectsOfTypeAll(); for (int i = 0; i < array.Length; i++) { if ((int)((Object)array[i]).hideFlags == 0 && ((Object)array[i]).name == name) { return array[i]; } } return null; } }