using System; using System.Collections; using System.Collections.Generic; using System.Diagnostics; using System.IO; using System.Linq; using System.Reflection; using System.Runtime.CompilerServices; using System.Runtime.Versioning; using System.Security; using System.Security.Permissions; using Assets.RoR2.Scripts.Platform; using BepInEx; using BepInEx.Bootstrap; using BepInEx.Configuration; using BepInEx.Logging; using EntityStates; using EntityStates.AI.Walker; using EntityStates.Commando; using EntityStates.Commando.CommandoWeapon; using EntityStates.ImpMonster; using EntityStates.Missions.BrotherEncounter; using GhoulMod.Modules; using GhoulMod.Modules.Achievements; using GhoulMod.Modules.BaseStates; using GhoulMod.Modules.Characters; using GhoulMod.Survivors.Ghoul; using GhoulMod.Survivors.Ghoul.Components; using GhoulMod.Survivors.Ghoul.Items; using GhoulMod.Survivors.Ghoul.SkillStates; using GhoulMod.Survivors.Ghoul.SkillStates.Cling; using HG; using HG.BlendableTypes; using KinematicCharacterController; using ModdedEntityStates.Ghoul; using On.EntityStates.Missions.BrotherEncounter; using On.RoR2; using On.RoR2.UI; using R2API; using R2API.Networking; using R2API.Networking.Interfaces; using R2API.Utils; using RiskOfOptions; using RiskOfOptions.OptionConfigs; using RiskOfOptions.Options; using RoR2; using RoR2.Achievements; using RoR2.Audio; using RoR2.CharacterAI; using RoR2.ContentManagement; using RoR2.Projectile; using RoR2.Skills; using RoR2.UI; using TMPro; using UnityEngine; using UnityEngine.AddressableAssets; using UnityEngine.Networking; using UnityEngine.Rendering; using UnityEngine.UI; [assembly: CompilationRelaxations(8)] [assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)] [assembly: Debuggable(DebuggableAttribute.DebuggingModes.Default | DebuggableAttribute.DebuggingModes.DisableOptimizations | DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints | DebuggableAttribute.DebuggingModes.EnableEditAndContinue)] [assembly: TargetFramework(".NETStandard,Version=v2.1", FrameworkDisplayName = ".NET Standard 2.1")] [assembly: AssemblyCompany("GhoulSurvMod")] [assembly: AssemblyConfiguration("Debug")] [assembly: AssemblyFileVersion("1.0.0.0")] [assembly: AssemblyInformationalVersion("1.0.0+513bda4b90bcbb6968126a6e585a100c748e2e3d")] [assembly: AssemblyProduct("GhoulSurvMod")] [assembly: AssemblyTitle("GhoulSurvMod")] [assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)] [assembly: AssemblyVersion("1.0.0.0")] [module: UnverifiableCode] public class GhoulInvasionManager : MonoBehaviour { private readonly float invasionInterval = 300f; private int previousInvasionCycle; private Run run; private GhoulWeaponComponent _ghoul; private CharacterBody characterBody; public int lastStageCount = -1; public int currentStageCount; private PickupDropTable dropTable; private static readonly Xoroshiro128Plus treasureRng = new Xoroshiro128Plus(0uL); private SceneDef lastSpawnSceneDef; public List restrictedStages = new List { "moon", "moon2", "limbo", "bazaar", "voidstage", "arena", "mysteryspace", "meridian", "voidraid" }; public static event Action onFeralGhoulDeath; private void Start() { run = Run.instance; dropTable = (PickupDropTable)(object)ScriptableObject.CreateInstance(); } private void OnEnable() { GlobalEventManager.onCharacterDeathGlobal += OnCharacterDeathGlobal; } private void OnDisable() { GlobalEventManager.onCharacterDeathGlobal -= OnCharacterDeathGlobal; } private void FixedUpdate() { int currentInvasionCycle = GetCurrentInvasionCycle(); if (!hasSpawnedThisStage() && !isRestrictedStage() && (previousInvasionCycle < currentInvasionCycle || (isRageFull(_ghoul) && _ghoul.rageThreshold > 0f))) { lastSpawnSceneDef = SceneCatalog.mostRecentSceneDef; previousInvasionCycle = currentInvasionCycle; PerformInvasion(); } currentStageCount = run.stageClearCount; } public void SetGhoul(GhoulWeaponComponent ghoul) { _ghoul = ghoul; } private void OnCharacterDeathGlobal(DamageReport damageReport) { //IL_00bb: 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_007a: Unknown result type (might be due to invalid IL or missing references) CharacterMaster victimMaster = damageReport.victimMaster; Inventory val = ((victimMaster != null) ? victimMaster.inventory : null); if (Object.op_Implicit((Object)(object)val) && damageReport.victimBody.HasBuff(GhoulBuffs.feralAffix) && val.GetItemCountEffective(Items.ExtraLife) == 0 && val.GetItemCountEffective(Items.ExtraLifeVoid) == 0 && !damageReport.victimBody.HasBuff(Buffs.ExtraLifeBuff) && damageReport.victimBody.equipmentSlot.equipmentIndex != Equipment.HealAndRevive.equipmentIndex && isRageFull(damageReport.attacker.GetComponent())) { _ghoul.rageValue = 0f; ItemDrop(GhoulAssets.essenceObject, ((Component)damageReport.victim).transform.position); } } public void ItemDrop(GameObject drop, Vector3 position) { //IL_001f: 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) //IL_0047: 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_0059: 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_005c: 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_006c: Unknown result type (might be due to invalid IL or missing references) if (!NetworkServer.active) { Debug.LogWarning((object)"[Server] function 'System.Void RoR2.OptionChestBehavior::ItemDrop()' called on client"); return; } CreatePickupInfo val = default(CreatePickupInfo); val.pickerOptions = PickupPickerController.GenerateOptionsFromDropTable(2, dropTable, treasureRng); val.position = position; val.rotation = Quaternion.identity; val.prefabOverride = drop; CreatePickupInfo val2 = val; PickupDropletController.CreatePickupDroplet(val2, val2.position, Vector3.up * 20f); } private bool isRageFull(GhoulWeaponComponent wep) { if (Object.op_Implicit((Object)(object)wep) && wep.rageValue >= wep.rageThreshold) { return true; } return false; } private int GetCurrentInvasionCycle() { return Mathf.FloorToInt(run.GetRunStopwatch() / invasionInterval); } private bool isRestrictedStage() { if (restrictedStages.Contains(SceneCatalog.GetSceneDefForCurrentScene().baseSceneName)) { return true; } return false; } public bool hasSpawnedThisStage() { if ((Object)(object)SceneCatalog.mostRecentSceneDef == (Object)(object)lastSpawnSceneDef) { previousInvasionCycle = GetCurrentInvasionCycle(); return true; } return false; } public static void PerformInvasion() { //IL_001e: Unknown result type (might be due to invalid IL or missing references) //IL_0024: Invalid comparison between Unknown and I4 for (int num = CharacterMaster.readOnlyInstancesList.Count - 1; num >= 0; num--) { CharacterMaster val = CharacterMaster.readOnlyInstancesList[num]; if ((int)val.teamIndex == 1 && Object.op_Implicit((Object)(object)val.playerCharacterMasterController) && val.GetBody().baseNameToken == "VCR_GHOUL_NAME") { CreateDoppelganger(val); } } } private static void CreateDoppelganger(CharacterMaster srcCharacterMaster) { //IL_0052: 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_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) //IL_0060: 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_0069: Expected O, but got Unknown //IL_0069: 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 SpawnCard spawnCard = (SpawnCard)(object)GhoulFeralSpawnCard.GetSpawnCard(srcCharacterMaster); if (!Object.op_Implicit((Object)(object)spawnCard)) { return; } Transform spawnOnTarget; MonsterSpawnDistance val; if (Object.op_Implicit((Object)(object)TeleporterInteraction.instance)) { spawnOnTarget = ((Component)TeleporterInteraction.instance).transform; val = (MonsterSpawnDistance)0; } else { spawnOnTarget = srcCharacterMaster.GetBody().coreTransform; val = (MonsterSpawnDistance)2; } DirectorPlacementRule val2 = new DirectorPlacementRule { spawnOnTarget = spawnOnTarget, placementMode = (PlacementMode)3 }; DirectorCore.GetMonsterSpawnDistance(val, ref val2.minDistance, ref val2.maxDistance); DirectorSpawnRequest val3 = new DirectorSpawnRequest(spawnCard, val2, (Xoroshiro128Plus)null); val3.teamIndexOverride = (TeamIndex)2; val3.ignoreTeamMemberLimit = true; CombatSquad combatSquad = null; val3.onSpawnedServer = (Action)Delegate.Combine(val3.onSpawnedServer, (Action)delegate(SpawnResult result) { //IL_002f: 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_0068: Unknown result type (might be due to invalid IL or missing references) //IL_006e: Expected I4, but got Unknown //IL_007a: Unknown result type (might be due to invalid IL or missing references) if (!Object.op_Implicit((Object)(object)combatSquad)) { combatSquad = Object.Instantiate(LegacyResourcesAPI.Load("Prefabs/NetworkedObjects/Encounters/ShadowCloneEncounter")).GetComponent(); } result.spawnedInstance.GetComponent().GetBody().AddBuff(GhoulBuffs.feralAffix); result.spawnedInstance.GetComponent().inventory.GiveRandomItems(1, (ItemTier[])(object)new ItemTier[1] { (ItemTier)(int)GhoulItems.mutationTier.tier }); combatSquad.AddMember(result.spawnedInstance.GetComponent()); }); DirectorCore.instance.TrySpawnObject(val3); if (Object.op_Implicit((Object)(object)combatSquad)) { NetworkServer.Spawn(((Component)combatSquad).gameObject); } Object.Destroy((Object)(object)spawnCard); } } namespace GhoulSurvMod.Modules { public class Enemies { } } namespace ModdedEntityStates.Ghoul { public class AltGrappleThrownState : BaseSkillState { public float throwVelocity = 25f; public BlastAttack attack; public GameObject ghoulAttacker; public static float blastRadius = 8f; public static float blastProcCoefficient = 1f; public static float blastForce = 40f; public static Vector3 blastBonusForce = Vector3.down; public GameObject slamExplosion; public GameObject slamDecal; private bool slamNextFrame; public Vector3 throwDir; public override void OnEnter() { //IL_001d: Unknown result type (might be due to invalid IL or missing references) //IL_0027: Expected O, but got Unknown //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_004e: 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_0073: 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) if (Object.op_Implicit((Object)(object)((EntityState)this).characterMotor)) { ((EntityState)this).characterMotor.onMovementHit += new MovementHitDelegate(OnMovementHit); } if (Object.op_Implicit((Object)(object)((EntityState)this).characterMotor)) { ((EntityState)this).characterMotor.velocity = throwDir * throwVelocity; } if (Object.op_Implicit((Object)(object)((EntityState)this).rigidbodyMotor)) { RigidbodyMotor rigidbodyMotor = ((EntityState)this).rigidbodyMotor; PhysForceInfo val = new PhysForceInfo { force = throwDir * throwVelocity }; rigidbodyMotor.ApplyForceImpulse(ref val); } ((BaseState)this).OnEnter(); } public override void OnExit() { //IL_001d: Unknown result type (might be due to invalid IL or missing references) //IL_0027: Expected O, but got Unknown if (Object.op_Implicit((Object)(object)((EntityState)this).characterMotor)) { ((EntityState)this).characterMotor.onMovementHit -= new MovementHitDelegate(OnMovementHit); } ((EntityState)this).OnExit(); } public override void FixedUpdate() { //IL_004e: 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) if ((Object.op_Implicit((Object)(object)((EntityState)this).characterMotor) && ((EntityState)this).characterMotor.isGrounded) || slamNextFrame || isRigidBodyCollision()) { FireBlastAttack(); if (Object.op_Implicit((Object)(object)((EntityState)this).characterMotor)) { ((EntityState)this).characterMotor.velocity = throwDir * throwVelocity; } ((EntityState)this).outer.SetNextStateToMain(); } ((EntityState)this).FixedUpdate(); } private void OnMovementHit(ref MovementHitInfo movementHitInfo) { } private bool isRigidBodyCollision() { //IL_0009: 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_003e: 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) Ray val = default(Ray); ((Ray)(ref val))..ctor(((EntityState)this).transform.position, ((EntityState)this).transform.forward); RaycastHit val2 = default(RaycastHit); if (Object.op_Implicit((Object)(object)((EntityState)this).rigidbodyMotor) && !Object.op_Implicit((Object)(object)((EntityState)this).characterMotor) && Util.CharacterSpherecast(((EntityState)this).gameObject, val, 3f, ref val2, 0f, LayerMask.op_Implicit(LayerIndex.world.intVal), (QueryTriggerInteraction)2)) { return true; } return false; } public void FireBlastAttack() { //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) //IL_0028: 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_0041: 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_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_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_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_0084: Unknown result type (might be due to invalid IL or missing references) //IL_0089: Unknown result type (might be due to invalid IL or missing references) //IL_0094: Unknown result type (might be due to invalid IL or missing references) //IL_009f: 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_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_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_00af: Unknown result type (might be due to invalid IL or missing references) //IL_00b9: Expected O, but got Unknown //IL_00bf: Unknown result type (might be due to invalid IL or missing references) Vector3 footPosition = ((EntityState)this).characterBody.footPosition; slamDecal = Object.Instantiate(GhoulAssets.slamDecal); slamDecal.transform.position = footPosition; attack = new BlastAttack { attacker = ((EntityState)this).gameObject, baseDamage = ((BaseState)this).damageStat * 6f, baseForce = blastForce, bonusForce = blastBonusForce, crit = ((BaseState)this).RollCrit(), damageType = DamageTypeCombo.op_Implicit((DamageType)32), falloffModel = (FalloffModel)0, procCoefficient = blastProcCoefficient, radius = blastRadius, position = footPosition, attackerFiltering = (AttackerFiltering)3, teamIndex = (TeamIndex)1 }; attack.Fire(); } } } namespace GhoulMod { [NetworkCompatibility(/*Could not decode attribute arguments.*/)] [BepInPlugin("com.vcr.GhoulSurvMod", "GhoulMod", "1.0.0")] public class GhoulPlugin : BaseUnityPlugin { public const string MODUID = "com.vcr.GhoulSurvMod"; public const string MODNAME = "GhoulMod"; public const string MODVERSION = "1.0.0"; public const string DEVELOPER_PREFIX = "VCR"; public static GhoulPlugin instance; public static bool rooInstalled => Chainloader.PluginInfos.ContainsKey("com.rune580.riskofoptions"); private void Awake() { instance = this; Log.Init(((BaseUnityPlugin)this).Logger); Language.Init(); new GhoulSurvivor().Initialize(); new ContentPacks().Initialize(); NetworkingAPI.RegisterMessageType(); } } internal static class Log { internal static ManualLogSource _logSource; internal static void Init(ManualLogSource logSource) { _logSource = logSource; } internal static void Debug(object data) { _logSource.LogDebug(data); } internal static void Error(object data) { _logSource.LogError(data); } internal static void ErrorAssetBundle(string assetName, string bundleName) { Error("failed to load asset, " + assetName + ", because it does not exist in asset bundle, " + bundleName); } internal static void Fatal(object data) { _logSource.LogFatal(data); } internal static void Info(object data) { _logSource.LogInfo(data); } internal static void Message(object data) { _logSource.LogMessage(data); } internal static void Warning(object data) { _logSource.LogWarning(data); } } } namespace GhoulMod.Modules { internal static class Asset { internal static Dictionary loadedBundles = new Dictionary(); internal static AssetBundle LoadAssetBundle(string bundleName) { if (bundleName == "myassetbundle") { Log.Error("AssetBundle name hasn't been changed. not loading any assets to avoid conflicts.\nMake sure to rename your assetbundle filename and rename the AssetBundleName field in your character setup code "); return null; } if (loadedBundles.ContainsKey(bundleName)) { return loadedBundles[bundleName]; } AssetBundle val = null; try { val = AssetBundle.LoadFromFile(Path.Combine(Path.GetDirectoryName(((BaseUnityPlugin)GhoulPlugin.instance).Info.Location), "AssetBundles", bundleName)); } catch (Exception arg) { Log.Error($"Error loading asset bundle, {bundleName}. Your asset bundle must be in a folder next to your mod dll called 'AssetBundles'. Follow the guide to build and install your mod correctly!\n{arg}"); } loadedBundles[bundleName] = val; return val; } internal static GameObject CloneTracer(string originalTracerName, string newTracerName) { if ((Object)(object)LegacyResourcesAPI.Load("Prefabs/Effects/Tracers/" + originalTracerName) == (Object)null) { return null; } GameObject val = PrefabAPI.InstantiateClone(LegacyResourcesAPI.Load("Prefabs/Effects/Tracers/" + originalTracerName), newTracerName, true); if (!Object.op_Implicit((Object)(object)val.GetComponent())) { val.AddComponent(); } if (!Object.op_Implicit((Object)(object)val.GetComponent())) { val.AddComponent(); } if (!Object.op_Implicit((Object)(object)val.GetComponent())) { val.AddComponent(); } val.GetComponent().speed = 250f; val.GetComponent().length = 50f; Content.CreateAndAddEffectDef(val); return val; } internal static void ConvertAllRenderersToHopooShader(GameObject objectToConvert) { if (!Object.op_Implicit((Object)(object)objectToConvert)) { return; } MeshRenderer[] componentsInChildren = objectToConvert.GetComponentsInChildren(); foreach (MeshRenderer val in componentsInChildren) { if (Object.op_Implicit((Object)(object)val) && Object.op_Implicit((Object)(object)((Renderer)val).sharedMaterial)) { ((Renderer)val).sharedMaterial.ConvertDefaultShaderToHopoo(); } } SkinnedMeshRenderer[] componentsInChildren2 = objectToConvert.GetComponentsInChildren(); foreach (SkinnedMeshRenderer val2 in componentsInChildren2) { if (Object.op_Implicit((Object)(object)val2) && Object.op_Implicit((Object)(object)((Renderer)val2).sharedMaterial)) { ((Renderer)val2).sharedMaterial.ConvertDefaultShaderToHopoo(); } } } internal static GameObject LoadCrosshair(string crosshairName) { GameObject val = LegacyResourcesAPI.Load("Prefabs/Crosshair/" + crosshairName + "Crosshair"); if ((Object)(object)val == (Object)null) { Log.Error("could not load crosshair with the name " + crosshairName + ". defaulting to Standard"); return LegacyResourcesAPI.Load("Prefabs/Crosshair/StandardCrosshair"); } return val; } internal static GameObject LoadEffect(this AssetBundle assetBundle, string resourceName, bool parentToTransform) { return assetBundle.LoadEffect(resourceName, "", parentToTransform); } internal static GameObject LoadEffect(this AssetBundle assetBundle, string resourceName, string soundName = "", bool parentToTransform = false) { //IL_0046: 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) GameObject val = assetBundle.LoadAsset(resourceName); if (!Object.op_Implicit((Object)(object)val)) { Log.ErrorAssetBundle(resourceName, ((Object)assetBundle).name); return null; } val.AddComponent().duration = 12f; val.AddComponent(); val.AddComponent().vfxPriority = (VFXPriority)2; EffectComponent val2 = val.AddComponent(); val2.applyScale = false; val2.effectIndex = (EffectIndex)(-1); val2.parentToReferencedTransform = parentToTransform; val2.positionAtReferencedTransform = true; val2.soundName = soundName; Content.CreateAndAddEffectDef(val); return val; } internal static GameObject CreateProjectileGhostPrefab(this AssetBundle assetBundle, string ghostName) { GameObject val = assetBundle.LoadAsset(ghostName); if ((Object)(object)val == (Object)null) { Log.Error("Failed to load ghost prefab " + ghostName); } if (!Object.op_Implicit((Object)(object)val.GetComponent())) { val.AddComponent(); } if (!Object.op_Implicit((Object)(object)val.GetComponent())) { val.AddComponent(); } ConvertAllRenderersToHopooShader(val); return val; } internal static GameObject CloneProjectilePrefab(string prefabName, string newPrefabName) { return PrefabAPI.InstantiateClone(LegacyResourcesAPI.Load("Prefabs/Projectiles/" + prefabName), newPrefabName); } internal static GameObject LoadAndAddProjectilePrefab(this AssetBundle assetBundle, string newPrefabName) { GameObject val = assetBundle.LoadAsset(newPrefabName); if ((Object)(object)val == (Object)null) { Log.ErrorAssetBundle(newPrefabName, ((Object)assetBundle).name); return null; } Content.AddProjectilePrefab(val); return val; } } public static class Config { public static ConfigFile MyConfig = ((BaseUnityPlugin)GhoulPlugin.instance).Config; public static ConfigEntry CharacterEnableConfig(string section, string characterName, string description = "", bool enabledByDefault = true) { if (string.IsNullOrEmpty(description)) { description = "Set to false to disable this character and as much of its code and content as possible"; } return BindAndOptions(section, "Enable " + characterName, enabledByDefault, description, restartRequired: true); } public static ConfigEntry BindAndOptions(string section, string name, T defaultValue, string description = "", bool restartRequired = false) { return BindAndOptions(section, name, defaultValue, 0f, 20f, description, restartRequired); } public static ConfigEntry BindAndOptions(string section, string name, T defaultValue, float min, float max, string description = "", bool restartRequired = false) { if (string.IsNullOrEmpty(description)) { description = name; } if (restartRequired) { description += " (restart required)"; } ConfigEntry val = MyConfig.Bind(section, name, defaultValue, description); if (Chainloader.PluginInfos.ContainsKey("com.rune580.riskofoptions")) { TryRegisterOption(val, min, max, restartRequired); } return val; } public static ConfigEntry BindAndOptionsSlider(string section, string name, float defaultValue, string description, float min = 0f, float max = 20f, bool restartRequired = false) { return BindAndOptions(section, name, defaultValue, min, max, description, restartRequired); } [MethodImpl(MethodImplOptions.NoInlining | MethodImplOptions.NoOptimization)] private static void TryRegisterOption(ConfigEntry entry, float min, float max, bool restartRequired) { //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_0028: 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_003f: Expected O, but got Unknown //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0044: Expected O, but got Unknown //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_0067: 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_007b: Expected O, but got Unknown //IL_0076: Unknown result type (might be due to invalid IL or missing references) //IL_0080: Expected O, but got Unknown //IL_0097: Unknown result type (might be due to invalid IL or missing references) //IL_00a1: Expected O, but got Unknown //IL_00b8: Unknown result type (might be due to invalid IL or missing references) //IL_00c2: Expected O, but got Unknown if (entry is ConfigEntry) { ModSettingsManager.AddOption((BaseOption)new SliderOption(entry as ConfigEntry, new SliderConfig { min = min, max = max, formatString = "{0:0.00}", restartRequired = restartRequired })); } if (entry is ConfigEntry) { ModSettingsManager.AddOption((BaseOption)new IntSliderOption(entry as ConfigEntry, new IntSliderConfig { min = (int)min, max = (int)max, restartRequired = restartRequired })); } if (entry is ConfigEntry) { ModSettingsManager.AddOption((BaseOption)new CheckBoxOption(entry as ConfigEntry, restartRequired)); } if (entry is ConfigEntry) { ModSettingsManager.AddOption((BaseOption)new KeyBindOption(entry as ConfigEntry, restartRequired)); } } public static bool GetKeyPressed(KeyboardShortcut entry) { //IL_0012: Unknown result type (might be due to invalid IL or missing references) //IL_0017: Unknown result type (might be due to invalid IL or missing references) //IL_0019: 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) foreach (KeyCode modifier in ((KeyboardShortcut)(ref entry)).Modifiers) { if (!Input.GetKey(modifier)) { return false; } } return Input.GetKeyDown(((KeyboardShortcut)(ref entry)).MainKey); } public static void InitROO(Sprite modSprite, string modDescription) { if (GhoulPlugin.rooInstalled) { _InitROO(modSprite, modDescription); } } public static void _InitROO(Sprite modSprite, string modDescription) { ModSettingsManager.SetModIcon(modSprite); ModSettingsManager.SetModDescription(modDescription); } public static bool RobGetKeyPressed(ConfigEntry entry) { //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_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_0020: Unknown result type (might be due to invalid IL or missing references) //IL_004a: Unknown result type (might be due to invalid IL or missing references) //IL_004f: Unknown result type (might be due to invalid IL or missing references) //IL_0052: Unknown result type (might be due to invalid IL or missing references) KeyboardShortcut value = entry.Value; foreach (KeyCode modifier in ((KeyboardShortcut)(ref value)).Modifiers) { if (!Input.GetKey(modifier)) { return false; } } value = entry.Value; return Input.GetKeyDown(((KeyboardShortcut)(ref value)).MainKey); } } internal class Content { internal static void AddCharacterBodyPrefab(GameObject bprefab) { ContentPacks.bodyPrefabs.Add(bprefab); } internal static void AddMasterPrefab(GameObject prefab) { ContentPacks.masterPrefabs.Add(prefab); } internal static void AddProjectilePrefab(GameObject prefab) { ContentPacks.projectilePrefabs.Add(prefab); } internal static void AddSurvivorDef(SurvivorDef survivorDef) { ContentPacks.survivorDefs.Add(survivorDef); } internal static void CreateSurvivor(GameObject bodyPrefab, GameObject displayPrefab, Color charColor, string tokenPrefix) { //IL_0003: Unknown result type (might be due to invalid IL or missing references) CreateSurvivor(bodyPrefab, displayPrefab, charColor, tokenPrefix, null, 100f); } internal static void CreateSurvivor(GameObject bodyPrefab, GameObject displayPrefab, Color charColor, string tokenPrefix, float sortPosition) { //IL_0003: Unknown result type (might be due to invalid IL or missing references) CreateSurvivor(bodyPrefab, displayPrefab, charColor, tokenPrefix, null, sortPosition); } internal static void CreateSurvivor(GameObject bodyPrefab, GameObject displayPrefab, Color charColor, string tokenPrefix, UnlockableDef unlockableDef) { //IL_0003: Unknown result type (might be due to invalid IL or missing references) CreateSurvivor(bodyPrefab, displayPrefab, charColor, tokenPrefix, unlockableDef, 100f); } internal static void CreateSurvivor(GameObject bodyPrefab, GameObject displayPrefab, Color charColor, string tokenPrefix, UnlockableDef unlockableDef, float sortPosition) { //IL_0016: 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) SurvivorDef val = ScriptableObject.CreateInstance(); val.bodyPrefab = bodyPrefab; val.displayPrefab = displayPrefab; val.primaryColor = charColor; val.cachedName = ((Object)bodyPrefab).name.Replace("Body", ""); val.displayNameToken = tokenPrefix + "NAME"; val.descriptionToken = tokenPrefix + "DESCRIPTION"; val.outroFlavorToken = tokenPrefix + "OUTRO_FLAVOR"; val.mainEndingEscapeFailureFlavorToken = tokenPrefix + "OUTRO_FAILURE"; val.desiredSortPosition = sortPosition; val.unlockableDef = unlockableDef; AddSurvivorDef(val); } internal static void AddUnlockableDef(UnlockableDef unlockableDef) { ContentPacks.unlockableDefs.Add(unlockableDef); } internal static UnlockableDef CreateAndAddUnlockbleDef(string identifier, string nameToken, Sprite achievementIcon) { UnlockableDef val = ScriptableObject.CreateInstance(); val.cachedName = identifier; val.nameToken = nameToken; val.achievementIcon = achievementIcon; AddUnlockableDef(val); return val; } internal static void AddSkillDef(SkillDef skillDef) { ContentPacks.skillDefs.Add(skillDef); } internal static void AddSkillFamily(SkillFamily skillFamily) { ContentPacks.skillFamilies.Add(skillFamily); } internal static void AddEntityState(Type entityState) { ContentPacks.entityStates.Add(entityState); } internal static void AddBuffDef(BuffDef buffDef) { ContentPacks.buffDefs.Add(buffDef); } internal static BuffDef CreateAndAddBuff(string buffName, Sprite buffIcon, Color buffColor, bool canStack, bool isDebuff) { //IL_0010: 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) BuffDef val = ScriptableObject.CreateInstance(); ((Object)val).name = buffName; val.buffColor = buffColor; val.canStack = canStack; val.isDebuff = isDebuff; val.eliteDef = null; val.iconSprite = buffIcon; AddBuffDef(val); return val; } internal static void AddEffectDef(EffectDef effectDef) { ContentPacks.effectDefs.Add(effectDef); } internal static EffectDef CreateAndAddEffectDef(GameObject effectPrefab) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown EffectDef val = new EffectDef(effectPrefab); AddEffectDef(val); return val; } internal static void AddNetworkSoundEventDef(NetworkSoundEventDef networkSoundEventDef) { ContentPacks.networkSoundEventDefs.Add(networkSoundEventDef); } internal static NetworkSoundEventDef CreateAndAddNetworkSoundEventDef(string eventName) { NetworkSoundEventDef val = ScriptableObject.CreateInstance(); val.akId = AkSoundEngine.GetIDFromString(eventName); val.eventName = eventName; AddNetworkSoundEventDef(val); return val; } } internal class ContentPacks : IContentPackProvider { internal ContentPack contentPack = new ContentPack(); public static List bodyPrefabs = new List(); public static List masterPrefabs = new List(); public static List projectilePrefabs = new List(); public static List survivorDefs = new List(); public static List unlockableDefs = new List(); public static List skillFamilies = new List(); public static List skillDefs = new List(); public static List entityStates = new List(); public static List buffDefs = new List(); public static List effectDefs = new List(); public static List networkSoundEventDefs = new List(); public string identifier => "com.vcr.GhoulSurvMod"; public void Initialize() { //IL_0008: Unknown result type (might be due to invalid IL or missing references) //IL_0012: Expected O, but got Unknown ContentManager.collectContentPackProviders += new CollectContentPackProvidersDelegate(ContentManager_collectContentPackProviders); } private void ContentManager_collectContentPackProviders(AddContentPackProviderDelegate addContentPackProvider) { addContentPackProvider.Invoke((IContentPackProvider)(object)this); } public IEnumerator LoadStaticContentAsync(LoadStaticContentAsyncArgs args) { contentPack.identifier = identifier; contentPack.bodyPrefabs.Add(bodyPrefabs.ToArray()); contentPack.masterPrefabs.Add(masterPrefabs.ToArray()); contentPack.projectilePrefabs.Add(projectilePrefabs.ToArray()); contentPack.survivorDefs.Add(survivorDefs.ToArray()); contentPack.unlockableDefs.Add(unlockableDefs.ToArray()); contentPack.skillDefs.Add(skillDefs.ToArray()); contentPack.skillFamilies.Add(skillFamilies.ToArray()); contentPack.entityStateTypes.Add(entityStates.ToArray()); contentPack.buffDefs.Add(buffDefs.ToArray()); contentPack.effectDefs.Add(effectDefs.ToArray()); contentPack.networkSoundEventDefs.Add(networkSoundEventDefs.ToArray()); args.ReportProgress(1f); yield break; } public IEnumerator GenerateContentPackAsync(GetContentPackAsyncArgs args) { ContentPack.Copy(contentPack, args.output); args.ReportProgress(1f); yield break; } public IEnumerator FinalizeAsync(FinalizeAsyncArgs args) { args.ReportProgress(1f); yield break; } } internal class Helpers { internal class SyncHeal : INetMessage, ISerializableObject { private NetworkInstanceId netId; private int healFraction; public SyncHeal() { } public SyncHeal(NetworkInstanceId netId, int healFraction) { //IL_0009: 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) this.netId = netId; this.healFraction = healFraction; } public void Deserialize(NetworkReader reader) { //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) netId = reader.ReadNetworkId(); healFraction = reader.ReadInt32(); } public void OnReceived() { //IL_0002: 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_0069: Unknown result type (might be due to invalid IL or missing references) GameObject val = Util.FindNetworkObject(netId); if (Object.op_Implicit((Object)(object)val) && (!Object.op_Implicit((Object)(object)val.GetComponent()) || val.GetComponent().isPlayerControlled)) { HealthComponent component = val.GetComponent(); if (Object.op_Implicit((Object)(object)component)) { component.HealFraction((float)healFraction * 0.01f, default(ProcChainMask)); } } } public void Serialize(NetworkWriter writer) { //IL_0003: Unknown result type (might be due to invalid IL or missing references) writer.Write(netId); writer.Write(healFraction); } } public static bool isLocalUserGhoul { get { //IL_003a: Unknown result type (might be due to invalid IL or missing references) foreach (PlayerCharacterMasterController instance in PlayerCharacterMasterController.instances) { if ((Object)(object)instance != (Object)null && (Object)(object)instance.networkUser != (Object)null) { GameObject bodyPrefab = BodyCatalog.GetBodyPrefab(instance.networkUser.bodyIndexPreference); if (Object.op_Implicit((Object)(object)bodyPrefab) && Object.op_Implicit((Object)(object)bodyPrefab.GetComponent()) && ((NetworkBehaviour)instance).hasAuthority) { return true; } } } return false; } } public static PlayerCharacterMasterController getLocalPlayer { get { foreach (PlayerCharacterMasterController instance in PlayerCharacterMasterController.instances) { if (((NetworkBehaviour)instance).hasAuthority) { return instance; } } return null; } } public static NetworkUser getLocalUser { get { foreach (PlayerCharacterMasterController instance in PlayerCharacterMasterController.instances) { if (((NetworkBehaviour)instance).hasAuthority) { return instance.networkUser; } } return null; } } } internal static class ItemDisplayCheck { public static List allDisplayedItems; public static void PrintUnused(ItemDisplayRuleSet itemDisplayRuleSet, string bodyName = "") { PrintUnused((IEnumerable)itemDisplayRuleSet.keyAssetRuleGroups.ToList(), bodyName); } public static void PrintUnused(IEnumerable ruleSet = null, string bodyName = "") { //IL_0048: Unknown result type (might be due to invalid IL or missing references) //IL_004d: Unknown result type (might be due to invalid IL or missing references) //IL_0050: 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_0069: 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_0085: Unknown result type (might be due to invalid IL or missing references) string text = "generating item displays for " + bodyName; if (allDisplayedItems == null) { LazyGatherAllItems(); } List list = new List(allDisplayedItems); string text2 = ""; if (ruleSet != null) { foreach (KeyAssetRuleGroup item in ruleSet) { if (item.displayRuleGroup.rules.Length != 0) { list.Remove(item.keyAsset); if (string.IsNullOrEmpty(text2)) { text2 = item.displayRuleGroup.rules[0].childName; } } } } if (string.IsNullOrEmpty(text2)) { text2 = "Chest"; } foreach (Object item2 in list) { string text3 = ""; if (ItemDisplays.KeyAssetDisplayPrefabs.ContainsKey(item2)) { text3 += SpitOutNewRule(item2, text2, ItemDisplays.KeyAssetDisplayPrefabs[item2]); } else { Log.Error($"COULD NOT FIND DISPLAY PREFABS FOR KEYASSET {item2}"); } text += text3; } Log.Message(text); } private static void LazyGatherAllItems() { allDisplayedItems = new List(ItemDisplays.KeyAssetDisplayPrefabs.Keys); allDisplayedItems.Sort(delegate(Object item1, Object item2) { if (item1 is ItemDef && item2 is ItemDef) { return item1.name.CompareTo(item2.name); } if (item1 is EquipmentDef && item2 is EquipmentDef) { return item1.name.CompareTo(item2.name); } if (item1 is ItemDef && item2 is EquipmentDef) { return -1; } return (item1 is EquipmentDef && item2 is ItemDef) ? 1 : 0; }); } private static string SpitOutNewRule(Object asset, string firstCompatibleChild, ItemDisplayRule[] displayRules) { //IL_0040: Unknown result type (might be due to invalid IL or missing references) //IL_0046: Invalid comparison between Unknown and I4 //IL_00a5: Unknown result type (might be due to invalid IL or missing references) if (displayRules.Length == 0) { return $"\n[NO DISPLAY RULES FOUND FOR THE KEYASSET {asset}"; } string text = "\n itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets[\"" + asset.name + "\"]"; for (int i = 0; i < displayRules.Length; i++) { text = (((int)displayRules[i].limbMask != 0) ? (text + ",\n" + $" ItemDisplays.CreateLimbMaskDisplayRule(LimbFlags.{displayRules[i].limbMask})") : (text + ",\n ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay(\"" + ((Object)displayRules[i].followerPrefab).name + "\"),\n \"" + firstCompatibleChild + "\",\n new Vector3(2, 2, 2),\n new Vector3(0, 0, 0),\n new Vector3(1, 1, 1)\n )")); } return text + "\n ));"; } } internal static class ItemDisplays { private static Dictionary itemDisplayPrefabs = new Dictionary(); public static Dictionary KeyAssetDisplayPrefabs = new Dictionary(); public static Dictionary KeyAssets = new Dictionary(); public static int queuedDisplays; public static bool initialized = false; public static void LazyInit() { if (!initialized) { initialized = true; PopulateDisplays(); } } internal static void DisposeWhenDone() { queuedDisplays--; if (queuedDisplays <= 0 && initialized) { initialized = false; itemDisplayPrefabs = null; KeyAssetDisplayPrefabs = null; KeyAssets = null; } } internal static void PopulateDisplays() { PopulateFromBody("LoaderBody"); } private static void PopulateFromBody(string bodyName) { ItemDisplayRuleSet itemDisplayRuleSet = ((Component)LegacyResourcesAPI.Load("Prefabs/CharacterBodies/" + bodyName).GetComponent().modelTransform).GetComponent().itemDisplayRuleSet; KeyAssetRuleGroup[] keyAssetRuleGroups = itemDisplayRuleSet.keyAssetRuleGroups; for (int i = 0; i < keyAssetRuleGroups.Length; i++) { ItemDisplayRule[] rules = keyAssetRuleGroups[i].displayRuleGroup.rules; KeyAssetDisplayPrefabs[keyAssetRuleGroups[i].keyAsset] = rules; KeyAssets[keyAssetRuleGroups[i].keyAsset.name] = keyAssetRuleGroups[i].keyAsset; for (int j = 0; j < rules.Length; j++) { GameObject followerPrefab = rules[j].followerPrefab; if (Object.op_Implicit((Object)(object)followerPrefab)) { string key = ((Object)followerPrefab).name?.ToLowerInvariant(); if (!itemDisplayPrefabs.ContainsKey(key)) { itemDisplayPrefabs[key] = followerPrefab; } } } } } private static void PopulateCustomLightningArm() { GameObject val = PrefabAPI.InstantiateClone(itemDisplayPrefabs["displaylightningarmright"], "DisplayLightningCustom", false); LimbMatcher component = val.GetComponent(); component.limbPairs[0].targetChildLimb = "LightningArm1"; component.limbPairs[1].targetChildLimb = "LightningArm2"; component.limbPairs[2].targetChildLimb = "LightningArmEnd"; itemDisplayPrefabs["displaylightningarmcustom"] = val; } public static GameObject LoadDisplay(string name) { if (itemDisplayPrefabs.ContainsKey(name.ToLowerInvariant()) && Object.op_Implicit((Object)(object)itemDisplayPrefabs[name.ToLowerInvariant()])) { return itemDisplayPrefabs[name.ToLowerInvariant()]; } Log.Error("item display " + name + " returned null"); return null; } public static KeyAssetRuleGroup CreateDisplayRuleGroupWithRules(string itemName, params ItemDisplayRule[] rules) { //IL_0007: Unknown result type (might be due to invalid IL or missing references) return CreateDisplayRuleGroupWithRules(GetKeyAssetFromString(itemName), rules); } public static KeyAssetRuleGroup CreateDisplayRuleGroupWithRules(Object keyAsset_, params ItemDisplayRule[] rules) { //IL_0019: 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_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_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) //IL_0043: Unknown result type (might be due to invalid IL or missing references) if (keyAsset_ == (Object)null) { Log.Error("could not find keyasset"); } KeyAssetRuleGroup result = default(KeyAssetRuleGroup); result.keyAsset = keyAsset_; result.displayRuleGroup = new DisplayRuleGroup { rules = rules }; return result; } public static ItemDisplayRule CreateDisplayRule(string prefabName, string childName, Vector3 position, Vector3 rotation, Vector3 scale) { //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_000b: Unknown result type (might be due to invalid IL or missing references) return CreateDisplayRule(LoadDisplay(prefabName), childName, position, rotation, scale); } public static ItemDisplayRule CreateDisplayRule(GameObject itemPrefab, string childName, Vector3 position, Vector3 rotation, Vector3 scale) { //IL_0003: 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) //IL_0024: 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_002c: 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_0034: 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_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_0043: 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) ItemDisplayRule result = default(ItemDisplayRule); result.ruleType = (ItemDisplayRuleType)0; result.childName = childName; result.followerPrefab = itemPrefab; result.limbMask = (LimbFlags)0; result.localPos = position; result.localAngles = rotation; result.localScale = scale; return result; } public static ItemDisplayRule CreateLimbMaskDisplayRule(LimbFlags limb) { //IL_0003: 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) //IL_0013: 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_002d: Unknown result type (might be due to invalid IL or missing references) //IL_002e: 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) ItemDisplayRule result = default(ItemDisplayRule); result.ruleType = (ItemDisplayRuleType)1; result.limbMask = limb; result.childName = ""; result.followerPrefab = null; return result; } private static Object GetKeyAssetFromString(string itemName) { Object val = (Object)(object)LegacyResourcesAPI.Load("ItemDefs/" + itemName); if (val == (Object)null) { val = (Object)(object)LegacyResourcesAPI.Load("EquipmentDefs/" + itemName); } if (val == (Object)null) { Log.Error("Could not load keyasset for " + itemName); } return val; } } internal static class Language { public static string TokensOutput = ""; public static bool usingLanguageFolder = false; public static bool printingEnabled = false; public static void Init() { if (usingLanguageFolder) { Language.collectLanguageRootFolders += Language_collectLanguageRootFolders; } } private static void Language_collectLanguageRootFolders(List obj) { string text = Path.Combine(Path.GetDirectoryName(((BaseUnityPlugin)GhoulPlugin.instance).Info.Location), "Language"); if (Directory.Exists(text)) { obj.Add(text); } } public static void Add(string token, string text) { if (!usingLanguageFolder) { LanguageAPI.Add(token, text); } if (printingEnabled) { TokensOutput = TokensOutput + "\n \"" + token + "\" : \"" + text.Replace(Environment.NewLine, "\\n").Replace("\n", "\\n") + "\","; } } public static void PrintOutput(string fileName = "") { if (printingEnabled) { string text = "{\n strings:\n {" + TokensOutput + "\n }\n}"; Log.Message(fileName + ": \n" + text); if (!string.IsNullOrEmpty(fileName)) { string path = Path.Combine(Directory.GetParent(((BaseUnityPlugin)GhoulPlugin.instance).Info.Location).FullName, "Language", "en", fileName); File.WriteAllText(path, text); } TokensOutput = ""; } } } internal static class Materials { private static List cachedMaterials = new List(); internal static Shader hotpoo = LegacyResourcesAPI.Load("Shaders/Deferred/HGStandard"); public static Material LoadMaterial(this AssetBundle assetBundle, string materialName) { return assetBundle.CreateHopooMaterialFromBundle(materialName); } public static Material CreateHopooMaterialFromBundle(this AssetBundle assetBundle, string materialName) { //IL_007e: Unknown result type (might be due to invalid IL or missing references) //IL_0084: Expected O, but got Unknown Material val = cachedMaterials.Find(delegate(Material mat) { materialName.Replace(" (Instance)", ""); return ((Object)mat).name.Contains(materialName); }); if (Object.op_Implicit((Object)(object)val)) { Log.Debug(((Object)val).name + " has already been loaded. returning cached"); return val; } val = assetBundle.LoadAsset(materialName); if (!Object.op_Implicit((Object)(object)val)) { Log.ErrorAssetBundle(materialName, ((Object)assetBundle).name); return new Material(hotpoo); } return val.ConvertDefaultShaderToHopoo(); } public static Material SetHopooMaterial(this Material tempMat) { return tempMat.ConvertDefaultShaderToHopoo(); } public static Material ConvertDefaultShaderToHopoo(this Material tempMat) { //IL_00d2: Unknown result type (might be due to invalid IL or missing references) //IL_015c: Unknown result type (might be due to invalid IL or missing references) if (cachedMaterials.Contains(tempMat)) { Log.Debug(((Object)tempMat).name + " has already been converted. returning cached"); return tempMat; } string text = ((Object)tempMat.shader).name.ToLowerInvariant(); if (!text.StartsWith("standard") && !text.StartsWith("autodesk")) { Log.Debug(((Object)tempMat).name + " is not unity standard shader. aborting material conversion"); return tempMat; } float? num = null; Color? val = null; if (tempMat.IsKeywordEnabled("_NORMALMAP")) { num = tempMat.GetFloat("_BumpScale"); } if (tempMat.IsKeywordEnabled("_EMISSION")) { val = tempMat.GetColor("_EmissionColor"); } tempMat.shader = hotpoo; tempMat.SetTexture("_EmTex", tempMat.GetTexture("_EmissionMap")); tempMat.EnableKeyword("DITHER"); if (num.HasValue) { tempMat.SetFloat("_NormalStrength", num.Value); tempMat.SetTexture("_NormalTex", tempMat.GetTexture("_BumpMap")); } if (val.HasValue) { tempMat.SetColor("_EmColor", val.Value); tempMat.SetFloat("_EmPower", 1f); } if (tempMat.IsKeywordEnabled("NOCULL")) { tempMat.SetInt("_Cull", 0); } if (tempMat.IsKeywordEnabled("LIMBREMOVAL")) { tempMat.SetInt("_LimbRemovalOn", 1); } cachedMaterials.Add(tempMat); return tempMat; } public static Material MakeUnique(this Material material) { //IL_0012: Unknown result type (might be due to invalid IL or missing references) //IL_0018: Expected O, but got Unknown if (cachedMaterials.Contains(material)) { return new Material(material); } return material; } public static Material SetColor(this Material material, Color color) { //IL_0007: Unknown result type (might be due to invalid IL or missing references) material.SetColor("_Color", color); return material; } public static Material SetNormal(this Material material, float normalStrength = 1f) { material.SetFloat("_NormalStrength", normalStrength); return material; } public static Material SetEmission(this Material material) { return material.SetEmission(1f); } public static Material SetEmission(this Material material, float emission) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) return material.SetEmission(emission, Color.white); } public static Material SetEmission(this Material material, float emission, Color emissionColor) { //IL_0014: Unknown result type (might be due to invalid IL or missing references) material.SetFloat("_EmPower", emission); material.SetColor("_EmColor", emissionColor); return material; } public static Material SetCull(this Material material, bool cull = false) { material.SetInt("_Cull", cull ? 1 : 0); return material; } public static Material SetSpecular(this Material material, float strength) { material.SetFloat("_SpecularStrength", strength); return material; } public static Material SetSpecular(this Material material, float strength, float exponent) { material.SetFloat("_SpecularStrength", strength); material.SetFloat("SpecularExponent", exponent); return material; } } internal static class Prefabs { private static PhysicMaterial ragdollMaterial; public static GameObject CreateDisplayPrefab(AssetBundle assetBundle, string displayPrefabName, GameObject prefab) { GameObject val = assetBundle.LoadAsset(displayPrefabName); if ((Object)(object)val == (Object)null) { Log.Error("could not load display prefab " + displayPrefabName + ". Make sure this prefab exists in assetbundle " + ((Object)assetBundle).name); return null; } CharacterModel val2 = val.GetComponent(); if (!Object.op_Implicit((Object)(object)val2)) { val2 = val.AddComponent(); } val2.baseRendererInfos = prefab.GetComponentInChildren().baseRendererInfos; Asset.ConvertAllRenderersToHopooShader(val); return val; } public static GameObject LoadCharacterModel(AssetBundle assetBundle, string modelName) { GameObject val = assetBundle.LoadAsset(modelName); if ((Object)(object)val == (Object)null) { Log.Error("could not load model prefab " + modelName + ". Make sure this prefab exists in assetbundle " + ((Object)assetBundle).name); return null; } return val; } public static GameObject LoadCharacterBody(AssetBundle assetBundle, string bodyName) { GameObject val = assetBundle.LoadAsset(bodyName); if ((Object)(object)val == (Object)null) { Log.Error("could not load body prefab " + bodyName + ". Make sure this prefab exists in assetbundle " + ((Object)assetBundle).name); return null; } return val; } public static GameObject CloneCharacterBody(BodyInfo bodyInfo) { GameObject val = LegacyResourcesAPI.Load("Prefabs/CharacterBodies/" + bodyInfo.bodyNameToClone + "Body"); if (!Object.op_Implicit((Object)(object)val)) { Log.Error(bodyInfo.bodyNameToClone + " Body to clone is not a valid body, character creation failed"); return null; } GameObject val2 = PrefabAPI.InstantiateClone(val, bodyInfo.bodyName); for (int num = val2.transform.childCount - 1; num >= 0; num--) { Object.DestroyImmediate((Object)(object)((Component)val2.transform.GetChild(num)).gameObject); } return val2; } public static GameObject CreateBodyPrefab(AssetBundle assetBundle, string modelPrefabName, BodyInfo bodyInfo) { return CreateBodyPrefab(LoadCharacterModel(assetBundle, modelPrefabName), bodyInfo); } public static GameObject CreateBodyPrefab(GameObject model, BodyInfo bodyInfo) { return CreateBodyPrefab(CloneCharacterBody(bodyInfo), model, bodyInfo); } public static GameObject CreateBodyPrefab(GameObject newBodyPrefab, AssetBundle assetBundle, string modelName, BodyInfo bodyInfo) { return CreateBodyPrefab(newBodyPrefab, LoadCharacterModel(assetBundle, modelName), bodyInfo); } public static GameObject CreateBodyPrefab(AssetBundle assetBundle, string bodyPrefabName, string modelPrefabName, BodyInfo bodyInfo) { return CreateBodyPrefab(LoadCharacterBody(assetBundle, bodyPrefabName), LoadCharacterModel(assetBundle, modelPrefabName), bodyInfo); } public static GameObject CreateBodyPrefab(GameObject newBodyPrefab, GameObject model, BodyInfo bodyInfo) { if ((Object)(object)model == (Object)null || (Object)(object)newBodyPrefab == (Object)null) { Log.Error($"Character creation failed. Model: {model}, Body: {newBodyPrefab}"); return null; } SetupCharacterBody(newBodyPrefab, bodyInfo); Transform modelBaseTransform = AddCharacterModelToSurvivorBody(newBodyPrefab, model.transform, bodyInfo); SetupModelLocator(newBodyPrefab, modelBaseTransform, model.transform); SetupCharacterDirection(newBodyPrefab, modelBaseTransform, model.transform); SetupCameraTargetParams(newBodyPrefab, bodyInfo); SetupCapsuleCollider(newBodyPrefab); Content.AddCharacterBodyPrefab(newBodyPrefab); return newBodyPrefab; } private static void SetupCharacterBody(GameObject newBodyPrefab, BodyInfo bodyInfo) { //IL_002e: 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_01fc: Unknown result type (might be due to invalid IL or missing references) //IL_020a: Unknown result type (might be due to invalid IL or missing references) CharacterBody component = newBodyPrefab.GetComponent(); component.baseNameToken = bodyInfo.bodyNameToken; component.subtitleNameToken = bodyInfo.subtitleNameToken; component.portraitIcon = bodyInfo.characterPortrait; component.bodyColor = bodyInfo.bodyColor; component._defaultCrosshairPrefab = bodyInfo.crosshair; component.hideCrosshair = false; component.preferredPodPrefab = bodyInfo.podPrefab; component.baseMaxHealth = bodyInfo.maxHealth; component.baseRegen = bodyInfo.healthRegen; component.baseArmor = bodyInfo.armor; component.baseMaxShield = bodyInfo.shield; component.baseDamage = bodyInfo.damage; component.baseAttackSpeed = bodyInfo.attackSpeed; component.baseCrit = bodyInfo.crit; component.baseMoveSpeed = bodyInfo.moveSpeed; component.baseJumpPower = bodyInfo.jumpPower; component.autoCalculateLevelStats = bodyInfo.autoCalculateLevelStats; if (bodyInfo.autoCalculateLevelStats) { component.levelMaxHealth = Mathf.Round(component.baseMaxHealth * 0.3f); component.levelMaxShield = Mathf.Round(component.baseMaxShield * 0.3f); component.levelRegen = component.baseRegen * 0.2f; component.levelMoveSpeed = 0f; component.levelJumpPower = 0f; component.levelDamage = component.baseDamage * 0.2f; component.levelAttackSpeed = 0f; component.levelCrit = 0f; component.levelArmor = 0f; } else { component.levelMaxHealth = bodyInfo.healthGrowth; component.levelMaxShield = bodyInfo.shieldGrowth; component.levelRegen = bodyInfo.regenGrowth; component.levelMoveSpeed = bodyInfo.moveSpeedGrowth; component.levelJumpPower = bodyInfo.jumpPowerGrowth; component.levelDamage = bodyInfo.damageGrowth; component.levelAttackSpeed = bodyInfo.attackSpeedGrowth; component.levelCrit = bodyInfo.critGrowth; component.levelArmor = bodyInfo.armorGrowth; } component.baseAcceleration = bodyInfo.acceleration; component.baseJumpCount = bodyInfo.jumpCount; component.sprintingSpeedMultiplier = 1.45f; component.bodyFlags = (BodyFlags)1; component.rootMotionInMainState = false; component.hullClassification = (HullClassification)0; component.isChampion = false; } private static Transform AddCharacterModelToSurvivorBody(GameObject bodyPrefab, Transform modelTransform, BodyInfo bodyInfo) { //IL_0063: 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_0023: 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_0049: Unknown result type (might be due to invalid IL or missing references) //IL_009e: Unknown result type (might be due to invalid IL or missing references) //IL_00b8: Unknown result type (might be due to invalid IL or missing references) //IL_00c4: Unknown result type (might be due to invalid IL or missing references) //IL_00f4: 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_011a: Unknown result type (might be due to invalid IL or missing references) Transform val = bodyPrefab.transform.Find("ModelBase"); if ((Object)(object)val == (Object)null) { val = new GameObject("ModelBase").transform; val.parent = bodyPrefab.transform; val.localPosition = bodyInfo.modelBasePosition; val.localRotation = Quaternion.identity; } modelTransform.parent = ((Component)val).transform; modelTransform.localPosition = Vector3.zero; modelTransform.localRotation = Quaternion.identity; Transform val2 = bodyPrefab.transform.Find("CameraPivot"); if ((Object)(object)val2 == (Object)null) { val2 = new GameObject("CameraPivot").transform; val2.parent = bodyPrefab.transform; val2.localPosition = bodyInfo.cameraPivotPosition; val2.localRotation = Quaternion.identity; } Transform val3 = bodyPrefab.transform.Find("AimOrigin"); if ((Object)(object)val3 == (Object)null) { val3 = new GameObject("AimOrigin").transform; val3.parent = bodyPrefab.transform; val3.localPosition = bodyInfo.aimOriginPosition; val3.localRotation = Quaternion.identity; } bodyPrefab.GetComponent().aimOriginTransform = val3; return ((Component)val).transform; } private static void SetupCharacterDirection(GameObject prefab, Transform modelBaseTransform, Transform modelTransform) { if (Object.op_Implicit((Object)(object)prefab.GetComponent())) { CharacterDirection component = prefab.GetComponent(); component.targetTransform = modelBaseTransform; component.overrideAnimatorForwardTransform = null; component.rootMotionAccumulator = null; component.modelAnimator = ((Component)modelTransform).GetComponent(); component.driveFromRootRotation = false; component.turnSpeed = 720f; } } private static void SetupCameraTargetParams(GameObject prefab, BodyInfo bodyInfo) { CameraTargetParams component = prefab.GetComponent(); component.cameraParams = bodyInfo.cameraParams; component.cameraPivotTransform = prefab.transform.Find("CameraPivot"); } private static void SetupModelLocator(GameObject prefab, Transform modelBaseTransform, Transform modelTransform) { ModelLocator component = prefab.GetComponent(); component.modelTransform = modelTransform; component.modelBaseTransform = modelBaseTransform; } private static void SetupCapsuleCollider(GameObject prefab) { //IL_0018: Unknown result type (might be due to invalid IL or missing references) CapsuleCollider component = prefab.GetComponent(); component.center = new Vector3(0f, 0f, 0f); component.radius = 0.5f; component.height = 1.82f; component.direction = 1; } public static CharacterModel SetupCharacterModel(GameObject bodyPrefab, CustomRendererInfo[] customInfos = null) { CharacterModel val = ((Component)bodyPrefab.GetComponent().modelTransform).gameObject.GetComponent(); bool flag = (Object)(object)val != (Object)null; if (!flag) { val = ((Component)bodyPrefab.GetComponent().modelTransform).gameObject.AddComponent(); } val.body = bodyPrefab.GetComponent(); val.autoPopulateLightInfos = true; val.temporaryOverlays = new List(); if (!flag) { SetupCustomRendererInfos(val, customInfos); } else { SetupPreAttachedRendererInfos(val); } SetupHurtboxGroup(bodyPrefab, ((Component)val).gameObject); SetupAimAnimator(bodyPrefab, ((Component)val).gameObject); SetupFootstepController(((Component)val).gameObject); SetupRagdoll(((Component)val).gameObject); return val; } public static void SetupPreAttachedRendererInfos(CharacterModel characterModel) { for (int i = 0; i < characterModel.baseRendererInfos.Length; i++) { if ((Object)(object)characterModel.baseRendererInfos[i].defaultMaterial == (Object)null) { characterModel.baseRendererInfos[i].defaultMaterial = characterModel.baseRendererInfos[i].renderer.sharedMaterial; } if ((Object)(object)characterModel.baseRendererInfos[i].defaultMaterial == (Object)null) { Log.Error($"no material for rendererinfo of this renderer: {characterModel.baseRendererInfos[i].renderer}"); } characterModel.baseRendererInfos[i].defaultMaterial.ConvertDefaultShaderToHopoo(); } } public static void SetupCustomRendererInfos(CharacterModel characterModel, CustomRendererInfo[] customInfos) { //IL_00de: 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) ChildLocator component = ((Component)characterModel).GetComponent(); if (!Object.op_Implicit((Object)(object)component)) { Log.Error("Failed CharacterModel setup: ChildLocator component does not exist on the model"); return; } List list = new List(); for (int i = 0; i < customInfos.Length; i++) { if (!Object.op_Implicit((Object)(object)component.FindChild(customInfos[i].childName))) { Log.Error("Trying to add a RendererInfo for a renderer that does not exist: " + customInfos[i].childName); continue; } Renderer component2 = ((Component)component.FindChild(customInfos[i].childName)).GetComponent(); if (Object.op_Implicit((Object)(object)component2)) { Material val = customInfos[i].material; if ((Object)(object)val == (Object)null) { val = ((!customInfos[i].dontHotpoo) ? component2.sharedMaterial.ConvertDefaultShaderToHopoo() : component2.sharedMaterial); } list.Add(new RendererInfo { renderer = component2, defaultMaterial = val, ignoreOverlays = customInfos[i].ignoreOverlays, defaultShadowCastingMode = (ShadowCastingMode)1 }); } } characterModel.baseRendererInfos = list.ToArray(); } private static void SetupHurtboxGroup(GameObject bodyPrefab, GameObject model) { SetupMainHurtboxesFromChildLocator(bodyPrefab, model); SetHurtboxesHealthComponents(bodyPrefab); } private static void SetupMainHurtboxesFromChildLocator(GameObject bodyPrefab, GameObject model) { //IL_011b: 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) if ((Object)(object)bodyPrefab.GetComponent() != (Object)null) { Log.Debug("Hitboxgroup already exists on model prefab. aborting code setup"); return; } ChildLocator component = model.GetComponent(); if (string.IsNullOrEmpty(component.FindChildNameInsensitive("MainHurtbox"))) { Log.Error("Could not set up main hurtbox: make sure you have a transform pair in your prefab's ChildLocator called 'MainHurtbox'"); return; } HurtBoxGroup val = model.AddComponent(); HurtBox val2 = null; GameObject val3 = component.FindChildGameObjectInsensitive("HeadHurtbox"); if (Object.op_Implicit((Object)(object)val3)) { Log.Debug("HeadHurtboxFound. Setting up"); val2 = val3.AddComponent(); ((Component)val2).gameObject.layer = LayerIndex.entityPrecise.intVal; val2.healthComponent = bodyPrefab.GetComponent(); val2.isBullseye = false; val2.isSniperTarget = true; val2.damageModifier = (DamageModifier)0; val2.hurtBoxGroup = val; val2.indexInGroup = 1; } HurtBox val4 = component.FindChildGameObjectInsensitive("MainHurtbox").AddComponent(); ((Component)val4).gameObject.layer = LayerIndex.entityPrecise.intVal; val4.healthComponent = bodyPrefab.GetComponent(); val4.isBullseye = true; val4.isSniperTarget = (Object)(object)val2 == (Object)null; val4.damageModifier = (DamageModifier)0; val4.hurtBoxGroup = val; val4.indexInGroup = 0; if (Object.op_Implicit((Object)(object)val2)) { val.hurtBoxes = (HurtBox[])(object)new HurtBox[2] { val4, val2 }; } else { val.hurtBoxes = (HurtBox[])(object)new HurtBox[1] { val4 }; } val.mainHurtBox = val4; val.bullseyeCount = 1; } private static string FindChildNameInsensitive(this ChildLocator childLocator, string child) { //IL_0025: Unknown result type (might be due to invalid IL or missing references) return childLocator.transformPairs.Where((NameTransformPair pair) => pair.name.ToLowerInvariant() == child.ToLowerInvariant()).FirstOrDefault().name; } private static Transform FindChildInsensitive(this ChildLocator childLocator, string child) { return childLocator.FindChild(childLocator.FindChildNameInsensitive(child)); } private static GameObject FindChildGameObjectInsensitive(this ChildLocator childLocator, string child) { return childLocator.FindChildGameObject(childLocator.FindChildNameInsensitive(child)); } public static void SetHurtboxesHealthComponents(GameObject bodyPrefab) { HealthComponent component = bodyPrefab.GetComponent(); HurtBoxGroup[] componentsInChildren = bodyPrefab.GetComponentsInChildren(); foreach (HurtBoxGroup val in componentsInChildren) { val.mainHurtBox.healthComponent = component; for (int j = 0; j < val.hurtBoxes.Length; j++) { val.hurtBoxes[j].healthComponent = component; } } } private static void SetupFootstepController(GameObject model) { FootstepHandler val = model.AddComponent(); val.baseFootstepString = "Play_player_footstep"; val.sprintFootstepOverrideString = ""; val.enableFootstepDust = true; val.footstepDustPrefab = LegacyResourcesAPI.Load("Prefabs/GenericFootstepDust"); } private static void SetupRagdoll(GameObject model) { RagdollController component = model.GetComponent(); if (!Object.op_Implicit((Object)(object)component)) { return; } if ((Object)(object)ragdollMaterial == (Object)null) { ragdollMaterial = ((Component)LegacyResourcesAPI.Load("Prefabs/CharacterBodies/CommandoBody").GetComponentInChildren().bones[1]).GetComponent().material; } Transform[] bones = component.bones; foreach (Transform val in bones) { if (Object.op_Implicit((Object)(object)val)) { ((Component)val).gameObject.layer = LayerIndex.ragdoll.intVal; Collider component2 = ((Component)val).GetComponent(); if (Object.op_Implicit((Object)(object)component2)) { component2.sharedMaterial = ragdollMaterial; } else { Log.Error($"Ragdoll bone {((Component)val).gameObject} doesn't have a collider. Ragdoll will break."); } } } } private static void SetupAimAnimator(GameObject prefab, GameObject model) { AimAnimator val = model.AddComponent(); val.directionComponent = prefab.GetComponent(); val.pitchRangeMax = 60f; val.pitchRangeMin = -60f; val.yawRangeMin = -80f; val.yawRangeMax = 80f; val.pitchGiveupRange = 30f; val.yawGiveupRange = 10f; val.giveupDuration = 3f; val.inputBank = prefab.GetComponent(); } public static void CreateGenericDoppelganger(GameObject bodyPrefab, string masterName, string masterToCopy) { CloneDopplegangerMaster(bodyPrefab, masterName, masterToCopy); } public static GameObject CloneDopplegangerMaster(GameObject bodyPrefab, string masterName, string masterToCopy) { GameObject val = PrefabAPI.InstantiateClone(LegacyResourcesAPI.Load("Prefabs/CharacterMasters/" + masterToCopy + "MonsterMaster"), masterName, true); val.GetComponent().bodyPrefab = bodyPrefab; Content.AddMasterPrefab(val); return val; } public static GameObject CreateBlankMasterPrefab(GameObject bodyPrefab, string masterName) { GameObject val = PrefabAPI.InstantiateClone(LegacyResourcesAPI.Load("Prefabs/CharacterMasters/CommandoMonsterMaster"), masterName, true); ContentPacks.masterPrefabs.Add(val); CharacterMaster component = val.GetComponent(); component.bodyPrefab = bodyPrefab; AISkillDriver[] components = val.GetComponents(); for (int i = 0; i < components.Length; i++) { Object.Destroy((Object)(object)components[i]); } return val; } public static GameObject LoadMaster(this AssetBundle assetBundle, GameObject bodyPrefab, string assetName) { //IL_0047: 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) GameObject val = assetBundle.LoadAsset(assetName); BaseAI val2 = val.GetComponent(); if ((Object)(object)val2 == (Object)null) { val2 = val.AddComponent(); val2.aimVectorDampTime = 0.1f; val2.aimVectorMaxSpeed = 360f; } val2.scanState = new SerializableEntityStateType(typeof(Wander)); EntityStateMachine component = val.GetComponent(); if ((Object)(object)component == (Object)null) { AddEntityStateMachine(val, "AI", typeof(Wander), typeof(Wander)); } val2.stateMachine = component; CharacterMaster val3 = val.GetComponent(); if ((Object)(object)val3 == (Object)null) { val3 = val.AddComponent(); } val3.bodyPrefab = bodyPrefab; val3.teamIndex = (TeamIndex)2; Content.AddMasterPrefab(val); return val; } public static void ClearEntityStateMachines(GameObject bodyPrefab) { EntityStateMachine[] components = bodyPrefab.GetComponents(); for (int num = components.Length - 1; num >= 0; num--) { Object.DestroyImmediate((Object)(object)components[num]); } NetworkStateMachine component = bodyPrefab.GetComponent(); component.stateMachines = Array.Empty(); CharacterDeathBehavior component2 = bodyPrefab.GetComponent(); if (Object.op_Implicit((Object)(object)component2)) { component2.idleStateMachine = Array.Empty(); } SetStateOnHurt component3 = bodyPrefab.GetComponent(); if (Object.op_Implicit((Object)(object)component3)) { component3.idleStateMachine = Array.Empty(); } CharacterBody component4 = bodyPrefab.GetComponent(); if (Object.op_Implicit((Object)(object)component4)) { component4.vehicleIdleStateMachine = Array.Empty(); } } public static EntityStateMachine AddEntityStateMachine(GameObject prefab, string machineName, Type mainStateType = null, Type initalStateType = null, bool addToHurt = true, bool addToDeath = true) { //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_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) EntityStateMachine val = EntityStateMachine.FindByCustomName(prefab, machineName); if ((Object)(object)val == (Object)null) { val = prefab.AddComponent(); } else { Log.Message("An Entity State Machine already exists with the name " + machineName + ". replacing."); } val.customName = machineName; if (mainStateType == null) { mainStateType = typeof(Idle); } val.mainStateType = new SerializableEntityStateType(mainStateType); if (initalStateType == null) { initalStateType = typeof(Idle); } val.initialStateType = new SerializableEntityStateType(initalStateType); NetworkStateMachine component = prefab.GetComponent(); if (Object.op_Implicit((Object)(object)component)) { component.stateMachines = component.stateMachines.Append(val).ToArray(); } CharacterDeathBehavior component2 = prefab.GetComponent(); if (Object.op_Implicit((Object)(object)component2) && addToDeath) { component2.idleStateMachine = component2.idleStateMachine.Append(val).ToArray(); } SetStateOnHurt component3 = prefab.GetComponent(); if (Object.op_Implicit((Object)(object)component3) && addToHurt) { component3.idleStateMachine = component3.idleStateMachine.Append(val).ToArray(); } return val; } public static EntityStateMachine AddMainEntityStateMachine(GameObject bodyPrefab, string machineName = "Body", Type mainStateType = null, Type initalStateType = null) { //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_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) EntityStateMachine val = EntityStateMachine.FindByCustomName(bodyPrefab, machineName); if ((Object)(object)val == (Object)null) { val = bodyPrefab.AddComponent(); } else { Log.Message("An Entity State Machine already exists with the name " + machineName + ". replacing."); } val.customName = machineName; if (mainStateType == null) { mainStateType = typeof(GenericCharacterMain); } val.mainStateType = new SerializableEntityStateType(mainStateType); if (initalStateType == null) { initalStateType = typeof(SpawnTeleporterState); } val.initialStateType = new SerializableEntityStateType(initalStateType); NetworkStateMachine component = bodyPrefab.GetComponent(); if (Object.op_Implicit((Object)(object)component)) { component.stateMachines = component.stateMachines.Append(val).ToArray(); } CharacterDeathBehavior component2 = bodyPrefab.GetComponent(); if (Object.op_Implicit((Object)(object)component2)) { component2.deathStateMachine = val; } SetStateOnHurt component3 = bodyPrefab.GetComponent(); if (Object.op_Implicit((Object)(object)component3)) { component3.targetStateMachine = val; } return val; } public static void SetupHitBoxGroup(GameObject modelPrefab, string hitBoxGroupName, params string[] hitboxChildNames) { ChildLocator component = modelPrefab.GetComponent(); Transform[] array = (Transform[])(object)new Transform[hitboxChildNames.Length]; for (int i = 0; i < hitboxChildNames.Length; i++) { array[i] = component.FindChild(hitboxChildNames[i]); if ((Object)(object)array[i] == (Object)null) { Log.Error("missing hitbox for " + hitboxChildNames[i]); } } SetupHitBoxGroup(modelPrefab, hitBoxGroupName, array); } public static void SetupHitBoxGroup(GameObject prefab, string hitBoxGroupName, params Transform[] hitBoxTransforms) { List list = new List(); foreach (Transform val in hitBoxTransforms) { if ((Object)(object)val == (Object)null) { Log.Error("Error setting up hitboxGroup for " + hitBoxGroupName + ": hitbox transform was null"); continue; } HitBox item = ((Component)val).gameObject.AddComponent(); ((Component)val).gameObject.layer = LayerIndex.projectile.intVal; list.Add(item); } if (list.Count == 0) { Log.Error("No hitboxes were set up. aborting setting up hitboxGroup for " + hitBoxGroupName); return; } HitBoxGroup val2 = prefab.AddComponent(); val2.hitBoxes = list.ToArray(); val2.groupName = hitBoxGroupName; } } public class CustomRendererInfo { public string childName; public Material material = null; public bool dontHotpoo = false; public bool ignoreOverlays = false; } internal static class Skills { public static void CreateSkillFamilies(GameObject targetPrefab) { SkillSlot[] array = new SkillSlot[4]; RuntimeHelpers.InitializeArray(array, (RuntimeFieldHandle)/*OpCode not supported: LdMemberToken*/); CreateSkillFamilies(targetPrefab, (SkillSlot[])(object)array); } public static void CreateSkillFamilies(GameObject targetPrefab, params SkillSlot[] slots) { //IL_0010: 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_0015: Unknown result type (might be due to invalid IL or missing references) //IL_002f: Expected I4, but got Unknown SkillLocator component = targetPrefab.GetComponent(); foreach (SkillSlot val in slots) { SkillSlot val2 = val; switch (val2 - -1) { case 1: component.primary = CreateGenericSkillWithSkillFamily(targetPrefab, "Primary"); break; case 2: component.secondary = CreateGenericSkillWithSkillFamily(targetPrefab, "Secondary"); break; case 3: component.utility = CreateGenericSkillWithSkillFamily(targetPrefab, "Utility"); break; case 4: component.special = CreateGenericSkillWithSkillFamily(targetPrefab, "Special"); break; } } } public static void ClearGenericSkills(GameObject targetPrefab) { GenericSkill[] componentsInChildren = targetPrefab.GetComponentsInChildren(); foreach (GenericSkill val in componentsInChildren) { Object.DestroyImmediate((Object)(object)val); } } public static GenericSkill CreateGenericSkillWithSkillFamily(GameObject targetPrefab, SkillSlot skillSlot, bool hidden = false) { //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_000a: 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_000c: 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_0028: Expected I4, but got Unknown SkillLocator component = targetPrefab.GetComponent(); switch (skillSlot - -1) { case 1: return component.primary = CreateGenericSkillWithSkillFamily(targetPrefab, "Primary", hidden); case 2: return component.secondary = CreateGenericSkillWithSkillFamily(targetPrefab, "Secondary", hidden); case 3: return component.utility = CreateGenericSkillWithSkillFamily(targetPrefab, "Utility", hidden); case 4: return component.special = CreateGenericSkillWithSkillFamily(targetPrefab, "Special", hidden); case 0: Log.Error("Failed to create GenericSkill with skillslot None. If making a GenericSkill outside of the main 4, specify a familyName, and optionally a genericSkillName"); return null; default: return null; } } public static GenericSkill CreateGenericSkillWithSkillFamily(GameObject targetPrefab, string familyName, bool hidden = false) { return CreateGenericSkillWithSkillFamily(targetPrefab, familyName, familyName, hidden); } public static GenericSkill CreateGenericSkillWithSkillFamily(GameObject targetPrefab, string genericSkillName, string familyName, bool hidden = false) { GenericSkill val = targetPrefab.AddComponent(); val.skillName = genericSkillName; val.hideInCharacterSelect = hidden; SkillFamily val2 = ScriptableObject.CreateInstance(); ((Object)val2).name = ((Object)targetPrefab).name + familyName + "Family"; val2.variants = (Variant[])(object)new Variant[0]; val._skillFamily = val2; Content.AddSkillFamily(val2); return val; } public static void AddSkillToFamily(SkillFamily skillFamily, SkillDef skillDef, UnlockableDef unlockableDef = null) { //IL_0029: 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) 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, unlockableDef = unlockableDef }; ((Variant)(ref val)).viewableNode = new Node(skillDef.skillNameToken, false, (Node)null); variants[num] = val; } public static void AddSkillsToFamily(SkillFamily skillFamily, params SkillDef[] skillDefs) { foreach (SkillDef skillDef in skillDefs) { AddSkillToFamily(skillFamily, skillDef); } } public static void AddPrimarySkills(GameObject targetPrefab, params SkillDef[] skillDefs) { AddSkillsToFamily(targetPrefab.GetComponent().primary.skillFamily, skillDefs); } public static void AddSecondarySkills(GameObject targetPrefab, params SkillDef[] skillDefs) { AddSkillsToFamily(targetPrefab.GetComponent().secondary.skillFamily, skillDefs); } public static void AddUtilitySkills(GameObject targetPrefab, params SkillDef[] skillDefs) { AddSkillsToFamily(targetPrefab.GetComponent().utility.skillFamily, skillDefs); } public static void AddSpecialSkills(GameObject targetPrefab, params SkillDef[] skillDefs) { AddSkillsToFamily(targetPrefab.GetComponent().special.skillFamily, skillDefs); } public static void AddUnlockablesToFamily(SkillFamily skillFamily, params UnlockableDef[] unlockableDefs) { //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_0024: 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) for (int i = 0; i < unlockableDefs.Length; i++) { Variant val = skillFamily.variants[i]; val.unlockableDef = unlockableDefs[i]; skillFamily.variants[i] = val; } } public static SkillDef CreateSkillDef(SkillDefInfo skillDefInfo) { return Skills.CreateSkillDef(skillDefInfo); } public static T CreateSkillDef(SkillDefInfo skillDefInfo) where T : SkillDef { //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_0086: 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) T val = ScriptableObject.CreateInstance(); ((SkillDef)val).skillName = skillDefInfo.skillName; ((Object)(object)val).name = skillDefInfo.skillName; ((SkillDef)val).skillNameToken = skillDefInfo.skillNameToken; ((SkillDef)val).skillDescriptionToken = skillDefInfo.skillDescriptionToken; ((SkillDef)val).icon = skillDefInfo.skillIcon; ((SkillDef)val).activationState = skillDefInfo.activationState; ((SkillDef)val).activationStateMachineName = skillDefInfo.activationStateMachineName; ((SkillDef)val).interruptPriority = skillDefInfo.interruptPriority; ((SkillDef)val).baseMaxStock = skillDefInfo.baseMaxStock; ((SkillDef)val).baseRechargeInterval = skillDefInfo.baseRechargeInterval; ((SkillDef)val).rechargeStock = skillDefInfo.rechargeStock; ((SkillDef)val).requiredStock = skillDefInfo.requiredStock; ((SkillDef)val).stockToConsume = skillDefInfo.stockToConsume; ((SkillDef)val).dontAllowPastMaxStocks = skillDefInfo.dontAllowPastMaxStocks; ((SkillDef)val).beginSkillCooldownOnSkillEnd = skillDefInfo.beginSkillCooldownOnSkillEnd; ((SkillDef)val).canceledFromSprinting = skillDefInfo.canceledFromSprinting; ((SkillDef)val).forceSprintDuringState = skillDefInfo.forceSprintDuringState; ((SkillDef)val).fullRestockOnAssign = skillDefInfo.fullRestockOnAssign; ((SkillDef)val).resetCooldownTimerOnUse = skillDefInfo.resetCooldownTimerOnUse; ((SkillDef)val).isCombatSkill = skillDefInfo.isCombatSkill; ((SkillDef)val).mustKeyPress = skillDefInfo.mustKeyPress; ((SkillDef)val).cancelSprintingOnActivation = skillDefInfo.cancelSprintingOnActivation; ((SkillDef)val).keywordTokens = skillDefInfo.keywordTokens; Content.AddSkillDef((SkillDef)(object)val); return val; } } internal class SkillDefInfo { public string skillName; public string skillNameToken; public string skillDescriptionToken; public string[] keywordTokens = Array.Empty(); public Sprite skillIcon; public SerializableEntityStateType activationState; public string activationStateMachineName; public InterruptPriority interruptPriority; public float baseRechargeInterval; public int baseMaxStock = 1; public int rechargeStock = 1; public int requiredStock = 1; public int stockToConsume = 1; public bool resetCooldownTimerOnUse = false; public bool fullRestockOnAssign = true; public bool dontAllowPastMaxStocks = false; public bool beginSkillCooldownOnSkillEnd = false; public bool mustKeyPress = false; public bool isCombatSkill = true; public bool canceledFromSprinting = false; public bool cancelSprintingOnActivation = true; public bool forceSprintDuringState = false; public SkillDefInfo() { } public SkillDefInfo(string skillName, string skillNameToken, string skillDescriptionToken, Sprite skillIcon, SerializableEntityStateType activationState, string activationStateMachineName = "Weapon", bool agile = false) { //IL_008c: 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_00c2: Unknown result type (might be due to invalid IL or missing references) this.skillName = skillName; this.skillNameToken = skillNameToken; this.skillDescriptionToken = skillDescriptionToken; this.skillIcon = skillIcon; this.activationState = activationState; this.activationStateMachineName = activationStateMachineName; cancelSprintingOnActivation = !agile; if (agile) { keywordTokens = new string[1] { "KEYWORD_AGILE" }; } interruptPriority = (InterruptPriority)0; isCombatSkill = true; baseRechargeInterval = 0f; requiredStock = 0; stockToConsume = 0; } } internal static class Skins { internal struct SkinDefInfo { internal SkinDef[] BaseSkins; internal Sprite Icon; internal string NameToken; internal UnlockableDef UnlockableDef; internal GameObject RootObject; internal RendererInfo[] RendererInfos; internal MeshReplacement[] MeshReplacements; internal GameObjectActivation[] GameObjectActivations; internal ProjectileGhostReplacement[] ProjectileGhostReplacements; internal MinionSkinReplacement[] MinionSkinReplacements; internal string Name; } internal static SkinDef CreateSkinDef(string skinName, Sprite skinIcon, RendererInfo[] defaultRendererInfos, GameObject root, UnlockableDef unlockableDef = null) { //IL_008a: Unknown result type (might be due to invalid IL or missing references) //IL_0094: Expected O, but got Unknown //IL_0135: Unknown result type (might be due to invalid IL or missing references) //IL_013f: Expected O, but got Unknown SkinDefInfo skinDefInfo = default(SkinDefInfo); skinDefInfo.BaseSkins = Array.Empty(); skinDefInfo.GameObjectActivations = (GameObjectActivation[])(object)new GameObjectActivation[0]; skinDefInfo.Icon = skinIcon; skinDefInfo.MeshReplacements = (MeshReplacement[])(object)new MeshReplacement[0]; skinDefInfo.MinionSkinReplacements = (MinionSkinReplacement[])(object)new MinionSkinReplacement[0]; skinDefInfo.Name = skinName; skinDefInfo.NameToken = skinName; skinDefInfo.ProjectileGhostReplacements = (ProjectileGhostReplacement[])(object)new ProjectileGhostReplacement[0]; skinDefInfo.RendererInfos = (RendererInfo[])(object)new RendererInfo[defaultRendererInfos.Length]; skinDefInfo.RootObject = root; skinDefInfo.UnlockableDef = unlockableDef; SkinDefInfo skinDefInfo2 = skinDefInfo; SkinDef.Awake += new hook_Awake(DoNothing); SkinDef val = ScriptableObject.CreateInstance(); val.baseSkins = skinDefInfo2.BaseSkins; val.icon = skinDefInfo2.Icon; val.unlockableDef = skinDefInfo2.UnlockableDef; val.rootObject = skinDefInfo2.RootObject; defaultRendererInfos.CopyTo(skinDefInfo2.RendererInfos, 0); val.rendererInfos = skinDefInfo2.RendererInfos; val.gameObjectActivations = skinDefInfo2.GameObjectActivations; val.meshReplacements = skinDefInfo2.MeshReplacements; val.projectileGhostReplacements = skinDefInfo2.ProjectileGhostReplacements; val.minionSkinReplacements = skinDefInfo2.MinionSkinReplacements; val.nameToken = skinDefInfo2.NameToken; ((Object)val).name = skinDefInfo2.Name; SkinDef.Awake -= new hook_Awake(DoNothing); return val; } private static void DoNothing(orig_Awake orig, SkinDef self) { } private static RendererInfo[] getRendererMaterials(RendererInfo[] defaultRenderers, params Material[] materials) { RendererInfo[] array = (RendererInfo[])(object)new RendererInfo[defaultRenderers.Length]; defaultRenderers.CopyTo(array, 0); for (int i = 0; i < array.Length; i++) { try { array[i].defaultMaterial = materials[i]; } catch { Log.Error("error adding skin rendererinfo material. make sure you're not passing in too many"); } } return array; } internal static MeshReplacement[] getMeshReplacements(AssetBundle assetBundle, RendererInfo[] defaultRendererInfos, params string[] meshes) { //IL_001d: 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) List list = new List(); for (int i = 0; i < defaultRendererInfos.Length; i++) { if (!string.IsNullOrEmpty(meshes[i])) { list.Add(new MeshReplacement { renderer = defaultRendererInfos[i].renderer, mesh = assetBundle.LoadAsset(meshes[i]) }); } } return list.ToArray(); } } internal static class Tokens { public const string agilePrefix = "Agile."; public static string DamageText(string text) { return "" + text + ""; } public static string DamageValueText(float value) { return $"{value * 100f}% damage"; } public static string UtilityText(string text) { return "" + text + ""; } public static string RedText(string text) { return HealthText(text); } public static string HealthText(string text) { return "" + text + ""; } public static string KeywordText(string keyword, string sub) { return "" + keyword + "" + sub + ""; } public static string ScepterDescription(string desc) { return "\nSCEPTER: " + desc + ""; } public static string GetAchievementNameToken(string identifier) { return "ACHIEVEMENT_" + identifier.ToUpperInvariant() + "_NAME"; } public static string GetAchievementDescriptionToken(string identifier) { return "ACHIEVEMENT_" + identifier.ToUpperInvariant() + "_DESCRIPTION"; } } } namespace GhoulMod.Modules.Characters { public abstract class CharacterBase where T : CharacterBase, new() { public abstract string assetBundleName { get; } public abstract string bodyName { get; } public abstract string modelPrefabName { get; } public abstract BodyInfo bodyInfo { get; } public virtual CustomRendererInfo[] customRendererInfos { get; } public virtual ItemDisplaysBase itemDisplays { get; } public static T instance { get; private set; } public abstract AssetBundle assetBundle { get; protected set; } public abstract GameObject bodyPrefab { get; protected set; } public abstract CharacterBody prefabCharacterBody { get; protected set; } public abstract GameObject characterModelObject { get; protected set; } public abstract CharacterModel prefabCharacterModel { get; protected set; } public virtual void Initialize() { instance = this as T; assetBundle = Asset.LoadAssetBundle(assetBundleName); InitializeCharacter(); } public virtual void InitializeCharacter() { InitializeCharacterBodyPrefab(); InitializeItemDisplays(); } protected virtual void InitializeCharacterBodyPrefab() { characterModelObject = Prefabs.LoadCharacterModel(assetBundle, modelPrefabName); bodyPrefab = Prefabs.CreateBodyPrefab(characterModelObject, bodyInfo); prefabCharacterBody = bodyPrefab.GetComponent(); prefabCharacterModel = Prefabs.SetupCharacterModel(bodyPrefab, customRendererInfos); } public virtual void InitializeItemDisplays() { ItemDisplayRuleSet val = ScriptableObject.CreateInstance(); ((Object)val).name = "idrs" + bodyName; prefabCharacterModel.itemDisplayRuleSet = val; if (itemDisplays != null) { ItemDisplays.queuedDisplays++; ContentManager.onContentPacksAssigned += SetItemDisplays; } } public void SetItemDisplays(ReadOnlyArray obj) { itemDisplays.SetItemDisplays(prefabCharacterModel.itemDisplayRuleSet); } public abstract void InitializeEntityStateMachines(); public abstract void InitializeSkills(); public abstract void InitializeSkins(); public abstract void InitializeCharacterMaster(); } public class BodyInfo { public string bodyName = ""; public string bodyNameToken = ""; public string subtitleNameToken = ""; public string bodyNameToClone = "Commando"; public Color bodyColor = Color.white; public Texture characterPortrait = null; public float sortPosition = 100f; public GameObject crosshair = null; public GameObject podPrefab = null; public float maxHealth = 100f; public float healthRegen = 1f; public float armor = 0f; public float shield = 0f; public int jumpCount = 1; public float damage = 12f; public float attackSpeed = 1f; public float crit = 1f; public float moveSpeed = 7f; public float acceleration = 80f; public float jumpPower = 15f; public bool autoCalculateLevelStats = true; public float healthGrowth = 30.000002f; public float regenGrowth = 0.2f; public float armorGrowth = 0f; public float shieldGrowth = 0f; public float damageGrowth = 2.4f; public float attackSpeedGrowth = 0f; public float critGrowth = 0f; public float moveSpeedGrowth = 0f; public float jumpPowerGrowth = 0f; public Vector3 aimOriginPosition = new Vector3(0f, 1.6f, 0f); public Vector3 modelBasePosition = new Vector3(0f, -0.92f, 0f); public Vector3 cameraPivotPosition = new Vector3(0f, 0.8f, 0f); public float cameraParamsVerticalOffset = 1.37f; public float cameraParamsDepth = -10f; private CharacterCameraParams _cameraParams; public CharacterCameraParams cameraParams { get { //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_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_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_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_00a4: 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) if ((Object)(object)_cameraParams == (Object)null) { _cameraParams = ScriptableObject.CreateInstance(); _cameraParams.data.minPitch = BlendableFloat.op_Implicit(-70f); _cameraParams.data.maxPitch = BlendableFloat.op_Implicit(70f); _cameraParams.data.wallCushion = BlendableFloat.op_Implicit(0.1f); _cameraParams.data.pivotVerticalOffset = BlendableFloat.op_Implicit(cameraParamsVerticalOffset); _cameraParams.data.idealLocalCameraPos = BlendableVector3.op_Implicit(new Vector3(0f, 0f, cameraParamsDepth)); } return _cameraParams; } set { _cameraParams = value; } } } public abstract class ItemDisplaysBase { public void SetItemDisplays(ItemDisplayRuleSet itemDisplayRuleSet) { List list = new List(); ItemDisplays.LazyInit(); SetItemDisplayRules(list); itemDisplayRuleSet.keyAssetRuleGroups = list.ToArray(); ItemDisplays.DisposeWhenDone(); } protected abstract void SetItemDisplayRules(List itemDisplayRules); } public abstract class SurvivorBase : CharacterBase where T : SurvivorBase, new() { public abstract string masterName { get; } public abstract string displayPrefabName { get; } public abstract string survivorTokenPrefix { get; } public abstract UnlockableDef characterUnlockableDef { get; } public abstract GameObject displayPrefab { get; protected set; } public override void InitializeCharacter() { base.InitializeCharacter(); InitializeDisplayPrefab(); InitializeSurvivor(); } protected virtual void InitializeDisplayPrefab() { displayPrefab = Prefabs.CreateDisplayPrefab(assetBundle, displayPrefabName, bodyPrefab); } protected virtual void InitializeSurvivor() { //IL_0013: Unknown result type (might be due to invalid IL or missing references) Content.CreateSurvivor(bodyPrefab, displayPrefab, bodyInfo.bodyColor, survivorTokenPrefix, characterUnlockableDef, bodyInfo.sortPosition); } protected virtual void AddCssPreviewSkill(int indexFromEditor, SkillFamily skillFamily, SkillDef skillDef) { CharacterSelectSurvivorPreviewDisplayController component = displayPrefab.GetComponent(); if (!Object.op_Implicit((Object)(object)component)) { Log.Error("trying to add skillChangeResponse to null CharacterSelectSurvivorPreviewDisplayController.\nMake sure you created one on your Display prefab in editor"); return; } component.skillChangeResponses[indexFromEditor].triggerSkillFamily = skillFamily; component.skillChangeResponses[indexFromEditor].triggerSkill = skillDef; } protected virtual void AddCssPreviewSkin(int indexFromEditor, SkinDef skinDef) { CharacterSelectSurvivorPreviewDisplayController component = displayPrefab.GetComponent(); if (!Object.op_Implicit((Object)(object)component)) { Log.Error("trying to add skinChangeResponse to null CharacterSelectSurvivorPreviewDisplayController.\nMake sure you created one on your Display prefab in editor"); } else { component.skinChangeResponses[indexFromEditor].triggerSkin = skinDef; } } protected virtual void FinalizeCSSPreviewDisplayController() { //IL_0073: Unknown result type (might be due to invalid IL or missing references) if (!Object.op_Implicit((Object)(object)displayPrefab)) { return; } CharacterSelectSurvivorPreviewDisplayController component = displayPrefab.GetComponent(); if (!Object.op_Implicit((Object)(object)component)) { return; } component.bodyPrefab = bodyPrefab; List list = new List(); for (int i = 0; i < component.skillChangeResponses.Length; i++) { if ((Object)(object)component.skillChangeResponses[i].triggerSkillFamily != (Object)null) { list.Add(component.skillChangeResponses[i]); } } component.skillChangeResponses = list.ToArray(); } } } namespace GhoulMod.Modules.BaseStates { public abstract class BaseMeleeAttack : GhoulBaseSkillState, IStepSetter { public int swingIndex; protected string hitboxGroupName = "SwordGroup"; protected DamageTypeCombo damageType = DamageTypeCombo.op_Implicit((DamageType)0); protected float damageCoefficient = 3.5f; protected float procCoefficient = 1f; protected float pushForce = 300f; protected Vector3 bonusForce = Vector3.zero; protected float baseDuration = 1f; protected float attackStartPercentTime = 0.2f; protected float attackEndPercentTime = 0.4f; protected float earlyExitPercentTime = 0.4f; protected float hitStopDuration = 0.012f; protected float attackRecoil = 0.75f; protected float hitHopVelocity = 4f; protected string swingSoundString = ""; protected string hitSoundString = ""; protected string muzzleString = "SwingCenter"; protected string playbackRateParam = "Slash.playbackRate"; protected GameObject swingEffectPrefab; protected GameObject hitEffectPrefab; protected NetworkSoundEventIndex impactSound = (NetworkSoundEventIndex)(-1); protected OverlapAttack attack; public float duration; private bool hasFired; private float hitPauseTimer; protected bool inHitPause; private bool hasHopped; protected float stopwatch; protected Animator animator; private HitStopCachedState hitStopCachedState; private Vector3 storedVelocity; private GhoulWeaponComponent wep; public override void OnEnter() { //IL_004f: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Expected O, but got Unknown //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) //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_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_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) ((BaseState)this).OnEnter(); duration = baseDuration / ((BaseState)this).attackSpeedStat; animator = ((EntityState)this).GetModelAnimator(); ((BaseState)this).StartAimMode(0.5f + duration, false); PlayAttackAnimation(); wep = ((EntityState)this).GetComponent(); attack = new OverlapAttack(); attack.damageType = damageType; attack.attacker = ((EntityState)this).gameObject; attack.inflictor = ((EntityState)this).gameObject; attack.teamIndex = ((BaseState)this).GetTeam(); attack.damage = damageCoefficient * ((BaseState)this).damageStat; attack.procCoefficient = procCoefficient; attack.hitEffectPrefab = hitEffectPrefab; attack.forceVector = bonusForce; attack.pushAwayForce = pushForce; attack.hitBoxGroup = ((BaseState)this).FindHitBoxGroup(hitboxGroupName); attack.isCrit = ((BaseState)this).RollCrit(); attack.impactSound = impactSound; ModifyOverlapAttack(attack); } protected virtual void ModifyOverlapAttack(OverlapAttack attack) { } protected virtual void PlayAttackAnimation() { ((EntityState)this).PlayCrossfade("Gesture, Override", "Slash" + (1 + swingIndex), playbackRateParam, duration, 0.05f); } public override void OnExit() { if (inHitPause) { RemoveHitstop(); } ((EntityState)this).OnExit(); } protected virtual void PlaySwingEffect() { if (!((Object)(object)swingEffectPrefab == (Object)null)) { EffectManager.SimpleMuzzleFlash(swingEffectPrefab, ((EntityState)this).gameObject, muzzleString, false); } } protected virtual void OnHitEnemyAuthority() { Util.PlaySound(hitSoundString, ((EntityState)this).gameObject); if (!hasHopped) { if (Object.op_Implicit((Object)(object)((EntityState)this).characterMotor) && !((EntityState)this).characterMotor.isGrounded && hitHopVelocity > 0f) { ((BaseState)this).SmallHop(((EntityState)this).characterMotor, hitHopVelocity); } hasHopped = true; } ApplyHitstop(); if (Object.op_Implicit((Object)(object)wep)) { wep.AddEnraged(attack.damage, duration); } } protected void ApplyHitstop() { //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_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) if (!inHitPause && hitStopDuration > 0f) { storedVelocity = ((EntityState)this).characterMotor.velocity; hitStopCachedState = ((BaseState)this).CreateHitStopCachedState(((EntityState)this).characterMotor, animator, playbackRateParam); hitPauseTimer = hitStopDuration / ((BaseState)this).attackSpeedStat; inHitPause = true; } } public virtual void FireAttack() { //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_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_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) //IL_0044: 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) if (((EntityState)this).isAuthority) { Ray aimRay = ((BaseState)this).GetAimRay(); Vector3 direction = ((Ray)(ref aimRay)).direction; direction.y = MathF.Max(direction.y, direction.y * 0.5f); ((BaseState)this).FindModelChild("MeleePivot").rotation = Util.QuaternionSafeLookRotation(direction); if (attack.Fire((List)null)) { OnHitEnemyAuthority(); } } } private void EnterAttack() { hasFired = true; Util.PlayAttackSpeedSound(swingSoundString, ((EntityState)this).gameObject, ((BaseState)this).attackSpeedStat); PlaySwingEffect(); if (((EntityState)this).isAuthority) { ((BaseState)this).AddRecoil(-1f * attackRecoil, -2f * attackRecoil, -0.5f * attackRecoil, 0.5f * attackRecoil); } } public override void FixedUpdate() { //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) ((EntityState)this).FixedUpdate(); hitPauseTimer -= Time.deltaTime; if (hitPauseTimer <= 0f && inHitPause) { RemoveHitstop(); } if (!inHitPause) { stopwatch += Time.deltaTime; } else { if (Object.op_Implicit((Object)(object)((EntityState)this).characterMotor)) { ((EntityState)this).characterMotor.velocity = Vector3.zero; } if (Object.op_Implicit((Object)(object)animator)) { animator.SetFloat(playbackRateParam, 0f); } } bool flag = stopwatch >= duration * attackStartPercentTime; bool flag2 = stopwatch >= duration * attackEndPercentTime; if ((flag && !flag2) || (flag && flag2 && !hasFired)) { if (!hasFired) { EnterAttack(); } FireAttack(); } if (stopwatch >= duration && ((EntityState)this).isAuthority) { ((EntityState)this).outer.SetNextStateToMain(); } } private void RemoveHitstop() { //IL_0003: 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) ((BaseState)this).ConsumeHitStopCachedState(hitStopCachedState, ((EntityState)this).characterMotor, animator); inHitPause = false; ((EntityState)this).characterMotor.velocity = storedVelocity; } public override InterruptPriority GetMinimumInterruptPriority() { //IL_0023: 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) if (stopwatch >= duration * earlyExitPercentTime) { return (InterruptPriority)0; } return (InterruptPriority)1; } public override void OnSerialize(NetworkWriter writer) { ((BaseSkillState)this).OnSerialize(writer); writer.Write(swingIndex); } public override void OnDeserialize(NetworkReader reader) { ((BaseSkillState)this).OnDeserialize(reader); swingIndex = reader.ReadInt32(); } public void SetStep(int i) { swingIndex = i; } } public abstract class BaseTimedSkillState : BaseSkillState { protected float duration; protected float castStartTime; protected float castEndTime; protected bool hasFired; protected bool isFiring; protected bool hasExited; public abstract float TimedBaseDuration { get; } public abstract float TimedBaseCastStartPercentTime { get; } public virtual float TimedBaseCastEndPercentTime => 1f; public override void OnEnter() { InitDurationValues(); ((BaseState)this).OnEnter(); } protected virtual void InitDurationValues() { duration = TimedBaseDuration / ((BaseState)this).attackSpeedStat; castStartTime = TimedBaseCastStartPercentTime * duration; castEndTime = TimedBaseCastEndPercentTime * duration; } protected virtual void OnCastEnter() { } protected virtual void OnCastFixedUpdate() { } protected virtual void OnCastUpdate() { } protected virtual void OnCastExit() { } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); bool flag = ((EntityState)this).fixedAge >= castStartTime; bool flag2 = ((EntityState)this).fixedAge >= castEndTime; isFiring = false; if ((flag && !flag2) || (flag && flag2 && !hasFired)) { isFiring = true; OnCastFixedUpdate(); if (!hasFired) { OnCastEnter(); hasFired = true; } } if (flag2 && !hasExited) { hasExited = true; OnCastExit(); } if (((EntityState)this).fixedAge > duration) { ((EntityState)this).outer.SetNextStateToMain(); } } public override void Update() { ((EntityState)this).Update(); if (isFiring) { OnCastUpdate(); } } } public class ExampleTimedSkillState : BaseTimedSkillState { public override float TimedBaseDuration => 1.5f; public override float TimedBaseCastStartPercentTime => 0.2f; public override float TimedBaseCastEndPercentTime => 0.9f; protected override void OnCastEnter() { } protected override void OnCastFixedUpdate() { } protected override void OnCastExit() { } } public class ExampleDelayedSkillState : BaseTimedSkillState { public override float TimedBaseDuration => 1.5f; public override float TimedBaseCastStartPercentTime => 0.2f; protected override void OnCastEnter() { } } } namespace GhoulMod.Modules.Achievements { public abstract class BaseMasteryAchievement : BaseAchievement { public abstract string RequiredCharacterBody { get; } public abstract float RequiredDifficultyCoefficient { get; } public override BodyIndex LookUpRequiredBodyIndex() { //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) //IL_000f: Unknown result type (might be due to invalid IL or missing references) return BodyCatalog.FindBodyIndex(RequiredCharacterBody); } public override void OnBodyRequirementMet() { ((BaseAchievement)this).OnBodyRequirementMet(); Run.onClientGameOverGlobal += OnClientGameOverGlobal; } public override void OnBodyRequirementBroken() { Run.onClientGameOverGlobal -= OnClientGameOverGlobal; ((BaseAchievement)this).OnBodyRequirementBroken(); } private void OnClientGameOverGlobal(Run run, RunReport runReport) { //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_0077: Unknown result type (might be due to invalid IL or missing references) //IL_0079: Invalid comparison between Unknown and I4 //IL_007b: Unknown result type (might be due to invalid IL or missing references) //IL_007e: Invalid comparison between Unknown and I4 if (!Object.op_Implicit((Object)(object)runReport.gameEnding) || !runReport.gameEnding.isWin) { return; } DifficultyIndex val = runReport.ruleBook.FindDifficulty(); DifficultyDef difficultyDef = DifficultyCatalog.GetDifficultyDef(val); if (difficultyDef != null) { bool flag = difficultyDef.countsAsHardMode && difficultyDef.scalingValue >= RequiredDifficultyCoefficient; bool flag2 = difficultyDef.nameToken == "INFERNO_NAME"; bool flag3 = (int)val >= 3 && (int)val <= 10; if (flag || flag2 || flag3) { ((BaseAchievement)this).Grant(); } } } } } namespace GhoulMod.Survivors.Ghoul { public class GhoulFeralSpawnCard : MasterCopySpawnCard { public static GhoulFeralSpawnCard GetSpawnCard(CharacterMaster srcCharacterMaster) { GhoulFeralSpawnCard ghoulFeralSpawnCard = ScriptableObject.CreateInstance(); MasterCopySpawnCard.CopyDataFromMaster((MasterCopySpawnCard)(object)ghoulFeralSpawnCard, srcCharacterMaster, true, true); ((MasterCopySpawnCard)ghoulFeralSpawnCard).onPreSpawnSetup = OnPreSpawnSetup; return ghoulFeralSpawnCard; void OnPreSpawnSetup(CharacterMaster spawnedMaster) { BaseAI ai = ((Component)spawnedMaster).GetComponent(); CharacterBody srcBody = srcCharacterMaster.GetBody(); ai.onBodyDiscovered += SetEnemyToOriginator; void SetEnemyToOriginator(CharacterBody body) { ai.currentEnemy.gameObject = ((Component)srcBody).gameObject; ai.onBodyDiscovered -= SetEnemyToOriginator; } } } } public static class GhoulAI { public static GameObject master; public static void Init(GameObject bodyPrefab, string masterName) { //IL_0046: 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_00dc: 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_010a: Unknown result type (might be due to invalid IL or missing references) //IL_0147: 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_01b9: 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_01d2: Unknown result type (might be due to invalid IL or missing references) //IL_01ef: Unknown result type (might be due to invalid IL or missing references) //IL_0245: Unknown result type (might be due to invalid IL or missing references) //IL_0261: Unknown result type (might be due to invalid IL or missing references) //IL_0273: Unknown result type (might be due to invalid IL or missing references) //IL_027a: Unknown result type (might be due to invalid IL or missing references) //IL_029a: Unknown result type (might be due to invalid IL or missing references) //IL_02e2: Unknown result type (might be due to invalid IL or missing references) //IL_0302: Unknown result type (might be due to invalid IL or missing references) //IL_0316: Unknown result type (might be due to invalid IL or missing references) //IL_031e: Unknown result type (might be due to invalid IL or missing references) //IL_033e: Unknown result type (might be due to invalid IL or missing references) //IL_0366: Unknown result type (might be due to invalid IL or missing references) //IL_0386: Unknown result type (might be due to invalid IL or missing references) //IL_039a: Unknown result type (might be due to invalid IL or missing references) //IL_03a2: Unknown result type (might be due to invalid IL or missing references) master = Prefabs.CreateBlankMasterPrefab(bodyPrefab, masterName); BaseAI component = master.GetComponent(); component.aimVectorDampTime = 0.1f; component.aimVectorMaxSpeed = 360f; AISkillDriver val = master.AddComponent(); val.customName = "Use Primary Swing"; val.skillSlot = (SkillSlot)0; val.requiredSkill = null; val.requireSkillReady = false; val.requireEquipmentReady = false; val.minUserHealthFraction = float.NegativeInfinity; val.maxUserHealthFraction = float.PositiveInfinity; val.minTargetHealthFraction = float.NegativeInfinity; val.maxTargetHealthFraction = float.PositiveInfinity; val.minDistance = 0f; val.maxDistance = 24f; val.selectionRequiresTargetLoS = true; val.selectionRequiresOnGround = false; val.selectionRequiresAimTarget = true; val.maxTimesSelected = -1; val.moveTargetType = (TargetType)0; val.activationRequiresTargetLoS = false; val.activationRequiresAimTargetLoS = false; val.activationRequiresAimConfirmation = false; val.movementType = (MovementType)2; val.moveInputScale = 1f; val.aimType = (AimType)1; val.ignoreNodeGraph = false; val.shouldSprint = false; val.shouldFireEquipment = false; val.buttonPressType = (ButtonPressType)2; val.driverUpdateTimerOverride = -1f; val.resetCurrentEnemyOnNextDriverSelection = false; val.noRepeat = false; val.nextHighPriorityOverride = null; AISkillDriver val2 = master.AddComponent(); val2.customName = "Use Grapple"; val2.skillSlot = (SkillSlot)1; val2.requireSkillReady = true; val2.minDistance = 20f; val2.maxDistance = 70f; val2.minUserHealthFraction = float.NegativeInfinity; val2.maxUserHealthFraction = float.PositiveInfinity; val2.selectionRequiresTargetLoS = false; val2.selectionRequiresOnGround = false; val2.selectionRequiresAimTarget = false; val2.maxTimesSelected = -1; val2.moveTargetType = (TargetType)0; val2.activationRequiresTargetLoS = false; val2.activationRequiresAimTargetLoS = false; val2.activationRequiresAimConfirmation = true; val2.movementType = (MovementType)1; val2.moveInputScale = 1f; val2.aimType = (AimType)1; val2.buttonPressType = (ButtonPressType)0; AISkillDriver val3 = master.AddComponent(); val3.customName = "Use Block"; val3.skillSlot = (SkillSlot)2; val3.requireSkillReady = true; val3.minDistance = 0f; val3.maxDistance = 20f; val3.selectionRequiresTargetLoS = true; val3.selectionRequiresOnGround = false; val3.selectionRequiresAimTarget = false; val3.minUserHealthFraction = float.NegativeInfinity; val3.maxUserHealthFraction = 80f; val3.maxTimesSelected = -1; val3.moveTargetType = (TargetType)0; val3.activationRequiresTargetLoS = false; val3.activationRequiresAimTargetLoS = false; val3.activationRequiresAimConfirmation = false; val3.movementType = (MovementType)1; val3.moveInputScale = 1f; val3.aimType = (AimType)1; val3.buttonPressType = (ButtonPressType)0; AISkillDriver val4 = master.AddComponent(); val4.customName = "Use Special"; val4.skillSlot = (SkillSlot)3; val4.requireSkillReady = true; val4.minDistance = 0f; val4.maxDistance = 10f; val4.selectionRequiresTargetLoS = false; val4.selectionRequiresOnGround = false; val4.selectionRequiresAimTarget = false; val4.maxTimesSelected = -1; val4.moveTargetType = (TargetType)0; val4.activationRequiresTargetLoS = false; val4.activationRequiresAimTargetLoS = false; val4.activationRequiresAimConfirmation = false; val4.movementType = (MovementType)1; val4.moveInputScale = 1f; val4.aimType = (AimType)1; val4.buttonPressType = (ButtonPressType)0; AISkillDriver val5 = master.AddComponent(); val5.customName = "Chase"; val5.skillSlot = (SkillSlot)(-1); val5.requireSkillReady = false; val5.minDistance = 0f; val5.maxDistance = float.PositiveInfinity; val5.moveTargetType = (TargetType)0; val5.activationRequiresTargetLoS = false; val5.activationRequiresAimTargetLoS = false; val5.activationRequiresAimConfirmation = false; val5.movementType = (MovementType)1; val5.moveInputScale = 1f; val5.aimType = (AimType)1; val5.buttonPressType = (ButtonPressType)0; } } public static class GhoulAssets { public static GameObject essenceObject; public static GameObject essenceUIObject; public static GameObject essenceDisplay; public static GameObject tendrilThrustEffect; public static GameObject tendrilSweepEffect; public static GameObject dashEffect; public static GameObject tantalizeStabEffect; public static GameObject bloodEffect; public static GameObject bloodDripEffect; public static GameObject altSlamIndicator; public static GameObject swordHitImpactEffect; public static GameObject bloodSplatEffect; public static GameObject tentacleTerrainImpact; public static GameObject blinkPrefab; public static Texture baseIcon; public static Texture tokyoIcon; public static Texture carnageIcon; public static GameObject bombExplosionEffect; public static GameObject slamDecal; public static GameObject lobby_RoarShake; public static NetworkSoundEventDef swordHitSoundEvent; public static NetworkSoundEventDef swordHitSoundEventHeavy; public static RuntimeAnimatorController mainAnimController; public static RuntimeAnimatorController enragedAnimController; public static GameObject rageMeter; public static GameObject vignette; public static Texture defaultCrosshair; public static Texture grappleCrosshair; public static GameObject impSpikePrefab; public static GameObject bombProjectilePrefab; private static AssetBundle _assetBundle; public static Material targetOverlayMat; public static Material impOverlayMat; public static void Init(AssetBundle assetBundle) { _assetBundle = assetBundle; swordHitSoundEvent = Content.CreateAndAddNetworkSoundEventDef("Play_Ghoul_Attack_Impact"); swordHitSoundEventHeavy = Content.CreateAndAddNetworkSoundEventDef("Play_Ghoul_Attack_Impact_Heavy"); Config.InitROO(_assetBundle.LoadAsset("Base_Icon"), "I am the [City] Ghoul."); CreateEffects(); CacheAnimators(); CreateProjectiles(); CreateEnrageOverlayMat(); CreateHudElements(); CreateSlamGround(); CreateCrosshairIcons(); CreateEssenceObject(); CacheIcons(); } private static void CreateEffects() { //IL_0092: 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_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_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_0181: Unknown result type (might be due to invalid IL or missing references) CreateBombExplosionEffect(); tendrilThrustEffect = _assetBundle.LoadEffect("GhoulTendrilStrikeEffect", parentToTransform: true); tendrilSweepEffect = _assetBundle.LoadEffect("GhoulTendrilSweepEffect", parentToTransform: true); swordHitImpactEffect = _assetBundle.LoadEffect("BloodGushEffectSmall"); tantalizeStabEffect = _assetBundle.LoadEffect("GhoulTantalizeEffect", parentToTransform: true); altSlamIndicator = _assetBundle.LoadAsset("GhoulAltSlamIndicator"); ((Renderer)((Component)altSlamIndicator.transform.Find("Expander/Rim")).GetComponent()).sharedMaterial = Addressables.LoadAssetAsync((object)"RoR2/Base/Common/VFX/matAreaIndicatorRim.mat").WaitForCompletion(); lobby_RoarShake = _assetBundle.LoadAsset("Lobby_RoarShake"); tentacleTerrainImpact = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/DLC2/FalseSon/OmniImpactVFXFalseSonGroundSlam.prefab").WaitForCompletion(), "VcrGhoulTerrainDust", false); if (Object.op_Implicit((Object)(object)tentacleTerrainImpact.GetComponent())) { Object.Destroy((Object)(object)tentacleTerrainImpact.GetComponent()); } dashEffect = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Common/VFX/CharacterLandImpact.prefab").WaitForCompletion(), "VcrGhoulDashDust", false); if (Object.op_Implicit((Object)(object)dashEffect.GetComponent())) { Object.Destroy((Object)(object)dashEffect.GetComponent()); } if (Object.op_Implicit((Object)(object)dashEffect.GetComponent())) { Object.Destroy((Object)(object)dashEffect.GetComponent()); } dashEffect.transform.rotation = Quaternion.Euler(90f, 0f, 0f); bloodEffect = _assetBundle.LoadAsset("BloodDripEffect"); bloodDripEffect = _assetBundle.LoadAsset("BloodPourEffect"); } private static void CreateEssenceObject() { //IL_0006: Unknown result type (might be due to invalid IL or missing references) //IL_000b: Unknown result type (might be due to invalid IL or missing references) //IL_004e: Unknown result type (might be due to invalid IL or missing references) //IL_0053: Unknown result type (might be due to invalid IL or missing references) //IL_00e7: Unknown result type (might be due to invalid IL or missing references) //IL_00ec: Unknown result type (might be due to invalid IL or missing references) //IL_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_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) essenceUIObject = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/DLC1/OptionPickup/OptionPickerPanel.prefab").WaitForCompletion(), "VcrGhoulEssenceUI", true); LanguageTextMeshController component = ((Component)essenceUIObject.transform.Find("MainPanel/Juice/Label")).GetComponent(); component.token = "VCR_GHOUL_ESSENCE_PICKUP_INTERACTION_SUBTITLE"; essenceObject = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/DLC1/OptionPickup/OptionPickup.prefab").WaitForCompletion(), "VcrGhoulEssence", true); essenceObject.GetComponent().panelPrefab = essenceUIObject; essenceObject.GetComponent().contextString = "VCR_GHOUL_ESSENCE_PICKUP_INTERACTION_PROMPT"; if (Object.op_Implicit((Object)(object)essenceObject.GetComponent())) { essenceObject.GetComponent().displayToken = "VCR_GHOUL_ESSENCE_PICKUP_NAME"; } Transform transform = ((Component)essenceObject.transform.Find("PickupDisplay/Mesh/Sphere, Core")).transform; ((Renderer)((Component)transform.GetChild(0)).GetComponent()).sharedMaterial = Addressables.LoadAssetAsync((object)"RoR2/Base/Common/VFX/matBloodHumanLarge.mat").WaitForCompletion(); ((Renderer)((Component)transform.GetChild(1)).GetComponent()).sharedMaterial = Addressables.LoadAssetAsync((object)"RoR2/Base/moon2/matBloodSiphon.mat").WaitForCompletion(); ((Renderer)((Component)transform.GetChild(2)).GetComponent()).sharedMaterial = Addressables.LoadAssetAsync((object)"RoR2/Base/Common/VFX/matBloodHumanLarge.mat").WaitForCompletion(); } private static void CacheAnimators() { mainAnimController = _assetBundle.LoadAsset("animGhoul"); enragedAnimController = _assetBundle.LoadAsset("animGhoulEnrage"); } private static void CreateEnrageOverlayMat() { //IL_0006: Unknown result type (might be due to invalid IL or missing references) //IL_000b: Unknown result type (might be due to invalid IL or missing references) //IL_0027: 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_0058: Unknown result type (might be due to invalid IL or missing references) targetOverlayMat = Object.Instantiate(Addressables.LoadAssetAsync((object)"RoR2/DLC1/VoidSurvivor/matVoidSurvivorCorruptOverlay 1.mat").WaitForCompletion()); targetOverlayMat.SetColor("_TintColor", Color.red); impOverlayMat = Object.Instantiate(Addressables.LoadAssetAsync((object)"RoR2/Base/Imp/matImpBossDissolve.mat").WaitForCompletion()); impOverlayMat.SetColor("_TintColor", Color.red); } private static void CreateHudElements() { rageMeter = _assetBundle.LoadAsset("GhoulEnrageMeter"); rageMeter.AddComponent(); vignette = _assetBundle.LoadAsset("GhoulVignetteUI"); vignette.AddComponent(); } private static void CreateSlamGround() { //IL_0006: Unknown result type (might be due to invalid IL or missing references) //IL_000b: Unknown result type (might be due to invalid IL or missing references) slamDecal = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/BeetleGuard/BeetleGuardGroundSlam.prefab").WaitForCompletion(), "VcrGhoulSlamImpact", false); if (Object.op_Implicit((Object)(object)slamDecal.GetComponent())) { Object.Destroy((Object)(object)slamDecal.GetComponent()); } if (Object.op_Implicit((Object)(object)slamDecal.GetComponent())) { Object.Destroy((Object)(object)slamDecal.GetComponent()); } } private static void CreateBombExplosionEffect() { //IL_0079: 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) bombExplosionEffect = _assetBundle.LoadEffect("BombExplosionEffect", "GhoulSlamExplosion"); if (Object.op_Implicit((Object)(object)bombExplosionEffect)) { EffectComponent component = bombExplosionEffect.GetComponent(); component.applyScale = true; component.noEffectData = true; ShakeEmitter val = bombExplosionEffect.AddComponent(); val.amplitudeTimeDecay = true; val.duration = 0.5f; val.radius = 200f; val.scaleShakeRadiusWithLocalScale = false; val.wave = new Wave { amplitude = 1f, frequency = 40f, cycleOffset = 0f }; } } private static void CreateProjectiles() { CreateBombProjectile(); CreateSpike(); Content.AddProjectilePrefab(impSpikePrefab); Content.AddProjectilePrefab(bombProjectilePrefab); } private static void CreateSpike() { //IL_0006: Unknown result type (might be due to invalid IL or missing references) //IL_000b: Unknown result type (might be due to invalid IL or missing references) impSpikePrefab = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/ImpBoss/ImpVoidspikeProjectile.prefab").WaitForCompletion(), "VcrGhoulSpikePrefab", false); } private static void CreateBombProjectile() { //IL_0048: Unknown result type (might be due to invalid IL or missing references) bombProjectilePrefab = Asset.CloneProjectilePrefab("CommandoGrenadeProjectile", "HenryBombProjectile"); Object.Destroy((Object)(object)bombProjectilePrefab.GetComponent()); ProjectileImpactExplosion val = bombProjectilePrefab.AddComponent(); ((ProjectileExplosion)val).blastRadius = 16f; ((ProjectileExplosion)val).blastDamageCoefficient = 1f; ((ProjectileExplosion)val).falloffModel = (FalloffModel)0; val.destroyOnEnemy = true; val.lifetime = 12f; val.impactEffect = bombExplosionEffect; val.lifetimeExpiredSound = Content.CreateAndAddNetworkSoundEventDef("HenryBombExplosion"); val.timerAfterImpact = true; val.lifetimeAfterImpact = 0.1f; ProjectileController component = bombProjectilePrefab.GetComponent(); if ((Object)(object)_assetBundle.LoadAsset("HenryBombGhost") != (Object)null) { component.ghostPrefab = _assetBundle.CreateProjectileGhostPrefab("HenryBombGhost"); } component.startSound = ""; } public static void CacheIcons() { baseIcon = LoadCharacterIcon("Base"); tokyoIcon = LoadCharacterIcon("Kaneki"); carnageIcon = LoadCharacterIcon("Carnage"); } internal static Texture LoadCharacterIcon(string charactername) { if (_assetBundle.Contains(charactername + "_Icon")) { return (Texture)(object)_assetBundle.LoadAsset(charactername + "_Icon").texture; } Log.Error("AssetBundle does not contain icon sprite from that character. Returning Default. "); return (Texture)(object)_assetBundle.LoadAsset("Base_Icon").texture; } public static void CreateCrosshairIcons() { defaultCrosshair = (Texture)(object)_assetBundle.LoadAsset("ghoulCrosshair_NoGrapple").texture; grappleCrosshair = (Texture)(object)_assetBundle.LoadAsset("crosshairRing").texture; } } public static class GhoulBuffs { public static BuffDef blockBuff; public static BuffDef hungerBuff; public static BuffDef preyDebuff; public static BuffDef feralAffix; public static void Init(AssetBundle assetBundle) { //IL_0015: 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_005f: 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) blockBuff = Content.CreateAndAddBuff("GhoulBlockBuff", LegacyResourcesAPI.Load("BuffDefs/HiddenInvincibility").iconSprite, Color.white, canStack: false, isDebuff: false); hungerBuff = Content.CreateAndAddBuff("GhoulHungerBuff", LegacyResourcesAPI.Load("BuffDefs/HiddenInvincibility").iconSprite, Color.white, canStack: false, isDebuff: false); preyDebuff = Content.CreateAndAddBuff("GhoulPreyDebuff", LegacyResourcesAPI.Load("BuffDefs/HiddenInvincibility").iconSprite, Color.white, canStack: false, isDebuff: true); feralAffix = Content.CreateAndAddBuff("GhoulAffixFeral", null, Color.white, canStack: false, isDebuff: false); } } public static class GhoulConfig { public static ConfigEntry unravelOnFinalBoss; public static ConfigEntry dynamicCamera; public static ConfigEntry cursed; public static ConfigEntry someConfigFloat; public static ConfigEntry someConfigFloatWithCustomRange; public static void Init() { string section = "01-General"; unravelOnFinalBoss = Config.BindAndOptions(section, "Unravel on Mithrix Phase 2", defaultValue: true, "Enable to play Unravel's intrumental during Mithrix's second phase"); dynamicCamera = Config.BindAndOptions(section, "Cinematic Enraged Camera", defaultValue: false, "While entering Enraged have a cinematic camera UNEMPLIMENTED"); cursed = Config.BindAndOptions(section, "Enable/Disable Cursed", defaultValue: false, "Enable to see unfinished content", restartRequired: true); someConfigFloat = Config.BindAndOptions(section, "someConfigfloat", 5f); someConfigFloatWithCustomRange = Config.BindAndOptions(section, "someConfigfloat2", 5f, 0f, 50f, "if a custom range is not passed in, a float will default to a slider with range 0-20. risk of options only has sliders"); } } public class GhoulItemDisplays : ItemDisplaysBase { protected override void SetItemDisplayRules(List itemDisplayRules) { //IL_0037: 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_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_006e: 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_00c3: Unknown result type (might be due to invalid IL or missing references) //IL_00d7: Unknown result type (might be due to invalid IL or missing references) //IL_00dc: Unknown result type (might be due to invalid IL or missing references) //IL_00e1: Unknown result type (might be due to invalid IL or missing references) //IL_00e6: Unknown result type (might be due to invalid IL or missing references) //IL_0127: 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_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_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_019f: 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_01c7: 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_01d1: Unknown result type (might be due to invalid IL or missing references) //IL_01d6: Unknown result type (might be due to invalid IL or missing references) //IL_0217: 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_023f: Unknown result type (might be due to invalid IL or missing references) //IL_0244: Unknown result type (might be due to invalid IL or missing references) //IL_0249: Unknown result type (might be due to invalid IL or missing references) //IL_024e: Unknown result type (might be due to invalid IL or missing references) //IL_028f: Unknown result type (might be due to invalid IL or missing references) //IL_02a3: Unknown result type (might be due to invalid IL or missing references) //IL_02b7: Unknown result type (might be due to invalid IL or missing references) //IL_02bc: Unknown result type (might be due to invalid IL or missing references) //IL_02c1: 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_0307: Unknown result type (might be due to invalid IL or missing references) //IL_031b: 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_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_033e: Unknown result type (might be due to invalid IL or missing references) //IL_037f: 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_03a7: Unknown result type (might be due to invalid IL or missing references) //IL_03ac: Unknown result type (might be due to invalid IL or missing references) //IL_03b1: Unknown result type (might be due to invalid IL or missing references) //IL_03b6: Unknown result type (might be due to invalid IL or missing references) //IL_03f7: Unknown result type (might be due to invalid IL or missing references) //IL_040b: Unknown result type (might be due to invalid IL or missing references) //IL_041f: Unknown result type (might be due to invalid IL or missing references) //IL_0424: Unknown result type (might be due to invalid IL or missing references) //IL_0429: Unknown result type (might be due to invalid IL or missing references) //IL_042e: Unknown result type (might be due to invalid IL or missing references) //IL_046f: Unknown result type (might be due to invalid IL or missing references) //IL_0483: Unknown result type (might be due to invalid IL or missing references) //IL_0497: Unknown result type (might be due to invalid IL or missing references) //IL_049c: Unknown result type (might be due to invalid IL or missing references) //IL_04a1: Unknown result type (might be due to invalid IL or missing references) //IL_04a6: Unknown result type (might be due to invalid IL or missing references) //IL_04e7: Unknown result type (might be due to invalid IL or missing references) //IL_04fb: Unknown result type (might be due to invalid IL or missing references) //IL_050f: Unknown result type (might be due to invalid IL or missing references) //IL_0514: Unknown result type (might be due to invalid IL or missing references) //IL_0519: Unknown result type (might be due to invalid IL or missing references) //IL_051e: Unknown result type (might be due to invalid IL or missing references) //IL_055f: Unknown result type (might be due to invalid IL or missing references) //IL_0573: Unknown result type (might be due to invalid IL or missing references) //IL_0587: Unknown result type (might be due to invalid IL or missing references) //IL_058c: Unknown result type (might be due to invalid IL or missing references) //IL_0591: Unknown result type (might be due to invalid IL or missing references) //IL_0596: Unknown result type (might be due to invalid IL or missing references) //IL_05d7: Unknown result type (might be due to invalid IL or missing references) //IL_05eb: Unknown result type (might be due to invalid IL or missing references) //IL_05ff: Unknown result type (might be due to invalid IL or missing references) //IL_0604: Unknown result type (might be due to invalid IL or missing references) //IL_0609: Unknown result type (might be due to invalid IL or missing references) //IL_060e: Unknown result type (might be due to invalid IL or missing references) //IL_064f: Unknown result type (might be due to invalid IL or missing references) //IL_0663: Unknown result type (might be due to invalid IL or missing references) //IL_0677: Unknown result type (might be due to invalid IL or missing references) //IL_067c: Unknown result type (might be due to invalid IL or missing references) //IL_0681: Unknown result type (might be due to invalid IL or missing references) //IL_0686: Unknown result type (might be due to invalid IL or missing references) //IL_06c7: 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_06ef: Unknown result type (might be due to invalid IL or missing references) //IL_06f4: Unknown result type (might be due to invalid IL or missing references) //IL_06f9: Unknown result type (might be due to invalid IL or missing references) //IL_06fe: Unknown result type (might be due to invalid IL or missing references) //IL_073f: Unknown result type (might be due to invalid IL or missing references) //IL_0753: Unknown result type (might be due to invalid IL or missing references) //IL_0767: 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_0771: Unknown result type (might be due to invalid IL or missing references) //IL_0776: Unknown result type (might be due to invalid IL or missing references) //IL_07b7: Unknown result type (might be due to invalid IL or missing references) //IL_07cb: Unknown result type (might be due to invalid IL or missing references) //IL_07df: Unknown result type (might be due to invalid IL or missing references) //IL_07e4: Unknown result type (might be due to invalid IL or missing references) //IL_07e9: Unknown result type (might be due to invalid IL or missing references) //IL_07ee: Unknown result type (might be due to invalid IL or missing references) //IL_082f: Unknown result type (might be due to invalid IL or missing references) //IL_0843: 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_085c: Unknown result type (might be due to invalid IL or missing references) //IL_0861: Unknown result type (might be due to invalid IL or missing references) //IL_0866: Unknown result type (might be due to invalid IL or missing references) //IL_08a7: Unknown result type (might be due to invalid IL or missing references) //IL_08bb: Unknown result type (might be due to invalid IL or missing references) //IL_08cf: Unknown result type (might be due to invalid IL or missing references) //IL_08d4: Unknown result type (might be due to invalid IL or missing references) //IL_08d9: Unknown result type (might be due to invalid IL or missing references) //IL_08de: Unknown result type (might be due to invalid IL or missing references) //IL_091f: Unknown result type (might be due to invalid IL or missing references) //IL_0933: Unknown result type (might be due to invalid IL or missing references) //IL_0947: Unknown result type (might be due to invalid IL or missing references) //IL_094c: Unknown result type (might be due to invalid IL or missing references) //IL_0951: Unknown result type (might be due to invalid IL or missing references) //IL_0956: Unknown result type (might be due to invalid IL or missing references) //IL_0997: Unknown result type (might be due to invalid IL or missing references) //IL_09ab: Unknown result type (might be due to invalid IL or missing references) //IL_09bf: Unknown result type (might be due to invalid IL or missing references) //IL_09c4: Unknown result type (might be due to invalid IL or missing references) //IL_09c9: Unknown result type (might be due to invalid IL or missing references) //IL_09ce: Unknown result type (might be due to invalid IL or missing references) //IL_0a0f: Unknown result type (might be due to invalid IL or missing references) //IL_0a23: Unknown result type (might be due to invalid IL or missing references) //IL_0a37: Unknown result type (might be due to invalid IL or missing references) //IL_0a3c: Unknown result type (might be due to invalid IL or missing references) //IL_0a41: Unknown result type (might be due to invalid IL or missing references) //IL_0a46: Unknown result type (might be due to invalid IL or missing references) //IL_0a87: Unknown result type (might be due to invalid IL or missing references) //IL_0a9b: Unknown result type (might be due to invalid IL or missing references) //IL_0aaf: Unknown result type (might be due to invalid IL or missing references) //IL_0ab4: Unknown result type (might be due to invalid IL or missing references) //IL_0ab9: Unknown result type (might be due to invalid IL or missing references) //IL_0abe: Unknown result type (might be due to invalid IL or missing references) //IL_0aff: Unknown result type (might be due to invalid IL or missing references) //IL_0b13: Unknown result type (might be due to invalid IL or missing references) //IL_0b27: Unknown result type (might be due to invalid IL or missing references) //IL_0b2c: Unknown result type (might be due to invalid IL or missing references) //IL_0b31: Unknown result type (might be due to invalid IL or missing references) //IL_0b36: Unknown result type (might be due to invalid IL or missing references) //IL_0b77: Unknown result type (might be due to invalid IL or missing references) //IL_0b8b: Unknown result type (might be due to invalid IL or missing references) //IL_0b9f: Unknown result type (might be due to invalid IL or missing references) //IL_0ba4: Unknown result type (might be due to invalid IL or missing references) //IL_0ba9: Unknown result type (might be due to invalid IL or missing references) //IL_0bae: Unknown result type (might be due to invalid IL or missing references) //IL_0bef: Unknown result type (might be due to invalid IL or missing references) //IL_0c03: Unknown result type (might be due to invalid IL or missing references) //IL_0c17: Unknown result type (might be due to invalid IL or missing references) //IL_0c1c: Unknown result type (might be due to invalid IL or missing references) //IL_0c21: Unknown result type (might be due to invalid IL or missing references) //IL_0c26: Unknown result type (might be due to invalid IL or missing references) //IL_0c67: Unknown result type (might be due to invalid IL or missing references) //IL_0c7b: Unknown result type (might be due to invalid IL or missing references) //IL_0c8f: Unknown result type (might be due to invalid IL or missing references) //IL_0c94: Unknown result type (might be due to invalid IL or missing references) //IL_0c99: Unknown result type (might be due to invalid IL or missing references) //IL_0c9e: Unknown result type (might be due to invalid IL or missing references) //IL_0cdf: Unknown result type (might be due to invalid IL or missing references) //IL_0cf3: Unknown result type (might be due to invalid IL or missing references) //IL_0d07: Unknown result type (might be due to invalid IL or missing references) //IL_0d0c: Unknown result type (might be due to invalid IL or missing references) //IL_0d11: Unknown result type (might be due to invalid IL or missing references) //IL_0d16: Unknown result type (might be due to invalid IL or missing references) //IL_0d57: Unknown result type (might be due to invalid IL or missing references) //IL_0d6b: Unknown result type (might be due to invalid IL or missing references) //IL_0d7f: Unknown result type (might be due to invalid IL or missing references) //IL_0d84: Unknown result type (might be due to invalid IL or missing references) //IL_0d89: Unknown result type (might be due to invalid IL or missing references) //IL_0d8e: Unknown result type (might be due to invalid IL or missing references) //IL_0dcf: Unknown result type (might be due to invalid IL or missing references) //IL_0de3: Unknown result type (might be due to invalid IL or missing references) //IL_0df7: Unknown result type (might be due to invalid IL or missing references) //IL_0dfc: Unknown result type (might be due to invalid IL or missing references) //IL_0e01: Unknown result type (might be due to invalid IL or missing references) //IL_0e06: Unknown result type (might be due to invalid IL or missing references) //IL_0e47: Unknown result type (might be due to invalid IL or missing references) //IL_0e5b: Unknown result type (might be due to invalid IL or missing references) //IL_0e6f: Unknown result type (might be due to invalid IL or missing references) //IL_0e74: Unknown result type (might be due to invalid IL or missing references) //IL_0e79: Unknown result type (might be due to invalid IL or missing references) //IL_0e7e: Unknown result type (might be due to invalid IL or missing references) //IL_0ebf: Unknown result type (might be due to invalid IL or missing references) //IL_0ed3: Unknown result type (might be due to invalid IL or missing references) //IL_0ee7: Unknown result type (might be due to invalid IL or missing references) //IL_0eec: Unknown result type (might be due to invalid IL or missing references) //IL_0ef1: Unknown result type (might be due to invalid IL or missing references) //IL_0ef6: Unknown result type (might be due to invalid IL or missing references) //IL_0f37: Unknown result type (might be due to invalid IL or missing references) //IL_0f4b: Unknown result type (might be due to invalid IL or missing references) //IL_0f5f: Unknown result type (might be due to invalid IL or missing references) //IL_0f64: Unknown result type (might be due to invalid IL or missing references) //IL_0f69: Unknown result type (might be due to invalid IL or missing references) //IL_0f6e: Unknown result type (might be due to invalid IL or missing references) //IL_0faf: Unknown result type (might be due to invalid IL or missing references) //IL_0fc3: Unknown result type (might be due to invalid IL or missing references) //IL_0fd7: Unknown result type (might be due to invalid IL or missing references) //IL_0fdc: Unknown result type (might be due to invalid IL or missing references) //IL_0fe1: Unknown result type (might be due to invalid IL or missing references) //IL_0fe6: Unknown result type (might be due to invalid IL or missing references) //IL_1027: Unknown result type (might be due to invalid IL or missing references) //IL_103b: Unknown result type (might be due to invalid IL or missing references) //IL_104f: Unknown result type (might be due to invalid IL or missing references) //IL_1054: Unknown result type (might be due to invalid IL or missing references) //IL_1059: Unknown result type (might be due to invalid IL or missing references) //IL_105e: Unknown result type (might be due to invalid IL or missing references) //IL_109f: Unknown result type (might be due to invalid IL or missing references) //IL_10b3: Unknown result type (might be due to invalid IL or missing references) //IL_10c7: 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_10d6: Unknown result type (might be due to invalid IL or missing references) //IL_1117: Unknown result type (might be due to invalid IL or missing references) //IL_112b: Unknown result type (might be due to invalid IL or missing references) //IL_113f: Unknown result type (might be due to invalid IL or missing references) //IL_1144: Unknown result type (might be due to invalid IL or missing references) //IL_1149: Unknown result type (might be due to invalid IL or missing references) //IL_114e: Unknown result type (might be due to invalid IL or missing references) //IL_118f: Unknown result type (might be due to invalid IL or missing references) //IL_11a3: 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_11c1: Unknown result type (might be due to invalid IL or missing references) //IL_11c6: Unknown result type (might be due to invalid IL or missing references) //IL_1207: Unknown result type (might be due to invalid IL or missing references) //IL_121b: Unknown result type (might be due to invalid IL or missing references) //IL_122f: Unknown result type (might be due to invalid IL or missing references) //IL_1234: Unknown result type (might be due to invalid IL or missing references) //IL_1239: Unknown result type (might be due to invalid IL or missing references) //IL_123e: Unknown result type (might be due to invalid IL or missing references) //IL_127f: Unknown result type (might be due to invalid IL or missing references) //IL_1293: Unknown result type (might be due to invalid IL or missing references) //IL_12a7: Unknown result type (might be due to invalid IL or missing references) //IL_12ac: Unknown result type (might be due to invalid IL or missing references) //IL_12b1: Unknown result type (might be due to invalid IL or missing references) //IL_12b6: Unknown result type (might be due to invalid IL or missing references) //IL_12f7: Unknown result type (might be due to invalid IL or missing references) //IL_130b: Unknown result type (might be due to invalid IL or missing references) //IL_131f: Unknown result type (might be due to invalid IL or missing references) //IL_1324: Unknown result type (might be due to invalid IL or missing references) //IL_1329: Unknown result type (might be due to invalid IL or missing references) //IL_132e: Unknown result type (might be due to invalid IL or missing references) //IL_136f: Unknown result type (might be due to invalid IL or missing references) //IL_1383: Unknown result type (might be due to invalid IL or missing references) //IL_1397: Unknown result type (might be due to invalid IL or missing references) //IL_139c: Unknown result type (might be due to invalid IL or missing references) //IL_13a1: Unknown result type (might be due to invalid IL or missing references) //IL_13a6: Unknown result type (might be due to invalid IL or missing references) //IL_13e7: Unknown result type (might be due to invalid IL or missing references) //IL_13fb: Unknown result type (might be due to invalid IL or missing references) //IL_140f: Unknown result type (might be due to invalid IL or missing references) //IL_1414: Unknown result type (might be due to invalid IL or missing references) //IL_1419: Unknown result type (might be due to invalid IL or missing references) //IL_141e: Unknown result type (might be due to invalid IL or missing references) //IL_145f: Unknown result type (might be due to invalid IL or missing references) //IL_1473: Unknown result type (might be due to invalid IL or missing references) //IL_1487: Unknown result type (might be due to invalid IL or missing references) //IL_148c: Unknown result type (might be due to invalid IL or missing references) //IL_1491: Unknown result type (might be due to invalid IL or missing references) //IL_1496: Unknown result type (might be due to invalid IL or missing references) //IL_14d7: Unknown result type (might be due to invalid IL or missing references) //IL_14eb: Unknown result type (might be due to invalid IL or missing references) //IL_14ff: Unknown result type (might be due to invalid IL or missing references) //IL_1504: Unknown result type (might be due to invalid IL or missing references) //IL_1509: Unknown result type (might be due to invalid IL or missing references) //IL_150e: Unknown result type (might be due to invalid IL or missing references) //IL_154f: Unknown result type (might be due to invalid IL or missing references) //IL_1563: Unknown result type (might be due to invalid IL or missing references) //IL_1577: Unknown result type (might be due to invalid IL or missing references) //IL_157c: Unknown result type (might be due to invalid IL or missing references) //IL_1581: Unknown result type (might be due to invalid IL or missing references) //IL_1586: Unknown result type (might be due to invalid IL or missing references) //IL_15c7: Unknown result type (might be due to invalid IL or missing references) //IL_15db: Unknown result type (might be due to invalid IL or missing references) //IL_15ef: Unknown result type (might be due to invalid IL or missing references) //IL_15f4: Unknown result type (might be due to invalid IL or missing references) //IL_15f9: Unknown result type (might be due to invalid IL or missing references) //IL_15fe: Unknown result type (might be due to invalid IL or missing references) //IL_163f: Unknown result type (might be due to invalid IL or missing references) //IL_1653: Unknown result type (might be due to invalid IL or missing references) //IL_1667: Unknown result type (might be due to invalid IL or missing references) //IL_166c: Unknown result type (might be due to invalid IL or missing references) //IL_1671: Unknown result type (might be due to invalid IL or missing references) //IL_1676: 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_16cb: Unknown result type (might be due to invalid IL or missing references) //IL_16df: Unknown result type (might be due to invalid IL or missing references) //IL_16e4: Unknown result type (might be due to invalid IL or missing references) //IL_16e9: Unknown result type (might be due to invalid IL or missing references) //IL_16f1: Unknown result type (might be due to invalid IL or missing references) //IL_16f6: Unknown result type (might be due to invalid IL or missing references) //IL_16fb: Unknown result type (might be due to invalid IL or missing references) //IL_173c: Unknown result type (might be due to invalid IL or missing references) //IL_1750: Unknown result type (might be due to invalid IL or missing references) //IL_1764: Unknown result type (might be due to invalid IL or missing references) //IL_1769: Unknown result type (might be due to invalid IL or missing references) //IL_176e: Unknown result type (might be due to invalid IL or missing references) //IL_1773: Unknown result type (might be due to invalid IL or missing references) //IL_17b4: Unknown result type (might be due to invalid IL or missing references) //IL_17c8: Unknown result type (might be due to invalid IL or missing references) //IL_17dc: Unknown result type (might be due to invalid IL or missing references) //IL_17e1: Unknown result type (might be due to invalid IL or missing references) //IL_17e6: Unknown result type (might be due to invalid IL or missing references) //IL_17eb: Unknown result type (might be due to invalid IL or missing references) //IL_182c: Unknown result type (might be due to invalid IL or missing references) //IL_1840: Unknown result type (might be due to invalid IL or missing references) //IL_1854: Unknown result type (might be due to invalid IL or missing references) //IL_1859: Unknown result type (might be due to invalid IL or missing references) //IL_185e: Unknown result type (might be due to invalid IL or missing references) //IL_1863: Unknown result type (might be due to invalid IL or missing references) //IL_18a4: Unknown result type (might be due to invalid IL or missing references) //IL_18b8: Unknown result type (might be due to invalid IL or missing references) //IL_18cc: Unknown result type (might be due to invalid IL or missing references) //IL_18d1: Unknown result type (might be due to invalid IL or missing references) //IL_18d6: Unknown result type (might be due to invalid IL or missing references) //IL_18fb: Unknown result type (might be due to invalid IL or missing references) //IL_190f: Unknown result type (might be due to invalid IL or missing references) //IL_1923: Unknown result type (might be due to invalid IL or missing references) //IL_1928: Unknown result type (might be due to invalid IL or missing references) //IL_192d: Unknown result type (might be due to invalid IL or missing references) //IL_1932: Unknown result type (might be due to invalid IL or missing references) //IL_1973: Unknown result type (might be due to invalid IL or missing references) //IL_1987: Unknown result type (might be due to invalid IL or missing references) //IL_199b: Unknown result type (might be due to invalid IL or missing references) //IL_19a0: Unknown result type (might be due to invalid IL or missing references) //IL_19a5: Unknown result type (might be due to invalid IL or missing references) //IL_19aa: Unknown result type (might be due to invalid IL or missing references) //IL_19eb: Unknown result type (might be due to invalid IL or missing references) //IL_19ff: Unknown result type (might be due to invalid IL or missing references) //IL_1a13: Unknown result type (might be due to invalid IL or missing references) //IL_1a18: Unknown result type (might be due to invalid IL or missing references) //IL_1a1d: Unknown result type (might be due to invalid IL or missing references) //IL_1a22: Unknown result type (might be due to invalid IL or missing references) //IL_1a63: Unknown result type (might be due to invalid IL or missing references) //IL_1a77: Unknown result type (might be due to invalid IL or missing references) //IL_1a8b: Unknown result type (might be due to invalid IL or missing references) //IL_1a90: Unknown result type (might be due to invalid IL or missing references) //IL_1a95: Unknown result type (might be due to invalid IL or missing references) //IL_1a9a: Unknown result type (might be due to invalid IL or missing references) //IL_1adb: Unknown result type (might be due to invalid IL or missing references) //IL_1aef: Unknown result type (might be due to invalid IL or missing references) //IL_1b03: Unknown result type (might be due to invalid IL or missing references) //IL_1b08: Unknown result type (might be due to invalid IL or missing references) //IL_1b0d: Unknown result type (might be due to invalid IL or missing references) //IL_1b12: Unknown result type (might be due to invalid IL or missing references) //IL_1b53: Unknown result type (might be due to invalid IL or missing references) //IL_1b67: Unknown result type (might be due to invalid IL or missing references) //IL_1b7b: Unknown result type (might be due to invalid IL or missing references) //IL_1b80: Unknown result type (might be due to invalid IL or missing references) //IL_1b85: Unknown result type (might be due to invalid IL or missing references) //IL_1b8a: Unknown result type (might be due to invalid IL or missing references) //IL_1bcb: Unknown result type (might be due to invalid IL or missing references) //IL_1bdf: Unknown result type (might be due to invalid IL or missing references) //IL_1bf3: Unknown result type (might be due to invalid IL or missing references) //IL_1bf8: Unknown result type (might be due to invalid IL or missing references) //IL_1bfd: Unknown result type (might be due to invalid IL or missing references) //IL_1c02: Unknown result type (might be due to invalid IL or missing references) //IL_1c43: Unknown result type (might be due to invalid IL or missing references) //IL_1c57: Unknown result type (might be due to invalid IL or missing references) //IL_1c6b: Unknown result type (might be due to invalid IL or missing references) //IL_1c70: Unknown result type (might be due to invalid IL or missing references) //IL_1c75: Unknown result type (might be due to invalid IL or missing references) //IL_1c7a: Unknown result type (might be due to invalid IL or missing references) //IL_1cbb: Unknown result type (might be due to invalid IL or missing references) //IL_1ccf: Unknown result type (might be due to invalid IL or missing references) //IL_1ce3: 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_1cf2: Unknown result type (might be due to invalid IL or missing references) //IL_1d33: Unknown result type (might be due to invalid IL or missing references) //IL_1d47: Unknown result type (might be due to invalid IL or missing references) //IL_1d5b: Unknown result type (might be due to invalid IL or missing references) //IL_1d60: Unknown result type (might be due to invalid IL or missing references) //IL_1d65: Unknown result type (might be due to invalid IL or missing references) //IL_1d6a: Unknown result type (might be due to invalid IL or missing references) //IL_1dab: Unknown result type (might be due to invalid IL or missing references) //IL_1dbf: Unknown result type (might be due to invalid IL or missing references) //IL_1dd3: Unknown result type (might be due to invalid IL or missing references) //IL_1dd8: Unknown result type (might be due to invalid IL or missing references) //IL_1ddd: Unknown result type (might be due to invalid IL or missing references) //IL_1de2: Unknown result type (might be due to invalid IL or missing references) //IL_1e23: Unknown result type (might be due to invalid IL or missing references) //IL_1e37: Unknown result type (might be due to invalid IL or missing references) //IL_1e4b: Unknown result type (might be due to invalid IL or missing references) //IL_1e50: Unknown result type (might be due to invalid IL or missing references) //IL_1e55: Unknown result type (might be due to invalid IL or missing references) //IL_1e5a: Unknown result type (might be due to invalid IL or missing references) //IL_1e9b: Unknown result type (might be due to invalid IL or missing references) //IL_1eaf: Unknown result type (might be due to invalid IL or missing references) //IL_1ec3: Unknown result type (might be due to invalid IL or missing references) //IL_1ec8: Unknown result type (might be due to invalid IL or missing references) //IL_1ecd: Unknown result type (might be due to invalid IL or missing references) //IL_1ed2: Unknown result type (might be due to invalid IL or missing references) //IL_1f13: Unknown result type (might be due to invalid IL or missing references) //IL_1f27: Unknown result type (might be due to invalid IL or missing references) //IL_1f3b: Unknown result type (might be due to invalid IL or missing references) //IL_1f40: Unknown result type (might be due to invalid IL or missing references) //IL_1f45: Unknown result type (might be due to invalid IL or missing references) //IL_1f4a: Unknown result type (might be due to invalid IL or missing references) //IL_1f8b: Unknown result type (might be due to invalid IL or missing references) //IL_1f9f: Unknown result type (might be due to invalid IL or missing references) //IL_1fb3: Unknown result type (might be due to invalid IL or missing references) //IL_1fb8: Unknown result type (might be due to invalid IL or missing references) //IL_1fbd: Unknown result type (might be due to invalid IL or missing references) //IL_1fc2: Unknown result type (might be due to invalid IL or missing references) //IL_2003: Unknown result type (might be due to invalid IL or missing references) //IL_2017: Unknown result type (might be due to invalid IL or missing references) //IL_202b: Unknown result type (might be due to invalid IL or missing references) //IL_2030: Unknown result type (might be due to invalid IL or missing references) //IL_2035: Unknown result type (might be due to invalid IL or missing references) //IL_203a: Unknown result type (might be due to invalid IL or missing references) //IL_207b: Unknown result type (might be due to invalid IL or missing references) //IL_208f: Unknown result type (might be due to invalid IL or missing references) //IL_20a3: Unknown result type (might be due to invalid IL or missing references) //IL_20a8: Unknown result type (might be due to invalid IL or missing references) //IL_20ad: Unknown result type (might be due to invalid IL or missing references) //IL_20b2: Unknown result type (might be due to invalid IL or missing references) //IL_20f3: Unknown result type (might be due to invalid IL or missing references) //IL_2107: Unknown result type (might be due to invalid IL or missing references) //IL_211b: Unknown result type (might be due to invalid IL or missing references) //IL_2120: Unknown result type (might be due to invalid IL or missing references) //IL_2125: Unknown result type (might be due to invalid IL or missing references) //IL_212a: Unknown result type (might be due to invalid IL or missing references) //IL_216b: Unknown result type (might be due to invalid IL or missing references) //IL_217f: Unknown result type (might be due to invalid IL or missing references) //IL_2193: Unknown result type (might be due to invalid IL or missing references) //IL_2198: Unknown result type (might be due to invalid IL or missing references) //IL_219d: Unknown result type (might be due to invalid IL or missing references) //IL_21a2: Unknown result type (might be due to invalid IL or missing references) //IL_21e3: Unknown result type (might be due to invalid IL or missing references) //IL_21f7: Unknown result type (might be due to invalid IL or missing references) //IL_220b: Unknown result type (might be due to invalid IL or missing references) //IL_2210: Unknown result type (might be due to invalid IL or missing references) //IL_2215: Unknown result type (might be due to invalid IL or missing references) //IL_221a: Unknown result type (might be due to invalid IL or missing references) //IL_225b: Unknown result type (might be due to invalid IL or missing references) //IL_226f: Unknown result type (might be due to invalid IL or missing references) //IL_2283: Unknown result type (might be due to invalid IL or missing references) //IL_2288: Unknown result type (might be due to invalid IL or missing references) //IL_228d: Unknown result type (might be due to invalid IL or missing references) //IL_2292: Unknown result type (might be due to invalid IL or missing references) //IL_22d3: Unknown result type (might be due to invalid IL or missing references) //IL_22e7: Unknown result type (might be due to invalid IL or missing references) //IL_22fb: Unknown result type (might be due to invalid IL or missing references) //IL_2300: Unknown result type (might be due to invalid IL or missing references) //IL_2305: Unknown result type (might be due to invalid IL or missing references) //IL_230a: Unknown result type (might be due to invalid IL or missing references) //IL_234b: Unknown result type (might be due to invalid IL or missing references) //IL_235f: Unknown result type (might be due to invalid IL or missing references) //IL_2373: Unknown result type (might be due to invalid IL or missing references) //IL_2378: Unknown result type (might be due to invalid IL or missing references) //IL_237d: Unknown result type (might be due to invalid IL or missing references) //IL_2382: Unknown result type (might be due to invalid IL or missing references) //IL_23c3: Unknown result type (might be due to invalid IL or missing references) //IL_23d7: Unknown result type (might be due to invalid IL or missing references) //IL_23eb: Unknown result type (might be due to invalid IL or missing references) //IL_23f0: Unknown result type (might be due to invalid IL or missing references) //IL_23f5: Unknown result type (might be due to invalid IL or missing references) //IL_23fa: Unknown result type (might be due to invalid IL or missing references) //IL_243b: Unknown result type (might be due to invalid IL or missing references) //IL_244f: Unknown result type (might be due to invalid IL or missing references) //IL_2463: Unknown result type (might be due to invalid IL or missing references) //IL_2468: Unknown result type (might be due to invalid IL or missing references) //IL_246d: Unknown result type (might be due to invalid IL or missing references) //IL_2472: Unknown result type (might be due to invalid IL or missing references) //IL_24b3: Unknown result type (might be due to invalid IL or missing references) //IL_24c7: Unknown result type (might be due to invalid IL or missing references) //IL_24db: Unknown result type (might be due to invalid IL or missing references) //IL_24e0: Unknown result type (might be due to invalid IL or missing references) //IL_24e5: Unknown result type (might be due to invalid IL or missing references) //IL_24ea: Unknown result type (might be due to invalid IL or missing references) //IL_252b: Unknown result type (might be due to invalid IL or missing references) //IL_253f: Unknown result type (might be due to invalid IL or missing references) //IL_2553: Unknown result type (might be due to invalid IL or missing references) //IL_2558: Unknown result type (might be due to invalid IL or missing references) //IL_255d: Unknown result type (might be due to invalid IL or missing references) //IL_2562: Unknown result type (might be due to invalid IL or missing references) //IL_25a3: Unknown result type (might be due to invalid IL or missing references) //IL_25b7: Unknown result type (might be due to invalid IL or missing references) //IL_25cb: Unknown result type (might be due to invalid IL or missing references) //IL_25d0: Unknown result type (might be due to invalid IL or missing references) //IL_25d5: Unknown result type (might be due to invalid IL or missing references) //IL_25da: Unknown result type (might be due to invalid IL or missing references) //IL_261b: Unknown result type (might be due to invalid IL or missing references) //IL_262f: Unknown result type (might be due to invalid IL or missing references) //IL_2643: Unknown result type (might be due to invalid IL or missing references) //IL_2648: Unknown result type (might be due to invalid IL or missing references) //IL_264d: Unknown result type (might be due to invalid IL or missing references) //IL_2652: Unknown result type (might be due to invalid IL or missing references) //IL_2693: Unknown result type (might be due to invalid IL or missing references) //IL_26a7: Unknown result type (might be due to invalid IL or missing references) //IL_26bb: Unknown result type (might be due to invalid IL or missing references) //IL_26c0: Unknown result type (might be due to invalid IL or missing references) //IL_26c5: Unknown result type (might be due to invalid IL or missing references) //IL_26ca: Unknown result type (might be due to invalid IL or missing references) //IL_270b: Unknown result type (might be due to invalid IL or missing references) //IL_271f: Unknown result type (might be due to invalid IL or missing references) //IL_2733: Unknown result type (might be due to invalid IL or missing references) //IL_2738: Unknown result type (might be due to invalid IL or missing references) //IL_273d: Unknown result type (might be due to invalid IL or missing references) //IL_2742: Unknown result type (might be due to invalid IL or missing references) //IL_2783: Unknown result type (might be due to invalid IL or missing references) //IL_2797: Unknown result type (might be due to invalid IL or missing references) //IL_27ab: Unknown result type (might be due to invalid IL or missing references) //IL_27b0: Unknown result type (might be due to invalid IL or missing references) //IL_27b5: Unknown result type (might be due to invalid IL or missing references) //IL_27ba: Unknown result type (might be due to invalid IL or missing references) //IL_27fb: Unknown result type (might be due to invalid IL or missing references) //IL_280f: Unknown result type (might be due to invalid IL or missing references) //IL_2823: Unknown result type (might be due to invalid IL or missing references) //IL_2828: Unknown result type (might be due to invalid IL or missing references) //IL_282d: Unknown result type (might be due to invalid IL or missing references) //IL_2832: Unknown result type (might be due to invalid IL or missing references) //IL_2873: Unknown result type (might be due to invalid IL or missing references) //IL_2887: Unknown result type (might be due to invalid IL or missing references) //IL_289b: 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_28a5: Unknown result type (might be due to invalid IL or missing references) //IL_28aa: Unknown result type (might be due to invalid IL or missing references) //IL_28eb: Unknown result type (might be due to invalid IL or missing references) //IL_28ff: Unknown result type (might be due to invalid IL or missing references) //IL_2913: Unknown result type (might be due to invalid IL or missing references) //IL_2918: Unknown result type (might be due to invalid IL or missing references) //IL_291d: Unknown result type (might be due to invalid IL or missing references) //IL_2922: Unknown result type (might be due to invalid IL or missing references) //IL_2963: Unknown result type (might be due to invalid IL or missing references) //IL_2977: Unknown result type (might be due to invalid IL or missing references) //IL_298b: Unknown result type (might be due to invalid IL or missing references) //IL_2990: Unknown result type (might be due to invalid IL or missing references) //IL_2995: Unknown result type (might be due to invalid IL or missing references) //IL_299a: Unknown result type (might be due to invalid IL or missing references) //IL_29db: Unknown result type (might be due to invalid IL or missing references) //IL_29ef: Unknown result type (might be due to invalid IL or missing references) //IL_2a03: Unknown result type (might be due to invalid IL or missing references) //IL_2a08: Unknown result type (might be due to invalid IL or missing references) //IL_2a0d: Unknown result type (might be due to invalid IL or missing references) //IL_2a12: 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_2a67: Unknown result type (might be due to invalid IL or missing references) //IL_2a7b: Unknown result type (might be due to invalid IL or missing references) //IL_2a80: Unknown result type (might be due to invalid IL or missing references) //IL_2a85: Unknown result type (might be due to invalid IL or missing references) //IL_2a8a: Unknown result type (might be due to invalid IL or missing references) //IL_2acb: Unknown result type (might be due to invalid IL or missing references) //IL_2adf: Unknown result type (might be due to invalid IL or missing references) //IL_2af3: Unknown result type (might be due to invalid IL or missing references) //IL_2af8: Unknown result type (might be due to invalid IL or missing references) //IL_2afd: Unknown result type (might be due to invalid IL or missing references) //IL_2b02: Unknown result type (might be due to invalid IL or missing references) //IL_2b43: Unknown result type (might be due to invalid IL or missing references) //IL_2b57: Unknown result type (might be due to invalid IL or missing references) //IL_2b6b: Unknown result type (might be due to invalid IL or missing references) //IL_2b70: Unknown result type (might be due to invalid IL or missing references) //IL_2b75: Unknown result type (might be due to invalid IL or missing references) //IL_2b7a: Unknown result type (might be due to invalid IL or missing references) //IL_2bbb: Unknown result type (might be due to invalid IL or missing references) //IL_2bcf: Unknown result type (might be due to invalid IL or missing references) //IL_2be3: Unknown result type (might be due to invalid IL or missing references) //IL_2be8: Unknown result type (might be due to invalid IL or missing references) //IL_2bed: Unknown result type (might be due to invalid IL or missing references) //IL_2bf2: Unknown result type (might be due to invalid IL or missing references) //IL_2c33: Unknown result type (might be due to invalid IL or missing references) //IL_2c47: Unknown result type (might be due to invalid IL or missing references) //IL_2c5b: Unknown result type (might be due to invalid IL or missing references) //IL_2c60: Unknown result type (might be due to invalid IL or missing references) //IL_2c65: Unknown result type (might be due to invalid IL or missing references) //IL_2c6a: Unknown result type (might be due to invalid IL or missing references) //IL_2cab: Unknown result type (might be due to invalid IL or missing references) //IL_2cbf: Unknown result type (might be due to invalid IL or missing references) //IL_2cd3: Unknown result type (might be due to invalid IL or missing references) //IL_2cd8: Unknown result type (might be due to invalid IL or missing references) //IL_2cdd: Unknown result type (might be due to invalid IL or missing references) //IL_2ce2: Unknown result type (might be due to invalid IL or missing references) //IL_2d23: Unknown result type (might be due to invalid IL or missing references) //IL_2d37: Unknown result type (might be due to invalid IL or missing references) //IL_2d4b: Unknown result type (might be due to invalid IL or missing references) //IL_2d50: Unknown result type (might be due to invalid IL or missing references) //IL_2d55: Unknown result type (might be due to invalid IL or missing references) //IL_2d5a: Unknown result type (might be due to invalid IL or missing references) //IL_2d9b: Unknown result type (might be due to invalid IL or missing references) //IL_2daf: Unknown result type (might be due to invalid IL or missing references) //IL_2dc3: Unknown result type (might be due to invalid IL or missing references) //IL_2dc8: Unknown result type (might be due to invalid IL or missing references) //IL_2dcd: Unknown result type (might be due to invalid IL or missing references) //IL_2dd2: Unknown result type (might be due to invalid IL or missing references) //IL_2e13: Unknown result type (might be due to invalid IL or missing references) //IL_2e27: Unknown result type (might be due to invalid IL or missing references) //IL_2e3b: Unknown result type (might be due to invalid IL or missing references) //IL_2e40: Unknown result type (might be due to invalid IL or missing references) //IL_2e45: Unknown result type (might be due to invalid IL or missing references) //IL_2e4a: Unknown result type (might be due to invalid IL or missing references) //IL_2e8b: Unknown result type (might be due to invalid IL or missing references) //IL_2e9f: Unknown result type (might be due to invalid IL or missing references) //IL_2eb3: Unknown result type (might be due to invalid IL or missing references) //IL_2eb8: Unknown result type (might be due to invalid IL or missing references) //IL_2ebd: Unknown result type (might be due to invalid IL or missing references) //IL_2ec2: Unknown result type (might be due to invalid IL or missing references) //IL_2f03: Unknown result type (might be due to invalid IL or missing references) //IL_2f17: Unknown result type (might be due to invalid IL or missing references) //IL_2f2b: Unknown result type (might be due to invalid IL or missing references) //IL_2f30: Unknown result type (might be due to invalid IL or missing references) //IL_2f35: Unknown result type (might be due to invalid IL or missing references) //IL_2f3a: Unknown result type (might be due to invalid IL or missing references) //IL_2f7b: Unknown result type (might be due to invalid IL or missing references) //IL_2f8f: Unknown result type (might be due to invalid IL or missing references) //IL_2fa3: Unknown result type (might be due to invalid IL or missing references) //IL_2fa8: Unknown result type (might be due to invalid IL or missing references) //IL_2fad: Unknown result type (might be due to invalid IL or missing references) //IL_2fb2: Unknown result type (might be due to invalid IL or missing references) //IL_2ff3: Unknown result type (might be due to invalid IL or missing references) //IL_3007: Unknown result type (might be due to invalid IL or missing references) //IL_301b: Unknown result type (might be due to invalid IL or missing references) //IL_3020: Unknown result type (might be due to invalid IL or missing references) //IL_3025: Unknown result type (might be due to invalid IL or missing references) //IL_302a: Unknown result type (might be due to invalid IL or missing references) //IL_306b: Unknown result type (might be due to invalid IL or missing references) //IL_307f: Unknown result type (might be due to invalid IL or missing references) //IL_3093: Unknown result type (might be due to invalid IL or missing references) //IL_3098: Unknown result type (might be due to invalid IL or missing references) //IL_309d: Unknown result type (might be due to invalid IL or missing references) //IL_30c2: Unknown result type (might be due to invalid IL or missing references) //IL_30d6: Unknown result type (might be due to invalid IL or missing references) //IL_30ea: Unknown result type (might be due to invalid IL or missing references) //IL_30ef: Unknown result type (might be due to invalid IL or missing references) //IL_30f4: Unknown result type (might be due to invalid IL or missing references) //IL_30f9: Unknown result type (might be due to invalid IL or missing references) //IL_313a: Unknown result type (might be due to invalid IL or missing references) //IL_314e: Unknown result type (might be due to invalid IL or missing references) //IL_3162: Unknown result type (might be due to invalid IL or missing references) //IL_3167: Unknown result type (might be due to invalid IL or missing references) //IL_316c: Unknown result type (might be due to invalid IL or missing references) //IL_3171: Unknown result type (might be due to invalid IL or missing references) //IL_31b2: Unknown result type (might be due to invalid IL or missing references) //IL_31c6: Unknown result type (might be due to invalid IL or missing references) //IL_31da: Unknown result type (might be due to invalid IL or missing references) //IL_31df: Unknown result type (might be due to invalid IL or missing references) //IL_31e4: Unknown result type (might be due to invalid IL or missing references) //IL_31e9: Unknown result type (might be due to invalid IL or missing references) //IL_322a: Unknown result type (might be due to invalid IL or missing references) //IL_323e: Unknown result type (might be due to invalid IL or missing references) //IL_3252: Unknown result type (might be due to invalid IL or missing references) //IL_3257: Unknown result type (might be due to invalid IL or missing references) //IL_325c: Unknown result type (might be due to invalid IL or missing references) //IL_3261: Unknown result type (might be due to invalid IL or missing references) //IL_32a2: Unknown result type (might be due to invalid IL or missing references) //IL_32b6: Unknown result type (might be due to invalid IL or missing references) //IL_32ca: Unknown result type (might be due to invalid IL or missing references) //IL_32cf: Unknown result type (might be due to invalid IL or missing references) //IL_32d4: Unknown result type (might be due to invalid IL or missing references) //IL_32d9: Unknown result type (might be due to invalid IL or missing references) //IL_331a: Unknown result type (might be due to invalid IL or missing references) //IL_332e: Unknown result type (might be due to invalid IL or missing references) //IL_3342: Unknown result type (might be due to invalid IL or missing references) //IL_3347: Unknown result type (might be due to invalid IL or missing references) //IL_334c: Unknown result type (might be due to invalid IL or missing references) //IL_3351: Unknown result type (might be due to invalid IL or missing references) //IL_3392: Unknown result type (might be due to invalid IL or missing references) //IL_33a6: Unknown result type (might be due to invalid IL or missing references) //IL_33ba: Unknown result type (might be due to invalid IL or missing references) //IL_33bf: Unknown result type (might be due to invalid IL or missing references) //IL_33c4: Unknown result type (might be due to invalid IL or missing references) //IL_33e9: Unknown result type (might be due to invalid IL or missing references) //IL_33fd: Unknown result type (might be due to invalid IL or missing references) //IL_3411: Unknown result type (might be due to invalid IL or missing references) //IL_3416: Unknown result type (might be due to invalid IL or missing references) //IL_341b: Unknown result type (might be due to invalid IL or missing references) //IL_3420: Unknown result type (might be due to invalid IL or missing references) //IL_3461: Unknown result type (might be due to invalid IL or missing references) //IL_3475: Unknown result type (might be due to invalid IL or missing references) //IL_3489: Unknown result type (might be due to invalid IL or missing references) //IL_348e: Unknown result type (might be due to invalid IL or missing references) //IL_3493: Unknown result type (might be due to invalid IL or missing references) //IL_3498: Unknown result type (might be due to invalid IL or missing references) //IL_34d9: Unknown result type (might be due to invalid IL or missing references) //IL_34ed: Unknown result type (might be due to invalid IL or missing references) //IL_3501: Unknown result type (might be due to invalid IL or missing references) //IL_3506: Unknown result type (might be due to invalid IL or missing references) //IL_350b: Unknown result type (might be due to invalid IL or missing references) //IL_3510: Unknown result type (might be due to invalid IL or missing references) //IL_3551: Unknown result type (might be due to invalid IL or missing references) //IL_3565: Unknown result type (might be due to invalid IL or missing references) //IL_3579: Unknown result type (might be due to invalid IL or missing references) //IL_357e: Unknown result type (might be due to invalid IL or missing references) //IL_3583: Unknown result type (might be due to invalid IL or missing references) //IL_3588: Unknown result type (might be due to invalid IL or missing references) //IL_35c9: Unknown result type (might be due to invalid IL or missing references) //IL_35dd: Unknown result type (might be due to invalid IL or missing references) //IL_35f1: Unknown result type (might be due to invalid IL or missing references) //IL_35f6: Unknown result type (might be due to invalid IL or missing references) //IL_35fb: Unknown result type (might be due to invalid IL or missing references) //IL_3600: Unknown result type (might be due to invalid IL or missing references) //IL_3641: Unknown result type (might be due to invalid IL or missing references) //IL_3655: Unknown result type (might be due to invalid IL or missing references) //IL_3669: Unknown result type (might be due to invalid IL or missing references) //IL_366e: Unknown result type (might be due to invalid IL or missing references) //IL_3673: Unknown result type (might be due to invalid IL or missing references) //IL_3678: Unknown result type (might be due to invalid IL or missing references) //IL_36b9: Unknown result type (might be due to invalid IL or missing references) //IL_36cd: Unknown result type (might be due to invalid IL or missing references) //IL_36e1: Unknown result type (might be due to invalid IL or missing references) //IL_36e6: Unknown result type (might be due to invalid IL or missing references) //IL_36eb: Unknown result type (might be due to invalid IL or missing references) //IL_36f0: Unknown result type (might be due to invalid IL or missing references) //IL_3731: Unknown result type (might be due to invalid IL or missing references) //IL_3745: Unknown result type (might be due to invalid IL or missing references) //IL_3759: Unknown result type (might be due to invalid IL or missing references) //IL_375e: Unknown result type (might be due to invalid IL or missing references) //IL_3763: Unknown result type (might be due to invalid IL or missing references) //IL_3768: Unknown result type (might be due to invalid IL or missing references) //IL_37a9: Unknown result type (might be due to invalid IL or missing references) //IL_37bd: Unknown result type (might be due to invalid IL or missing references) //IL_37d1: Unknown result type (might be due to invalid IL or missing references) //IL_37d6: Unknown result type (might be due to invalid IL or missing references) //IL_37db: Unknown result type (might be due to invalid IL or missing references) //IL_37e0: Unknown result type (might be due to invalid IL or missing references) //IL_3821: Unknown result type (might be due to invalid IL or missing references) //IL_3835: Unknown result type (might be due to invalid IL or missing references) //IL_3849: Unknown result type (might be due to invalid IL or missing references) //IL_384e: Unknown result type (might be due to invalid IL or missing references) //IL_3853: Unknown result type (might be due to invalid IL or missing references) //IL_3858: Unknown result type (might be due to invalid IL or missing references) //IL_3899: Unknown result type (might be due to invalid IL or missing references) //IL_38ad: Unknown result type (might be due to invalid IL or missing references) //IL_38c1: Unknown result type (might be due to invalid IL or missing references) //IL_38c6: Unknown result type (might be due to invalid IL or missing references) //IL_38cb: Unknown result type (might be due to invalid IL or missing references) //IL_38d0: Unknown result type (might be due to invalid IL or missing references) //IL_3911: 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_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_3948: Unknown result type (might be due to invalid IL or missing references) //IL_3989: Unknown result type (might be due to invalid IL or missing references) //IL_399d: Unknown result type (might be due to invalid IL or missing references) //IL_39b1: Unknown result type (might be due to invalid IL or missing references) //IL_39b6: Unknown result type (might be due to invalid IL or missing references) //IL_39bb: Unknown result type (might be due to invalid IL or missing references) //IL_39c0: Unknown result type (might be due to invalid IL or missing references) //IL_3a01: Unknown result type (might be due to invalid IL or missing references) //IL_3a15: Unknown result type (might be due to invalid IL or missing references) //IL_3a29: Unknown result type (might be due to invalid IL or missing references) //IL_3a2e: Unknown result type (might be due to invalid IL or missing references) //IL_3a33: Unknown result type (might be due to invalid IL or missing references) //IL_3a38: Unknown result type (might be due to invalid IL or missing references) //IL_3a79: Unknown result type (might be due to invalid IL or missing references) //IL_3a8d: Unknown result type (might be due to invalid IL or missing references) //IL_3aa1: Unknown result type (might be due to invalid IL or missing references) //IL_3aa6: Unknown result type (might be due to invalid IL or missing references) //IL_3aab: Unknown result type (might be due to invalid IL or missing references) //IL_3ab0: Unknown result type (might be due to invalid IL or missing references) //IL_3af1: Unknown result type (might be due to invalid IL or missing references) //IL_3b05: Unknown result type (might be due to invalid IL or missing references) //IL_3b19: Unknown result type (might be due to invalid IL or missing references) //IL_3b1e: Unknown result type (might be due to invalid IL or missing references) //IL_3b23: Unknown result type (might be due to invalid IL or missing references) //IL_3b28: Unknown result type (might be due to invalid IL or missing references) //IL_3b69: Unknown result type (might be due to invalid IL or missing references) //IL_3b7d: Unknown result type (might be due to invalid IL or missing references) //IL_3b91: Unknown result type (might be due to invalid IL or missing references) //IL_3b96: Unknown result type (might be due to invalid IL or missing references) //IL_3b9b: Unknown result type (might be due to invalid IL or missing references) //IL_3ba3: Unknown result type (might be due to invalid IL or missing references) //IL_3ba8: Unknown result type (might be due to invalid IL or missing references) //IL_3bad: Unknown result type (might be due to invalid IL or missing references) //IL_3bee: Unknown result type (might be due to invalid IL or missing references) //IL_3c02: Unknown result type (might be due to invalid IL or missing references) //IL_3c16: Unknown result type (might be due to invalid IL or missing references) //IL_3c1b: Unknown result type (might be due to invalid IL or missing references) //IL_3c20: Unknown result type (might be due to invalid IL or missing references) //IL_3c25: Unknown result type (might be due to invalid IL or missing references) //IL_3c66: Unknown result type (might be due to invalid IL or missing references) //IL_3c7a: Unknown result type (might be due to invalid IL or missing references) //IL_3c8e: Unknown result type (might be due to invalid IL or missing references) //IL_3c93: Unknown result type (might be due to invalid IL or missing references) //IL_3c98: Unknown result type (might be due to invalid IL or missing references) //IL_3c9d: Unknown result type (might be due to invalid IL or missing references) //IL_3cde: Unknown result type (might be due to invalid IL or missing references) //IL_3cf2: Unknown result type (might be due to invalid IL or missing references) //IL_3d06: Unknown result type (might be due to invalid IL or missing references) //IL_3d0b: Unknown result type (might be due to invalid IL or missing references) //IL_3d10: Unknown result type (might be due to invalid IL or missing references) //IL_3d15: Unknown result type (might be due to invalid IL or missing references) //IL_3d56: Unknown result type (might be due to invalid IL or missing references) //IL_3d6a: Unknown result type (might be due to invalid IL or missing references) //IL_3d7e: Unknown result type (might be due to invalid IL or missing references) //IL_3d83: Unknown result type (might be due to invalid IL or missing references) //IL_3d88: Unknown result type (might be due to invalid IL or missing references) //IL_3d8d: Unknown result type (might be due to invalid IL or missing references) //IL_3dce: Unknown result type (might be due to invalid IL or missing references) //IL_3de2: Unknown result type (might be due to invalid IL or missing references) //IL_3df6: Unknown result type (might be due to invalid IL or missing references) //IL_3dfb: Unknown result type (might be due to invalid IL or missing references) //IL_3e00: Unknown result type (might be due to invalid IL or missing references) //IL_3e05: Unknown result type (might be due to invalid IL or missing references) //IL_3e46: Unknown result type (might be due to invalid IL or missing references) //IL_3e5a: Unknown result type (might be due to invalid IL or missing references) //IL_3e6e: Unknown result type (might be due to invalid IL or missing references) //IL_3e73: Unknown result type (might be due to invalid IL or missing references) //IL_3e78: Unknown result type (might be due to invalid IL or missing references) //IL_3e7d: Unknown result type (might be due to invalid IL or missing references) //IL_3ebe: Unknown result type (might be due to invalid IL or missing references) //IL_3ed2: Unknown result type (might be due to invalid IL or missing references) //IL_3ee6: Unknown result type (might be due to invalid IL or missing references) //IL_3eeb: Unknown result type (might be due to invalid IL or missing references) //IL_3ef0: Unknown result type (might be due to invalid IL or missing references) //IL_3ef5: Unknown result type (might be due to invalid IL or missing references) //IL_3f36: Unknown result type (might be due to invalid IL or missing references) //IL_3f4a: Unknown result type (might be due to invalid IL or missing references) //IL_3f5e: Unknown result type (might be due to invalid IL or missing references) //IL_3f63: Unknown result type (might be due to invalid IL or missing references) //IL_3f68: Unknown result type (might be due to invalid IL or missing references) //IL_3f6d: Unknown result type (might be due to invalid IL or missing references) itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["AlienHead"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayAlienHead"), "Pelvis", new Vector3(-0.14171f, -0.01943f, 0.05641f), new Vector3(4.1436f, 142.3923f, 192.1287f), new Vector3(1f, 1f, 1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["ArmorPlate"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayRepulsionArmorPlate"), "LowerArmR", new Vector3(0.07217f, 0.15416f, 0.02874f), new Vector3(90f, 209.4232f, 0f), new Vector3(0.3f, 0.3f, 0.3f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["ArmorReductionOnHit"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayWarhammer"), "Pelvis", new Vector3(0.16345f, -0.08755f, 0.15251f), new Vector3(90f, 32.84614f, 0f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["AttackSpeedAndMoveSpeed"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayCoffee"), "Pelvis", new Vector3(-0.2287f, 5E-05f, -0.0272f), new Vector3(-1E-05f, 180f, 180f), new Vector3(0.2f, 0.2f, 0.2f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["AttackSpeedOnCrit"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayWolfPelt"), "Head", new Vector3(0f, 0.12188f, 0.11098f), new Vector3(0f, 0f, 0f), new Vector3(0.5f, 0.5f, 0.5f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["AutoCastEquipment"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayFossil"), "Chest", new Vector3(0.12475f, 0.08006f, 0.16313f), new Vector3(0.95692f, 119.5537f, 8.86006f), new Vector3(0.3f, 0.3f, 0.3f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["Bandolier"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayBandolier"), "UpperArmL", new Vector3(0f, 0.2311f, 0.00155f), new Vector3(90f, 270f, 0f), new Vector3(0.27f, 0.27f, 0.27f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["BarrierOnKill"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayBrooch"), "Chest", new Vector3(-0.09153f, 0.07617f, 0.14477f), new Vector3(307.3344f, 262.4988f, 253.771f), new Vector3(0.6f, 0.6f, 0.6f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["BarrierOnOverHeal"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayAegis"), "LowerArmL", new Vector3(-0.13987f, -0.30531f, -0.06628f), new Vector3(282.8641f, 41.65464f, 255.2802f), new Vector3(0.15f, 0.15f, 0.15f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["Bear"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayBear"), "Chest", new Vector3(0f, 0.13054f, 0.18713f), new Vector3(6.42078f, 0f, 0f), new Vector3(0.25f, 0.25f, 0.25f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["BearVoid"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayBearVoid"), "Chest", new Vector3(0f, 0.13054f, 0.18713f), new Vector3(6.42078f, 0f, 0f), new Vector3(0.25f, 0.25f, 0.25f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["BeetleGland"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayBeetleGland"), "ThighL", new Vector3(-0.10536f, 0.19706f, -1E-05f), new Vector3(0f, 0f, 0f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["Behemoth"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayBehemoth"), "Chest", new Vector3(-0.21211f, 0.30613f, -0.2091f), new Vector3(11.05646f, 0f, 0f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["BleedOnHit"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayTriTip"), "Pelvis", new Vector3(0.20959f, -0.07195f, -0.10003f), new Vector3(322.0855f, 242.4531f, 180f), new Vector3(0.25f, 0.25f, 0.25f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["BleedOnHitAndExplode"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayBleedOnHitAndExplode"), "ThighR", new Vector3(0.14225f, -2E-05f, 0.0814f), new Vector3(31.66996f, 0f, 0f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["BleedOnHitVoid"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayTriTipVoid"), "HandR", new Vector3(0.02101f, 0.05549f, -0.05571f), new Vector3(270f, 345.3987f, 0f), new Vector3(0.15f, 0.15f, 0.15f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["BonusGoldPackOnKill"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayTome"), "Pelvis", new Vector3(0.24617f, 0.11252f, -0.07347f), new Vector3(5.81531f, 116.2075f, 0f), new Vector3(0.075f, 0.075f, 0.075f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["BossDamageBonus"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayAPRound"), "GunL", new Vector3(-0.04594f, 0.15329f, -0.08882f), new Vector3(0f, 0f, 90f), new Vector3(0.5f, 0.5f, 0.5f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["BounceNearby"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayHook"), "LowerArmL", new Vector3(-0.11435f, 0.15668f, -0.00553f), new Vector3(353.6647f, 185.0547f, 178.3664f), new Vector3(0.25f, 0.25f, 0.25f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["ChainLightning"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayUkulele"), "Chest", new Vector3(0f, 0.00792f, -0.16953f), new Vector3(16.63155f, 180f, 0f), new Vector3(0.5f, 0.5f, 0.5f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["ChainLightningVoid"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayUkuleleVoid"), "Chest", new Vector3(0f, 0.00792f, -0.16953f), new Vector3(16.63155f, 180f, 0f), new Vector3(0.5f, 0.5f, 0.5f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["CritDamage"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayLaserSight"), "GunR", new Vector3(0.01965f, 0.12726f, -0.1316f), new Vector3(0f, 90f, 270f), new Vector3(0.15f, 0.15f, 0.15f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["CritGlasses"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayGlasses"), "Head", new Vector3(0f, 0.08009f, 0.17316f), new Vector3(354.9501f, 0f, 0f), new Vector3(0.3f, 0.3f, 0.3f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["CritGlassesVoid"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayGlassesVoid"), "Head", new Vector3(0f, 0.08009f, 0.17316f), new Vector3(354.9501f, 0f, 0f), new Vector3(0.3f, 0.3f, 0.3f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["Crowbar"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayCrowbar"), "Pelvis", new Vector3(0.19026f, -0.00157f, 0.11355f), new Vector3(18.56944f, 296.1121f, 180f), new Vector3(0.2f, 0.2f, 0.2f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["Dagger"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayDagger"), "Chest", new Vector3(-0.04674f, 0.27471f, -0.31614f), new Vector3(284.0471f, 45.62282f, 133.5081f), new Vector3(0.8f, 0.8f, 0.8f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["DeathMark"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayDeathMark"), "UpperArmL", new Vector3(-0.07665f, -0.02692f, -0.09585f), new Vector3(32.59687f, 207.9747f, 140.7682f), new Vector3(0.05f, 0.05f, 0.05f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["ElementalRingVoid"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayVoidRing"), "LowerArmL", new Vector3(-1E-05f, 0.1411f, 0f), new Vector3(90f, 0f, 0f), new Vector3(0.4f, 0.4f, 0.4f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["EnergizedOnEquipmentUse"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayWarHorn"), "Pelvis", new Vector3(0.13576f, -0.06227f, 0.05434f), new Vector3(9.81415f, 13.43985f, 299.9043f), new Vector3(0.3f, 0.3f, 0.3f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["EquipmentMagazine"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayBattery"), "Pelvis", new Vector3(0f, -0.08488f, 0.10961f), new Vector3(0f, 90f, 0f), new Vector3(0.2f, 0.2f, 0.2f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["EquipmentMagazineVoid"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayFuelCellVoid"), "Pelvis", new Vector3(0f, -0.08488f, 0.10961f), new Vector3(0f, 90f, 0f), new Vector3(0.2f, 0.2f, 0.2f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["ExecuteLowHealthElite"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayGuillotine"), "GunL", new Vector3(-0.00174f, 0.15431f, -0.31907f), new Vector3(18.62938f, 183.438f, 264.2258f), new Vector3(0.2f, 0.2f, 0.2f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["ExplodeOnDeath"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayWilloWisp"), "Pelvis", new Vector3(-0.17651f, -3E-05f, 0.15634f), new Vector3(336.4932f, 180f, 180f), new Vector3(0.075f, 0.075f, 0.075f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["ExplodeOnDeathVoid"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayWillowWispVoid"), "Pelvis", new Vector3(-0.17651f, -3E-05f, 0.15634f), new Vector3(336.4932f, 180f, 180f), new Vector3(0.075f, 0.075f, 0.075f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["Feather"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayFeather"), "Head", new Vector3(0f, 0.0578f, -0.10595f), new Vector3(279.7181f, 0f, 0f), new Vector3(0.025f, 0.025f, 0.025f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["FireballsOnHit"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayFireballsOnHit"), "Head", new Vector3(-0.14486f, 0.25261f, -0.16272f), new Vector3(332.0983f, 210.2406f, 334.7576f), new Vector3(0.065f, 0.065f, 0.065f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["FireRing"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayFireRing"), "LowerArmL", new Vector3(-1E-05f, 0.1411f, 0f), new Vector3(90f, 0f, 0f), new Vector3(0.4f, 0.4f, 0.4f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["Firework"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayFirework"), "Pelvis", new Vector3(0.22449f, -0.04647f, 0.11301f), new Vector3(65.04882f, 139.1895f, 82.52743f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["FlatHealth"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplaySteakCurved"), "Head", new Vector3(0f, 0.07622f, 0.17562f), new Vector3(286.1554f, 180f, 155.1997f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["FocusConvergence"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayFocusedConvergence"), "Root", new Vector3(0f, 0.94234f, -0.93766f), new Vector3(0f, 0f, 0f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["FragileDamageBonus"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayDelicateWatch"), "LowerArmR", new Vector3(0.02137f, 0.1949f, 0f), new Vector3(90f, 90f, 0f), new Vector3(0.4f, 0.4f, 0.4f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["FreeChest"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayShippingRequestForm"), "Pelvis", new Vector3(0.18113f, -0.00265f, 0.12588f), new Vector3(287.7112f, 305.2608f, 270f), new Vector3(0.25f, 0.25f, 0.25f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["GhostOnKill"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayMask"), "Chest", new Vector3(0.24529f, 0.08601f, -0.20966f), new Vector3(0.65172f, 90.16528f, 6.45411f), new Vector3(0.7f, 0.7f, 0.7f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["GoldOnHit"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayBoneCrown"), "Head", new Vector3(0f, 0.12377f, -0.03088f), new Vector3(302.9495f, 0f, 0f), new Vector3(1f, 1f, 1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["GoldOnHurt"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayRollOfPennies"), "Pelvis", new Vector3(0.13828f, -0.02651f, 0.14412f), new Vector3(0f, 0f, 0f), new Vector3(0.2f, 0.2f, 0.2f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["HealingPotion"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayHealingPotion"), "Pelvis", new Vector3(-0.19888f, -0.05699f, -1E-05f), new Vector3(-1E-05f, 180f, 162.3634f), new Vector3(0.05f, 0.05f, 0.05f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["HealOnCrit"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayScythe"), "Pelvis", new Vector3(0.16962f, -0.04777f, 0.11641f), new Vector3(90f, 37.87189f, 0f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["HealWhileSafe"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplaySnail"), "HandL", new Vector3(-0.02856f, 1E-05f, -0.0177f), new Vector3(0f, 0f, 0f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["Hoof"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayHoof"), "CalfR", new Vector3(0f, 0.15428f, -0.05221f), new Vector3(70.36934f, 0f, 0f), new Vector3(0.05f, 0.05f, 0.05f)), ItemDisplays.CreateLimbMaskDisplayRule((LimbFlags)8))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["IceRing"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayIceRing"), "LowerArmL", new Vector3(-2E-05f, 0.24577f, 0f), new Vector3(90f, 0f, 0f), new Vector3(0.4f, 0.4f, 0.4f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["Icicle"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayFrostRelic"), "Chest", new Vector3(0.62521f, 0.31365f, -0.43838f), new Vector3(270.7646f, -0.00128f, 310.6224f), new Vector3(1f, 1f, 1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["IgniteOnKill"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayGasoline"), "Muzzle", new Vector3(-0.01185f, -0.36462f, -0.99135f), new Vector3(336.2224f, 0f, 180f), new Vector3(0.75f, 0.75f, 0.75f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["IncreaseHealing"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayAntler"), "Head", new Vector3(-0.1f, 0.15f, 0f), new Vector3(0f, 270f, 0f), new Vector3(0.6f, 0.6f, 0.6f)), ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayAntler"), "Head", new Vector3(0.1f, 0.15f, 0f), new Vector3(0f, 90f, 0f), new Vector3(0.6f, 0.6f, 0.6f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["Infusion"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayInfusion"), "Chest", new Vector3(-0.1508f, 0.08293f, 0.13163f), new Vector3(0f, 308.7207f, 333.9637f), new Vector3(0.4f, 0.4f, 0.4f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["JumpBoost"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayWaxBird"), "Head", new Vector3(0f, 0f, 0f), new Vector3(331.7836f, 0f, 0f), new Vector3(0.4f, 0.4f, 0.4f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["KillEliteFrenzy"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayBrainstalk"), "Head", new Vector3(0f, 0.14749f, -1E-05f), new Vector3(318.3282f, 0f, 23.10016f), new Vector3(0.2f, 0.2f, 0.2f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["Knurl"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayKnurl"), "Muzzle", new Vector3(0.00057f, 0.01422f, -1.1628f), new Vector3(0f, 0f, 0f), new Vector3(0.05f, 0.05f, 0.05f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["LaserTurbine"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayLaserTurbine"), "Muzzle", new Vector3(0f, -0.23113f, -0.67984f), new Vector3(90f, 0f, 0f), new Vector3(0.4f, 0.4f, 0.4f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["LightningStrikeOnHit"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayChargedPerforator"), "Head", new Vector3(0.09219f, 0.22078f, -0.11686f), new Vector3(314.7368f, 0f, 169.6854f), new Vector3(1f, 1f, 1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["LunarDagger"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayLunarDagger"), "Pelvis", new Vector3(0.21635f, -0.10314f, 0.06861f), new Vector3(287.6115f, 89.99998f, 309.7596f), new Vector3(0.3f, 0.3f, 0.3f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["LunarPrimaryReplacement"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayBirdEye"), "Muzzle", new Vector3(0.25815f, -0.08905f, -0.87338f), new Vector3(0f, 0f, 90f), new Vector3(0.4f, 0.4f, 0.4f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["LunarSecondaryReplacement"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayBirdClaw"), "LowerArmL", new Vector3(0f, 0f, 0f), new Vector3(357.6886f, 238.4376f, 175.9198f), new Vector3(1f, 1f, 1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["LunarSpecialReplacement"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayBirdHeart"), "Chest", new Vector3(-0.12501f, 0.14339f, 0.1724f), new Vector3(0f, 0f, 0f), new Vector3(0.2f, 0.2f, 0.2f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["LunarUtilityReplacement"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayBirdFoot"), "ThighL", new Vector3(-0.08354f, 0.13113f, 0.02494f), new Vector3(0f, 84.8299f, 324.7619f), new Vector3(0.75f, 0.75f, 0.75f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["Medkit"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayMedkit"), "Muzzle", new Vector3(-0.15269f, -0.13413f, -0.8174f), new Vector3(270f, 270f, 0f), new Vector3(0.75f, 0.75f, 0.75f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["Missile"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayMissileLauncher"), "HandR", new Vector3(-0.29487f, -0.08857f, -0.29376f), new Vector3(9.60957f, 160.7295f, 261.3232f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["MissileVoid"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayMissileLauncherVoid"), "HandR", new Vector3(-0.29487f, -0.08857f, -0.29376f), new Vector3(9.60957f, 160.7295f, 261.3232f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["MoreMissile"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayICBM"), "GunR", new Vector3(-0.00707f, 0.37915f, 0.09777f), new Vector3(0f, 0f, 0f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["MoveSpeedOnKill"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayGrappleHook"), "Muzzle", new Vector3(0f, -0.02516f, -0.35644f), new Vector3(292.1078f, 89.99996f, 270.0001f), new Vector3(0.2f, 0.2f, 0.2f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["Mushroom"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayMushroom"), "Muzzle", new Vector3(0f, 0.04336f, -1.18973f), new Vector3(290.1331f, 180f, 180f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["MushroomVoid"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayMushroomVoid"), "Muzzle", new Vector3(0f, 0.04336f, -1.18973f), new Vector3(290.1331f, 180f, 180f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["NearbyDamageBonus"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayDiamond"), "Muzzle", new Vector3(0.25217f, -0.09576f, -0.8768f), new Vector3(0f, 0f, 0f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["NovaOnLowHealth"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayJellyGuts"), "HandL", new Vector3(0.03324f, -0.01458f, -0.07482f), new Vector3(352.5879f, 269.5538f, 30.13444f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["OutOfCombatArmor"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayOddlyShapedOpal"), "Chest", new Vector3(0.13739f, 0.21313f, 0.13242f), new Vector3(0f, 0f, 0f), new Vector3(0.2f, 0.2f, 0.2f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["ParentEgg"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayParentEgg"), "Chest", new Vector3(-0.19889f, 0.40627f, -0.32673f), new Vector3(59.30617f, 20.56151f, 357.9481f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["PermanentDebuffOnHit"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayScorpion"), "Pelvis", new Vector3(0f, 0f, 0f), new Vector3(-1E-05f, 180f, 180f), new Vector3(1f, 1f, 1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["PersonalShield"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayShieldGenerator"), "ThighL", new Vector3(0f, 0.23643f, -0.06101f), new Vector3(60f, 180f, 180f), new Vector3(0.25f, 0.25f, 0.25f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["Phasing"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayStealthkit"), "Chest", new Vector3(-0.18265f, 0.26151f, -0.36851f), new Vector3(71.08897f, 195.637f, 180f), new Vector3(0.2f, 0.2f, 0.2f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["PrimarySkillShuriken"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayShuriken"), "HandL", new Vector3(-0.02145f, 0.05095f, -0.04379f), new Vector3(90f, 0f, 0f), new Vector3(0.25f, 0.25f, 0.25f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["RandomDamageZone"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayRandomDamageZone"), "Chest", new Vector3(1E-05f, 0.06566f, -0.09133f), new Vector3(0f, 0f, 0f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["RegeneratingScrap"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayRegeneratingScrap"), "ThighL", new Vector3(-0.10349f, -0.02032f, -0.02738f), new Vector3(12.67568f, 105.6867f, 190.2213f), new Vector3(0.2f, 0.2f, 0.2f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["SecondarySkillMagazine"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayDoubleMag"), "GunL", new Vector3(0.03626f, 0.25043f, 0.26051f), new Vector3(286.2324f, 180f, 180f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["Seed"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplaySeed"), "LowerArmL", new Vector3(-0.05619f, 0.07175f, 0.01755f), new Vector3(323.4312f, 249.3649f, -1E-05f), new Vector3(0.025f, 0.025f, 0.025f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["ShockNearby"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayTeslaCoil"), "Chest", new Vector3(-0.13793f, 0.1943f, -0.28491f), new Vector3(285.1101f, 0f, 10.00615f), new Vector3(0.2f, 0.2f, 0.2f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["SiphonOnLowHealth"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplaySiphonOnLowHealth"), "CalfL", new Vector3(0f, 0.09453f, -0.0653f), new Vector3(-1E-05f, 180f, 180f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["SlowOnHit"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayBauble"), "Chest", new Vector3(0.03091f, -1E-05f, 0f), new Vector3(0f, 338.3918f, 0f), new Vector3(0.4f, 0.4f, 0.4f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["SlowOnHitVoid"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayBaubleVoid"), "Chest", new Vector3(0.03091f, -1E-05f, 0f), new Vector3(0f, 338.3918f, 0f), new Vector3(0.4f, 0.4f, 0.4f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["SprintArmor"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayBuckler"), "Chest", new Vector3(0.25978f, 0.31751f, -0.1879f), new Vector3(341.1178f, 100.978f, 19.03026f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["SprintBonus"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplaySoda"), "HandR", new Vector3(0.04132f, -0.01992f, -0.07778f), new Vector3(0f, 82.02044f, 0f), new Vector3(0.4f, 0.4f, 0.4f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["SprintOutOfCombat"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayWhip"), "Pelvis", new Vector3(-0.26018f, 0.00331f, 0.00927f), new Vector3(-1E-05f, 180f, 154.7494f), new Vector3(0.25f, 0.25f, 0.25f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["SprintWisp"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayBrokenMask"), "ThighR", new Vector3(-1E-05f, 0.24895f, -0.03441f), new Vector3(317.3214f, 180f, 180f), new Vector3(0.2f, 0.2f, 0.2f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["Squid"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplaySquidTurret"), "CalfR", new Vector3(0.13508f, 0.15426f, -0.04073f), new Vector3(75.20986f, 0f, 270f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["StickyBomb"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayStickyBomb"), "GunL", new Vector3(0.051f, 0.14163f, 0.16179f), new Vector3(18.39093f, 337.0306f, 327.8457f), new Vector3(0.2f, 0.2f, 0.2f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["StrengthenBurn"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayGasTank"), "Chest", new Vector3(-0.18644f, 0.31352f, -0.27416f), new Vector3(40.70905f, 13.07178f, 1.2476f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["StunChanceOnHit"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayStunGrenade"), "Pelvis", new Vector3(-0.18795f, -1E-05f, -0.07074f), new Vector3(70.49339f, 156.6409f, 89.99998f), new Vector3(1f, 1f, 1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["Syringe"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplaySyringeCluster"), "UpperArmR", new Vector3(0.01845f, 0.03001f, 3E-05f), new Vector3(0f, 0f, 270f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["Talisman"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayTalisman"), "Chest", new Vector3(0.04948f, 4E-05f, -0.90166f), new Vector3(0f, 329.0994f, 0f), new Vector3(1f, 1f, 1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["Thorns"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayRazorwireLeft"), "UpperArmL", new Vector3(0f, 0f, 0f), new Vector3(0f, 0f, 0f), new Vector3(0.3f, 0.3f, 0.3f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["TitanGoldDuringTP"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayGoldHeart"), "Head", new Vector3(-0.23181f, 0.19679f, -0.05975f), new Vector3(10.11879f, 316.8379f, 317.6933f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["TPHealingNova"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayGlowFlower"), "Head", new Vector3(0.12438f, 0.08503f, -0.15264f), new Vector3(10.61431f, 132.4948f, 188.6654f), new Vector3(0.2f, 0.2f, 0.2f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["TreasureCache"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayKey"), "Pelvis", new Vector3(0.20025f, -0.06225f, 0.12587f), new Vector3(13.68541f, 321.1866f, 279.4453f), new Vector3(0.6f, 0.6f, 0.6f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["TreasureCacheVoid"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayKeyVoid"), "Pelvis", new Vector3(0.20025f, -0.06225f, 0.12587f), new Vector3(13.68541f, 321.1866f, 279.4453f), new Vector3(0.6f, 0.6f, 0.6f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["UtilitySkillMagazine"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayAfterburnerShoulderRing"), "UpperArmR", new Vector3(0f, 0f, 0f), new Vector3(0f, 0f, 101.8453f), new Vector3(0.25f, 0.25f, 0.25f)), ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayAfterburnerShoulderRing"), "UpperArmL", new Vector3(0f, 0f, 0f), new Vector3(5.87933f, 209.4046f, 79.69863f), new Vector3(0.25f, 0.25f, 0.25f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["VoidMegaCrabItem"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayMegaCrabItem"), "CalfL", new Vector3(0f, 0f, 0f), new Vector3(37.94162f, 0f, 0f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["WarCryOnMultiKill"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayPauldron"), "UpperArmL", new Vector3(0.03709f, 0.22272f, 0.04961f), new Vector3(38.78278f, 10.44462f, 353.4107f), new Vector3(0.5f, 0.5f, 0.5f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["WardOnLevel"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayWarbanner"), "GunR", new Vector3(-2E-05f, 0.23067f, 0.15244f), new Vector3(270f, 90.00001f, 0f), new Vector3(0.25f, 0.25f, 0.25f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["BFG"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayBFG"), "Chest", new Vector3(0.08595f, 0.21269f, -0.14902f), new Vector3(356.9302f, 341.8869f, 322.5006f), new Vector3(0.4f, 0.4f, 0.4f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["Blackhole"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayGravCube"), "Chest", new Vector3(0.60421f, 0.28603f, -0.57657f), new Vector3(0f, 0f, 0f), new Vector3(0.7f, 0.7f, 0.7f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["BossHunter"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayTricornGhost"), "Head", new Vector3(0.02756f, 0.33536f, -0.04116f), new Vector3(26.22608f, 0f, 0f), new Vector3(1f, 1f, 1f)), ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayBlunderbuss"), "Chest", new Vector3(0.9303f, 0.75718f, -0.2324f), new Vector3(90f, 315.9429f, 0f), new Vector3(1f, 1f, 1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["BossHunterConsumed"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayTricornUsed"), "Head", new Vector3(0.02756f, 0.33536f, -0.04116f), new Vector3(26.22608f, 0f, 0f), new Vector3(1f, 1f, 1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["BurnNearby"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayPotion"), "HandL", new Vector3(0.02877f, -0.03763f, -0.10299f), new Vector3(0f, 0f, 29.77753f), new Vector3(0.05f, 0.05f, 0.05f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["Cleanse"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayWaterPack"), "Chest", new Vector3(1E-05f, 0.08202f, -0.1285f), new Vector3(0f, 180f, 0f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["CommandMissile"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayMissileRack"), "Chest", new Vector3(0f, 0.22281f, -0.24387f), new Vector3(84.18402f, 180f, 0f), new Vector3(0.5f, 0.5f, 0.5f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["CritOnUse"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayNeuralImplant"), "Head", new Vector3(-1E-05f, 0.31177f, 0.69472f), new Vector3(0f, 0f, 0f), new Vector3(0.25f, 0.25f, 0.25f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["DeathProjectile"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayDeathProjectile"), "HandL", new Vector3(-0.08925f, -0.02373f, -0.07659f), new Vector3(70.75671f, 282.3277f, 11.65827f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["DroneBackup"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayRadio"), "Pelvis", new Vector3(0.19548f, -0.04333f, -0.05619f), new Vector3(0f, 83.19177f, 180f), new Vector3(0.5f, 0.5f, 0.5f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["FireBallDash"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayEgg"), "Pelvis", new Vector3(0.15962f, -2E-05f, -0.00138f), new Vector3(90f, 0f, 0f), new Vector3(0.3f, 0.3f, 0.3f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["Fruit"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayFruit"), "Chest", new Vector3(-0.06597f, -0.09094f, -0.13058f), new Vector3(0f, 49.20116f, 0f), new Vector3(0.3f, 0.3f, 0.3f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["GainArmor"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayElephantFigure"), "Head", new Vector3(0f, 0.24203f, -0.10288f), new Vector3(323.0464f, 0f, 0f), new Vector3(0.6f, 0.6f, 0.6f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["Gateway"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayVase"), "Chest", new Vector3(0f, 0.18661f, -0.24945f), new Vector3(0f, 0f, 0f), new Vector3(0.3f, 0.3f, 0.3f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["GoldGat"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayGoldGat"), "Chest", new Vector3(-0.2049f, 0.69364f, -0.29167f), new Vector3(348.3431f, 45.79039f, 356.165f), new Vector3(0.2f, 0.2f, 0.2f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["GummyClone"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayGummyClone"), "Head", new Vector3(-0.04215f, 0.11151f, -0.1261f), new Vector3(0f, 0f, 0f), new Vector3(0.2f, 0.2f, 0.2f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["Jetpack"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayBugWings"), "Chest", new Vector3(0f, 1E-05f, -0.0821f), new Vector3(15.77955f, 0f, 0f), new Vector3(0.15f, 0.15f, 0.15f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["LifestealOnHit"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayLifestealOnHit"), "LowerArmL", new Vector3(-0.00444f, 0.00267f, 0.11214f), new Vector3(336.7938f, 180f, 180f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["Lightning"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayLightningArmRight"), "Chest", new Vector3(2f, 2f, 2f), new Vector3(0f, 0f, 0f), new Vector3(1f, 1f, 1f)), ItemDisplays.CreateLimbMaskDisplayRule((LimbFlags)2))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["Molotov"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayMolotov"), "Pelvis", new Vector3(-0.1736f, -1E-05f, 0f), new Vector3(-1E-05f, 180f, 180f), new Vector3(0.2f, 0.2f, 0.2f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["MultiShopCard"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayExecutiveCard"), "Pelvis", new Vector3(0.18102f, -0.03633f, 0.13942f), new Vector3(0.42736f, 306.6231f, 255.2241f), new Vector3(0.7f, 0.7f, 0.7f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["QuestVolatileBattery"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayBatteryArray"), "Muzzle", new Vector3(0.07208f, -0.07546f, -1.13104f), new Vector3(53.5405f, 0f, 0f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["Recycle"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayRecycler"), "ThighR", new Vector3(0.14144f, 0.12928f, 0.00333f), new Vector3(318.6689f, 180f, 180f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["Saw"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplaySawmerangFollower"), "Root", new Vector3(-0.54368f, 0.8338f, -1.15286f), new Vector3(90f, 0f, 0f), new Vector3(0.1f, 0.1f, 0.1f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["Scanner"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayScanner"), "Chest", new Vector3(-0.04659f, 0.22645f, -0.16198f), new Vector3(334.027f, 182.4031f, 178.9471f), new Vector3(0.2f, 0.2f, 0.2f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["TeamWarCry"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayTeamWarCry"), "Chest", new Vector3(0f, 0.20426f, -0.20374f), new Vector3(0f, 180f, 0f), new Vector3(0.05f, 0.05f, 0.05f)))); itemDisplayRules.Add(ItemDisplays.CreateDisplayRuleGroupWithRules(ItemDisplays.KeyAssets["VendingMachine"], ItemDisplays.CreateDisplayRule(ItemDisplays.LoadDisplay("DisplayVendingMachine"), "Pelvis", new Vector3(0.1803f, -0.04813f, -0.08484f), new Vector3(0f, 0f, 180f), new Vector3(0.2f, 0.2f, 0.2f)))); } } public class GhoulItemDropTable : ExplicitPickupDropTable { public PickupDefEntry[] itemEntries = (PickupDefEntry[])(object)new PickupDefEntry[4] { new PickupDefEntry { pickupDef = (Object)(object)GhoulItems.defaultEnragedItemDef, pickupWeight = 3f }, new PickupDefEntry { pickupDef = (Object)(object)GhoulItems.slamItemDef, pickupWeight = 2f }, new PickupDefEntry { pickupDef = (Object)(object)GhoulItems.thirdEyeItemDef, pickupWeight = 2f }, new PickupDefEntry { pickupDef = (Object)(object)GhoulItems.thirdEyeItemDef, pickupWeight = 2f } }; public override void Regenerate(Run run) { base.pickupEntries = itemEntries; ((ExplicitPickupDropTable)this).Regenerate(run); } } public class GhoulItems { public static ItemDef testItemDef; public static ItemDef defaultEnragedItemDef; public static ItemDef slamItemDef; public static ItemDef thirdEyeItemDef; public static ItemDef overlordItemDef; public static ItemDef vultureBoneItemDef; public static ItemTierDef mutationTier; private static string prefix = "VCR_GHOUL_"; private static AssetBundle bundle; public static void Init(AssetBundle assetBundle) { bundle = assetBundle; CreateItemTier(); CreateItems(); } private static void CreateItems() { //IL_044d: Unknown result type (might be due to invalid IL or missing references) //IL_0453: Expected O, but got Unknown //IL_0459: Unknown result type (might be due to invalid IL or missing references) //IL_045f: Expected O, but got Unknown //IL_0465: Unknown result type (might be due to invalid IL or missing references) //IL_046b: Expected O, but got Unknown //IL_0471: Unknown result type (might be due to invalid IL or missing references) //IL_0477: Expected O, but got Unknown //IL_047d: Unknown result type (might be due to invalid IL or missing references) //IL_0484: Expected O, but got Unknown //IL_048a: Unknown result type (might be due to invalid IL or missing references) //IL_0491: Expected O, but got Unknown testItemDef = ScriptableObject.CreateInstance(); ((Object)testItemDef).name = "GhoulTestItem"; testItemDef.nameToken = prefix + "TEST_ITEM_NAME"; testItemDef.descriptionToken = prefix + "TEST_ITEM_DESCRIPTION"; testItemDef.pickupToken = prefix + "TEST_ITEM_DESCRIPTION"; testItemDef.loreToken = prefix + "TestTest"; testItemDef._itemTierDef = mutationTier; testItemDef.canRemove = false; ItemDef obj = testItemDef; ItemTag[] array = new ItemTag[7]; RuntimeHelpers.InitializeArray(array, (RuntimeFieldHandle)/*OpCode not supported: LdMemberToken*/); obj.tags = (ItemTag[])(object)array; defaultEnragedItemDef = ScriptableObject.CreateInstance(); ((Object)defaultEnragedItemDef).name = "GhoulDefaultEnraged"; defaultEnragedItemDef.nameToken = prefix + "DEFAULT_ENRAGED_ITEM_NAME"; defaultEnragedItemDef.descriptionToken = prefix + "DEFAULT_ENRAGED_ITEM_DESCRIPTION"; defaultEnragedItemDef.pickupToken = prefix + "DEFAULT_ENRAGED_ITEM_DESCRIPTION"; defaultEnragedItemDef.loreToken = prefix + "Erm Slam them all?"; defaultEnragedItemDef.pickupIconSprite = bundle.LoadAsset("texGnawHungIcon"); defaultEnragedItemDef.pickupModelPrefab = bundle.LoadAsset("GhoulEssencePickupPrefab"); defaultEnragedItemDef._itemTierDef = mutationTier; defaultEnragedItemDef.canRemove = false; ItemDef obj2 = defaultEnragedItemDef; ItemTag[] array2 = new ItemTag[7]; RuntimeHelpers.InitializeArray(array2, (RuntimeFieldHandle)/*OpCode not supported: LdMemberToken*/); obj2.tags = (ItemTag[])(object)array2; thirdEyeItemDef = ScriptableObject.CreateInstance(); ((Object)thirdEyeItemDef).name = "GhoulThirdEye"; thirdEyeItemDef.nameToken = prefix + "THIRD_EYE_ITEM_NAME"; thirdEyeItemDef.descriptionToken = prefix + "THIRD_EYE_ITEM_DESCRIPTION"; thirdEyeItemDef.pickupToken = prefix + "THIRD_EYE_ITEM_DESCRIPTION"; thirdEyeItemDef.loreToken = prefix + "Erm See them all?"; thirdEyeItemDef.pickupIconSprite = bundle.LoadAsset("texGnawHungIcon"); thirdEyeItemDef.pickupModelPrefab = bundle.LoadAsset("GhoulEssencePickupPrefab"); thirdEyeItemDef._itemTierDef = mutationTier; thirdEyeItemDef.canRemove = false; ItemDef obj3 = thirdEyeItemDef; ItemTag[] array3 = new ItemTag[7]; RuntimeHelpers.InitializeArray(array3, (RuntimeFieldHandle)/*OpCode not supported: LdMemberToken*/); obj3.tags = (ItemTag[])(object)array3; slamItemDef = ScriptableObject.CreateInstance(); ((Object)slamItemDef).name = "GhoulSlam"; slamItemDef.nameToken = prefix + "SLAM_ITEM_NAME"; slamItemDef.descriptionToken = prefix + "SLAM_ITEM_DESCRIPTION"; slamItemDef.pickupToken = prefix + "SLAM_ITEM_DESCRIPTION"; slamItemDef.loreToken = prefix + "Erm Smash them all?"; slamItemDef.pickupIconSprite = bundle.LoadAsset("texGnawHungIcon"); slamItemDef.pickupModelPrefab = bundle.LoadAsset("GhoulEssencePickupPrefab"); slamItemDef._itemTierDef = mutationTier; slamItemDef.canRemove = false; ItemDef obj4 = slamItemDef; ItemTag[] array4 = new ItemTag[7]; RuntimeHelpers.InitializeArray(array4, (RuntimeFieldHandle)/*OpCode not supported: LdMemberToken*/); obj4.tags = (ItemTag[])(object)array4; overlordItemDef = ScriptableObject.CreateInstance(); ((Object)overlordItemDef).name = "GhoulOverlord"; overlordItemDef.nameToken = prefix + "ONE_EYE_KING_ITEM_NAME"; overlordItemDef.descriptionToken = prefix + "ONE_EYE_KING_ITEM_DESCRIPTION"; overlordItemDef.pickupToken = prefix + "ONE_EYE_KING_ITEM_DESCRIPTION"; overlordItemDef.loreToken = prefix + "Erm Rule them all?"; overlordItemDef.pickupIconSprite = bundle.LoadAsset("texGnawHungIcon"); overlordItemDef.pickupModelPrefab = bundle.LoadAsset("GhoulEssencePickupPrefab"); overlordItemDef._itemTierDef = mutationTier; overlordItemDef.canRemove = false; ItemDef obj5 = overlordItemDef; ItemTag[] array5 = new ItemTag[7]; RuntimeHelpers.InitializeArray(array5, (RuntimeFieldHandle)/*OpCode not supported: LdMemberToken*/); obj5.tags = (ItemTag[])(object)array5; ItemDisplayRuleDict val = new ItemDisplayRuleDict(Array.Empty()); CustomItem val2 = new CustomItem(defaultEnragedItemDef, val); CustomItem val3 = new CustomItem(slamItemDef, val); CustomItem val4 = new CustomItem(thirdEyeItemDef, val); CustomItem val5 = new CustomItem(overlordItemDef, val); CustomItem val6 = new CustomItem(testItemDef, val); ItemAPI.Add(val2); ItemAPI.Add(val4); ItemAPI.Add(val5); ItemAPI.Add(val3); ItemAPI.Add(val6); } private static void CreateItemTier() { //IL_0006: Unknown result type (might be due to invalid IL or missing references) //IL_000b: Unknown result type (might be due to invalid IL or missing references) //IL_0057: 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_0090: 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) mutationTier = Object.Instantiate(Addressables.LoadAssetAsync((object)"RoR2/Base/Common/BossTierDef.asset").WaitForCompletion()); ((Object)mutationTier).name = "GhoulMutationTier"; mutationTier.canRestack = false; mutationTier.canScrap = false; mutationTier.tier = (ItemTier)11; mutationTier._tier = (ItemTier)11; mutationTier.isDroppable = false; mutationTier.canScrap = false; mutationTier.canRestack = false; mutationTier.colorIndex = (ColorIndex)9; mutationTier.darkColorIndex = (ColorIndex)9; mutationTier.pickupRules = (PickupRules)0; ContentAddition.AddItemTierDef(mutationTier); } } public static class GhoulStates { public static void Init() { Content.AddEntityState(typeof(TentacleStrike)); Content.AddEntityState(typeof(TentacleSweep)); Content.AddEntityState(typeof(PreTentacleGrapple)); Content.AddEntityState(typeof(TapGrapple)); Content.AddEntityState(typeof(HoldGrapple)); Content.AddEntityState(typeof(EnragedGrapple)); Content.AddEntityState(typeof(EnragedGrab)); Content.AddEntityState(typeof(AltGrapple)); Content.AddEntityState(typeof(AltGrappleFallState)); Content.AddEntityState(typeof(AltGrappleBounce)); Content.AddEntityState(typeof(AltGrappleThrowAttack)); Content.AddEntityState(typeof(AltGrappleThrownState)); Content.AddEntityState(typeof(BlockStart)); Content.AddEntityState(typeof(BlockCounter)); Content.AddEntityState(typeof(EnragedSpin)); Content.AddEntityState(typeof(AltBlock)); Content.AddEntityState(typeof(SlamFall)); Content.AddEntityState(typeof(DashStart)); Content.AddEntityState(typeof(DashAttack)); Content.AddEntityState(typeof(Tantalize)); Content.AddEntityState(typeof(Binge)); Content.AddEntityState(typeof(ShootImpSpike)); Content.AddEntityState(typeof(GhoulMainState)); Content.AddEntityState(typeof(GhoulSpawnState)); Content.AddEntityState(typeof(EnrageTransitionIn)); Content.AddEntityState(typeof(EnrageTransitionOut)); Content.AddEntityState(typeof(ClingBaseState)); Content.AddEntityState(typeof(GhoulClingState)); Content.AddEntityState(typeof(EndClingState)); } } public static class GhoulStaticValues { public const float tentacleDamageCoefficient = 2.6f; public const float tentacleSweepDamageCoefficient = 3.6f; public const float grappleRange = 58f; public const float grabChompDamageCoefficient = 5f; public const float grappleAttackDamageCoefficient = 1.2f; public const float altGrappleDamageCoefficient = 2f; public const float altGrappleSlamDamageCoefficient = 6f; public const float blockCounterDamageCoefficient = 4f; public const float spinWeakDamageCoefficient = 3.4f; public const float spinDamageCoefficient = 4f; public const float slamDamageCoefficient = 12f; public const float feedingDamageCoefficient = 6.25f; public const float hungryStabDamageCoefficient = 1.8f; public const float bingeDamageCoefficient = 2.8f; public const float impSpikeDamageCoeffiecient = 2.5f; } public static class GhoulTokens { public static void Init() { AddGhoulTokens(); } public static void AddGhoulTokens() { string text = "VCR_GHOUL_"; string text2 = "The Ghoul is a frenzied mid-ranged melee survivor that enters a feral rage, influencing their abilities. What caused this warped evolution? Nonetheless it's hellbent on one goal: sate it's neverending hunger." + Environment.NewLine + Environment.NewLine + "< ! > With it's natural regeneration stunted, it must damage enemies to nourish it's starved body." + Environment.NewLine + Environment.NewLine + "< ! > Ravenous Leap grants extreme map traversal and rapid movement with quick reaction time, releasing at the right time retains the most momentum." + Environment.NewLine + Environment.NewLine + "< ! > Retaliate blocks most incoming damage, charging up speed for the following dodge." + Environment.NewLine + Environment.NewLine + "< ! > Feeding Frenzy acts as a good finisher, resetting skill cooldowns on kill." + Environment.NewLine + Environment.NewLine; string text3 = "..and so it left, it's hunger unsated."; string text4 = "..and so it vanished, the trauma sticking with those who escaped."; string text5 = "Nourish"; string text6 = "Incident Report" + Environment.NewLine + "Transcript of recovered comms chatter:" + Environment.NewLine + Environment.NewLine + "''That THING is not an imp!''" + Environment.NewLine + Environment.NewLine + "''I know an imp when I see one, I've pushed them back through their portals by the hundreds!''" + Environment.NewLine + Environment.NewLine + "''Man, I know what I saw! That thing was...eating one of them. The imps.''" + Environment.NewLine + Environment.NewLine + "''Damnit Soldier, get yourself together! And save the fairy tales for scaring the men around the campfire tonight. I want a proper report on the situation. Not losing anyone else to this thing.''" + Environment.NewLine + Environment.NewLine + "''...S-Sir, I wish I was kidding. Back at the crash site when we were recovering what was left of the Lieutenant, I heard noises behind one of the cargo containers. I found that...creature, squatting over the corpse of an imp, devouring it whole. It noticed me as I approached and sprouted...tendrils? And leapt away. But something around its neck got caught and left behind. I-I think you need to see this, sir.''" + Environment.NewLine + Environment.NewLine + "''What in the hell could possibly be this important? Gimme that, let's see what we're deali-" + Environment.NewLine + "No..." + Environment.NewLine + "Nonononono, that can't be right..." + Environment.NewLine + Environment.NewLine + "Get Command on the line, NOW!''" + Environment.NewLine + Environment.NewLine + Environment.NewLine + "Further radio chatter unrecoverable due to extensive damage of comms hardware." + Environment.NewLine + Environment.NewLine + Environment.NewLine + "Other recovered materials include:" + Environment.NewLine + Environment.NewLine + "- Two (2) UES Standard issue pistols" + Environment.NewLine + "Notes: Two empty magazines found in close proximity. One pistol had a third magazine forced in backwards." + Environment.NewLine + Environment.NewLine + "- The bodies and gear of Ensign [REDACTED] and Lt. Commander [REDACTED]." + Environment.NewLine + "Notes: Identity was only able to be confirmed with DNA match." + Environment.NewLine + Environment.NewLine + "- Three (3) UES Dog Tags" + Environment.NewLine + "Notes: Required extensive cleaning and sanitizing. Two matched the bodies recovered." + Environment.NewLine + "Remaining dog tag is not a member of [REDACTED] Squad, as all have been recovered. Unable to determine name on the tag, due to excessive warping and discoloration of the metal."; Language.Add(text + "NAME", "Ghoul"); Language.Add(text + "DESCRIPTION", text2); Language.Add(text + "SUBTITLE", "Starved and Corrupt"); Language.Add(text + "LORE", text6); Language.Add(text + "OUTRO_FLAVOR", text3); Language.Add(text + "OUTRO_FAILURE", text4); Language.Add(text + "DEFAULT_SKIN_NAME", "Default"); Language.Add(text + "DEFAULT_SKIN_DESC", "In the darkness, a red eye staring back was the last thing he saw."); Language.Add(text + "MASTERY_SKIN_NAME", "Tokyo"); Language.Add(text + "MASTERY_SKIN_DESC", "It was him, John Ghoul"); Language.Add(text + "GRAND_MASTERY_SKIN_NAME", "Fresh Blood"); Language.Add(text + "GRAND_MASTERY_SKIN_DESC", "She lived vicariously though her new host, ever tempting his hunger."); Language.Add(text + "CANNIBAL_MASTERY_SKIN_NAME", "Unraveled"); Language.Add(text + "CANNIBAL_MASTERY_SKIN_DESC", "Battered and broken, he indulged in his own."); Language.Add(text + "CARNAGE_SKIN_NAME", "Carnage"); Language.Add(text + "CARNAGE_SKIN_DESC", "An unholy union bound in blood."); Language.Add(text + "EARLY_SUPPORTER_SKIN_NAME", "Early Supporter"); Language.Add(text + "CLEANSED_SKIN_NAME", "Cleansed"); Language.Add(text + "VOID_SKIN_NAME", "Infested"); Language.Add(text + "VOID_SKIN_DESC", "It was found within the prison out of time. Adapting, Consuming."); Language.Add(text + "PASSIVE_NAME", "Abyss Starved"); Language.Add(text + "PASSIVE_DESCRIPTION", text5 + " yourself on enemies to regain health."); Language.Add(text + "ALT_PASSIVE_NAME", "Hellish Mutation"); Language.Add(text + "ALT_PASSIVE_DESCRIPTION", "Filling the Rage meter summons a feral mutated Ghoul once per stage. Slaying them drops Essence to Evolve with."); Language.Add(text + "MISC_NAME", "Feral Rage"); Language.Add(text + "MISC_DESCRIPTION", "Build Rage by dealing or taking damage. When full, all skills gain Enraged effects for a brief duration"); Language.Add(text + "PRIMARY_STAB_NAME", "Gnawing Hunger"); Language.Add(text + "PRIMARY_STAB_DESCRIPTION", "3% " + text5 + $". Impale enemies with your tendrils for {260f}% damage."); Language.Add(text + "PRIMARY_SWEEP_NAME", "Tenderize"); Language.Add(text + "PRIMARY_SWEEP_DESCRIPTION", "4% " + text5 + $". Batter enemies with wide sweeps for {360f}% damage."); Language.Add(text + "SECONDARY_GRAPPLE_NAME", "Ravenous Lunge"); Language.Add(text + "SECONDARY_GRAPPLE_DESCRIPTION", "Anchor your tendrils into terrain. Tap to quickly pull toward anchor, hold to swing in look direction."); Language.Add(text + "SECONDARY_ALTGRAPPLE_NAME", "Hollow Agility"); Language.Add(text + "SECONDARY_ALTGRAPPLE_DESCRIPTION", $"Pull yourself toward enemies and slash for {200f}% before bouncing away."); Language.Add(text + "UTILITY_BLOCK_NAME", "Retaliate"); Language.Add(text + "UTILITY_BLOCK_DESCRIPTION", "10% " + text5 + $". Charge to gain 125 armor then launch forward for {340f}% damage."); Language.Add(text + "UTILITY_ENRAGED_SPIN_NAME", "Gormand"); Language.Add(text + "UTILITY_ENRAGED_SPIN_DESCRIPTION", "8% " + text5 + $". Bound through the air for {400f}% damage. Ends Feral Rage on miss."); Language.Add(text + "ALT_UTILITY_BLOCK_NAME", "Kebab"); Language.Add(text + "ALT_UTILITY_BLOCK_DESCRIPTION", "15% " + text5 + $". Charge to absorb incoming damage then skewer for {400f}% damage. Scales with damage absorbed."); Language.Add(text + "UTILITY_ENRAGED_DEVOUR_NAME", "Kebab"); Language.Add(text + "UTILITY_ENRAGED_DEVOUR_DESCRIPTION", "15% " + text5 + $". Charge to absorb incoming damage then skewer for {400f}% damage. Scales with damage absorbed."); Language.Add(text + "THIRD_EYE_SCREAM_NAME", "Howl"); Language.Add(text + "THIRD_EYE_SCREAM_DESCRIPTION", "Release the building wails of pain. Perhaps this parasite is not "); Language.Add(text + "SPECIAL_FRENZY_NAME", "Feeding Frenzy"); Language.Add(text + "SPECIAL_FRENZY_DESCRIPTION", "Slayer. 7% " + text5 + $". Dash a short distance and impale the nearest enemy for {625f}% damage. Kills reset cooldowns."); Language.Add(text + "SPECIAL_ENRAGED_SLAM_NAME", "Gorge"); Language.Add(text + "SPECIAL_ENRAGED_SLAM_DESCRIPTION", "15% " + text5 + $". Make a small leap, then slam for {1200f}% damage."); Language.Add(text + "SPECIAL_HUNGRY_NAME", "Tantilize"); Language.Add(text + "SPECIAL_HUNGRY_DESCRIPTION", "Lacerating. 15% " + text5 + $". Gut enemies with your tendrils for 2x{180f}% damage, intensifying your hunger."); Language.Add(text + "SPECIAL_ENRAGED_BINGE_NAME", "Binge"); Language.Add(text + "SPECIAL_ENRAGED_BINGE_DESCRIPTION", "20% " + text5 + $". Overcome by hunger, your tendrils flail for 4x{280f}% damage."); Language.Add(text + "LORD_VISAGE_SPIKE_ATTACK_NAME", "Temp Name"); Language.Add(text + "LORD_VISAGE_SPIKE_ATTACK_DESCRIPTION", "Temp Desciption"); Language.Add(Tokens.GetAchievementNameToken("VCR_GHOUL_masteryAchievement"), "Ghoul: Mastery"); Language.Add(Tokens.GetAchievementDescriptionToken("VCR_GHOUL_masteryAchievement"), "As Ghoul, beat the game or obliterate on Monsoon (or Higher)."); Language.Add(Tokens.GetAchievementNameToken("VCR_GHOUL_grandMasteryAchievement"), "Ghoul: Grandmastery"); Language.Add(Tokens.GetAchievementDescriptionToken("VCR_GHOUL_grandMasteryAchievement"), "As Ghoul, beat the game or obliterate on Typhoon (or Higher)."); Language.Add(Tokens.GetAchievementNameToken("VCR_GHOUL_unravelAchievement"), "Ghoul: I Am A..."); Language.Add(Tokens.GetAchievementDescriptionToken("VCR_GHOUL_unravelAchievement"), "As Ghoul, consume your doppelganger."); Language.Add(Tokens.GetAchievementNameToken("VCR_GHOUL_frenzyKillAchievement"), "Ghoul: All You Can Eat"); Language.Add(Tokens.GetAchievementDescriptionToken("VCR_GHOUL_frenzyKillAchievement"), "As Ghoul, devour 6 enemies with Feeding Frenzy in under 11 seconds"); Language.Add(Tokens.GetAchievementNameToken("VCR_GHOUL_massiveBlockAchievement"), "Ghoul: Better to be hurt than hurt others"); Language.Add(Tokens.GetAchievementDescriptionToken("VCR_GHOUL_massiveBlockAchievement"), "As Ghoul, store 1000 damage at once"); Language.Add(Tokens.GetAchievementNameToken("VCR_GHOUL_speedrunAchievement"), "Ghoul: Scarf it all"); Language.Add(Tokens.GetAchievementDescriptionToken("VCR_GHOUL_speedrunAchievement"), "As Ghoul, reach the final boss within one minute of landing on the moon."); Language.Add(text + "KEYWORD_GHOUL_N1", "X% NourishThis skill heals X% of your maximum health per hit."); Language.Add(text + "KEYWORD_GHOUL_E1", $"Enraged: TenderizeBatter enemies with wide sweeps for {360f}% damage and 4% Nourish."); Language.Add(text + "KEYWORD_GHOUL_E2", $"Enraged: Hungering MawLacerating. Throughout your grapple, impale enemies for {120.00001f}% damage. Can Anchor enemies."); Language.Add(text + "KEYWORD_GHOUL_E3", $"Enraged: GormandBound through the air for {400f}% damage and 8% Nourish. Ends Feral Rage on miss."); Language.Add(text + "KEYWORD_GHOUL_E4", $"Enraged: GorgeMake a small leap, then slam for {1200f}% damage."); Language.Add(text + "KEYWORD_GHOUL_E5", $"Enraged: BingeOvercome by hunger, your tendrils flail for 4x{280f}% damage and 20% Nourish."); Language.Add(text + "KEYWORD_GHOUL_E6", $"Enraged: TBDUpon reaching your target, launch them forward dealing {600f}% damage to them and nearby enemies on impact."); Language.Add(text + "KEYWORD_GHOUL_BLEED", "LaceratingThis attack bleeds on hit, critical hits inflict Hemmorage"); Language.Add(text + "ESSENCE_PICKUP_NAME", "Mutagenic Mass"); Language.Add(text + "ESSENCE_PICKUP_INTERACTION_PROMPT", "Consume Mutation"); Language.Add(text + "ESSENCE_PICKUP_INTERACTION_SUBTITLE", "Evolve Beyond..."); Language.Add(text + "TEST_ITEM_NAME", "TestingItem"); Language.Add(text + "TEST_ITEM_DESCRIPTION", "TestyTestTest"); Language.Add(text + "DEFAULT_ENRAGED_ITEM_NAME", "Wyrm Fragment"); Language.Add(text + "DEFAULT_ENRAGED_ITEM_DESCRIPTION", "Fracured stone hide of a once great Wyrm, twisting flesh into rough appendages."); Language.Add(text + "SLAM_ITEM_NAME", "Chitosan Flesh"); Language.Add(text + "SLAM_ITEM_DESCRIPTION", "Carapace from a beast of the Red Plane, its chitinous shell perfect for blunt force."); Language.Add(text + "ONE_EYE_KING_ITEM_NAME", "Lord's Visage"); Language.Add(text + "ONE_EYE_KING_ITEM_DESCRIPTION", "The presence of [their eminence] radiates from within, invoke it's power as your own."); Language.Add(text + "VULTURE_ITEM_NAME", "Vulture Bone"); Language.Add(text + "TULTURE_ITEM_DESCRIPTION", "The presence of [their eminence] radiates from within, invoke it's power as your own."); Language.Add(text + "THIRD_EYE_ITEM_NAME", "Third Eye"); Language.Add(text + "THIRD_EYE_ITEM_DESCRIPTION", "Parasytic growth causing propetual pain in the host, let it fuel you."); } } public static class GhoulUnlockables { public static UnlockableDef characterUnlockableDef; public static UnlockableDef masterySkinUnlockableDef; public static UnlockableDef grandMasterySkinUnlockableDef; public static UnlockableDef doppelgangerUnlockableDef; public static UnlockableDef frenzyKillUnlockableDef; public static UnlockableDef massiveBlockUnlockableDef; public static UnlockableDef speedrunUnlockableDef; public static void Init() { masterySkinUnlockableDef = Content.CreateAndAddUnlockbleDef("VCR_GHOUL_masteryUnlockable", Tokens.GetAchievementNameToken("VCR_GHOUL_masteryAchievement"), CharacterBase.instance.assetBundle.LoadAsset("texMasteryAchievement")); grandMasterySkinUnlockableDef = Content.CreateAndAddUnlockbleDef("VCR_GHOUL_grandMasteryUnlockable", Tokens.GetAchievementNameToken("VCR_GHOUL_grandMasteryAchievement"), CharacterBase.instance.assetBundle.LoadAsset("texMasteryAchievement")); doppelgangerUnlockableDef = Content.CreateAndAddUnlockbleDef("VCR_GHOUL_unravelAchievement", Tokens.GetAchievementNameToken("VCR_GHOUL_unravelAchievement"), CharacterBase.instance.assetBundle.LoadAsset("texMasteryAchievement")); frenzyKillUnlockableDef = Content.CreateAndAddUnlockbleDef("VCR_GHOUL_frenzyKillAchievement", Tokens.GetAchievementNameToken("VCR_GHOUL_frenzyKillAchievement"), CharacterBase.instance.assetBundle.LoadAsset("texMasteryAchievement")); massiveBlockUnlockableDef = Content.CreateAndAddUnlockbleDef("VCR_GHOUL_massiveBlockAchievement", Tokens.GetAchievementNameToken("VCR_GHOUL_massiveBlockAchievement"), CharacterBase.instance.assetBundle.LoadAsset("texMasteryAchievement")); speedrunUnlockableDef = Content.CreateAndAddUnlockbleDef("VCR_GHOUL_speedrunAchievement", Tokens.GetAchievementNameToken("VCR_GHOUL_speedrunAchievement"), CharacterBase.instance.assetBundle.LoadAsset("texMasteryAchievement")); } } public class GhoulSurvivor : SurvivorBase { public const string GHOUL_PREFIX = "VCR_GHOUL_"; public static SteppedSkillDef tendrilSlapDef; public static SkillDef spinSkillDef; public static SkillDef pointSlamSkillDef; public static SkillDef teleportDef; public static SkillDef slamSkillDef; public static SkillDef bingeSkillDef; public static SkillDef leapAttackSkillDef; public static SkillDef impSpikeSkillDef; public override string assetBundleName => "ghoulassetbundle"; public override string bodyName => "VcrGhoulBody"; public override string masterName => "VcrGhoulMonsterMaster"; public override string modelPrefabName => "mdlGhoul"; public override string displayPrefabName => "GhoulDisplay"; public override string survivorTokenPrefix => "VCR_GHOUL_"; public override BodyInfo bodyInfo => new BodyInfo { bodyName = bodyName, bodyNameToken = "VCR_GHOUL_NAME", subtitleNameToken = "VCR_GHOUL_SUBTITLE", characterPortrait = (Texture)(object)assetBundle.LoadAsset("Base_Icon").texture, bodyColor = Color.red, sortPosition = 15f, crosshair = assetBundle.LoadAsset("GhoulCrosshair"), maxHealth = 140f, healthRegen = 0f, armor = 10f, jumpCount = 1, cameraParamsVerticalOffset = 1.3f, cameraParamsDepth = -8.1f }; public override CustomRendererInfo[] customRendererInfos => new CustomRendererInfo[4] { new CustomRendererInfo { childName = "Model", material = assetBundle.LoadMaterial("matGhoul") }, new CustomRendererInfo { childName = "TentacleUpModel", material = assetBundle.LoadMaterial("matGhoulTentacles") }, new CustomRendererInfo { childName = "TentacleDownModel", material = assetBundle.LoadMaterial("matGhoulTentacles") }, new CustomRendererInfo { childName = "MiscModel", material = assetBundle.LoadMaterial("matGhoulTentacles") } }; public override UnlockableDef characterUnlockableDef => GhoulUnlockables.characterUnlockableDef; public override ItemDisplaysBase itemDisplays => new GhoulItemDisplays(); public override AssetBundle assetBundle { get; protected set; } public override GameObject bodyPrefab { get; protected set; } public override CharacterBody prefabCharacterBody { get; protected set; } public override GameObject characterModelObject { get; protected set; } public override CharacterModel prefabCharacterModel { get; protected set; } public override GameObject displayPrefab { get; protected set; } public static GameObject doppelgangerBodyPrefab { get; protected set; } public static GameObject doppelgangerMasterPrefab { get; protected set; } public override void Initialize() { base.Initialize(); } public override void InitializeCharacter() { GhoulUnlockables.Init(); base.InitializeCharacter(); GhoulConfig.Init(); GhoulStates.Init(); GhoulTokens.Init(); GhoulItems.Init(assetBundle); GhoulAssets.Init(assetBundle); GhoulBuffs.Init(assetBundle); InitializeEntityStateMachines(); InitializeSkills(); InitializeSkins(); InitializeCharacterMaster(); AdditionalBodySetup(); SetupDoppelganger(); AddHooks(); } private void AdditionalBodySetup() { AddHitboxes(); bodyPrefab.AddComponent(); displayPrefab.AddComponent(); bodyInfo.crosshair.AddComponent(); } public void AddHitboxes() { Prefabs.SetupHitBoxGroup(characterModelObject, "StabGroup", "TentacleStabHitbox"); Prefabs.SetupHitBoxGroup(characterModelObject, "SweepGroup", "TentacleSweepHitbox"); Prefabs.SetupHitBoxGroup(characterModelObject, "BlockCounterGroup", "CounterHitbox"); Prefabs.SetupHitBoxGroup(characterModelObject, "SpinGroup", "SpinHitbox"); Prefabs.SetupHitBoxGroup(characterModelObject, "ClingGroup", "ClingHitbox"); Prefabs.SetupHitBoxGroup(characterModelObject, "FrenzyGroup", "FrenzyHitbox"); Prefabs.SetupHitBoxGroup(characterModelObject, "GrappleGroup", "GrappleHitbox"); } public override void InitializeEntityStateMachines() { Prefabs.ClearEntityStateMachines(bodyPrefab); Prefabs.AddMainEntityStateMachine(bodyPrefab, "Body", typeof(GhoulMainState), typeof(GhoulSpawnState)); Prefabs.AddEntityStateMachine(bodyPrefab, "Weapon"); Prefabs.AddEntityStateMachine(bodyPrefab, "Weapon2"); } public override void InitializeSkills() { Skills.ClearGenericSkills(bodyPrefab); AddPassiveSkill(); AddMiscSkill(); AddPrimarySkills(); AddSecondarySkills(); AddUtiitySkills(); AddSpecialSkills(); } private void AddPassiveSkill() { GenericSkill val = Skills.CreateGenericSkillWithSkillFamily(bodyPrefab, "PassiveSkill"); SkillDefInfo skillDefInfo = new SkillDefInfo(); skillDefInfo.skillName = "GhoulPassive"; skillDefInfo.skillNameToken = "VCR_GHOUL_PASSIVE_NAME"; skillDefInfo.skillDescriptionToken = "VCR_GHOUL_PASSIVE_DESCRIPTION"; skillDefInfo.keywordTokens = new string[1] { "VCR_GHOUL_KEYWORD_GHOUL_N1" }; skillDefInfo.skillIcon = assetBundle.LoadAsset("texNourishIcon"); SkillDef val2 = Skills.CreateSkillDef(skillDefInfo); Skills.AddSkillsToFamily(val.skillFamily, val2); } private void AddMiscSkill() { GenericSkill val = Skills.CreateGenericSkillWithSkillFamily(bodyPrefab, "Misc"); SkillDef val2 = Skills.CreateSkillDef(new SkillDefInfo { skillName = "GhoulMisc", skillNameToken = "VCR_GHOUL_MISC_NAME", skillDescriptionToken = "VCR_GHOUL_MISC_DESCRIPTION", skillIcon = assetBundle.LoadAsset("texFeralRageIcon") }); SkillDef val3 = Skills.CreateSkillDef(new SkillDefInfo { skillName = "GhoulAltMisc", skillNameToken = "VCR_GHOUL_ALT_PASSIVE_NAME", skillDescriptionToken = "VCR_GHOUL_ALT_PASSIVE_DESCRIPTION", skillIcon = assetBundle.LoadAsset("texMutationIcon") }); Skills.AddSkillsToFamily(val.skillFamily, val2); if (GhoulConfig.cursed.Value) { Skills.AddSkillsToFamily(val.skillFamily, val3); } } private void AddPrimarySkills() { //IL_0038: 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) Skills.CreateGenericSkillWithSkillFamily(bodyPrefab, (SkillSlot)0); SteppedSkillDef val = Skills.CreateSkillDef(new SkillDefInfo("GhoulStab", "VCR_GHOUL_PRIMARY_STAB_NAME", "VCR_GHOUL_PRIMARY_STAB_DESCRIPTION", assetBundle.LoadAsset("texGnawHungIcon"), new SerializableEntityStateType(typeof(TentacleStrike)), "Weapon", agile: true)); ((SkillDef)val).keywordTokens = new string[2] { "VCR_GHOUL_KEYWORD_GHOUL_N1", "VCR_GHOUL_KEYWORD_GHOUL_E1" }; val.stepCount = 2; val.stepGraceDuration = 0.5f; ((SkillDef)val).cancelSprintingOnActivation = true; tendrilSlapDef = Skills.CreateSkillDef(new SkillDefInfo("GhoulStab", "VCR_GHOUL_PRIMARY_SWEEP_NAME", "VCR_GHOUL_PRIMARY_SWEEP_DESCRIPTION", assetBundle.LoadAsset("texGnawHungIcon"), new SerializableEntityStateType(typeof(TentacleSweep)), "Weapon", agile: true)); tendrilSlapDef.stepCount = 2; tendrilSlapDef.stepGraceDuration = 0.5f; ((SkillDef)tendrilSlapDef).cancelSprintingOnActivation = true; Skills.AddPrimarySkills(bodyPrefab, (SkillDef)val); } private void AddSecondarySkills() { //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) //IL_0092: 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_0186: Unknown result type (might be due to invalid IL or missing references) Skills.CreateGenericSkillWithSkillFamily(bodyPrefab, (SkillSlot)1); SkillDefInfo skillDefInfo = new SkillDefInfo(); skillDefInfo.skillName = "GhoulSwing"; skillDefInfo.skillNameToken = "VCR_GHOUL_SECONDARY_GRAPPLE_NAME"; skillDefInfo.skillDescriptionToken = "VCR_GHOUL_SECONDARY_GRAPPLE_DESCRIPTION"; skillDefInfo.keywordTokens = new string[3] { "VCR_GHOUL_KEYWORD_GHOUL_N1", "VCR_GHOUL_KEYWORD_GHOUL_E2", "VCR_GHOUL_KEYWORD_GHOUL_BLEED" }; skillDefInfo.skillIcon = assetBundle.LoadAsset("texRavenousLungeIcon"); skillDefInfo.activationState = new SerializableEntityStateType(typeof(PreTentacleGrapple)); skillDefInfo.activationStateMachineName = "Weapon"; skillDefInfo.interruptPriority = (InterruptPriority)1; skillDefInfo.baseRechargeInterval = 6f; skillDefInfo.baseMaxStock = 1; skillDefInfo.rechargeStock = 1; skillDefInfo.requiredStock = 1; skillDefInfo.stockToConsume = 0; skillDefInfo.resetCooldownTimerOnUse = false; skillDefInfo.fullRestockOnAssign = true; skillDefInfo.dontAllowPastMaxStocks = false; skillDefInfo.mustKeyPress = true; skillDefInfo.beginSkillCooldownOnSkillEnd = true; skillDefInfo.isCombatSkill = false; skillDefInfo.canceledFromSprinting = false; skillDefInfo.cancelSprintingOnActivation = false; skillDefInfo.forceSprintDuringState = false; SkillDef val = Skills.CreateSkillDef(skillDefInfo); val.autoHandleLuminousShot = false; skillDefInfo = new SkillDefInfo(); skillDefInfo.skillName = "GhoulAltSwing"; skillDefInfo.skillNameToken = "VCR_GHOUL_SECONDARY_ALTGRAPPLE_NAME"; skillDefInfo.skillDescriptionToken = "VCR_GHOUL_SECONDARY_ALTGRAPPLE_DESCRIPTION"; skillDefInfo.keywordTokens = new string[2] { "VCR_GHOUL_KEYWORD_GHOUL_N1", "VCR_GHOUL_KEYWORD_GHOUL_E6" }; skillDefInfo.skillIcon = assetBundle.LoadAsset("texAltSecondaryIcon"); skillDefInfo.activationState = new SerializableEntityStateType(typeof(AltGrapple)); skillDefInfo.activationStateMachineName = "Body"; skillDefInfo.interruptPriority = (InterruptPriority)1; skillDefInfo.baseRechargeInterval = 6f; skillDefInfo.baseMaxStock = 1; skillDefInfo.rechargeStock = 1; skillDefInfo.requiredStock = 1; skillDefInfo.stockToConsume = 1; skillDefInfo.resetCooldownTimerOnUse = false; skillDefInfo.fullRestockOnAssign = true; skillDefInfo.dontAllowPastMaxStocks = false; skillDefInfo.mustKeyPress = true; skillDefInfo.beginSkillCooldownOnSkillEnd = true; skillDefInfo.isCombatSkill = false; skillDefInfo.canceledFromSprinting = false; skillDefInfo.cancelSprintingOnActivation = false; skillDefInfo.forceSprintDuringState = false; SkillDef val2 = Skills.CreateSkillDef(skillDefInfo); Skills.AddSecondarySkills(bodyPrefab, val); if (GhoulConfig.cursed.Value) { Skills.AddSecondarySkills(bodyPrefab, val2); } } private void AddUtiitySkills() { //IL_0073: Unknown result type (might be due to invalid IL or missing references) //IL_0078: Unknown result type (might be due to invalid IL or missing references) //IL_008a: 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) //IL_0177: 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_0248: Unknown result type (might be due to invalid IL or missing references) //IL_0306: Unknown result type (might be due to invalid IL or missing references) //IL_030b: Unknown result type (might be due to invalid IL or missing references) //IL_031d: Unknown result type (might be due to invalid IL or missing references) Skills.CreateGenericSkillWithSkillFamily(bodyPrefab, (SkillSlot)2); SkillDefInfo skillDefInfo = new SkillDefInfo(); skillDefInfo.skillName = "GhoulBlock"; skillDefInfo.skillNameToken = "VCR_GHOUL_UTILITY_BLOCK_NAME"; skillDefInfo.skillDescriptionToken = "VCR_GHOUL_UTILITY_BLOCK_DESCRIPTION"; skillDefInfo.skillIcon = assetBundle.LoadAsset("texRetaliateIcon"); skillDefInfo.keywordTokens = new string[2] { "VCR_GHOUL_KEYWORD_GHOUL_N1", "VCR_GHOUL_KEYWORD_GHOUL_E3" }; skillDefInfo.activationState = new SerializableEntityStateType(typeof(BlockStart)); skillDefInfo.activationStateMachineName = "Weapon"; skillDefInfo.interruptPriority = (InterruptPriority)2; skillDefInfo.baseRechargeInterval = 7f; skillDefInfo.baseMaxStock = 1; skillDefInfo.rechargeStock = 1; skillDefInfo.requiredStock = 1; skillDefInfo.stockToConsume = 1; skillDefInfo.resetCooldownTimerOnUse = false; skillDefInfo.fullRestockOnAssign = true; skillDefInfo.dontAllowPastMaxStocks = false; skillDefInfo.mustKeyPress = true; skillDefInfo.beginSkillCooldownOnSkillEnd = true; skillDefInfo.isCombatSkill = false; skillDefInfo.canceledFromSprinting = false; skillDefInfo.cancelSprintingOnActivation = true; skillDefInfo.forceSprintDuringState = false; SkillDef val = Skills.CreateSkillDef(skillDefInfo); skillDefInfo = new SkillDefInfo(); skillDefInfo.skillName = "GhoulAltBlock"; skillDefInfo.skillNameToken = "VCR_GHOUL_ALT_UTILITY_BLOCK_NAME"; skillDefInfo.skillDescriptionToken = "VCR_GHOUL_ALT_UTILITY_BLOCK_DESCRIPTION"; skillDefInfo.skillIcon = assetBundle.LoadAsset("texRetaliateIcon"); skillDefInfo.keywordTokens = new string[2] { "VCR_GHOUL_KEYWORD_GHOUL_N1", "VCR_GHOUL_KEYWORD_GHOUL_E3" }; skillDefInfo.activationState = new SerializableEntityStateType(typeof(AltBlock)); skillDefInfo.activationStateMachineName = "Weapon"; skillDefInfo.interruptPriority = (InterruptPriority)2; skillDefInfo.baseRechargeInterval = 7f; skillDefInfo.baseMaxStock = 1; skillDefInfo.rechargeStock = 1; skillDefInfo.requiredStock = 1; skillDefInfo.stockToConsume = 1; skillDefInfo.resetCooldownTimerOnUse = false; skillDefInfo.fullRestockOnAssign = true; skillDefInfo.dontAllowPastMaxStocks = false; skillDefInfo.mustKeyPress = true; skillDefInfo.beginSkillCooldownOnSkillEnd = true; skillDefInfo.isCombatSkill = false; skillDefInfo.canceledFromSprinting = false; skillDefInfo.cancelSprintingOnActivation = true; skillDefInfo.forceSprintDuringState = false; SkillDef val2 = Skills.CreateSkillDef(skillDefInfo); skillDefInfo = new SkillDefInfo(); skillDefInfo.skillName = "GhoulSpin"; skillDefInfo.skillNameToken = "VCR_GHOUL_UTILITY_ENRAGED_SPIN_NAME"; skillDefInfo.skillDescriptionToken = "VCR_GHOUL_UTILITY_ENRAGED_SPIN_DESCRIPTION"; skillDefInfo.skillIcon = assetBundle.LoadAsset("texUtilitySpinIcon"); skillDefInfo.activationState = new SerializableEntityStateType(typeof(EnragedSpin)); skillDefInfo.activationStateMachineName = "Body"; skillDefInfo.interruptPriority = (InterruptPriority)2; skillDefInfo.baseRechargeInterval = 4f; skillDefInfo.baseMaxStock = 1; skillDefInfo.rechargeStock = 1; skillDefInfo.requiredStock = 1; skillDefInfo.stockToConsume = 1; skillDefInfo.resetCooldownTimerOnUse = false; skillDefInfo.fullRestockOnAssign = true; skillDefInfo.dontAllowPastMaxStocks = false; skillDefInfo.mustKeyPress = true; skillDefInfo.beginSkillCooldownOnSkillEnd = true; skillDefInfo.isCombatSkill = false; skillDefInfo.canceledFromSprinting = false; skillDefInfo.cancelSprintingOnActivation = true; skillDefInfo.forceSprintDuringState = false; spinSkillDef = Skills.CreateSkillDef(skillDefInfo); skillDefInfo = new SkillDefInfo(); skillDefInfo.skillName = "GhoulAltSlam"; skillDefInfo.skillNameToken = "VCR_GHOUL_UTILITY_ENRAGED_DEVOUR_NAME"; skillDefInfo.skillDescriptionToken = "VCR_GHOUL_UTILITY_ENRAGED_DEVOUR_DESCRIPTION"; skillDefInfo.skillIcon = assetBundle.LoadAsset("texUtilitySpinIcon"); skillDefInfo.activationState = new SerializableEntityStateType(typeof(EnragedLaunch)); skillDefInfo.activationStateMachineName = "Body"; skillDefInfo.interruptPriority = (InterruptPriority)2; skillDefInfo.baseRechargeInterval = 4f; skillDefInfo.baseMaxStock = 1; skillDefInfo.rechargeStock = 1; skillDefInfo.requiredStock = 1; skillDefInfo.stockToConsume = 1; skillDefInfo.resetCooldownTimerOnUse = false; skillDefInfo.fullRestockOnAssign = true; skillDefInfo.dontAllowPastMaxStocks = false; skillDefInfo.mustKeyPress = true; skillDefInfo.beginSkillCooldownOnSkillEnd = true; skillDefInfo.isCombatSkill = false; skillDefInfo.canceledFromSprinting = false; skillDefInfo.cancelSprintingOnActivation = true; skillDefInfo.forceSprintDuringState = false; pointSlamSkillDef = Skills.CreateSkillDef(skillDefInfo); Skills.AddUtilitySkills(bodyPrefab, val, val2); } private void AddSpecialSkills() { //IL_0073: Unknown result type (might be due to invalid IL or missing references) //IL_0078: Unknown result type (might be due to invalid IL or missing references) //IL_008a: 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_0127: 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_01ad: 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_01c4: Unknown result type (might be due to invalid IL or missing references) //IL_0243: Unknown result type (might be due to invalid IL or missing references) //IL_0248: Unknown result type (might be due to invalid IL or missing references) //IL_025a: Unknown result type (might be due to invalid IL or missing references) //IL_02d9: Unknown result type (might be due to invalid IL or missing references) //IL_02de: Unknown result type (might be due to invalid IL or missing references) //IL_02f0: Unknown result type (might be due to invalid IL or missing references) Skills.CreateGenericSkillWithSkillFamily(bodyPrefab, (SkillSlot)3); SkillDefInfo skillDefInfo = new SkillDefInfo(); skillDefInfo.skillName = "GhoulFrenzy"; skillDefInfo.skillNameToken = "VCR_GHOUL_SPECIAL_FRENZY_NAME"; skillDefInfo.skillDescriptionToken = "VCR_GHOUL_SPECIAL_FRENZY_DESCRIPTION"; skillDefInfo.keywordTokens = new string[2] { "VCR_GHOUL_KEYWORD_GHOUL_N1", "VCR_GHOUL_KEYWORD_GHOUL_E4" }; skillDefInfo.skillIcon = assetBundle.LoadAsset("texFeedingFrenzyIcon"); skillDefInfo.activationState = new SerializableEntityStateType(typeof(DashStart)); skillDefInfo.activationStateMachineName = "Body"; skillDefInfo.interruptPriority = (InterruptPriority)2; skillDefInfo.baseMaxStock = 1; skillDefInfo.baseRechargeInterval = 8f; skillDefInfo.isCombatSkill = true; skillDefInfo.mustKeyPress = true; SkillDef val = Skills.CreateSkillDef(skillDefInfo); skillDefInfo = new SkillDefInfo(); skillDefInfo.skillName = "GhoulHungryStab"; skillDefInfo.skillNameToken = "VCR_GHOUL_SPECIAL_HUNGRY_NAME"; skillDefInfo.skillDescriptionToken = "VCR_GHOUL_SPECIAL_HUNGRY_DESCRIPTION"; skillDefInfo.keywordTokens = new string[3] { "VCR_GHOUL_KEYWORD_GHOUL_BLEED", "VCR_GHOUL_KEYWORD_GHOUL_N1", "VCR_GHOUL_KEYWORD_GHOUL_E5" }; skillDefInfo.skillIcon = assetBundle.LoadAsset("texTantalizeIcon"); skillDefInfo.activationState = new SerializableEntityStateType(typeof(Tantalize)); skillDefInfo.activationStateMachineName = "Weapon"; skillDefInfo.interruptPriority = (InterruptPriority)1; skillDefInfo.baseMaxStock = 1; skillDefInfo.baseRechargeInterval = 8f; skillDefInfo.isCombatSkill = true; skillDefInfo.mustKeyPress = true; SkillDef val2 = Skills.CreateSkillDef(skillDefInfo); skillDefInfo = new SkillDefInfo(); skillDefInfo.skillName = "GhoulSlam"; skillDefInfo.skillNameToken = "VCR_GHOUL_SPECIAL_ENRAGED_SLAM_NAME"; skillDefInfo.skillDescriptionToken = "VCR_GHOUL_SPECIAL_ENRAGED_SLAM_DESCRIPTION"; skillDefInfo.skillIcon = assetBundle.LoadAsset("texSpecialSlamIcon"); skillDefInfo.activationState = new SerializableEntityStateType(typeof(SlamFall)); skillDefInfo.activationStateMachineName = "Body"; skillDefInfo.interruptPriority = (InterruptPriority)2; skillDefInfo.baseMaxStock = 1; skillDefInfo.baseRechargeInterval = 12f; skillDefInfo.isCombatSkill = true; skillDefInfo.mustKeyPress = true; skillDefInfo.fullRestockOnAssign = true; slamSkillDef = Skills.CreateSkillDef(skillDefInfo); skillDefInfo = new SkillDefInfo(); skillDefInfo.skillName = "GhoulBinge"; skillDefInfo.skillNameToken = "VCR_GHOUL_SPECIAL_ENRAGED_BINGE_NAME"; skillDefInfo.skillDescriptionToken = "VCR_GHOUL_SPECIAL_ENRAGED_BINGE_DESCRIPTION"; skillDefInfo.skillIcon = assetBundle.LoadAsset("texSpecialSlamIcon"); skillDefInfo.activationState = new SerializableEntityStateType(typeof(Binge)); skillDefInfo.activationStateMachineName = "Weapon"; skillDefInfo.interruptPriority = (InterruptPriority)2; skillDefInfo.baseMaxStock = 1; skillDefInfo.baseRechargeInterval = 8f; skillDefInfo.isCombatSkill = true; skillDefInfo.mustKeyPress = true; skillDefInfo.fullRestockOnAssign = true; bingeSkillDef = Skills.CreateSkillDef(skillDefInfo); skillDefInfo = new SkillDefInfo(); skillDefInfo.skillName = "GhoulOverlordSpikes"; skillDefInfo.skillNameToken = "VCR_GHOUL_LORD_VISAGE_SPIKE_ATTACK_NAME"; skillDefInfo.skillDescriptionToken = "VCR_GHOUL_LORD_VISAGE_SPIKE_ATTACK_DESCRIPTION"; skillDefInfo.skillIcon = assetBundle.LoadAsset("texSpecialSlamIcon"); skillDefInfo.activationState = new SerializableEntityStateType(typeof(ShootImpSpike)); skillDefInfo.activationStateMachineName = "Body"; skillDefInfo.interruptPriority = (InterruptPriority)2; skillDefInfo.baseMaxStock = 1; skillDefInfo.baseRechargeInterval = 8f; skillDefInfo.isCombatSkill = true; skillDefInfo.mustKeyPress = true; skillDefInfo.fullRestockOnAssign = true; impSpikeSkillDef = Skills.CreateSkillDef(skillDefInfo); Skills.AddSpecialSkills(bodyPrefab, val, val2); Skills.AddUnlockablesToFamily(bodyPrefab.GetComponent().special.skillFamily, default(UnlockableDef), GhoulUnlockables.frenzyKillUnlockableDef); } [Obsolete] public override void InitializeSkins() { ModelSkinController val = ((Component)prefabCharacterModel).gameObject.AddComponent(); ModelSkinController val2 = displayPrefab.gameObject.AddComponent(); ChildLocator component = ((Component)prefabCharacterModel).GetComponent(); RendererInfo[] baseRendererInfos = prefabCharacterModel.baseRendererInfos; List list = new List(); SkinDef val3 = Skins.CreateSkinDef("VCR_GHOUL_DEFAULT_SKIN_NAME", assetBundle.LoadAsset("texMainSkin"), baseRendererInfos, ((Component)prefabCharacterModel).gameObject); val3.meshReplacements = Skins.getMeshReplacements(assetBundle, baseRendererInfos, "meshGhoulBody", "GhoulTendrilsUp", "GhoulTendrilsDown", "meshMiscTentacles"); list.Add(val3); SkinDefParams.FromSkinDef(val3); SkinDef val4 = Skins.CreateSkinDef("VCR_GHOUL_MASTERY_SKIN_NAME", assetBundle.LoadAsset("texMasteryAchievement"), baseRendererInfos, ((Component)prefabCharacterModel).gameObject, GhoulUnlockables.masterySkinUnlockableDef); val4.meshReplacements = Skins.getMeshReplacements(assetBundle, baseRendererInfos, "meshGhoulTokyoBody", "GhoulTendrilsUp", "GhoulTendrilsDown", "meshGhoulTokyoMouth"); val4.rendererInfos[0].defaultMaterial = assetBundle.LoadMaterial("matGhoulTokyo"); val4.rendererInfos[3].defaultMaterial = assetBundle.LoadMaterial("matGhoulTokyo"); list.Add(val4); SkinDef val5 = Skins.CreateSkinDef("VCR_GHOUL_GRAND_MASTERY_SKIN_NAME", assetBundle.LoadAsset("texMasteryAchievement"), baseRendererInfos, ((Component)prefabCharacterModel).gameObject, GhoulUnlockables.grandMasterySkinUnlockableDef); val5.meshReplacements = Skins.getMeshReplacements(assetBundle, baseRendererInfos, "meshGhoulBlueBody", "GhoulTendrilsUp", "GhoulTendrilsDown", "meshGhoulTokyoMouth"); val5.rendererInfos[0].defaultMaterial = assetBundle.LoadMaterial("matGhoulBlueTokyo"); val5.rendererInfos[3].defaultMaterial = assetBundle.LoadMaterial("matGhoulTokyo"); list.Add(val5); SkinDef val6 = Skins.CreateSkinDef("VCR_GHOUL_CANNIBAL_MASTERY_SKIN_NAME", assetBundle.LoadAsset("texMasteryAchievement"), baseRendererInfos, ((Component)prefabCharacterModel).gameObject, GhoulUnlockables.doppelgangerUnlockableDef); val6.meshReplacements = Skins.getMeshReplacements(assetBundle, baseRendererInfos, "meshGhoulUnraveledBody", "GhoulTendrilsUp", "GhoulTendrilsDown", "meshGhoulTokyoMouth"); val6.rendererInfos[0].defaultMaterial = assetBundle.LoadMaterial("matGhoulTokyo"); val6.rendererInfos[3].defaultMaterial = assetBundle.LoadMaterial("matGhoulTokyo"); list.Add(val6); SkinDef val7 = Skins.CreateSkinDef("VCR_GHOUL_CARNAGE_SKIN_NAME", assetBundle.LoadAsset("texMasteryAchievement"), baseRendererInfos, ((Component)prefabCharacterModel).gameObject, GhoulUnlockables.masterySkinUnlockableDef); val7.meshReplacements = Skins.getMeshReplacements(assetBundle, baseRendererInfos, "meshCarnageBody", "GhoulCarnageTendrilsUp", "GhoulCarnageTendrilsDown", "meshCarnageMisc"); val7.rendererInfos[0].defaultMaterial = assetBundle.LoadMaterial("matGhoulCarnage"); val7.rendererInfos[1].defaultMaterial = assetBundle.LoadMaterial("matGhoulCarnageTentacles"); val7.rendererInfos[2].defaultMaterial = assetBundle.LoadMaterial("matGhoulCarnageTentacles"); val7.rendererInfos[3].defaultMaterial = assetBundle.LoadMaterial("matGhoulCarnageMisc"); list.Add(val7); val.skins = list.ToArray(); val2.skins = list.ToArray(); } public override void InitializeCharacterMaster() { GhoulAI.Init(bodyPrefab, masterName); } public void SetupDoppelganger() { doppelgangerBodyPrefab = PrefabAPI.InstantiateClone(bodyPrefab, "VcrFeralGhoulBody", true); CharacterBody component = doppelgangerBodyPrefab.GetComponent(); component.baseNameToken = "Feral Ghoul"; ContentAddition.AddBody(doppelgangerBodyPrefab); doppelgangerMasterPrefab = PrefabAPI.InstantiateClone(GhoulAI.master, "VcrFeralGhoulMonsterMaster", true); doppelgangerMasterPrefab.GetComponent().bodyPrefab = doppelgangerBodyPrefab; ContentAddition.AddMaster(doppelgangerMasterPrefab); } private void AddHooks() { //IL_0014: Unknown result type (might be due to invalid IL or missing references) //IL_001e: Expected O, but got Unknown //IL_0038: Unknown result type (might be due to invalid IL or missing references) //IL_0042: Expected O, but got Unknown //IL_004a: Unknown result type (might be due to invalid IL or missing references) //IL_0054: Expected O, but got Unknown //IL_005c: Unknown result type (might be due to invalid IL or missing references) //IL_0066: Expected O, but got Unknown //IL_006e: Unknown result type (might be due to invalid IL or missing references) //IL_0078: Expected O, but got Unknown //IL_0080: Unknown result type (might be due to invalid IL or missing references) //IL_008a: Expected O, but got Unknown //IL_0092: Unknown result type (might be due to invalid IL or missing references) //IL_009c: Expected O, but got Unknown GhoulWeaponComponent component = bodyPrefab.GetComponent(); RecalculateStatsAPI.GetStatCoefficients += new StatHookEventHandler(RecalculateStatsAPI_GetStatCoefficients); HUD.onHudTargetChangedGlobal += HUD_onHudTargetChangedGlobal; HealthComponent.Die += new hook_Die(HealthComponent_Die); CharacterSelectController.Awake += new hook_Awake(CharacterSelectController_Awake); Phase2.OnEnter += new hook_OnEnter(Phase2_OnEnter); CharacterBody.OnInventoryChanged += new hook_OnInventoryChanged(CharacterBody_OnInventoryChanged); GenericPickupController.AttemptGrant += new hook_AttemptGrant(GenericPickupController_AttemptGrant); GlobalEventManager.ServerDamageDealt += new hook_ServerDamageDealt(GlobalEventManager_ServerDamageDealt); } private void GlobalEventManager_ServerDamageDealt(orig_ServerDamageDealt orig, DamageReport damageReport) { orig.Invoke(damageReport); if (Object.op_Implicit((Object)(object)damageReport.victim) && Object.op_Implicit((Object)(object)damageReport.victimBody) && damageReport.victimBody.baseNameToken == bodyInfo.bodyNameToken) { if (damageReport.victimBody.HasBuff(GhoulBuffs.blockBuff)) { ((Component)damageReport.victimBody).GetComponent().blockedDamage += damageReport.damageDealt * 0.8f; float num = damageReport.damageDealt * 1.4f * ((Component)damageReport.victimBody).GetComponent().takeDamageCoefficient; float num2 = Mathf.Clamp(num, 0f, ((Component)damageReport.victimBody).GetComponent().rageThreshold * 0.3f); ((Component)damageReport.victimBody).GetComponent().rageValue += num2; } else { ((Component)damageReport.victimBody).GetComponent().rageValue += damageReport.damageDealt * ((Component)damageReport.victimBody).GetComponent().takeDamageCoefficient; } } } private void CharacterBody_OnInventoryChanged(orig_OnInventoryChanged orig, CharacterBody self) { if (((NetworkBehaviour)self).hasAuthority && Object.op_Implicit((Object)(object)self) && self.baseNameToken == bodyInfo.bodyNameToken) { self.AddItemBehavior(self.inventory.GetItemCountEffective(GhoulItems.testItemDef)); self.AddItemBehavior(self.inventory.GetItemCountEffective(GhoulItems.defaultEnragedItemDef)); self.AddItemBehavior(self.inventory.GetItemCountEffective(GhoulItems.slamItemDef)); self.AddItemBehavior(self.inventory.GetItemCountEffective(GhoulItems.thirdEyeItemDef)); self.AddItemBehavior(self.inventory.GetItemCountEffective(GhoulItems.overlordItemDef)); } orig.Invoke(self); } private static void GenericPickupController_AttemptGrant(orig_AttemptGrant orig, GenericPickupController self, CharacterBody body) { //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_002e: 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) if (Object.op_Implicit((Object)(object)self) && Object.op_Implicit((Object)(object)body)) { PickupIndex pickupIndex = self.pickupIndex; if (((PickupIndex)(ref pickupIndex)).isValid) { ItemDef itemDef = ItemCatalog.GetItemDef(PickupCatalog.GetPickupDef(self.pickupIndex).itemIndex); if (Object.op_Implicit((Object)(object)itemDef) && (Object)(object)itemDef._itemTierDef == (Object)(object)GhoulItems.mutationTier && (body.baseNameToken != "VCR_GHOUL_NAME" || (Object.op_Implicit((Object)(object)body.inventory) && body.inventory.GetItemCountEffective(itemDef) > 0))) { return; } } } orig.Invoke(self, body); } private void Phase2_OnEnter(orig_OnEnter orig, Phase2 self) { orig.Invoke(self); if (!GhoulConfig.unravelOnFinalBoss.Value) { return; } GhoulWeaponComponent[] array = Object.FindObjectsOfType(); foreach (GhoulWeaponComponent ghoulWeaponComponent in array) { if (Object.op_Implicit((Object)(object)ghoulWeaponComponent) && ((NetworkBehaviour)((Component)ghoulWeaponComponent).GetComponent()).hasAuthority) { ((Component)ghoulWeaponComponent).gameObject.AddComponent(); } } } private void HealthComponent_Die(orig_Die orig, HealthComponent self, bool noCorpse) { if (Object.op_Implicit((Object)(object)self) && Object.op_Implicit((Object)(object)((Component)self).GetComponent())) { ((Component)self).GetComponent().Effect(); } orig.Invoke(self, noCorpse); } private void HUD_onHudTargetChangedGlobal(HUD hud) { //IL_00ae: Unknown result type (might be due to invalid IL or missing references) if (Object.op_Implicit((Object)(object)hud.targetBodyObject) && Object.op_Implicit((Object)(object)hud.targetMaster) && (Object)(object)hud.targetMaster.bodyPrefab == (Object)(object)CharacterBase.instance.bodyPrefab && ((NetworkBehaviour)hud.targetMaster).hasAuthority) { GameObject val = Object.Instantiate(GhoulAssets.rageMeter, ((Component)hud.mainContainer.transform.Find("MainUIArea")).transform); val.GetComponent().targetHud = hud; val.GetComponent().wep = hud.targetBodyObject.GetComponent(); val.GetComponent().anchoredPosition = new Vector2(62f, -36f); GameObject val2 = Object.Instantiate(GhoulAssets.vignette, ((Component)hud.mainContainer.transform.Find("MainUIArea")).transform); val2.GetComponent().targetHud = hud; val2.GetComponent().wep = hud.targetBodyObject.GetComponent(); } } private void RecalculateStatsAPI_GetStatCoefficients(CharacterBody sender, StatHookEventArgs args) { if (sender.HasBuff(GhoulBuffs.blockBuff)) { args.armorAdd += 125f; args.moveSpeedReductionMultAdd += 0.3f; } if ((Object)(object)((Component)sender).GetComponent() != (Object)null && ((Component)sender).GetComponent().isEnraged) { args.sprintSpeedAdd += 0.57f; } if (sender.HasBuff(GhoulBuffs.feralAffix)) { args.damageMultAdd += -0.1f; args.healthMultAdd += 1.2f; } } private static void CharacterSelectController_Awake(orig_Awake orig, CharacterSelectController self) { orig.Invoke(self); if (Object.op_Implicit((Object)(object)self)) { GhoulCharacterMenuListener component = ((Component)self).GetComponent(); if (!Object.op_Implicit((Object)(object)component)) { component = ((Component)self).gameObject.AddComponent(); } } } } } namespace GhoulMod.Survivors.Ghoul.SkillStates { public class AltBlock : BlockStart { public override void OnEnter() { BlockStart.baseDuration = 4f; base.OnEnter(); } public override EntityState NextSkill() { return (EntityState)(object)new BlockCounter { blockedDamage = storedDamage }; } } public class EnragedLaunch : GhoulBaseSkillState { public float baseDuration = 0.6f; public static float airControl = 0.5f; public static float aimVelocity = 100f; public static float upwardVelocity = 25f; public static float forwardVelocity = 60f; public static float minimumY = 4f; private float previousAirControl; public override void OnEnter() { //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) //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_004e: 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_006f: Unknown result type (might be due to invalid IL or missing references) //IL_007a: Unknown result type (might be due to invalid IL or missing references) //IL_007f: 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_008a: Unknown result type (might be due to invalid IL or missing references) //IL_008f: Unknown result type (might be due to invalid IL or missing references) //IL_0091: Unknown result type (might be due to invalid IL or missing references) //IL_009c: Unknown result type (might be due to invalid IL or missing references) //IL_00a2: Unknown result type (might be due to invalid IL or missing references) //IL_00a7: Unknown result type (might be due to invalid IL or missing references) //IL_00ab: Unknown result type (might be due to invalid IL or missing references) //IL_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_00d8: 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_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_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) previousAirControl = ((EntityState)this).characterMotor.airControl; ((EntityState)this).characterMotor.airControl = airControl; Ray aimRay = ((BaseState)this).GetAimRay(); Vector3 direction = ((Ray)(ref aimRay)).direction; if (((EntityState)this).isAuthority) { ((EntityState)this).characterBody.isSprinting = true; direction.y = Mathf.Max(direction.y, minimumY); Vector3 val = ((Vector3)(ref direction)).normalized * aimVelocity * ((BaseState)this).moveSpeedStat; Vector3 val2 = Vector3.up * upwardVelocity; Vector3 val3 = new Vector3(direction.x, 0f, direction.z); Vector3 val4 = ((Vector3)(ref val3)).normalized * forwardVelocity; ((BaseCharacterController)((EntityState)this).characterMotor).Motor.ForceUnground(0.1f); ((EntityState)this).characterMotor.velocity = val + val2 + val4; } ((BaseState)this).OnEnter(); } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); if (((EntityState)this).fixedAge >= baseDuration) { ((EntityState)this).outer.SetNextState((EntityState)(object)new EnragedLaunchAir()); } } public override void OnExit() { ((EntityState)this).characterMotor.airControl = previousAirControl; ((EntityState)this).OnExit(); } } public class EnragedLaunchAir : GenericCharacterMain { public float maxDuration = 3f; public GameObject indicatorPrefab = GhoulAssets.altSlamIndicator; private GameObject indicatorInstance; public const float range = 150f; private float distance; private float angle; private float clampedAngle; private bool slamNextFrame; private bool hasStaredPull; public static float initialPullSpeed = 10f; public static float finalPullSpeed = 17f; private float pullSpeed; private Ray mond; private float angle2; public override void OnEnter() { //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_0013: 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_0020: 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_0031: 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_005d: 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_0085: 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_0091: Unknown result type (might be due to invalid IL or missing references) Vector3 corePosition = ((EntityState)this).characterBody.corePosition; Ray aimRay = ((BaseState)this).GetAimRay(); mond = new Ray(corePosition, ((Ray)(ref aimRay)).direction); angle2 = Vector3.Angle(Vector3.down, ((Ray)(ref mond)).direction); RaycastHit val = default(RaycastHit); if (Util.CharacterSpherecast(((EntityState)this).gameObject, mond, 0.35f, ref val, 150f, ((LayerIndex)(ref LayerIndex.world)).mask, (QueryTriggerInteraction)2)) { indicatorInstance = Object.Instantiate(indicatorPrefab, ((RaycastHit)(ref val)).collider.ClosestPointOnBounds(((RaycastHit)(ref val)).point), Quaternion.Euler(((RaycastHit)(ref val)).normal)); UpdateIndicator(); RecalculatePullSpeed(); Util.PlaySound("Play_Ghoul_Tendril_Grow", ((EntityState)this).gameObject); ((EntityState)this).GetModelAnimator().SetBool("RotateTendrils", true); ((EntityState)this).GetModelAnimator().SetBool("isGrappling", true); ((EntityState)this).PlayAnimation("TentaclePitch, Additive", "TentaclePitch"); ((EntityState)this).PlayAnimation("TentaclesDown, Override", "GrapplingTentacles"); } ((GenericCharacterMain)this).OnEnter(); } public override void Update() { ((GenericCharacterMain)this).Update(); if (!((EntityState)this).characterMotor.isGrounded && !hasStaredPull && Object.op_Implicit((Object)(object)indicatorInstance)) { UpdateIndicator(); UpdateTentacles(); } } public override void FixedUpdate() { //IL_0083: 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_0098: 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_00ac: Unknown result type (might be due to invalid IL or missing references) ((GenericCharacterMain)this).FixedUpdate(); if (!((EntityState)this).isAuthority || !Object.op_Implicit((Object)(object)((EntityState)this).characterMotor)) { return; } if (Object.op_Implicit((Object)(object)indicatorInstance)) { RecalculatePullSpeed(); if (((EntityState)this).fixedAge >= maxDuration || !KeyIsDown()) { hasStaredPull = true; } if (hasStaredPull) { CharacterMotor characterMotor = ((EntityState)this).characterMotor; Vector3 val = indicatorInstance.transform.position - ((EntityState)this).characterBody.corePosition; characterMotor.velocity = ((Vector3)(ref val)).normalized * pullSpeed; } else { ((EntityState)this).characterMotor.velocity.y = -4f; } if (slamNextFrame || ((BaseCharacterController)((EntityState)this).characterMotor).Motor.GroundingStatus.IsStableOnGround) { ((EntityState)this).outer.SetNextStateToMain(); } } else { ((EntityState)this).outer.SetNextStateToMain(); } } public override void OnExit() { ((EntityState)this).GetModelAnimator().SetBool("RotateTendrils", false); ((EntityState)this).GetModelAnimator().SetBool("isGrappling", false); ((EntityState)this).GetModelAnimator().SetFloat("aimPitchCached", 0.5f); if (Object.op_Implicit((Object)(object)indicatorInstance)) { EntityState.Destroy((Object)(object)indicatorInstance); } ((GenericCharacterMain)this).OnExit(); } private void UpdateTentacles() { //IL_0008: 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_0033: 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) distance = Vector3.Distance(((EntityState)this).characterBody.corePosition, indicatorInstance.transform.position); angle = indicatorInstance.transform.position.y - ((EntityState)this).characterBody.corePosition.y; clampedAngle = angle / 150f / 2f + 0.5f; ((EntityState)this).GetModelAnimator().SetFloat("aimPitchCached", clampedAngle); ((EntityState)this).GetModelAnimator().SetFloat("TendrilDistance", distance); } public override void HandleMovements() { if (!hasStaredPull) { ((GenericCharacterMain)this).HandleMovements(); } } private void RecalculatePullSpeed() { pullSpeed = ((BaseState)this).moveSpeedStat * Mathf.Lerp(initialPullSpeed, finalPullSpeed, ((EntityState)this).fixedAge); } public void UpdateIndicator() { //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_0013: 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_0020: 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_0031: 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_005d: 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_0086: Unknown result type (might be due to invalid IL or missing references) //IL_009e: 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) Vector3 corePosition = ((EntityState)this).characterBody.corePosition; Ray aimRay = ((BaseState)this).GetAimRay(); mond = new Ray(corePosition, ((Ray)(ref aimRay)).direction); angle2 = Vector3.Angle(Vector3.down, ((Ray)(ref mond)).direction); RaycastHit val = default(RaycastHit); if (Util.CharacterSpherecast(((EntityState)this).gameObject, mond, 0.35f, ref val, 150f, ((LayerIndex)(ref LayerIndex.world)).mask, (QueryTriggerInteraction)2)) { indicatorInstance.transform.position = ((RaycastHit)(ref val)).collider.ClosestPointOnBounds(((RaycastHit)(ref val)).point); indicatorInstance.transform.rotation = Quaternion.Euler(((RaycastHit)(ref val)).normal); } } protected bool KeyIsDown() { return ((EntityState)this).inputBank.skill3.down; } private void OnMovementHit(ref MovementHitInfo movementHitInfo) { slamNextFrame = true; ((EntityState)this).PlayCrossfade("FullBody, Override", "SlamAttack", 0.35f); Util.PlaySound("Play_Ghoul_Slam_SFX", ((EntityState)this).gameObject); } public override bool CanExecuteSkill(GenericSkill skillSlot) { return false; } } public class AltGrapple : GhoulBaseSkillState { public static float checkRadius = 2f; public static float baseDuration = 3f; public static float delay = 0.2f; public static float initialPullSpeed = 3.5f; public static float finalPullSpeed = 4.75f; public static float initialForwardSpeed = 4f; public static float finalForwardSpeed = 0f; public static float moveSpeedCoefficient = 5f; private float distance; private float angle; private float clampedAngle; private float speedCoefficient = 1f; private float pullSpeed; private float forwardSpeed; private float duration; private Vector3 travelDir; private Vector3 forwardDir; private float clampedSpeed; private uint loopSFX; private bool sfxStarted; private GhoulWeaponComponent wep; public Vector3 latchPos { get; set; } public override void OnEnter() { //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_0055: Unknown result type (might be due to invalid IL or missing references) ((BaseState)this).OnEnter(); if (!((EntityState)this).isAuthority) { return; } wep = ((EntityState)this).GetComponent(); RaycastHit val = default(RaycastHit); if (Util.CharacterSpherecast(((EntityState)this).gameObject, ((BaseState)this).GetAimRay(), checkRadius, ref val, 58f, ((LayerIndex)(ref LayerIndex.enemyBody)).mask, (QueryTriggerInteraction)2)) { latchPos = ((RaycastHit)(ref val)).point; ((EntityState)this).GetModelAnimator().SetBool("RotateTendrils", true); ((EntityState)this).GetModelAnimator().SetBool("isGrappling", true); ((EntityState)this).PlayAnimation("Fullbody, Override", "Grappling"); ((EntityState)this).PlayAnimation("TentaclePitch, Additive", "TentaclePitch"); ((EntityState)this).PlayAnimation("TentaclesDown, Override", "GrapplingTentacles"); ((BaseCharacterController)((EntityState)this).characterMotor).Motor.ForceUnground(0.1f); Util.PlaySound("Play_Ghoul_Tendril_Grow", ((EntityState)this).gameObject); duration = baseDuration; RecalculatePullSpeed(); RecalculateReelDirection(); RecalculateForwardDirection(); RecalculateForwardSpeed(); RecalDist(); float num = ((BaseState)this).moveSpeedStat / moveSpeedCoefficient; if (((BaseState)this).moveSpeedStat <= 10.2f) { num = 0f; } clampedSpeed = 10.15f + num; } else { ((EntityState)this).outer.SetState((EntityState)(object)new AltGrappleBounce { finalSpeedCoefficient = 3f }); } } public override void OnExit() { if (Object.op_Implicit((Object)(object)((EntityState)this).cameraTargetParams)) { ((EntityState)this).cameraTargetParams.fovOverride = -1f; } ((EntityState)this).GetModelAnimator().SetBool("RotateTendrils", false); ((EntityState)this).GetModelAnimator().SetBool("isGrappling", false); ((EntityState)this).GetModelAnimator().SetFloat("aimPitchCached", 0.5f); AkSoundEngine.StopPlayingID(loopSFX); ((EntityState)this).OnExit(); } public override void FixedUpdate() { //IL_0017: 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_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_008b: Unknown result type (might be due to invalid IL or missing references) //IL_0096: Unknown result type (might be due to invalid IL or missing references) //IL_009b: Unknown result type (might be due to invalid IL or missing references) //IL_00a0: Unknown result type (might be due to invalid IL or missing references) if (!((EntityState)this).isAuthority) { return; } ((EntityState)this).FixedUpdate(); _ = latchPos; if (1 == 0) { return; } RecalculateReelDirection(); RecalculateForwardDirection(); RecalDist(); if (Object.op_Implicit((Object)(object)((EntityState)this).characterDirection)) { ((EntityState)this).characterDirection.forward = travelDir; } if (((EntityState)this).fixedAge > delay) { ((EntityState)this).characterMotor.velocity = ((Vector3)(ref travelDir)).normalized * pullSpeed + forwardDir * forwardSpeed; RecalculateForwardSpeed(); RecalculatePullSpeed(); if (!sfxStarted) { sfxStarted = true; loopSFX = Util.PlaySound("Play_Ghoul_Grapple_Woosh_Loop", ((EntityState)this).gameObject); } } if (!ShouldKeepChargingAuthority() && ((EntityState)this).fixedAge >= 0.25f + delay) { ((EntityState)this).outer.SetNextState((EntityState)(object)new AltGrappleFallState()); } else if (((EntityState)this).fixedAge >= duration) { ((EntityState)this).outer.SetNextStateToMain(); } } private void RecalculateReelDirection() { //IL_0003: 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_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) travelDir = latchPos - ((EntityState)this).transform.position; } private void RecalculateForwardDirection() { //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_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_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) Ray aimRay = ((BaseState)this).GetAimRay(); Vector3 direction = ((Ray)(ref aimRay)).direction; forwardDir = ((Vector3)(ref direction)).normalized; } private void RecalculatePullSpeed() { pullSpeed = clampedSpeed * speedCoefficient * Mathf.Lerp(initialPullSpeed, finalPullSpeed, ((EntityState)this).fixedAge / duration); } private void RecalculateForwardSpeed() { forwardSpeed = clampedSpeed * speedCoefficient * Mathf.Lerp(initialForwardSpeed, finalForwardSpeed, ((EntityState)this).fixedAge / duration); } private void RecalDist() { //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_001f: 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) distance = Vector3.Distance(((EntityState)this).characterBody.corePosition, latchPos); angle = latchPos.y - ((EntityState)this).characterBody.corePosition.y; clampedAngle = angle / 58f / 2f + 0.5f; ((EntityState)this).GetModelAnimator().SetFloat("aimPitchCached", clampedAngle); ((EntityState)this).GetModelAnimator().SetFloat("TendrilDistance", distance); } protected virtual bool ShouldKeepChargingAuthority() { return ((EntityState)this).inputBank.skill2.down; } 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; } 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) ((BaseSkillState)this).OnSerialize(writer); writer.Write(travelDir); writer.Write(forwardDir); } 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) ((BaseSkillState)this).OnDeserialize(reader); travelDir = reader.ReadVector3(); forwardDir = reader.ReadVector3(); } } public class AltGrappleBounce : GhoulBaseSkillState { public float baseDuration = 2f; public float initialSpeedCoefficient = 8f; public float finalSpeedCoefficient = 5f; private float bounceSpeed; private float duration; private Vector3 bounceDirection; public static float dodgeFOV = DodgeState.dodgeFOV; private uint loopSFX; private bool sfxStarted; public override void OnEnter() { //IL_0024: 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) //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_003d: 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_0081: 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) ((BaseState)this).OnEnter(); RecalculateSpeed(); duration = baseDuration / ((BaseState)this).moveSpeedStat; Ray aimRay = ((BaseState)this).GetAimRay(); bounceDirection = ((Ray)(ref aimRay)).direction; ((EntityState)this).characterDirection.forward = bounceDirection; ((EntityState)this).PlayAnimation("FullBody, Override", "GrappleBounce", "Secondary.playbackRate", duration * 0.35f, 0f); ((EntityState)this).characterMotor.velocity = bounceDirection * bounceSpeed; } private void RecalculateSpeed() { bounceSpeed = ((BaseState)this).moveSpeedStat * Mathf.Lerp(initialSpeedCoefficient, finalSpeedCoefficient, ((EntityState)this).fixedAge / duration); } public override void FixedUpdate() { //IL_0021: Unknown result type (might be due to invalid IL or missing references) //IL_002c: Unknown result type (might be due to invalid IL or missing references) //IL_0031: Unknown result type (might be due to invalid IL or missing references) //IL_003d: Unknown result type (might be due to invalid IL or missing references) if (((EntityState)this).isAuthority) { ((EntityState)this).FixedUpdate(); RecalculateSpeed(); ((EntityState)this).characterMotor.velocity = bounceDirection * bounceSpeed; ((EntityState)this).characterDirection.forward = bounceDirection; if (((EntityState)this).fixedAge >= duration) { ((EntityState)this).outer.SetNextStateToMain(); } } } public override void OnExit() { ((EntityState)this).OnExit(); } } public class AltGrappleFallState : GhoulBaseSkillState { private OverlapAttack overlapAttack; private List overlapAttackHits = new List(); public override void OnEnter() { //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_0066: 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_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_007d: 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_009b: 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_00ad: 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_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_00cd: Expected O, but got Unknown ((BaseState)this).OnEnter(); HitBoxGroup hitBoxGroup = null; Transform modelTransform = ((EntityState)this).GetModelTransform(); if (Object.op_Implicit((Object)(object)modelTransform)) { hitBoxGroup = Array.Find(((Component)modelTransform).GetComponents(), (HitBoxGroup hitboxGroup) => hitboxGroup.groupName == "GrappleGroup"); } overlapAttack = new OverlapAttack { attacker = ((EntityState)this).gameObject, inflictor = ((EntityState)this).gameObject, teamIndex = ((BaseState)this).GetTeam(), procCoefficient = 3f, damage = 2f * ((BaseState)this).damageStat, isCrit = ((BaseState)this).RollCrit(), hitBoxGroup = hitBoxGroup, hitEffectPrefab = GhoulAssets.swordHitImpactEffect, impactSound = GhoulAssets.swordHitSoundEvent.index, damageType = DamageTypeCombo.GenericSecondary }; } public override void FixedUpdate() { //IL_0060: Unknown result type (might be due to invalid IL or missing references) ((EntityState)this).FixedUpdate(); overlapAttackHits.Clear(); if (overlapAttack.Fire(overlapAttackHits)) { if (overlapAttackHits.Count > 0) { ((EntityState)this).outer.SetNextState((EntityState)(object)new AltGrappleBounce()); NetworkIdentity component = ((EntityState)this).GetComponent(); if (Object.op_Implicit((Object)(object)component)) { NetMessageExtensions.Send((INetMessage)(object)new Helpers.SyncHeal(component.netId, 10 * overlapAttackHits.Count), (NetworkDestination)2); } } } else if (((EntityState)this).characterMotor.isGrounded) { ((EntityState)this).outer.SetNextStateToMain(); } } } public class AltGrappleThrowAttack : GhoulBaseSkillState { public static float baseDuration = 1.75f; public static float damageCoefficient = 6.25f; public static float procCoefficient = 1f; public static float firePercentTime = 0.6f; public static float force = 1500f; public static float recoil = 0f; public static float range = 6f; public CharacterBody targetBody; private float duration; private float fireTime; private bool hasFired; private string muzzleString; private BulletAttack attack; private OverlapAttack overlapAttack; private BullseyeSearch bullseyeSearch; private List overlapAttackHits = new List(); public override void OnEnter() { //IL_004e: Unknown result type (might be due to invalid IL or missing references) //IL_0058: Expected O, but got Unknown //IL_0099: Unknown result type (might be due to invalid IL or missing references) //IL_009e: 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_00b6: 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_00c2: Unknown result type (might be due to invalid IL or missing references) //IL_00cd: Unknown result type (might be due to invalid IL or missing references) //IL_00d9: Unknown result type (might be due to invalid IL or missing references) //IL_00e0: 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_00eb: Unknown result type (might be due to invalid IL or missing references) //IL_00f5: Expected O, but got Unknown ((BaseState)this).OnEnter(); duration = baseDuration / ((BaseState)this).attackSpeedStat; fireTime = firePercentTime * duration; ((EntityState)this).PlayAnimation("FullBody, Override", "Feral_Dash", "Special.PlaybackRate", duration, 0f); bullseyeSearch = new BullseyeSearch(); HitBoxGroup hitBoxGroup = null; Transform modelTransform = ((EntityState)this).GetModelTransform(); if (Object.op_Implicit((Object)(object)modelTransform)) { hitBoxGroup = Array.Find(((Component)modelTransform).GetComponents(), (HitBoxGroup hitboxGroup) => hitboxGroup.groupName == "FrenzyGroup"); } overlapAttack = new OverlapAttack { attacker = ((EntityState)this).gameObject, inflictor = ((EntityState)this).gameObject, teamIndex = ((BaseState)this).GetTeam(), damage = 0f, isCrit = ((BaseState)this).RollCrit(), hitBoxGroup = hitBoxGroup, damageType = DamageTypeCombo.op_Implicit((DamageType)2048) }; targetBody = FireOverlap(); } public override void FixedUpdate() { //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) ((EntityState)this).FixedUpdate(); ((EntityState)this).characterMotor.velocity = Vector3.zero; if ((Object)(object)targetBody != (Object)null && ((EntityState)this).fixedAge > fireTime) { Fire(); } if (((EntityState)this).fixedAge >= duration) { ((EntityState)this).outer.SetNextStateToMain(); } } public override void OnExit() { ((EntityState)this).GetModelAnimator().SetBool("RotateTendrils", false); ((EntityState)this).OnExit(); } private void Fire() { //IL_0051: 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_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_00c4: 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_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_00f4: Unknown result type (might be due to invalid IL or missing references) if (hasFired) { return; } hasFired = true; ((EntityState)this).characterBody.AddSpreadBloom(1.5f); Util.PlaySound("Play_Ghoul_Attack_Impact_Heavy", ((EntityState)this).gameObject); if (((EntityState)this).isAuthority) { Ray val = default(Ray); ((Ray)(ref val))..ctor(((EntityState)this).transform.position, targetBody.transform.position - ((EntityState)this).transform.position); EntityStateMachine val2 = EntityStateMachine.FindByCustomName(((Component)targetBody).gameObject, "Body"); if (!Object.op_Implicit((Object)(object)val2)) { Log.Warning("No StateMachiine of that name was found"); } if (val2 != null) { AltGrappleThrownState obj = new AltGrappleThrownState { ghoulAttacker = ((EntityState)this).gameObject }; Ray aimRay = ((BaseState)this).GetAimRay(); obj.throwDir = ((Ray)(ref aimRay)).direction; val2.SetState((EntityState)(object)obj); } NetworkIdentity component = ((EntityState)this).GetComponent(); if (Object.op_Implicit((Object)(object)component)) { NetMessageExtensions.Send((INetMessage)(object)new Helpers.SyncHeal(component.netId, 7), (NetworkDestination)2); } } } private CharacterBody FireOverlap() { overlapAttackHits.Clear(); if (overlapAttack.Fire(overlapAttackHits) && overlapAttackHits.Count > 0) { return overlapAttackHits[0].healthComponent?.body; } return null; } } public class Binge : BaseMeleeAttack { private RaycastHit hitInfo; private int attackIndex = 4; private int attacksUsed = 0; private uint sfxLoop; private float delay; private float cachedTime = 0f; public override void OnEnter() { //IL_0021: Unknown result type (might be due to invalid IL or missing references) //IL_0026: Unknown result type (might be due to invalid IL or missing references) //IL_004d: 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_00ec: Unknown result type (might be due to invalid IL or missing references) //IL_00f1: Unknown result type (might be due to invalid IL or missing references) delay = duration / (float)attackIndex; hitboxGroupName = "GrappleGroup"; damageType = DamageTypeCombo.GenericSpecial; damageCoefficient = 2.8f; procCoefficient = 1f; pushForce = 300f; bonusForce = Vector3.zero; baseDuration = 1.5f; attackStartPercentTime = 0f; attackEndPercentTime = 1f; earlyExitPercentTime = 0.9f; hitStopDuration = 0.012f; attackRecoil = 0.5f; hitHopVelocity = 4f; swingSoundString = "Play_Ghoul_Attack_Swing"; hitSoundString = "Play_Ghoul_Attack_Impact"; muzzleString = "HungryAttack"; playbackRateParam = "Special.playbackRate"; swingEffectPrefab = GhoulAssets.tendrilThrustEffect; hitEffectPrefab = GhoulAssets.swordHitImpactEffect; impactSound = GhoulAssets.swordHitSoundEvent.index; base.OnEnter(); } public override void FixedUpdate() { base.FixedUpdate(); attack.Fire((List)null); if (((EntityState)this).fixedAge >= cachedTime + delay && attacksUsed < attackIndex) { cachedTime = ((EntityState)this).fixedAge; attacksUsed++; Log.Debug(cachedTime + delay); Log.Debug(attacksUsed); attack.ResetIgnoredHealthComponents(); Util.PlaySound("Play_Ghoul_Attack_Swing", ((EntityState)this).gameObject); } } protected override void PlayAttackAnimation() { ((EntityState)this).PlayCrossfade("TentaclesUp, Override", "Feral_Binge_Reworked", playbackRateParam, duration, 0.1f * duration); ((EntityState)this).PlayCrossfade("TentaclesDown, Override", "Feral_Binge_Reworked", playbackRateParam, duration, 0.1f * duration); ((EntityState)this).PlayCrossfade("Gesture, Override", "Feral_Binge_Reworked", playbackRateParam, duration, 0.1f * duration); Util.PlaySound("", ((EntityState)this).gameObject); sfxLoop = Util.PlayAttackSpeedSound("Play_Ghoul_Tendril_Movement_Loop", ((EntityState)this).gameObject, ((BaseState)this).attackSpeedStat); } protected override void PlaySwingEffect() { base.PlaySwingEffect(); } protected override void OnHitEnemyAuthority() { //IL_001a: Unknown result type (might be due to invalid IL or missing references) base.OnHitEnemyAuthority(); NetworkIdentity component = ((EntityState)this).GetComponent(); if (Object.op_Implicit((Object)(object)component)) { NetMessageExtensions.Send((INetMessage)(object)new Helpers.SyncHeal(component.netId, 20), (NetworkDestination)2); } } public override void OnExit() { AkSoundEngine.StopPlayingID(sfxLoop); base.OnExit(); } } public class Tantalize : BaseMeleeAttack { private float dist; private GameObject terrainDust; private float hitSparkDelay; private bool hasSpawnedSpark; private RaycastHit hitInfo; private bool hasFired; private List attackHits = new List(); public override void OnEnter() { //IL_0012: Unknown result type (might be due to invalid IL or missing references) //IL_0017: Unknown result type (might be due to invalid IL or missing references) //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_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) //IL_0105: 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_01d6: Unknown result type (might be due to invalid IL or missing references) //IL_01db: Unknown result type (might be due to invalid IL or missing references) hitboxGroupName = "StabGroup"; damageType = DamageTypeCombo.op_Implicit((DamageType)1024); damageCoefficient = 1.8f; procCoefficient = 1f; pushForce = 300f; bonusForce = Vector3.zero; baseDuration = 1f; attackStartPercentTime = 0.3f; attackEndPercentTime = 0.7f; earlyExitPercentTime = 0.6f; hitStopDuration = 0.012f; attackRecoil = 0.5f; hitHopVelocity = 4f; swingSoundString = "Play_Ghoul_Attack_Swing"; hitSoundString = "Play_Ghoul_Attack_Impact_Heavy"; muzzleString = "TentacleStabR"; playbackRateParam = "Special.playbackRate"; swingEffectPrefab = GhoulAssets.tantalizeStabEffect; hitEffectPrefab = GhoulAssets.swordHitImpactEffect; impactSound = GhoulAssets.swordHitSoundEvent.index; hitSparkDelay = duration * 0.8f; dist = 25f; if (Physics.Raycast(((BaseState)this).GetAimRay(), ref hitInfo, 25f, LayerMask.op_Implicit(((LayerIndex)(ref LayerIndex.world)).mask), (QueryTriggerInteraction)2)) { dist = ((RaycastHit)(ref hitInfo)).distance; } float num = Mathf.Clamp(dist / 25f, 0.7f, 0.8f); hitSparkDelay = duration * num; ((EntityState)this).GetModelAnimator().SetFloat("TendrilDistance", dist); ((EntityState)this).GetModelAnimator().SetFloat("aimPitchCached", ((EntityState)this).GetModelAnimator().GetFloat("aimPitchCycle")); ((EntityState)this).GetModelAnimator().SetBool("RotateTendrils", true); base.OnEnter(); if (attack.isCrit) { attack.damageType = DamageTypeCombo.op_Implicit((DamageType)134217728); } } public override void FixedUpdate() { base.FixedUpdate(); ((EntityState)this).GetModelAnimator().SetFloat("aimPitchCached", ((EntityState)this).GetModelAnimator().GetFloat("aimPitchCycle")); if (((EntityState)this).fixedAge >= duration * 0.4f && !hasFired) { hasFired = true; attack.ignoredHealthComponentList.Clear(); attack.Fire((List)null); } } protected override void PlayAttackAnimation() { ((EntityState)this).PlayCrossfade("TentaclePitch, Additive", "TentaclePitch", (string)null, duration, 0.25f); ((EntityState)this).PlayCrossfade("TentaclesUp, Override", "HungerStabTendrils", playbackRateParam, duration, 0.1f * duration); ((EntityState)this).PlayCrossfade("Gesture, Override", "HungerStabBody", playbackRateParam, duration * 2f, 0.1f * duration); ((EntityState)this).PlayCrossfade("TentaclesDown, Override", "TentacleDownShrunk", playbackRateParam, duration, 0.1f * duration); } protected override void PlaySwingEffect() { base.PlaySwingEffect(); } protected override void OnHitEnemyAuthority() { //IL_0062: Unknown result type (might be due to invalid IL or missing references) base.OnHitEnemyAuthority(); ((EntityState)this).GetModelAnimator().SetBool("HungerStabHit", true); ((EntityState)this).characterBody.AddTimedBuff(GhoulBuffs.hungerBuff, 3f); Object.Instantiate(GhoulAssets.bloodDripEffect, ((Component)((EntityState)this).GetModelChildLocator().FindChild("TentacleBloodSpawn")).transform); NetworkIdentity component = ((EntityState)this).GetComponent(); if (Object.op_Implicit((Object)(object)component)) { NetMessageExtensions.Send((INetMessage)(object)new Helpers.SyncHeal(component.netId, 15), (NetworkDestination)2); } } public override void OnExit() { ((EntityState)this).GetModelAnimator().SetBool("RotateTendrils", false); ((EntityState)this).GetModelAnimator().SetFloat("aimPitchCached", 0.5f); ((EntityState)this).GetModelAnimator().SetBool("HungerStabHit", false); if ((Object)(object)terrainDust != (Object)null) { Object.Destroy((Object)(object)terrainDust); } base.OnExit(); } } public class GhoulBaseSkillState : BaseSkillState { public bool isSkinKaneki { get { ModelSkinController component = ((Component)((EntityState)this).GetModelTransform()).GetComponent(); if (Helpers.isLocalUserGhoul && component.skins[component.currentSkinIndex].nameToken.Contains("MASTERY")) { return true; } return false; } } } public class GhoulMainState : GenericCharacterMain { private GhoulWeaponComponent wep; public float enrageMulti = 0.16f; public float enrageTimeMulti = 2.25f; public static float enrageHealthCoefficient = 0.9f; public static float evolveDamageThreshold = 50f; public float baseMulti = 0.1f; private float drainRate; private float drainMulti = 1f; public bool altSkillRageFilled; public string preyBodyToken; private float range = 58f; private EntityStateMachine entityStateMachine; private EntityStateMachine entityStateMachine2; private bool enragedQueued; private Ray mond; public override void OnEnter() { ((GenericCharacterMain)this).OnEnter(); entityStateMachine = EntityStateMachine.FindByCustomName(((EntityState)this).gameObject, "Body"); entityStateMachine2 = EntityStateMachine.FindByCustomName(((EntityState)this).gameObject, "Weapon"); wep = ((EntityState)this).GetComponent(); } public override void Update() { ((GenericCharacterMain)this).Update(); if (((EntityState)this).skillLocator.secondary.baseSkill.skillName == "GhoulSwing") { DefaultGrappleIndicator(); } else if (((EntityState)this).skillLocator.secondary.baseSkill.skillName == "GhoulAltSwing") { AltGrappleIndicator(); } if (wep.isEnraged) { wep.drainSpeed = drainMulti; } else { wep.drainSpeed = 0.5f; } } public override void FixedUpdate() { ((GenericCharacterMain)this).FixedUpdate(); if (((EntityState)this).skillLocator.FindSkillByFamilyName("VcrGhoulBodyMiscFamily").baseSkill.skillName == "GhoulMisc") { wep.rageThreshold = ((EntityState)this).healthComponent.fullHealth * enrageHealthCoefficient; } if (((EntityState)this).skillLocator.FindSkillByFamilyName("VcrGhoulBodyMiscFamily").baseSkill.skillName == "GhoulAltMisc") { wep.rageThreshold = (1f + ((BaseState)this).damageStat) * evolveDamageThreshold; } if (wep.rageValue >= wep.rageThreshold && !wep.isEnraged && ((object)entityStateMachine2.state).GetType() == typeof(Idle) && ((EntityState)this).skillLocator.FindSkillByFamilyName("VcrGhoulBodyMiscFamily").baseSkill.skillName == "GhoulMisc") { ((EntityState)this).outer.SetInterruptState((EntityState)(object)new EnrageTransitionIn(), (InterruptPriority)2); } if (!((EntityState)this).characterBody.HasBuff(GhoulBuffs.feralAffix)) { if (wep.isEnraged) { drainRate = wep.rageThreshold * enrageMulti; drainMulti = Mathf.Lerp(0.5f, enrageTimeMulti, 0.08f * ((EntityState)this).fixedAge); if (wep.rageValue <= 0f) { ((EntityState)this).outer.SetNextState((EntityState)(object)new EnrageTransitionOut()); } } else { drainMulti = 1f; drainRate = wep.rageThreshold * baseMulti; } } else if (!wep.isEnraged && !((EntityState)this).characterBody.isPlayerControlled) { ((EntityState)this).outer.SetNextState((EntityState)(object)new EnrageTransitionIn()); } if (((EntityState)this).skillLocator.FindSkillByFamilyName("VcrGhoulBodyMiscFamily").baseSkill.skillName != "GhoulAltMisc") { if (wep.graceDelay <= 0f) { wep.rageValue -= drainRate * drainMulti * Time.fixedDeltaTime; } else { wep.graceDelay -= Time.fixedDeltaTime; } } wep.rageValue = Mathf.Clamp(wep.rageValue, 0f, wep.rageThreshold); } public override void ProcessJump() { //IL_0356: Unknown result type (might be due to invalid IL or missing references) //IL_035b: Unknown result type (might be due to invalid IL or missing references) //IL_0362: Unknown result type (might be due to invalid IL or missing references) //IL_0373: Expected O, but got Unknown //IL_0396: Unknown result type (might be due to invalid IL or missing references) //IL_039b: Unknown result type (might be due to invalid IL or missing references) //IL_03a2: Unknown result type (might be due to invalid IL or missing references) //IL_03ad: Unknown result type (might be due to invalid IL or missing references) //IL_03c4: Expected O, but got Unknown //IL_03d8: Unknown result type (might be due to invalid IL or missing references) //IL_03dd: Unknown result type (might be due to invalid IL or missing references) //IL_03e4: Unknown result type (might be due to invalid IL or missing references) //IL_03ef: Unknown result type (might be due to invalid IL or missing references) //IL_03f6: Unknown result type (might be due to invalid IL or missing references) //IL_03fb: Unknown result type (might be due to invalid IL or missing references) //IL_0400: Unknown result type (might be due to invalid IL or missing references) //IL_040b: Expected O, but got Unknown if (!((BaseCharacterMain)this).hasCharacterMotor) { return; } bool flag = false; bool flag2 = false; bool flag3 = ((EntityState)this).characterMotor.jumpCount < ((EntityState)this).characterBody.maxJumpCount; bool flag4 = (Object)(object)((EntityState)this).sfxLocator != (Object)null; if (Object.op_Implicit((Object)(object)((EntityState)this).characterBody) && Object.op_Implicit((Object)(object)((EntityState)this).characterBody.inventory) && ((EntityState)this).characterBody.inventory.GetItemCountEffective(Items.JumpDamageStrike) > 0) { ((EntityState)this).characterBody.GetBuffCount(Buffs.JumpDamageStrikeCharge); } if (!(base.jumpInputReceived && Object.op_Implicit((Object)(object)((EntityState)this).characterBody) && flag3)) { return; } int itemCountEffective = ((EntityState)this).characterBody.inventory.GetItemCountEffective(Items.JumpBoost); float num = 1f; float num2 = 1f; if (((EntityState)this).characterMotor.jumpCount >= ((EntityState)this).characterBody.baseJumpCount) { flag = true; num = 1.5f; num2 = 1.5f; } else if ((float)itemCountEffective > 0f && ((EntityState)this).characterBody.isSprinting) { float num3 = ((EntityState)this).characterBody.acceleration * ((EntityState)this).characterMotor.airControl; if (((EntityState)this).characterBody.moveSpeed > 0f && num3 > 0f) { flag2 = true; float num4 = Mathf.Sqrt(10f * (float)itemCountEffective / num3); float num5 = ((EntityState)this).characterBody.moveSpeed / num3; num = (num4 + num5) / num5; } } GenericCharacterMain.ApplyJumpVelocity(((EntityState)this).characterMotor, ((EntityState)this).characterBody, num, num2, false); if (flag4 && !string.IsNullOrEmpty(((EntityState)this).sfxLocator.jumpSound)) { Util.PlaySound(((EntityState)this).sfxLocator.jumpSound, ((Component)((EntityState)this).outer).gameObject); } if (((BaseCharacterMain)this).hasModelAnimator) { if (!wep.isEnraged) { int layerIndex = ((BaseCharacterMain)this).modelAnimator.GetLayerIndex("Body"); if (layerIndex >= 0) { if (((EntityState)this).characterMotor.jumpCount == 0 || ((EntityState)this).characterBody.baseJumpCount == 1) { ((BaseCharacterMain)this).modelAnimator.CrossFadeInFixedTime("Jump", ((BaseCharacterMain)this).smoothingParameters.intoJumpTransitionTime, layerIndex); } else { ((BaseCharacterMain)this).modelAnimator.CrossFadeInFixedTime("BonusJump", ((BaseCharacterMain)this).smoothingParameters.intoJumpTransitionTime, layerIndex); } } } else { int layerIndex2 = ((BaseCharacterMain)this).modelAnimator.GetLayerIndex("Body, Enraged"); if (layerIndex2 >= 0) { if (((EntityState)this).characterMotor.jumpCount == 0 || ((EntityState)this).characterBody.baseJumpCount == 1) { ((BaseCharacterMain)this).modelAnimator.CrossFadeInFixedTime("Jump", ((BaseCharacterMain)this).smoothingParameters.intoJumpTransitionTime, layerIndex2); } else { ((BaseCharacterMain)this).modelAnimator.CrossFadeInFixedTime("BonusJump", ((BaseCharacterMain)this).smoothingParameters.intoJumpTransitionTime, layerIndex2); } } } } if (flag) { EffectManager.SpawnEffect(LegacyResourcesAPI.Load("Prefabs/Effects/FeatherEffect"), new EffectData { origin = ((EntityState)this).characterBody.footPosition }, true); } else if (((EntityState)this).characterMotor.jumpCount > 0) { EffectManager.SpawnEffect(LegacyResourcesAPI.Load("Prefabs/Effects/ImpactEffects/CharacterLandImpact"), new EffectData { origin = ((EntityState)this).characterBody.footPosition, scale = ((EntityState)this).characterBody.radius }, true); } if (flag2) { EffectManager.SpawnEffect(LegacyResourcesAPI.Load("Prefabs/Effects/BoostJumpEffect"), new EffectData { origin = ((EntityState)this).characterBody.footPosition, rotation = Util.QuaternionSafeLookRotation(((EntityState)this).characterMotor.velocity) }, true); } CharacterMotor characterMotor = ((EntityState)this).characterMotor; characterMotor.jumpCount++; ((EntityState)this).characterBody.TriggerJumpEventGlobally(); } public override void OnSerialize(NetworkWriter writer) { ((EntityState)this).OnSerialize(writer); writer.Write(wep.rageValue); } public override void OnDeserialize(NetworkReader reader) { ((EntityState)this).OnDeserialize(reader); wep.rageValue = reader.ReadSingle(); } public void DefaultGrappleIndicator() { //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_0013: 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_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002c: Unknown result type (might be due to invalid IL or missing references) //IL_003e: 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_0076: 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_00ff: 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_0159: Unknown result type (might be due to invalid IL or missing references) Vector3 corePosition = ((EntityState)this).characterBody.corePosition; Ray aimRay = ((BaseState)this).GetAimRay(); mond = new Ray(corePosition, ((Ray)(ref aimRay)).direction); RaycastHit val = default(RaycastHit); RaycastHit val2 = default(RaycastHit); if (Util.CharacterRaycast(((EntityState)this).gameObject, mond, ref val, range, ((LayerIndex)(ref LayerIndex.world)).mask, (QueryTriggerInteraction)2)) { wep.grapplable = true; } else if (Util.CharacterRaycast(((EntityState)this).gameObject, mond, ref val2, range, ((LayerIndex)(ref LayerIndex.enemyBody)).mask, (QueryTriggerInteraction)2)) { if (Object.op_Implicit((Object)(object)((Component)((RaycastHit)(ref val2)).transform).GetComponent()) && !((Component)((RaycastHit)(ref val2)).transform).GetComponent().isBoss) { wep.grapplable = true; } } else { wep.grapplable = false; } RaycastHit val3 = default(RaycastHit); if (wep.isEnraged && Util.CharacterSpherecast(((EntityState)this).gameObject, mond, 7f, ref val3, 15f, ((LayerIndex)(ref LayerIndex.enemyBody)).mask, (QueryTriggerInteraction)2)) { if (Object.op_Implicit((Object)(object)((Component)((RaycastHit)(ref val3)).transform).GetComponent())) { wep.enemyDetected = true; } } else if (Util.CharacterSpherecast(((EntityState)this).gameObject, mond, 4f, ref val3, 25f, ((LayerIndex)(ref LayerIndex.enemyBody)).mask, (QueryTriggerInteraction)2)) { if (Object.op_Implicit((Object)(object)((Component)((RaycastHit)(ref val3)).transform).GetComponent())) { wep.enemyDetected = true; } } else { wep.enemyDetected = false; } } public void AltGrappleIndicator() { //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_0013: 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_0020: Unknown result type (might be due to invalid IL or missing references) //IL_002c: Unknown result type (might be due to invalid IL or missing references) //IL_003e: 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_0086: Unknown result type (might be due to invalid IL or missing references) Vector3 corePosition = ((EntityState)this).characterBody.corePosition; Ray aimRay = ((BaseState)this).GetAimRay(); mond = new Ray(corePosition, ((Ray)(ref aimRay)).direction); RaycastHit val = default(RaycastHit); if (Util.CharacterRaycast(((EntityState)this).gameObject, mond, ref val, range, ((LayerIndex)(ref LayerIndex.enemyBody)).mask, (QueryTriggerInteraction)2)) { wep.grapplable = true; } else { wep.grapplable = false; } RaycastHit val2 = default(RaycastHit); if (Util.CharacterSpherecast(((EntityState)this).gameObject, mond, 4f, ref val2, 25f, ((LayerIndex)(ref LayerIndex.enemyBody)).mask, (QueryTriggerInteraction)2)) { if (Object.op_Implicit((Object)(object)((Component)((RaycastHit)(ref val2)).transform).GetComponent())) { wep.enemyDetected = true; } } else { wep.enemyDetected = false; } } } public class GhoulSpawnState : GenericCharacterSpawnState { public GameObject portalPrefab; public static Material destealthMaterial; public static float delay = 0.75f; private bool hasPlayed; public override void OnEnter() { //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) base.duration = 4f; if (NetworkServer.active) { ((EntityState)this).characterBody.AddBuff(LegacyResourcesAPI.Load("BuffDefs/HiddenInvincibility")); } if (Object.op_Implicit((Object)(object)((EntityState)this).cameraTargetParams)) { ((EntityState)this).cameraTargetParams.fovOverride = Mathf.Lerp(120f, 60f, ((EntityState)this).fixedAge / base.duration + delay); } portalPrefab = Addressables.LoadAssetAsync((object)"RoR2/Base/Imp/ImpDeathEffect.prefab").WaitForCompletion(); if (Object.op_Implicit((Object)(object)((Component)((EntityState)this).modelLocator.modelTransform).GetComponent())) { ((Behaviour)((Component)((EntityState)this).modelLocator.modelTransform).GetComponent().componentsToDisableOnRagdoll[0]).enabled = false; } ((GenericCharacterSpawnState)this).OnEnter(); } public override void OnExit() { ((EntityState)this).OnExit(); if (Object.op_Implicit((Object)(object)((Component)((EntityState)this).modelLocator.modelTransform).GetComponent())) { ((Behaviour)((Component)((EntityState)this).modelLocator.modelTransform).GetComponent().componentsToDisableOnRagdoll[0]).enabled = true; } if (NetworkServer.active) { ((EntityState)this).characterBody.RemoveBuff(LegacyResourcesAPI.Load("BuffDefs/HiddenInvincibility")); } } public override void FixedUpdate() { ((GenericCharacterSpawnState)this).FixedUpdate(); if (((EntityState)this).fixedAge >= delay && !hasPlayed) { hasPlayed = true; Visuals(); } if (((EntityState)this).fixedAge >= base.duration + delay) { ((EntityState)this).outer.SetNextStateToMain(); } } private void Visuals() { //IL_004f: Unknown result type (might be due to invalid IL or missing references) //IL_0055: Expected O, but got Unknown //IL_0061: Unknown result type (might be due to invalid IL or missing references) ((EntityState)this).PlayAnimation("Body", "Spawn", "Spawn.playbackRate", base.duration - (delay + 0.5f), 0f); Util.PlaySound("Play_Ghoul_Tendril_Grow", ((EntityState)this).gameObject); if (Object.op_Implicit((Object)(object)portalPrefab)) { EffectData val = new EffectData(); val.origin = ((EntityState)this).modelLocator.modelBaseTransform.position; EffectManager.SpawnEffect(portalPrefab, val, false); } if (Object.op_Implicit((Object)(object)destealthMaterial)) { TemporaryOverlayInstance val2 = TemporaryOverlayManager.AddOverlay(((Component)((EntityState)this).GetModelAnimator()).gameObject); val2.duration = 1f; val2.destroyComponentOnEnd = true; val2.originalMaterial = destealthMaterial; val2.inspectorCharacterModel = ((Component)((EntityState)this).GetModelAnimator()).gameObject.GetComponent(); val2.alphaCurve = AnimationCurve.EaseInOut(0f, 1f, 1f, 0f); val2.animateShaderAlpha = true; } } } public class BlockCounter : BaseMeleeAttack { public float blockedDamage = 0f; private float dist; public override void OnEnter() { //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_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_00c2: Unknown result type (might be due to invalid IL or missing references) //IL_00c7: Unknown result type (might be due to invalid IL or missing references) //IL_00d8: 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) hitboxGroupName = "BlockCounterGroup"; damageType = DamageTypeCombo.GenericUtility; damageCoefficient = 4f; procCoefficient = 1f; pushForce = 300f; bonusForce = Vector3.zero; baseDuration = 1.35f; attackStartPercentTime = 0.2f; attackEndPercentTime = 0.4f; earlyExitPercentTime = 0.6f; hitStopDuration = 0.012f; attackRecoil = 0.5f; hitHopVelocity = 4f; swingSoundString = "Play_Ghoul_Attack_Swing"; hitSoundString = ""; playbackRateParam = "Utility.playbackRate"; hitEffectPrefab = GhoulAssets.swordHitImpactEffect; impactSound = GhoulAssets.swordHitSoundEvent.index; dist = 25f; RaycastHit val = default(RaycastHit); if (Physics.Raycast(((BaseState)this).GetAimRay(), ref val, 25f, LayerMask.op_Implicit(((LayerIndex)(ref LayerIndex.world)).mask), (QueryTriggerInteraction)2)) { dist = ((RaycastHit)(ref val)).distance; } ((EntityState)this).GetModelAnimator().SetFloat("TendrilDistance", dist); ((EntityState)this).GetModelAnimator().SetFloat("aimPitchCached", ((EntityState)this).GetModelAnimator().GetFloat("aimPitchCycle")); ((EntityState)this).GetModelAnimator().SetBool("RotateTendrils", true); base.OnEnter(); } protected override void ModifyOverlapAttack(OverlapAttack attack) { base.ModifyOverlapAttack(attack); attack.damage += blockedDamage; } protected override void PlayAttackAnimation() { ((EntityState)this).PlayCrossfade("TentaclesUp, Override", "Block_Attack", playbackRateParam, 0.46f * duration, 0.1f * duration); ((EntityState)this).PlayCrossfade("TentaclesDown, Override", "Block_Attack", playbackRateParam, 0.46f * duration, 0.1f * duration); } protected override void PlaySwingEffect() { base.PlaySwingEffect(); } protected override void OnHitEnemyAuthority() { //IL_001a: Unknown result type (might be due to invalid IL or missing references) base.OnHitEnemyAuthority(); NetworkIdentity component = ((EntityState)this).GetComponent(); if (Object.op_Implicit((Object)(object)component)) { NetMessageExtensions.Send((INetMessage)(object)new Helpers.SyncHeal(component.netId, 15), (NetworkDestination)2); } } public override void OnExit() { ((EntityState)this).GetModelAnimator().SetFloat("aimPitchCached", 0.5f); ((EntityState)this).GetModelAnimator().SetBool("RotateTendrils", false); base.OnExit(); } } public class BlockStart : BaseSkillState { public static float baseDuration = 2f; public static float minHoldTime = 0.25f; private float maxDuration; internal float storedDamage = 0f; private GhoulWeaponComponent wep; public static float masSpeed = 3.5f; private float speed; public override void OnEnter() { ((BaseState)this).OnEnter(); maxDuration = baseDuration * ((BaseState)this).attackSpeedStat; ((EntityState)this).characterBody.SetAimTimer(2f); Util.PlaySound("Play_Ghoul_Tendril_Grow", ((EntityState)this).gameObject); if (((NetworkBehaviour)((EntityState)this).characterBody).hasAuthority) { if (NetworkServer.active) { ((EntityState)this).characterBody.AddBuff(GhoulBuffs.blockBuff); } wep = ((EntityState)this).GetComponent(); } RecalculateSpeed(); ((EntityState)this).GetModelAnimator().SetBool("isBlocking", true); ((EntityState)this).PlayAnimation("Gesture, Override", "BodyBlock", "Utility.playbackRate", 0.5f / ((BaseState)this).attackSpeedStat, 0f); ((EntityState)this).PlayAnimation("TentaclesUp, Override", "Block", "Utility.playbackRate", 0.5f / ((BaseState)this).attackSpeedStat, 0f); ((EntityState)this).PlayAnimation("TentaclesDown, Override", "Block", "Utility.playbackRate", 0.5f / ((BaseState)this).attackSpeedStat, 0f); wep.EnrageOverlay(maxDuration); } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); if (((EntityState)this).isAuthority) { ((EntityState)this).characterBody.isSprinting = false; if (Object.op_Implicit((Object)(object)wep)) { storedDamage = wep.blockedDamage; } RecalculateSpeed(); if (!ShouldKeepChargingAuthority() && ((EntityState)this).fixedAge >= minHoldTime) { ((EntityState)this).outer.SetNextState(NextSkill()); } if (((EntityState)this).fixedAge >= maxDuration) { ((EntityState)this).outer.SetNextState(NextSkill()); } } } public virtual EntityState NextSkill() { return (EntityState)(object)new EnragedSpin { initialSpeed = speed, baseDamageCoefficient = 3.4f }; } public override void OnExit() { if (NetworkServer.active) { ((EntityState)this).characterBody.RemoveBuff(GhoulBuffs.blockBuff); } ((EntityState)this).GetModelAnimator().SetBool("isBlocking", false); if (Object.op_Implicit((Object)(object)wep)) { wep.blockedDamage = 0f; } ((EntityState)this).OnExit(); } private void RecalculateSpeed() { speed = ((BaseState)this).moveSpeedStat * Mathf.Lerp(0f, masSpeed, ((EntityState)this).fixedAge / maxDuration); } protected virtual bool ShouldKeepChargingAuthority() { return ((EntityState)this).inputBank.skill3.down; } public override InterruptPriority GetMinimumInterruptPriority() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (InterruptPriority)2; } } public class EnragedSpin : BaseMeleeAttack { public GhoulWeaponComponent swep; public float initialSpeed = 8f; public float finalSpeed = 3f; public float baseDamageCoefficient = 4f; private Vector3 moveDir; private Vector3 prevVel; private float speed; private bool hitEnemy; public GameObject blinkPrefab = BlinkState.blinkPrefab; public override void OnEnter() { //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_0046: 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_00cf: 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_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_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_00f4: 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_010c: Unknown result type (might be due to invalid IL or missing references) swep = ((EntityState)this).GetComponent(); hitboxGroupName = "SpinGroup"; damageType = DamageTypeCombo.GenericUtility; damageCoefficient = baseDamageCoefficient; procCoefficient = 1f; pushForce = 300f; bonusForce = Vector3.zero; baseDuration = 0.84f; attackStartPercentTime = 0f; attackEndPercentTime = 0.7f; earlyExitPercentTime = 0.6f; hitStopDuration = 0f; attackRecoil = 0f; hitHopVelocity = 0f; swingSoundString = "HenrySwordSwing"; hitSoundString = ""; playbackRateParam = "Utility.playbackRate"; hitEffectPrefab = GhoulAssets.swordHitImpactEffect; impactSound = GhoulAssets.swordHitSoundEvent.index; Ray aimRay = ((BaseState)this).GetAimRay(); moveDir = ((Ray)(ref aimRay)).direction; prevVel = ((EntityState)this).characterMotor.velocity; base.OnEnter(); CreateBlinkEffect(Util.GetCorePosition(((EntityState)this).gameObject)); swep.ImpOverlay(duration); } public override void FixedUpdate() { //IL_0016: 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_0027: Unknown result type (might be due to invalid IL or missing references) //IL_002c: Unknown result type (might be due to invalid IL or missing references) //IL_0031: Unknown result type (might be due to invalid IL or missing references) base.FixedUpdate(); RecalculateSpeed(); ((EntityState)this).characterMotor.velocity = moveDir * speed + prevVel; } protected override void PlayAttackAnimation() { ((EntityState)this).PlayAnimation("FullBody, Override", "SpinAttack", playbackRateParam, duration, 0f); } protected override void PlaySwingEffect() { base.PlaySwingEffect(); } private void RecalculateSpeed() { speed = ((BaseState)this).moveSpeedStat * Mathf.Lerp(initialSpeed, finalSpeed, ((EntityState)this).fixedAge / duration); } protected override void OnHitEnemyAuthority() { //IL_0021: Unknown result type (might be due to invalid IL or missing references) base.OnHitEnemyAuthority(); hitEnemy = true; NetworkIdentity component = ((EntityState)this).GetComponent(); if (Object.op_Implicit((Object)(object)component)) { NetMessageExtensions.Send((INetMessage)(object)new Helpers.SyncHeal(component.netId, 10), (NetworkDestination)2); } } private void CreateBlinkEffect(Vector3 origin) { //IL_0001: Unknown result type (might be due to invalid IL or missing references) //IL_0007: Expected O, but got Unknown //IL_0009: 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_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) EffectData val = new EffectData(); val.rotation = Util.QuaternionSafeLookRotation(moveDir); val.origin = origin; EffectManager.SpawnEffect(blinkPrefab, val, false); } public override void OnExit() { if (!hitEnemy && swep.isEnraged) { ((EntityState)this).outer.SetNextState((EntityState)(object)new EnrageTransitionOut()); } base.OnExit(); } } public class GrabBaseState : GhoulBaseSkillState { public float duration = 1f; public Collider grabbedCollider; private GameObject _anchor; private Vector3 _initialPosition; private Vector3 _lastPosition; private Quaternion _lastRotation; private Transform _modelTransform; public CharacterBody grabbedBody { get; set; } public override void OnEnter() { //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_0044: 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_0050: Unknown result type (might be due to invalid IL or missing references) //IL_005a: Expected O, but got Unknown //IL_0081: 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_00d4: 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_0140: 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_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_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) ((BaseState)this).OnEnter(); grabbedCollider = findClosestHurtbox(); if ((Object)(object)grabbedCollider == (Object)null) { ((EntityState)this).outer.SetNextStateToMain(); return; } Bounds bounds = grabbedCollider.bounds; Vector3 center = ((Bounds)(ref bounds)).center; _anchor = new GameObject("ghoulAnchor"); _anchor.transform.SetParent(((Component)grabbedCollider).transform); _anchor.transform.position = center; if ((Object)(object)grabbedBody.modelLocator != (Object)null && (Object)(object)grabbedBody.modelLocator.modelTransform != (Object)null) { _anchor.transform.rotation = grabbedBody.modelLocator.modelTransform.rotation; } else { _anchor.transform.rotation = ((Component)grabbedBody).gameObject.transform.rotation; } ((EntityState)this).gameObject.layer = LayerIndex.fakeActor.intVal; _modelTransform = ((EntityState)this).GetModelTransform(); _initialPosition = (Object.op_Implicit((Object)(object)_modelTransform) ? _modelTransform.position : ((EntityState)this).transform.position); _lastPosition = _initialPosition; _lastRotation = ((EntityState)this).transform.rotation; ((Behaviour)((EntityState)this).modelLocator).enabled = false; } public override void OnExit() { //IL_0017: 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) ((BaseCharacterController)((EntityState)this).characterMotor).Motor.SetPosition(((Component)((EntityState)this).characterMotor).transform.position + new Vector3(0f, 2.25f, 0f), true); Object.Destroy((Object)(object)_anchor); ((EntityState)this).PlayAnimation("FullBody, Underride", "RidingDismount"); ((Behaviour)((EntityState)this).modelLocator).enabled = true; } public override void FixedUpdate() { //IL_003e: Unknown result type (might be due to invalid IL or missing references) //IL_004f: Unknown result type (might be due to invalid IL or missing references) //IL_0054: Unknown result type (might be due to invalid IL or missing references) //IL_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(); if (grabbedBody.healthComponent.alive) { if (((EntityState)this).isAuthority && Object.op_Implicit((Object)(object)((EntityState)this).characterMotor)) { ((EntityState)this).characterMotor.moveDirection = Vector3.zero; ((EntityState)this).characterMotor.velocity = Vector3.zero; ((EntityState)this).characterMotor.rootMotion = Vector3.zero; if (((EntityState)this).fixedAge >= duration) { ((EntityState)this).outer.SetNextStateToMain(); } } } else { ((EntityState)this).outer.SetNextStateToMain(); } } public override void OnSerialize(NetworkWriter writer) { ((BaseSkillState)this).OnSerialize(writer); if (Object.op_Implicit((Object)(object)grabbedBody)) { writer.Write(((Component)grabbedBody).gameObject); } } public override void OnDeserialize(NetworkReader reader) { ((BaseSkillState)this).OnDeserialize(reader); GameObject val = reader.ReadGameObject(); if (Object.op_Implicit((Object)(object)val)) { grabbedBody = val.GetComponent(); } } private Collider findClosestHurtbox() { //IL_00c7: 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_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) if ((Object)(object)grabbedBody.hurtBoxGroup == (Object)null) { return null; } string name = ((Object)((Component)grabbedBody.hurtBoxGroup.mainHurtBox.healthComponent).gameObject).name; name.Replace("(Clone)", ""); GameObject val = BodyCatalog.FindBodyPrefab(name); if (!Object.op_Implicit((Object)(object)val)) { return null; } HurtBox[] array = null; int num = -1; if (Object.op_Implicit((Object)(object)val.GetComponentInChildren())) { array = val.GetComponentInChildren().hurtBoxes; for (int i = 0; i < array.Length; i++) { HurtBox val2 = array[i]; if (!((Object)(object)val2 == (Object)null)) { if (num == -1) { num = i; } else if (Vector3.Distance(((Component)val2).transform.position, ((EntityState)this).transform.position) > Vector3.Distance(((Component)array[i]).transform.position, ((EntityState)this).transform.position)) { num = i; } } } } return grabbedBody.hurtBoxGroup.hurtBoxes[num].collider; } } public class Roll : BaseSkillState { public static float duration = 0.5f; public static float initialSpeedCoefficient = 5f; public static float finalSpeedCoefficient = 2.5f; public static string dodgeSoundString = "HenryRoll"; public static float dodgeFOV = DodgeState.dodgeFOV; private float rollSpeed; private Vector3 forwardDirection; private Animator animator; private Vector3 previousPosition; public override void OnEnter() { //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_0098: 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_0069: 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_009d: Unknown result type (might be due to invalid IL or missing references) //IL_009e: 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_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_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_006e: 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_0109: 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_0139: 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_013e: Unknown result type (might be due to invalid IL or missing references) //IL_0147: Unknown result type (might be due to invalid IL or missing references) //IL_014c: Unknown result type (might be due to invalid IL or missing references) //IL_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) ((BaseState)this).OnEnter(); animator = ((EntityState)this).GetModelAnimator(); if (((EntityState)this).isAuthority && Object.op_Implicit((Object)(object)((EntityState)this).inputBank) && Object.op_Implicit((Object)(object)((EntityState)this).characterDirection)) { Vector3 val = ((((EntityState)this).inputBank.moveVector == Vector3.zero) ? ((EntityState)this).characterDirection.forward : ((EntityState)this).inputBank.moveVector); forwardDirection = ((Vector3)(ref val)).normalized; } Vector3 val2 = (Object.op_Implicit((Object)(object)((EntityState)this).characterDirection) ? ((EntityState)this).characterDirection.forward : forwardDirection); Vector3 val3 = Vector3.Cross(Vector3.up, val2); float num = Vector3.Dot(forwardDirection, val2); float num2 = Vector3.Dot(forwardDirection, val3); RecalculateRollSpeed(); if (Object.op_Implicit((Object)(object)((EntityState)this).characterMotor) && Object.op_Implicit((Object)(object)((EntityState)this).characterDirection)) { ((EntityState)this).characterMotor.velocity.y = 0f; ((EntityState)this).characterMotor.velocity = forwardDirection * rollSpeed; } Vector3 val4 = (Object.op_Implicit((Object)(object)((EntityState)this).characterMotor) ? ((EntityState)this).characterMotor.velocity : Vector3.zero); previousPosition = ((EntityState)this).transform.position - val4; ((EntityState)this).PlayAnimation("FullBody, Override", "Roll", "Roll.playbackRate", duration, 0f); Util.PlaySound(dodgeSoundString, ((EntityState)this).gameObject); if (NetworkServer.active) { ((EntityState)this).characterBody.AddTimedBuff(Buffs.HiddenInvincibility, 0.5f * duration); } } private void RecalculateRollSpeed() { rollSpeed = ((BaseState)this).moveSpeedStat * Mathf.Lerp(initialSpeedCoefficient, finalSpeedCoefficient, ((EntityState)this).fixedAge / duration); } public override void FixedUpdate() { //IL_0025: 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_0071: Unknown result type (might be due to invalid IL or missing references) //IL_0076: Unknown result type (might be due to invalid IL or missing references) //IL_007b: 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_009e: 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_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_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_00bf: Unknown result type (might be due to invalid IL or missing references) //IL_00c1: Unknown result type (might be due to invalid IL or missing references) //IL_00c4: 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_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_00fb: Unknown result type (might be due to invalid IL or missing references) //IL_00fd: Unknown result type (might be due to invalid IL or missing references) ((EntityState)this).FixedUpdate(); RecalculateRollSpeed(); if (Object.op_Implicit((Object)(object)((EntityState)this).characterDirection)) { ((EntityState)this).characterDirection.forward = forwardDirection; } if (Object.op_Implicit((Object)(object)((EntityState)this).cameraTargetParams)) { ((EntityState)this).cameraTargetParams.fovOverride = Mathf.Lerp(dodgeFOV, 60f, ((EntityState)this).fixedAge / duration); } Vector3 val = ((EntityState)this).transform.position - previousPosition; Vector3 normalized = ((Vector3)(ref val)).normalized; if (Object.op_Implicit((Object)(object)((EntityState)this).characterMotor) && Object.op_Implicit((Object)(object)((EntityState)this).characterDirection) && normalized != Vector3.zero) { Vector3 val2 = normalized * rollSpeed; float num = Mathf.Max(Vector3.Dot(val2, forwardDirection), 0f); val2 = forwardDirection * num; val2.y = 0f; ((EntityState)this).characterMotor.velocity = val2; } previousPosition = ((EntityState)this).transform.position; if (((EntityState)this).isAuthority && ((EntityState)this).fixedAge >= duration) { ((EntityState)this).outer.SetNextStateToMain(); } } public override void OnExit() { if (Object.op_Implicit((Object)(object)((EntityState)this).cameraTargetParams)) { ((EntityState)this).cameraTargetParams.fovOverride = -1f; } ((EntityState)this).OnExit(); ((EntityState)this).characterMotor.disableAirControlUntilCollision = false; } public override void OnSerialize(NetworkWriter writer) { //IL_000b: Unknown result type (might be due to invalid IL or missing references) ((BaseSkillState)this).OnSerialize(writer); writer.Write(forwardDirection); } 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) ((BaseSkillState)this).OnDeserialize(reader); forwardDirection = reader.ReadVector3(); } } public class Shoot : BaseSkillState { public static float damageCoefficient = 5f; public static float procCoefficient = 1f; public static float baseDuration = 0.6f; public static float firePercentTime = 0f; public static float force = 800f; public static float recoil = 3f; public static float range = 256f; public static GameObject tracerEffectPrefab = LegacyResourcesAPI.Load("Prefabs/Effects/Tracers/TracerGoldGat"); private float duration; private float fireTime; private bool hasFired; private string muzzleString; public override void OnEnter() { ((BaseState)this).OnEnter(); duration = baseDuration / ((BaseState)this).attackSpeedStat; fireTime = firePercentTime * duration; ((EntityState)this).characterBody.SetAimTimer(2f); muzzleString = "Muzzle"; ((EntityState)this).PlayAnimation("LeftArm, Override", "ShootGun", "ShootGun.playbackRate", 1.8f, 0f); } public override void OnExit() { ((EntityState)this).OnExit(); } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); if (((EntityState)this).fixedAge >= fireTime) { Fire(); } if (((EntityState)this).fixedAge >= duration && ((EntityState)this).isAuthority) { ((EntityState)this).outer.SetNextStateToMain(); } } private void Fire() { //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_009b: 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_00aa: Unknown result type (might be due to invalid IL or missing references) //IL_00b5: Unknown result type (might be due to invalid IL or missing references) //IL_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_00c2: 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_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_00dc: Unknown result type (might be due to invalid IL or missing references) //IL_00e1: Unknown result type (might be due to invalid IL or missing references) //IL_00e6: Unknown result type (might be due to invalid IL or missing references) //IL_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) //IL_0104: 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_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_011a: Unknown result type (might be due to invalid IL or missing references) //IL_0125: Unknown result type (might be due to invalid IL or missing references) //IL_0131: 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_0149: 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_0156: Unknown result type (might be due to invalid IL or missing references) //IL_015c: Unknown result type (might be due to invalid IL or missing references) //IL_0167: Unknown result type (might be due to invalid IL or missing references) //IL_0172: Unknown result type (might be due to invalid IL or missing references) //IL_0179: 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_0184: 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_01a1: Unknown result type (might be due to invalid IL or missing references) //IL_01ac: Unknown result type (might be due to invalid IL or missing references) //IL_01ae: Unknown result type (might be due to invalid IL or missing references) //IL_01b3: Unknown result type (might be due to invalid IL or missing references) if (!hasFired) { hasFired = true; ((EntityState)this).characterBody.AddSpreadBloom(1.5f); EffectManager.SimpleMuzzleFlash(FirePistol2.muzzleEffectPrefab, ((EntityState)this).gameObject, muzzleString, false); Util.PlaySound("HenryShootPistol", ((EntityState)this).gameObject); if (((EntityState)this).isAuthority) { Ray aimRay = ((BaseState)this).GetAimRay(); ((BaseState)this).AddRecoil(-1f * recoil, -2f * recoil, -0.5f * recoil, 0.5f * recoil); new BulletAttack { bulletCount = 1u, aimVector = ((Ray)(ref aimRay)).direction, origin = ((Ray)(ref aimRay)).origin, damage = damageCoefficient * ((BaseState)this).damageStat, damageColorIndex = (DamageColorIndex)0, damageType = DamageTypeCombo.GenericSecondary, falloffModel = (FalloffModel)0, maxDistance = range, force = force, hitMask = CommonMasks.bullet, minSpread = 0f, maxSpread = 0f, isCrit = ((BaseState)this).RollCrit(), owner = ((EntityState)this).gameObject, muzzleName = muzzleString, smartCollision = true, procChainMask = default(ProcChainMask), procCoefficient = procCoefficient, radius = 0.75f, sniper = false, stopperMask = CommonMasks.bullet, weapon = null, tracerEffectPrefab = tracerEffectPrefab, spreadPitchScale = 1f, spreadYawScale = 1f, queryTriggerInteraction = (QueryTriggerInteraction)0, hitEffectPrefab = FirePistol2.hitEffectPrefab }.Fire(); } } } public override InterruptPriority GetMinimumInterruptPriority() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (InterruptPriority)2; } } public class SlashCombo : BaseMeleeAttack { public override void OnEnter() { //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_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_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) hitboxGroupName = "SwordGroup"; damageType = DamageTypeCombo.GenericPrimary; damageCoefficient = 12f; procCoefficient = 1f; pushForce = 300f; bonusForce = Vector3.zero; baseDuration = 1f; attackStartPercentTime = 0.2f; attackEndPercentTime = 0.4f; earlyExitPercentTime = 0.6f; hitStopDuration = 0.012f; attackRecoil = 0.5f; hitHopVelocity = 4f; swingSoundString = "HenrySwordSwing"; hitSoundString = ""; muzzleString = ((swingIndex % 2 == 0) ? "SwingLeft" : "SwingRight"); playbackRateParam = "Slash.playbackRate"; hitEffectPrefab = GhoulAssets.swordHitImpactEffect; impactSound = GhoulAssets.swordHitSoundEvent.index; base.OnEnter(); } protected override void PlayAttackAnimation() { ((EntityState)this).PlayCrossfade("Gesture, Override", "Slash" + (1 + swingIndex), playbackRateParam, duration, 0.1f * duration); } protected override void PlaySwingEffect() { base.PlaySwingEffect(); } protected override void OnHitEnemyAuthority() { base.OnHitEnemyAuthority(); } public override void OnExit() { base.OnExit(); } } public class ThrowBomb : GenericProjectileBaseState { public static float BaseDuration = 0.65f; public static float BaseDelayDuration = 0f; public static float DamageCoefficient = 16f; public override void OnEnter() { base.projectilePrefab = GhoulAssets.bombProjectilePrefab; base.attackSoundString = "HenryBombThrow"; base.baseDuration = BaseDuration; base.baseDelayBeforeFiringProjectile = BaseDelayDuration; base.damageCoefficient = DamageCoefficient; base.force = 80f; base.recoilAmplitude = 0.1f; base.bloom = 10f; ((GenericProjectileBaseState)this).OnEnter(); } public override void ModifyProjectileInfo(ref FireProjectileInfo fireProjectileInfo) { //IL_000a: Unknown result type (might be due to invalid IL or missing references) ((GenericProjectileBaseState)this).ModifyProjectileInfo(ref fireProjectileInfo); fireProjectileInfo.damageTypeOverride = DamageTypeCombo.GenericSpecial; } public override void FixedUpdate() { ((GenericProjectileBaseState)this).FixedUpdate(); } public override InterruptPriority GetMinimumInterruptPriority() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (InterruptPriority)1; } public override void PlayAnimation(float duration) { if (Object.op_Implicit((Object)(object)((EntityState)this).GetModelAnimator())) { ((EntityState)this).PlayAnimation("Gesture, Override", "ThrowBomb", "ThrowBomb.playbackRate", base.duration, 0f); } } } public class ShootImpSpike : GhoulBaseSkillState { public static float BaseDuration = 0.7f; public static float BaseDelayPercent = 0.3f; private float duration; private float fireDelay; public string attackSoundString = ""; public static float selfForce = -18f; public static float forceMagnitude = 16f; public static float damageCoefficient = 2.5f; public static float projectileSpeed = 55f; public static float projectileSpeedPerProjectile = 20f; public static float upwardSpeed = 25f; public static GameObject projectilePrefab = GhoulAssets.impSpikePrefab; public static int projectileCount = 6; public static float projectileYawSpread = 16f; private bool hasFired; public override void OnEnter() { duration = BaseDuration / ((BaseState)this).attackSpeedStat; fireDelay = duration * BaseDelayPercent; ((BaseState)this).OnEnter(); ((EntityState)this).PlayAnimation("Gesture, Override", "ThrowBomb", "ThrowBomb.playbackRate", duration, 0f); } private void FireSpikeFan(Ray aimRay) { //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_0058: 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_0072: Unknown result type (might be due to invalid IL or missing references) Util.PlaySound(attackSoundString, ((EntityState)this).gameObject); if (((EntityState)this).isAuthority && !hasFired) { hasFired = true; Vector3 forward = ((EntityState)this).characterDirection.forward; if (Object.op_Implicit((Object)(object)((EntityState)this).characterMotor)) { ((EntityState)this).characterMotor.ApplyForce(forward * selfForce, true, false); } for (int i = 0; i < projectileCount; i++) { FireSpikeAuthority(aimRay, 0f, ((float)projectileCount / 2f - (float)i) * projectileYawSpread, projectileSpeed + projectileSpeedPerProjectile * (float)i); } } } private void FireSpikeAuthority(Ray aimRay, float bonusPitch, float bonusYaw, float speed) { //IL_0003: 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_0023: 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_0036: Unknown result type (might be due to invalid IL or missing references) Vector3 val = Util.ApplySpread(((Ray)(ref aimRay)).direction, 0f, 0f, 1f, 1f, bonusYaw, bonusPitch); ProjectileManager.instance.FireProjectileWithoutDamageType(projectilePrefab, ((Ray)(ref aimRay)).origin, Util.QuaternionSafeLookRotation(val), ((EntityState)this).gameObject, ((BaseState)this).damageStat * damageCoefficient, 0f, Util.CheckRoll(((BaseState)this).critStat, ((EntityState)this).characterBody.master), (DamageColorIndex)0, (GameObject)null, speed); } public override void FixedUpdate() { //IL_0051: 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_0020: Unknown result type (might be due to invalid IL or missing references) ((EntityState)this).FixedUpdate(); if (((EntityState)this).fixedAge >= fireDelay) { FireSpikeFan(((BaseState)this).GetAimRay()); } else { ((BaseCharacterController)((EntityState)this).characterMotor).Motor.ForceUnground(0.1f); ((EntityState)this).characterMotor.ApplyForce(((EntityState)this).transform.up * upwardSpeed, true, false); } if (((EntityState)this).fixedAge >= duration) { ((EntityState)this).outer.SetNextStateToMain(); } } public override InterruptPriority GetMinimumInterruptPriority() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (InterruptPriority)1; } } public class DashAttack : BaseSkillState { private GhoulWeaponComponent wep; public static float drainAmt = 0.07f; public static float damageCoefficient = 6.25f; public static float procCoefficient = 1f; public static float baseDuration = 0.7f; public static float firePercentTime = 0.6f; public static float force = 800f; public static float recoil = 0f; public static float range = 6f; public CharacterBody targetBody; private float duration; private float fireTime; private bool hasFired; private string muzzleString; private BulletAttack attack; public override void OnEnter() { wep = ((EntityState)this).GetComponent(); ((BaseState)this).OnEnter(); duration = baseDuration / ((BaseState)this).attackSpeedStat; fireTime = firePercentTime * duration; wep.graceDelay = duration; ((EntityState)this).PlayAnimation("FullBody, Override", "Feral_Dash_Attack", "Special.playbackRate", duration, 0f); if (NetworkServer.active) { ((EntityState)this).characterBody.AddTimedBuff(LegacyResourcesAPI.Load("BuffDefs/HiddenInvincibility"), duration); } } public override void OnExit() { ((EntityState)this).OnExit(); } public override void Update() { //IL_001f: 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_0034: 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_0041: 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_0063: Unknown result type (might be due to invalid IL or missing references) //IL_0068: Unknown result type (might be due to invalid IL or missing references) ((EntityState)this).Update(); if ((Object)(object)targetBody != (Object)null) { Vector3 val = targetBody.corePosition - ((EntityState)this).characterBody.corePosition; ((EntityState)this).characterBody.coreTransform.rotation = Quaternion.LookRotation(val); ((EntityState)this).characterDirection.forward = targetBody.corePosition - ((EntityState)this).characterBody.corePosition; } } public override void FixedUpdate() { //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) ((EntityState)this).FixedUpdate(); ((EntityState)this).characterMotor.velocity = Vector3.zero; if (((EntityState)this).fixedAge >= fireTime) { Fire(); } if (((EntityState)this).fixedAge >= duration && ((EntityState)this).isAuthority) { ((EntityState)this).outer.SetNextStateToMain(); } } private void Fire() { //IL_0069: 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_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_00d5: 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_00ee: Unknown result type (might be due to invalid IL or missing references) //IL_00f1: Unknown result type (might be due to invalid IL or missing references) //IL_00fc: 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_0104: 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_011b: Unknown result type (might be due to invalid IL or missing references) //IL_011d: Unknown result type (might be due to invalid IL or missing references) //IL_0122: Unknown result type (might be due to invalid IL or missing references) //IL_0123: Unknown result type (might be due to invalid IL or missing references) //IL_0125: Unknown result type (might be due to invalid IL or missing references) //IL_012a: Unknown result type (might be due to invalid IL or missing references) //IL_012c: 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_013d: 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_0149: 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_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_0175: Unknown result type (might be due to invalid IL or missing references) //IL_0181: Unknown result type (might be due to invalid IL or missing references) //IL_018d: Unknown result type (might be due to invalid IL or missing references) //IL_0194: Unknown result type (might be due to invalid IL or missing references) //IL_019a: 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_01ab: Unknown result type (might be due to invalid IL or missing references) //IL_01b6: Unknown result type (might be due to invalid IL or missing references) //IL_01bd: Unknown result type (might be due to invalid IL or missing references) //IL_01be: Unknown result type (might be due to invalid IL or missing references) //IL_01c3: Unknown result type (might be due to invalid IL or missing references) //IL_01c8: Unknown result type (might be due to invalid IL or missing references) //IL_01cf: Unknown result type (might be due to invalid IL or missing references) //IL_01d6: Unknown result type (might be due to invalid IL or missing references) //IL_01e1: Unknown result type (might be due to invalid IL or missing references) //IL_01ec: Unknown result type (might be due to invalid IL or missing references) //IL_01ee: Unknown result type (might be due to invalid IL or missing references) //IL_01f3: Unknown result type (might be due to invalid IL or missing references) //IL_0203: Expected O, but got Unknown //IL_0279: Unknown result type (might be due to invalid IL or missing references) if (hasFired) { return; } hasFired = true; ((EntityState)this).characterBody.AddSpreadBloom(1.5f); EffectManager.SimpleMuzzleFlash(FirePistol2.muzzleEffectPrefab, ((EntityState)this).gameObject, muzzleString, false); Util.PlaySound("Play_Ghoul_Attack_Impact_Heavy", ((EntityState)this).gameObject); if (((EntityState)this).isAuthority) { Ray val = default(Ray); ((Ray)(ref val))..ctor(((EntityState)this).transform.position, targetBody.transform.position - ((EntityState)this).transform.position); HealthComponent healthComponent = targetBody.healthComponent; if (!Object.op_Implicit((Object)(object)((Component)targetBody).gameObject.GetComponent())) { ((Component)targetBody).gameObject.AddComponent(); } DamageTypeCombo damageType = default(DamageTypeCombo); ((DamageTypeCombo)(ref damageType))..ctor(DamageTypeCombo.op_Implicit((DamageType)524292), (DamageTypeExtended)0, (DamageSource)8); attack = new BulletAttack { bulletCount = 1u, aimVector = ((Ray)(ref val)).direction, origin = ((Ray)(ref val)).origin, damage = damageCoefficient * ((BaseState)this).damageStat, damageColorIndex = (DamageColorIndex)0, damageType = damageType, falloffModel = (FalloffModel)0, maxDistance = range, force = force, hitMask = CommonMasks.bullet, minSpread = 0f, maxSpread = 0f, isCrit = ((BaseState)this).RollCrit(), owner = ((EntityState)this).gameObject, muzzleName = muzzleString, smartCollision = true, procChainMask = default(ProcChainMask), procCoefficient = procCoefficient, radius = 0.75f, sniper = false, stopperMask = CommonMasks.bullet, weapon = null, tracerEffectPrefab = null, spreadPitchScale = 1f, spreadYawScale = 1f, queryTriggerInteraction = (QueryTriggerInteraction)0, hitEffectPrefab = GhoulAssets.bloodSplatEffect }; attack.Fire(); if (((EntityState)this).skillLocator.FindSkillByFamilyName("VcrGhoulBodyMiscFamily").baseSkill.skillName == "GhoulMisc") { wep.rageValue -= wep.rageThreshold * (0.15f - drainAmt); } NetworkIdentity component = ((EntityState)this).GetComponent(); if (Object.op_Implicit((Object)(object)component)) { NetMessageExtensions.Send((INetMessage)(object)new Helpers.SyncHeal(component.netId, 7), (NetworkDestination)2); } } } public override InterruptPriority GetMinimumInterruptPriority() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (InterruptPriority)2; } } public class DashStart : BaseSkillState { public static float initialDashSpeed = 14f; public static float finalDashSpeed = 4f; public static float baseDuration = 0.35f; public GameObject dustInstance; private float duration; private float moveSpeed; private Vector3 moveDir; private OverlapAttack overlapAttack; private BullseyeSearch bullseyeSearch; private List overlapAttackHits = new List(); public override void OnEnter() { //IL_004e: Unknown result type (might be due to invalid IL or missing references) //IL_0053: Unknown result type (might be due to invalid IL or missing references) //IL_0056: Unknown result type (might be due to invalid IL or missing references) //IL_005b: Unknown result type (might be due to invalid IL or missing references) //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_006b: Expected O, but got Unknown //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_00bd: 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_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_00d5: 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_00ec: 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_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) //IL_0105: Expected O, but got Unknown //IL_011b: 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) ((BaseState)this).OnEnter(); duration = baseDuration; ((EntityState)this).PlayAnimation("FullBody, Override", "Feral_Dash", "Special.PlaybackRate", duration, 0f); Util.PlaySound("Play_Ghoul_Dash_Woosh", ((EntityState)this).gameObject); RecalculateMoveSpeed(); Ray aimRay = ((BaseState)this).GetAimRay(); moveDir = ((Ray)(ref aimRay)).direction; bullseyeSearch = new BullseyeSearch(); HitBoxGroup hitBoxGroup = null; Transform modelTransform = ((EntityState)this).GetModelTransform(); if (Object.op_Implicit((Object)(object)modelTransform)) { hitBoxGroup = Array.Find(((Component)modelTransform).GetComponents(), (HitBoxGroup hitboxGroup) => hitboxGroup.groupName == "FrenzyGroup"); } overlapAttack = new OverlapAttack { attacker = ((EntityState)this).gameObject, inflictor = ((EntityState)this).gameObject, teamIndex = ((BaseState)this).GetTeam(), damage = 0f, isCrit = ((BaseState)this).RollCrit(), hitBoxGroup = hitBoxGroup, damageType = DamageTypeCombo.op_Implicit((DamageType)32) }; dustInstance = Object.Instantiate(GhoulAssets.dashEffect, ((EntityState)this).GetModelChildLocator().FindChild("DashDust").position, ((EntityState)this).GetModelChildLocator().FindChild("DashDust").rotation); } public override void FixedUpdate() { //IL_0016: Unknown result type (might be due to invalid IL or missing references) //IL_0021: Unknown result type (might be due to invalid IL or missing references) //IL_0026: Unknown result type (might be due to invalid IL or missing references) //IL_0044: 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) ((EntityState)this).FixedUpdate(); RecalculateMoveSpeed(); ((EntityState)this).characterMotor.velocity = moveDir * moveSpeed; CharacterBody val = FireOverlap(); if ((Object)(object)val != (Object)null) { ((EntityState)this).characterMotor.velocity = Vector3.zero; ((EntityState)this).outer.SetNextState((EntityState)(object)new DashAttack { targetBody = val }); } if (((EntityState)this).fixedAge >= duration) { ((EntityState)this).outer.SetNextStateToMain(); } } private void RecalculateMoveSpeed() { moveSpeed = Mathf.Lerp(initialDashSpeed, finalDashSpeed, ((EntityState)this).fixedAge / duration) * ((BaseState)this).moveSpeedStat; } public override void OnExit() { ((EntityState)this).GetModelAnimator().SetBool("RotateTendrils", false); ((EntityState)this).OnExit(); } private CharacterBody FireOverlap() { overlapAttackHits.Clear(); if (overlapAttack.Fire(overlapAttackHits) && overlapAttackHits.Count > 0) { return overlapAttackHits[0].healthComponent?.body; } return null; } } public class SlamFall : BaseCharacterMain { public static float fallSpeed = 35f; public static float exitVerticalVelocity = 3f; public static float exitSpeedCoefficient = 0.1f; public static float minimumDuration = 0.1f; public static float airControl = 0.2f; public static float initialVerticalVelocity = 6f; public static float blastRadius = 16f; public static float blastProcCoefficient = 1f; public static float blastForce = 40f; public static Vector3 blastBonusForce = Vector3.down; public GameObject slamExplosion; public GameObject slamDecal; private float previousAirControl; private bool slamNextFrame; public override void OnEnter() { //IL_0036: Unknown result type (might be due to invalid IL or missing references) //IL_0040: Expected O, but got Unknown ((BaseCharacterMain)this).OnEnter(); ((BaseCharacterController)((EntityState)this).characterMotor).Motor.ForceUnground(0.1f); if (((EntityState)this).isAuthority) { ((EntityState)this).characterMotor.onMovementHit += new MovementHitDelegate(OnMovementHit); ((EntityState)this).characterMotor.velocity.y = initialVerticalVelocity; } ((EntityState)this).PlayAnimation("FullBody, Override", "SlamStart"); previousAirControl = ((EntityState)this).characterMotor.airControl; ((EntityState)this).characterMotor.airControl = airControl; } public override void FixedUpdate() { //IL_0032: 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_00a9: Unknown result type (might be due to invalid IL or missing references) ((BaseCharacterMain)this).FixedUpdate(); if (((EntityState)this).isAuthority && Object.op_Implicit((Object)(object)((EntityState)this).characterMotor)) { ((EntityState)this).characterMotor.moveDirection = ((EntityState)this).inputBank.moveVector; ((EntityState)this).characterDirection.moveVector = ((EntityState)this).characterMotor.moveDirection; ((EntityState)this).characterMotor.velocity.y -= fallSpeed * ((EntityState)this).GetDeltaTime(); if (((EntityState)this).fixedAge >= minimumDuration && (slamNextFrame || ((BaseCharacterController)((EntityState)this).characterMotor).Motor.GroundingStatus.IsStableOnGround)) { DetonateAuthority(); ((EntityState)this).outer.SetNextStateToMain(); } } } public override void OnExit() { //IL_001c: Unknown result type (might be due to invalid IL or missing references) //IL_0026: Expected O, but got Unknown //IL_0044: Unknown result type (might be due to invalid IL or missing references) //IL_004e: Unknown result type (might be due to invalid IL or missing references) //IL_0053: Unknown result type (might be due to invalid IL or missing references) //IL_007f: Unknown result type (might be due to invalid IL or missing references) if (((EntityState)this).isAuthority) { ((EntityState)this).characterMotor.onMovementHit -= new MovementHitDelegate(OnMovementHit); ((BaseCharacterController)((EntityState)this).characterMotor).Motor.ForceUnground(0.1f); CharacterMotor characterMotor = ((EntityState)this).characterMotor; characterMotor.velocity *= exitSpeedCoefficient; ((EntityState)this).characterMotor.velocity.y = exitVerticalVelocity; NetworkIdentity component = ((EntityState)this).GetComponent(); if (Object.op_Implicit((Object)(object)component)) { NetMessageExtensions.Send((INetMessage)(object)new Helpers.SyncHeal(component.netId, 15), (NetworkDestination)2); } } ((EntityState)this).characterMotor.airControl = previousAirControl; ((BaseCharacterMain)this).OnExit(); } private void OnMovementHit(ref MovementHitInfo movementHitInfo) { slamNextFrame = true; ((EntityState)this).PlayCrossfade("FullBody, Override", "SlamAttack", 0.35f); Util.PlaySound("Play_Ghoul_Slam_SFX", ((EntityState)this).gameObject); } protected Result DetonateAuthority() { //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) //IL_0028: 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_0051: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Expected O, but got Unknown //IL_0081: 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_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_00a6: 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_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_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_00e7: 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_00f2: 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) Vector3 footPosition = ((EntityState)this).characterBody.footPosition; slamExplosion = Object.Instantiate(GhoulAssets.bombExplosionEffect); slamExplosion.transform.position = footPosition; slamDecal = Object.Instantiate(GhoulAssets.slamDecal); slamDecal.transform.position = footPosition; BlastAttack val = new BlastAttack(); val.attacker = ((EntityState)this).gameObject; val.baseDamage = ((BaseState)this).damageStat * 12f; val.baseForce = blastForce; val.bonusForce = blastBonusForce; val.crit = ((BaseState)this).RollCrit(); val.damageType = DamageTypeCombo.op_Implicit((DamageType)32); val.falloffModel = (FalloffModel)0; val.procCoefficient = blastProcCoefficient; val.radius = blastRadius; val.position = footPosition; val.attackerFiltering = (AttackerFiltering)2; val.teamIndex = ((EntityState)this).teamComponent.teamIndex; val.damageType.damageSource = (DamageSource)8; return val.Fire(); } } public class EnragedGrab : GhoulClingState { public float delay = 0.5f; public float baseDuration = 1f; private OverlapAttack overlapAttack; private BullseyeSearch bullseyeSearch; private List overlapAttackHits = new List(); private bool hasAttacked; public override void OnEnter() { //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_001f: Expected O, but got Unknown //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) //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_009b: 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_00af: Unknown result type (might be due to invalid IL or missing references) //IL_00b4: Unknown result type (might be due to invalid IL or missing references) //IL_00be: Expected O, but got Unknown duration = baseDuration + delay; bullseyeSearch = new BullseyeSearch(); HitBoxGroup hitBoxGroup = null; Transform modelTransform = ((EntityState)this).GetModelTransform(); if (Object.op_Implicit((Object)(object)modelTransform)) { hitBoxGroup = Array.Find(((Component)modelTransform).GetComponents(), (HitBoxGroup hitboxGroup) => hitboxGroup.groupName == "ClingGroup"); } overlapAttack = new OverlapAttack { attacker = ((EntityState)this).gameObject, inflictor = ((EntityState)this).gameObject, teamIndex = ((BaseState)this).GetTeam(), damage = 5f * ((BaseState)this).damageStat, isCrit = ((BaseState)this).RollCrit(), hitBoxGroup = hitBoxGroup, damageType = DamageTypeCombo.GenericSecondary }; Log.Debug("In Grab State"); base.OnEnter(); } public override void FixedUpdate() { base.FixedUpdate(); if (((EntityState)this).fixedAge > delay && !hasAttacked) { hasAttacked = true; overlapAttack.Fire((List)null); } } private CharacterBody FireOverlap() { //IL_0048: Unknown result type (might be due to invalid IL or missing references) overlapAttackHits.Clear(); if (overlapAttack.Fire(overlapAttackHits) && overlapAttackHits.Count > 0) { NetworkIdentity component = ((EntityState)this).GetComponent(); if (Object.op_Implicit((Object)(object)component)) { NetMessageExtensions.Send((INetMessage)(object)new Helpers.SyncHeal(component.netId, 6), (NetworkDestination)2); } return overlapAttackHits[0].healthComponent?.body; } return null; } public override void OnExit() { ((EntityState)this).GetModelAnimator().SetBool("RotateTendrils", false); base.OnExit(); } } public class EnragedGrapple : BaseSkillState { public static float initialPullSpeed = 6f; public static float finalPullSpeed = 12f; public static float minDistance = 2.75f; public float adjustedDistance; private float pullSpeed; private Vector3 travelDir; private float distance; private float angle; private float clampedAngle; private OverlapAttack overlapAttack; public GameObject target { get; set; } public override void OnEnter() { //IL_00f1: Unknown result type (might be due to invalid IL or missing references) //IL_00f6: Unknown result type (might be due to invalid IL or missing references) //IL_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_0110: 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_011a: Unknown result type (might be due to invalid IL or missing references) //IL_0125: Unknown result type (might be due to invalid IL or missing references) //IL_0137: 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_014a: 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_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) //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_017a: Expected O, but got Unknown //IL_0196: 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) ((BaseState)this).OnEnter(); if (!((EntityState)this).isAuthority) { return; } ((BaseCharacterController)((EntityState)this).characterMotor).Motor.ForceUnground(0.1f); RecalDist(); ((EntityState)this).GetModelAnimator().SetBool("RotateTendrils", true); ((EntityState)this).GetModelAnimator().SetBool("isGrappling", true); ((EntityState)this).PlayAnimation("Fullbody, Override", "Grappling"); ((EntityState)this).PlayAnimation("TentaclePitch, Additive", "TentaclePitch"); ((EntityState)this).PlayAnimation("TentaclesDown, Override", "GrapplingTentacles"); ((EntityState)this).PlayAnimation("TentaclesUp, Override", "Feral_Binge_Reworked"); RecalculatePullSpeed(); RecalculateTravelDirection(); TrnasitionDistance(); HitBoxGroup hitBoxGroup = null; Transform modelTransform = ((EntityState)this).GetModelTransform(); if (Object.op_Implicit((Object)(object)modelTransform)) { hitBoxGroup = Array.Find(((Component)modelTransform).GetComponents(), (HitBoxGroup hitboxGroup) => hitboxGroup.groupName == "GrappleGroup"); } overlapAttack = new OverlapAttack { attacker = ((EntityState)this).gameObject, inflictor = ((EntityState)this).gameObject, teamIndex = ((BaseState)this).GetTeam(), procCoefficient = 3f, damage = 1.2f * ((BaseState)this).damageStat, isCrit = ((BaseState)this).RollCrit(), hitBoxGroup = hitBoxGroup, hitEffectPrefab = GhoulAssets.swordHitImpactEffect, impactSound = GhoulAssets.swordHitSoundEvent.index, damageType = DamageTypeCombo.op_Implicit((DamageType)1024) }; if (overlapAttack.isCrit) { overlapAttack.damageType = DamageTypeCombo.op_Implicit((DamageType)134217728); } } public override void OnExit() { ((EntityState)this).GetModelAnimator().SetBool("RotateTendrils", false); ((EntityState)this).GetModelAnimator().SetBool("isGrappling", false); ((EntityState)this).GetModelAnimator().SetFloat("aimPitchCached", 0.5f); ((EntityState)this).OnExit(); } public override void FixedUpdate() { //IL_0057: 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_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_008d: 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(); RecalculatePullSpeed(); RecalculateTravelDirection(); RecalDist(); overlapAttack.Fire((List)null); if (Object.op_Implicit((Object)(object)((EntityState)this).characterDirection)) { ((EntityState)this).characterDirection.forward = travelDir; } ((EntityState)this).characterMotor.velocity = ((Vector3)(ref travelDir)).normalized * pullSpeed; if (Vector3.Distance(target.GetComponent().ClosestPoint(((EntityState)this).transform.position), ((EntityState)this).transform.position) <= minDistance) { ((EntityState)this).outer.SetNextStateToMain(); } } private void RecalDist() { //IL_0008: 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_0023: 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_0049: 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) distance = Vector3.Distance(((EntityState)this).characterBody.corePosition, target.GetComponent().ClosestPoint(((EntityState)this).transform.position)); angle = target.GetComponent().ClosestPoint(((EntityState)this).transform.position).y - ((EntityState)this).characterBody.corePosition.y; clampedAngle = angle / 58f / 2f + 0.5f; ((EntityState)this).GetModelAnimator().SetFloat("aimPitchCached", clampedAngle); ((EntityState)this).GetModelAnimator().SetFloat("TendrilDistance", distance); } private void RecalculateTravelDirection() { //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_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) //IL_002d: Unknown result type (might be due to invalid IL or missing references) travelDir = target.GetComponent().ClosestPoint(((EntityState)this).transform.position) - ((EntityState)this).transform.position; } private void RecalculatePullSpeed() { pullSpeed = ((BaseState)this).moveSpeedStat * Mathf.Lerp(initialPullSpeed, finalPullSpeed, ((EntityState)this).fixedAge); } private void TrnasitionDistance() { } public override InterruptPriority GetMinimumInterruptPriority() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (InterruptPriority)2; } } public class HoldGrapple : BaseSkillState { public static float baseDuration = 3f; public static float delay = 0.2f; public static float initialPullSpeed = 3.5f; public static float finalPullSpeed = 4.75f; public static float initialForwardSpeed = 4f; public static float finalForwardSpeed = 0f; public static float moveSpeedCoefficient = 5f; public static float enragedSpeedMulti = 1.05f; internal bool enraged; public static float minDistance = 3f; private float distance; private float angle; private float clampedAngle; private float speedCoefficient = 1f; private float pullSpeed; private float forwardSpeed; private float duration; private Vector3 travelDir; private Vector3 forwardDir; public static float dodgeFOV = DodgeState.dodgeFOV; private float clampedSpeed; private uint loopSFX; private bool sfxStarted; private OverlapAttack overlapAttack; public Vector3 latchPos { get; set; } public override void OnEnter() { //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_016a: 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_0178: 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_018d: 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_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_01be: Unknown result type (might be due to invalid IL or missing references) //IL_01c4: 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_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 //IL_01ff: Unknown result type (might be due to invalid IL or missing references) //IL_0204: Unknown result type (might be due to invalid IL or missing references) ((BaseState)this).OnEnter(); if (!((EntityState)this).isAuthority) { return; } ((BaseCharacterController)((EntityState)this).characterMotor).Motor.ForceUnground(0.1f); Util.PlaySound("Play_Ghoul_Tendril_Grow", ((EntityState)this).gameObject); duration = baseDuration; RecalculatePullSpeed(); RecalculateReelDirection(); RecalculateForwardDirection(); RecalculateForwardSpeed(); RecalDist(); ((EntityState)this).GetModelAnimator().SetBool("RotateTendrils", true); ((EntityState)this).GetModelAnimator().SetBool("isGrappling", true); ((EntityState)this).PlayAnimation("Fullbody, Override", "Grappling"); ((EntityState)this).PlayAnimation("TentaclePitch, Additive", "TentaclePitch"); ((EntityState)this).PlayAnimation("TentaclesDown, Override", "GrapplingTentacles"); float num = ((BaseState)this).moveSpeedStat / moveSpeedCoefficient; if (((BaseState)this).moveSpeedStat <= 10.2f) { num = 0f; } clampedSpeed = 10.15f + num; if (enraged) { speedCoefficient = enragedSpeedMulti; HitBoxGroup hitBoxGroup = null; Transform modelTransform = ((EntityState)this).GetModelTransform(); if (Object.op_Implicit((Object)(object)modelTransform)) { hitBoxGroup = Array.Find(((Component)modelTransform).GetComponents(), (HitBoxGroup hitboxGroup) => hitboxGroup.groupName == "GrappleGroup"); } overlapAttack = new OverlapAttack { attacker = ((EntityState)this).gameObject, inflictor = ((EntityState)this).gameObject, teamIndex = ((BaseState)this).GetTeam(), procCoefficient = 3f, damage = 1.2f * ((BaseState)this).damageStat, isCrit = ((BaseState)this).RollCrit(), hitBoxGroup = hitBoxGroup, hitEffectPrefab = GhoulAssets.swordHitImpactEffect, impactSound = GhoulAssets.swordHitSoundEvent.index, damageType = DamageTypeCombo.op_Implicit((DamageType)1024) }; if (overlapAttack.isCrit) { overlapAttack.damageType = DamageTypeCombo.op_Implicit((DamageType)134217728); } } else { speedCoefficient = 1f; } } public override void OnExit() { if (Object.op_Implicit((Object)(object)((EntityState)this).cameraTargetParams)) { ((EntityState)this).cameraTargetParams.fovOverride = -1f; } ((EntityState)this).GetModelAnimator().SetBool("RotateTendrils", false); ((EntityState)this).GetModelAnimator().SetBool("isGrappling", false); ((EntityState)this).GetModelAnimator().SetFloat("aimPitchCached", 0.5f); AkSoundEngine.StopPlayingID(loopSFX); ((EntityState)this).OnExit(); } public override void FixedUpdate() { //IL_0090: 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_00c6: 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_00d7: Unknown result type (might be due to invalid IL or missing references) //IL_00dc: Unknown result type (might be due to invalid IL or missing references) //IL_00e1: Unknown result type (might be due to invalid IL or missing references) if (!((EntityState)this).isAuthority) { return; } ((EntityState)this).FixedUpdate(); RecalculateReelDirection(); RecalculateForwardDirection(); RecalDist(); if (enraged) { overlapAttack.Fire((List)null); } if (Object.op_Implicit((Object)(object)((EntityState)this).cameraTargetParams)) { ((EntityState)this).cameraTargetParams.fovOverride = Mathf.Lerp(dodgeFOV, 60f, ((EntityState)this).fixedAge / duration); } if (Object.op_Implicit((Object)(object)((EntityState)this).characterDirection)) { ((EntityState)this).characterDirection.forward = travelDir; } if (((EntityState)this).fixedAge > delay) { ((EntityState)this).characterMotor.velocity = ((Vector3)(ref travelDir)).normalized * pullSpeed + forwardDir * forwardSpeed; RecalculateForwardSpeed(); RecalculatePullSpeed(); if (!sfxStarted) { sfxStarted = true; loopSFX = Util.PlaySound("Play_Ghoul_Grapple_Woosh_Loop", ((EntityState)this).gameObject); } } if (!ShouldKeepChargingAuthority() && ((EntityState)this).fixedAge >= 0.25f + delay) { ((EntityState)this).outer.SetNextStateToMain(); } else if (distance <= minDistance) { ((EntityState)this).outer.SetNextStateToMain(); } else if (((EntityState)this).fixedAge >= duration) { ((EntityState)this).outer.SetNextStateToMain(); } } private void RecalculateReelDirection() { //IL_0003: 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_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) travelDir = latchPos - ((EntityState)this).transform.position; } private void RecalculateForwardDirection() { //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_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_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) Ray aimRay = ((BaseState)this).GetAimRay(); Vector3 direction = ((Ray)(ref aimRay)).direction; forwardDir = ((Vector3)(ref direction)).normalized; } private void RecalculatePullSpeed() { pullSpeed = clampedSpeed * speedCoefficient * Mathf.Lerp(initialPullSpeed, finalPullSpeed, ((EntityState)this).fixedAge / duration); } private void RecalculateForwardSpeed() { forwardSpeed = clampedSpeed * speedCoefficient * Mathf.Lerp(initialForwardSpeed, finalForwardSpeed, ((EntityState)this).fixedAge / duration); } private void RecalDist() { //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_001f: 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) distance = Vector3.Distance(((EntityState)this).characterBody.corePosition, latchPos); angle = latchPos.y - ((EntityState)this).characterBody.corePosition.y; clampedAngle = angle / 58f / 2f + 0.5f; ((EntityState)this).GetModelAnimator().SetFloat("aimPitchCached", clampedAngle); ((EntityState)this).GetModelAnimator().SetFloat("TendrilDistance", distance); } protected virtual bool ShouldKeepChargingAuthority() { return ((EntityState)this).inputBank.skill2.down; } 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; } 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) ((BaseSkillState)this).OnSerialize(writer); writer.Write(travelDir); writer.Write(forwardDir); } 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) ((BaseSkillState)this).OnDeserialize(reader); travelDir = reader.ReadVector3(); forwardDir = reader.ReadVector3(); } } public class PreTentacleGrapple : BaseSkillState { public static float minHold = 0.195f; public static float range = 58f; private Vector3 validLatchPos; private GameObject enrageTarget; private GhoulWeaponComponent wep; public override void OnEnter() { //IL_002d: 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_0038: 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_004b: 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_008f: 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_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_00ff: Unknown result type (might be due to invalid IL or missing references) //IL_0104: 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) ((BaseState)this).OnEnter(); wep = ((EntityState)this).GetComponent(); ((EntityState)this).characterBody.SetAimTimer(2f); Vector3 corePosition = ((EntityState)this).characterBody.corePosition; Ray aimRay = ((BaseState)this).GetAimRay(); Ray val = default(Ray); ((Ray)(ref val))..ctor(corePosition, ((Ray)(ref aimRay)).direction); RaycastHit val2 = default(RaycastHit); if (Util.CharacterSpherecast(((EntityState)this).gameObject, val, 0.35f, ref val2, range, ((LayerIndex)(ref LayerIndex.world)).mask, (QueryTriggerInteraction)2)) { validLatchPos = ((RaycastHit)(ref val2)).collider.ClosestPointOnBounds(((RaycastHit)(ref val2)).point); } RaycastHit val3 = default(RaycastHit); if (Util.CharacterSpherecast(((EntityState)this).gameObject, val, 1.25f, ref val3, range, ((LayerIndex)(ref LayerIndex.enemyBody)).mask, (QueryTriggerInteraction)2) && Object.op_Implicit((Object)(object)((Component)((RaycastHit)(ref val3)).transform).GetComponent()) && !((Component)((RaycastHit)(ref val3)).transform).GetComponent().isBoss) { enrageTarget = ((Component)((RaycastHit)(ref val3)).collider).gameObject; validLatchPos = ((RaycastHit)(ref val3)).point; if (wep.isEnraged) { ((EntityState)this).outer.SetNextState((EntityState)(object)new EnragedGrapple { target = enrageTarget }); ((EntityState)this).skillLocator.secondary.DeductStock(1); } else { ((EntityState)this).outer.SetNextState((EntityState)(object)new HoldGrapple { latchPos = enrageTarget.transform.position, enraged = wep.isEnraged }); ((EntityState)this).skillLocator.secondary.DeductStock(1); } } } public override void FixedUpdate() { //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_0058: 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) ((EntityState)this).FixedUpdate(); if (!((EntityState)this).isAuthority) { return; } if (validLatchPos != Vector3.zero) { if (!ShouldKeepChargingAuthority() && ((EntityState)this).fixedAge < minHold) { ((EntityState)this).outer.SetNextState((EntityState)(object)new TapGrapple { latchPos = validLatchPos, enraged = wep.isEnraged }); ((EntityState)this).skillLocator.secondary.DeductStock(1); } else if (((EntityState)this).fixedAge >= minHold) { ((EntityState)this).outer.SetNextState((EntityState)(object)new HoldGrapple { latchPos = validLatchPos, enraged = wep.isEnraged }); ((EntityState)this).skillLocator.secondary.DeductStock(1); } } else { ((EntityState)this).outer.SetNextStateToMain(); } } protected virtual bool ShouldKeepChargingAuthority() { return ((BaseSkillState)this).IsKeyDownAuthority(); } public override InterruptPriority GetMinimumInterruptPriority() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0005: Unknown result type (might be due to invalid IL or missing references) return (InterruptPriority)2; } } public class TapGrapple : BaseSkillState { public static float initialPullSpeed = 9f; public static float finalPullSpeed = 6f; public static float minDistance = 3f; public static float moveSpeedCoefficient = 4.5f; public static float enragedSpeedMulti = 1.15f; private float pullSpeed; private Vector3 travelDir; private float clampedSpeed; private float speedCoefficient = 1f; internal bool enraged; private float distance; private float angle; private float clampedAngle; private OverlapAttack overlapAttack; public Vector3 latchPos { get; set; } public override void OnEnter() { //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_014c: 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_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_0181: Unknown result type (might be due to invalid IL or missing references) //IL_018d: Unknown result type (might be due to invalid IL or missing references) //IL_0194: Unknown result type (might be due to invalid IL or missing references) //IL_019f: 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_01aa: 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_01ba: Unknown result type (might be due to invalid IL or missing references) //IL_01c4: Expected O, but got Unknown //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) ((BaseState)this).OnEnter(); if (!((EntityState)this).isAuthority) { return; } ((BaseCharacterController)((EntityState)this).characterMotor).Motor.ForceUnground(0.1f); RecalculatePullSpeed(); RecalculateTravelDirection(); RecalDist(); ((EntityState)this).GetModelAnimator().SetBool("RotateTendrils", true); ((EntityState)this).GetModelAnimator().SetBool("isGrappling", true); ((EntityState)this).PlayAnimation("Fullbody, Override", "Grappling"); ((EntityState)this).PlayAnimation("TentaclePitch, Additive", "TentaclePitch"); ((EntityState)this).PlayAnimation("TentaclesDown, Override", "GrapplingTentacles"); float num = ((BaseState)this).moveSpeedStat / moveSpeedCoefficient; Util.PlaySound("Play_Ghoul_Tendril_Grow", ((EntityState)this).gameObject); if (((BaseState)this).moveSpeedStat <= 10.2f) { num = 0f; } clampedSpeed = 8.1f + num; if (enraged) { speedCoefficient = enragedSpeedMulti; } HitBoxGroup hitBoxGroup = null; Transform modelTransform = ((EntityState)this).GetModelTransform(); if (Object.op_Implicit((Object)(object)modelTransform)) { hitBoxGroup = Array.Find(((Component)modelTransform).GetComponents(), (HitBoxGroup hitboxGroup) => hitboxGroup.groupName == "GrappleGroup"); } overlapAttack = new OverlapAttack { attacker = ((EntityState)this).gameObject, inflictor = ((EntityState)this).gameObject, teamIndex = ((BaseState)this).GetTeam(), procCoefficient = 3f, damage = 1.2f * ((BaseState)this).damageStat, isCrit = ((BaseState)this).RollCrit(), hitBoxGroup = hitBoxGroup, hitEffectPrefab = GhoulAssets.swordHitImpactEffect, impactSound = GhoulAssets.swordHitSoundEvent.index, damageType = DamageTypeCombo.op_Implicit((DamageType)1024) }; if (overlapAttack.isCrit) { overlapAttack.damageType = DamageTypeCombo.op_Implicit((DamageType)134217728); } } public override void OnExit() { ((EntityState)this).GetModelAnimator().SetBool("RotateTendrils", false); ((EntityState)this).GetModelAnimator().SetBool("isGrappling", false); ((EntityState)this).GetModelAnimator().SetFloat("aimPitchCached", 0.5f); ((EntityState)this).OnExit(); } public override void FixedUpdate() { //IL_0041: 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_0081: 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) ((EntityState)this).FixedUpdate(); if (((EntityState)this).isAuthority) { RecalculatePullSpeed(); RecalculateTravelDirection(); RecalDist(); if (Object.op_Implicit((Object)(object)((EntityState)this).characterDirection)) { ((EntityState)this).characterDirection.forward = travelDir; } if (enraged) { overlapAttack.Fire((List)null); } ((EntityState)this).characterMotor.velocity = ((Vector3)(ref travelDir)).normalized * pullSpeed; if (Vector3.Distance(latchPos, ((EntityState)this).transform.position) <= minDistance) { ((EntityState)this).outer.SetNextStateToMain(); } } } public override void Update() { ((EntityState)this).Update(); RecalDist(); } private void RecalculateTravelDirection() { //IL_0003: 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_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) travelDir = latchPos - ((EntityState)this).transform.position; } private void RecalculatePullSpeed() { pullSpeed = clampedSpeed * speedCoefficient * Mathf.Lerp(initialPullSpeed, finalPullSpeed, ((EntityState)this).fixedAge); } private void RecalDist() { //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_001f: 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) distance = Vector3.Distance(((EntityState)this).characterBody.corePosition, latchPos); angle = latchPos.y - ((EntityState)this).characterBody.corePosition.y; clampedAngle = angle / 58f / 2f + 0.5f; ((EntityState)this).GetModelAnimator().SetFloat("aimPitchCached", clampedAngle); ((EntityState)this).GetModelAnimator().SetFloat("TendrilDistance", distance); } 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; } public override void OnSerialize(NetworkWriter writer) { //IL_000b: Unknown result type (might be due to invalid IL or missing references) ((BaseSkillState)this).OnSerialize(writer); writer.Write(travelDir); } 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) ((BaseSkillState)this).OnDeserialize(reader); travelDir = reader.ReadVector3(); } } public class TentacleStrike : BaseMeleeAttack { public int overrideIndex; private float dist; private GameObject terrainDust; private float hitSparkDelay; private bool hasSpawnedSpark; private RaycastHit hitInfo; public override void OnEnter() { //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_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_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_0111: Unknown result type (might be due to invalid IL or missing references) //IL_0126: Unknown result type (might be due to invalid IL or missing references) hitboxGroupName = "StabGroup"; damageType = DamageTypeCombo.GenericPrimary; damageCoefficient = 2.6f; procCoefficient = 1f; pushForce = 300f; bonusForce = Vector3.zero; baseDuration = 0.81f; attackStartPercentTime = 0.3f; attackEndPercentTime = 0.7f; earlyExitPercentTime = 0.6f; hitStopDuration = 0.012f; attackRecoil = 0.5f; hitHopVelocity = 4f; swingSoundString = "Play_Ghoul_Attack_Swing"; hitSoundString = ""; muzzleString = ((swingIndex % 2 == 0) ? "TentacleStabL" : "TentacleStabR"); playbackRateParam = "Stab.playbackRate"; swingEffectPrefab = GhoulAssets.tendrilThrustEffect; hitEffectPrefab = GhoulAssets.swordHitImpactEffect; impactSound = GhoulAssets.swordHitSoundEvent.index; hitSparkDelay = duration * 0.8f; dist = 25f; if (Physics.Raycast(((BaseState)this).GetAimRay(), ref hitInfo, 25f, LayerMask.op_Implicit(((LayerIndex)(ref LayerIndex.world)).mask), (QueryTriggerInteraction)2)) { dist = ((RaycastHit)(ref hitInfo)).distance; } float num = Mathf.Clamp(dist / 25f, 0.7f, 0.8f); hitSparkDelay = duration * num; ((EntityState)this).GetModelAnimator().SetFloat("TendrilDistance", dist); ((EntityState)this).GetModelAnimator().SetFloat("aimPitchCached", ((EntityState)this).GetModelAnimator().GetFloat("aimPitchCycle")); ((EntityState)this).GetModelAnimator().SetBool("RotateTendrils", true); base.OnEnter(); } public override void FixedUpdate() { //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_0085: 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_009f: Unknown result type (might be due to invalid IL or missing references) base.FixedUpdate(); ((EntityState)this).GetModelAnimator().SetFloat("aimPitchCached", ((EntityState)this).GetModelAnimator().GetFloat("aimPitchCycle")); if (!hasSpawnedSpark && dist < 25f && ((EntityState)this).fixedAge >= hitSparkDelay) { hasSpawnedSpark = true; terrainDust = Object.Instantiate(GhoulAssets.tentacleTerrainImpact, ((RaycastHit)(ref hitInfo)).point, Quaternion.Euler(((RaycastHit)(ref hitInfo)).normal.x, ((RaycastHit)(ref hitInfo)).normal.y, ((RaycastHit)(ref hitInfo)).normal.z)); Util.PlaySound("Play_Ghoul_Attack_Terrain", terrainDust); } } protected override void PlayAttackAnimation() { ((EntityState)this).PlayCrossfade("TentaclePitch, Additive", "TentaclePitch", (string)null, duration, 0.25f); ((EntityState)this).PlayCrossfade("TentaclesUp, Override", "Stab" + (1 + swingIndex), playbackRateParam, duration, 0.1f * duration); ((EntityState)this).PlayCrossfade("TentaclesDown, Override", "TentacleDownShrunk", playbackRateParam, duration, 0.1f * duration); } protected override void PlaySwingEffect() { base.PlaySwingEffect(); } protected override void OnHitEnemyAuthority() { //IL_001a: Unknown result type (might be due to invalid IL or missing references) base.OnHitEnemyAuthority(); NetworkIdentity component = ((EntityState)this).GetComponent(); if (Object.op_Implicit((Object)(object)component)) { NetMessageExtensions.Send((INetMessage)(object)new Helpers.SyncHeal(component.netId, 3), (NetworkDestination)2); } } public override void OnExit() { ((EntityState)this).GetModelAnimator().SetBool("RotateTendrils", false); ((EntityState)this).GetModelAnimator().SetFloat("aimPitchCached", 0.5f); if ((Object)(object)terrainDust != (Object)null) { Object.Destroy((Object)(object)terrainDust); } base.OnExit(); } } public class TentacleSweep : BaseMeleeAttack { public override void OnEnter() { //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_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_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) hitboxGroupName = "SweepGroup"; damageType = DamageTypeCombo.GenericPrimary; damageCoefficient = 3.6f; procCoefficient = 1f; pushForce = 300f; bonusForce = Vector3.zero; baseDuration = 1.12f; attackStartPercentTime = 0.3f; attackEndPercentTime = 0.4f; earlyExitPercentTime = 0.6f; hitStopDuration = 0.012f; attackRecoil = 0.5f; hitHopVelocity = 4f; swingSoundString = "Play_Ghoul_Attack_Sweep_Swing"; hitSoundString = ""; playbackRateParam = "Stab.playbackRate"; swingEffectPrefab = GhoulAssets.tendrilSweepEffect; hitEffectPrefab = GhoulAssets.swordHitImpactEffect; impactSound = GhoulAssets.swordHitSoundEvent.index; ((EntityState)this).GetModelAnimator().SetFloat("aimPitchCached", ((EntityState)this).GetModelAnimator().GetFloat("aimPitchCycle")); ((EntityState)this).GetModelAnimator().SetBool("RotateTendrils", true); base.OnEnter(); } public override void FixedUpdate() { base.FixedUpdate(); ((EntityState)this).GetModelAnimator().SetFloat("aimPitchCached", ((EntityState)this).GetModelAnimator().GetFloat("aimPitchCycle")); } protected override void PlayAttackAnimation() { ((EntityState)this).PlayCrossfade("Gesture, Override", "SweepBody" + (1 + swingIndex), playbackRateParam, duration, 0.1f * duration); ((EntityState)this).PlayCrossfade("TentaclePitch, Additive", "TentaclePitch", (string)null, duration, 0.25f); ((EntityState)this).PlayCrossfade("TentaclesUp, Override", "Sweep" + (1 + swingIndex), playbackRateParam, duration, 0.1f * duration); if (((EntityState)this).skillLocator.FindSkillByFamilyName("VcrGhoulBodyMiscFamily").baseSkill.skillName == "GhoulAltMisc") { ((EntityState)this).PlayAnimation("TentaclesDown, Override", "TentacleDownShrunk", (string)null, duration + 1f, 0f); } } protected override void PlaySwingEffect() { base.PlaySwingEffect(); } protected override void OnHitEnemyAuthority() { //IL_001a: Unknown result type (might be due to invalid IL or missing references) base.OnHitEnemyAuthority(); NetworkIdentity component = ((EntityState)this).GetComponent(); if (Object.op_Implicit((Object)(object)component)) { NetMessageExtensions.Send((INetMessage)(object)new Helpers.SyncHeal(component.netId, 4), (NetworkDestination)2); } } public override void OnExit() { ((EntityState)this).GetModelAnimator().SetFloat("aimPitchCached", 0.5f); ((EntityState)this).GetModelAnimator().SetBool("RotateTendrils", false); base.OnExit(); } } public class EnrageTransitionIn : GhoulTransitionMainBase { public float baseDuration = 2.5f; private float duration; private GhoulWeaponComponent wep; private bool hasPlayed; private float roarDelay; public override void OnEnter() { duration = baseDuration / ((BaseState)this).attackSpeedStat; ((EntityState)this).PlayAnimation("TentaclesUp, Override", "Empty", "", duration, 0f); ((EntityState)this).PlayAnimation("TentaclesDown, Override", "Empty", "", duration, 0f); if (base.isSkinKaneki) { ((EntityState)this).PlayAnimation("Gesture, Override", "EnrageTransitionKaneki", "", duration, 0f); ((EntityState)this).PlayAnimation("TentaclesUp, Override", "EnrageTransitionKaneki", "", duration, 0f); ((EntityState)this).PlayAnimation("TentaclesDown, Override", "EnrageTransitionKaneki", "", duration, 0f); roarDelay = 0.9f; } else { ((EntityState)this).PlayAnimation("Gesture, Override", "EnrageTransition", "", duration, 0f); ((EntityState)this).PlayAnimation("TentaclesUp, Override", "EnrageTransition", "", duration, 0f); ((EntityState)this).PlayAnimation("TentaclesDown, Override", "EnrageTransition", "", duration, 0f); roarDelay = 1.3f; } ((GenericCharacterMain)this).OnEnter(); wep = ((EntityState)this).GetComponent(); wep.isEnraged = true; ((EntityState)this).characterBody.AddTimedBuff(LegacyResourcesAPI.Load("BuffDefs/HiddenInvincibility"), duration + 1f); Util.PlaySound("Play_Ghoul_Tendril_Grow", ((EntityState)this).gameObject); } public void Roar() { hasPlayed = true; if (base.isSkinKaneki) { Util.PlaySound("Play_Ghoul_Kaneki_Roar", ((EntityState)this).gameObject); } else { Util.PlaySound("Play_Ghoul_Roar", ((EntityState)this).gameObject); } } public override void FixedUpdate() { ((GenericCharacterMain)this).FixedUpdate(); if (((EntityState)this).isAuthority) { if (((EntityState)this).fixedAge > roarDelay && !hasPlayed) { Roar(); } if (((EntityState)this).fixedAge >= duration) { wep.isEnraged = true; ((EntityState)this).outer.SetNextStateToMain(); } } } public override void OnExit() { ((EntityState)this).GetModelAnimator().SetLayerWeight(((EntityState)this).GetModelAnimator().GetLayerIndex("Body, Enraged"), 1f); ((EntityState)this).skillLocator.primary.SetSkillOverride((object)((EntityState)this).skillLocator, (SkillDef)(object)GhoulSurvivor.tendrilSlapDef, (SkillOverridePriority)4); if (!((EntityState)this).skillLocator.utility.skillNameToken.Contains("ALT")) { ((EntityState)this).skillLocator.utility.SetSkillOverride((object)((EntityState)this).skillLocator, GhoulSurvivor.spinSkillDef, (SkillOverridePriority)4); } else { ((EntityState)this).skillLocator.utility.SetSkillOverride((object)((EntityState)this).skillLocator, GhoulSurvivor.spinSkillDef, (SkillOverridePriority)4); } if (!((EntityState)this).skillLocator.special.skillNameToken.Contains("HUNGRY")) { ((EntityState)this).skillLocator.special.SetSkillOverride((object)((EntityState)this).skillLocator, GhoulSurvivor.slamSkillDef, (SkillOverridePriority)4); } else { ((EntityState)this).skillLocator.special.SetSkillOverride((object)((EntityState)this).skillLocator, GhoulSurvivor.bingeSkillDef, (SkillOverridePriority)4); } wep.EnrageOverlay(); ((GenericCharacterMain)this).OnExit(); } public override bool CanExecuteSkill(GenericSkill skillSlot) { return false; } } public class EnrageTransitionOut : GenericCharacterMain { private GhoulWeaponComponent wep; public override void OnEnter() { ((GenericCharacterMain)this).OnEnter(); wep = ((EntityState)this).GetComponent(); wep.isEnraged = false; wep.rageValue = 0f; ((EntityState)this).skillLocator.primary.UnsetSkillOverride((object)((EntityState)this).skillLocator, (SkillDef)(object)GhoulSurvivor.tendrilSlapDef, (SkillOverridePriority)4); ((EntityState)this).skillLocator.utility.UnsetSkillOverride((object)((EntityState)this).skillLocator, GhoulSurvivor.spinSkillDef, (SkillOverridePriority)4); ((EntityState)this).skillLocator.special.UnsetSkillOverride((object)((EntityState)this).skillLocator, GhoulSurvivor.slamSkillDef, (SkillOverridePriority)4); if (((EntityState)this).skillLocator.utility.skillNameToken.Contains("DEVOUR")) { ((EntityState)this).skillLocator.utility.UnsetSkillOverride((object)((EntityState)this).skillLocator, GhoulSurvivor.spinSkillDef, (SkillOverridePriority)4); } if (((EntityState)this).skillLocator.special.skillNameToken.Contains("BINGE")) { ((EntityState)this).skillLocator.special.UnsetSkillOverride((object)((EntityState)this).skillLocator, GhoulSurvivor.bingeSkillDef, (SkillOverridePriority)4); } ((EntityState)this).outer.SetNextStateToMain(); } public override void OnExit() { ((EntityState)this).GetModelAnimator().SetLayerWeight(((EntityState)this).GetModelAnimator().GetLayerIndex("Body, Enraged"), 0f); Util.PlaySound("Play_Ghoul_Tendril_Shrink", ((EntityState)this).gameObject); wep.RemoveOverlay(); ((EntityState)this).characterBody.isSprinting = false; ((GenericCharacterMain)this).OnExit(); } } public class EvolveTransitionState : GhoulBaseSkillState { public override void OnEnter() { ((BaseState)this).OnEnter(); } public override void OnExit() { ((EntityState)this).OnExit(); } public override void FixedUpdate() { ((EntityState)this).FixedUpdate(); } } public class GhoulTransitionMainBase : GenericCharacterMain { public bool isSkinKaneki { get { ModelSkinController component = ((Component)((EntityState)this).GetModelTransform()).GetComponent(); if (Helpers.isLocalUserGhoul && component.skins[component.currentSkinIndex].nameToken.Contains("MASTERY")) { return true; } return false; } } public override bool CanExecuteSkill(GenericSkill skillSlot) { return false; } } } namespace GhoulMod.Survivors.Ghoul.SkillStates.Cling { public class ClingBaseState : BaseSkillState { public CharacterBody riddenBody; public Collider riddenCollider; private GameObject _anchor; private Vector3 _initialPosition; private Vector3 _lastPosition; private Transform _modelTransform; public override void OnEnter() { //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_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_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_005c: Unknown result type (might be due to invalid IL or missing references) //IL_0087: Unknown result type (might be due to invalid IL or missing references) //IL_0091: Expected O, but got Unknown //IL_00b8: 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_011e: 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_0123: Unknown result type (might be due to invalid IL or missing references) //IL_012a: Unknown result type (might be due to invalid IL or missing references) //IL_012f: Unknown result type (might be due to invalid IL or missing references) ((BaseState)this).OnEnter(); riddenCollider = findClosestHurtbox(); if ((Object)(object)riddenCollider == (Object)null) { ((EntityState)this).outer.SetNextStateToMain(); return; } Bounds bounds = riddenCollider.bounds; Vector3 center = ((Bounds)(ref bounds)).center; bounds = riddenCollider.bounds; center.y = ((Bounds)(ref bounds)).max.y; Vector3 localPosition = default(Vector3); ((Vector3)(ref localPosition))..ctor(0f, -0.7f, -0.3f); _anchor = new GameObject("ghoulAnchor"); _anchor.transform.SetParent(((Component)riddenCollider).transform); _anchor.transform.position = center; string name = ((Object)((Component)riddenBody.hurtBoxGroup.mainHurtBox.healthComponent).gameObject).name; _anchor.transform.localPosition = localPosition; _modelTransform = ((EntityState)this).GetModelTransform(); _initialPosition = (Object.op_Implicit((Object)(object)_modelTransform) ? _modelTransform.position : ((EntityState)this).transform.position); _lastPosition = _initialPosition; ((Behaviour)((EntityState)this).modelLocator).enabled = false; ((EntityState)this).gameObject.layer = LayerIndex.fakeActor.intVal; } private Collider findClosestHurtbox() { //IL_00c7: 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_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) if ((Object)(object)riddenBody.hurtBoxGroup == (Object)null) { return null; } string name = ((Object)((Component)riddenBody.hurtBoxGroup.mainHurtBox.healthComponent).gameObject).name; name.Replace("(Clone)", ""); GameObject val = BodyCatalog.FindBodyPrefab(name); if (!Object.op_Implicit((Object)(object)val)) { return null; } HurtBox[] array = null; int num = -1; if (Object.op_Implicit((Object)(object)val.GetComponentInChildren())) { array = val.GetComponentInChildren().hurtBoxes; for (int i = 0; i < array.Length; i++) { HurtBox val2 = array[i]; if (!((Object)(object)val2 == (Object)null)) { if (num == -1) { num = i; } else if (Vector3.Distance(((Component)val2).transform.position, ((EntityState)this).transform.position) > Vector3.Distance(((Component)array[i]).transform.position, ((EntityState)this).transform.position)) { num = i; } } } } Log.Debug(riddenBody.hurtBoxGroup.hurtBoxes[num].collider); return riddenBody.hurtBoxGroup.hurtBoxes[num].collider; } public override void Update() { ((EntityState)this).Update(); if ((Object)(object)riddenCollider != (Object)null && (Object)(object)_anchor != (Object)null) { UpdateRidingPosition(); } } public override void FixedUpdate() { //IL_0041: 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_0057: 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) ((EntityState)this).FixedUpdate(); if (riddenBody.healthComponent.alive) { if (((EntityState)this).isAuthority && Object.op_Implicit((Object)(object)((EntityState)this).characterMotor)) { ((EntityState)this).characterMotor.moveDirection = Vector3.zero; ((EntityState)this).characterMotor.velocity = Vector3.zero; ((EntityState)this).characterMotor.rootMotion = Vector3.zero; if ((Object)(object)riddenCollider != (Object)null && (Object)(object)_anchor != (Object)null) { UpdateRidingPosition(fixedUpdate: true); } else { ((EntityState)this).outer.SetNextStateToMain(); } } } else { ((EntityState)this).outer.SetNextStateToMain(); } } private void UpdateRidingPosition(bool fixedUpdate = false) { //IL_0002: 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_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) //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_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_0046: 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_00a6: 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_007c: 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) Vector3 val = Vector3.Lerp(_initialPosition, _anchor.transform.position, ((EntityState)this).fixedAge * 3f); val = Vector3.Lerp(_lastPosition, val, 0.5f); ((BaseCharacterController)((EntityState)this).characterMotor).Motor.SetPosition(val, true); if (Object.op_Implicit((Object)(object)_modelTransform)) { _modelTransform.position = val; _modelTransform.LookAt(_anchor.transform.position); ((EntityState)this).characterDirection.forward = _anchor.transform.forward; } _lastPosition = val; } public override void OnExit() { //IL_001e: 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) ((EntityState)this).OnExit(); ((BaseCharacterController)((EntityState)this).characterMotor).Motor.SetPosition(((Component)((EntityState)this).characterMotor).transform.position + new Vector3(0f, 2.25f, 0f), true); Object.Destroy((Object)(object)_anchor); ((EntityState)this).PlayAnimation("FullBody, Underride", "RidingDismount"); ((Behaviour)((EntityState)this).modelLocator).enabled = true; ((EntityState)this).gameObject.layer = LayerIndex.defaultLayer.intVal; } public override void OnSerialize(NetworkWriter writer) { ((BaseSkillState)this).OnSerialize(writer); if (Object.op_Implicit((Object)(object)riddenBody)) { writer.Write(((Component)riddenBody).gameObject); } } public override void OnDeserialize(NetworkReader reader) { ((BaseSkillState)this).OnDeserialize(reader); GameObject val = reader.ReadGameObject(); if (Object.op_Implicit((Object)(object)val)) { riddenBody = val.GetComponent(); } } } public class EndClingState : BaseState { public override void OnEnter() { ((BaseState)this).OnEnter(); ((EntityState)this).GetModelAnimator().SetBool("Riding", false); ((EntityState)this).PlayAnimation("FullBody, Underride", "RidingDismount"); ((EntityState)this).outer.SetState((EntityState)(object)new GhoulMainState()); } } public class GhoulClingState : ClingBaseState { public float duration = 1f; public override void OnEnter() { base.OnEnter(); ChildLocator modelChildLocator = ((EntityState)this).GetModelChildLocator(); ((EntityState)this).PlayAnimation("FullBody, Underride", "Riding", "RidingClimb.playbackRate", 0.4f, 0f); ((EntityState)this).GetModelAnimator().SetBool("Riding", true); } public override void FixedUpdate() { base.FixedUpdate(); if (((EntityState)this).isAuthority && ((EntityState)this).fixedAge >= duration) { ((EntityState)this).outer.SetState((EntityState)(object)new EndClingState()); } } public override void OnExit() { base.OnExit(); } } } namespace GhoulMod.Survivors.Ghoul.Items { public class BaseMutationItem : ItemBehavior { public string mutationName; private bool hasModelChanged; private bool hasPlayedSfx; public void MutationOverride(GenericSkill family, SkillDef skillReplacement) { family.SetSkillOverride((object)((Component)family).gameObject, skillReplacement, (SkillOverridePriority)3); } public void MutationOverride(GenericSkill family, SkillDef skillReplacement, GenericSkill family2, SkillDef skillReplacement2) { family.SetSkillOverride((object)((Component)family).gameObject, skillReplacement, (SkillOverridePriority)3); family2.SetSkillOverride((object)((Component)family2).gameObject, skillReplacement2, (SkillOverridePriority)3); } public void ResetSkills(GenericSkill family, SkillDef skillReplacement) { family.UnsetSkillOverride((object)((Component)family).gameObject, skillReplacement, (SkillOverridePriority)3); } public void ResetSkills(GenericSkill family, SkillDef skillReplacement, GenericSkill family2, SkillDef skillReplacement2) { family.UnsetSkillOverride((object)((Component)family).gameObject, skillReplacement, (SkillOverridePriority)3); family2.UnsetSkillOverride((object)((Component)family2).gameObject, skillReplacement2, (SkillOverridePriority)3); } [Tooltip("Use to enable/disable a ChildLocator Transform")] public void OverrideModel(string modelReplacement, bool enable) { if (!Object.op_Implicit((Object)(object)base.body.modelLocator) || !Object.op_Implicit((Object)(object)((Component)base.body.modelLocator.modelTransform).GetComponent())) { return; } if (Object.op_Implicit((Object)(object)((Component)base.body.modelLocator.modelTransform).GetComponent().FindChild(modelReplacement))) { if (!Object.op_Implicit((Object)(object)((Component)((Component)base.body.modelLocator.modelTransform).GetComponent().FindChild(modelReplacement)).gameObject)) { Log.Warning("The childpair has a null object, aborting"); } else { ((Component)((Component)base.body.modelLocator.modelTransform).GetComponent().FindChild(modelReplacement)).gameObject.SetActive(enable); } } else { Log.Warning("The childpair you are searching for does not exist! make sure to recheck the name"); } } [Tooltip("Use to enable one ChildLocator Transform and disable another")] public void OverrideModel(string modelToReplace, string modelReplacement) { if (Object.op_Implicit((Object)(object)base.body.modelLocator) && Object.op_Implicit((Object)(object)((Component)base.body.modelLocator.modelTransform).GetComponent())) { if (Object.op_Implicit((Object)(object)((Component)base.body.modelLocator.modelTransform).GetComponent().FindChild(modelToReplace)) && Object.op_Implicit((Object)(object)((Component)base.body.modelLocator.modelTransform).GetComponent().FindChild(modelReplacement))) { ((Component)((Component)base.body.modelLocator.modelTransform).GetComponent().FindChild(modelReplacement)).gameObject.SetActive(true); if (Object.op_Implicit((Object)(object)((Component)((Component)base.body.modelLocator.modelTransform).GetComponent().FindChild(modelReplacement)).GetComponent())) { Object.Destroy((Object)(object)((Component)((Component)base.body.modelLocator.modelTransform).GetComponent().FindChild(modelReplacement)).GetComponent()); } ((Component)((Component)base.body.modelLocator.modelTransform).GetComponent().FindChild(modelToReplace)).gameObject.SetActive(false); } else { Log.Warning("One or more childpairs you are searching for do not exist! make sure to recheck the names"); } } Log.Debug("Model overriden"); } private void PlaySound() { if (base.stack == 1 && !hasPlayedSfx) { hasPlayedSfx = true; Util.PlaySound("Play_Ghoul_Mutation_" + mutationName + "_Picked_Up", ((Component)this).gameObject); } } public virtual void Behaviour() { } public virtual void DisableBehaviour() { } private void Awake() { ((Behaviour)this).enabled = false; } private void OnEnable() { Behaviour(); } private void FixedUpdate() { PlaySound(); } private void OnDisable() { if (Object.op_Implicit((Object)(object)base.body)) { DisableBehaviour(); } } } public class DefaultEnragedMutation : BaseMutationItem { public override void Behaviour() { mutationName = "Default"; base.Behaviour(); MutationOverride(((ItemBehavior)this).body.skillLocator.primary, (SkillDef)(object)GhoulSurvivor.tendrilSlapDef, ((ItemBehavior)this).body.skillLocator.utility, GhoulSurvivor.spinSkillDef); OverrideModel("TentacleUpModel", "DefaultMutationModel"); } public override void DisableBehaviour() { base.DisableBehaviour(); OverrideModel("DefaultMutationModel", "TentacleUpModel"); ResetSkills(((ItemBehavior)this).body.skillLocator.primary, (SkillDef)(object)GhoulSurvivor.tendrilSlapDef, ((ItemBehavior)this).body.skillLocator.utility, GhoulSurvivor.spinSkillDef); } } public class OneEyeKingItemMutation : BaseMutationItem { public override void Behaviour() { mutationName = "One_Eye_King"; base.Behaviour(); MutationOverride(((ItemBehavior)this).body.skillLocator.special, GhoulSurvivor.impSpikeSkillDef); OverrideModel("TentacleDownModel", "OneEyeKingMutationModel"); } public override void DisableBehaviour() { base.DisableBehaviour(); OverrideModel("OneEyeKingMutationModel", "TentacleDownModel"); ResetSkills(((ItemBehavior)this).body.skillLocator.special, GhoulSurvivor.impSpikeSkillDef); } } public class SlamItemMutation : BaseMutationItem { public override void Behaviour() { mutationName = "Arm"; base.Behaviour(); MutationOverride(((ItemBehavior)this).body.skillLocator.special, GhoulSurvivor.slamSkillDef); OverrideModel("ArmMutationModel", enable: true); } public override void DisableBehaviour() { base.DisableBehaviour(); ResetSkills(((ItemBehavior)this).body.skillLocator.special, GhoulSurvivor.slamSkillDef); OverrideModel("ArmMutationModel", enable: false); } } public class TestItem : ItemBehavior { private void Awake() { ((Behaviour)this).enabled = false; } private void OnEnable() { Log.Message("Hallo World"); } private void FixedUpdate() { } private void OnDisable() { Log.Message("Goodbye World Uwah"); } } public class ThirdEyeItemMutation : BaseMutationItem { public override void Behaviour() { mutationName = "Third_Eye"; base.Behaviour(); MutationOverride(((ItemBehavior)this).body.skillLocator.utility, GhoulSurvivor.bingeSkillDef); OverrideModel("EyeMutationModel", enable: true); } public override void DisableBehaviour() { base.DisableBehaviour(); OverrideModel("EyeMutationModel", enable: false); ResetSkills(((ItemBehavior)this).body.skillLocator.utility, GhoulSurvivor.bingeSkillDef); } } } namespace GhoulMod.Survivors.Ghoul.Components { public class AnimationFunctions : MonoBehaviour { public void GrowSound() { } public void Roar() { ModelSkinController component = ((Component)this).GetComponent(); if (component.skins[component.currentSkinIndex].nameToken.Contains("MASTERY")) { Util.PlaySound("Play_Ghoul_Kaneki_Roar", ((Component)this).gameObject); } else { Util.PlaySound("Play_Ghoul_Roar", ((Component)this).gameObject); } } } public class DisplayPrefabEffects : MonoBehaviour { private GameObject shaker; private GameObject bloodPrefab = GhoulAssets.bloodEffect; private GameObject bloodInstance; private uint roarSFX; private uint stabSFX; private uint goreSFX; private uint tendrilLoopSFX; private uint tendrilGrowSFX; private uint tendrilShrinkSFX; public void Start() { goreSFX = Util.PlaySound("Play_Ghoul_Lobby_Enter", ((Component)this).gameObject); tendrilLoopSFX = Util.PlaySound("Play_Ghoul_Tendril_Movement_Loop", ((Component)this).gameObject); } public void SquealchSFX() { bloodInstance = Object.Instantiate(bloodPrefab, ((Component)this).transform.Find("GhoulLobby_Extras")); stabSFX = Util.PlaySound("Play_Ghoul_Attack_Impact", ((Component)this).gameObject); } public void RoarSFX() { ModelSkinController component = ((Component)this).GetComponent(); if (component.skins[component.currentSkinIndex].nameToken.Contains("MASTERY")) { roarSFX = Util.PlaySound("Play_Ghoul_Kaneki_Roar", ((Component)this).gameObject); } else { roarSFX = Util.PlaySound("Play_Ghoul_Roar", ((Component)this).gameObject); } StartScreenShake(); } public void GrowSFX() { tendrilGrowSFX = Util.PlaySound("Play_Ghoul_Tendril_Grow", ((Component)this).gameObject); } public void ShrinkSFX() { tendrilShrinkSFX = Util.PlaySound("Play_Ghoul_Tendril_Shrink", ((Component)this).gameObject); } public void StartScreenShake() { shaker = Object.Instantiate(GhoulAssets.lobby_RoarShake, ((Component)this).gameObject.transform); } public void OnDestroy() { if ((Object)(object)shaker != (Object)null) { Object.Destroy((Object)(object)shaker); } AkSoundEngine.StopPlayingID(roarSFX); AkSoundEngine.StopPlayingID(goreSFX); AkSoundEngine.StopPlayingID(stabSFX); AkSoundEngine.StopPlayingID(tendrilLoopSFX); } } public class EnrageCameraController : MonoBehaviour { public static string targetChild = "BaseTransform"; public CharacterBody body; public CharacterMaster characterMaster; public GameObject cameraObject; public Animator ultimateAnimator; public Transform ultimateCameraTransform; public GameObject ultimateCameraGameObject; public Transform previousCameraParent; public CameraTargetParams cameraTargetParams; public Animator domainUltimateAnimator; public GameObject domainUltimateCameraGameObject; public Transform domainUltimateCameraTransform; public ModelLocator modelLocator; public Transform rootTransform; public float smoothDampTime = 0.2f; public float maxSmoothDampSpeed = 50f; public bool cameraStartFovAnimation = false; public bool cameraStartFovAnimation2 = false; public bool cameraAlreadyDamping2 = false; public bool cameraAlreadyDamping = false; public float cameraTimeAtStart; public bool baseAIPresent = false; public Vector3 previousCameraPosition; public Quaternion previousRotation; public Vector3 smoothDampVelocity; public CameraParamsOverrideHandle handle; public float lerpRotationInterpolationValue; public bool shouldRotateCamera; public Quaternion startRotation; public float stopwatch; public static float lerpTime = 1.25f; public void Awake() { } public void Start() { body = ((Component)this).gameObject.GetComponent(); modelLocator = ((Component)this).gameObject.GetComponent(); cameraTargetParams = ((Component)this).GetComponent(); ChildLocator component = ((Component)modelLocator.modelTransform).gameObject.GetComponent(); rootTransform = component.FindChild("BaseTransform"); ultimateAnimator = ((Component)ultimateCameraGameObject.transform.GetChild(0)).GetComponent(); domainUltimateAnimator = domainUltimateCameraGameObject.GetComponent(); ultimateCameraTransform = ultimateCameraGameObject.transform.GetChild(0).GetChild(0); domainUltimateCameraTransform = domainUltimateCameraGameObject.transform.GetChild(0); characterMaster = body.master; BaseAI component2 = ((Component)characterMaster).GetComponent(); baseAIPresent = Object.op_Implicit((Object)(object)component2); if (!Object.op_Implicit((Object)(object)characterMaster)) { baseAIPresent = true; } try { cameraObject = ((Component)Camera.main).gameObject; previousCameraParent = cameraObject.transform.parent; } catch (NullReferenceException arg) { Debug.Log((object)$"Should be alright: {arg}"); } } public void Update() { //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_0082: 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_0230: Unknown result type (might be due to invalid IL or missing references) //IL_0241: 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_00ef: 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_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) //IL_0109: 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_0113: 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_0126: 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_0144: Unknown result type (might be due to invalid IL or missing references) //IL_0149: Unknown result type (might be due to invalid IL or missing references) //IL_0184: 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_019f: Unknown result type (might be due to invalid IL or missing references) //IL_01a4: Unknown result type (might be due to invalid IL or missing references) //IL_01ad: 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_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_01c3: 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_01d6: Unknown result type (might be due to invalid IL or missing references) //IL_01ed: Unknown result type (might be due to invalid IL or missing references) //IL_01f4: Unknown result type (might be due to invalid IL or missing references) //IL_01f9: Unknown result type (might be due to invalid IL or missing references) if (!Object.op_Implicit((Object)(object)cameraObject)) { cameraObject = ((Component)Camera.main).gameObject; previousCameraParent = cameraObject.transform.parent; } if (Object.op_Implicit((Object)(object)cameraObject)) { cameraObject.transform.localPosition = Vector3.SmoothDamp(cameraObject.transform.localPosition, Vector3.zero, ref smoothDampVelocity, smoothDampTime, maxSmoothDampSpeed, Time.deltaTime); } if (Object.op_Implicit((Object)(object)ultimateAnimator)) { if (Time.time > cameraTimeAtStart + 2.6f && !cameraAlreadyDamping && cameraStartFovAnimation) { cameraTargetParams.RemoveParamsOverride(handle, 0.2f); CharacterCameraParamsData currentCameraParamsData = cameraTargetParams.currentCameraParamsData; currentCameraParamsData.fov = BlendableFloat.op_Implicit(130f); CameraParamsOverrideRequest val = default(CameraParamsOverrideRequest); val.cameraParamsData = currentCameraParamsData; val.priority = 0f; CameraParamsOverrideRequest val2 = val; cameraAlreadyDamping = true; cameraStartFovAnimation = false; handle = cameraTargetParams.AddParamsOverride(val2, 0.7f); } if (Time.time > cameraTimeAtStart + 3.4f && !cameraAlreadyDamping2 && cameraStartFovAnimation2) { cameraTargetParams.RemoveParamsOverride(handle, 0.2f); CharacterCameraParamsData currentCameraParamsData2 = cameraTargetParams.currentCameraParamsData; currentCameraParamsData2.fov = BlendableFloat.op_Implicit(60f); CameraParamsOverrideRequest val = default(CameraParamsOverrideRequest); val.cameraParamsData = currentCameraParamsData2; val.priority = 0f; CameraParamsOverrideRequest val3 = val; cameraAlreadyDamping2 = true; cameraStartFovAnimation2 = false; handle = cameraTargetParams.AddParamsOverride(val3, 0.3f); } } if (shouldRotateCamera) { stopwatch += Time.deltaTime; cameraObject.transform.localRotation = Quaternion.Slerp(startRotation, Quaternion.identity, stopwatch / lerpTime); if (stopwatch >= lerpTime) { stopwatch = 0f; shouldRotateCamera = false; } } } public void UnsetUltimate() { //IL_0080: 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_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) if (!baseAIPresent) { cameraAlreadyDamping = false; cameraAlreadyDamping2 = false; smoothDampTime = 0.75f; maxSmoothDampSpeed = 50f; lerpTime = 1.25f; if (Object.op_Implicit((Object)(object)ultimateAnimator)) { ultimateAnimator.Play("New State"); } cameraObject.transform.SetParent(previousCameraParent, true); cameraTargetParams.RemoveParamsOverride(handle, 0f); shouldRotateCamera = true; startRotation = cameraObject.transform.localRotation; } } public void UnsetDomainUltimate() { //IL_0073: 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) if (!baseAIPresent) { cameraAlreadyDamping = false; cameraAlreadyDamping2 = false; smoothDampTime = 0.5f; maxSmoothDampSpeed = 50f; lerpTime = 0.5f; shouldRotateCamera = true; domainUltimateAnimator.Play("New State"); cameraObject.transform.SetParent(previousCameraParent, true); cameraTargetParams.RemoveParamsOverride(handle, 0.2f); } } public void TriggerDomainUlt() { //IL_0062: 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_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_0091: 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_009a: 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_00ac: 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_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) if (!baseAIPresent) { smoothDampTime = 0.001f; maxSmoothDampSpeed = 9999999f; domainUltimateAnimator.SetTrigger("startUltimateDomain"); shouldRotateCamera = false; cameraObject.transform.SetParent(domainUltimateCameraTransform, true); cameraObject.transform.localRotation = Quaternion.identity; CharacterCameraParamsData currentCameraParamsData = cameraTargetParams.currentCameraParamsData; currentCameraParamsData.fov = BlendableFloat.op_Implicit(40f); CameraParamsOverrideRequest val = default(CameraParamsOverrideRequest); val.cameraParamsData = currentCameraParamsData; val.priority = 0f; CameraParamsOverrideRequest val2 = val; handle = cameraTargetParams.AddParamsOverride(val2, 0.05f); } } public void TriggerUlt() { //IL_007b: Unknown result type (might be due to invalid IL or missing references) //IL_0091: Unknown result type (might be due to invalid IL or missing references) //IL_0096: Unknown result type (might be due to invalid IL or missing references) //IL_009e: 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_00aa: 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_00b3: 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_00c5: 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_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) if (!baseAIPresent) { smoothDampTime = 0.001f; maxSmoothDampSpeed = 9999999f; ultimateAnimator.SetTrigger("startUltimate"); cameraTimeAtStart = Time.time; cameraStartFovAnimation = true; cameraStartFovAnimation2 = true; shouldRotateCamera = false; cameraObject.transform.SetParent(ultimateCameraTransform, true); cameraObject.transform.localRotation = Quaternion.identity; CharacterCameraParamsData currentCameraParamsData = cameraTargetParams.currentCameraParamsData; currentCameraParamsData.fov = BlendableFloat.op_Implicit(40f); CameraParamsOverrideRequest val = default(CameraParamsOverrideRequest); val.cameraParamsData = currentCameraParamsData; val.priority = 0f; CameraParamsOverrideRequest val2 = val; handle = cameraTargetParams.AddParamsOverride(val2, 0.05f); } } public void OnDestroy() { Object.Destroy((Object)(object)ultimateCameraGameObject); } } internal class GhoulCharacterMenuListener : MonoBehaviour { private GameObject loadoutPanel; private MPEventSystemLocator eventSystemLocator; private UserProfile userProfile; private Loadout loadout; private BodyIndex survivorIndex; public void Start() { //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) loadoutPanel = ((Component)((Component)this).gameObject.transform.Find("SafeArea/LeftHandPanel (Layer: Main)/SurvivorInfoPanel, Active (Layer: Secondary)/ContentPanel (Overview, Skills, Loadout)/LoadoutScrollContainer/LoadoutScrollPanel/LoadoutPanel")).gameObject; Hook(); eventSystemLocator = loadoutPanel.GetComponent(); MPEventSystem eventSystem = eventSystemLocator.eventSystem; if ((Object)(object)eventSystem == (Object)null) { userProfile = null; } else { LocalUser localUser = eventSystem.localUser; userProfile = ((localUser != null) ? localUser.userProfile : null); } loadout = userProfile.loadout; survivorIndex = BodyCatalog.FindBodyIndex("VcrGhoulBody"); } public void Unhook() { //IL_0008: Unknown result type (might be due to invalid IL or missing references) //IL_0012: Expected O, but got Unknown SurvivorIconController.Update -= new hook_Update(SurvivorIconController_Update); } public void Hook() { //IL_0008: Unknown result type (might be due to invalid IL or missing references) //IL_0012: Expected O, but got Unknown SurvivorIconController.Update += new hook_Update(SurvivorIconController_Update); } private void SurvivorIconController_Update(orig_Update orig, SurvivorIconController self) { //IL_0017: 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_003b: Unknown result type (might be due to invalid IL or missing references) if (Object.op_Implicit((Object)(object)self) && Object.op_Implicit((Object)(object)self.survivorIcon) && self.survivorBodyIndex == survivorIndex) { switch (loadout.bodyLoadoutManager.GetSkinIndex(survivorIndex)) { case 0u: self.survivorIcon.texture = GhoulAssets.baseIcon; break; case 1u: self.survivorIcon.texture = GhoulAssets.tokyoIcon; break; case 2u: self.survivorIcon.texture = GhoulAssets.tokyoIcon; break; case 3u: self.survivorIcon.texture = GhoulAssets.tokyoIcon; break; case 4u: self.survivorIcon.texture = GhoulAssets.carnageIcon; break; default: self.survivorIcon.texture = GhoulAssets.baseIcon; break; } } orig.Invoke(self); } public void OnDestroy() { Unhook(); } } public class GhoulCrosshairController : MonoBehaviour { public GhoulWeaponComponent wep; public Transform ring; public RawImage ringImage; public Transform dot; public SkillLocator sl; public CrosshairController crosshairController { get; set; } private void Start() { //IL_00be: Unknown result type (might be due to invalid IL or missing references) ring = ((Component)this).transform.Find("Ring"); ringImage = ((Component)ring).GetComponent(); dot = ((Component)this).transform.Find("Center"); crosshairController = ((Component)this).GetComponentInParent(); wep = ((Component)crosshairController.hudElement.targetCharacterBody).gameObject.GetComponent(); sl = ((Component)crosshairController.hudElement.targetCharacterBody).gameObject.GetComponent(); if (wep.grapplable && sl.secondary.stock > 0) { ((Graphic)((Component)ring).GetComponent()).color = Color.red; } } private void FixedUpdate() { //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_00e2: 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_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_0127: 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) //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_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) //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_0087: 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_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_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_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_01ed: Unknown result type (might be due to invalid IL or missing references) if (Object.op_Implicit((Object)(object)((Component)ring).GetComponent())) { if (wep.enemyDetected) { ((Graphic)((Component)ring).GetComponent()).color = Color32.op_Implicit(Color32.Lerp(Color32.op_Implicit(((Graphic)((Component)ring).GetComponent()).color), Color32.op_Implicit(Color.red), Time.deltaTime * 15f)); ((Graphic)((Component)dot).GetComponent()).color = Color32.op_Implicit(Color32.Lerp(Color32.op_Implicit(((Graphic)((Component)dot).GetComponent()).color), Color32.op_Implicit(Color.red), Time.deltaTime * 25f)); } else { ((Graphic)((Component)ring).GetComponent()).color = Color32.op_Implicit(Color32.Lerp(Color32.op_Implicit(((Graphic)((Component)ring).GetComponent()).color), Color32.op_Implicit(Color.white), Time.deltaTime * 15f)); ((Graphic)((Component)dot).GetComponent()).color = Color32.op_Implicit(Color32.Lerp(Color32.op_Implicit(((Graphic)((Component)dot).GetComponent()).color), Color32.op_Implicit(Color.white), Time.deltaTime * 15f)); } if (wep.grapplable && sl.secondary.stock > 0 && Object.op_Implicit((Object)(object)ringImage)) { ringImage.texture = GhoulAssets.grappleCrosshair; ((Component)ring).transform.Rotate(0f, 0f, 140f * Time.fixedDeltaTime, (Space)1); } else { ringImage.texture = GhoulAssets.defaultCrosshair; ((Component)ring).transform.rotation = Quaternion.RotateTowards(((Component)ring).transform.rotation, Quaternion.identity, 25f); } } } } public class GhoulEruptOnDeath : MonoBehaviour { public GameObject bloodSplatObject = GhoulAssets.bloodSplatEffect; private GameObject bloodSplatInstance; public void Effect() { //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) Log.Debug("Spawned Blood"); bloodSplatInstance = Object.Instantiate(bloodSplatObject, ((Component)this).transform.position, Quaternion.identity); } } public class GhoulMusicComponent : MonoBehaviour { private uint songID; private MusicTrackOverride musicTrackOverride; private float duration = 231f; private float stopwatch = 0f; private void Awake() { //IL_0031: Unknown result type (might be due to invalid IL or missing references) //IL_0036: Unknown result type (might be due to invalid IL or missing references) if (((NetworkBehaviour)((Component)this).GetComponent()).hasAuthority) { musicTrackOverride = ((Component)this).gameObject.AddComponent(); musicTrackOverride.track = Addressables.LoadAssetAsync((object)"RoR2/Base/Common/MusicTrackDefs/muNone.asset").WaitForCompletion(); musicTrackOverride.priority = 90000; songID = Util.PlaySound("Play_Ghoul_Unravel_Song", ((Component)this).gameObject); } } public void Update() { stopwatch += Time.deltaTime; if (stopwatch >= duration) { Object.Destroy((Object)(object)this); } } private void OnDestroy() { AkSoundEngine.StopPlayingID(songID); Object.Destroy((Object)(object)musicTrackOverride); } } public class GhoulRageBar : MonoBehaviour { public HUD targetHud; public GhoulWeaponComponent wep; public Slider valueSlider; public Image fillImage; public Animator anim; public TextMeshProUGUI textbox; private void Start() { valueSlider = ((Component)this).GetComponent(); anim = ((Component)this).GetComponent(); fillImage = ((Component)((Component)this).transform.Find("Fill Area").Find("Fill")).GetComponent(); textbox = ((Component)((Component)this).transform.Find("TextBox")).GetComponent(); } private void OnDestroy() { } private void Update() { //IL_00e4: 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) if (Object.op_Implicit((Object)(object)wep)) { valueSlider.maxValue = wep.rageThreshold; valueSlider.value = wep.rageValue; if (wep.blockedDamage > 0f) { ((TMP_Text)textbox).text = Mathf.Round(wep.blockedDamage).ToString(); } else { ((TMP_Text)textbox).text = ""; } if (wep.isEnraged) { ((Graphic)fillImage).color = Color.red; anim.SetBool("isEnraged", true); } else { ((Graphic)fillImage).color = new Color(130f, 0f, 0f, 255f); anim.SetBool("isEnraged", false); } } } private void SetDisplay() { } } public class GhoulVignette : MonoBehaviour { public HUD targetHud; public GhoulWeaponComponent wep; public Animator anim; public void Start() { anim = ((Component)this).GetComponent(); } public void Update() { if (Object.op_Implicit((Object)(object)wep)) { anim.SetBool("VignetteActive", wep.isEnraged); anim.SetFloat("VignetteSpeed", wep.drainSpeed); } } public void Heartbeat() { if (((NetworkBehaviour)((Component)wep).GetComponent()).hasAuthority) { Util.PlayAttackSpeedSound("Play_Ghoul_Heartbeat", ((Component)wep).gameObject, wep.drainSpeed + 0.5f); } } } public class GhoulWeaponComponent : MonoBehaviour { public float rageValue; public float takeDamageCoefficient = 1.1f; public float dealDamageCoefficient = 0.3f; public float itemDamageCoefficient = 0.25f; public float blockedDamage = 0f; public float drainSpeed; public float rageThreshold; public bool isEnraged; public bool isBlocking; public bool grapplable; public bool enemyDetected; internal float graceDelay = 0f; private HUD hud = null; private bool validatedSkin; private TemporaryOverlayInstance temporaryOverlay; private TemporaryOverlayInstance impTempOverlay; private ModelSkinController skinController; private CharacterBody characterBody; private ModelLocator locator; public GhoulInvasionManager _invasion; private DccsPool stagePool; internal float cravingTimer; public GhoulInvasionManager invasion { get { if (Object.op_Implicit((Object)(object)_invasion)) { return _invasion; } if (Object.op_Implicit((Object)(object)characterBody) && Object.op_Implicit((Object)(object)characterBody.master) && ((Component)this).GetComponent().FindSkillByFamilyName("VcrGhoulBodyMiscFamily").baseSkill.skillName == "GhoulAltMisc") { GhoulInvasionManager ghoulInvasionManager = ((Component)characterBody.master).GetComponent(); if (!Object.op_Implicit((Object)(object)ghoulInvasionManager)) { ghoulInvasionManager = ((Component)characterBody.master).gameObject.AddComponent(); } ghoulInvasionManager.SetGhoul(this); _invasion = ghoulInvasionManager; stagePool = ClassicStageInfo.instance.GetMonsterDccsPool; Log.Debug("This invasion thing working?"); return ghoulInvasionManager; } return null; } } private void Start() { characterBody = ((Component)this).GetComponent(); locator = ((Component)this).GetComponent(); skinController = ((Component)locator.modelTransform).gameObject.GetComponent(); if (((Component)this).GetComponent().FindSkillByFamilyName("VcrGhoulBodyMiscFamily").baseSkill.skillName == "GhoulAltMisc" && characterBody.isPlayerControlled) { GhoulInvasionManager ghoulInvasionManager = ((Component)characterBody.master).GetComponent(); if (!Object.op_Implicit((Object)(object)ghoulInvasionManager)) { ghoulInvasionManager = ((Component)characterBody.master).gameObject.AddComponent(); } ghoulInvasionManager.SetGhoul(this); _invasion = ghoulInvasionManager; } } public void AddEnraged(float additive, float graceAdd) { float num = (((Component)this).GetComponent().HasBuff(GhoulBuffs.hungerBuff) ? 2.2f : 1f); float num2 = additive * dealDamageCoefficient; rageValue += num2 * num; graceDelay = graceAdd + 0.4f; } public void EnrageOverlay(float duration = float.PositiveInfinity) { ModelLocator component = ((Component)this).GetComponent(); if (Object.op_Implicit((Object)(object)component)) { Transform modelTransform = component.modelTransform; if (Object.op_Implicit((Object)(object)modelTransform)) { temporaryOverlay = TemporaryOverlayManager.AddOverlay(((Component)modelTransform).gameObject); temporaryOverlay.duration = duration; temporaryOverlay.destroyComponentOnEnd = true; temporaryOverlay.originalMaterial = GhoulAssets.targetOverlayMat; temporaryOverlay.inspectorCharacterModel = ((Component)modelTransform).GetComponent(); temporaryOverlay.alphaCurve = AnimationCurve.EaseInOut(0f, 1f, 1f, 0f); temporaryOverlay.animateShaderAlpha = true; temporaryOverlay.AddToCharacterModel(((Component)modelTransform).GetComponent()); } } } public void ImpOverlay(float duration) { ModelLocator component = ((Component)this).GetComponent(); if (Object.op_Implicit((Object)(object)component)) { Transform modelTransform = component.modelTransform; if (Object.op_Implicit((Object)(object)modelTransform)) { impTempOverlay = TemporaryOverlayManager.AddOverlay(((Component)modelTransform).gameObject); impTempOverlay.duration = duration; impTempOverlay.destroyComponentOnEnd = true; impTempOverlay.originalMaterial = GhoulAssets.impOverlayMat; impTempOverlay.inspectorCharacterModel = ((Component)modelTransform).GetComponent(); impTempOverlay.alphaCurve = AnimationCurve.EaseInOut(0f, 1f, 1f, 0f); impTempOverlay.animateShaderAlpha = true; impTempOverlay.AddToCharacterModel(((Component)modelTransform).GetComponent()); } } } public void RemoveOverlay() { ModelLocator component = ((Component)this).GetComponent(); if (Object.op_Implicit((Object)(object)component)) { Transform modelTransform = component.modelTransform; if (Object.op_Implicit((Object)(object)modelTransform)) { temporaryOverlay.duration = 2f; temporaryOverlay.alphaCurve = AnimationCurve.EaseInOut(0f, 1f, 1f, 0f); } } } public void DeterminePrey() { cravingTimer = 0f; } public void FixedUpdate() { ValidateSkin(); } private void ValidateSkin() { if (validatedSkin || (Object.op_Implicit((Object)(object)skinController) && skinController.currentSkinIndex == -1) || !Object.op_Implicit((Object)(object)characterBody) || !Object.op_Implicit((Object)(object)skinController) || skinController.skins == null || skinController.skins.Length == 0 || skinController.currentSkinIndex >= skinController.skins.Length) { return; } SkinDef val = skinController.skins[skinController.currentSkinIndex]; if (!Object.op_Implicit((Object)(object)val)) { return; } validatedSkin = true; if (skinController.currentSkinIndex > 0) { switch (val.nameToken) { case "VCR_GHOUL_MASTERY_SKIN_NAME": characterBody.portraitIcon = GhoulAssets.LoadCharacterIcon("Kaneki"); break; case "VCR_GHOUL_GRAND_MASTERY_SKIN_NAME": characterBody.portraitIcon = GhoulAssets.LoadCharacterIcon("Kaneki"); break; case "VCR_GHOUL_CANNIBAL_MASTERY_SKIN_NAME": characterBody.portraitIcon = GhoulAssets.LoadCharacterIcon("Kaneki"); break; case "VCR_GHOUL_CLEANSED_SKIN_NAME": characterBody.portraitIcon = GhoulAssets.LoadCharacterIcon("Base"); break; case "VCR_GHOUL_VOID_SKIN_NAME": characterBody.portraitIcon = GhoulAssets.LoadCharacterIcon("Base"); break; case "VCR_GHOUL_CARNAGE_SKIN_NAME": characterBody.portraitIcon = GhoulAssets.LoadCharacterIcon("Carnage"); break; } } } } } namespace GhoulMod.Survivors.Ghoul.Achievements { [RegisterAchievement("VCR_GHOUL_unravelAchievement", "VCR_GHOUL_unravelAchievement", null, 3u, typeof(GhoulDoppelGangerServerAchievement))] public class GhoulDoppelGangerAchievement : BaseAchievement { private class GhoulDoppelGangerServerAchievement : BaseServerAchievement { private BodyIndex bodyIndex; public override void OnInstall() { //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) ((BaseServerAchievement)this).OnInstall(); bodyIndex = BodyCatalog.FindBodyIndex("VcrGhoulBody"); GlobalEventManager.onCharacterDeathGlobal += OnCharacterDeath; } public override void OnUninstall() { GlobalEventManager.onCharacterDeathGlobal -= OnCharacterDeath; ((BaseServerAchievement)this).OnUninstall(); } private void OnCharacterDeath(DamageReport damageReport) { //IL_0017: 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) if (Object.op_Implicit((Object)(object)damageReport.victimBody) && damageReport.victimBody.bodyIndex == bodyIndex && ((BaseServerAchievement)this).IsCurrentBody(damageReport.attackerBody)) { ((BaseServerAchievement)this).Grant(); } } } public const string identifier = "VCR_GHOUL_unravelAchievement"; public const string unlockableIdentifier = "VCR_GHOUL_unravelAchievement"; public override BodyIndex LookUpRequiredBodyIndex() { //IL_0006: Unknown result type (might be due to invalid IL or missing references) //IL_000b: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) return BodyCatalog.FindBodyIndex("VcrGhoulBody"); } public override void OnBodyRequirementMet() { ((BaseAchievement)this).OnBodyRequirementMet(); ((BaseAchievement)this).SetServerTracked(true); } public override void OnBodyRequirementBroken() { ((BaseAchievement)this).SetServerTracked(false); ((BaseAchievement)this).OnBodyRequirementBroken(); } } [RegisterAchievement("VCR_GHOUL_grandMasteryAchievement", "VCR_GHOUL_grandMasteryUnlockable", null, 10u, null)] public class GhoulGrandmasteryAchievement : BaseMasteryAchievement { public const string identifier = "VCR_GHOUL_grandMasteryAchievement"; public const string unlockableIdentifier = "VCR_GHOUL_grandMasteryUnlockable"; public override string RequiredCharacterBody => CharacterBase.instance.bodyName; public override float RequiredDifficultyCoefficient => 3.5f; } [RegisterAchievement("VCR_GHOUL_frenzyKillAchievement", "VCR_GHOUL_frenzyKillAchievement", null, 3u, typeof(GhoulKillFrenzyServerAchievement))] public class GhoulKillFrenzyAchievement : BaseAchievement { private class GhoulKillFrenzyServerAchievement : BaseServerAchievement { private int killCount; private float stopwatch = 0f; public override void OnInstall() { ((BaseServerAchievement)this).OnInstall(); RoR2Application.onFixedUpdate += OnFixedUpdate; GlobalEventManager.onCharacterDeathGlobal += OnCharacterDeath; } public override void OnUninstall() { GlobalEventManager.onCharacterDeathGlobal -= OnCharacterDeath; RoR2Application.onFixedUpdate -= OnFixedUpdate; ((BaseServerAchievement)this).OnUninstall(); } private void OnFixedUpdate() { if (stopwatch > 0f) { stopwatch -= Time.fixedDeltaTime; } else { killCount = 0; } } private void OnCharacterDeath(DamageReport damageReport) { //IL_0027: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Invalid comparison between Unknown and I4 if (Object.op_Implicit((Object)(object)damageReport.attackerBody) && ((BaseServerAchievement)this).IsCurrentBody(damageReport.attackerBody) && (int)damageReport.damageInfo.damageType.damageSource == 8 && Object.op_Implicit((Object)(object)((Component)damageReport.attackerBody).GetComponent()) && !((Component)damageReport.attackerBody).GetComponent().isEnraged) { if (stopwatch <= 0f) { stopwatch = 11f; } killCount++; if (requirement <= killCount && stopwatch > 0f) { ((BaseServerAchievement)this).Grant(); ((BaseServerAchievement)this).ServerTryToCompleteActivity(); } } } } public const string identifier = "VCR_GHOUL_frenzyKillAchievement"; public const string unlockableIdentifier = "VCR_GHOUL_frenzyKillAchievement"; private static readonly int requirement = 6; public override BodyIndex LookUpRequiredBodyIndex() { //IL_0006: Unknown result type (might be due to invalid IL or missing references) //IL_000b: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) return BodyCatalog.FindBodyIndex("VcrGhoulBody"); } public override void OnBodyRequirementMet() { ((BaseAchievement)this).OnBodyRequirementMet(); ((BaseAchievement)this).SetServerTracked(true); } public override void OnBodyRequirementBroken() { ((BaseAchievement)this).SetServerTracked(false); ((BaseAchievement)this).OnBodyRequirementBroken(); } public override void TryToCompleteActivity() { //IL_0026: Unknown result type (might be due to invalid IL or missing references) //IL_002c: Expected O, but got Unknown if (((BaseAchievement)this).localUser.id == LocalUserManager.GetFirstLocalUser().id && base.shouldGrant) { BaseActivitySelector val = new BaseActivitySelector(); val.activityAchievementID = "VCR_GHOUL_frenzyKillAchievement"; PlatformSystems.activityManager.TryToCompleteActivity(val, true, true); } } } [RegisterAchievement("VCR_GHOUL_massiveBlockAchievement", "VCR_GHOUL_massiveBlockAchievement", null, 3u, typeof(GhoulMassiveBlockServerAchievement))] public class GhoulMassiveBlockAchievement : BaseAchievement { private class GhoulMassiveBlockServerAchievement : BaseServerAchievement { public override void OnInstall() { //IL_000f: Unknown result type (might be due to invalid IL or missing references) //IL_0019: Expected O, but got Unknown ((BaseServerAchievement)this).OnInstall(); HealthComponent.TakeDamage += new hook_TakeDamage(HealthComponent_TakeDamage); } private void HealthComponent_TakeDamage(orig_TakeDamage orig, HealthComponent self, DamageInfo damageInfo) { if (Object.op_Implicit((Object)(object)((Component)self).GetComponent()) && ((BaseServerAchievement)this).IsCurrentBody(((Component)self).gameObject) && ((Component)self).GetComponent().HasBuff(GhoulBuffs.blockBuff)) { if (!Object.op_Implicit((Object)(object)((Component)self).GetComponent())) { return; } if (requirement <= ((Component)self).GetComponent().blockedDamage) { ((BaseServerAchievement)this).Grant(); ((BaseServerAchievement)this).ServerTryToCompleteActivity(); } } orig.Invoke(self, damageInfo); } public override void OnUninstall() { //IL_0008: Unknown result type (might be due to invalid IL or missing references) //IL_0012: Expected O, but got Unknown HealthComponent.TakeDamage -= new hook_TakeDamage(HealthComponent_TakeDamage); ((BaseServerAchievement)this).OnUninstall(); } } public const string identifier = "VCR_GHOUL_massiveBlockAchievement"; public const string unlockableIdentifier = "VCR_GHOUL_massiveBlockAchievement"; private static readonly float requirement = 1000f; public override BodyIndex LookUpRequiredBodyIndex() { //IL_0006: Unknown result type (might be due to invalid IL or missing references) //IL_000b: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) return BodyCatalog.FindBodyIndex("VcrGhoulBody"); } public override void OnBodyRequirementMet() { ((BaseAchievement)this).OnBodyRequirementMet(); ((BaseAchievement)this).SetServerTracked(true); } public override void OnBodyRequirementBroken() { ((BaseAchievement)this).SetServerTracked(false); ((BaseAchievement)this).OnBodyRequirementBroken(); } public override void TryToCompleteActivity() { //IL_0026: Unknown result type (might be due to invalid IL or missing references) //IL_002c: Expected O, but got Unknown if (((BaseAchievement)this).localUser.id == LocalUserManager.GetFirstLocalUser().id && base.shouldGrant) { BaseActivitySelector val = new BaseActivitySelector(); val.activityAchievementID = "VCR_GHOUL_massiveBlockAchievement"; PlatformSystems.activityManager.TryToCompleteActivity(val, true, true); } } } [RegisterAchievement("VCR_GHOUL_masteryAchievement", "VCR_GHOUL_masteryUnlockable", null, 10u, null)] public class GhoulMasteryAchievement : BaseMasteryAchievement { public const string identifier = "VCR_GHOUL_masteryAchievement"; public const string unlockableIdentifier = "VCR_GHOUL_masteryUnlockable"; public override string RequiredCharacterBody => CharacterBase.instance.bodyName; public override float RequiredDifficultyCoefficient => 3f; } [RegisterAchievement("VCR_GHOUL_speedrunAchievement", "VCR_GHOUL_speedrunAchievement", null, 3u, null)] public class GhoulSpeedrunAchievement : BaseAchievement { public const string identifier = "VCR_GHOUL_speedrunAchievement"; public const string unlockableIdentifier = "VCR_GHOUL_speedrunAchievement"; private SceneDef requiredSceneDef = SceneCatalog.GetSceneDefFromSceneName("moon2"); private float addedTime = 60f; private float thresholdTime; private float timer { get { float num = 0f; if (Object.op_Implicit((Object)(object)Run.instance)) { num = Run.instance.GetRunStopwatch(); } return num - thresholdTime; } } private bool passed => timer <= 0f; public override BodyIndex LookUpRequiredBodyIndex() { //IL_0006: Unknown result type (might be due to invalid IL or missing references) //IL_000b: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) return BodyCatalog.FindBodyIndex("VcrGhoulBody"); } private bool CheckMoonScene() { bool result = false; if ((Object)(object)SceneCatalog.mostRecentSceneDef == (Object)(object)requiredSceneDef) { result = true; } return result; } private void OnReachedState(orig_Start orig, SceneDirector self) { if (CheckMoonScene()) { thresholdTime = timer + addedTime; } orig.Invoke(self); } public override void OnBodyRequirementMet() { //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 PreEncounter.OnEnter += new hook_OnEnter(PreEncounter_OnEnter); SceneDirector.Start += new hook_Start(OnReachedState); } public override void OnBodyRequirementBroken() { //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 PreEncounter.OnEnter -= new hook_OnEnter(PreEncounter_OnEnter); SceneDirector.Start -= new hook_Start(OnReachedState); } private void PreEncounter_OnEnter(orig_OnEnter orig, PreEncounter self) { if (passed) { ((BaseAchievement)this).Grant(); } orig.Invoke(self); } } }