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 System.Text; using BepInEx; using BepInEx.Bootstrap; using BepInEx.Configuration; using BepInEx.Logging; using EnemiesReturns.Enemies.Judgement; using EnemiesReturns.Enemies.LynxTribe; using EnemiesReturns.Enemies.MechanicalSpider; using EntityStates; using EntityStates.Barrel; using EntityStates.Bell.BellWeapon; using EntityStates.BrotherMonster; using EntityStates.Croco; using EntityStates.DroneCombiner; using EntityStates.DroneScrapper; using EntityStates.FalseSonBoss; using EntityStates.Interactables.GoldBeacon; using EntityStates.Loader; using EntityStates.MealPrep; using EntityStates.Merc; using EntityStates.Merc.Weapon; using EntityStates.MeridianEvent; using EntityStates.Missions.AccessCodes.Node; using EntityStates.Missions.Arena.NullWard; using EntityStates.Missions.BrotherEncounter; using EntityStates.Missions.GeodeSecretMission; using EntityStates.Missions.Moon; using EntityStates.QuestVolatileBattery; using EntityStates.Scrapper; using EntityStates.ShrineHalcyonite; using EntityStates.SolusWing2; using EntityStates.Toolbot; using EntityStates.VoidRaidCrab; using EntityStates.VoidSurvivor.Weapon; using HG; using HG.Reflection; using IL.EntityStates.Bell.BellWeapon; using IL.EntityStates.Merc; using IL.EntityStates.Merc.Weapon; using IL.RoR2; using IL.RoR2.UI; using IL.RoR2.UI.LogBook; using ItemQualities; using Microsoft.CodeAnalysis; using Mono.Cecil.Cil; using MonoMod.Cil; using On; using On.EntityStates.Barrel; using On.EntityStates.BrotherMonster; using On.EntityStates.Croco; using On.EntityStates.DroneCombiner; using On.EntityStates.DroneScrapper; using On.EntityStates.FalseSonBoss; using On.EntityStates.Interactables.GoldBeacon; using On.EntityStates.Loader; using On.EntityStates.MealPrep; using On.EntityStates.Merc; using On.EntityStates.Merc.Weapon; using On.EntityStates.Missions.AccessCodes.Node; using On.EntityStates.Missions.Arena.NullWard; using On.EntityStates.Missions.BrotherEncounter; using On.EntityStates.Missions.GeodeSecretMission; using On.EntityStates.Missions.Moon; using On.EntityStates.QuestVolatileBattery; using On.EntityStates.Scrapper; using On.EntityStates.ShrineHalcyonite; using On.EntityStates.SolusWing2; using On.EntityStates.Toolbot; using On.EntityStates.VoidRaidCrab; using On.EntityStates.VoidSurvivor.Weapon; using On.RoR2; using On.RoR2.CharacterAI; using On.RoR2.UI; using On.RoR2.UI.LogBook; using On.RoR2.UI.MainMenu; using ProperSave; using R2API; using R2API.Utils; using RiskOfOptions; using RiskOfOptions.OptionConfigs; using RiskOfOptions.Options; using RoR2; using RoR2.Artifacts; using RoR2.CharacterAI; using RoR2.ConVar; using RoR2.ContentManagement; using RoR2.EntitlementManagement; using RoR2.ExpansionManagement; using RoR2.Hologram; using RoR2.Items; using RoR2.Networking; using RoR2.Orbs; using RoR2.Projectile; using RoR2.Skills; using RoR2.Stats; using RoR2.UI; using RoR2.UI.LogBook; using RoR2.UI.MainMenu; using SS2; using SS2.Components; using TMPro; using TPDespair.ZetAspects; using ThreeEyedGames; using UnityEngine; using UnityEngine.AddressableAssets; using UnityEngine.EventSystems; using UnityEngine.Events; using UnityEngine.Networking; using UnityEngine.Rendering; using UnityEngine.Rendering.PostProcessing; using UnityEngine.UI; using WolfoLibrary; using WolfoQoL_Client.DeathScreen; using WolfoQoL_Client.Menu; using WolfoQoL_Client.ModSupport; using WolfoQoL_Client.Reminders; using WolfoQoL_Client.Skins; using WolfoQoL_Client.Text; using vanillaVoid.Interactables; using vanillaVoid.Items; [assembly: CompilationRelaxations(8)] [assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)] [assembly: Debuggable(DebuggableAttribute.DebuggingModes.Default | DebuggableAttribute.DebuggingModes.DisableOptimizations | DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints | DebuggableAttribute.DebuggingModes.EnableEditAndContinue)] [assembly: OptIn] [assembly: TargetFramework(".NETStandard,Version=v2.1", FrameworkDisplayName = ".NET Standard 2.1")] [assembly: AssemblyCompany("WolfoQoL_Client")] [assembly: AssemblyConfiguration("Debug")] [assembly: AssemblyFileVersion("1.0.0.0")] [assembly: AssemblyInformationalVersion("1.0.0+785c975fb2625db9ea82ba60d8d21db880c87e83")] [assembly: AssemblyProduct("WolfoQoL_Client")] [assembly: AssemblyTitle("WolfoQoL_Client")] [assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)] [assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)] [assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)] [assembly: AssemblyVersion("1.0.0.0")] [module: UnverifiableCode] [module: RefSafetyRules(11)] [module: UnverifiableCode] [module: UnverifiableCode] namespace Microsoft.CodeAnalysis { [CompilerGenerated] [Microsoft.CodeAnalysis.Embedded] internal sealed class EmbeddedAttribute : Attribute { } } namespace System.Runtime.CompilerServices { [CompilerGenerated] [Microsoft.CodeAnalysis.Embedded] [AttributeUsage(AttributeTargets.Module, AllowMultiple = false, Inherited = false)] internal sealed class RefSafetyRulesAttribute : Attribute { public readonly int Version; public RefSafetyRulesAttribute(int P_0) { Version = P_0; } } } namespace WolfoQoL_Client { public static class Assets { [CompilerGenerated] private static class <>O { public static hook_SetFolders <0>__SetFolders; } public static AssetBundle Bundle; public static PluginInfo PluginInfo; public static string Folder = "QualityOfLife\\"; internal static string assemblyDir => Path.GetDirectoryName(PluginInfo.Location); public static Sprite Load(string s) { return Bundle.LoadAsset("Assets/WQoL/PingIcons/" + s + ".png"); } internal static void Init(PluginInfo info) { //IL_00ce: Unknown result type (might be due to invalid IL or missing references) //IL_00d3: Unknown result type (might be due to invalid IL or missing references) //IL_00d9: Expected O, but got Unknown PluginInfo = info; if (!Directory.Exists(GetPathToFile(Folder))) { Folder = "plugins\\" + Folder; } if (Directory.Exists(GetPathToFile(Folder + "AssetBundles"))) { Bundle = AssetBundle.LoadFromFile(GetPathToFile(Folder + "AssetBundles", "wolfoqualityoflife")); Bundle.LoadAllAssets(); } else { Debug.LogError((object)"COULD NOT FIND ASSETBUNDLES FOLDER"); } if (WConfig.cfgTestDisableMod.Value) { return; } if (Directory.Exists(GetPathToFile(Folder + "Languages"))) { object obj = <>O.<0>__SetFolders; if (obj == null) { hook_SetFolders val = SetFolders; <>O.<0>__SetFolders = val; obj = (object)val; } Language.SetFolders += (hook_SetFolders)obj; } else { Debug.LogError((object)"COULD NOT FIND LANGUAGES FOLDER"); } } private static void SetFolders(orig_SetFolders orig, Language self, IEnumerable newFolders) { IEnumerable second = Directory.EnumerateDirectories(Path.Combine(GetPathToFile(Folder + "Languages")), self.name); orig.Invoke(self, newFolders.Union(second)); } internal static string GetPathToFile(string folderName) { return Path.Combine(assemblyDir, folderName); } internal static string GetPathToFile(string folderName, string fileName) { return Path.Combine(GetPathToFile(folderName), fileName); } } public static class ClientChecks { [CompilerGenerated] private static class <>O { public static hook_Start <0>__AddClientListeners; public static hook_SetBodyPrefabToPreference <1>__PlayerCharacterMasterController_SetBodyPrefabToPreference; public static hook_OnDeserialize <2>__ClientCheck_Multishop; public static hook_OnEnter <3>__ScrapperBaseState_OnEnter; public static hook_OnEnter <4>__ScrappingDroneMessage_Client; public static Manipulator <5>__ClientCheck_Purchase; public static Manipulator <6>__Inventory_OnDeserialize; public static hook_OnDisable <7>__EquipmentDrone_ForceMessage; } public static void Start() { //IL_0011: 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_001c: Expected O, but got Unknown //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Unknown result type (might be due to invalid IL or missing references) //IL_003d: Expected O, but got Unknown //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_005e: Expected O, but got Unknown //IL_0074: Unknown result type (might be due to invalid IL or missing references) //IL_0079: Unknown result type (might be due to invalid IL or missing references) //IL_007f: Expected O, but got Unknown //IL_0095: 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_00a0: Expected O, but got Unknown //IL_00b6: Unknown result type (might be due to invalid IL or missing references) //IL_00bb: Unknown result type (might be due to invalid IL or missing references) //IL_00c1: Expected O, but got Unknown //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_00e2: Expected O, but got Unknown //IL_00f8: Unknown result type (might be due to invalid IL or missing references) //IL_00fd: Unknown result type (might be due to invalid IL or missing references) //IL_0103: Expected O, but got Unknown object obj = <>O.<0>__AddClientListeners; if (obj == null) { hook_Start val = AddClientListeners; <>O.<0>__AddClientListeners = val; obj = (object)val; } PlayerCharacterMasterController.Start += (hook_Start)obj; object obj2 = <>O.<1>__PlayerCharacterMasterController_SetBodyPrefabToPreference; if (obj2 == null) { hook_SetBodyPrefabToPreference val2 = PlayerCharacterMasterController_SetBodyPrefabToPreference; <>O.<1>__PlayerCharacterMasterController_SetBodyPrefabToPreference = val2; obj2 = (object)val2; } PlayerCharacterMasterController.SetBodyPrefabToPreference += (hook_SetBodyPrefabToPreference)obj2; object obj3 = <>O.<2>__ClientCheck_Multishop; if (obj3 == null) { hook_OnDeserialize val3 = ClientCheck_Multishop; <>O.<2>__ClientCheck_Multishop = val3; obj3 = (object)val3; } MultiShopController.OnDeserialize += (hook_OnDeserialize)obj3; object obj4 = <>O.<3>__ScrapperBaseState_OnEnter; if (obj4 == null) { hook_OnEnter val4 = ScrapperBaseState_OnEnter; <>O.<3>__ScrapperBaseState_OnEnter = val4; obj4 = (object)val4; } ScrapperBaseState.OnEnter += (hook_OnEnter)obj4; object obj5 = <>O.<4>__ScrappingDroneMessage_Client; if (obj5 == null) { hook_OnEnter val5 = ScrappingDroneMessage_Client; <>O.<4>__ScrappingDroneMessage_Client = val5; obj5 = (object)val5; } DroneScrapperBaseState.OnEnter += (hook_OnEnter)obj5; object obj6 = <>O.<5>__ClientCheck_Purchase; if (obj6 == null) { Manipulator val6 = ClientCheck_Purchase; <>O.<5>__ClientCheck_Purchase = val6; obj6 = (object)val6; } PurchaseInteraction.OnDeserialize += (Manipulator)obj6; object obj7 = <>O.<6>__Inventory_OnDeserialize; if (obj7 == null) { Manipulator val7 = Inventory_OnDeserialize; <>O.<6>__Inventory_OnDeserialize = val7; obj7 = (object)val7; } Inventory.OnDeserialize += (Manipulator)obj7; object obj8 = <>O.<7>__EquipmentDrone_ForceMessage; if (obj8 == null) { hook_OnDisable val8 = EquipmentDrone_ForceMessage; <>O.<7>__EquipmentDrone_ForceMessage = val8; obj8 = (object)val8; } SummonMasterBehavior.OnDisable += (hook_OnDisable)obj8; } private static void ScrappingDroneMessage_Client(orig_OnEnter orig, DroneScrapperBaseState self) { orig.Invoke(self); if (!NetworkServer.active && self is DroneScrapping) { DroneLoss_ClientListener.SendMessage(); } } private static void PlayerCharacterMasterController_SetBodyPrefabToPreference(orig_SetBodyPrefabToPreference orig, PlayerCharacterMasterController self) { orig.Invoke(self); ItemLossBase_ClientListener itemLossBase_ClientListener = default(ItemLossBase_ClientListener); if (((Component)self).TryGetComponent(ref itemLossBase_ClientListener)) { itemLossBase_ClientListener.subjectAsNetworkUser = self.networkUser; } } private static void EquipmentDrone_ForceMessage(orig_OnDisable orig, SummonMasterBehavior self) { //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002a: Invalid comparison between Unknown and I4 orig.Invoke(self); if (self.callOnEquipmentSpentOnPurchase) { PurchaseInteraction component = ((Component)self).GetComponent(); if (Object.op_Implicit((Object)(object)component) && (int)component.costType == 7) { PlayerItemLoss_ClientListener.forceEquip = true; PlayerItemLoss_ClientListener.token = "ITEM_LOSS_GENERIC"; ItemLossBase_ClientListener.TryMessage(); } } } private static void ClientCheck_Purchase(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown //IL_006d: Unknown result type (might be due to invalid IL or missing references) ILCursor val = new ILCursor(il); val.TryGotoNext((MoveType)0, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchStfld(x, "RoR2.PurchaseInteraction", "available") }); if (val.TryGotoNext((MoveType)0, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchStfld(x, "RoR2.PurchaseInteraction", "available") })) { val.Emit(OpCodes.Ldarg_0); val.EmitDelegate>((Func)delegate(bool t, PurchaseInteraction pur) { if (!t) { CheckInteractable_ClientOnly(pur, isMulti: false); } return t; }); } else { Log.LogWarning("IL Failed : PurchaseInteraction_OnDeserialize"); } } private static void Inventory_OnDeserialize(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown ILCursor val = new ILCursor(il); if (val.TryGotoNext((MoveType)0, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchLdflda(x, "RoR2.Inventory", "permanentItemStacks") })) { val.EmitDelegate>((Func)delegate(Inventory inventory) { //IL_0022: Unknown result type (might be due to invalid IL or missing references) //IL_0027: Unknown result type (might be due to invalid IL or missing references) PlayerItemLoss_ClientListener playerItemLoss_ClientListener2 = default(PlayerItemLoss_ClientListener); if (((Component)inventory).TryGetComponent(ref playerItemLoss_ClientListener2)) { inventory.WriteAllPermanentItemStacks((Span)playerItemLoss_ClientListener2.prevItems); playerItemLoss_ClientListener2.prevEquip = inventory.currentEquipmentIndex; } return inventory; }); } else { Log.LogWarning("IL Failed : Inventory_OnDeserialize 1"); } val.TryGotoNext((MoveType)0, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchStfld(x, "RoR2.Inventory", "equipmentDisabled") }); if (val.TryGotoNext((MoveType)2, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchLdarg(x, 0) })) { val.EmitDelegate>((Func)delegate(Inventory inventory) { //IL_0010: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) PlayerItemLoss_ClientListener playerItemLoss_ClientListener = default(PlayerItemLoss_ClientListener); if (((Component)inventory).TryGetComponent(ref playerItemLoss_ClientListener)) { playerItemLoss_ClientListener.prevEquip = inventory.currentEquipmentIndex; } return inventory; }); } else { Log.LogWarning("IL Failed : Inventory_OnDeserialize 2"); } } private static void ScrapperBaseState_OnEnter(orig_OnEnter orig, ScrapperBaseState self) { orig.Invoke(self); if (!NetworkServer.active && self is WaitToBeginScrapping) { PlayerItemLoss_ClientListener.source = ItemLossMessage.Source.Scrapper; ItemLossBase_ClientListener.TryMessage(); } } public static void AddClientListeners(orig_Start orig, PlayerCharacterMasterController self) { orig.Invoke(self); ((Component)self).gameObject.AddComponent(); if (!WQoLMain.HostHasMod) { ((Component)self).gameObject.AddComponent(); ((Component)self).gameObject.AddComponent(); } } private static void ClientCheck_Multishop(orig_OnDeserialize orig, MultiShopController self, NetworkReader reader, bool initialState) { bool available = self.available; orig.Invoke(self, reader, initialState); if (available && !self.available && ((Object)self).name.StartsWith("FreeChestMultiShop")) { CheckInteractable_ClientOnly(null, isMulti: true); } } public static void CheckInteractable_ClientOnly(PurchaseInteraction purchase, bool isMulti) { //IL_0051: 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_0058: 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_0099: Expected I4, but got Unknown if (isMulti) { if (Object.op_Implicit((Object)(object)TreasureReminder.instance.Objective_FreeChest)) { TreasureReminder.Deduct(TreasureReminder.instance.Objective_FreeChest, ref TreasureReminder.instance.freeChestCount); } return; } if (purchase.saleStarCompatible) { PlayerItemLoss_ClientListener.TrySaleStar(purchase); } CostTypeIndex costType = purchase.costType; CostTypeIndex val = costType; switch ((int)val) { case 4: case 5: case 6: case 10: if (((Object)((Component)purchase).gameObject).name.StartsWith("LunarCauldron")) { PlayerItemLoss_ClientListener.source = ItemLossMessage.Source.LunarCauldron; PlayerItemLoss_ClientListener.token = "ITEM_LOSS_CAULDRON"; } else { PlayerItemLoss_ClientListener.token = "ITEM_LOSS_GENERIC"; } ItemLossBase_ClientListener.TryMessage(); break; case 7: PlayerItemLoss_ClientListener.checkEquip = true; PlayerItemLoss_ClientListener.token = "ITEM_LOSS_GENERIC"; ItemLossBase_ClientListener.TryMessage(); break; case 9: PlayerItemLoss_ClientListener.checkEquip = true; PlayerItemLoss_ClientListener.source = ItemLossMessage.Source.CleansingPool; PlayerItemLoss_ClientListener.token = "ITEM_LOSS_CLEANSING"; ItemLossBase_ClientListener.TryMessage(); break; case 12: if (Object.op_Implicit((Object)(object)TreasureReminder.instance)) { TreasureReminder.Deduct(TreasureReminder.instance.Objective_Lockbox, ref TreasureReminder.instance.lockboxCount); } break; case 13: if (Object.op_Implicit((Object)(object)TreasureReminder.instance)) { TreasureReminder.Deduct(TreasureReminder.instance.Objective_LockboxVoid, ref TreasureReminder.instance.lockboxVoidCount); } break; case 0: break; case 1: case 2: case 3: case 8: case 11: break; } } } public class KillerInfo_ClientListener : MonoBehaviour { [CompilerGenerated] private sealed class d__8 : IEnumerator, IEnumerator, IDisposable { private int <>1__state; private object <>2__current; public KillerInfo_ClientListener <>4__this; object IEnumerator.Current { [DebuggerHidden] get { return <>2__current; } } object IEnumerator.Current { [DebuggerHidden] get { return <>2__current; } } [DebuggerHidden] public d__8(int <>1__state) { this.<>1__state = <>1__state; } [DebuggerHidden] void IDisposable.Dispose() { <>1__state = -2; } private bool MoveNext() { //IL_0026: Unknown result type (might be due to invalid IL or missing references) //IL_0030: Expected O, but got Unknown switch (<>1__state) { default: return false; case 0: <>1__state = -1; <>2__current = (object)new WaitForSeconds(0.3f); <>1__state = 1; return true; case 1: <>1__state = -1; <>4__this.SendMessage(); <>4__this.latestDmg = null; return false; } } bool IEnumerator.MoveNext() { //ILSpy generated this explicit interface implementation from .override directive in MoveNext return this.MoveNext(); } [DebuggerHidden] void IEnumerator.Reset() { throw new NotSupportedException(); } } public GameObject playerBodyObject; public CharacterBody charBody; public CharacterMaster playerMaster; public UnityAction deathEvent; public bool killed = false; private DamageDealtMessage latestDmg; public void OnEnable() { //IL_0083: Unknown result type (might be due to invalid IL or missing references) //IL_008d: Expected O, but got Unknown if (WQoLMain.HostHasMod) { Log.LogMessage("Host has mod, removing Client Workaround : KillerInfo_ClientListener"); Object.Destroy((Object)(object)this); return; } PlayerCharacterMasterController component = ((Component)this).GetComponent(); if (!((Object)(object)component == (Object)null)) { GlobalEventManager.onClientDamageNotified += onClientDamageNotified; playerMaster = component.master; playerMaster.onBodyStart += Master_onBodyStart; if (deathEvent == null) { deathEvent = new UnityAction(OnBodyDeath); playerMaster.onBodyDeath.AddListener(deathEvent); } } } public void OnDisable() { if (deathEvent != null) { playerMaster.onBodyDeath.RemoveListener(deathEvent); } playerMaster.onBodyStart -= Master_onBodyStart; GlobalEventManager.onClientDamageNotified -= onClientDamageNotified; } public void SendMessage() { //IL_00f5: Unknown result type (might be due to invalid IL or missing references) //IL_0100: Unknown result type (might be due to invalid IL or missing references) if (latestDmg == null) { return; } if (charBody.healthComponent.alive) { Log.LogMessage("KillerInfo_ClientListener | Sending message but is Alive?" + (object)charBody); } if (killed) { Log.LogMessage("KillerInfo_ClientListener | Already sent message, how are they dying again?" + (object)charBody); return; } killed = true; string bestBodyName = Util.GetBestBodyName(latestDmg.attacker); CharacterMaster attackerMaster = null; CharacterBody val = null; if (Object.op_Implicit((Object)(object)latestDmg.attacker)) { val = latestDmg.attacker.GetComponent(); if (Object.op_Implicit((Object)(object)val)) { attackerMaster = val.master; } } DeathMessage.DeathAndKillerInventoryMessage(latestDmg.damage, charBody, val, attackerMaster, latestDmg.damageType, latestDmg.damageColorIndex, latestDmg.delayedHit, sendOverNetwork: false); } [IteratorStateMachine(typeof(d__8))] public IEnumerator Delay_DeathMessage() { //yield-return decompiler failed: Unexpected instruction in Iterator.Dispose() return new d__8(0) { <>4__this = this }; } private void Master_onBodyStart(CharacterBody obj) { //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_0056: Unknown result type (might be due to invalid IL or missing references) killed = false; playerBodyObject = ((Component)obj).gameObject; charBody = obj; if (obj.isRemoteOp && WConfig.DroneMessage_RemoteOp.Value) { DroneChatMessage obj2 = new DroneChatMessage { baseToken = "REMOTEOP_DRONE", _DroneIndex = DroneCatalog.GetDroneIndexFromBodyIndex(obj.bodyIndex) }; ((SubjectChatMessage)obj2).subjectAsNetworkUser = playerMaster.playerCharacterMasterController.networkUser; Chat.AddMessage((ChatMessageBase)(object)obj2); } } private void OnBodyDeath() { ((MonoBehaviour)this).StartCoroutine(Delay_DeathMessage()); if (WConfig.cfgTestClient.Value) { SendMessage(); killed = false; } } private void onClientDamageNotified(DamageDealtMessage dmg) { if ((Object)(object)dmg.victim == (Object)(object)playerBodyObject) { latestDmg = dmg; } } } public class ItemLossBase_ClientListener : MonoBehaviour { public static ItemLossBase_ClientListener latest; public Inventory inventory; public NetworkUser subjectAsNetworkUser; public int[] prevItems = ItemCatalog.RequestItemStackArray(); public EquipmentIndex prevEquip = (EquipmentIndex)(-1); public virtual void OnEnable() { if (WQoLMain.HostHasMod) { Log.LogMessage("Host has mod, removing Client Workaround : ItemLoss_ClientListener"); Object.Destroy((Object)(object)this); } else { inventory = ((Component)this).GetComponent(); inventory.onInventoryChanged += Inventory_onInventoryChanged; } } public virtual void OnDisable() { if (Object.op_Implicit((Object)(object)inventory)) { inventory.onInventoryChanged -= Inventory_onInventoryChanged; } } public virtual void Inventory_onInventoryChanged() { latest = this; } public static void TryMessage() { if ((Object)(object)latest != (Object)null) { latest.TryMessageInstance(); } } public virtual void TryMessageInstance() { } } public class DevotionItemLoss_ClientListener : ItemLossBase_ClientListener { public override void OnEnable() { base.OnEnable(); CharacterMaster summonerMaster = ((Component)this).GetComponent().SummonerMaster; if ((Object)(object)summonerMaster == (Object)null) { Log.LogWarning("DevotionItemLoss Client Listener null Summoner Master"); } subjectAsNetworkUser = summonerMaster.playerCharacterMasterController.networkUser; } public override void Inventory_onInventoryChanged() { //IL_000f: Unknown result type (might be due to invalid IL or missing references) base.Inventory_onInventoryChanged(); SingleItemLoss(inventory.permanentItemStacks); } public bool SingleItemLoss(ItemCollection now) { //IL_005c: Unknown result type (might be due to invalid IL or missing references) //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_00a6: Unknown result type (might be due to invalid IL or missing references) //IL_00ab: Unknown result type (might be due to invalid IL or missing references) //IL_00b0: Unknown result type (might be due to invalid IL or missing references) bool flag = false; int num = -1; int pickupQuantity = -1; for (int i = 0; i < prevItems.Length; i++) { if (prevItems[i] > ((ItemCollection)(ref now)).GetStackValue((ItemIndex)i)) { flag = true; num = i; pickupQuantity = prevItems[i] - ((ItemCollection)(ref now)).GetStackValue((ItemIndex)i); break; } } if (flag) { PickupIndex val = PickupCatalog.FindPickupIndex((ItemIndex)num); PickupDef pickupDef = ((PickupIndex)(ref val)).pickupDef; Log.LogMessage(pickupDef.internalName); DevotionDeathMessage devotionDeathMessage = new DevotionDeathMessage(); ((SubjectChatMessage)devotionDeathMessage).subjectAsNetworkUser = subjectAsNetworkUser; ((SubjectChatMessage)devotionDeathMessage).baseToken = "DEVOTED_LEMURIAN_DEATH"; ((PlayerPickupChatMessage)devotionDeathMessage).pickupToken = pickupDef.nameToken; ((PlayerPickupChatMessage)devotionDeathMessage).pickupColor = Color32.op_Implicit(pickupDef.baseColor); ((PlayerPickupChatMessage)devotionDeathMessage).pickupQuantity = (uint)pickupQuantity; Chat.AddMessage((ChatMessageBase)(object)devotionDeathMessage); } inventory.WriteAllPermanentItemStacks((Span)prevItems); return flag; } } public class DroneLoss_ClientListener : MonoBehaviour { public static NetworkUser lastDroneOwner; public static GameObject lastDeadDrone; public static int tier; public void OnDisable() { lastDroneOwner = ((Component)this).GetComponent().ownerMaster.playerCharacterMasterController.networkUser; lastDeadDrone = ((Component)this).GetComponent().bodyPrefab; tier = ((Component)this).GetComponent().GetItemCountPermanent(Items.DroneUpgradeHidden); } public static void SendMessage() { //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_005c: Unknown result type (might be due to invalid IL or missing references) //IL_0061: Unknown result type (might be due to invalid IL or missing references) if (!((Object)(object)lastDroneOwner == (Object)null) && !((Object)(object)lastDeadDrone == (Object)null)) { ItemLossMessage obj = new ItemLossMessage { source = ItemLossMessage.Source.DroneScrapper, baseToken = "ITEM_LOSS_SCRAP", itemCount = tier, pickupIndexOnlyOneItem = PickupCatalog.FindPickupIndex(DroneCatalog.GetDroneIndexFromBodyIndex(lastDeadDrone.GetComponent().bodyIndex)) }; ((SubjectChatMessage)obj).subjectAsNetworkUser = lastDroneOwner; Chat.AddMessage((ChatMessageBase)(object)obj); } } } public class PlayerItemLoss_ClientListener : ItemLossBase_ClientListener { public static bool forceEquip = false; public static bool checkEquip = false; public static bool checkSaleStar = false; public static string token = "ITEM_LOSS_GENERIC"; public static ItemLossMessage.Source source; public void Start() { subjectAsNetworkUser = ((Component)this).GetComponent().networkUser; } public override void Inventory_onInventoryChanged() { base.Inventory_onInventoryChanged(); if (forceEquip) { ItemLossBase_ClientListener.TryMessage(); } } public static void TrySaleStar(PurchaseInteraction purchase) { //IL_0030: Unknown result type (might be due to invalid IL or missing references) //IL_0036: Expected I4, but got Unknown if (WConfig.cfgMessagesSaleStar.Value && (Object)(object)ItemLossBase_ClientListener.latest != (Object)null) { int num = (int)Items.LowerPricedChests.itemIndex; int num2 = ItemLossBase_ClientListener.latest.prevItems[num]; int itemCountEffective = ItemLossBase_ClientListener.latest.inventory.GetItemCountEffective((ItemIndex)num); Log.LogMessage("SaleStar " + num2 + " " + itemCountEffective); if (num2 > 0 && itemCountEffective == 0) { ItemLossBase_ClientListener.latest.prevItems[num] = 0; InteractableMessage obj = new InteractableMessage { interactableToken = purchase.displayNameToken }; ((SubjectChatMessage)obj).subjectAsNetworkUser = ItemLossBase_ClientListener.latest.subjectAsNetworkUser; Chat.AddMessage((ChatMessageBase)(object)obj); } } } public override void TryMessageInstance() { //IL_001e: 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_003d: Invalid comparison between Unknown and I4 //IL_006d: Unknown result type (might be due to invalid IL or missing references) //IL_0073: Invalid comparison between Unknown and I4 //IL_004b: Unknown result type (might be due to invalid IL or missing references) //IL_0050: Unknown result type (might be due to invalid IL or missing references) //IL_0091: Unknown result type (might be due to invalid IL or missing references) base.TryMessageInstance(); bool flag = false; if (source == ItemLossMessage.Source.Scrapper) { flag = ItemScrapMessage(inventory.permanentItemStacks); } else if (!forceEquip) { flag = ((!checkEquip || (int)inventory.currentEquipmentIndex != -1) ? ItemMessage(inventory.permanentItemStacks) : EquipmentMessage()); } else { if ((int)prevEquip == -1) { prevEquip = inventory.currentEquipmentIndex; } flag = EquipmentMessage(); } if (!flag) { } forceEquip = false; checkEquip = false; source = ItemLossMessage.Source.Default; } public bool ItemScrapMessage(ItemCollection now) { //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) if (!WConfig.cfgMessageScrap.Value) { return false; } bool flag = false; int num = -1; int itemCount = -1; for (int i = 0; i < prevItems.Length; i++) { if (prevItems[i] > ((ItemCollection)(ref now)).GetStackValue((ItemIndex)i)) { flag = true; num = i; itemCount = prevItems[i] - ((ItemCollection)(ref now)).GetStackValue((ItemIndex)i); break; } } if (flag) { ItemLossMessage obj = new ItemLossMessage { source = ItemLossMessage.Source.Scrapper, baseToken = "ITEM_LOSS_SCRAP" }; ((SubjectChatMessage)obj).subjectAsNetworkUser = subjectAsNetworkUser; obj.pickupIndexOnlyOneItem = PickupCatalog.FindPickupIndex((ItemIndex)num); obj.itemCount = itemCount; Chat.AddMessage((ChatMessageBase)(object)obj); } inventory.WriteAllPermanentItemStacks((Span)prevItems); return flag; } public bool ItemMessage(ItemCollection now) { //IL_00c9: Unknown result type (might be due to invalid IL or missing references) //IL_00ce: Unknown result type (might be due to invalid IL or missing references) int[] array = ItemCatalog.RequestItemStackArray(); int num = 0; int num2 = -1; for (int i = 0; i < prevItems.Length; i++) { if (prevItems[i] > ((ItemCollection)(ref now)).GetStackValue((ItemIndex)i)) { num++; num2 = i; array[i] = prevItems[i] - ((ItemCollection)(ref now)).GetStackValue((ItemIndex)i); } } if (num == 1) { if (token != "ITEM_LOSS_CAULDRON") { ItemDef itemDef = ItemCatalog.GetItemDef((ItemIndex)num2); if (itemDef.ContainsTag((ItemTag)10)) { token = "ITEM_LOSS_USED"; } } ItemLossMessage obj = new ItemLossMessage { source = source, baseToken = token }; ((SubjectChatMessage)obj).subjectAsNetworkUser = subjectAsNetworkUser; obj.pickupIndexOnlyOneItem = PickupCatalog.FindPickupIndex((ItemIndex)num2); Chat.AddMessage((ChatMessageBase)(object)obj); } else if (num > 0) { ItemLossMessage obj2 = new ItemLossMessage { baseToken = token }; ((SubjectChatMessage)obj2).subjectAsNetworkUser = subjectAsNetworkUser; obj2.itemStacks = array; Chat.AddMessage((ChatMessageBase)(object)obj2); } inventory.WriteAllPermanentItemStacks((Span)prevItems); return num > 0; } public bool EquipmentMessage() { //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_000f: Unknown result type (might be due to invalid IL or missing references) //IL_0011: Invalid comparison between Unknown and I4 //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_0022: Invalid comparison between Unknown and I4 //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_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_0045: Unknown result type (might be due to invalid IL or missing references) //IL_0074: Unknown result type (might be due to invalid IL or missing references) //IL_0079: Unknown result type (might be due to invalid IL or missing references) bool result = false; EquipmentIndex currentEquipmentIndex = inventory.currentEquipmentIndex; if ((int)currentEquipmentIndex == -1) { currentEquipmentIndex = prevEquip; } if ((int)currentEquipmentIndex != -1) { result = true; ItemLossMessage obj = new ItemLossMessage { baseToken = token, pickupIndexOnlyOneItem = PickupCatalog.FindPickupIndex(currentEquipmentIndex) }; ((SubjectChatMessage)obj).subjectAsNetworkUser = subjectAsNetworkUser; Chat.AddMessage((ChatMessageBase)(object)obj); } else { Log.LogWarning("EquipmentMessage but without Equipment?"); } prevEquip = inventory.currentEquipmentIndex; return result; } } public struct AllyDef { public ItemTier tier; public float desiredSortPosition; public ColorIndex colorOverride; public Texture bgTextureOverride; public ExpansionDef requiredExpansion; } public static class AllyCatalog { [CompilerGenerated] private static class <>O { public static hook_DroneBody <0>__PageBuilder_DroneBody; } public static Dictionary AllyDefs; public static void Make() { //IL_0012: 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_002a: Unknown result type (might be due to invalid IL or missing references) //IL_0036: Unknown result type (might be due to invalid IL or missing references) //IL_00b4: 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_00e7: 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_0126: Unknown result type (might be due to invalid IL or missing references) //IL_0142: Unknown result type (might be due to invalid IL or missing references) //IL_0159: 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_018c: Unknown result type (might be due to invalid IL or missing references) //IL_01a8: Unknown result type (might be due to invalid IL or missing references) //IL_01bf: Unknown result type (might be due to invalid IL or missing references) //IL_01db: Unknown result type (might be due to invalid IL or missing references) //IL_01fe: Unknown result type (might be due to invalid IL or missing references) //IL_021a: Unknown result type (might be due to invalid IL or missing references) //IL_0223: Unknown result type (might be due to invalid IL or missing references) //IL_024b: Unknown result type (might be due to invalid IL or missing references) //IL_0267: Unknown result type (might be due to invalid IL or missing references) //IL_0270: Unknown result type (might be due to invalid IL or missing references) //IL_0298: Unknown result type (might be due to invalid IL or missing references) //IL_02b5: Unknown result type (might be due to invalid IL or missing references) //IL_02d8: Unknown result type (might be due to invalid IL or missing references) //IL_02f5: Unknown result type (might be due to invalid IL or missing references) //IL_0318: Unknown result type (might be due to invalid IL or missing references) //IL_0335: Unknown result type (might be due to invalid IL or missing references) //IL_035e: Unknown result type (might be due to invalid IL or missing references) //IL_0363: Unknown result type (might be due to invalid IL or missing references) //IL_0369: Expected O, but got Unknown Debug.Log((object)"AllyCatalog"); DroneDefs.BackupDrone.colorOverride = (ColorIndex)5; DroneDefs.DTGunnerDrone.colorOverride = (ColorIndex)12; DroneDefs.DTHealDrone.colorOverride = (ColorIndex)12; DroneDefs.DTHaulerDrone.colorOverride = (ColorIndex)12; bool flag = Chainloader.PluginInfos.ContainsKey("prodzpod.RealerCheatUnlocks"); if (AllyDefs != null) { return; } AllyDefs = new Dictionary(); if (!(!WConfig.Logbook_AllyExpansion.Value || flag)) { if (Language.currentLanguage.TokenIsRegistered("LOGBOOK_CATEGORY_DRONE_AND_ALLIES")) { LanguageAPI.Add("LOGBOOK_CATEGORY_DRONE", Language.GetString("LOGBOOK_CATEGORY_DRONE_AND_ALLIES")); } AllyDefs.Add(BodyPrefabs.SquidTurretBody.bodyIndex, new AllyDef { desiredSortPosition = 200f, tier = (ItemTier)1 }); AllyDefs.Add(BodyPrefabs.FriendUnitBody.bodyIndex, new AllyDef { desiredSortPosition = 200f, tier = (ItemTier)2, requiredExpansion = DLCS.DLC3 }); AllyDefs.Add(BodyPrefabs.BeetleGuardAllyBody.bodyIndex, new AllyDef { desiredSortPosition = 1f, tier = (ItemTier)4 }); AllyDefs.Add(BodyPrefabs.RoboBallRedBuddyBody.bodyIndex, new AllyDef { desiredSortPosition = 2f, tier = (ItemTier)4 }); AllyDefs.Add(BodyPrefabs.RoboBallGreenBuddyBody.bodyIndex, new AllyDef { desiredSortPosition = 2f, tier = (ItemTier)4 }); AllyDefs.Add(BodyPrefabs.MinorConstructOnKillBody.bodyIndex, new AllyDef { desiredSortPosition = 3f, tier = (ItemTier)4, requiredExpansion = DLCS.DLC1 }); AllyDefs.Add(BodyPrefabs.EngiTurretBody.bodyIndex, new AllyDef { desiredSortPosition = 30f, tier = (ItemTier)6, colorOverride = (ColorIndex)12, bgTextureOverride = LegacyResourcesAPI.Load("Textures/ItemIcons/BG/texSurvivorBGIcon") }); AllyDefs.Add(BodyPrefabs.EngiWalkerTurretBody.bodyIndex, new AllyDef { desiredSortPosition = 31f, tier = (ItemTier)6, colorOverride = (ColorIndex)12, bgTextureOverride = LegacyResourcesAPI.Load("Textures/ItemIcons/BG/texSurvivorBGIcon") }); AllyDefs.Add(BodyPrefabs.NullifierAllyBody.bodyIndex, new AllyDef { desiredSortPosition = 3f, tier = (ItemTier)9, requiredExpansion = DLCS.DLC1 }); AllyDefs.Add(BodyPrefabs.VoidJailerAllyBody.bodyIndex, new AllyDef { desiredSortPosition = 3f, tier = (ItemTier)9, requiredExpansion = DLCS.DLC1 }); AllyDefs.Add(BodyPrefabs.VoidMegaCrabAllyBody.bodyIndex, new AllyDef { desiredSortPosition = 3f, tier = (ItemTier)9, requiredExpansion = DLCS.DLC1 }); object obj = <>O.<0>__PageBuilder_DroneBody; if (obj == null) { hook_DroneBody val = PageBuilder_DroneBody; <>O.<0>__PageBuilder_DroneBody = val; obj = (object)val; } PageBuilder.DroneBody += (hook_DroneBody)obj; } } private static void PageBuilder_DroneBody(orig_DroneBody orig, PageBuilder builder) { //IL_000c: Unknown result type (might be due to invalid IL or missing references) //IL_0012: Expected O, but got Unknown //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_001e: Invalid comparison between Unknown and I4 CharacterBody val = (CharacterBody)builder.entry.extraData; if ((int)DroneCatalog.GetDroneIndexFromBodyIndex(val.bodyIndex) == -1) { string text = ((Object)val).name.Replace("Body", "_SKILL_DESCRIPTION").ToUpper(); if (Language.english.TokenIsRegistered(text)) { builder.AddDescriptionPanel(Language.GetString(text)); } builder.AddSimpleBody(val); builder.AddDronePanel(val); builder.AddBodyLore(val); } else { orig.Invoke(builder); } } public static bool CanSelectDroneEntry(AllyDef allyDef, Dictionary expansionAvailability) { ExpansionDef requiredExpansion = allyDef.requiredExpansion; return !Object.op_Implicit((Object)(object)requiredExpansion) || !expansionAvailability.ContainsKey(requiredExpansion) || expansionAvailability[requiredExpansion]; } public static EntryStatus GetAllyStatus(in Entry entry, UserProfile viewerProfile) { //IL_0020: 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_0042: Unknown result type (might be due to invalid IL or missing references) //IL_003e: Unknown result type (might be due to invalid IL or missing references) //IL_0045: Unknown result type (might be due to invalid IL or missing references) if (viewerProfile == null) { return (EntryStatus)3; } if (viewerProfile.statSheet.GetStatValueULong(PerBodyStatDef.timesSummoned, ((Object)((Component)(CharacterBody)entry.extraData).gameObject).name) != 0) { return (EntryStatus)4; } return (EntryStatus)3; } public static ItemTier TierFromBodyDroneOrAlly(CharacterBody body) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0007: Unknown result type (might be due to invalid IL or missing references) //IL_000c: Unknown result type (might be due to invalid IL or missing references) //IL_000d: Unknown result type (might be due to invalid IL or missing references) //IL_000f: Invalid comparison between Unknown and I4 //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0019: Unknown result type (might be due to invalid IL or missing references) //IL_001f: 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_004a: Unknown result type (might be due to invalid IL or missing references) //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_0046: Unknown result type (might be due to invalid IL or missing references) //IL_004d: Unknown result type (might be due to invalid IL or missing references) DroneIndex droneIndexFromBodyIndex = DroneCatalog.GetDroneIndexFromBodyIndex(body.bodyIndex); if ((int)droneIndexFromBodyIndex != -1) { return DroneCatalog.GetDroneDef(droneIndexFromBodyIndex).tier; } if (AllyDefs.TryGetValue(body.bodyIndex, out var value)) { return value.tier; } return (ItemTier)0; } public static float SortFromBodyDroneOrAlly(CharacterBody body) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0007: Unknown result type (might be due to invalid IL or missing references) //IL_000c: Unknown result type (might be due to invalid IL or missing references) //IL_000d: Unknown result type (might be due to invalid IL or missing references) //IL_000f: Invalid comparison between Unknown and I4 //IL_002d: 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) DroneIndex droneIndexFromBodyIndex = DroneCatalog.GetDroneIndexFromBodyIndex(body.bodyIndex); if ((int)droneIndexFromBodyIndex != -1) { return DroneCatalog.GetDroneDef(droneIndexFromBodyIndex).desiredSortPosition; } if (AllyDefs.TryGetValue(body.bodyIndex, out var value)) { return value.desiredSortPosition; } return 0f; } } public static class Logbook_MoreStats { [CompilerGenerated] private static class <>O { public static hook_AddBodyStatsPanel <0>__PageBuilder_AddBodyStatsPanel; public static hook_AddMonsterPanel <1>__ExtraMonsterStats; public static hook_AddSurvivorPanel <2>__PageBuilder_AddSurvivorPanel; public static hook_SurvivorBody <3>__PageBuilder_SurvivorBody; public static hook_AddStagePanel <4>__PageBuilder_AddStagePanel1; } public static void MoreStats() { //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_0022: Expected O, but got Unknown //IL_0038: Unknown result type (might be due to invalid IL or missing references) //IL_003d: Unknown result type (might be due to invalid IL or missing references) //IL_0043: Expected O, but got Unknown //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005e: Unknown result type (might be due to invalid IL or missing references) //IL_0064: Expected O, but got Unknown //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_0085: Expected O, but got Unknown //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_00a6: Expected O, but got Unknown Logbook_AddRecipes.Add(); object obj = <>O.<0>__PageBuilder_AddBodyStatsPanel; if (obj == null) { hook_AddBodyStatsPanel val = PageBuilder_AddBodyStatsPanel; <>O.<0>__PageBuilder_AddBodyStatsPanel = val; obj = (object)val; } PageBuilder.AddBodyStatsPanel += (hook_AddBodyStatsPanel)obj; object obj2 = <>O.<1>__ExtraMonsterStats; if (obj2 == null) { hook_AddMonsterPanel val2 = ExtraMonsterStats; <>O.<1>__ExtraMonsterStats = val2; obj2 = (object)val2; } PageBuilder.AddMonsterPanel += (hook_AddMonsterPanel)obj2; object obj3 = <>O.<2>__PageBuilder_AddSurvivorPanel; if (obj3 == null) { hook_AddSurvivorPanel val3 = PageBuilder_AddSurvivorPanel; <>O.<2>__PageBuilder_AddSurvivorPanel = val3; obj3 = (object)val3; } PageBuilder.AddSurvivorPanel += (hook_AddSurvivorPanel)obj3; object obj4 = <>O.<3>__PageBuilder_SurvivorBody; if (obj4 == null) { hook_SurvivorBody val4 = PageBuilder_SurvivorBody; <>O.<3>__PageBuilder_SurvivorBody = val4; obj4 = (object)val4; } PageBuilder.SurvivorBody += (hook_SurvivorBody)obj4; object obj5 = <>O.<4>__PageBuilder_AddStagePanel1; if (obj5 == null) { hook_AddStagePanel val5 = PageBuilder_AddStagePanel1; <>O.<4>__PageBuilder_AddStagePanel1 = val5; obj5 = (object)val5; } PageBuilder.AddStagePanel += (hook_AddStagePanel)obj5; } private static void PageBuilder_AddStagePanel1(orig_AddStagePanel orig, PageBuilder self, SceneDef sceneDef) { string @string = Language.GetString(sceneDef.subtitleToken); if (@string.Length != 0) { self.AddSimpleTextPanel(" " + @string + " "); } orig.Invoke(self, sceneDef); } private static void PageBuilder_SurvivorBody(orig_SurvivorBody orig, PageBuilder builder) { //IL_0014: Unknown result type (might be due to invalid IL or missing references) //IL_001a: Expected O, but got Unknown //IL_0020: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(builder); CharacterBody val = (CharacterBody)builder.entry.extraData; SurvivorDef survivorDef = SurvivorCatalog.GetSurvivorDef(SurvivorCatalog.bodyIndexToSurvivorIndex[val.bodyIndex]); string text = string.Empty; bool flag = false; if (!string.IsNullOrEmpty(survivorDef.outroFlavorToken)) { flag = true; text = text + Language.GetString(survivorDef.outroFlavorToken) + "\n"; } if (!string.IsNullOrEmpty(survivorDef.mainEndingEscapeFailureFlavorToken)) { flag = true; text = text + Language.GetString(survivorDef.mainEndingEscapeFailureFlavorToken) + "\n"; } if (flag) { builder.AddSimpleTextPanel(text); } } private static void PageBuilder_AddStagePanel(orig_AddStagePanel orig, PageBuilder self, SceneDef sceneDef) { orig.Invoke(self, sceneDef); TextMeshProUGUI component = ((Component)self.managedObjects.Last().GetComponent().FindChild("MainLabel")).GetComponent(); } private static void PageBuilder_AddSimplePickup(orig_AddSimplePickup orig, PageBuilder self, PickupIndex pickupIndex) { //IL_0003: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self, pickupIndex); TextMeshProUGUI component = ((Component)self.managedObjects[self.managedObjects.Count - 2].GetComponent().FindChild("MainLabel")).GetComponent(); } public static string TimeHHMMSSDisplayValueFormatter(double time2) { ulong num = (ulong)time2; ulong num2 = num / 3600; ulong num3 = (num - num2 * 3600) / 60; ulong num4 = num - num2 * 3600 - num3 * 60; return $"{num2:00}:{num3:00}:{num4:00}"; } private static void PageBuilder_AddSurvivorPanel(orig_AddSurvivorPanel orig, PageBuilder self, CharacterBody bodyPrefabComponent) { orig.Invoke(self, bodyPrefabComponent); string text = TimeHHMMSSDisplayValueFormatter(self.statSheet.GetStatValueDouble(PerBodyStatDef.totalTimeAlive, ((Object)((Component)bodyPrefabComponent).gameObject).name)); TextMeshProUGUI component = ((Component)self.managedObjects.Last().GetComponent().FindChild("MainLabel")).GetComponent(); string empty = string.Empty; string name = ((Object)((Component)bodyPrefabComponent).gameObject).name; empty += StatMethod(PerBodyStatDef.totalWins, name, self.statSheet); empty = empty + Language.GetString("PERBODYSTATNAME_TOTALTIMEALIVE") + ": " + text + "\n"; empty += ((TMP_Text)component).text; empty += StatMethod(PerBodyStatDef.killsAs, name, self.statSheet); empty += StatMethod(PerBodyStatDef.damageDealtAs, name, self.statSheet); empty += StatMethod(PerBodyStatDef.damageTakenAs, name, self.statSheet); empty += StatMethod(PerBodyStatDef.deathsAs, name, self.statSheet); ((TMP_Text)component).text = empty; } public static string StatMethod(PerBodyStatDef statDef, string bodyName, StatSheet self) { return Language.GetString(statDef.nameToken) + ": " + TextSerialization.ToStringNumeric(self.GetStatValueULong(statDef, bodyName)) + "\n"; } private static void ExtraMonsterStats(orig_AddMonsterPanel orig, PageBuilder self, CharacterBody bodyPrefabComponent) { orig.Invoke(self, bodyPrefabComponent); string name = ((Object)((Component)bodyPrefabComponent).gameObject).name; TextMeshProUGUI component = ((Component)self.managedObjects.Last().GetComponent().FindChild("MainLabel")).GetComponent(); string empty = string.Empty; empty += StatMethod(PerBodyStatDef.damageDealtTo, name, self.statSheet); empty += ((TMP_Text)component).text; empty += "\n"; empty += StatMethod(PerBodyStatDef.damageTakenFrom, name, self.statSheet); ((TMP_Text)component).text = empty; } private static void PageBuilder_AddBodyStatsPanel(orig_AddBodyStatsPanel orig, PageBuilder self, CharacterBody bodyPrefabComponent) { if (self.managedObjects.Count == 0 && bodyPrefabComponent.subtitleNameToken.Length != 0) { self.AddSimpleTextPanel(" " + Language.GetString(bodyPrefabComponent.subtitleNameToken) + " "); } orig.Invoke(self, bodyPrefabComponent); } } public static class LogbookStuff { [CompilerGenerated] private static class <>O { public static hook_BuildMonsterEntries <0>__AddMissingMonsters; public static hook_BuildMonsterEntries <1>__SortBossMonster; public static hook_BuildPickupEntries <2>__AddMissingEquipment; public static Manipulator <3>__SortBossEquip2; public static hook_BuildSurvivorEntries <4>__SurvivorEntryColor; public static hook_GetPickupStatus <5>__EliteEquipmentViewable; public static Action <6>__Add; } public static void Start() { //IL_0011: 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_001c: Expected O, but got Unknown //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Unknown result type (might be due to invalid IL or missing references) //IL_003d: Expected O, but got Unknown //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_005e: Expected O, but got Unknown //IL_0074: Unknown result type (might be due to invalid IL or missing references) //IL_0079: Unknown result type (might be due to invalid IL or missing references) //IL_007f: Expected O, but got Unknown //IL_0095: 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_00a0: Expected O, but got Unknown //IL_00b6: Unknown result type (might be due to invalid IL or missing references) //IL_00bb: Unknown result type (might be due to invalid IL or missing references) //IL_00c1: Expected O, but got Unknown //IL_00fe: Unknown result type (might be due to invalid IL or missing references) //IL_0103: Unknown result type (might be due to invalid IL or missing references) //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_019c: Unknown result type (might be due to invalid IL or missing references) //IL_01a1: Unknown result type (might be due to invalid IL or missing references) //IL_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_01ce: Unknown result type (might be due to invalid IL or missing references) //IL_01d3: Unknown result type (might be due to invalid IL or missing references) object obj = <>O.<0>__AddMissingMonsters; if (obj == null) { hook_BuildMonsterEntries val = AddMissingMonsters; <>O.<0>__AddMissingMonsters = val; obj = (object)val; } LogBookController.BuildMonsterEntries += (hook_BuildMonsterEntries)obj; object obj2 = <>O.<1>__SortBossMonster; if (obj2 == null) { hook_BuildMonsterEntries val2 = SortBossMonster; <>O.<1>__SortBossMonster = val2; obj2 = (object)val2; } LogBookController.BuildMonsterEntries += (hook_BuildMonsterEntries)obj2; object obj3 = <>O.<2>__AddMissingEquipment; if (obj3 == null) { hook_BuildPickupEntries val3 = AddMissingEquipment; <>O.<2>__AddMissingEquipment = val3; obj3 = (object)val3; } LogBookController.BuildPickupEntries += (hook_BuildPickupEntries)obj3; object obj4 = <>O.<3>__SortBossEquip2; if (obj4 == null) { Manipulator val4 = SortBossEquip2; <>O.<3>__SortBossEquip2 = val4; obj4 = (object)val4; } LogBookController.BuildPickupEntries += (Manipulator)obj4; object obj5 = <>O.<4>__SurvivorEntryColor; if (obj5 == null) { hook_BuildSurvivorEntries val5 = SurvivorEntryColor; <>O.<4>__SurvivorEntryColor = val5; obj5 = (object)val5; } LogBookController.BuildSurvivorEntries += (hook_BuildSurvivorEntries)obj5; object obj6 = <>O.<5>__EliteEquipmentViewable; if (obj6 == null) { hook_GetPickupStatus val6 = EliteEquipmentViewable; <>O.<5>__EliteEquipmentViewable = val6; obj6 = (object)val6; } LogBookController.GetPickupStatus += (hook_GetPickupStatus)obj6; Logbook_Allies.MoreStats(); Logbook_MoreStats.MoreStats(); ((ResourceAvailability)(ref SceneCatalog.availability)).CallWhenAvailable((Action)LogSimuStages.Add); Addressables.LoadAssetAsync((object)"RoR2/DLC2/meridian/meridian.asset").WaitForCompletion().stageOrder = 80; LegacyResourcesAPI.Load("SceneDefs/goldshores").stageOrder = 81; LegacyResourcesAPI.Load("SceneDefs/bazaar").stageOrder = 90; LegacyResourcesAPI.Load("SceneDefs/arena").stageOrder = 91; LegacyResourcesAPI.Load("SceneDefs/voidstage").stageOrder = 92; Addressables.LoadAssetAsync((object)"RoR2/DLC1/voidraid/voidraid.asset").WaitForCompletion().stageOrder = 93; LegacyResourcesAPI.Load("SceneDefs/mysteryspace").stageOrder = 150; LegacyResourcesAPI.Load("SceneDefs/limbo").stageOrder = 151; Addressables.LoadAssetAsync((object)"808fe615086cfa042baf950436b1da20").WaitForCompletion().stageOrder = 95; Addressables.LoadAssetAsync((object)"55dcf3dbd137f99458af33ad467bb574").WaitForCompletion().stageOrder = 96; Addressables.LoadAssetAsync((object)"5272c5e76a99aa046b72ad8fb941974c").WaitForCompletion().stageOrder = 97; } private static void SortBossEquip2(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown ILCursor val = new ILCursor(il); if (val.TryGotoNext((MoveType)0, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchStloc(x, 1) })) { val.EmitDelegate, IEnumerable>>((Func, IEnumerable>)((IEnumerable entries) => entries.OrderBy((Entry entry) => EquipmentCatalog.GetEquipmentDef(PickupCatalog.GetPickupDef((PickupIndex)entry.extraData).equipmentIndex).isBoss))); } else { Log.LogWarning("IL Failed: SortBossEquip2"); } } private static EntryStatus EliteEquipmentViewable(orig_GetPickupStatus orig, ref Entry entry, UserProfile viewerProfile) { //IL_0004: 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_000c: Invalid comparison between Unknown and I4 //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_002a: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0016: Unknown result type (might be due to invalid IL or missing references) //IL_0038: Unknown result type (might be due to invalid IL or missing references) //IL_0171: Unknown result type (might be due to invalid IL or missing references) //IL_003d: 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_0040: Invalid comparison between Unknown and I4 //IL_016c: Unknown result type (might be due to invalid IL or missing references) //IL_016d: Unknown result type (might be due to invalid IL or missing references) //IL_004f: 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_008d: 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_0124: Invalid comparison between Unknown and I4 //IL_0167: Unknown result type (might be due to invalid IL or missing references) //IL_0161: Unknown result type (might be due to invalid IL or missing references) EntryStatus val = orig.Invoke(ref entry, viewerProfile); if ((int)val == 4) { return val; } PickupIndex val2 = (PickupIndex)entry.extraData; PickupDef pickupDef = PickupCatalog.GetPickupDef(val2); EquipmentIndex val3 = (EquipmentIndex)((pickupDef == null) ? (-1) : ((int)pickupDef.equipmentIndex)); if ((int)val3 != -1) { EquipmentDef equipmentDef = EquipmentCatalog.GetEquipmentDef(val3); if (Object.op_Implicit((Object)(object)equipmentDef.passiveBuffDef) && equipmentDef.passiveBuffDef.isElite) { if (viewerProfile.HasDiscoveredPickup(val2)) { return (EntryStatus)4; } bool flag = false; if ((Object)(object)equipmentDef == (Object)(object)Equipment.AffixLunar) { flag = viewerProfile.HasUnlockable(Items.LunarBadLuck.unlockableDef); } else if ((Object)(object)equipmentDef == (Object)(object)Equipment.EliteVoidEquipment) { flag = viewerProfile.HasAchievement("Characters.VoidSurvivor"); } else if ((Object)(object)equipmentDef == (Object)(object)Equipment.EliteAurelioniteEquipment) { flag = viewerProfile.HasUnlockable(Equipment.HealAndRevive.unlockableDef); } else { EliteDef eliteDef = equipmentDef.passiveBuffDef.eliteDef; flag = (((int)eliteDef.devotionLevel != 2) ? viewerProfile.HasUnlockable(Survivors.Captain.unlockableDef) : viewerProfile.HasUnlockable(Items.Clover.unlockableDef)); } if (flag) { return (EntryStatus)4; } return (EntryStatus)3; } } return val; } private static Entry[] SortBossMonster(orig_BuildMonsterEntries orig, Dictionary expansionAvailability) { if (!WConfig.Logbook_SortBosses.Value) { return orig.Invoke(expansionAvailability); } Entry[] array = orig.Invoke(expansionAvailability); List list = new List(); List list2 = new List(); for (int i = 0; i < array.Length; i++) { object extraData = array[i].extraData; if (((CharacterBody)((extraData is CharacterBody) ? extraData : null)).isChampion) { list2.Add(array[i]); } else { list.Add(array[i]); } } list.AddRange(list2); return list.ToArray(); } public static Entry[] AddMissingMonsters(orig_BuildMonsterEntries orig, Dictionary expansionAvailability) { if (WConfig.Logbook_More.Value) { UnlockableDef logUnlockableDef = ((Component)BodyPrefabs.GupBody).GetComponent().logUnlockableDef; ((Component)BodyPrefabs.GeepBody).GetComponent().logUnlockableDef = logUnlockableDef; ((Component)BodyPrefabs.GipBody).GetComponent().logUnlockableDef = logUnlockableDef; UnlockableDef logUnlockableDef2 = ((Component)BodyPrefabs.MinePodBody).GetComponent().logUnlockableDef; ((Component)BodyPrefabs.SolusMineBody).GetComponent().logUnlockableDef = logUnlockableDef2; BodyPrefabs.ScavLunar1Body.baseNameToken = "SCAVLUNAR_BODY_SUBTITLE"; ((Component)BodyPrefabs.ScavLunar1Body).GetComponent().logUnlockableDef = LegacyResourcesAPI.Load("UnlockableDefs/Logs.Stages.limbo"); } if (WConfig.Logbook_WeirdoEnemies.Value) { UnlockableDef logUnlockableDef3 = ((Component)BodyPrefabs.SolusAmalgamatorBody).GetComponent().logUnlockableDef; ((Component)BodyPrefabs.SolusAmalgamatorFlamethrowerCannonBody).GetComponent().logUnlockableDef = logUnlockableDef3; ((Component)BodyPrefabs.SolusAmalgamatorMissilePodBody).GetComponent().logUnlockableDef = logUnlockableDef3; ((Component)BodyPrefabs.SolusAmalgamatorThrusterBody).GetComponent().logUnlockableDef = logUnlockableDef3; UnlockableDef logUnlockableDef4 = LegacyResourcesAPI.Load("unlockabledefs/Items.Clover"); UnityObjectExtensions.EnsureComponent(LegacyResourcesAPI.Load("Prefabs/CharacterBodies/UrchinTurretBody")).logUnlockableDef = logUnlockableDef4; } Entry[] result = orig.Invoke(expansionAvailability); BodyPrefabs.ScavLunar1Body.baseNameToken = "SCAVLUNAR1_BODY_NAME"; return result; } public static Entry[] AddMissingEquipment(orig_BuildPickupEntries orig, Dictionary expansionAvailability) { Equipment.EliteGoldEquipment.dropOnDeathChance = 0f; List list = new List(); if (!WQoLMain.ZetAspects && WConfig.Logbook_EliteEquip.Value) { for (int i = 0; i < EliteCatalog.eliteDefs.Length; i++) { EquipmentDef eliteEquipmentDef = EliteCatalog.eliteDefs[i].eliteEquipmentDef; if (Object.op_Implicit((Object)(object)eliteEquipmentDef) && eliteEquipmentDef.dropOnDeathChance != 0f) { list.Add(eliteEquipmentDef); } } } if (WConfig.Logbook_More.Value) { list.Add(Equipment.QuestVolatileBattery); list.Add(Equipment.BossHunterConsumed); list.Add(Equipment.HealAndReviveConsumed); } for (int j = 0; j < list.Count; j++) { list[j].canDrop = true; } Entry[] result = orig.Invoke(expansionAvailability); for (int k = 0; k < list.Count; k++) { list[k].canDrop = false; } return result; } public static Entry[] SurvivorEntryColor(orig_BuildSurvivorEntries orig, Dictionary expansionAvailability) { //IL_0011: 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) Entry[] array = orig.Invoke(expansionAvailability); for (int i = 0; i < array.Length; i++) { array[i].color = ColorModule.NewSurvivorLogbookNameColor; } return array; } } public static class Logbook_AddRecipes { [CompilerGenerated] private static class <>O { public static hook_AddSimplePickup <0>__AddRecipe; public static hook_PopulateRecipes <1>__RemoveUnneededCycleImages; public static hook_PopulateImages <2>__RemoveDuplicateRecipes; public static hook_PopulateImages <3>__RecipeStrip_PopulateImages; public static hook_SetEntry <4>__LogBookPage_SetEntry; } public static void Add() { //IL_0028: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0049: Unknown result type (might be due to invalid IL or missing references) //IL_004e: Unknown result type (might be due to invalid IL or missing references) //IL_0054: Expected O, but got Unknown //IL_006a: Unknown result type (might be due to invalid IL or missing references) //IL_006f: Unknown result type (might be due to invalid IL or missing references) //IL_0075: Expected O, but got Unknown //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_00d5: Unknown result type (might be due to invalid IL or missing references) //IL_008b: Unknown result type (might be due to invalid IL or missing references) //IL_0090: Unknown result type (might be due to invalid IL or missing references) //IL_0096: Expected O, but got Unknown //IL_011e: Unknown result type (might be due to invalid IL or missing references) //IL_0123: Unknown result type (might be due to invalid IL or missing references) //IL_0129: Expected O, but got Unknown if (WConfig.Logbook_Recipes.Value) { object obj = <>O.<0>__AddRecipe; if (obj == null) { hook_AddSimplePickup val = AddRecipe; <>O.<0>__AddRecipe = val; obj = (object)val; } PageBuilder.AddSimplePickup += (hook_AddSimplePickup)obj; object obj2 = <>O.<1>__RemoveUnneededCycleImages; if (obj2 == null) { hook_PopulateRecipes val2 = RemoveUnneededCycleImages; <>O.<1>__RemoveUnneededCycleImages = val2; obj2 = (object)val2; } RecipeInfoContainer.PopulateRecipes += (hook_PopulateRecipes)obj2; object obj3 = <>O.<2>__RemoveDuplicateRecipes; if (obj3 == null) { hook_PopulateImages val3 = RemoveDuplicateRecipes; <>O.<2>__RemoveDuplicateRecipes = val3; obj3 = (object)val3; } RecipeDisplay.PopulateImages += (hook_PopulateImages)obj3; object obj4 = <>O.<3>__RecipeStrip_PopulateImages; if (obj4 == null) { hook_PopulateImages val4 = RecipeStrip_PopulateImages; <>O.<3>__RecipeStrip_PopulateImages = val4; obj4 = (object)val4; } RecipeStrip.PopulateImages += (hook_PopulateImages)obj4; GameObject val5 = Addressables.LoadAssetAsync((object)"RoR2/DLC3/UI/RecipeDisplayUpdated.prefab").WaitForCompletion(); ((Transform)val5.GetComponentInChildren().recipeStripPrefab).GetChild(1).GetChild(0).localPosition = new Vector3(-20f, 0f, 0f); CyclingImage[] componentsInChildren = val5.GetComponentsInChildren(); foreach (CyclingImage val6 in componentsInChildren) { val6.beatBetweenSwaps = 0.8f; } object obj5 = <>O.<4>__LogBookPage_SetEntry; if (obj5 == null) { hook_SetEntry val7 = LogBookPage_SetEntry; <>O.<4>__LogBookPage_SetEntry = val7; obj5 = (object)val7; } LogBookPage.SetEntry += (hook_SetEntry)obj5; } } private static void LogBookPage_SetEntry(orig_SetEntry orig, LogBookPage self, UserProfile userProfile, Entry entry) { orig.Invoke(self, userProfile, entry); ((Component)((Transform)self.pageBuilder.container).parent.parent.GetChild(1)).gameObject.SetActive(true); ((Component)((Transform)self.pageBuilder.container).parent.parent.parent).GetComponent().SetDirty(); } public static void RecipeStrip_PopulateNew(RecipeStrip self, PickupIndex itemRecipesFor, bool usedIn) { //IL_0014: Unknown result type (might be due to invalid IL or missing references) //IL_0019: Unknown result type (might be due to invalid IL or missing references) //IL_0031: Unknown result type (might be due to invalid IL or missing references) //IL_0055: Unknown result type (might be due to invalid IL or missing references) //IL_014e: Unknown result type (might be due to invalid IL or missing references) //IL_00bc: Unknown result type (might be due to invalid IL or missing references) //IL_00c1: Unknown result type (might be due to invalid IL or missing references) //IL_00c4: 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_019c: Unknown result type (might be due to invalid IL or missing references) //IL_01a1: Unknown result type (might be due to invalid IL or missing references) //IL_01b7: Unknown result type (might be due to invalid IL or missing references) //IL_01c5: 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_01d3: Unknown result type (might be due to invalid IL or missing references) //IL_01dc: Unknown result type (might be due to invalid IL or missing references) PickupIndex value = self.recipe.possibleIngredients[0].pickups[0]; bool flag = ((ReadOnlySpan)self.recipe.possibleIngredients[0].pickups).IndexOf(value) != -1; bool flag2 = ((ReadOnlySpan)self.recipe.possibleIngredients[1].pickups).IndexOf(value) != -1; bool flag3 = false; for (int i = 0; i < self.recipe.possibleIngredients.Length; i++) { RectTransform val = Object.Instantiate(self.imagePrefab); ((Component)val).gameObject.SetActive(true); ((Transform)val).parent = (Transform)(object)self.ingredientContainer; List list = new List(); PickupIndex[] pickups = self.recipe.possibleIngredients[i].pickups; foreach (PickupIndex val2 in pickups) { if (PickupAvailable(val2)) { list.Add(val2); } } flag3 = flag3 || list.Count == 0; ((Component)val).GetComponent().SetSpritesFromPickupIndices(list.ToArray()); } if (!((Object)(object)self.resultIcon != (Object)null)) { return; } PickupDef pickupDef = PickupCatalog.GetPickupDef(self.recipe.result); if (pickupDef != null) { self.resultIcon.sprite = pickupDef.iconSprite; } if ((Object)(object)self.resultBackground != (Object)null) { Image[] componentsInChildren = ((Component)self.resultBackground).GetComponentsInChildren(); Color darkColor = pickupDef.darkColor; Image[] array = componentsInChildren; foreach (Image val3 in array) { float a = ((Graphic)val3).color.a; ((Graphic)val3).color = new Color(darkColor.r, darkColor.g, darkColor.b, a); } } } private static void RecipeStrip_PopulateImages(orig_PopulateImages orig, RecipeStrip self) { //IL_0070: Unknown result type (might be due to invalid IL or missing references) //IL_0077: Expected O, but got Unknown //IL_00df: Unknown result type (might be due to invalid IL or missing references) if (((Component)self).transform.GetChild(0).childCount == 2 && self.recipe != null && self.recipe.possibleIngredients != null) { orig.Invoke(self); if (self.recipe.amountToDrop > 1) { GameObject val = new GameObject("Quantity"); ((TMP_Text)val.AddComponent()).text = self.recipe.amountToDrop + "x"; ((TMP_Text)val.GetComponent()).fontSize = 30f; val.transform.SetParent(((Component)self.resultIcon).transform, false); val.transform.localPosition = new Vector3(24f, -8f, 0f); } } } private static void RemoveUnneededCycleImages(orig_PopulateRecipes orig, RecipeInfoContainer self, PickupIndex pickupIndex) { //IL_0003: 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_0029: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self, pickupIndex); try { Fixture((Transform)(object)self.createdFromDisplay.container, pickupIndex, 1); Fixture((Transform)(object)self.usedToMakeDisplay.container, pickupIndex, 0); } catch (Exception ex) { Debug.LogError((object)ex); } } public static void Fixture(Transform recipeHolder, PickupIndex pickup, int start) { //IL_001c: 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_0092: 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_010d: Unknown result type (might be due to invalid IL or missing references) for (int i = start; i < recipeHolder.childCount; i++) { RecipeStrip component = ((Component)recipeHolder.GetChild(i)).GetComponent(); if (!component.recipe.IsUsedInMultipleSlots(pickup)) { if (component.recipe.possibleIngredients[1].pickups.Length != 1 && ((ReadOnlySpan)component.recipe.possibleIngredients[1].pickups).IndexOf(pickup) != -1) { ((Component)((Component)component).transform.GetChild(0).GetChild(3)).GetComponent().SetSprites((Sprite[])(object)new Sprite[1] { PickupCatalog.GetPickupDef(pickup).iconSprite }); } else if (component.recipe.possibleIngredients[0].pickups.Length != 1 && ((ReadOnlySpan)component.recipe.possibleIngredients[0].pickups).IndexOf(pickup) != -1) { ((Component)((Component)component).transform.GetChild(0).GetChild(2)).GetComponent().SetSprites((Sprite[])(object)new Sprite[1] { PickupCatalog.GetPickupDef(pickup).iconSprite }); } } } } internal static bool PickupAvailable(PickupIndex index) { //IL_0001: 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_000f: Invalid comparison between Unknown and I4 //IL_0062: Unknown result type (might be due to invalid IL or missing references) //IL_0068: Invalid comparison between Unknown and I4 //IL_001a: 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) PickupDef pickupDef = PickupCatalog.GetPickupDef(index); if ((int)pickupDef.itemIndex != -1) { ItemDef itemDef = ItemCatalog.GetItemDef(pickupDef.itemIndex); if ((Object)(object)itemDef != (Object)null) { ExpansionDef requiredExpansion = itemDef.requiredExpansion; if ((Object)(object)requiredExpansion != (Object)null) { return ((BaseUserEntitlementTracker)(object)EntitlementManager.localUserEntitlementTracker).AnyUserHasEntitlement(requiredExpansion.requiredEntitlement); } } } else if ((int)pickupDef.equipmentIndex != -1) { EquipmentDef equipmentDef = EquipmentCatalog.GetEquipmentDef(pickupDef.equipmentIndex); if ((Object)(object)equipmentDef != (Object)null) { ExpansionDef requiredExpansion2 = equipmentDef.requiredExpansion; if ((Object)(object)requiredExpansion2 != (Object)null) { return ((BaseUserEntitlementTracker)(object)EntitlementManager.localUserEntitlementTracker).AnyUserHasEntitlement(requiredExpansion2.requiredEntitlement); } } } return true; } private static void RemoveDuplicateRecipes(orig_PopulateImages orig, RecipeDisplay self, List newRecipeEntries) { //IL_003f: 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_0093: 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) bool flag = ((Object)self).name.StartsWith("U"); flag = false; List list = newRecipeEntries.Distinct().ToList(); List list2 = new List(); foreach (RecipeEntry item in list) { if (PickupAvailable(item.result) && (!flag || item.Required(item.result) == 0) && (item.possibleIngredients[0].pickups.Length != 1 || PickupAvailable(item.possibleIngredients[0].pickups[0])) && (item.possibleIngredients[1].pickups.Length != 1 || PickupAvailable(item.possibleIngredients[1].pickups[0]))) { list2.Add(item); } } if (list2.Count > 1) { list2.Sort((RecipeEntry x, RecipeEntry y) => x.RecipeComparer(in y)); } orig.Invoke(self, list2); if (Object.op_Implicit((Object)(object)self.container)) { for (int i = 0; i < ((Transform)self.container).childCount; i++) { ((Component)((Transform)self.container).GetChild(i)).GetComponent().PopulateImages(); } } } private static void AddRecipe(orig_AddSimplePickup orig, PageBuilder self, PickupIndex pickupIndex) { //IL_0003: Unknown result type (might be due to invalid IL or missing references) //IL_0010: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0029: 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_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_0079: 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) orig.Invoke(self, pickupIndex); GameObject val = self.AddPrefabInstance(Addressables.LoadAssetAsync((object)"RoR2/DLC3/UI/RecipeDisplayUpdated.prefab").WaitForCompletion()); val.GetComponent().PopulateRecipes(pickupIndex); ((Graphic)val.GetComponent()).color = new Color(0.3255f, 0.4039f, 0.4706f, 0.8706f); val.GetComponent().sprite = Addressables.LoadAssetAsync((object)"03f90788916529e459ba4d7f40bb32ee").WaitForCompletion(); val.SetActive(CraftableCatalog.resultToRecipeSearchTable.ContainsKey(pickupIndex) || CraftableCatalog.pickupToIngredientSearchTable.ContainsKey(pickupIndex)); } public static int RecipeComparer(this RecipeEntry first, in RecipeEntry other) { //IL_0006: Unknown result type (might be due to invalid IL or missing references) //IL_000d: Unknown result type (might be due to invalid IL or missing references) //IL_0049: 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_001d: 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_00b0: 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_007a: 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_00e3: 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_011d: Unknown result type (might be due to invalid IL or missing references) //IL_0123: Invalid comparison between Unknown and I4 //IL_0126: Unknown result type (might be due to invalid IL or missing references) //IL_012c: Invalid comparison between Unknown and I4 //IL_018a: Unknown result type (might be due to invalid IL or missing references) //IL_0190: Invalid comparison between Unknown and I4 //IL_013c: Unknown result type (might be due to invalid IL or missing references) //IL_014b: Unknown result type (might be due to invalid IL or missing references) //IL_0193: Unknown result type (might be due to invalid IL or missing references) //IL_0199: Invalid comparison between Unknown and I4 //IL_0200: Unknown result type (might be due to invalid IL or missing references) //IL_0206: Unknown result type (might be due to invalid IL or missing references) //IL_021d: Unknown result type (might be due to invalid IL or missing references) //IL_0223: Unknown result type (might be due to invalid IL or missing references) PickupDef val = null; PickupDef val2 = null; if (first.result != other.result) { val = PickupCatalog.GetPickupDef(first.result); val2 = PickupCatalog.GetPickupDef(other.result); } else if (first.possibleIngredients[0].pickups[0] != other.possibleIngredients[0].pickups[0]) { val = PickupCatalog.GetPickupDef(first.possibleIngredients[0].pickups[0]); val2 = PickupCatalog.GetPickupDef(other.possibleIngredients[0].pickups[0]); } else if (first.possibleIngredients[1].pickups[0] != other.possibleIngredients[1].pickups[0]) { val = PickupCatalog.GetPickupDef(first.possibleIngredients[1].pickups[0]); val2 = PickupCatalog.GetPickupDef(other.possibleIngredients[1].pickups[0]); } if (val == null) { return 0; } if ((int)val.itemIndex != -1 && (int)val2.itemIndex != -1) { int num = TierToSorting(val2.itemTier).CompareTo(TierToSorting(val.itemTier)); if (num == 0) { return val.internalName.CompareTo(val2.internalName); } return num; } if ((int)val.equipmentIndex != -1 && (int)val2.equipmentIndex != -1) { if (val.isBoss && !val2.isBoss) { return -1; } if (val.isLunar && !val2.isLunar) { return -1; } return val.internalName.CompareTo(val2.internalName); } if (val.pickupIndex < val2.pickupIndex) { return -1; } if (val.pickupIndex > val2.pickupIndex) { return 1; } return 0; } public static int TierToSorting(ItemTier itemTier) { //IL_0001: Unknown result type (might be due to invalid IL or missing references) //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0003: Unknown result type (might be due to invalid IL or missing references) //IL_0004: 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) //IL_0007: Unknown result type (might be due to invalid IL or missing references) //IL_0021: Expected I4, but got Unknown //IL_0023: Unknown result type (might be due to invalid IL or missing references) //IL_0025: Unknown result type (might be due to invalid IL or missing references) //IL_0027: Expected I4, but got Unknown //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Expected I4, but got Unknown switch (itemTier - 6) { case 0: case 1: case 2: return itemTier - 6; case 3: return 4; case 4: return 10000; default: return (int)itemTier; } } } public class Logbook_AllyStatsMult : MonoBehaviour { public float healthMult = 1f; public float damageMult = 1f; public int healthDecay; } public class Logbook_Allies { [CompilerGenerated] private static class <>O { public static hook_AddBodyStatsPanel <0>__PageBuilder_AddBodyStatsPanel1; public static hook_BuildDroneEntries <1>__LogBookController_BuildDroneEntries; public static hook_AddDronePanel <2>__PageBuilder_AddDronePanel; public static Manipulator <3>__FixNegativeRegenStatNotShowingInLog; public static Manipulator <4>__AddOperatorCommand; public static Action <5>__Make; public static Action <6>__SetDroneIcon; } public static void MoreStats() { //IL_0008: Unknown result type (might be due to invalid IL or missing references) //IL_000d: Unknown result type (might be due to invalid IL or missing references) //IL_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_005c: Unknown result type (might be due to invalid IL or missing references) //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_008d: Unknown result type (might be due to invalid IL or missing references) //IL_0092: Unknown result type (might be due to invalid IL or missing references) //IL_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_00c8: Expected O, but got Unknown //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_00e9: Expected O, but got Unknown //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_010a: Expected O, but got Unknown //IL_0120: Unknown result type (might be due to invalid IL or missing references) //IL_0125: Unknown result type (might be due to invalid IL or missing references) //IL_012b: Expected O, but got Unknown //IL_0141: Unknown result type (might be due to invalid IL or missing references) //IL_0146: Unknown result type (might be due to invalid IL or missing references) //IL_014c: Expected O, but got Unknown Logbook_AllyStatsMult logbook_AllyStatsMult = null; GameObject val = Addressables.LoadAssetAsync((object)"5290eaf612d386740ac26f289e06b62f").WaitForCompletion(); logbook_AllyStatsMult = val.AddComponent(); logbook_AllyStatsMult.healthDecay = 30; GameObject val2 = Addressables.LoadAssetAsync((object)"e21e3b9cdc2802148986eda1c923c9a1").WaitForCompletion(); logbook_AllyStatsMult = val2.AddComponent(); logbook_AllyStatsMult.healthMult = 2f; logbook_AllyStatsMult.damageMult = 4f; GameObject val3 = Addressables.LoadAssetAsync((object)"bf5b53aa9306bce4b910220a43b30062").WaitForCompletion(); logbook_AllyStatsMult = val3.AddComponent(); logbook_AllyStatsMult.healthMult = 4f; logbook_AllyStatsMult.damageMult = 4f; GameObject val4 = Addressables.LoadAssetAsync((object)"1553966a1aafdb743bf87ff4d6602c22").WaitForCompletion(); logbook_AllyStatsMult = val4.AddComponent(); logbook_AllyStatsMult.healthDecay = 30; object obj = <>O.<0>__PageBuilder_AddBodyStatsPanel1; if (obj == null) { hook_AddBodyStatsPanel val5 = PageBuilder_AddBodyStatsPanel1; <>O.<0>__PageBuilder_AddBodyStatsPanel1 = val5; obj = (object)val5; } PageBuilder.AddBodyStatsPanel += (hook_AddBodyStatsPanel)obj; object obj2 = <>O.<1>__LogBookController_BuildDroneEntries; if (obj2 == null) { hook_BuildDroneEntries val6 = LogBookController_BuildDroneEntries; <>O.<1>__LogBookController_BuildDroneEntries = val6; obj2 = (object)val6; } LogBookController.BuildDroneEntries += (hook_BuildDroneEntries)obj2; object obj3 = <>O.<2>__PageBuilder_AddDronePanel; if (obj3 == null) { hook_AddDronePanel val7 = PageBuilder_AddDronePanel; <>O.<2>__PageBuilder_AddDronePanel = val7; obj3 = (object)val7; } PageBuilder.AddDronePanel += (hook_AddDronePanel)obj3; object obj4 = <>O.<3>__FixNegativeRegenStatNotShowingInLog; if (obj4 == null) { Manipulator val8 = FixNegativeRegenStatNotShowingInLog; <>O.<3>__FixNegativeRegenStatNotShowingInLog = val8; obj4 = (object)val8; } PageBuilder.AddBodyStatsPanel += (Manipulator)obj4; object obj5 = <>O.<4>__AddOperatorCommand; if (obj5 == null) { Manipulator val9 = AddOperatorCommand; <>O.<4>__AddOperatorCommand = val9; obj5 = (object)val9; } PageBuilder.DroneBody += (Manipulator)obj5; ((ResourceAvailability)(ref BodyCatalog.availability)).CallWhenAvailable((Action)AllyCatalog.Make); ((ResourceAvailability)(ref LogBookController.availability)).CallWhenAvailable((Action)SetDroneIcon); } public static void SetDroneIcon() { //IL_002a: Unknown result type (might be due to invalid IL or missing references) ((Graphic)((Component)CommonAssets.droneEntryIcon.transform.GetChild(0)).GetComponent()).color = new Color(0.6588f, 0.708f, 0.741f, 1f); } private static void FixNegativeRegenStatNotShowingInLog(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown //IL_0042: 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) ILCursor val = new ILCursor(il); if (val.TryGotoNext((MoveType)2, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchLdsfld(x, "UnityEngine.Mathf", "Epsilon") })) { val.Prev.OpCode = OpCodes.Ldc_R4; val.Prev.Operand = 0f; val.Next.OpCode = OpCodes.Bne_Un_S; } else { Log.LogWarning("IL Failed: FixNegativeRegenStatNotShowingInLog"); } } private static void AddOperatorCommand(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown //IL_005f: Unknown result type (might be due to invalid IL or missing references) ILCursor val = new ILCursor(il); if (val.TryGotoNext((MoveType)0, new Func[2] { (Instruction x) => ILPatternMatchingExt.MatchLdloc(x, 0), (Instruction x) => ILPatternMatchingExt.MatchCallvirt(x, "RoR2.UI.LogBook.PageBuilder", "AddSimpleBody") })) { val.Emit(OpCodes.Ldloc_0); val.EmitDelegate>((Func)delegate(PageBuilder page, CharacterBody body) { bool flag = false; if (Object.op_Implicit((Object)(object)Run.instance) && Run.instance.IsExpansionEnabled(DLCS.DLC3)) { flag = true; } else if (((BaseUserEntitlementTracker)(object)EntitlementManager.localUserEntitlementTracker).AnyUserHasEntitlement(DLCS.DLC3.requiredEntitlement)) { flag = true; } if (flag) { string text = body.baseNameToken.Replace("DT", "").Replace("BODY_NAME", "TIERINFO"); if (Language.english.TokenIsRegistered(text)) { TextMeshProUGUI component = ((Component)page.managedObjects.Last().GetComponent().FindChild("MainLabel")).GetComponent(); ((TMP_Text)component).text = ((TMP_Text)component).text + "\n" + Language.GetString(text); } DroneCommandReceiver val2 = default(DroneCommandReceiver); if (((Component)body).TryGetComponent(ref val2)) { GenericSkill commandSkill = val2.commandSkill; if (Object.op_Implicit((Object)(object)val2.commandSkill) && Object.op_Implicit((Object)(object)val2.commandSkill.skillFamily)) { page.AddSimpleTextPanel(string.Format("{0}:\n{1}", new object[2] { Language.GetString("DRONETECH_SECONDARY_NAME"), Language.GetString(val2.commandSkill.skillFamily.defaultSkillDef.skillDescriptionToken) })); } } } return page; }); } else { Log.LogWarning("IL Failed: AddOperatorCommand"); } } private static void PageBuilder_AddDronePanel(orig_AddDronePanel orig, PageBuilder self, CharacterBody bodyPrefabComponent) { //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_0035: Unknown result type (might be due to invalid IL or missing references) //IL_0036: Unknown result type (might be due to invalid IL or missing references) //IL_0038: Invalid comparison between Unknown and I4 //IL_0045: 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) orig.Invoke(self, bodyPrefabComponent); TextMeshProUGUI component = ((Component)self.managedObjects.Last().GetComponent().FindChild("MainLabel")).GetComponent(); DroneIndex droneIndexFromBodyIndex = DroneCatalog.GetDroneIndexFromBodyIndex(bodyPrefabComponent.bodyIndex); if ((int)droneIndexFromBodyIndex != -1) { DroneDef droneDef = DroneCatalog.GetDroneDef(droneIndexFromBodyIndex); if (Object.op_Implicit((Object)(object)droneDef) && Object.op_Implicit((Object)(object)droneDef.droneBrokenSpawnCard)) { PurchaseInteraction component2 = droneDef.droneBrokenSpawnCard.prefab.GetComponent(); CostTypeDef costTypeDef = CostTypeCatalog.GetCostTypeDef(component2.costType); Language.GetStringFormatted(costTypeDef.costStringFormatToken, new object[1] { component2.cost }); ((TMP_Text)component).text = ((TMP_Text)component).text + Language.GetStringFormatted("DRONE_COST_STAT", new object[1] { Language.GetStringFormatted(costTypeDef.costStringFormatToken, new object[1] { component2.cost }) }); } } } private static Entry[] LogBookController_BuildDroneEntries(orig_BuildDroneEntries orig, Dictionary expansionAvailability) { //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_0077: Unknown result type (might be due to invalid IL or missing references) //IL_0082: Unknown result type (might be due to invalid IL or missing references) //IL_0151: 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_0333: 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_0349: Unknown result type (might be due to invalid IL or missing references) //IL_0354: 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: Expected O, but got Unknown //IL_01f4: Unknown result type (might be due to invalid IL or missing references) //IL_020b: Unknown result type (might be due to invalid IL or missing references) //IL_01fd: Unknown result type (might be due to invalid IL or missing references) //IL_0210: Unknown result type (might be due to invalid IL or missing references) //IL_0215: Unknown result type (might be due to invalid IL or missing references) //IL_021a: Unknown result type (might be due to invalid IL or missing references) //IL_0269: Unknown result type (might be due to invalid IL or missing references) //IL_0273: Expected O, but got Unknown //IL_027d: Unknown result type (might be due to invalid IL or missing references) //IL_0287: Expected O, but got Unknown //IL_02a4: Unknown result type (might be due to invalid IL or missing references) //IL_02ae: Expected O, but got Unknown DroneDefs.DTHaulerDrone.desiredSortPosition = 14f; DroneDefs.DTHealDrone.desiredSortPosition = 13f; DroneDefs.BomberDrone.desiredSortPosition = 100f; DroneDefs.DroneCommander.desiredSortPosition = 100f; DroneDefs.MissileDrone.desiredSortPosition = 0f; DroneDefs.FlameDrone.desiredSortPosition = 1f; DroneDefs.BackupDrone.tier = (ItemTier)3; DroneDefs.DTGunnerDrone.tier = (ItemTier)6; DroneDefs.DTHealDrone.tier = (ItemTier)6; DroneDefs.DTHaulerDrone.tier = (ItemTier)6; Entry[] array = orig.Invoke(expansionAvailability); Entry[] array2 = array; foreach (Entry val in array2) { if (val.extraData == BodyPrefabs.BackupDroneBody) { val.bgTexture = LegacyResourcesAPI.Load("Textures/ItemIcons/BG/texEquipmentBGIcon"); } else if (val.extraData == BodyPrefabs.DTGunnerDroneBody || val.extraData == BodyPrefabs.DTHaulerDroneBody || val.extraData == BodyPrefabs.DTHealingDroneBody) { val.bgTexture = (Texture)(object)CommonAssets.survivorBgIcon; } } List list = new List(); foreach (KeyValuePair allyDef in AllyCatalog.AllyDefs) { if (AllyCatalog.CanSelectDroneEntry(allyDef.Value, expansionAvailability)) { CharacterBody bodyPrefabBodyComponent = BodyCatalog.GetBodyPrefabBodyComponent(allyDef.Key); ItemTierDef itemTierDef = ItemTierCatalog.GetItemTierDef(allyDef.Value.tier); GameObject modelPrefab = null; ModelLocator component = ((Component)bodyPrefabBodyComponent).GetComponent(); if ((Object)(object)component != (Object)null && (Object)(object)component.logBookModel != (Object)null) { modelPrefab = ((Component)component.logBookModel).gameObject; } else { Debug.LogError((object)("MISSING MODEL PREFAB REF ON " + bodyPrefabBodyComponent.baseNameToken)); } Entry val2 = new Entry(); val2.nameToken = bodyPrefabBodyComponent.baseNameToken; val2.iconTexture = bodyPrefabBodyComponent.portraitIcon; val2.color = Color32.op_Implicit(ColorCatalog.GetColor(((int)allyDef.Value.colorOverride != 0) ? allyDef.Value.colorOverride : itemTierDef.colorIndex)); val2.bgTexture = (Object.op_Implicit((Object)(object)allyDef.Value.bgTextureOverride) ? allyDef.Value.bgTextureOverride : itemTierDef.bgIconTexture); val2.extraData = bodyPrefabBodyComponent; val2.modelPrefab = modelPrefab; val2.getStatusImplementation = new GetStatusDelegate(AllyCatalog.GetAllyStatus); val2.getTooltipContentImplementation = new GetTooltipContentDelegate(LogBookController.GetDroneTooltipContent); val2.pageBuilderMethod = PageBuilder.DroneBody; val2.isWIPImplementation = new IsWIPDelegate(LogBookController.IsEntryBodyWithoutLore); list.Add(val2); } } list.AddRange(array); Entry[] result = (from entry in list orderby AllyCatalog.TierFromBodyDroneOrAlly((CharacterBody)entry.extraData), AllyCatalog.SortFromBodyDroneOrAlly((CharacterBody)entry.extraData) select entry).ToArray(); DroneDefs.BackupDrone.tier = (ItemTier)1; DroneDefs.DTGunnerDrone.tier = (ItemTier)1; DroneDefs.DTHealDrone.tier = (ItemTier)1; DroneDefs.DTHaulerDrone.tier = (ItemTier)1; return result; } private static void PageBuilder_AddBodyStatsPanel1(orig_AddBodyStatsPanel orig, PageBuilder self, CharacterBody body) { //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_002e: 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_0054: 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_0073: 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_008b: Unknown result type (might be due to invalid IL or missing references) //IL_0098: Expected O, but got Unknown Logbook_AllyStatsMult component = ((Component)body).GetComponent(); if (Object.op_Implicit((Object)(object)component)) { CharacterBody val = new CharacterBody { baseMaxHealth = body.baseMaxHealth * component.healthMult, levelMaxHealth = body.levelMaxHealth * component.healthMult, baseDamage = body.baseDamage * component.damageMult, levelDamage = body.levelDamage * component.damageMult, baseArmor = body.armor, baseRegen = body.baseRegen, levelRegen = body.levelRegen, baseMoveSpeed = body.baseMoveSpeed }; if (component.healthDecay > 0) { val.baseRegen = (0f - body.baseMaxHealth) / (float)component.healthDecay; val.levelRegen = float.Parse(((0f - body.levelMaxHealth) / (float)component.healthDecay).ToString("0.00")); } orig.Invoke(self, val); Object.Destroy((Object)(object)body); } else { orig.Invoke(self, body); } } } public static class LogSimuStages { [CompilerGenerated] private static class <>O { public static hook_GetStageStatus <0>__ITStageIfCompletedOnce; } public static void Add() { //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_001a: Unknown result type (might be due to invalid IL or missing references) //IL_001f: Unknown result type (might be due to invalid IL or missing references) //IL_011a: Unknown result type (might be due to invalid IL or missing references) //IL_011f: Unknown result type (might be due to invalid IL or missing references) //IL_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_00a6: Unknown result type (might be due to invalid IL or missing references) //IL_00b0: Expected O, but got Unknown //IL_0138: 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_014c: Unknown result type (might be due to invalid IL or missing references) //IL_0151: Unknown result type (might be due to invalid IL or missing references) //IL_016c: Unknown result type (might be due to invalid IL or missing references) //IL_0171: Unknown result type (might be due to invalid IL or missing references) //IL_0181: Unknown result type (might be due to invalid IL or missing references) //IL_0186: Unknown result type (might be due to invalid IL or missing references) //IL_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) //IL_01fe: Unknown result type (might be due to invalid IL or missing references) //IL_0285: Unknown result type (might be due to invalid IL or missing references) //IL_028a: Unknown result type (might be due to invalid IL or missing references) //IL_02a0: Unknown result type (might be due to invalid IL or missing references) //IL_02a5: Unknown result type (might be due to invalid IL or missing references) //IL_02b8: Unknown result type (might be due to invalid IL or missing references) //IL_02c2: Expected O, but got Unknown //IL_02c7: Unknown result type (might be due to invalid IL or missing references) //IL_02cc: Unknown result type (might be due to invalid IL or missing references) //IL_02ee: Unknown result type (might be due to invalid IL or missing references) //IL_02f3: Unknown result type (might be due to invalid IL or missing references) //IL_0315: Unknown result type (might be due to invalid IL or missing references) //IL_031a: Unknown result type (might be due to invalid IL or missing references) //IL_033c: Unknown result type (might be due to invalid IL or missing references) //IL_0341: Unknown result type (might be due to invalid IL or missing references) //IL_0363: Unknown result type (might be due to invalid IL or missing references) //IL_0368: Unknown result type (might be due to invalid IL or missing references) //IL_038a: Unknown result type (might be due to invalid IL or missing references) //IL_038f: Unknown result type (might be due to invalid IL or missing references) //IL_03d1: Unknown result type (might be due to invalid IL or missing references) //IL_03d6: Unknown result type (might be due to invalid IL or missing references) //IL_03dc: Expected O, but got Unknown SceneCollection val = Addressables.LoadAssetAsync((object)"262363a2da6e02f4da3c752da7310e9e").WaitForCompletion(); GameObject val2 = Addressables.LoadAssetAsync((object)"ba70f68b08210a84f86ff7a12a324263").WaitForCompletion(); GameObject gameObject = ((Component)val2.transform.GetChild(0).GetChild(0)).gameObject; gameObject.AddComponent(); for (int i = 0; i < val.sceneEntries.Length; i++) { SceneDef sceneDef = ((SceneEntry)val.sceneEntries[i]).sceneDef; SceneDef val3 = Help.ITtoNormal(sceneDef); sceneDef.stageOrder = 5130 + val3.stageOrder; sceneDef.shouldIncludeInLogbook = WConfig.LogbookSimuStages.Value; sceneDef.dioramaPrefab = gameObject; sceneDef.dioramaPrefabAddress = new AssetReferenceGameObject(""); sceneDef.loreToken = string.Empty; string text = $"MAP_{sceneDef.cachedName}_NAME"; object[] args = new string[2] { Language.GetString("MAP_INFINITETOWER_TITLE"), Language.GetString(val3.nameToken) }; LanguageAPI.Add(text, string.Format("{0} ({1})", args)); sceneDef.nameToken = text; } SceneDef val4 = Addressables.LoadAssetAsync((object)"RoR2/DLC1/itmoon/itmoon.asset").WaitForCompletion(); GameObject val5 = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"a03e9bece79327549b82cc12874868af").WaitForCompletion(), "ITMoonDiorama", false); Material val6 = Addressables.LoadAssetAsync((object)"700e3cf101d42a04bb09174d67a90137").WaitForCompletion(); Material val7 = Addressables.LoadAssetAsync((object)"3dd74c91566eae840abf59a09d6748ea").WaitForCompletion(); Material val8 = Addressables.LoadAssetAsync((object)"0318c1c3351c71c4aaad528f5b76191c").WaitForCompletion(); val6.SetFloat("_AlphaBoost", 46.8f); val7.SetFloat("_AlphaBoost", 46.8f); val8.SetFloat("_AlphaBoost", 46.8f); Material val9 = Object.Instantiate(val7); val9.SetFloat("_AlphaBoost", 10000f); val5.transform.localScale = Vector3.one; ((Component)val5.transform.GetChild(0)).gameObject.SetActive(false); ((Component)val5.transform.GetChild(2)).GetComponent().material = val9; ((Component)val5.transform.GetChild(3)).GetComponent().material = val9; ModelPanelParameters val10 = val5.AddComponent(); InstantiateModelParams val11 = val5.AddComponent(); val10.maxDistance = 5f; val11.CameraPosition = new Vector3(0f, 2f, 3f); val11.FocusPosition = new Vector3(0f, 2f, 0f); val4.dioramaPrefab = val5; val4.dioramaPrefabAddress = new AssetReferenceGameObject(""); Addressables.LoadAssetAsync((object)"dda7dbdf013275747949dfc522842635").WaitForCompletion().previewTexture = (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/SimuPreview/texGolemplainsPreview.png"); Addressables.LoadAssetAsync((object)"0a35bec906d067941a8a378b963e9e9d").WaitForCompletion().previewTexture = (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/SimuPreview/texGoolakePreview.png"); Addressables.LoadAssetAsync((object)"568295b69af09c241968fa18ca37b56d").WaitForCompletion().previewTexture = (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/SimuPreview/texAncientLoftPreview.png"); Addressables.LoadAssetAsync((object)"0ab15976715ddd6438e2e5bd6ddbe224").WaitForCompletion().previewTexture = (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/SimuPreview/texFrozenwallPreview.png"); Addressables.LoadAssetAsync((object)"c33b24f6ebf27db49a5cfb88dbe9b8ff").WaitForCompletion().previewTexture = (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/SimuPreview/texDampcavePreview.png"); Addressables.LoadAssetAsync((object)"6a2712b5c8cf36f44b34c128f2759522").WaitForCompletion().previewTexture = (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/SimuPreview/texSkymeadowPreview.png"); val4.previewTexture = (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/SimuPreview/texMoonPreview.png"); object obj = <>O.<0>__ITStageIfCompletedOnce; if (obj == null) { hook_GetStageStatus val12 = ITStageIfCompletedOnce; <>O.<0>__ITStageIfCompletedOnce = val12; obj = (object)val12; } LogBookController.GetStageStatus += (hook_GetStageStatus)obj; } private static EntryStatus ITStageIfCompletedOnce(orig_GetStageStatus orig, ref Entry entry, UserProfile viewerProfile) { //IL_0066: Unknown result type (might be due to invalid IL or missing references) //IL_006b: Unknown result type (might be due to invalid IL or missing references) //IL_006e: 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) object extraData = entry.extraData; SceneDef val = (SceneDef)((extraData is SceneDef) ? extraData : null); if (val.stageOrder > 5129 && (viewerProfile.statSheet.HasUnlockable(Survivors.VoidSurvivor.unlockableDef) || viewerProfile.statSheet.GetStatValueULong(PerStageStatDef.totalTimesCleared.FindStatDef(val.baseSceneName)) != 0)) { return (EntryStatus)4; } return orig.Invoke(ref entry, viewerProfile); } } public static class UIBorders { [CompilerGenerated] private static class <>O { public static hook_Rebuild <0>__Eclipse_Border_SurvivorIcon; public static hook_Rebuild <1>__Beat_Simulacrum_IconBorder; } public static void Start() { //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_0057: Expected O, but got Unknown //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: Expected O, but got Unknown if (!Chainloader.PluginInfos.ContainsKey("depression_church.EclipseLevelInCharacterSelection")) { object obj = <>O.<0>__Eclipse_Border_SurvivorIcon; if (obj == null) { hook_Rebuild val = Eclipse_Border_SurvivorIcon; <>O.<0>__Eclipse_Border_SurvivorIcon = val; obj = (object)val; } SurvivorIconController.Rebuild += (hook_Rebuild)obj; } object obj2 = <>O.<1>__Beat_Simulacrum_IconBorder; if (obj2 == null) { hook_Rebuild val2 = Beat_Simulacrum_IconBorder; <>O.<1>__Beat_Simulacrum_IconBorder = val2; obj2 = (object)val2; } SurvivorIconController.Rebuild += (hook_Rebuild)obj2; } private static void Eclipse_Border_SurvivorIcon(orig_Rebuild orig, SurvivorIconController self) { //IL_005d: Unknown result type (might be due to invalid IL or missing references) //IL_0067: Invalid comparison between Unknown and I4 //IL_007b: 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_0106: Expected O, but got Unknown //IL_010b: Unknown result type (might be due to invalid IL or missing references) //IL_0112: Expected O, but got Unknown //IL_0117: Unknown result type (might be due to invalid IL or missing references) //IL_011e: Expected O, but got Unknown //IL_017e: 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_01b6: Unknown result type (might be due to invalid IL or missing references) //IL_01cd: Unknown result type (might be due to invalid IL or missing references) //IL_01e9: Unknown result type (might be due to invalid IL or missing references) //IL_0200: Unknown result type (might be due to invalid IL or missing references) //IL_0217: Unknown result type (might be due to invalid IL or missing references) //IL_022e: 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_026a: Unknown result type (might be due to invalid IL or missing references) //IL_0286: Unknown result type (might be due to invalid IL or missing references) //IL_029d: Unknown result type (might be due to invalid IL or missing references) //IL_02b9: Unknown result type (might be due to invalid IL or missing references) //IL_02d0: Unknown result type (might be due to invalid IL or missing references) //IL_02e7: Unknown result type (might be due to invalid IL or missing references) //IL_02fe: Unknown result type (might be due to invalid IL or missing references) //IL_0315: Unknown result type (might be due to invalid IL or missing references) //IL_033a: Unknown result type (might be due to invalid IL or missing references) //IL_0356: Unknown result type (might be due to invalid IL or missing references) //IL_036d: Unknown result type (might be due to invalid IL or missing references) //IL_0389: Unknown result type (might be due to invalid IL or missing references) //IL_03a0: Unknown result type (might be due to invalid IL or missing references) //IL_03b7: Unknown result type (might be due to invalid IL or missing references) //IL_03ce: Unknown result type (might be due to invalid IL or missing references) //IL_03e5: Unknown result type (might be due to invalid IL or missing references) //IL_0432: Unknown result type (might be due to invalid IL or missing references) //IL_0437: Unknown result type (might be due to invalid IL or missing references) //IL_0458: Unknown result type (might be due to invalid IL or missing references) //IL_0470: Unknown result type (might be due to invalid IL or missing references) //IL_048a: Unknown result type (might be due to invalid IL or missing references) //IL_04b8: Unknown result type (might be due to invalid IL or missing references) //IL_04d2: Unknown result type (might be due to invalid IL or missing references) //IL_0508: Unknown result type (might be due to invalid IL or missing references) //IL_050d: Unknown result type (might be due to invalid IL or missing references) //IL_0525: Unknown result type (might be due to invalid IL or missing references) //IL_053f: Unknown result type (might be due to invalid IL or missing references) //IL_0572: Unknown result type (might be due to invalid IL or missing references) //IL_0577: Unknown result type (might be due to invalid IL or missing references) //IL_058f: Unknown result type (might be due to invalid IL or missing references) //IL_05a9: Unknown result type (might be due to invalid IL or missing references) //IL_05dc: Unknown result type (might be due to invalid IL or missing references) //IL_05e1: Unknown result type (might be due to invalid IL or missing references) //IL_05f9: Unknown result type (might be due to invalid IL or missing references) //IL_0613: Unknown result type (might be due to invalid IL or missing references) //IL_0635: Unknown result type (might be due to invalid IL or missing references) //IL_0645: Unknown result type (might be due to invalid IL or missing references) //IL_064c: Expected O, but got Unknown //IL_0680: Unknown result type (might be due to invalid IL or missing references) //IL_069c: Unknown result type (might be due to invalid IL or missing references) //IL_06b8: Unknown result type (might be due to invalid IL or missing references) //IL_06d4: Unknown result type (might be due to invalid IL or missing references) //IL_06f0: Unknown result type (might be due to invalid IL or missing references) //IL_0711: Unknown result type (might be due to invalid IL or missing references) //IL_0732: Unknown result type (might be due to invalid IL or missing references) //IL_077c: Unknown result type (might be due to invalid IL or missing references) //IL_0781: Unknown result type (might be due to invalid IL or missing references) //IL_07a2: Unknown result type (might be due to invalid IL or missing references) //IL_07be: Unknown result type (might be due to invalid IL or missing references) //IL_07da: Unknown result type (might be due to invalid IL or missing references) //IL_07f6: Unknown result type (might be due to invalid IL or missing references) //IL_0812: Unknown result type (might be due to invalid IL or missing references) //IL_083e: Unknown result type (might be due to invalid IL or missing references) //IL_085a: Unknown result type (might be due to invalid IL or missing references) //IL_086a: Unknown result type (might be due to invalid IL or missing references) //IL_0871: Expected O, but got Unknown //IL_08c1: Unknown result type (might be due to invalid IL or missing references) //IL_08c6: Unknown result type (might be due to invalid IL or missing references) //IL_08f4: Unknown result type (might be due to invalid IL or missing references) //IL_08f9: Unknown result type (might be due to invalid IL or missing references) //IL_0922: Unknown result type (might be due to invalid IL or missing references) //IL_093e: Unknown result type (might be due to invalid IL or missing references) //IL_095a: Unknown result type (might be due to invalid IL or missing references) //IL_097b: Unknown result type (might be due to invalid IL or missing references) //IL_099c: Unknown result type (might be due to invalid IL or missing references) //IL_09b8: Unknown result type (might be due to invalid IL or missing references) //IL_09d4: Unknown result type (might be due to invalid IL or missing references) //IL_09f8: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self); if (!WConfig.cfgUIEclipseBorder.Value) { return; } bool flag = false; bool flag2 = false; if (((Object)((Graphic)((Component)self).GetComponent()).canvas).name.StartsWith("Eclipse")) { flag2 = true; flag = true; } else if (Object.op_Implicit((Object)(object)PreGameController.instance) && (int)PreGameController.instance.gameModeIndex != 255 && GameModeCatalog.GetGameModeName(PreGameController.instance.gameModeIndex).StartsWith("Eclipse")) { flag = true; } if (!flag) { return; } LocalUser firstLocalUser = LocalUserManager.GetFirstLocalUser(); if (!Object.op_Implicit((Object)(object)self.survivorDef)) { return; } int localUserSurvivorCompletedEclipseLevel = EclipseRun.GetLocalUserSurvivorCompletedEclipseLevel(firstLocalUser, self.survivorDef); Transform val = ((Component)self).transform.Find("Eclipse_Holder"); GameObject val2 = null; if ((Object)(object)val == (Object)null) { val2 = new GameObject("Eclipse_Holder"); GameObject val3 = new GameObject("Border"); GameObject val4 = new GameObject("NumberHolder"); val3.transform.SetParent(val2.transform, false); val4.transform.SetParent(val2.transform, false); RectTransform val5 = val2.AddComponent(); val2.transform.SetParent(((Component)self).transform); val = val2.transform; ((Transform)val5).position = new Vector3(35f, 0f, 0f); ((Transform)val5).localScale = new Vector3(1f, 1f, 1f); ((Transform)val5).localEulerAngles = new Vector3(0f, 0f, 0f); val5.anchoredPosition = new Vector2(0f, 0f); val5.anchoredPosition3D = new Vector3(0f, 0f, 0f); val5.anchorMax = new Vector2(1f, 1f); val5.anchorMin = new Vector2(0f, 0f); val5.offsetMax = new Vector2(0f, 0f); val5.offsetMin = new Vector2(0f, 0f); val5 = val3.AddComponent(); ((Transform)val5).localScale = new Vector3(1f, 1f, 1f); ((Transform)val5).localEulerAngles = new Vector3(0f, 0f, 0f); val5.anchoredPosition = new Vector2(0f, 0f); val5.anchoredPosition3D = new Vector3(0f, 0f, 0f); val5.anchorMax = new Vector2(1f, 1f); val5.anchorMin = new Vector2(0f, 0f); val5.offsetMax = new Vector2(0f, 0f); val5.offsetMin = new Vector2(0f, 0f); val5 = val4.AddComponent(); ((Transform)val5).localScale = new Vector3(1f, 1f, 1f); ((Transform)val5).localEulerAngles = new Vector3(0f, 0f, 0f); val5.anchoredPosition = new Vector2(0f, 0f); val5.anchoredPosition3D = new Vector3(0f, 0f, 0f); val5.anchorMax = new Vector2(1f, 1f); val5.anchorMin = new Vector2(0f, 0f); val5.offsetMax = new Vector2(0f, 0f); val5.offsetMin = new Vector2(0f, 0f); int num = 5; GameObject val6 = Object.Instantiate(((Component)((Component)self).gameObject.transform.GetChild(1)).gameObject, val3.transform); ((Graphic)val6.GetComponent()).color = Color32.op_Implicit(new Color32((byte)156, (byte)195, (byte)231, byte.MaxValue)); val6.transform.localScale = new Vector3(1f, 1f, 1f); val6.GetComponent().offsetMax = new Vector2((float)num, (float)num); val6.GetComponent().offsetMin = new Vector2((float)(-num), (float)(-num)); num--; val6 = Object.Instantiate(val6, val3.transform); val6.GetComponent().offsetMax = new Vector2((float)num, (float)num); val6.GetComponent().offsetMin = new Vector2((float)(-num), (float)(-num)); num--; val6 = Object.Instantiate(val6, val3.transform); ((Graphic)val6.GetComponent()).color = Color32.op_Implicit(new Color32((byte)93, (byte)117, (byte)140, byte.MaxValue)); val6.GetComponent().offsetMax = new Vector2((float)num, (float)num); val6.GetComponent().offsetMin = new Vector2((float)(-num), (float)(-num)); num--; val6 = Object.Instantiate(val6, val3.transform); ((Graphic)val6.GetComponent()).color = Color32.op_Implicit(new Color32((byte)66, (byte)81, (byte)99, byte.MaxValue)); val6.GetComponent().offsetMax = new Vector2((float)num, (float)num); val6.GetComponent().offsetMin = new Vector2((float)(-num), (float)(-num)); num--; val6 = Object.Instantiate(val6, val3.transform); ((Graphic)val6.GetComponent()).color = Color32.op_Implicit(new Color32((byte)27, (byte)35, (byte)40, byte.MaxValue)); val6.GetComponent().offsetMax = new Vector2((float)num, (float)num); val6.GetComponent().offsetMin = new Vector2((float)(-num), (float)(-num)); num--; val4.GetComponent().anchoredPosition = new Vector2(-4f, -4f); GameObject val7 = new GameObject("BackDrop"); val7.transform.SetParent(val4.transform, false); Image val8 = val7.AddComponent(); ((Graphic)val8).color = new Color(0f, 0f, 0f, 0.95f); val7.GetComponent().anchorMax = new Vector2(0.4f, 0.4f); val7.GetComponent().anchorMin = new Vector2(0f, 0f); val7.GetComponent().offsetMax = new Vector2(0f, 0f); val7.GetComponent().offsetMin = new Vector2(0f, 0f); val7.GetComponent().anchoredPosition3D = new Vector3(3f, 3f, 0f); ((Transform)val7.GetComponent()).localScale = new Vector3(1f, 1f, 1f); val6 = Object.Instantiate(((Component)((Component)self).gameObject.transform.GetChild(1)).gameObject, val4.transform); ((Graphic)val6.GetComponent()).color = Color32.op_Implicit(new Color32((byte)156, (byte)195, (byte)231, byte.MaxValue)); val6.transform.localScale = new Vector3(1f, 1f, 1f); val6.GetComponent().anchorMax = new Vector2(0.5f, 0.5f); val6.GetComponent().anchorMin = new Vector2(0f, 0f); val6.GetComponent().offsetMax = new Vector2(-1f, -1f); val6.GetComponent().offsetMin = new Vector2(0f, 0f); val6 = Object.Instantiate(val6, val4.transform); val6.GetComponent().offsetMax = new Vector2(-2f, -2f); val6.GetComponent().offsetMin = new Vector2(1f, 1f); GameObject val9 = new GameObject("Number"); val9.transform.SetParent(val4.transform, false); HGTextMeshProUGUI val10 = val9.AddComponent(); ((TMP_Text)val10).text = localUserSurvivorCompletedEclipseLevel.ToString(); ((TMP_Text)val10).fontSize = 30f; ((Graphic)val10).color = Color32.op_Implicit(new Color32((byte)242, (byte)242, (byte)242, byte.MaxValue)); ((TMP_Text)val10).alignment = (TextAlignmentOptions)514; ((Graphic)val10).color = Color32.op_Implicit(new Color32((byte)242, (byte)242, (byte)242, byte.MaxValue)); ((TMP_Text)val10).alignment = (TextAlignmentOptions)514; val9.GetComponent().anchorMax = new Vector2(0f, 0f); val9.GetComponent().anchorMin = new Vector2(0f, 0f); val9.GetComponent().pivot = new Vector2(0f, 0f); val9.GetComponent().anchoredPosition3D = new Vector3(17f, 17f, 0f); ((Transform)val9.GetComponent()).localScale = new Vector3(1f, 1f, 1f); val9.GetComponent().offsetMin = new Vector2(0f, 0f); val9.GetComponent().offsetMax = new Vector2(34f, 34f); if (flag2) { val9.GetComponent().offsetMax = new Vector2(32f, 34f); } } else { val2 = ((Component)val).gameObject; } ((TMP_Text)((Component)val2.transform.GetChild(1)).GetComponentInChildren()).text = localUserSurvivorCompletedEclipseLevel.ToString(); bool flag3 = true; if (flag3 && localUserSurvivorCompletedEclipseLevel == EclipseRun.maxEclipseLevel) { val2.transform.SetAsFirstSibling(); val2.SetActive(true); ((Component)val2.transform.GetChild(0)).gameObject.SetActive(true); ((Component)val2.transform.GetChild(1)).gameObject.SetActive(false); } else if (flag3 || localUserSurvivorCompletedEclipseLevel > 0) { val2.transform.SetAsLastSibling(); val2.SetActive(true); ((Component)val2.transform.GetChild(0)).gameObject.SetActive(false); if (flag3) { ((TMP_Text)((Component)val2.transform.GetChild(1)).GetComponentInChildren()).text = (1 + localUserSurvivorCompletedEclipseLevel).ToString(); } else { ((TMP_Text)((Component)val2.transform.GetChild(1)).GetComponentInChildren()).text = localUserSurvivorCompletedEclipseLevel.ToString(); } } else { val2.SetActive(false); } } private static void Beat_Simulacrum_IconBorder(orig_Rebuild orig, SurvivorIconController self) { //IL_005b: Unknown result type (might be due to invalid IL or missing references) //IL_0065: Invalid comparison between Unknown and I4 //IL_0079: 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_0104: Invalid comparison between Unknown and I4 //IL_0114: Unknown result type (might be due to invalid IL or missing references) //IL_017c: Unknown result type (might be due to invalid IL or missing references) //IL_0183: Expected O, but got Unknown //IL_01ba: 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_01f2: Unknown result type (might be due to invalid IL or missing references) //IL_0209: Unknown result type (might be due to invalid IL or missing references) //IL_0225: Unknown result type (might be due to invalid IL or missing references) //IL_023c: Unknown result type (might be due to invalid IL or missing references) //IL_0253: Unknown result type (might be due to invalid IL or missing references) //IL_026a: Unknown result type (might be due to invalid IL or missing references) //IL_0281: Unknown result type (might be due to invalid IL or missing references) //IL_02c6: Unknown result type (might be due to invalid IL or missing references) //IL_02cb: Unknown result type (might be due to invalid IL or missing references) //IL_02ec: Unknown result type (might be due to invalid IL or missing references) //IL_0308: Unknown result type (might be due to invalid IL or missing references) //IL_0324: Unknown result type (might be due to invalid IL or missing references) //IL_034b: Unknown result type (might be due to invalid IL or missing references) //IL_0367: Unknown result type (might be due to invalid IL or missing references) //IL_0395: Unknown result type (might be due to invalid IL or missing references) //IL_039a: 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_03d2: Unknown result type (might be due to invalid IL or missing references) //IL_03fc: Unknown result type (might be due to invalid IL or missing references) //IL_0401: Unknown result type (might be due to invalid IL or missing references) //IL_041d: Unknown result type (might be due to invalid IL or missing references) //IL_0439: Unknown result type (might be due to invalid IL or missing references) //IL_0460: Unknown result type (might be due to invalid IL or missing references) //IL_0465: Unknown result type (might be due to invalid IL or missing references) //IL_0481: Unknown result type (might be due to invalid IL or missing references) //IL_049d: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self); if (!WConfig.cfgUISimuBorder.Value) { return; } bool flag = false; if (((Object)((Graphic)((Component)self).GetComponent()).canvas).name.StartsWith("InfiniteT")) { flag = true; } else if (Object.op_Implicit((Object)(object)PreGameController.instance) && (int)PreGameController.instance.gameModeIndex != 255 && GameModeCatalog.GetGameModeName(PreGameController.instance.gameModeIndex).StartsWith("InfiniteT")) { flag = true; } if (!flag) { return; } MPEventSystem eventSystem = self.characterSelectBarController.eventSystemLocator.eventSystem; UserProfile val; if ((Object)(object)eventSystem == (Object)null) { val = null; } else { LocalUser localUser = eventSystem.localUser; val = ((localUser != null) ? localUser.userProfile : null); } UserProfile val2 = val; if (val2 == null) { return; } StatSheet statSheet = val2.statSheet; if ((int)self.survivorBodyIndex != -1) { string bodyName = BodyCatalog.GetBodyName(self.survivorBodyIndex); ulong statValueULong = statSheet.GetStatValueULong(PerBodyStatDef.highestInfiniteTowerWaveReachedEasy, bodyName); ulong statValueULong2 = statSheet.GetStatValueULong(PerBodyStatDef.highestInfiniteTowerWaveReachedNormal, bodyName); ulong statValueULong3 = statSheet.GetStatValueULong(PerBodyStatDef.highestInfiniteTowerWaveReachedHard, bodyName); Transform val3 = ((Component)self).transform.Find("IT_Win_Holder"); GameObject val4 = null; if ((Object)(object)val3 == (Object)null) { val4 = new GameObject("IT_Win_Holder"); RectTransform val5 = val4.AddComponent(); val4.transform.SetParent(((Component)self).transform, false); val3 = val4.transform; ((Transform)val5).position = new Vector3(35f, 0f, 0f); ((Transform)val5).localScale = new Vector3(1f, 1f, 1f); ((Transform)val5).localEulerAngles = new Vector3(0f, 0f, 0f); val5.anchoredPosition = new Vector2(0f, 0f); val5.anchoredPosition3D = new Vector3(0f, 0f, 0f); val5.anchorMax = new Vector2(1f, 1f); val5.anchorMin = new Vector2(0f, 0f); val5.offsetMax = new Vector2(0f, 0f); val5.offsetMin = new Vector2(0f, 0f); GameObject val6 = Object.Instantiate(((Component)((Component)self).gameObject.transform.GetChild(1)).gameObject, val3); ((Graphic)val6.GetComponent()).color = Color32.op_Implicit(new Color32((byte)231, (byte)154, (byte)239, byte.MaxValue)); val6.transform.localScale = new Vector3(1f, 1f, 1f); val6.GetComponent().offsetMax = new Vector2(5f, 5f); val6.GetComponent().offsetMin = new Vector2(-5f, -5f); val6 = Object.Instantiate(val6, val3); val6.GetComponent().offsetMax = new Vector2(4f, 4f); val6.GetComponent().offsetMin = new Vector2(-4f, -4f); val6 = Object.Instantiate(val6, val3); ((Graphic)val6.GetComponent()).color = Color32.op_Implicit(new Color32((byte)247, (byte)117, (byte)206, byte.MaxValue)); val6.GetComponent().offsetMax = new Vector2(3f, 3f); val6.GetComponent().offsetMin = new Vector2(-3f, -3f); val6 = Object.Instantiate(val6, val3); ((Graphic)val6.GetComponent()).color = Color32.op_Implicit(new Color32((byte)189, (byte)4, (byte)66, byte.MaxValue)); val6.GetComponent().offsetMax = new Vector2(2f, 2f); val6.GetComponent().offsetMin = new Vector2(-2f, -2f); val6 = Object.Instantiate(val6, val3); ((Graphic)val6.GetComponent()).color = Color32.op_Implicit(new Color32((byte)85, (byte)8, (byte)35, byte.MaxValue)); val6.GetComponent().offsetMax = new Vector2(1f, 1f); val6.GetComponent().offsetMin = new Vector2(-1f, -1f); val4.transform.SetAsFirstSibling(); } else { val4 = ((Component)val3).gameObject; } if (statValueULong3 >= 50 || statValueULong2 >= 50 || statValueULong >= 50) { val4.SetActive(true); } else { val4.SetActive(false); } } } } public static class UI_Color { [CompilerGenerated] private static class <>O { public static hook_SetItemIndex_ItemIndex_int_float <0>__ShowTemporaryItemStacksDifferently; } public static Color Temp = new Color(0.75f, 0.95f, 1f, 1f); public static void Start() { //IL_0042: 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_0077: 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_00a4: Unknown result type (might be due to invalid IL or missing references) //IL_00aa: Expected O, but got Unknown Color color = default(Color); ((Color)(ref color))..ctor(0.52f, 0.584f, 0.66f, 0.1333f); GameObject val = LegacyResourcesAPI.Load("Prefabs/HUDSimple"); ((Graphic)((Component)val.GetComponent().lunarCoinContainer.transform.GetChild(0)).GetComponent()).color = color; GameObject val2 = Addressables.LoadAssetAsync((object)"a27b8dde5bc73be4fae7f40a46e3cdff").WaitForCompletion(); ((Graphic)((Component)val2.GetComponent().rewardArea.transform.GetChild(0)).GetComponent()).color = color; if (WConfig.cfgTempItemCyanStack.Value) { object obj = <>O.<0>__ShowTemporaryItemStacksDifferently; if (obj == null) { hook_SetItemIndex_ItemIndex_int_float val3 = ShowTemporaryItemStacksDifferently; <>O.<0>__ShowTemporaryItemStacksDifferently = val3; obj = (object)val3; } ItemIcon.SetItemIndex_ItemIndex_int_float += (hook_SetItemIndex_ItemIndex_int_float)obj; } } private static void ShowTemporaryItemStacksDifferently(orig_SetItemIndex_ItemIndex_int_float orig, ItemIcon self, ItemIndex newItemIndex, int newItemCount, float newDurationPercent) { //IL_0003: 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_0038: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self, newItemIndex, newItemCount, newDurationPercent); if (newDurationPercent > 0f) { if (newItemCount == 1) { self.spriteAsNumberManager.SetItemCount(1); } self.spriteAsNumberManager.SetSpriteColor(Temp); } else { self.spriteAsNumberManager.SetSpriteColor(Color.white); } } public static void AllowScrolling(GameObject chatBox) { //IL_0073: Unknown result type (might be due to invalid IL or missing references) ChatBox component = chatBox.GetComponent(); component.scrollRect.vertical = true; component.scrollRect.scrollSensitivity = 6f; Transform child = chatBox.transform.GetChild(2).GetChild(0).GetChild(3) .GetChild(0); TMP_InputField component2 = ((Component)child).GetComponent(); ((Behaviour)((Selectable)component2).image).enabled = true; ((Graphic)((Selectable)component2).image).color = new Color(0f, 0f, 0f, 0f); } } public static class UI_RealTimeTimer { [CompilerGenerated] private static class <>O { public static hook_OnEnable <0>__ScoreboardController_OnEnable; public static hook_OnDisable <1>__ScoreboardController_OnDisable; public static hook_InstantiateUi <2>__Run_InstantiateUi; } public static bool scoreboardOpen = false; private static GameObject Timer = ((Component)Addressables.LoadAssetAsync((object)"23b0bcee7bc7a0c4d91d884c778cc70a").WaitForCompletion().transform.GetChild(0).GetChild(1)).gameObject; public static void Start() { //IL_0011: 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_001c: Expected O, but got Unknown //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Unknown result type (might be due to invalid IL or missing references) //IL_003d: Expected O, but got Unknown //IL_0073: 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_00cf: 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_00d9: Unknown result type (might be due to invalid IL or missing references) //IL_0117: Unknown result type (might be due to invalid IL or missing references) //IL_0118: Unknown result type (might be due to invalid IL or missing references) //IL_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_012d: Unknown result type (might be due to invalid IL or missing references) //IL_0132: Unknown result type (might be due to invalid IL or missing references) //IL_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_005e: Expected O, but got Unknown object obj = <>O.<0>__ScoreboardController_OnEnable; if (obj == null) { hook_OnEnable val = ScoreboardController_OnEnable; <>O.<0>__ScoreboardController_OnEnable = val; obj = (object)val; } ScoreboardController.OnEnable += (hook_OnEnable)obj; object obj2 = <>O.<1>__ScoreboardController_OnDisable; if (obj2 == null) { hook_OnDisable val2 = ScoreboardController_OnDisable; <>O.<1>__ScoreboardController_OnDisable = val2; obj2 = (object)val2; } ScoreboardController.OnDisable += (hook_OnDisable)obj2; object obj3 = <>O.<2>__Run_InstantiateUi; if (obj3 == null) { hook_InstantiateUi val3 = Run_InstantiateUi; <>O.<2>__Run_InstantiateUi = val3; obj3 = (object)val3; } Run.InstantiateUi += (hook_InstantiateUi)obj3; (RealTimerUIController.format = ScriptableObject.CreateInstance()).format = new Format { prefix = "", suffix = "", units = (Unit[])(object)new Unit[2] { new Unit { name = "minutes", conversionRate = 60.0, minDigits = 2u, maxDigits = uint.MaxValue }, new Unit { name = "seconds", prefix = ":", conversionRate = 1.0, minDigits = 2u, maxDigits = 2u } } }; GameObject gameObject = ((Component)Addressables.LoadAssetAsync((object)"23b0bcee7bc7a0c4d91d884c778cc70a").WaitForCompletion().transform.GetChild(0).GetChild(1)).gameObject; } private static GameObject Run_InstantiateUi(orig_InstantiateUi orig, Run self, Transform uiRoot) { GameObject val = orig.Invoke(self, uiRoot); val.transform.GetChild(0); GameObject val2 = Object.Instantiate(Timer, val.transform.GetChild(0)); Object.Destroy((Object)(object)val2.GetComponent()); RealTimerUIController realTimerUIController = val2.AddComponent(); realTimerUIController.runStopwatchTimerTextController = val2.GetComponent(); realTimerUIController.Setup(); RealTimerUIController.instance = val2; val2.SetActive(false); return val; } private static void ScoreboardController_OnDisable(orig_OnDisable orig, ScoreboardController self) { orig.Invoke(self); if (Object.op_Implicit((Object)(object)RealTimerUIController.instance)) { RealTimerUIController.instance.SetActive(false); } } private static void ScoreboardController_OnEnable(orig_OnEnable orig, ScoreboardController self) { orig.Invoke(self); if (Object.op_Implicit((Object)(object)RealTimerUIController.instance) && WConfig.RealTimeTimer.Value) { RealTimerUIController.instance.SetActive(true); } } } public class RealTimerUIController : MonoBehaviour { public static TimerStringFormatter format; public static GameObject instance; public Transform realTimer; public float runStartingOffset; public TimerText runStopwatchTimerTextController; public void OnEnable() { //IL_0013: 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) runStartingOffset = 0.2f; Transform obj = realTimer; obj.localPosition += new Vector3(0f, 2f, 0f); } public void OnDisable() { //IL_0008: 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_0021: Unknown result type (might be due to invalid IL or missing references) Transform obj = realTimer; obj.localPosition -= new Vector3(0f, 2f, 0f); } public void Setup() { //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_0028: 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_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) runStopwatchTimerTextController.format = format; HGTextMeshProUGUI component = ((Component)this).GetComponent(); Color color = ((Graphic)component).color; ((Graphic)component).color = ((Color)(ref color)).AlphaMultiplied(0.25f); ((TMP_Text)component).alignment = (TextAlignmentOptions)516; ((Component)this).transform.localPosition = new Vector3(-32.5f, -10f, 0f); ((Component)this).transform.localScale = Vector3.one * 0.5f; realTimer = ((Component)this).transform.parent.GetChild(1); } private void Update() { if (Object.op_Implicit((Object)(object)runStopwatchTimerTextController)) { runStopwatchTimerTextController.seconds = (Object.op_Implicit((Object)(object)Run.instance) ? (Run.instance.fixedTime - runStartingOffset) : 0f); } } } public static class UI_Stuff { [CompilerGenerated] private static class <>O { public static hook_Awake <0>__AllowMoreChatMessages; public static hook_OnEnable <1>__CrosshairManager_OnEnable; public static Manipulator <2>__ScoreboardForDeadPeopleToo; public static hook_Rebuild <3>__AddDevotedLemurians; } [Serializable] [CompilerGenerated] private sealed class <>c { public static readonly <>c <>9 = new <>c(); public static hook_RebuildPing <>9__2_0; public static Func <>9__6_1; public static Func <>9__6_2; public static Func, List> <>9__6_0; internal void b__2_0(orig_RebuildPing orig, PingIndicator self) { orig.Invoke(self); self.fixedTimer *= 2f; } internal bool b__6_1(Instruction x) { return ILPatternMatchingExt.MatchStloc(x, 0); } internal List b__6_0(List self) { return PlayerCharacterMasterController.instances.Where((PlayerCharacterMasterController x) => ((Component)x).gameObject.activeInHierarchy && x.isConnected).ToList(); } internal bool b__6_2(PlayerCharacterMasterController x) { return ((Component)x).gameObject.activeInHierarchy && x.isConnected; } } public static GameObject DifficultyStat; public static GameObject UnlockContainer; public static void Start() { //IL_0011: 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_001c: Expected O, but got Unknown //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Unknown result type (might be due to invalid IL or missing references) //IL_003d: Expected O, but got Unknown //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_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_0095: 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_00a9: Unknown result type (might be due to invalid IL or missing references) //IL_00ae: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_005c: Unknown result type (might be due to invalid IL or missing references) //IL_0062: Expected O, but got Unknown //IL_0113: Unknown result type (might be due to invalid IL or missing references) //IL_0118: Unknown result type (might be due to invalid IL or missing references) //IL_011e: Expected O, but got Unknown //IL_0134: 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_013f: Expected O, but got Unknown object obj = <>O.<0>__AllowMoreChatMessages; if (obj == null) { hook_Awake val = AllowMoreChatMessages; <>O.<0>__AllowMoreChatMessages = val; obj = (object)val; } ChatBox.Awake += (hook_Awake)obj; object obj2 = <>O.<1>__CrosshairManager_OnEnable; if (obj2 == null) { hook_OnEnable val2 = CrosshairManager_OnEnable; <>O.<1>__CrosshairManager_OnEnable = val2; obj2 = (object)val2; } CrosshairManager.OnEnable += (hook_OnEnable)obj2; object obj3 = <>c.<>9__2_0; if (obj3 == null) { hook_RebuildPing val3 = delegate(orig_RebuildPing orig, PingIndicator self) { orig.Invoke(self); self.fixedTimer *= 2f; }; <>c.<>9__2_0 = val3; obj3 = (object)val3; } PingIndicator.RebuildPing += (hook_RebuildPing)obj3; GameObject chatBox = Addressables.LoadAssetAsync((object)"RoR2/Base/UI/ChatBox.prefab").WaitForCompletion(); GameObject chatBox2 = Addressables.LoadAssetAsync((object)"RoR2/Base/UI/ChatBox, In Run.prefab").WaitForCompletion(); GameObject val4 = Addressables.LoadAssetAsync((object)"RoR2/Base/UI/GameEndReportPanel.prefab").WaitForCompletion(); GameObject val5 = Addressables.LoadAssetAsync((object)"RoR2/DLC1/GameModes/InfiniteTowerRun/InfiniteTowerGameEndReportPanel.prefab").WaitForCompletion(); AllowScrolling(chatBox2); AllowScrolling(chatBox); DifficultyStat = ((Component)((Transform)val4.GetComponent().statContentArea).GetChild(0)).gameObject; UnlockContainer = ((Component)val4.transform.GetChild(0).GetChild(0).GetChild(0)).gameObject; object obj4 = <>O.<2>__ScoreboardForDeadPeopleToo; if (obj4 == null) { Manipulator val6 = ScoreboardForDeadPeopleToo; <>O.<2>__ScoreboardForDeadPeopleToo = val6; obj4 = (object)val6; } ScoreboardController.Rebuild += (Manipulator)obj4; object obj5 = <>O.<3>__AddDevotedLemurians; if (obj5 == null) { hook_Rebuild val7 = AddDevotedLemurians; <>O.<3>__AddDevotedLemurians = val7; obj5 = (object)val7; } ScoreboardController.Rebuild += (hook_Rebuild)obj5; MealMenu(); } private static void AddDevotedLemurians(orig_Rebuild orig, ScoreboardController self) { //IL_008c: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self); if (WConfig.cfgDevotedInventory.Value == WConfig.MessageWho.Off || DevotionInventoryController.InstanceList.Count == 0) { return; } foreach (PlayerCharacterMasterController instance in PlayerCharacterMasterController.instances) { if ((!((NetworkBehaviour)instance).isLocalPlayer && WConfig.cfgDevotedInventory.Value != WConfig.MessageWho.Anybody) || !instance.isConnected) { continue; } CharacterMaster master = instance.master; MinionGroup val = MinionGroup.FindGroup(((NetworkBehaviour)master).netId); if (val == null) { continue; } MinionOwnership[] members = val.members; foreach (MinionOwnership val2 in members) { if (Object.op_Implicit((Object)(object)val2) && Object.op_Implicit((Object)(object)((Component)val2).GetComponent())) { int count = self.stripAllocator.elements.Count; self.stripAllocator.AllocateElements(count + 1); self.stripAllocator.elements[count].SetMaster(((Component)val2).GetComponent()); ((TMP_Text)self.stripAllocator.elements[count].nameLabel).text = string.Format("{0}'s {1}s", Util.GetBestMasterName(master), Language.GetString("LEMURIAN_BODY_NAME")); break; } } } } public static void MealMenu() { //IL_001d: Unknown result type (might be due to invalid IL or missing references) //IL_0022: Unknown result type (might be due to invalid IL or missing references) //IL_005f: 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_0098: Unknown result type (might be due to invalid IL or missing references) //IL_00a7: Unknown result type (might be due to invalid IL or missing references) //IL_00ac: Unknown result type (might be due to invalid IL or missing references) //IL_00c4: Unknown result type (might be due to invalid IL or missing references) //IL_00d3: Unknown result type (might be due to invalid IL or missing references) //IL_00d8: Unknown result type (might be due to invalid IL or missing references) //IL_00eb: Unknown result type (might be due to invalid IL or missing references) //IL_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) if (WConfig.cfgChefMenuTweak.Value) { GameObject val = Addressables.LoadAssetAsync((object)"f503de92590d0ee40bae54e7a7d969c8").WaitForCompletion(); val.GetComponent().maxColumnCount = 10; Transform val2 = val.transform.Find("MainPanel/Juice/BGContainer/"); val2.GetChild(0).localScale = new Vector3(1.2f, 0.95f, 0.9f); val2.GetChild(0).localPosition = new Vector3(0f, -12f, 0f); Transform child = val2.GetChild(2); Transform obj = ((child is RectTransform) ? child : null); ((RectTransform)obj).offsetMax = ((RectTransform)obj).offsetMax + new Vector2(100f, 0f); Transform child2 = val2.GetChild(2); Transform obj2 = ((child2 is RectTransform) ? child2 : null); ((RectTransform)obj2).offsetMin = ((RectTransform)obj2).offsetMin - new Vector2(100f, 50f); Transform child3 = val2.GetChild(3); child3.localPosition += new Vector3(0f, -50f, 0f); } } private static string IncludeEliteTypeInSubjectName(orig_GetSubjectName orig, SubjectChatMessage self) { if ((Object)(object)self.subjectAsNetworkUser == (Object)null && Object.op_Implicit((Object)(object)self.subjectAsCharacterBody)) { return Util.GetBestBodyName(((Component)self.subjectAsCharacterBody).gameObject); } return orig.Invoke(self); } private static void ScoreboardForDeadPeopleToo(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown ILCursor val = new ILCursor(il); if (val.TryGotoNext((MoveType)0, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchStloc(x, 0) })) { val.EmitDelegate, List>>((Func, List>)((List self) => PlayerCharacterMasterController.instances.Where((PlayerCharacterMasterController x) => ((Component)x).gameObject.activeInHierarchy && x.isConnected).ToList())); } else { Log.LogWarning("IL Failed: ScoreboardForDeadPeopleToo"); } } public static void AllowScrolling(GameObject chatBox) { //IL_0073: Unknown result type (might be due to invalid IL or missing references) ChatBox component = chatBox.GetComponent(); component.scrollRect.vertical = true; component.scrollRect.scrollSensitivity = 6f; Transform child = chatBox.transform.GetChild(2).GetChild(0).GetChild(3) .GetChild(0); TMP_InputField component2 = ((Component)child).GetComponent(); ((Behaviour)((Selectable)component2).image).enabled = true; ((Graphic)((Selectable)component2).image).color = new Color(0f, 0f, 0f, 0f); } private static void AllowMoreChatMessages(orig_Awake orig, ChatBox self) { //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_009c: 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_00c8: Unknown result type (might be due to invalid IL or missing references) //IL_0185: Unknown result type (might be due to invalid IL or missing references) //IL_0121: Unknown result type (might be due to invalid IL or missing references) //IL_0138: 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_00ef: Unknown result type (might be due to invalid IL or missing references) //IL_0106: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self); if (((Object)self).name.EndsWith("In Run(Clone)")) { bool flag = Object.op_Implicit((Object)(object)((Component)self).transform.parent.parent.parent.parent.Find("DPSMeterPanel")); self.allowExpandedChatbox = true; RectTransform component = ((Component)self.inputField).GetComponent(); component.offsetMax = new Vector2(48f, 48f); component.offsetMin = new Vector2(-8f, 0f); RectTransform expandedChatboxRect = self.expandedChatboxRect; expandedChatboxRect.anchorMax = new Vector2(1f, 1f); expandedChatboxRect.offsetMax = new Vector2(120f, 0f); expandedChatboxRect.offsetMin = new Vector2(-10f, 49f); RectTransform standardChatboxRect = self.standardChatboxRect; if (flag) { standardChatboxRect.offsetMax = new Vector2(120f, 0f); standardChatboxRect.offsetMin = new Vector2(-10f, 49f); } else { standardChatboxRect.offsetMax = new Vector2(120f, -24f); standardChatboxRect.offsetMax = new Vector2(120f, -6f); standardChatboxRect.offsetMin = new Vector2(-10f, 0f); } } else if (((Object)self).name.EndsWith("ChatBox")) { self.expandedChatboxRect.offsetMax = new Vector2(0f, 196f); } } private static void CrosshairManager_OnEnable(orig_OnEnable orig, CrosshairManager self) { //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_0056: 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_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_00b3: Unknown result type (might be due to invalid IL or missing references) //IL_00c3: Unknown result type (might be due to invalid IL or missing references) //IL_00c8: Unknown result type (might be due to invalid IL or missing references) //IL_00d7: Unknown result type (might be due to invalid IL or missing references) //IL_00de: Expected O, but got Unknown //IL_00f3: 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_010a: Expected O, but got Unknown //IL_011f: Unknown result type (might be due to invalid IL or missing references) //IL_0166: Unknown result type (might be due to invalid IL or missing references) //IL_0188: Unknown result type (might be due to invalid IL or missing references) //IL_019b: Unknown result type (might be due to invalid IL or missing references) //IL_01ad: Unknown result type (might be due to invalid IL or missing references) //IL_01c3: Unknown result type (might be due to invalid IL or missing references) //IL_01da: Unknown result type (might be due to invalid IL or missing references) //IL_01df: Unknown result type (might be due to invalid IL or missing references) //IL_0203: Unknown result type (might be due to invalid IL or missing references) //IL_0208: Unknown result type (might be due to invalid IL or missing references) //IL_020d: Unknown result type (might be due to invalid IL or missing references) //IL_020f: Unknown result type (might be due to invalid IL or missing references) //IL_0218: Unknown result type (might be due to invalid IL or missing references) //IL_022f: Unknown result type (might be due to invalid IL or missing references) //IL_0234: Unknown result type (might be due to invalid IL or missing references) //IL_0258: Unknown result type (might be due to invalid IL or missing references) //IL_025d: Unknown result type (might be due to invalid IL or missing references) //IL_0262: Unknown result type (might be due to invalid IL or missing references) //IL_0264: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self); if (WConfig.cfgNewSprintCrosshair.Value) { GameObject val = Addressables.LoadAssetAsync((object)"RoR2/Base/UI/SprintingCrosshair.prefab").WaitForCompletion(); if (val.transform.childCount <= 0) { val.transform.localScale = Vector3.one * 1.1f; CrosshairController component = val.GetComponent(); RawImage component2 = val.GetComponent(); component.maxSpreadAngle = 8f; component2.texture = (Texture)(object)Addressables.LoadAssetAsync((object)"RoR2/Base/UI/texCrosshairDot.png").WaitForCompletion(); ((Graphic)component2).color = new Color(1f, 1f, 1f, 0.9f); Texture2D texture = Addressables.LoadAssetAsync((object)"RoR2/Base/UI/texCrosshairArrow.png").WaitForCompletion(); GameObject val2 = new GameObject("Right"); RawImage val3 = val2.AddComponent(); val3.texture = (Texture)(object)texture; ((Graphic)val3).color = ((Graphic)component2).color; GameObject val4 = new GameObject("Left"); val3 = val4.AddComponent(); val3.texture = (Texture)(object)texture; ((Graphic)val3).color = ((Graphic)component2).color; val2.transform.SetParent(val.transform); val4.transform.SetParent(val.transform); val2.transform.SetLocalEulerAngles(new Vector3(0f, 0f, -90f), (RotationOrder)0); val4.transform.SetLocalEulerAngles(new Vector3(0f, 0f, 90f), (RotationOrder)0); val2.transform.localScale = Vector3.one; val4.transform.localScale = Vector3.one; component.spriteSpreadPositions = (SpritePosition[])(object)new SpritePosition[2] { new SpritePosition { onePosition = new Vector3(96f, 0f, 0f), target = val4.GetComponent(), zeroPosition = new Vector3(24f, 0f, 0f) }, new SpritePosition { onePosition = new Vector3(-96f, 0f, 0f), target = val2.GetComponent(), zeroPosition = new Vector3(-24f, 0f, 0f) } }; } } } } public static class AudioStuff { [CompilerGenerated] private static class <>O { public static hook_OnEnter <0>__RestartMusicAfterSolusWing; } public static void Start() { //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_001a: Unknown result type (might be due to invalid IL or missing references) //IL_001f: Unknown result type (might be due to invalid IL or missing references) //IL_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_0085: 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_0040: Unknown result type (might be due to invalid IL or missing references) //IL_0045: Unknown result type (might be due to invalid IL or missing references) //IL_004b: Expected O, but got Unknown SceneDef val = Addressables.LoadAssetAsync((object)"RoR2/Base/rootjungle/rootjungle.asset").WaitForCompletion(); MusicTrackDef bossTrack = Addressables.LoadAssetAsync((object)"RoR2/DLC1/Common/muBossfightDLC1_12.asset").WaitForCompletion(); val.bossTrack = bossTrack; object obj = <>O.<0>__RestartMusicAfterSolusWing; if (obj == null) { hook_OnEnter val2 = RestartMusicAfterSolusWing; <>O.<0>__RestartMusicAfterSolusWing = val2; obj = (object)val2; } Mission5Death.OnEnter += (hook_OnEnter)obj; GameObject val3 = Addressables.LoadAssetAsync((object)"c6f87be1350f96b4c8545a4ae7f22207").WaitForCompletion(); val3.GetComponent().DoNotPool = true; PlaySoundOnEvent val4 = val3.AddComponent(); val4.soundEvent = "Play_item_proc_extraShrineItem"; val4.triggeringEvent = (PlaySoundEvent)2; val4 = val3.AddComponent(); val4.soundEvent = "Play_item_proc_extraShrineItem"; val4.triggeringEvent = (PlaySoundEvent)2; } private static void RestartMusicAfterSolusWing(orig_OnEnter orig, Mission5Death self) { orig.Invoke(self); if (WConfig.SH_Music_Restarter.Value) { ((SolusWing2BaseMissionState)self).solutionalHauntReferences.PostFightMusic.AddComponent().duration = 10f; } } } public static class ColorModule { [CompilerGenerated] private static class <>O { public static hook_BuildPickupEntries <0>__EquipmentAddBG; public static Action <1>__NewColorOutlineIcons; public static hook_Init <2>__PickupCatalog_Init; public static hook_CreatePickupDef <3>__ItemDef_CreatePickupDef; public static hook_CreatePickupDef <4>__EquipmentDef_CreatePickupDef; } public static GameObject EquipmentBossOrb; public static GameObject EquipmentLunarOrb; public static GameObject NoTierOrb; public static Color NewSurvivorLogbookNameColor = Color32.op_Implicit(new Color32((byte)80, (byte)130, (byte)173, byte.MaxValue)); public static Color ColorEquip_Lunar; public static Color ColorEquip_Boss; public static Color ColorEquip_Consumed; public static Color Color_Quest; public static Color Color_QuestDark; public static Color Color_Temp; public static Texture2D texEquipmentBossBG = new Texture2D(512, 512, (TextureFormat)12, false); public static Texture2D texEquipmentLunarBG = new Texture2D(512, 512, (TextureFormat)12, false); public static ColorIndex index_EquipLunar = (ColorIndex)4; public static ColorIndex index_EquipBoss = (ColorIndex)13; public static ColorIndex index_EquipConsumed = (ColorIndex)5; public static ColorIndex index_Void1 = (ColorIndex)25; public static ColorIndex index_Void3 = (ColorIndex)25; public static ColorIndex index_Void4 = (ColorIndex)25; public static ColorIndex index_Food = (ColorIndex)5; public static ColorIndex index_Quest = (ColorIndex)13; public static ColorIndex index_QuestDark = (ColorIndex)22; public static void Main() { //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_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_008f: Unknown result type (might be due to invalid IL or missing references) //IL_0094: Unknown result type (might be due to invalid IL or missing references) //IL_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_00a3: Unknown result type (might be due to invalid IL or missing references) //IL_00a8: Unknown result type (might be due to invalid IL or missing references) //IL_00a9: Unknown result type (might be due to invalid IL or missing references) //IL_00ae: Unknown result type (might be due to invalid IL or missing references) //IL_00b3: Unknown result type (might be due to invalid IL or missing references) //IL_00b4: Unknown result type (might be due to invalid IL or missing references) //IL_00b9: Unknown result type (might be due to invalid IL or missing references) //IL_00be: Unknown result type (might be due to invalid IL or missing references) //IL_00bf: Unknown result type (might be due to invalid IL or missing references) //IL_00c4: Unknown result type (might be due to invalid IL or missing references) //IL_00c9: Unknown result type (might be due to invalid IL or missing references) //IL_00ca: Unknown result type (might be due to invalid IL or missing references) //IL_00cf: Unknown result type (might be due to invalid IL or missing references) //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_0106: Unknown result type (might be due to invalid IL or missing references) //IL_010b: Unknown result type (might be due to invalid IL or missing references) //IL_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_011f: 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_0129: 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_0185: Expected O, but got Unknown //IL_01c1: Unknown result type (might be due to invalid IL or missing references) //IL_01c6: Unknown result type (might be due to invalid IL or missing references) //IL_01cc: Expected O, but got Unknown //IL_01e2: Unknown result type (might be due to invalid IL or missing references) //IL_01e7: Unknown result type (might be due to invalid IL or missing references) //IL_01ed: Expected O, but got Unknown //IL_0203: Unknown result type (might be due to invalid IL or missing references) //IL_0208: Unknown result type (might be due to invalid IL or missing references) //IL_020e: Expected O, but got Unknown ColorUtility.TryParseHtmlString("#78AFFF", ref ColorEquip_Lunar); ColorUtility.TryParseHtmlString("#FFC211", ref ColorEquip_Boss); ColorUtility.TryParseHtmlString("#C9731D", ref ColorEquip_Consumed); ColorUtility.TryParseHtmlString("#8bc7d5", ref Color_Temp); Color val = default(Color); ColorUtility.TryParseHtmlString("#FF9EEC", ref val); Color val2 = default(Color); ColorUtility.TryParseHtmlString("#FF73BF", ref val2); Color val3 = default(Color); ColorUtility.TryParseHtmlString("#E658A6", ref val3); Color val4 = default(Color); ColorUtility.TryParseHtmlString("#FF994B", ref val4); OrbMaker(); index_EquipLunar = ColorsAPI.RegisterColor(ColorEquip_Lunar); index_EquipBoss = ColorsAPI.RegisterColor(ColorEquip_Boss); index_EquipConsumed = ColorsAPI.RegisterColor(ColorEquip_Consumed); index_Void1 = ColorsAPI.RegisterColor(val); index_Void3 = ColorsAPI.RegisterColor(val2); index_Void4 = ColorsAPI.RegisterColor(val3); index_Food = ColorsAPI.RegisterColor(val4); Color_Quest = new Color(0.9216f, 1f, 0.0157f, 1f); Color_QuestDark = new Color(0.7059f, 0.7412f, 0.2353f, 1f); index_Quest = ColorsAPI.RegisterColor(Color_Quest); index_QuestDark = ColorsAPI.RegisterColor(Color_QuestDark); texEquipmentBossBG = Assets.Bundle.LoadAsset("Assets/WQoL/General/texEquipmentBossBG.png"); texEquipmentLunarBG = Assets.Bundle.LoadAsset("Assets/WQoL/General/texEquipmentLunarBG.png"); if (WConfig.cfgColorMain.Value) { object obj = <>O.<0>__EquipmentAddBG; if (obj == null) { hook_BuildPickupEntries val5 = EquipmentAddBG; <>O.<0>__EquipmentAddBG = val5; obj = (object)val5; } LogBookController.BuildPickupEntries += (hook_BuildPickupEntries)obj; ((ResourceAvailability)(ref EquipmentCatalog.availability)).CallWhenAvailable((Action)NewColorOutlineIcons); object obj2 = <>O.<2>__PickupCatalog_Init; if (obj2 == null) { hook_Init val6 = PickupCatalog_Init; <>O.<2>__PickupCatalog_Init = val6; obj2 = (object)val6; } PickupCatalog.Init += (hook_Init)obj2; object obj3 = <>O.<3>__ItemDef_CreatePickupDef; if (obj3 == null) { hook_CreatePickupDef val7 = ItemDef_CreatePickupDef; <>O.<3>__ItemDef_CreatePickupDef = val7; obj3 = (object)val7; } ItemDef.CreatePickupDef += (hook_CreatePickupDef)obj3; object obj4 = <>O.<4>__EquipmentDef_CreatePickupDef; if (obj4 == null) { hook_CreatePickupDef val8 = EquipmentDef_CreatePickupDef; <>O.<4>__EquipmentDef_CreatePickupDef = val8; obj4 = (object)val8; } EquipmentDef.CreatePickupDef += (hook_CreatePickupDef)obj4; } PlayerPing.Hooks(); } public static Entry[] EquipmentAddBG(orig_BuildPickupEntries orig, Dictionary expansionAvailability) { //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_0024: 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_0032: Invalid comparison between Unknown and I4 //IL_003f: Unknown result type (might be due to invalid IL or missing references) Entry[] array = orig.Invoke(expansionAvailability); for (int i = 0; i < array.Length; i++) { PickupIndex val = PickupCatalog.FindPickupIndex(array[i].extraData.ToString()); PickupDef pickupDef = PickupCatalog.GetPickupDef(val); if ((int)pickupDef.equipmentIndex == -1) { continue; } EquipmentDef equipmentDef = EquipmentCatalog.GetEquipmentDef(pickupDef.equipmentIndex); if (WConfig.cfgColorMain.Value) { if (equipmentDef.isBoss) { array[i].bgTexture = (Texture)(object)texEquipmentBossBG; } else if (equipmentDef.isLunar) { array[i].bgTexture = (Texture)(object)texEquipmentLunarBG; } } } return array; } private static PickupDef ItemDef_CreatePickupDef(orig_CreatePickupDef orig, ItemDef self) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Invalid comparison between Unknown and I4 if ((int)self.tier == 5) { PickupDef val = orig.Invoke(self); val.dropletDisplayPrefab = NoTierOrb; return val; } return orig.Invoke(self); } private static PickupDef EquipmentDef_CreatePickupDef(orig_CreatePickupDef orig, EquipmentDef self) { PickupDef val = orig.Invoke(self); if (self.isBoss) { val.dropletDisplayPrefab = EquipmentBossOrb; } else if (self.isLunar) { val.dropletDisplayPrefab = EquipmentLunarOrb; } return val; } public static void MissingSceneColors() { //IL_001f: Unknown result type (might be due to invalid IL or missing references) //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_0029: 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_0050: 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_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_009d: Unknown result type (might be due to invalid IL or missing references) //IL_00a2: Unknown result type (might be due to invalid IL or missing references) //IL_00a7: Unknown result type (might be due to invalid IL or missing references) //IL_00c7: Unknown result type (might be due to invalid IL or missing references) //IL_00cc: Unknown result type (might be due to invalid IL or missing references) //IL_00d1: Unknown result type (might be due to invalid IL or missing references) //IL_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_00fb: 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_0145: Unknown result type (might be due to invalid IL or missing references) //IL_014a: Unknown result type (might be due to invalid IL or missing references) //IL_014f: Unknown result type (might be due to invalid IL or missing references) //IL_016a: Unknown result type (might be due to invalid IL or missing references) //IL_016f: Unknown result type (might be due to invalid IL or missing references) //IL_0174: Unknown result type (might be due to invalid IL or missing references) //IL_0197: Unknown result type (might be due to invalid IL or missing references) //IL_019c: Unknown result type (might be due to invalid IL or missing references) //IL_01bf: 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_01e7: 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_020f: Unknown result type (might be due to invalid IL or missing references) //IL_0214: Unknown result type (might be due to invalid IL or missing references) //IL_0219: Unknown result type (might be due to invalid IL or missing references) //IL_023c: 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_0246: Unknown result type (might be due to invalid IL or missing references) //IL_0263: Unknown result type (might be due to invalid IL or missing references) //IL_0268: Unknown result type (might be due to invalid IL or missing references) //IL_026d: Unknown result type (might be due to invalid IL or missing references) //IL_0290: Unknown result type (might be due to invalid IL or missing references) //IL_0295: 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_02b4: Unknown result type (might be due to invalid IL or missing references) //IL_02b9: Unknown result type (might be due to invalid IL or missing references) //IL_02be: Unknown result type (might be due to invalid IL or missing references) //IL_02de: Unknown result type (might be due to invalid IL or missing references) //IL_02e3: Unknown result type (might be due to invalid IL or missing references) //IL_02e8: Unknown result type (might be due to invalid IL or missing references) //IL_0308: Unknown result type (might be due to invalid IL or missing references) //IL_030d: Unknown result type (might be due to invalid IL or missing references) //IL_0312: Unknown result type (might be due to invalid IL or missing references) //IL_0331: Unknown result type (might be due to invalid IL or missing references) //IL_0336: Unknown result type (might be due to invalid IL or missing references) //IL_033b: Unknown result type (might be due to invalid IL or missing references) SceneCatalog.FindSceneDef("lakes").environmentColor = Color32.op_Implicit(new Color32((byte)153, (byte)247, (byte)219, byte.MaxValue)); SceneCatalog.FindSceneDef("lakesnight").environmentColor = Color32.op_Implicit(new Color32((byte)116, (byte)93, (byte)166, byte.MaxValue)); SceneCatalog.FindSceneDef("village").environmentColor = Color32.op_Implicit(new Color32((byte)170, (byte)179, (byte)145, byte.MaxValue)); SceneCatalog.FindSceneDef("villagenight").environmentColor = Color32.op_Implicit(new Color32((byte)71, (byte)137, (byte)168, byte.MaxValue)); SceneCatalog.FindSceneDef("lemuriantemple").environmentColor = Color32.op_Implicit(new Color32((byte)246, (byte)188, (byte)67, byte.MaxValue)); SceneCatalog.FindSceneDef("habitat").environmentColor = Color32.op_Implicit(new Color32((byte)163, (byte)182, (byte)94, byte.MaxValue)); SceneCatalog.FindSceneDef("habitatfall").environmentColor = Color32.op_Implicit(new Color32((byte)214, (byte)121, (byte)66, byte.MaxValue)); SceneCatalog.FindSceneDef("meridian").environmentColor = Color32.op_Implicit(new Color32((byte)132, (byte)201, byte.MaxValue, byte.MaxValue)); SceneCatalog.FindSceneDef("helminthroost").environmentColor = Color32.op_Implicit(new Color32((byte)203, (byte)0, (byte)0, byte.MaxValue)); SceneCatalog.FindSceneDef("artifactworld01").environmentColor = new Color(0.6f, 0.2f, 0.18f, 1f); SceneCatalog.FindSceneDef("artifactworld02").environmentColor = new Color(0.5f, 0.5f, 0.18f, 1f); SceneCatalog.FindSceneDef("artifactworld03").environmentColor = new Color(0.5f, 0.25f, 0.18f, 1f); SceneCatalog.FindSceneDef("nest").environmentColor = Color32.op_Implicit(new Color32((byte)145, (byte)170, (byte)198, byte.MaxValue)); SceneCatalog.FindSceneDef("ironalluvium").environmentColor = Color32.op_Implicit(new Color32((byte)228, (byte)194, (byte)134, byte.MaxValue)); SceneCatalog.FindSceneDef("ironalluvium2").environmentColor = Color32.op_Implicit(new Color32((byte)87, (byte)136, (byte)105, byte.MaxValue)); SceneCatalog.FindSceneDef("repurposedcrater").environmentColor = Color32.op_Implicit(new Color32((byte)230, (byte)158, (byte)139, byte.MaxValue)); SceneCatalog.FindSceneDef("conduitcanyon").environmentColor = Color32.op_Implicit(new Color32((byte)16, (byte)77, (byte)107, byte.MaxValue)); SceneCatalog.FindSceneDef("solutionalhaunt").environmentColor = Color32.op_Implicit(new Color32((byte)79, (byte)163, (byte)170, byte.MaxValue)); SceneCatalog.FindSceneDef("computationalexchange").environmentColor = Color32.op_Implicit(new Color32((byte)90, (byte)219, (byte)181, byte.MaxValue)); SceneCatalog.FindSceneDef("solusweb").environmentColor = Color32.op_Implicit(new Color32(byte.MaxValue, (byte)0, (byte)148, byte.MaxValue)); } private static IEnumerator PickupCatalog_Init(orig_Init orig) { ChangeColorsViaIndex(); return orig.Invoke(); } public static void OrbMaker() { //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_001a: Unknown result type (might be due to invalid IL or missing references) //IL_001f: Unknown result type (might be due to invalid IL or missing references) //IL_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_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_0100: 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_0106: Unknown result type (might be due to invalid IL or missing references) //IL_013a: 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_0175: 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_0193: Unknown result type (might be due to invalid IL or missing references) //IL_0195: Unknown result type (might be due to invalid IL or missing references) //IL_019e: Unknown result type (might be due to invalid IL or missing references) //IL_01a6: Unknown result type (might be due to invalid IL or missing references) //IL_01ab: Unknown result type (might be due to invalid IL or missing references) //IL_01bc: 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_01e0: Unknown result type (might be due to invalid IL or missing references) //IL_01e5: Unknown result type (might be due to invalid IL or missing references) //IL_01e9: 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_021a: Unknown result type (might be due to invalid IL or missing references) //IL_021f: Unknown result type (might be due to invalid IL or missing references) //IL_0223: Unknown result type (might be due to invalid IL or missing references) //IL_0228: 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_0253: Unknown result type (might be due to invalid IL or missing references) //IL_0254: Unknown result type (might be due to invalid IL or missing references) //IL_0288: Unknown result type (might be due to invalid IL or missing references) //IL_02ae: Unknown result type (might be due to invalid IL or missing references) //IL_02c3: Unknown result type (might be due to invalid IL or missing references) //IL_02cb: Unknown result type (might be due to invalid IL or missing references) //IL_02d0: Unknown result type (might be due to invalid IL or missing references) //IL_02e1: Unknown result type (might be due to invalid IL or missing references) //IL_02e3: Unknown result type (might be due to invalid IL or missing references) //IL_02ec: Unknown result type (might be due to invalid IL or missing references) //IL_02f4: Unknown result type (might be due to invalid IL or missing references) //IL_02f9: Unknown result type (might be due to invalid IL or missing references) //IL_030a: Unknown result type (might be due to invalid IL or missing references) //IL_030c: Unknown result type (might be due to invalid IL or missing references) //IL_032e: Unknown result type (might be due to invalid IL or missing references) //IL_0333: Unknown result type (might be due to invalid IL or missing references) //IL_0337: Unknown result type (might be due to invalid IL or missing references) //IL_033c: Unknown result type (might be due to invalid IL or missing references) //IL_0368: Unknown result type (might be due to invalid IL or missing references) //IL_036d: Unknown result type (might be due to invalid IL or missing references) //IL_0371: Unknown result type (might be due to invalid IL or missing references) //IL_0376: Unknown result type (might be due to invalid IL or missing references) //IL_0410: Unknown result type (might be due to invalid IL or missing references) //IL_0444: Unknown result type (might be due to invalid IL or missing references) //IL_0478: Unknown result type (might be due to invalid IL or missing references) GameObject val = Addressables.LoadAssetAsync((object)"7c61d88eadef8a94ebf06138b6d2c2cb").WaitForCompletion(); EquipmentBossOrb = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"47decc91b30009d41a6b60735cd38ed9").WaitForCompletion(), "EquipmentBossOrb", false); EquipmentLunarOrb = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"69411ae2cb84bd744827d19b2042f749").WaitForCompletion(), "EquipmentLunarOrb", false); NoTierOrb = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"62b4a745e2a56ad4880ba1418a12ee85").WaitForCompletion(), "NoTierOrb", false); Color val2 = default(Color); ((Color)(ref val2))..ctor(0.2f, 0.2f, 0.2f, 0f); Color val3 = default(Color); ((Color)(ref val3))..ctor(0.5f, 0.5f, 0.5f, 1f); PlaySoundOnEvent[] components = EquipmentBossOrb.GetComponents(); components[0].soundEvent = "Play_item_use_bossHunter"; components[1].soundEvent = "Play_UI_item_land_tier3"; components[0].akSoundEvent = null; components[1].akSoundEvent = null; ((Component)EquipmentBossOrb.transform.GetChild(0)).GetComponent().startColor = ColorEquip_Boss * val3; ((Component)EquipmentBossOrb.transform.GetChild(0)).GetComponent().endColor = new Color(1f, 0f, 0f, 0f); ((Component)EquipmentBossOrb.transform.GetChild(0).GetChild(2)).GetComponent().color = ColorEquip_Boss; GradientColorKey[] colorKeys = (GradientColorKey[])(object)new GradientColorKey[2] { new GradientColorKey { color = ColorEquip_Boss, time = 0f }, new GradientColorKey { color = ColorEquip_Boss, time = 1f } }; ColorOverLifetimeModule colorOverLifetime = ((Component)EquipmentBossOrb.transform.GetChild(0).GetChild(0)).GetComponent().colorOverLifetime; MinMaxGradient color = ((ColorOverLifetimeModule)(ref colorOverLifetime)).color; ((MinMaxGradient)(ref color)).gradient.colorKeys = colorKeys; colorOverLifetime = ((Component)EquipmentBossOrb.transform.GetChild(0).GetChild(1)).GetComponent().colorOverLifetime; color = ((ColorOverLifetimeModule)(ref colorOverLifetime)).color; ((MinMaxGradient)(ref color)).gradient.colorKeys = colorKeys; ((Component)EquipmentLunarOrb.transform.GetChild(0)).GetComponent().startColor = ColorEquip_Lunar * val3; ((Component)EquipmentLunarOrb.transform.GetChild(0)).GetComponent().endColor = new Color(0f, 0f, 1f, 0f); ((Component)EquipmentLunarOrb.transform.GetChild(0).GetChild(1)).GetComponent().color = ColorEquip_Lunar; GradientColorKey[] colorKeys2 = (GradientColorKey[])(object)new GradientColorKey[2] { new GradientColorKey { color = ColorEquip_Lunar, time = 0f }, new GradientColorKey { color = ColorEquip_Lunar, time = 1f } }; colorOverLifetime = ((Component)EquipmentLunarOrb.transform.GetChild(0).GetChild(0)).GetComponent().colorOverLifetime; color = ((ColorOverLifetimeModule)(ref colorOverLifetime)).color; ((MinMaxGradient)(ref color)).gradient.colorKeys = colorKeys2; colorOverLifetime = ((Component)EquipmentLunarOrb.transform.GetChild(0).GetChild(2)).GetComponent().colorOverLifetime; color = ((ColorOverLifetimeModule)(ref colorOverLifetime)).color; ((MinMaxGradient)(ref color)).gradient.colorKeys = colorKeys2; Object.Instantiate(((Component)val.transform.GetChild(0).GetChild(2)).gameObject, EquipmentBossOrb.transform.GetChild(0)); Object.Instantiate(((Component)val.transform.GetChild(0).GetChild(2)).gameObject, EquipmentLunarOrb.transform.GetChild(0)); ((Component)NoTierOrb.transform.GetChild(0).GetChild(0)).GetComponent().startColor = new Color(0.1f, 0.1f, 0.1f, 1f); ((Component)NoTierOrb.transform.GetChild(0)).GetComponent().startColor = new Color(0f, 0f, 0f, 0f); ((Component)NoTierOrb.transform.GetChild(0)).GetComponent().endColor = new Color(0.5f, 0.5f, 0.5f, 1f); components = NoTierOrb.GetComponents(); components[0].soundEvent = "Play_ui_lunar_coin_drop"; components[1].soundEvent = "Play_UI_lunarCache_open"; components[0].akSoundEvent = null; components[1].akSoundEvent = null; } public static void ChangeColorsViaIndex() { //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_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_0026: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_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_00b4: Unknown result type (might be due to invalid IL or missing references) //IL_00b9: Unknown result type (might be due to invalid IL or missing references) //IL_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_00ea: 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) if (WConfig.cfgColorVoids.Value) { ItemTierCatalog.GetItemTierDef((ItemTier)6).colorIndex = index_Void1; ItemTierCatalog.GetItemTierDef((ItemTier)8).colorIndex = index_Void3; ItemTierCatalog.GetItemTierDef((ItemTier)9).colorIndex = index_Void4; } ItemTierCatalog.GetItemTierDef((ItemTier)10).colorIndex = index_Food; ItemTierCatalog.GetItemTierDef((ItemTier)10).bgIconTexture = (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/General/FoodBGIcon.png"); for (int i = 0; EquipmentCatalog.equipmentDefs.Length > i; i++) { EquipmentDef val = EquipmentCatalog.equipmentDefs[i]; if (Object.op_Implicit((Object)(object)val.passiveBuffDef) && val.passiveBuffDef.isElite) { val.isBoss = true; } if (val.isBoss) { val.colorIndex = index_EquipBoss; } else if (val.isLunar) { val.colorIndex = index_EquipLunar; } else if (val.isConsumed) { val.colorIndex = index_EquipConsumed; } } } public static void ChangeColorsPost() { //IL_0006: 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_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_0026: Unknown result type (might be due to invalid IL or missing references) //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Unknown result type (might be due to invalid IL or missing references) //IL_003c: Unknown result type (might be due to invalid IL or missing references) //IL_0046: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Invalid comparison between Unknown and I4 //IL_0065: Unknown result type (might be due to invalid IL or missing references) //IL_006a: Unknown result type (might be due to invalid IL or missing references) //IL_0074: 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_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_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) PickupCatalog.GetPickupDef(PickupCatalog.FindPickupIndex("LunarCoin.Coin0")).baseColor = Color32.op_Implicit(ColorCatalog.GetColor((ColorIndex)12)); PickupCatalog.GetPickupDef(PickupCatalog.FindPickupIndex("LunarCoin.Coin0")).darkColor = Color32.op_Implicit(ColorCatalog.GetColor((ColorIndex)12)); if ((int)Items.LevelBonus.tier == 5) { Color baseColor = default(Color); ColorUtility.TryParseHtmlString("#ECFC80", ref baseColor); PickupCatalog.GetPickupDef(PickupCatalog.FindPickupIndex(Items.UseAmbientLevel.itemIndex)).baseColor = baseColor; PickupCatalog.GetPickupDef(PickupCatalog.FindPickupIndex(Items.LevelBonus.itemIndex)).baseColor = Color_Quest; } } public static void AddMissingItemHighlights() { //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_001a: Unknown result type (might be due to invalid IL or missing references) //IL_001f: Unknown result type (might be due to invalid IL or missing references) //IL_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_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_0059: 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) //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_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_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) GameObject val = Addressables.LoadAssetAsync((object)"730ea84bde179504e985c5f3c66db36b").WaitForCompletion(); Sprite cornerImage = Addressables.LoadAssetAsync((object)"43a45be290137ab439552af4ff6eb6c4").WaitForCompletion(); Addressables.LoadAssetAsync((object)"RoR2/Base/UI/HighlightLunarItem.prefab").WaitForCompletion().GetComponent() .highlightColor = Color32.op_Implicit(new Color32((byte)55, (byte)101, byte.MaxValue, byte.MaxValue)); Addressables.LoadAssetAsync((object)"RoR2/Base/UI/HighlightBossItem.prefab").WaitForCompletion().GetComponent() .cornerImage = cornerImage; Addressables.LoadAssetAsync((object)"RoR2/Base/UI/HighlightVoidBossItem.prefab").WaitForCompletion().GetComponent() .cornerImage = cornerImage; GameObject val2 = PrefabAPI.InstantiateClone(val, "HighlightEquipmentLunar", false); GameObject val3 = PrefabAPI.InstantiateClone(val, "HighlightEquipmentBoss", false); val2.GetComponent().highlightColor = ColorEquip_Lunar; val3.GetComponent().highlightColor = new Color(1f, 0.75f, 0f, 1f); val3.GetComponent().cornerImage = cornerImage; EquipmentCatalog.lunarEquipmentHighlightPrefab = val2; EquipmentCatalog.bossEquipmentHighlightPrefab = val3; } public static void NewColorOutlineIcons() { Equipment.AffixRed.pickupIconSprite = Assets.Bundle.LoadAsset("Assets/WQoL/Items/EliteFire.png"); Equipment.AffixBlue.pickupIconSprite = Assets.Bundle.LoadAsset("Assets/WQoL/Items/EliteLightning.png"); Equipment.AffixWhite.pickupIconSprite = Assets.Bundle.LoadAsset("Assets/WQoL/Items/EliteIce.png"); Equipment.AffixPoison.pickupIconSprite = Assets.Bundle.LoadAsset("Assets/WQoL/Items/ElitePoison.png"); Equipment.AffixHaunted.pickupIconSprite = Assets.Bundle.LoadAsset("Assets/WQoL/Items/EliteHaunted.png"); Equipment.AffixLunar.pickupIconSprite = Assets.Bundle.LoadAsset("Assets/WQoL/Items/EliteLunar.png"); Equipment.EliteEarthEquipment.pickupIconSprite = Assets.Bundle.LoadAsset("Assets/WQoL/Items/EliteEarth.png"); Equipment.EliteVoidEquipment.pickupIconSprite = Assets.Bundle.LoadAsset("Assets/WQoL/Items/EliteVoid.png"); Equipment.EliteSecretSpeedEquipment.pickupIconSprite = Assets.Bundle.LoadAsset("Assets/WQoL/Items/EliteSecret.png"); Equipment.EliteAurelioniteEquipment.pickupIconSprite = Assets.Bundle.LoadAsset("Assets/WQoL/Items/EliteAurelionite.png"); Equipment.EliteBeadEquipment.pickupIconSprite = Assets.Bundle.LoadAsset("Assets/WQoL/Items/EliteBead.png"); Equipment.EliteCollectiveEquipment.pickupIconSprite = Assets.Bundle.LoadAsset("Assets/WQoL/Items/EliteCollective.png"); Equipment.CrippleWard.pickupIconSprite = Assets.Bundle.LoadAsset("Assets/WQoL/Items/LunarEffigy.png"); Equipment.Meteor.pickupIconSprite = Assets.Bundle.LoadAsset("Assets/WQoL/Items/LunarMeteor.png"); Equipment.BurnNearby.pickupIconSprite = Assets.Bundle.LoadAsset("Assets/WQoL/Items/LunarHelfire.png"); Equipment.Tonic.pickupIconSprite = Assets.Bundle.LoadAsset("Assets/WQoL/Items/LunarPotion.png"); Equipment.LunarPortalOnUse.pickupIconSprite = Assets.Bundle.LoadAsset("Assets/WQoL/Items/LunarPortal.png"); Items.CritHeal.pickupIconSprite = Assets.Bundle.LoadAsset("Assets/WQoL/Items/Beta/betaCorpse.png"); Items.CrippleWardOnLevel.pickupIconSprite = Assets.Bundle.LoadAsset("Assets/WQoL/Items/Beta/betaEffigy.png"); Items.BurnNearby.pickupIconSprite = Assets.Bundle.LoadAsset("Assets/WQoL/Items/Beta/betaHelfire.png"); Items.TempestOnKill.pickupIconSprite = Assets.Bundle.LoadAsset("Assets/WQoL/Items/Beta/betaTempest.png"); Items.WarCryOnCombat.pickupIconSprite = Assets.Bundle.LoadAsset("Assets/WQoL/Items/Beta/betaPauldron.png"); Items.CooldownOnCrit.pickupIconSprite = Assets.Bundle.LoadAsset("Assets/WQoL/Items/Beta/betaWicked.png"); } public static void ModSupport() { } } public static class PlayerPing { [CompilerGenerated] private static class <>O { public static Manipulator <0>__PlayerPingsIL; public static hook_GetDisplayName <1>__ColoredItem_Pickup; public static hook_GetFormattedTargetString <2>__ColoredItem_Shops; } public static PingType playerPingType = (PingType)73; public static Color playerTeamPingColor2 = new Color(0.125f, 0.425f, 0.65f, 1f); public static Color playerTeamPingColor = new Color(0.49f, 0.843f, 0.96f, 1f); public static void Hooks() { //IL_0011: 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_001c: Expected O, but got Unknown //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Unknown result type (might be due to invalid IL or missing references) //IL_003d: Expected O, but got Unknown //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_005e: Expected O, but got Unknown object obj = <>O.<0>__PlayerPingsIL; if (obj == null) { Manipulator val = PlayerPingsIL; <>O.<0>__PlayerPingsIL = val; obj = (object)val; } PingIndicator.RebuildPing += (Manipulator)obj; object obj2 = <>O.<1>__ColoredItem_Pickup; if (obj2 == null) { hook_GetDisplayName val2 = ColoredItem_Pickup; <>O.<1>__ColoredItem_Pickup = val2; obj2 = (object)val2; } GenericPickupController.GetDisplayName += (hook_GetDisplayName)obj2; object obj3 = <>O.<2>__ColoredItem_Shops; if (obj3 == null) { hook_GetFormattedTargetString val3 = ColoredItem_Shops; <>O.<2>__ColoredItem_Shops = val3; obj3 = (object)val3; } PingIndicator.GetFormattedTargetString += (hook_GetFormattedTargetString)obj3; } public static void PlayerPingsIL(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown //IL_00b1: Unknown result type (might be due to invalid IL or missing references) ILCursor val = new ILCursor(il); val.TryGotoNext((MoveType)0, new Func[2] { (Instruction x) => ILPatternMatchingExt.MatchLdcI4(x, 1), (Instruction x) => ILPatternMatchingExt.MatchStfld(x, "RoR2.UI.PingIndicator", "pingType") }); if (val.TryGotoPrev((MoveType)2, new Func[2] { (Instruction x) => ILPatternMatchingExt.MatchCall(x, "RoR2.UI.PingIndicator", "get_pingTarget"), (Instruction x) => ILPatternMatchingExt.MatchCall(x, "UnityEngine.Object", "op_Implicit") })) { val.Emit(OpCodes.Ldarg_0); val.EmitDelegate>((Func)delegate(bool doesEx, PingIndicator self) { //IL_0047: Unknown result type (might be due to invalid IL or missing references) //IL_004d: Invalid comparison between Unknown and I4 //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) if (WConfig.cfgPlayerPing.Value && Object.op_Implicit((Object)(object)self.pingTarget)) { CharacterBody component = self.pingTarget.GetComponent(); if (Object.op_Implicit((Object)(object)component) && Object.op_Implicit((Object)(object)component.teamComponent) && (int)component.teamComponent.teamIndex == 1) { Debug.LogFormat("Ping playerTeam target {0}", new object[1] { self.pingTarget }); self.pingType = playerPingType; return false; } } return doesEx; }); } else { Log.LogWarning("IL Failed: PlayerPingsIL"); } if (val.TryGotoNext((MoveType)0, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchLdfld(x, "RoR2.UI.PingIndicator", "pingType") })) { val.EmitDelegate>((Func)delegate(PingIndicator self) { BuildPlayerPing(self); return self; }); } else { Log.LogWarning("IL Failed: PlayerPingsILPart2"); } } public static void BuildPlayerPing(PingIndicator self) { //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_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_0111: Unknown result type (might be due to invalid IL or missing references) //IL_0116: Unknown result type (might be due to invalid IL or missing references) //IL_0119: 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_0269: Unknown result type (might be due to invalid IL or missing references) //IL_027b: 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_0151: 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) Transform val = self.defaultPingGameObjects[0].transform.parent.Find("Player"); Transform val2 = self.enemyPingGameObjects[1].transform.parent.Find("PlayerPositionRing"); if (Object.op_Implicit((Object)(object)val)) { ((Component)val).gameObject.SetActive(false); ((Component)val2).gameObject.SetActive(false); } if (self.pingType != playerPingType) { return; } string ownerName = self.GetOwnerName(); string bestBodyName = Util.GetBestBodyName(self.pingTarget); self.pingColor = playerTeamPingColor; self.pingDuration = self.enemyPingDuration; ModelLocator component = self.pingTarget.GetComponent(); if (!Object.op_Implicit((Object)(object)component)) { return; } Transform modelTransform = component.modelTransform; if (Object.op_Implicit((Object)(object)modelTransform)) { CharacterModel component2 = ((Component)modelTransform).GetComponent(); if (Object.op_Implicit((Object)(object)component2)) { self.targetTransformToFollow = component2.coreTransform; RendererInfo[] baseRendererInfos = component2.baseRendererInfos; foreach (RendererInfo val3 in baseRendererInfos) { if (!val3.ignoreOverlays && ((Component)val3.renderer).gameObject.activeInHierarchy) { self.pingTargetRenderers.Add(val3.renderer); self.activeColor = playerTeamPingColor; } } } } string text = "PLAYER_PING_PLAYER"; if (Object.op_Implicit((Object)(object)RunArtifactManager.instance) && RunArtifactManager.instance.IsArtifactEnabled(Artifacts.FriendlyFire)) { text = "PLAYER_PING_ENEMY"; text = Language.GetString(text).Replace("Health", "Utility"); } else { text = Language.GetString(text); } if (Object.op_Implicit((Object)(object)val)) { ((Component)val).gameObject.SetActive(true); ((Component)val2).gameObject.SetActive(true); } else { GameObject val4 = Object.Instantiate(self.defaultPingGameObjects[0], self.defaultPingGameObjects[0].transform.parent); GameObject val5 = Object.Instantiate(self.enemyPingGameObjects[1], self.enemyPingGameObjects[1].transform.parent); ((Object)val4).name = "Player"; ((Object)val5).name = "PlayerPositionRing"; val4.SetActive(true); val5.SetActive(true); val4.GetComponent().color = playerTeamPingColor; val5.GetComponent().startColor = playerTeamPingColor2; } Chat.AddMessage(string.Format(text, ownerName, bestBodyName)); } private static string ColoredItem_Pickup(orig_GetDisplayName orig, GenericPickupController self) { //IL_0016: Unknown result type (might be due to invalid IL or missing references) if (WConfig.cfgMessagesColoredItemPings.Value) { PickupDef pickupDef = PickupCatalog.GetPickupDef(self._pickupState.pickupIndex); if (pickupDef != null) { return Help.GetColoredName(pickupDef, ((UniquePickup)(ref self._pickupState)).isTempItem); } } return orig.Invoke(self); } private static string ColoredItem_Shops(orig_GetFormattedTargetString orig, string pingTargetName, PickupIndex pickupIndex, bool shouldShowName) { //IL_006d: 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_001a: 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) if (WConfig.cfgMessagesColoredItemPings.Value) { string text = orig.Invoke(pingTargetName, pickupIndex, shouldShowName); PickupDef pickupDef = PickupCatalog.GetPickupDef(pickupIndex); if (pickupDef != null) { string text2 = ColorUtility.ToHtmlStringRGB(pickupDef.baseColor); text = text.Replace("(", "("); text = text.Replace(")", ")"); } return text; } return orig.Invoke(pingTargetName, pickupIndex, shouldShowName); } } public static class BodyIcons { public class AllyBodyIconOverwrite : MonoBehaviour { public Texture2D portraitIcon; public void Start() { //IL_0029: Unknown result type (might be due to invalid IL or missing references) //IL_002f: Invalid comparison between Unknown and I4 CharacterBody component = ((Component)this).GetComponent(); if (Object.op_Implicit((Object)(object)component) && Object.op_Implicit((Object)(object)component.teamComponent) && (int)component.teamComponent.teamIndex == 1) { component.portraitIcon = (Texture)(object)portraitIcon; } } } [CompilerGenerated] private static class <>O { public static hook_FinishAsyncLoads <0>__BodyCatalog_FinishAsyncLoads; } public static void Start() { //IL_0026: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_0031: Expected O, but got Unknown if (WConfig.cfgIconsBodyIcons.Value) { NewBodyIcons(); object obj = <>O.<0>__BodyCatalog_FinishAsyncLoads; if (obj == null) { hook_FinishAsyncLoads val = BodyCatalog_FinishAsyncLoads; <>O.<0>__BodyCatalog_FinishAsyncLoads = val; obj = (object)val; } BodyCatalog.FinishAsyncLoads += (hook_FinishAsyncLoads)obj; } } private static void BodyCatalog_FinishAsyncLoads(orig_FinishAsyncLoads orig, BodyIndex _bodyIndex, Texture2D tex) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(_bodyIndex, (Texture2D)null); } public static void NewBodyIcons() { //IL_0141: Unknown result type (might be due to invalid IL or missing references) //IL_0146: Unknown result type (might be due to invalid IL or missing references) //IL_016c: Unknown result type (might be due to invalid IL or missing references) //IL_0171: Unknown result type (might be due to invalid IL or missing references) //IL_0197: Unknown result type (might be due to invalid IL or missing references) //IL_019c: Unknown result type (might be due to invalid IL or missing references) //IL_01c2: Unknown result type (might be due to invalid IL or missing references) //IL_01c7: Unknown result type (might be due to invalid IL or missing references) //IL_0272: Unknown result type (might be due to invalid IL or missing references) //IL_0277: 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_0294: Unknown result type (might be due to invalid IL or missing references) LegacyResourcesAPI.Load("Prefabs/CharacterBodies/BanditBody").GetComponent().portraitIcon = (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/Body/Bandit1.png"); LegacyResourcesAPI.Load("Prefabs/CharacterBodies/BrotherHurtBody").GetComponent().portraitIcon = (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/Body/texBodyBrotherHurt.png"); LegacyResourcesAPI.Load("Prefabs/CharacterBodies/BrotherHauntBody").GetComponent().portraitIcon = (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/Body/texBodyBrotherHurt.png"); LegacyResourcesAPI.Load("Prefabs/CharacterBodies/EngiWalkerTurretBody").GetComponent().portraitIcon = (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/Body/texBodyEngiWalkerTurret.png"); LegacyResourcesAPI.Load("Prefabs/CharacterBodies/RoboBallRedBuddyBody").GetComponent().portraitIcon = (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/Body/texBodyRoboBallBuddyRed.png"); LegacyResourcesAPI.Load("Prefabs/CharacterBodies/RoboBallGreenBuddyBody").GetComponent().portraitIcon = (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/Body/texBodyRoboBallBuddyGreen.png"); LegacyResourcesAPI.Load("Prefabs/CharacterBodies/BrotherBody").GetComponent().portraitIcon = (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/Body/texBodyBrother.png"); LegacyResourcesAPI.Load("Prefabs/CharacterBodies/SquidTurretBody").GetComponent().portraitIcon = (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/Body/texBodySquidTurret.png"); LegacyResourcesAPI.Load("prefabs/characterbodies/WispSoulBody").GetComponent().portraitIcon = (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/Body/texBodyWispSoul.png"); Addressables.LoadAssetAsync((object)"RoR2/CU8/DevotedLemurianBody.prefab").WaitForCompletion().GetComponent() .portraitIcon = (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/Body/DevotedLemurian.png"); Addressables.LoadAssetAsync((object)"RoR2/CU8/DevotedLemurianBruiserBody.prefab").WaitForCompletion().GetComponent() .portraitIcon = (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/Body/DevotedElder.png"); Addressables.LoadAssetAsync((object)"RoR2/Base/MiniMushroom/MiniMushroomBody.prefab").WaitForCompletion().GetComponent() .portraitIcon = (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/Body/MiniMushroom.png"); Addressables.LoadAssetAsync((object)"RoR2/Base/ClayBoss/ClayBossBody.prefab").WaitForCompletion().GetComponent() .portraitIcon = (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/Body/ClayDunestrider.png"); Texture portraitIcon = LegacyResourcesAPI.Load("Prefabs/CharacterBodies/ArtifactShellBody").GetComponent().portraitIcon; LegacyResourcesAPI.Load("Prefabs/CharacterBodies/ExplosivePotDestructibleBody").GetComponent().portraitIcon = (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/Body/Destructible_ClayPot.png"); LegacyResourcesAPI.Load("Prefabs/CharacterBodies/FusionCellDestructibleBody").GetComponent().portraitIcon = (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/Body/Destructible_FusionCell.png"); LegacyResourcesAPI.Load("Prefabs/CharacterBodies/TimeCrystalBody").GetComponent().portraitIcon = portraitIcon; LegacyResourcesAPI.Load("Prefabs/CharacterBodies/AltarSkeletonBody").GetComponent().portraitIcon = portraitIcon; Addressables.LoadAssetAsync((object)"RoR2/DLC2/FalseSonBoss/LunarRain.prefab").WaitForCompletion().GetComponent() .portraitIcon = portraitIcon; Addressables.LoadAssetAsync((object)"RoR2/DLC2/CorruptionSpike/CorruptionSpike.prefab").WaitForCompletion().GetComponent() .portraitIcon = portraitIcon; LegacyResourcesAPI.Load("Prefabs/CharacterBodies/TitanGoldBody").AddComponent().portraitIcon = Assets.Bundle.LoadAsset("Assets/WQoL/Body/texBodyTitanGoldAlly.png"); LegacyResourcesAPI.Load("Prefabs/CharacterBodies/ParentPodBody").GetComponent().portraitIcon = (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/Body/texAncestralIncubatorIcon.png"); } } public static class BuffIcons { public static void BuffColorChanger() { //IL_001f: Unknown result type (might be due to invalid IL or missing references) //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_0029: 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_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) LegacyResourcesAPI.Load("buffdefs/AffixHauntedRecipient").buffColor = Color32.op_Implicit(new Color32((byte)148, (byte)215, (byte)214, byte.MaxValue)); LegacyResourcesAPI.Load("buffdefs/SmallArmorBoost").buffColor = new Color(0.6784f, 0.6118f, 0.4118f, 1f); LegacyResourcesAPI.Load("buffdefs/WhipBoost").buffColor = Color32.op_Implicit(new Color32((byte)245, (byte)158, (byte)73, byte.MaxValue)); } public static void Awake() { //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_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) //IL_00b6: Unknown result type (might be due to invalid IL or missing references) //IL_00bb: Unknown result type (might be due to invalid IL or missing references) //IL_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) if (WConfig.cfgBuff_RepeatColors.Value) { BuffColorChanger(); } BuffDef val = Addressables.LoadAssetAsync((object)"RoR2/DLC1/ImmuneToDebuff/bdImmuneToDebuffReady.asset").WaitForCompletion(); if (((Object)val.iconSprite).name.StartsWith("texBuffImmune")) { val.iconSprite = Assets.Bundle.LoadAsset("Assets/WQoL/Buffs/texBuffRaincoat.png"); } BuffDef val2 = Addressables.LoadAssetAsync((object)"64016639a97b88f43b182dfebe9fee92").WaitForCompletion(); val2.isHidden = false; val2.canStack = false; BuffDef val3 = Addressables.LoadAssetAsync((object)"RoR2/DLC2/Items/TeleportOnLowHealth/bdTeleportOnLowHealthActive.asset").WaitForCompletion(); val3.isHidden = false; val3.iconSprite = Assets.Bundle.LoadAsset("Assets/WQoL/Buffs/texBuffTeleportOnLowHealthIcon.png"); BuffDef val4 = Addressables.LoadAssetAsync((object)"048bb7e2972c1ee47a80f56c8283ff48").WaitForCompletion(); val4.iconSprite = Assets.Bundle.LoadAsset("Assets/WQoL/Buffs/texBuffJailed.png"); val4.buffColor = Color.white; } } public static class Icon_Colors { [CompilerGenerated] private static class <>O { public static Manipulator <0>__TeleporterDiscoveredRed; } public static void Start() { //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_0025: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Expected O, but got Unknown if (WConfig.cfgTpIconDiscoveredRed.Value) { object obj = <>O.<0>__TeleporterDiscoveredRed; if (obj == null) { Manipulator val = TeleporterDiscoveredRed; <>O.<0>__TeleporterDiscoveredRed = val; obj = (object)val; } ChargeIndicatorController.Update += (Manipulator)obj; } } private static void TeleporterDiscoveredRed(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown ILCursor val = new ILCursor(il); if (val.TryGotoNext((MoveType)0, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchLdfld(x, "RoR2.UI.ChargeIndicatorController", "isDiscovered") }) && val.TryGotoNext((MoveType)0, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchLdfld(x, "RoR2.UI.ChargeIndicatorController", "spriteChargedColor") })) { val.Remove(); val.EmitDelegate>((Func)((ChargeIndicatorController charg) => charg.spriteFlashColor)); } else { Log.LogWarning("IL Failed: TP RED DISCOVER CHANGE"); } } } public static class MissionPointers { public class MissionPointer : MonoBehaviour { public enum Version { Gold, Void, Lunar, Item } public PositionIndicator positionIndicator; public GameObject indicator; public GameObject indicatorPrefab; public static GameObject LunarPillarPositionIndicator; public static GameObject GoldShoresPositionIndicator; public Version version; public float destroyAfter; public void OnEnable() { if (!WConfig.cfgMissionPointers.Value) { Object.Destroy((Object)(object)this); } } public void AddIndicator() { //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_005b: Unknown result type (might be due to invalid IL or missing references) //IL_0060: Unknown result type (might be due to invalid IL or missing references) if (!WConfig.cfgMissionPointers.Value) { Object.Destroy((Object)(object)this); } else { if (Object.op_Implicit((Object)(object)indicator)) { return; } Addressables.LoadAssetAsync((object)"RoR2/Base/UI/skinObjectivePanel.asset").WaitForCompletion(); if (version == Version.Void) { indicatorPrefab = Addressables.LoadAssetAsync((object)"RoR2/DLC1/VoidCamp/VoidCampPositionIndicator.prefab").WaitForCompletion(); } else if (version == Version.Lunar) { indicatorPrefab = LunarPillarPositionIndicator; } else { indicatorPrefab = GoldShoresPositionIndicator; } if (Object.op_Implicit((Object)(object)indicatorPrefab)) { indicator = Object.Instantiate(indicatorPrefab, ((Component)this).transform); positionIndicator = indicator.GetComponent(); positionIndicator.targetTransform = ((Component)this).gameObject.transform; } if (version == Version.Void) { ObjectScaleCurve componentInChildren = indicator.GetComponentInChildren(true); if (Object.op_Implicit((Object)(object)componentInChildren)) { componentInChildren.timeMax = 22f; } } } } public void OnDisable() { if (Object.op_Implicit((Object)(object)indicator)) { Object.Destroy((Object)(object)indicator); } } } [CompilerGenerated] private static class <>O { public static hook_OnEnter <0>__VoidFields_AddPointer; public static hook_OnExit <1>__VoidFields_RemovePointer; public static hook_OnEnter <2>__LunarPillar_AddPointers; public static hook_OnEnter <3>__GildedCoast_Client; public static hook_OnEnter <4>__GildedCoast_Add; } public static void Start() { //IL_0011: 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_001c: Expected O, but got Unknown //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Unknown result type (might be due to invalid IL or missing references) //IL_003d: Expected O, but got Unknown //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_005e: Expected O, but got Unknown //IL_0074: Unknown result type (might be due to invalid IL or missing references) //IL_0079: Unknown result type (might be due to invalid IL or missing references) //IL_007f: Expected O, but got Unknown //IL_00a6: Unknown result type (might be due to invalid IL or missing references) //IL_00ad: Expected O, but got Unknown //IL_00c1: 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_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_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_0117: Unknown result type (might be due to invalid IL or missing references) //IL_011c: Unknown result type (might be due to invalid IL or missing references) //IL_0095: 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_00a0: Expected O, but got Unknown //IL_017d: Unknown result type (might be due to invalid IL or missing references) //IL_01fe: Unknown result type (might be due to invalid IL or missing references) //IL_0203: Unknown result type (might be due to invalid IL or missing references) object obj = <>O.<0>__VoidFields_AddPointer; if (obj == null) { hook_OnEnter val = VoidFields_AddPointer; <>O.<0>__VoidFields_AddPointer = val; obj = (object)val; } WardOnAndReady.OnEnter += (hook_OnEnter)obj; object obj2 = <>O.<1>__VoidFields_RemovePointer; if (obj2 == null) { hook_OnExit val2 = VoidFields_RemovePointer; <>O.<1>__VoidFields_RemovePointer = val2; obj2 = (object)val2; } WardOnAndReady.OnExit += (hook_OnExit)obj2; object obj3 = <>O.<2>__LunarPillar_AddPointers; if (obj3 == null) { hook_OnEnter val3 = LunarPillar_AddPointers; <>O.<2>__LunarPillar_AddPointers = val3; obj3 = (object)val3; } MoonBatteryComplete.OnEnter += (hook_OnEnter)obj3; object obj4 = <>O.<3>__GildedCoast_Client; if (obj4 == null) { hook_OnEnter val4 = GildedCoast_Client; <>O.<3>__GildedCoast_Client = val4; obj4 = (object)val4; } NotReady.OnEnter += (hook_OnEnter)obj4; object obj5 = <>O.<4>__GildedCoast_Add; if (obj5 == null) { hook_OnEnter val5 = GildedCoast_Add; <>O.<4>__GildedCoast_Add = val5; obj5 = (object)val5; } Ready.OnEnter += (hook_OnEnter)obj5; AnimationCurve val6 = new AnimationCurve(); val6.keys = (Keyframe[])(object)new Keyframe[3] { new Keyframe(0f, 1f), new Keyframe(0.5f, 1f), new Keyframe(1f, 0f) }; val6.postWrapMode = (WrapMode)8; val6.preWrapMode = (WrapMode)8; AnimationCurve overallCurve = val6; GameObject val7 = (MissionPointer.LunarPillarPositionIndicator = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/DLC1/VoidCamp/VoidCampPositionIndicator.prefab").WaitForCompletion(), "LunarPillarPositionIndicator", false)); PositionIndicator component = val7.GetComponent(); component.outsideViewObject.SetActive(false); component.outsideViewObject = component.insideViewObject; SpriteRenderer[] componentsInChildren = ((Component)component).GetComponentsInChildren(true); for (int i = 0; i < componentsInChildren.Length; i++) { componentsInChildren[i].color = new Color(0.5223f, 0.8071f, 0.9151f, 1f); } Object.Destroy((Object)(object)((Component)val7.transform.GetChild(2).GetChild(0)).GetComponent()); ObjectScaleCurve val8 = val7.AddComponent(); val8.timeMax = 15f; val8.useOverallCurveOnly = true; val8.overallCurve = overallCurve; DestroyOnTimer val9 = val7.AddComponent(); val9.duration = val8.timeMax + 1f; val7 = (MissionPointer.GoldShoresPositionIndicator = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/DLC1/GameModes/InfiniteTowerRun/ITAssets/WaveEndPositionIndicator.prefab").WaitForCompletion(), "GoldShoresPositionIndicator", false)); Object.Destroy((Object)(object)((Component)val7.transform.GetChild(2).GetChild(0)).GetComponent()); val8 = val7.AddComponent(); val8.timeMax = 4f; val8.useOverallCurveOnly = true; val8.overallCurve = overallCurve; val9 = val7.AddComponent(); val9.duration = val8.timeMax + 1f; } private static void GildedCoast_Client(orig_OnEnter orig, NotReady self) { orig.Invoke(self); if (!NetworkServer.active && Object.op_Implicit((Object)(object)GoldshoresMissionController.instance)) { GoldshoresMissionController.instance.beaconInstanceList.Add(((EntityState)self).gameObject); } } private static void GildedCoast_Add(orig_OnEnter orig, Ready self) { orig.Invoke(self); if (!WConfig.cfgMissionPointers.Value || !Object.op_Implicit((Object)(object)GoldshoresMissionController.instance) || GoldshoresMissionController.instance.beaconsActive <= 3) { return; } List beaconInstanceList = GoldshoresMissionController.instance.beaconInstanceList; for (int i = 0; i < beaconInstanceList.Count; i++) { Object.Destroy((Object)(object)beaconInstanceList[i].gameObject.GetComponent()); if (beaconInstanceList[i].GetComponent().state is NotReady) { MissionPointer missionPointer = beaconInstanceList[i].gameObject.AddComponent(); missionPointer.version = MissionPointer.Version.Gold; missionPointer.AddIndicator(); } } } private static void VoidFields_RemovePointer(orig_OnExit orig, WardOnAndReady self) { orig.Invoke(self); Object.Destroy((Object)(object)((EntityState)self).gameObject.GetComponent()); } private static void VoidFields_AddPointer(orig_OnEnter orig, WardOnAndReady self) { //IL_0035: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self); ((EntityState)self).gameObject.transform.GetChild(3).GetChild(0).GetChild(0) .localScale = new Vector3(1.5f, 3f, 1.5f); if (WConfig.cfgMissionPointers.Value) { MissionPointer missionPointer = ((EntityState)self).gameObject.AddComponent(); missionPointer.version = MissionPointer.Version.Void; missionPointer.AddIndicator(); } } private static void LunarPillar_AddPointers(orig_OnEnter orig, MoonBatteryComplete self) { orig.Invoke(self); if (!WConfig.cfgMissionPointers.Value || !Object.op_Implicit((Object)(object)MoonBatteryMissionController.instance) || MoonBatteryMissionController.instance.numChargedBatteries >= MoonBatteryMissionController.instance._numRequiredBatteries) { return; } HoldoutZoneController[] batteryHoldoutZones = MoonBatteryMissionController.instance.batteryHoldoutZones; for (int i = 0; i < batteryHoldoutZones.Length; i++) { Object.Destroy((Object)(object)((Component)batteryHoldoutZones[i]).gameObject.GetComponent()); if (batteryHoldoutZones[i].charge == 0f) { MissionPointer missionPointer = ((Component)batteryHoldoutZones[i]).gameObject.AddComponent(); missionPointer.version = MissionPointer.Version.Lunar; missionPointer.AddIndicator(); } } } } public static class PingIcons { [CompilerGenerated] private static class <>O { public static hook_Start <0>__PrimordialTPIcon; public static hook_PreStartClient <1>__NewtPingIcon; public static hook_PreStartClient <2>__GeodePingIcon; public static hook_OnEnable <3>__SetPortalIcon; public static hook_OnInteractionBegin <4>__RemoveScannerIcon_General; public static hook_OnPurchase <5>__RemoveScannerIcon_Shop; public static hook_OnInteractionBegin <6>__RemoveScannerIcon_Barrel; public static hook_ShouldShowOnScanner <7>__BlockScanner_Purchase; public static hook_ShouldShowOnScanner <8>__BlockScanner_Generic; public static hook_PreStartClient <9>__PingIconsOnStage; public static hook_OnEnter <10>__VoidCell_Inidicator; public static hook_OnEnter <11>__VoidCell_DestroyIndicator; public static Action <12>__MakePickupSpriteDict; public static hook_SyncPickupState <13>__PingIconsForItems; public static hook_SyncPickupState <14>__PingIconsForCommandCubes; } public static Dictionary pickupToPingIcon; public static Sprite LunarIcon; public static Sprite VoidIcon; public static Sprite ExclamationIcon; public static Sprite NullVentIcon; public static Sprite PortalIcon; public static Sprite PrimordialTeleporterChargedIcon = LegacyResourcesAPI.Load("Textures/MiscIcons/texTeleporterIcon"); public static Sprite QuestionMarkIcon = LegacyResourcesAPI.Load("textures/miscicons/texMysteryIcon"); public static bool otherPingIconMods = false; public static Dictionary pingIconDict = new Dictionary(); private static Transform r2apiRoot; public static void AddHooks() { //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_0025: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Expected O, but got Unknown //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_0046: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Expected O, but got Unknown //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_006d: Expected O, but got Unknown //IL_0083: Unknown result type (might be due to invalid IL or missing references) //IL_0088: Unknown result type (might be due to invalid IL or missing references) //IL_008e: Expected O, but got Unknown //IL_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_00af: Expected O, but got Unknown //IL_00c5: Unknown result type (might be due to invalid IL or missing references) //IL_00ca: Unknown result type (might be due to invalid IL or missing references) //IL_00d0: Expected O, but got Unknown //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_00f1: Expected O, but got Unknown //IL_0107: 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_0112: Expected O, but got Unknown //IL_0128: Unknown result type (might be due to invalid IL or missing references) //IL_012d: Unknown result type (might be due to invalid IL or missing references) //IL_0133: Expected O, but got Unknown //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_0154: Expected O, but got Unknown if (!otherPingIconMods) { object obj = <>O.<0>__PrimordialTPIcon; if (obj == null) { hook_Start val = PrimordialTPIcon; <>O.<0>__PrimordialTPIcon = val; obj = (object)val; } TeleporterInteraction.Start += (hook_Start)obj; object obj2 = <>O.<1>__NewtPingIcon; if (obj2 == null) { hook_PreStartClient val2 = NewtPingIcon; <>O.<1>__NewtPingIcon = val2; obj2 = (object)val2; } PortalStatueBehavior.PreStartClient += (hook_PreStartClient)obj2; object obj3 = <>O.<2>__GeodePingIcon; if (obj3 == null) { hook_PreStartClient val3 = GeodePingIcon; <>O.<2>__GeodePingIcon = val3; obj3 = (object)val3; } GeodeController.PreStartClient += (hook_PreStartClient)obj3; object obj4 = <>O.<3>__SetPortalIcon; if (obj4 == null) { hook_OnEnable val4 = SetPortalIcon; <>O.<3>__SetPortalIcon = val4; obj4 = (object)val4; } SceneExitController.OnEnable += (hook_OnEnable)obj4; object obj5 = <>O.<4>__RemoveScannerIcon_General; if (obj5 == null) { hook_OnInteractionBegin val5 = RemoveScannerIcon_General; <>O.<4>__RemoveScannerIcon_General = val5; obj5 = (object)val5; } PurchaseInteraction.OnInteractionBegin += (hook_OnInteractionBegin)obj5; object obj6 = <>O.<5>__RemoveScannerIcon_Shop; if (obj6 == null) { hook_OnPurchase val6 = RemoveScannerIcon_Shop; <>O.<5>__RemoveScannerIcon_Shop = val6; obj6 = (object)val6; } MultiShopController.OnPurchase += (hook_OnPurchase)obj6; object obj7 = <>O.<6>__RemoveScannerIcon_Barrel; if (obj7 == null) { hook_OnInteractionBegin val7 = RemoveScannerIcon_Barrel; <>O.<6>__RemoveScannerIcon_Barrel = val7; obj7 = (object)val7; } BarrelInteraction.OnInteractionBegin += (hook_OnInteractionBegin)obj7; object obj8 = <>O.<7>__BlockScanner_Purchase; if (obj8 == null) { hook_ShouldShowOnScanner val8 = BlockScanner_Purchase; <>O.<7>__BlockScanner_Purchase = val8; obj8 = (object)val8; } PurchaseInteraction.ShouldShowOnScanner += (hook_ShouldShowOnScanner)obj8; object obj9 = <>O.<8>__BlockScanner_Generic; if (obj9 == null) { hook_ShouldShowOnScanner val9 = BlockScanner_Generic; <>O.<8>__BlockScanner_Generic = val9; obj9 = (object)val9; } GenericInteraction.ShouldShowOnScanner += (hook_ShouldShowOnScanner)obj9; object obj10 = <>O.<9>__PingIconsOnStage; if (obj10 == null) { hook_PreStartClient val10 = PingIconsOnStage; <>O.<9>__PingIconsOnStage = val10; obj10 = (object)val10; } Stage.PreStartClient += (hook_PreStartClient)obj10; } } private static void GeodePingIcon(orig_PreStartClient orig, GeodeController self) { orig.Invoke(self); ((Component)self).gameObject.AddComponent().pingIconOverride = Assets.Bundle.LoadAsset("Assets/WQoL/PingIcons/DLC2/Geode.png"); } public static void PingIconsOnStage(orig_PreStartClient orig, Stage self) { orig.Invoke(self); SetAllStageInteractablePingIcons(); } private static void SetPortalIcon(orig_OnEnable orig, SceneExitController self) { orig.Invoke(self); if (((Component)self).transform.childCount > 0 && ((Object)((Component)self).transform.GetChild(0)).name == "PortalCenter") { PingInfoProvider val = default(PingInfoProvider); if (((Component)self).TryGetComponent(ref val)) { val.pingIconOverride = PortalIcon; } else { ((Component)self).gameObject.AddComponent().pingIconOverride = PortalIcon; } } } private static void RemoveScannerIcon_Barrel(orig_OnInteractionBegin orig, BarrelInteraction self, Interactor activator) { orig.Invoke(self, activator); Object.Destroy((Object)(object)((Component)self).GetComponent()); } private static void RemoveScannerIcon_Shop(orig_OnPurchase orig, MultiShopController self, PayCostContext payCostContext, PayCostResults payCostResult) { orig.Invoke(self, payCostContext, payCostResult); for (int i = 0; i < self.terminalGameObjects.Length; i++) { Object.Destroy((Object)(object)self.terminalGameObjects[i].GetComponent()); } } private static void RemoveScannerIcon_General(orig_OnInteractionBegin orig, PurchaseInteraction self, Interactor activator) { orig.Invoke(self, activator); Object.Destroy((Object)(object)((Component)self).GetComponent()); } private static void NewtPingIcon(orig_PreStartClient orig, PortalStatueBehavior self) { //IL_000a: Unknown result type (might be due to invalid IL or missing references) //IL_0010: Invalid comparison between Unknown and I4 orig.Invoke(self); if ((int)self.portalType == 0) { PingInfoProvider val = ((Component)self).GetComponent(); if (!Object.op_Implicit((Object)(object)val)) { val = ((Component)self).gameObject.AddComponent(); } val.pingIconOverride = LunarIcon; } } private static void PingIconsShareColor(orig_Awake orig, ChargeIndicatorController self) { orig.Invoke(self); } private static void PrimordialTPIcon(orig_Start orig, TeleporterInteraction self) { //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_006e: Unknown result type (might be due to invalid IL or missing references) //IL_013f: Unknown result type (might be due to invalid IL or missing references) //IL_0144: Unknown result type (might be due to invalid IL or missing references) //IL_0163: Unknown result type (might be due to invalid IL or missing references) //IL_0168: Unknown result type (might be due to invalid IL or missing references) //IL_0187: Unknown result type (might be due to invalid IL or missing references) //IL_018c: Unknown result type (might be due to invalid IL or missing references) //IL_00bb: Unknown result type (might be due to invalid IL or missing references) //IL_00c0: Unknown result type (might be due to invalid IL or missing references) //IL_00c7: Unknown result type (might be due to invalid IL or missing references) //IL_0101: Unknown result type (might be due to invalid IL or missing references) //IL_0106: Unknown result type (might be due to invalid IL or missing references) //IL_010d: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self); if (!((Object)self).name.StartsWith("LunarT") || !Object.op_Implicit((Object)(object)self.teleporterChargeIndicatorController)) { return; } if (WConfig.cfgPrimordialBlueHighlight.Value) { Highlight component = ((Component)self).GetComponent(); component.CustomColor = new Color(0.5223f, 0.8071f, 0.9151f, 1f); component.highlightColor = (HighlightColor)3; Transform child = ((Component)self).transform.GetChild(0).GetChild(8); component = ((Component)child).GetComponent().prefab.GetComponent(); if (Object.op_Implicit((Object)(object)component)) { component.CustomColor = new Color(0.5223f, 0.8071f, 0.9151f, 1f); component.highlightColor = (HighlightColor)3; } if (child.childCount > 0) { component = ((Component)child.GetChild(0)).GetComponent(); component.CustomColor = new Color(0.5223f, 0.8071f, 0.9151f, 1f); component.highlightColor = (HighlightColor)3; } } if (WConfig.cfgPrimordialBlueIcon.Value) { self.teleporterChargeIndicatorController.spriteFlashColor = new Color(0.5918f, 0.8219f, 0.9434f, 1f); self.teleporterChargeIndicatorController.spriteChargingColor = new Color(0.5223f, 0.8071f, 0.9151f, 1f); self.teleporterChargeIndicatorController.spriteBaseColor = new Color(0.1745f, 0.4115f, 1f, 1f); } if (WConfig.cfgPingIcons.Value) { self.teleporterChargeIndicatorController.iconSprites[0].sprite = PrimordialTeleporterChargedIcon; } } private static bool BlockScanner_Generic(orig_ShouldShowOnScanner orig, GenericInteraction self) { if ((Object)(object)((Component)self).GetComponent() != (Object)null) { return false; } return orig.Invoke(self); } private static bool BlockScanner_Purchase(orig_ShouldShowOnScanner orig, PurchaseInteraction self) { if ((Object)(object)((Component)self).GetComponent() != (Object)null) { return false; } return orig.Invoke(self); } public static void MiscIcons() { //IL_0011: 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_001c: Expected O, but got Unknown //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_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_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Unknown result type (might be due to invalid IL or missing references) //IL_003d: Expected O, but got Unknown //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_00c3: Expected O, but got Unknown //IL_00d9: 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_00e4: Expected O, but got Unknown object obj = <>O.<10>__VoidCell_Inidicator; if (obj == null) { hook_OnEnter val = VoidCell_Inidicator; <>O.<10>__VoidCell_Inidicator = val; obj = (object)val; } Active.OnEnter += (hook_OnEnter)obj; object obj2 = <>O.<11>__VoidCell_DestroyIndicator; if (obj2 == null) { hook_OnEnter val2 = VoidCell_DestroyIndicator; <>O.<11>__VoidCell_DestroyIndicator = val2; obj2 = (object)val2; } Complete.OnEnter += (hook_OnEnter)obj2; Addressables.LoadAssetAsync((object)"0db1724ef7010364b87726287e1c2088").WaitForCompletion().AddComponent(); Addressables.LoadAssetAsync((object)"d9c642aeefb6c974da664933489071d4").WaitForCompletion().AddComponent(); if (WConfig.cfgLootIcons.Value) { ((ResourceAvailability)(ref PickupCatalog.availability)).CallWhenAvailable((Action)MakePickupSpriteDict); object obj3 = <>O.<13>__PingIconsForItems; if (obj3 == null) { hook_SyncPickupState val3 = PingIconsForItems; <>O.<13>__PingIconsForItems = val3; obj3 = (object)val3; } GenericPickupController.SyncPickupState += (hook_SyncPickupState)obj3; object obj4 = <>O.<14>__PingIconsForCommandCubes; if (obj4 == null) { hook_SyncPickupState val4 = PingIconsForCommandCubes; <>O.<14>__PingIconsForCommandCubes = val4; obj4 = (object)val4; } PickupIndexNetworker.SyncPickupState += (hook_SyncPickupState)obj4; } } private static void MakePickupSpriteDict() { //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_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_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_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_00a5: Unknown result type (might be due to invalid IL or missing references) //IL_00aa: Unknown result type (might be due to invalid IL or missing references) //IL_00c9: Unknown result type (might be due to invalid IL or missing references) //IL_00ce: Unknown result type (might be due to invalid IL or missing references) pickupToPingIcon = new Dictionary(); pickupToPingIcon.Add(PickupCatalog.FindPickupIndex(MiscPickups.LunarCoin.miscPickupIndex), Assets.Load("LunarCoin")); pickupToPingIcon.Add(PickupCatalog.FindPickupIndex(MiscPickups.VoidCoin.miscPickupIndex), Assets.Load("VoidCoin")); pickupToPingIcon.Add(PickupCatalog.FindPickupIndex(Items.PowerPyramid.itemIndex), Assets.Load("DLC3/Power_Pyramid2Shrunk")); pickupToPingIcon.Add(PickupCatalog.FindPickupIndex(Items.PowerCube.itemIndex), Assets.Load("DLC3/Power_Cube2Shrunk")); pickupToPingIcon.Add(PickupCatalog.FindPickupIndex(Items.MasterBattery.itemIndex), Assets.Load("DLC3/Power_Orb2")); pickupToPingIcon.Add(PickupCatalog.FindPickupIndex(Items.MasterCore.itemIndex), Assets.Load("DLC3/Power_Orb2")); } private static void PingIconsForCommandCubes(orig_SyncPickupState orig, PickupIndexNetworker self, UniquePickup newPickupState) { //IL_0003: 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) orig.Invoke(self, newPickupState); PingInfoProvider val = default(PingInfoProvider); if (((Component)self).TryGetComponent(ref val) && (Object)(object)val.pingIconOverride == (Object)null) { val.pingIconOverride = PingIconFromPickupIndex(newPickupState); } } public static Sprite PingIconFromPickupIndex(UniquePickup pickup) { //IL_0001: Unknown result type (might be due to invalid IL or missing references) //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0007: Unknown result type (might be due to invalid IL or missing references) //IL_0022: 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_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_007a: Unknown result type (might be due to invalid IL or missing references) //IL_0080: Invalid comparison between Unknown and I4 //IL_00ec: Unknown result type (might be due to invalid IL or missing references) //IL_00f2: Invalid comparison between Unknown and I4 //IL_008d: 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_014f: Invalid comparison between Unknown and I4 //IL_00ff: 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 (pickup.pickupIndex == PickupIndex.none) { return null; } if (pickupToPingIcon.TryGetValue(pickup.pickupIndex, out var value)) { return value; } if (((UniquePickup)(ref pickup)).isTempItem) { return Assets.Load("Loot_TempItem2"); } PickupDef pickupDef = PickupCatalog.GetPickupDef(pickup.pickupIndex); if (pickupDef == null) { return null; } if ((int)pickupDef.equipmentIndex != -1) { EquipmentDef equipmentDef = EquipmentCatalog.GetEquipmentDef(pickupDef.equipmentIndex); if (Object.op_Implicit((Object)(object)equipmentDef) && Object.op_Implicit((Object)(object)equipmentDef.passiveBuffDef) && Object.op_Implicit((Object)(object)equipmentDef.passiveBuffDef.eliteDef)) { return Assets.Load("Loot_Aspect"); } return Assets.Load("Loot_Equipment"); } if ((int)pickupDef.itemIndex != -1) { ItemDef itemDef = ItemCatalog.GetItemDef(pickupDef.itemIndex); if (Object.op_Implicit((Object)(object)itemDef) && WQoLMain.ZetAspects && ModPing_ZetAspects(itemDef)) { return Assets.Load("Loot_Aspect"); } } else if ((int)pickupDef.droneIndex != -1) { DroneDef droneDef = DroneCatalog.GetDroneDef(pickupDef.droneIndex); if (Object.op_Implicit((Object)(object)droneDef) && Object.op_Implicit((Object)(object)droneDef.droneBrokenSpawnCard)) { PingInfoProvider component = droneDef.droneBrokenSpawnCard.prefab.GetComponent(); if (Object.op_Implicit((Object)(object)component)) { return component.pingIconOverride; } return LegacyResourcesAPI.Load("textures/miscicons/texDroneIconOutlined"); } } return null; } private static void PingIconsForItems(orig_SyncPickupState orig, GenericPickupController self, UniquePickup newPickupState) { //IL_0003: 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) orig.Invoke(self, newPickupState); PingInfoProvider val = default(PingInfoProvider); if (((Component)self).TryGetComponent(ref val)) { val.pingIconOverride = PingIconFromPickupIndex(newPickupState); } } private static void VoidCell_DestroyIndicator(orig_OnEnter orig, Complete self) { //IL_003d: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self); Transform val = ((EntityState)self).transform.Find("NullCellPositionIndicator"); if ((Object)(object)val != (Object)null) { Object.Destroy((Object)(object)((Component)val).gameObject); } HoldoutZoneController.sharedColorPropertyBlock.SetColor("_TintColor", Color.white); ((Renderer)((Component)((EntityState)self).transform.GetChild(1).GetChild(0)).GetComponent()).SetPropertyBlock(HoldoutZoneController.sharedColorPropertyBlock); } private static void VoidCell_Inidicator(orig_OnEnter orig, Active self) { //IL_0166: 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_0094: Unknown result type (might be due to invalid IL or missing references) //IL_00a9: Unknown result type (might be due to invalid IL or missing references) //IL_00ae: Unknown result type (might be due to invalid IL or missing references) //IL_00c3: Unknown result type (might be due to invalid IL or missing references) //IL_00c8: Unknown result type (might be due to invalid IL or missing references) //IL_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_00f7: 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_0111: Unknown result type (might be due to invalid IL or missing references) //IL_0116: Unknown result type (might be due to invalid IL or missing references) //IL_019f: Unknown result type (might be due to invalid IL or missing references) //IL_0186: Unknown result type (might be due to invalid IL or missing references) //IL_0155: 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) orig.Invoke(self); if (WConfig.cfgVoidFieldsChargeIndicator.Value) { HoldoutZoneController component = ((Component)((EntityState)self).outer).GetComponent(); GameObject val = Object.Instantiate(LegacyResourcesAPI.Load("Prefabs/PositionIndicators/PillarChargingPositionIndicator")); ((Object)val).name = "NullCellPositionIndicator"; val.GetComponent().targetTransform = ((Component)((EntityState)self).outer).transform; val.transform.SetParent(((Component)((EntityState)self).outer).transform, false); ChargeIndicatorController component2 = val.GetComponent(); component2.holdoutZoneController = component; component2.spriteBaseColor = new Color(0.915f, 0.807f, 0.915f); component2.spriteChargedColor = new Color(0.977f, 0.877f, 0.977f); component2.spriteChargingColor = new Color(0.943f, 0.621f, 0.943f); component2.spriteFlashColor = new Color(0.92f, 0.411f, 0.92f); component2.textBaseColor = new Color(0.858f, 0.714f, 0.858f); component2.textChargingColor = new Color(1f, 1f, 1f); if (component2.iconSprites.Length != 0) { component2.iconSprites[0].sprite = NullVentIcon; } component.baseIndicatorColor = new Color(1f, 1f, 1f, 1f); } if (Util.GetItemCountForTeam((TeamIndex)1, Items.FocusConvergence.itemIndex, true, false) > 0) { HoldoutZoneController.sharedColorPropertyBlock.SetColor("_TintColor", FocusConvergenceController.convergenceMaterialColor); } else { HoldoutZoneController.sharedColorPropertyBlock.SetColor("_TintColor", Color.white); } ((Renderer)((Component)((EntityState)self).transform.GetChild(1).GetChild(0)).GetComponent()).SetPropertyBlock(HoldoutZoneController.sharedColorPropertyBlock); } public static void SetAllStageInteractablePingIcons() { //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) Type[] typesToCheck = ChestRevealer.typesToCheck; NetworkIdentity val = default(NetworkIdentity); PingInfoProvider val2 = default(PingInfoProvider); for (int i = 0; i < typesToCheck.Length; i++) { foreach (MonoBehaviour item in InstanceTracker.FindInstancesEnumerable(typesToCheck[i])) { if (!((Component)item).TryGetComponent(ref val)) { continue; } NetworkSceneId sceneId = val.sceneId; if (((NetworkSceneId)(ref sceneId)).Value != 0 && pingIconDict.TryGetValue(((Object)((Component)item).gameObject).name.Split(" ")[0], out var value)) { if ((Object)(object)value == (Object)null) { ((Component)item).gameObject.AddComponent(); } if (((Component)item).TryGetComponent(ref val2)) { val2.pingIconOverride = value; } else { ((Component)item).gameObject.AddComponent().pingIconOverride = value; } } } } } public static void SetAllIcons(string obj, string sprite, bool setInspect = true) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0007: Unknown result type (might be due to invalid IL or missing references) SetAllIcons(Addressables.LoadAssetAsync((object)obj).WaitForCompletion(), Assets.Bundle.LoadAsset("Assets/WQoL/PingIcons/" + sprite + ".png"), setInspect); } public static void SetAllIcons(string obj, Sprite sprite) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0007: Unknown result type (might be due to invalid IL or missing references) SetAllIcons(Addressables.LoadAssetAsync((object)obj).WaitForCompletion(), sprite); } public static void SetAllIcons(GameObject obj, string sprite) { SetAllIcons(obj, Assets.Bundle.LoadAsset("Assets/WQoL/PingIcons/" + sprite + ".png")); } public static void SetAllIcons(GameObject obj, Sprite sprite, bool setInspect = true) { if (!Object.op_Implicit((Object)(object)sprite)) { Log.LogError($"{obj} trying to set NULL SPRITE"); return; } if (!Object.op_Implicit((Object)(object)obj)) { Log.LogError($"{sprite} trying to set NULL OBJECT"); return; } UnityObjectExtensions.EnsureComponent(obj).pingIconOverride = sprite; SpecialObjectAttributes val = default(SpecialObjectAttributes); if (obj.TryGetComponent(ref val)) { val.portraitIcon = (Texture)(object)sprite.texture; } if (!setInspect) { return; } GenericInspectInfoProvider val2 = default(GenericInspectInfoProvider); SummonMasterBehavior val3 = default(SummonMasterBehavior); PickupDistributorBehavior val4 = default(PickupDistributorBehavior); if (obj.TryGetComponent(ref val2)) { if (Object.op_Implicit((Object)(object)val2.InspectInfo)) { val2.InspectInfo.Info.Visual = sprite; } } else if (obj.TryGetComponent(ref val3)) { if (Object.op_Implicit((Object)(object)val3.inspectDef)) { val3.inspectDef.Info.Visual = sprite; } } else if (obj.TryGetComponent(ref val4) && Object.op_Implicit((Object)(object)val4.inspectDef)) { val4.inspectDef.Info.Visual = sprite; } } public static void AddIcons() { otherPingIconMods = Chainloader.PluginInfos.ContainsKey("NotAJunkie.PingIconsOverhaul"); if (!otherPingIconMods) { ExclamationIcon = Assets.Bundle.LoadAsset("Assets/WQoL/PingIcons/ExclamationIcon.png"); PortalIcon = Assets.Bundle.LoadAsset("Assets/WQoL/PingIcons/PortalIcon.png"); Pings_Dictionary(); Pings_Other(); Pings_Chests(); Pings_Shrines(); Pings_Drones(); Pings_Printer(); Pings_Loot(); } } public static void Pings_Loot() { SetAllIcons("f8e3413a378bd7c44aa09bed0020eaf5", "DLC1/Loot_Potential"); SetAllIcons("cda6217a2c0775c42a3f456b3bb5e073", "DLC2/Loot_Fragment"); } public static void Pings_Dictionary() { pingIconDict.Add("Chest2", Assets.Load("ChestLargeIcon")); pingIconDict.Add("Chest1StealthedVariant", Assets.Load("ChestInvisibleIcon")); pingIconDict.Add("GoldChest", Assets.Load("ChestLegendaryIcon")); pingIconDict.Add("LunarChest", Assets.Load("ChestLunarIcon")); pingIconDict.Add("Scrapper", Assets.Load("ScrapperIcon")); pingIconDict.Add("ShrineRestack", Assets.Load("ShrineOrderIcon")); pingIconDict.Add("TemporaryItemsShopTerminal", Assets.Load("DLC3/TempVendor")); pingIconDict.Add("HumanFan", ExclamationIcon); pingIconDict.Add("FW_HumanFan", ExclamationIcon); pingIconDict.Add("TimedChest", Assets.Load("ChestTimedIcon")); pingIconDict.Add("PortalDialer", QuestionMarkIcon); pingIconDict.Add("NullSafeZone", Assets.Load("Void_Cell")); pingIconDict.Add("TripleShopEquipment", Assets.Load("TrippleShop_Equipment")); pingIconDict.Add("ShrineRebirth", Assets.Load("SotsIcon3_Shrunk")); pingIconDict.Add("LunarShopTerminal", Assets.Load("ChestLunarIcon")); pingIconDict.Add("LunarCauldron,", Assets.Load("LunarCauldron")); pingIconDict.Add("SeerStation", Assets.Load("LunarSeer")); Sprite value = LegacyResourcesAPI.Load("textures/miscicons/texLunarPillarIcon"); pingIconDict.Add("MoonBatteryMass", value); pingIconDict.Add("MoonBatteryBlood", value); pingIconDict.Add("MoonBatterySoul", value); pingIconDict.Add("MoonBatteryDesign", value); pingIconDict.Add("Access", Assets.Load("DLC3/Access_Node")); pingIconDict.Add("PowerPedestal_Pyramid", Assets.Load("DLC3/Power_Pyramid2")); pingIconDict.Add("PowerPedestal_Cube", Assets.Load("DLC3/Power_Cube2")); pingIconDict.Add("CoinSlotStatue_SH_PostBossPuzzle", ExclamationIcon); pingIconDict.Add("DrifterBagChest", Assets.Load("ScavBagIcon")); pingIconDict.Add("BrokenHAND", QuestionMarkIcon); pingIconDict.Add("DroneCombinerStation", Assets.Load("DLC3/Drone__Combiner")); pingIconDict.Add("DroneScrapper", Assets.Load("DLC3/Drone__Scrapper")); pingIconDict.Add("MealPrep", Assets.Load("DLC3/Meal_Station")); pingIconDict.Add("VendingMachine", Assets.Load("DLC1/VendingMachine")); pingIconDict.Add("SolusVendorShrine2", Assets.Load("DLC3/Power_Orb3")); pingIconDict.Add("Duplicator", Assets.Load("Printer")); pingIconDict.Add("DuplicatorLarge", Assets.Load("PrinterLarge")); pingIconDict.Add("DuplicatorMilitary", Assets.Load("PrinterMili")); pingIconDict.Add("DuplicatorWild", Assets.Load("PrinterWild")); pingIconDict.Add("LemurianEgg", Assets.Load("LemurianEgg")); pingIconDict.Add("Drone2Broken", Assets.Load("DroneHealIcon")); pingIconDict.Add("HaulerDroneBroken", Assets.Load("DLC3/Drone_Transport")); pingIconDict.Add("JunkDroneBroken", Assets.Load("DLC3/Drone_Junk")); pingIconDict.Add("MissileDroneBroken", Assets.Load("DroneMissileIcon")); pingIconDict.Add("RechargeDroneBroken", Assets.Load("DLC3/Drone_Barrier")); pingIconDict.Add("JailerDroneBroken", Assets.Load("DLC3/Drone_Jailer")); pingIconDict.Add("CleanupDroneBroken", Assets.Load("DLC3/Drone_Cleanup")); pingIconDict.Add("CopycatDroneBroken", Assets.Load("DLC3/Drone_Freeze")); pingIconDict.Add("BombardmentDroneBroken", Assets.Load("DLC3/Drone_Bomber")); pingIconDict.Add("MegaDroneBroken", Assets.Load("DroneMegaIcon")); } public static void Pings_Chests() { SetAllIcons("19deacd9e155c044595f2c344e110dde", LegacyResourcesAPI.Load("textures/miscicons/texInventoryIconOutlined")); SetAllIcons("f460ead3fd64fe0408ec760850cf3301", "ChestLargeIcon"); SetAllIcons("e4f9d194b928e2943962a39ad25cc9b7", "ChestLegendaryIcon"); SetAllIcons("7886981945e868f43852dfd0a6832ae2", "ChestCategoryDamage"); SetAllIcons("624679952282b144a8ad63c93b0d8abc", "ChestCategoryHealing"); SetAllIcons("6722ebff89fcfc94e84212a1ba51d46a", "ChestCategoryUtility"); SetAllIcons("RoR2/DLC1/CategoryChest2/CategoryChest2Damage Variant.prefab", "ChestCategory2Damage"); SetAllIcons("RoR2/DLC1/CategoryChest2/CategoryChest2Healing Variant.prefab", "ChestCategory2Healing"); SetAllIcons("RoR2/DLC1/CategoryChest2/CategoryChest2Utility Variant.prefab", "ChestCategory2Utility"); SetAllIcons("26aed741113c79c49806d3144ba32731", "ChestLunarIcon"); SetAllIcons("70ee08f9f87fa3e41bb3dd8efb1c363f", "ChestEquipIcon"); SetAllIcons("fd68bfe758b25714288565a552d40d83", "ChestCasinoIcon"); SetAllIcons("7d97551ee4c1e904b9a225abc63c3f0d", "ChestInvisibleIcon"); SetAllIcons("e82b1a3fea19dfd439109683ce4a14b7", "DLC1/ChestVoid"); SetAllIcons("341c368b343432b4dbe8ff30752fbbb4", "DLC1/ChestVoidPotential"); SetAllIcons("RoR2/Base/TreasureCache/Lockbox.prefab", "LockedIcon"); SetAllIcons("RoR2/DLC1/TreasureCacheVoid/LockboxVoid.prefab", "LockedIconAlt"); SetAllIcons("RoR2/DLC1/FreeChestMultiShop/FreeChestMultiShop.prefab", "PingIconShippingDrone"); SetAllIcons("RoR2/DLC1/FreeChestTerminalShippingDrone/FreeChestTerminalShippingDrone.prefab", "PingIconShippingDrone"); SetAllIcons("e6f68d343e0ec6645986c7af57417bee", "ScavBagIcon"); SetAllIcons("269db96d60fd1df49a685e708d1aa81f", "ScavBagIcon"); SetAllIcons("3e5352137390b2e4a8ced6c62df6be34", "ScavBagIcon"); SetAllIcons("664d4964dd9d5cf408168f09b05a0cb3", "ChestTimedIcon"); SetAllIcons("063fc18c1e1408b42a2c4aa3a789e906", "TrippleShop_Small"); SetAllIcons("9eb9c2d7c9f1cb54c9aee8bb625259f5", "TrippleShop_Small"); SetAllIcons("c87d4eb171e0ee44cb2d4ec714c58c72", "TrippleShop_Large"); SetAllIcons("c814170ba819d7b45934c0fc54fd99d1", "TrippleShop_Large"); SetAllIcons("e992781bd4b52804c8d340a56db49a06", "TrippleShop_Equipment"); SetAllIcons("63251d66a257b1a4c8eed4de5dd89561", "TrippleShop_Equipment"); SetAllIcons("d31df5066858329458b33f21b3b22d2e", "DLC3/TempVendor"); } public static void Pings_Shrines() { SetAllIcons("da96cf099344e8b4fa0f8198af665244", "ShrineMountainIcon"); SetAllIcons("ae1455033c65c694e9abf728a10418b2", "ShrineMountainIcon"); SetAllIcons("f7bb8988c277bc740bbc041c09dc81fd", "ShrineMountainIcon"); SetAllIcons("afcf09fce0fd504498c42cc15c6e77ef", "ShrineBloodIcon"); SetAllIcons("b77af4163bbc41549916df3bdfed560e", "ShrineBloodIcon"); SetAllIcons("d7851739065b43748a1b1e22e5280558", "ShrineBloodIcon"); SetAllIcons("8a681654848ac374980fea55c4cf55a7", "ShrineChanceIcon"); SetAllIcons("ccb461071fd3f6d4c9bc0bd96af47721", "ShrineChanceIcon"); SetAllIcons("a232aa071f626734d9e6349ef4f984ca", "ShrineChanceIcon"); SetAllIcons("d59b10d76f9ca41489a04053300576c1", "ShrineOrderIcon"); SetAllIcons("7cb2ac171b983124b851c8b883e6754f", "ShrineOrderIcon"); SetAllIcons("36f43f9ec00ade748927e89df4b0e743", "ShrineOrderIcon"); SetAllIcons("9f0ac77d429ca5d40b3870b5feaec1b5", "ShrineHealIcon"); SetAllIcons("3e31184a8e111c54b9ea20fbcb67ee49", "ShrineGoldIcon"); SetAllIcons("f521acffba61ae040a5cbd40c7d30141", "CleanseIcon"); SetAllIcons("52e1e53e0ae52184897f5b940b270326", "CleanseIcon"); SetAllIcons("7a4808b55ec828748bd6f8820c5b9faf", "CleanseIcon"); SetAllIcons("50f9b823c49c5a8468dadcd770415e2f", "DLC2/ShrineShaping"); SetAllIcons("c10fd181efcffc24f8fed4c2f246fac8", "DLC2/SotsIcon3_Shrunk"); SetAllIcons("59244efe276f7bb47ae34fbbb0095b5f", "DLC2/SotsIcon3_Shrunk"); } public static void Pings_Drones() { SetAllIcons("60e08168b0a17fd43a94b7493175608a", "DroneTurretIcon"); SetAllIcons("61c9fc1ae1d9c54489ed062b6aee78f2", "DroneEquipmentIcon"); SetAllIcons("e4fe5cc222934f043a63cafe4e9a7960", "DroneHealIcon"); SetAllIcons("5d5f4ad58811263418cfe7e5e6fca555", "DroneEmergencyIcon"); SetAllIcons("991dfa1354cf4aa4ca3758e8f0745312", "DroneMissileIcon"); SetAllIcons("d9979d4c99d42ad4886f4dc13ef72b30", "DroneFlameIcon"); SetAllIcons("5891e07c07cb11141ac34a5cd55e51ee", "DroneMegaIcon"); SetAllIcons("bfc3ebeae2b68bd458bbf0059301053a", "DLC3/Drone_Transport"); SetAllIcons("8e572d3d605684e408cc5480c24171b4", "DLC3/Drone_Junk"); SetAllIcons("9842714e20c0b0e4696db39caa97dd07", "DLC3/Drone_Barrier"); SetAllIcons("57a1adb4e1dfda540b9097b6bcbf3488", "DLC3/Drone_Cleanup"); SetAllIcons("c8b005f303334c040b7011f563c4bfc9", "DLC3/Drone_Jailer"); SetAllIcons("1452f88e28bf6524897c9abf2fabb9a5", "DLC3/Drone_Bomber"); SetAllIcons("3e7219df186245c49a3d9f622ffe1955", "DLC3/Drone_Freeze"); SetAllIcons("d3a49e0172a17c847aea4585b65cd418", "DLC3/Drone__Shop"); } public static void Pings_Printer() { SetAllIcons("f21b2c8a9cc028046935ea871dc4af54", "PrinterLarge"); SetAllIcons("8a8411ca0d2c7de4f8f5e5f85a91a8f7", "Printer"); SetAllIcons("5a46385c842a0cd4990bc33c0237dda4", "PrinterMili"); SetAllIcons("c1498d4e50ce815458de7d84f1e903c3", "PrinterWild"); SetAllIcons("f3f941fba20ea0a45bfad9d1b78474b7", "ScrapperIcon"); SetAllIcons("60048e6f3cc383a418818ae8315ff8b3", "DLC3/Drone__Combiner"); SetAllIcons("ce12b07631d644a4aa9b5191ed1956f5", "DLC3/Drone__Scrapper"); SetAllIcons("b2eb207c2edb18b459a03c271b97be17", "LunarCauldron"); SetAllIcons("277e9808d2bf40f45a4732c2ef8a5070", "LunarCauldron"); SetAllIcons("205b0f1b9c2a8de47945946eca80e564", "LunarCauldron"); } public static void Pings_Other() { //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_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_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_018f: 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) NullVentIcon = Assets.Bundle.LoadAsset("Assets/WQoL/PingIcons/Void_Cell.png"); PrimordialTeleporterChargedIcon = Assets.Bundle.LoadAsset("Assets/WQoL/PingIcons/PrimordialTeleporterChargedIcon.png"); LunarIcon = Assets.Bundle.LoadAsset("Assets/WQoL/PingIcons/LunarIcon.png"); VoidIcon = Addressables.LoadAssetAsync((object)"RoR2/DLC1/DeepVoidPortalBattery/texDeepVoidPortalBatteryIcon.png").WaitForCompletion(); Sprite val = Addressables.LoadAssetAsync((object)"ccf87dcf9daaa0645a94a7e14fa5749a").WaitForCompletion(); Sprite pingIconOverride = LegacyResourcesAPI.Load("textures/miscicons/texRescueshipIcon"); Sprite sprite = Addressables.LoadAssetAsync((object)"RoR2/DLC1/GameModes/InfiniteTowerRun/ITAssets/texInfiniteTowerSafeWardIcon.png").WaitForCompletion(); LegacyResourcesAPI.Load("Prefabs/CharacterBodies/ArtifactShellBody").AddComponent(); LegacyResourcesAPI.Load("Prefabs/CharacterBodies/ArtifactShellBody").AddComponent().pingIconOverride = QuestionMarkIcon; SetAllIcons("06d0621d2cadf98439f357fe148e7791", VoidIcon); SetAllIcons("8a6a0189c5090eb4bab48bd10e3074ea", "Void_Cell"); SetAllIcons("09ebe2eaaf93ad640a8d505eb6d7f5b6", VoidIcon); SetAllIcons("e515327d3d5e0144488357748ce1e899", "VoidIcon"); SetAllIcons("ba70f68b08210a84f86ff7a12a324263", sprite); SetAllIcons("9ff23f803358e9d42a7d7c4c1200b6f7", sprite); SetAllIcons("aa803cc8277f3b54fafd988a6fbabe64", "LunarSeer"); Sprite sprite2 = LegacyResourcesAPI.Load("textures/miscicons/texLunarPillarIcon"); SetAllIcons("b790659c0441e464e8921a2b0c536acb", sprite2); SetAllIcons("aa2c395b0fc2d3b4e8102691b5da81af", sprite2); SetAllIcons("34a1c551103d9214aab8ded73405b0d3", sprite2); SetAllIcons("b3bcad23353b0434abbab25614098026", sprite2); SetAllIcons("019dc92c7d183e24bb69db690bbcff90", "RadarTower", setInspect: false); SetAllIcons("452b7f73a60721b4eb546e2efe29d6d2", "LemurianEgg"); SetAllIcons("e69e4c37270ee1f4a8ecd2e60c03faad", "DLC1/VendingMachine"); Addressables.LoadAssetAsync((object)"be6e220724818e54493d5447cc8caa4e").WaitForCompletion().GetComponent() .portraitIcon = (Texture)(object)val.texture; SetAllIcons("3a7dc0d37d5875c4a9eafc8d7097c000", "DLC1/VoidStalk"); LegacyResourcesAPI.Load("Prefabs/networkedobjects/QuestVolatileBatteryWorldPickup").AddComponent().pingIconOverride = pingIconOverride; LegacyResourcesAPI.Load("Prefabs/networkedobjects/SurvivorPodBatteryPanel").AddComponent().pingIconOverride = pingIconOverride; LegacyResourcesAPI.Load("Prefabs/networkedobjects/teleporters/LunarTeleporter Variant").AddComponent().pingIconOverride = Assets.Bundle.LoadAsset("Assets/WQoL/PingIcons/PrimordialTeleporterIcon.png"); LegacyResourcesAPI.Load("Prefabs/networkedobjects/teleporters/LunarTeleporterProngs").AddComponent().pingIconOverride = PrimordialTeleporterChargedIcon; LegacyResourcesAPI.Load("Prefabs/networkedobjects/HumanFan").AddComponent(); LegacyResourcesAPI.Load("Prefabs/networkedobjects/GoldshoresBeacon").GetComponent().pingIconOverride = ExclamationIcon; LegacyResourcesAPI.Load("Prefabs/networkedobjects/captainsupplydrops/CaptainSupplyDrop, Healing").AddComponent().pingIconOverride = ExclamationIcon; LegacyResourcesAPI.Load("Prefabs/networkedobjects/captainsupplydrops/CaptainSupplyDrop, Shocking").AddComponent().pingIconOverride = ExclamationIcon; LegacyResourcesAPI.Load("Prefabs/networkedobjects/captainsupplydrops/CaptainSupplyDrop, EquipmentRestock").AddComponent().pingIconOverride = ExclamationIcon; LegacyResourcesAPI.Load("Prefabs/networkedobjects/captainsupplydrops/CaptainSupplyDrop, Hacking").AddComponent().pingIconOverride = ExclamationIcon; } public static void ModSupport() { r2apiRoot = Merc_Red.MercSwordSlash_Red.transform.parent; if (WQoLMain.QualityModInstalled) { ModPing_Quality(); } if (Chainloader.PluginInfos.ContainsKey("com.TeamMoonstorm")) { ModPing_SS2(); } if (Chainloader.PluginInfos.ContainsKey("com.Zenithrium.vanillaVoid")) { ModPing_VV(); } if (Chainloader.PluginInfos.ContainsKey("com.Viliger.EnemiesReturns")) { ModPing_EnemyReturns(); } } public static bool ModPing_ZetAspects(ItemDef def) { return ZetAspectsContent.itemDefs.Contains(def); } public static void ModPing_EnemyReturns() { SetAllIcons(MechanicalSpiderStuff.InteractablePrefab, "Mod/EnemyReturn/Drone_Spider"); SetAllIcons(LynxTribeStuff.LynxShrine1, "Mod/EnemyReturn/ShrineLynx"); SetAllIcons(LynxTribeStuff.LynxShrine2, "Mod/EnemyReturn/ShrineLynx"); SetAllIcons(LynxTribeStuff.LynxShrine3, "Mod/EnemyReturn/ShrineLynx"); SetupJudgementPath.PileOfDirt.GetComponent().shouldShowOnScanner = true; UnityObjectExtensions.EnsureComponent(SetupJudgementPath.PileOfDirt).pingIconOverride = ExclamationIcon; } public static void ModPing_SS2() { SetAllIcons(SS2Assets.LoadAsset("acShockDrone", (SS2Bundle)16).interactablePrefab, "Mod/SS2/DroneShock"); SetAllIcons(SS2Assets.LoadAsset("acCloneDrone", (SS2Bundle)16).interactablePrefab, "Mod/SS2/DroneDuplicator"); SetAllIcons(SS2Assets.LoadAsset("acDroneTable", (SS2Bundle)16).interactablePrefab, "Mod/SS2/DroneTable"); SetAllIcons(SS2Assets.LoadAsset("acLunarGambler", (SS2Bundle)16).interactablePrefab, ExclamationIcon); SetAllIcons(EtherealBehavior.shrinePrefab, "Mod/SS2/Shrine_Ethereal"); UnityObjectExtensions.EnsureComponent(VoidBehavior.rockPrefab).pingIconOverride = ExclamationIcon; } public static void ModPing_VV() { //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) if (Object.op_Implicit((Object)(object)ShatteredMonolith.InteractableBodyModelPrefab)) { SetAllIcons(ShatteredMonolith.InteractableBodyModelPrefab, "PingIconVoidEradicator"); } if (Object.op_Implicit((Object)(object)VoidShell.PortalBattery)) { SetAllIcons(VoidShell.PortalBattery, Addressables.LoadAssetAsync((object)"RoR2/DLC1/DeepVoidPortalBattery/texDeepVoidPortalBatteryIcon.png").WaitForCompletion()); VoidShell.PortalBattery.AddComponent().interactable = SpawnListener.Interactable.vvVoidFreeChest; } } public static void ModPing_Quality() { SetAllIcons(((SpawnCard)SpawnCards.QualityChest1).prefab, "Mod/Quality/Quality_Chest"); SetAllIcons(((SpawnCard)SpawnCards.QualityChest2).prefab, "Mod/Quality/Quality_Chest2"); SetAllIcons(((SpawnCard)SpawnCards.QualityEquipmentBarrel).prefab, "Mod/Quality/Quality_Equip"); SetAllIcons(((SpawnCard)SpawnCards.QualityDuplicator).prefab, "Mod/Quality/Quality_Printer"); ((SpawnCard)SpawnCards.QualityDuplicatorLarge).prefab.AddComponent().interactable = SpawnListener.Interactable.greenPrinterQuality; SetAllIcons(((SpawnCard)SpawnCards.QualityDuplicatorLarge).prefab, "Mod/Quality/Quality_PrinterLarge"); SetAllIcons(((SpawnCard)SpawnCards.QualityDuplicatorMilitary).prefab, "Mod/Quality/Quality_PrinterMili"); SetAllIcons(((SpawnCard)SpawnCards.QualityDuplicatorWild).prefab, "Mod/Quality/Quality_PrinterWild"); Transform val = r2apiRoot.Find("SpeedOnPickupBarrel"); if (Object.op_Implicit((Object)(object)val)) { SetAllIcons(((Component)val).gameObject, "Mod/Quality/Cool_Barrel"); ((Component)val).gameObject.AddComponent().interactable = SpawnListener.Interactable.QualityCollectorsBarrel; } } } public class BlockScanner : PingInfoProvider { } public class ChefOil : MonoBehaviour { [CompilerGenerated] private static class <>O { public static hook_DoGhostVisual <0>__OilGhostController_DoGhostVisual; } public static GameObject FireMeatBallExplosion = Addressables.LoadAssetAsync((object)"02e06953c75c74746b1e1f957f804e37").WaitForCompletion(); public static GameObject ChefIceBoxExplosionVFX = Addressables.LoadAssetAsync((object)"d7fd97a7825c2644e83cea446b03e54b").WaitForCompletion(); public static void Start() { //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_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_002f: Expected O, but got Unknown GameObject val = Addressables.LoadAssetAsync((object)"RoR2/DLC2/Chef/ChefImpactOilGhost.prefab").WaitForCompletion(); object obj = <>O.<0>__OilGhostController_DoGhostVisual; if (obj == null) { hook_DoGhostVisual val2 = OilGhostController_DoGhostVisual; <>O.<0>__OilGhostController_DoGhostVisual = val2; obj = (object)val2; } OilGhostController.DoGhostVisual += (hook_DoGhostVisual)obj; ((Component)val.transform.GetChild(0).GetChild(1)).gameObject.AddComponent().soundEvent = "Play_scorchling_slagBomb_explo"; ((Component)val.transform.GetChild(0).GetChild(2)).gameObject.AddComponent().soundEvent = "Play_scorchling_slagBomb_explo"; Object.Destroy((Object)(object)((Component)val.transform.GetChild(0).GetChild(4)).gameObject.GetComponent()); } private static void OilGhostController_DoGhostVisual(orig_DoGhostVisual orig, OilGhostController self, bool ignited, bool boosted, bool frozen) { //IL_0018: Unknown result type (might be due to invalid IL or missing references) //IL_001d: Unknown result type (might be due to invalid IL or missing references) //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002f: Unknown result type (might be due to invalid IL or missing references) //IL_0040: Expected O, but got Unknown //IL_0050: Unknown result type (might be due to invalid IL or missing references) //IL_0055: Unknown result type (might be due to invalid IL or missing references) //IL_005c: Unknown result type (might be due to invalid IL or missing references) //IL_0067: Unknown result type (might be due to invalid IL or missing references) //IL_0078: Expected O, but got Unknown orig.Invoke(self, ignited, boosted, frozen); if (ignited) { EffectManager.SpawnEffect(FireMeatBallExplosion, new EffectData { origin = ((Component)self).transform.position, scale = 25f }, false); } else if (frozen) { EffectManager.SpawnEffect(ChefIceBoxExplosionVFX, new EffectData { origin = ((Component)self).transform.position, scale = 10f }, false); } } } public static class DuplicatorModel { public static RuntimeAnimatorController oldAnimationControllerNOT; public static void DuplicatorModelChanger() { //IL_00dc: 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_00fb: Unknown result type (might be due to invalid IL or missing references) //IL_010b: Unknown result type (might be due to invalid IL or missing references) //IL_014d: 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_016c: Unknown result type (might be due to invalid IL or missing references) //IL_017c: Unknown result type (might be due to invalid IL or missing references) GameObject val = LegacyResourcesAPI.Load("Prefabs/networkedobjects/chest/DuplicatorLarge"); GameObject val2 = LegacyResourcesAPI.Load("Prefabs/networkedobjects/chest/DuplicatorMilitary"); if (WConfig.OldModelDuplcators.Value) { Vector3 localPosition = default(Vector3); ((Vector3)(ref localPosition))..ctor(-1.23f, 1.832f, -0.108f); Vector3 localPosition2 = default(Vector3); ((Vector3)(ref localPosition2))..ctor(0f, 0.55f, 1.64f); Vector3 localScale = default(Vector3); ((Vector3)(ref localScale))..ctor(1.15f, 1.15f, 1.15f); Vector3 localPosition3 = default(Vector3); ((Vector3)(ref localPosition3))..ctor(1.35f, 1.0877f, 0.1f); Mesh sharedMesh = Assets.Bundle.LoadAsset("Assets/WQoL/General/DuplicatorOldMesh.asset"); RuntimeAnimatorController runtimeAnimatorController = Assets.Bundle.LoadAsset("Assets/WQoL/General/animDuplicatorOld.controller"); Transform child = val.transform.GetChild(0); ((Behaviour)((Component)child).GetComponent()).enabled = false; ((Component)child.GetChild(0)).GetComponent().sharedMesh = sharedMesh; child.GetChild(3).localPosition = localPosition; child.GetChild(5).localPosition = localPosition3; child.GetChild(4).localScale = localScale; child.GetChild(4).localPosition = localPosition2; ((Component)child).GetComponent().runtimeAnimatorController = runtimeAnimatorController; Transform child2 = val2.transform.GetChild(0); ((Component)child2.GetChild(0)).GetComponent().sharedMesh = sharedMesh; child2.GetChild(3).localPosition = localPosition; child2.GetChild(5).localPosition = localPosition3; child2.GetChild(4).localScale = localScale; child2.GetChild(4).localPosition = localPosition2; ((Component)child2).GetComponent().runtimeAnimatorController = runtimeAnimatorController; } } } public static class HoldoutZoneFlowers { [CompilerGenerated] private static class <>O { public static hook_Awake <0>__AddFlowersToMiscHoldoutZone; } [Serializable] [CompilerGenerated] private sealed class <>c { public static readonly <>c <>9 = new <>c(); public static hook_Start <>9__2_0; internal void b__2_0(orig_Start orig, HoldoutZoneController self) { //IL_001a: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self); if (!self.applyHealingNova) { return; } if (Util.GetItemCountForTeam((TeamIndex)1, Items.TPHealingNova.itemIndex, false, true) > 0) { if (Object.op_Implicit((Object)(object)self.healingNovaItemEffect)) { self.healingNovaItemEffect.SetActive(true); self.healingNovaItemEffect = null; } } else if (Object.op_Implicit((Object)(object)self.healingNovaItemEffect)) { self.healingNovaItemEffect.SetActive(false); } } } public static GameObject LeptonDaisyTeleporterDecoration; public static GameObject GlowFlowerForPillar; public static void FlowersForOtherHoldoutZones() { //IL_004a: 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_0097: 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_00f0: 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_0144: Unknown result type (might be due to invalid IL or missing references) //IL_0173: Unknown result type (might be due to invalid IL or missing references) //IL_019d: 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_01f6: Unknown result type (might be due to invalid IL or missing references) //IL_0220: Unknown result type (might be due to invalid IL or missing references) //IL_024a: Unknown result type (might be due to invalid IL or missing references) //IL_0279: 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_02be: Unknown result type (might be due to invalid IL or missing references) //IL_02c3: Unknown result type (might be due to invalid IL or missing references) //IL_02c9: Expected O, but got Unknown //IL_02e3: Unknown result type (might be due to invalid IL or missing references) //IL_02e8: Unknown result type (might be due to invalid IL or missing references) //IL_02ee: Expected O, but got Unknown HoldoutZoneController component = LegacyResourcesAPI.Load("Prefabs/networkedobjects/teleporters/Teleporter1").GetComponent(); LeptonDaisyTeleporterDecoration = component.healingNovaItemEffect; GlowFlowerForPillar = PrefabAPI.InstantiateClone(LeptonDaisyTeleporterDecoration, "GlowFlowerForPillar", false); GlowFlowerForPillar.transform.localScale = new Vector3(0.6f, 0.6f, 0.55f); GlowFlowerForPillar.transform.localPosition = new Vector3(0f, 0f, 1f); GlowFlowerForPillar.transform.localRotation = new Quaternion(0.5373f, 0.8434f, 0f, 0f); GlowFlowerForPillar.transform.GetChild(0).localPosition = new Vector3(-0.9f, -2.9f, 4.35f); GlowFlowerForPillar.transform.GetChild(0).localRotation = new Quaternion(-0.4991f, 0.0297f, 0.2375f, -0.8328f); GlowFlowerForPillar.transform.GetChild(0).localScale = new Vector3(0.4f, 0.4f, 0.4f); GlowFlowerForPillar.transform.GetChild(1).localPosition = new Vector3(0.9f, 2.9f, 4.3f); GlowFlowerForPillar.transform.GetChild(1).localRotation = new Quaternion(0.5f, 0f, 0f, -0.866f); GlowFlowerForPillar.transform.GetChild(1).localScale = new Vector3(0.55f, 0.55f, 0.55f); GlowFlowerForPillar.transform.GetChild(2).localPosition = new Vector3(-2.7f, 1.3f, 4.4f); GlowFlowerForPillar.transform.GetChild(2).localRotation = new Quaternion(-0.1504f, -0.4924f, -0.0868f, 0.8529f); GlowFlowerForPillar.transform.GetChild(2).localScale = new Vector3(0.45f, 0.45f, 0.45f); GlowFlowerForPillar.transform.GetChild(3).localPosition = new Vector3(2.8f, -1f, 4.3f); GlowFlowerForPillar.transform.GetChild(3).localRotation = new Quaternion(0.1504f, 0.4924f, -0.0868f, 0.8529f); GlowFlowerForPillar.transform.GetChild(3).localScale = new Vector3(0.5f, 0.5f, 0.5f); object obj = <>O.<0>__AddFlowersToMiscHoldoutZone; if (obj == null) { hook_Awake val = AddFlowersToMiscHoldoutZone; <>O.<0>__AddFlowersToMiscHoldoutZone = val; obj = (object)val; } HoldoutZoneController.Awake += (hook_Awake)obj; object obj2 = <>c.<>9__2_0; if (obj2 == null) { hook_Start val2 = delegate(orig_Start orig, HoldoutZoneController self) { //IL_001a: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self); if (self.applyHealingNova) { if (Util.GetItemCountForTeam((TeamIndex)1, Items.TPHealingNova.itemIndex, false, true) > 0) { if (Object.op_Implicit((Object)(object)self.healingNovaItemEffect)) { self.healingNovaItemEffect.SetActive(true); self.healingNovaItemEffect = null; } } else if (Object.op_Implicit((Object)(object)self.healingNovaItemEffect)) { self.healingNovaItemEffect.SetActive(false); } } }; <>c.<>9__2_0 = val2; obj2 = (object)val2; } HoldoutZoneController.Start += (hook_Start)obj2; } private static void AddFlowersToMiscHoldoutZone(orig_Awake orig, HoldoutZoneController self) { //IL_02c2: 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_00c3: 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_0197: Unknown result type (might be due to invalid IL or missing references) //IL_01bc: Unknown result type (might be due to invalid IL or missing references) //IL_01e1: Unknown result type (might be due to invalid IL or missing references) //IL_0265: Unknown result type (might be due to invalid IL or missing references) //IL_028a: Unknown result type (might be due to invalid IL or missing references) //IL_02af: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self); if (!self.applyHealingNova) { return; } if (!Object.op_Implicit((Object)(object)self.healingNovaItemEffect)) { if (((Object)self).name.StartsWith("InfiniteTowerSafeWard")) { self.healingNovaItemEffect = Object.Instantiate(LeptonDaisyTeleporterDecoration, ((Component)self).transform.GetChild(0).GetChild(0).GetChild(8) .GetChild(0) .GetChild(1) .GetChild(0)); self.healingNovaItemEffect.transform.rotation = new Quaternion(0f, -0.7071f, -0.7071f, 0f); self.healingNovaItemEffect.transform.localScale = new Vector3(0.1928f, 0.1928f, 0.1928f); self.healingNovaItemEffect.transform.localPosition = new Vector3(0f, -0.4193f, 0f); } else if (((Object)self).name.StartsWith("MoonBattery")) { self.healingNovaItemEffect = Object.Instantiate(GlowFlowerForPillar, ((Component)self).transform.GetChild(0).GetChild(0).GetChild(0) .GetChild(0) .GetChild(1)); } else if (((Object)self).name.StartsWith("NullSafeZone")) { self.healingNovaItemEffect = Object.Instantiate(LeptonDaisyTeleporterDecoration, ((Component)self).transform); self.healingNovaItemEffect.transform.rotation = new Quaternion(-0.5649f, -0.4254f, -0.4254f, 0.5649f); self.healingNovaItemEffect.transform.localScale = new Vector3(0.275f, 0.275f, 0.225f); self.healingNovaItemEffect.transform.localPosition = new Vector3(0f, -0.3f, 0f); } else if (((Object)self).name.StartsWith("DeepVoidPortalBattery(Clone)")) { self.healingNovaItemEffect = (self.healingNovaItemEffect = Object.Instantiate(GlowFlowerForPillar, ((Component)self).transform.GetChild(0).GetChild(2).GetChild(2) .GetChild(0) .GetChild(0))); self.healingNovaItemEffect.transform.localEulerAngles = new Vector3(270f, 0f, 0f); self.healingNovaItemEffect.transform.localScale = new Vector3(0.375f, 0.375f, 0.375f); self.healingNovaItemEffect.transform.localPosition = new Vector3(0f, -0.4f, 0f); } } if (Util.GetItemCountForTeam((TeamIndex)1, Items.TPHealingNova.itemIndex, false, true) > 0 && Object.op_Implicit((Object)(object)self.healingNovaItemEffect)) { self.healingNovaItemEffect.SetActive(true); self.healingNovaItemEffect = null; } } } public class MakePriceTransform : MonoBehaviour { public bool disableRotation; public Vector3 holoPos; public Vector3 holoRot; public void Awake() { //IL_0006: Unknown result type (might be due to invalid IL or missing references) //IL_000c: Expected O, but got Unknown //IL_0026: 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) GameObject val = new GameObject("PriceTransform"); val.transform.SetParent(((Component)this).transform, false); val.transform.localPosition = holoPos; HologramProjector val2 = ((Component)this).GetComponent(); if ((Object)(object)val2 == (Object)null) { val2 = ((Component)this).gameObject.AddComponent(); } val2.disableHologramRotation = disableRotation; val.transform.localEulerAngles = holoRot; val2.hologramPivot = val.transform; SpecialObjectAttributes val3 = default(SpecialObjectAttributes); if (((Component)this).TryGetComponent(ref val3)) { val3.behavioursToDisable.Add((MonoBehaviour)(object)val2); } } } public static class InteractableVisuals { [CompilerGenerated] private static class <>O { public static hook_RpcUpdateInteractionClients <0>__ShrineShapingExtras_Client; public static hook_ReviveAlliedPlayers <1>__ShrineShapingExtras_Host; public static Action <2>__SpawnEffectsOnRevive; } public static void Start() { //IL_0011: 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_001c: Expected O, but got Unknown //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Unknown result type (might be due to invalid IL or missing references) //IL_003d: Expected O, but got Unknown object obj = <>O.<0>__ShrineShapingExtras_Client; if (obj == null) { hook_RpcUpdateInteractionClients val = ShrineShapingExtras_Client; <>O.<0>__ShrineShapingExtras_Client = val; obj = (object)val; } ShrineColossusAccessBehavior.RpcUpdateInteractionClients += (hook_RpcUpdateInteractionClients)obj; object obj2 = <>O.<1>__ShrineShapingExtras_Host; if (obj2 == null) { hook_ReviveAlliedPlayers val2 = ShrineShapingExtras_Host; <>O.<1>__ShrineShapingExtras_Host = val2; obj2 = (object)val2; } ShrineColossusAccessBehavior.ReviveAlliedPlayers += (hook_ReviveAlliedPlayers)obj2; PriceTransformStuff(); } private static void ShrineShapingExtras_Host(orig_ReviveAlliedPlayers orig, ShrineColossusAccessBehavior self) { try { ShrineShapingExtra_VISUALS(); } catch (Exception ex) { Debug.LogError((object)ex); orig.Invoke(self); return; } orig.Invoke(self); } public static string NameOfAllDeadPlayers(out int anyDead) { string text = ""; anyDead = 0; foreach (PlayerCharacterMasterController instance in PlayerCharacterMasterController.instances) { if (instance.master.lostBodyToDeath) { anyDead++; text = text + Util.EscapeRichTextForTextMeshPro(instance.networkUser.userName) + "'s"; } } return text; } private static void RezEffectOnDead(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown ILCursor val = new ILCursor(il); if (val.TryGotoNext((MoveType)0, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchLdsfld(x, "RoR2.RoR2Content/Buffs", "Immune") })) { val.EmitDelegate>((Func)delegate(CharacterBody body) { //IL_0018: Unknown result type (might be due to invalid IL or missing references) //IL_001d: Unknown result type (might be due to invalid IL or missing references) //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_002f: Unknown result type (might be due to invalid IL or missing references) //IL_0036: 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_0046: Expected O, but got Unknown if (Object.op_Implicit((Object)(object)body)) { GameObject val2 = LegacyResourcesAPI.Load("Prefabs/Effects/HippoRezEffect"); EffectManager.SpawnEffect(val2, new EffectData { origin = body.transform.position, rotation = body.transform.rotation }, true); Util.PlaySound("Play_item_proc_extraLife", ((Component)body).gameObject); } return body; }); } else { Log.LogWarning("IL Failed : bro they forgot to make a rez effect2"); } } internal static void PriceTransformStuff() { //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_001a: Unknown result type (might be due to invalid IL or missing references) //IL_001f: Unknown result type (might be due to invalid IL or missing references) //IL_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_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_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_006b: Unknown result type (might be due to invalid IL or missing references) //IL_0070: Unknown result type (might be due to invalid IL or missing references) //IL_0090: Unknown result type (might be due to invalid IL or missing references) //IL_0095: Unknown result type (might be due to invalid IL or missing references) //IL_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_00ce: Unknown result type (might be due to invalid IL or missing references) //IL_00d3: Unknown result type (might be due to invalid IL or missing references) //IL_0111: Unknown result type (might be due to invalid IL or missing references) //IL_0116: Unknown result type (might be due to invalid IL or missing references) //IL_0131: Unknown result type (might be due to invalid IL or missing references) //IL_0136: Unknown result type (might be due to invalid IL or missing references) //IL_0151: 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) GameObject val = Addressables.LoadAssetAsync((object)"RoR2/Base/ShrineCleanse/ShrineCleanse.prefab").WaitForCompletion(); GameObject val2 = Addressables.LoadAssetAsync((object)"RoR2/Base/ShrineCleanse/ShrineCleanseSandy Variant.prefab").WaitForCompletion(); GameObject val3 = Addressables.LoadAssetAsync((object)"RoR2/Base/ShrineCleanse/ShrineCleanseSnowy Variant.prefab").WaitForCompletion(); GameObject val4 = Addressables.LoadAssetAsync((object)"RoR2/Base/TreasureCache/Lockbox.prefab").WaitForCompletion(); GameObject val5 = Addressables.LoadAssetAsync((object)"RoR2/DLC1/TreasureCacheVoid/LockboxVoid.prefab").WaitForCompletion(); GameObject val6 = Addressables.LoadAssetAsync((object)"RoR2/DLC1/VendingMachine/VendingMachine.prefab").WaitForCompletion(); val.AddComponent().holoPos = new Vector3(0f, 0.75f, -1.65f); val2.AddComponent().holoPos = new Vector3(0f, 0.75f, -1.65f); val3.AddComponent().holoPos = new Vector3(0f, 0.75f, -1.65f); val.GetComponent().disableRotation = true; val2.GetComponent().disableRotation = true; val3.GetComponent().disableRotation = true; val4.AddComponent().holoPos = new Vector3(0f, 1.6f, 0f); val5.AddComponent().holoPos = new Vector3(0f, 2f, 0f); val6.AddComponent().holoPos = new Vector3(0f, 4.5f, 0f); } private static void CharacterMaster_RespawnExtraLifeShrine(orig_RespawnExtraLifeShrine orig, CharacterMaster self) { //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0034: Unknown result type (might be due to invalid IL or missing references) //IL_003f: Unknown result type (might be due to invalid IL or missing references) //IL_004b: Unknown result type (might be due to invalid IL or missing references) //IL_0050: Unknown result type (might be due to invalid IL or missing references) //IL_005b: Expected O, but got Unknown orig.Invoke(self); if (NetworkServer.active && Object.op_Implicit((Object)(object)self.bodyInstanceObject)) { EffectManager.SpawnEffect(LegacyResourcesAPI.Load("Prefabs/Effects/HippoRezEffect"), new EffectData { origin = self.deathFootPosition, rotation = self.bodyInstanceObject.transform.rotation }, true); } } public static void ShrineShapingExtra_VISUALS() { //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_00ad: Unknown result type (might be due to invalid IL or missing references) //IL_00b8: Unknown result type (might be due to invalid IL or missing references) //IL_00b9: Unknown result type (might be due to invalid IL or missing references) //IL_00be: Unknown result type (might be due to invalid IL or missing references) //IL_00c3: Unknown result type (might be due to invalid IL or missing references) //IL_00ce: Unknown result type (might be due to invalid IL or missing references) //IL_00de: Unknown result type (might be due to invalid IL or missing references) //IL_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_00f3: Expected O, but got Unknown foreach (PlayerCharacterMasterController instance in PlayerCharacterMasterController.instances) { if (!instance.isConnected) { continue; } CharacterMaster master = instance.master; if (Object.op_Implicit((Object)(object)master)) { GameObject bodyObject = master.GetBodyObject(); Log.LogMessage(master.lostBodyToDeath + " " + (object)bodyObject); if (Object.op_Implicit((Object)(object)bodyObject)) { Util.PlaySound("Play_obj_portalShaping_activate", bodyObject); EffectManager.SpawnEffect(LegacyResourcesAPI.Load("Prefabs/Effects/ShrineUseEffect"), new EffectData { origin = bodyObject.transform.position, rotation = Quaternion.identity, scale = 1f, color = Color32.op_Implicit(new Color(16f / 51f, 0.8392157f, 64f / 85f)) }, false); } else { master.onBodyStart += SpawnEffectsOnRevive; } } } } private static void ShrineShapingExtras_Client(orig_RpcUpdateInteractionClients orig, ShrineColossusAccessBehavior self) { orig.Invoke(self); if (!NetworkServer.active) { ShrineShapingExtra_VISUALS(); } } private static void SpawnEffectsOnRevive(CharacterBody body) { //IL_001c: Unknown result type (might be due to invalid IL or missing references) //IL_0021: Unknown result type (might be due to invalid IL or missing references) //IL_0028: Unknown result type (might be due to invalid IL or missing references) //IL_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_0039: Unknown result type (might be due to invalid IL or missing references) //IL_003e: Unknown result type (might be due to invalid IL or missing references) //IL_0049: Unknown result type (might be due to invalid IL or missing references) //IL_0059: Unknown result type (might be due to invalid IL or missing references) //IL_005e: Unknown result type (might be due to invalid IL or missing references) //IL_0063: Unknown result type (might be due to invalid IL or missing references) //IL_006e: Expected O, but got Unknown //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_0085: 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_0097: Unknown result type (might be due to invalid IL or missing references) //IL_009c: Unknown result type (might be due to invalid IL or missing references) //IL_00a7: Expected O, but got Unknown Util.PlaySound("Play_obj_portalShaping_activate", ((Component)body).gameObject); EffectManager.SpawnEffect(LegacyResourcesAPI.Load("Prefabs/Effects/ShrineUseEffect"), new EffectData { origin = body.transform.position, rotation = Quaternion.identity, scale = 1f, color = Color32.op_Implicit(new Color(16f / 51f, 0.8392157f, 64f / 85f)) }, false); EffectManager.SpawnEffect(LegacyResourcesAPI.Load("Prefabs/Effects/HippoRezEffect"), new EffectData { origin = body.transform.position, rotation = body.transform.rotation }, false); body.master.onBodyStart -= SpawnEffectsOnRevive; } } public static class OptionPickup_Visuals { [CompilerGenerated] private static class <>O { public static hook_GiveColossusItem <0>__FalseSon_GreenOrRed; public static hook_SetOptionsInternal <1>__OptionPickup_Fixes; } public static ItemTier orange = (ItemTier)100; public static void Start() { //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_002c: 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_00d2: Unknown result type (might be due to invalid IL or missing references) //IL_00d7: Unknown result type (might be due to invalid IL or missing references) //IL_01c0: Unknown result type (might be due to invalid IL or missing references) //IL_01e2: 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) //IL_0226: Unknown result type (might be due to invalid IL or missing references) //IL_00bc: Unknown result type (might be due to invalid IL or missing references) //IL_00c1: Unknown result type (might be due to invalid IL or missing references) //IL_00c7: Expected O, but got Unknown //IL_0241: Unknown result type (might be due to invalid IL or missing references) //IL_0246: Unknown result type (might be due to invalid IL or missing references) //IL_024c: Expected O, but got Unknown GameObject val = Addressables.LoadAssetAsync((object)"RoR2/DLC1/OptionPickup/OptionPickup.prefab").WaitForCompletion(); Transform child = val.transform.GetChild(0); GameObject val2 = Addressables.LoadAssetAsync((object)"RoR2/DLC1/OptionPickup/OptionPickerPanel.prefab").WaitForCompletion(); ((Component)child.GetChild(0)).GetComponent().radius = 1.5f; for (int i = 1; i < child.childCount; i++) { child.GetChild(i).localPosition = new Vector3(0f, -0.5f, 0f); ((Behaviour)((Component)child.GetChild(i)).GetComponent()).enabled = false; } val2.GetComponent().maxColumnCount = 3; object obj = <>O.<0>__FalseSon_GreenOrRed; if (obj == null) { hook_GiveColossusItem val3 = FalseSon_GreenOrRed; <>O.<0>__FalseSon_GreenOrRed = val3; obj = (object)val3; } SkyJumpDeathState.GiveColossusItem += (hook_GiveColossusItem)obj; GameObject val4 = Addressables.LoadAssetAsync((object)"RoR2/DLC2/FragmentPotentialPickup.prefab").WaitForCompletion(); Transform child2 = val4.transform.GetChild(0); ((Component)child2.GetChild(1).GetChild(0).GetChild(3)).gameObject.SetActive(false); ((Component)child2.GetChild(2).GetChild(2)).gameObject.SetActive(false); ((Component)child2.GetChild(3).GetChild(2)).gameObject.SetActive(false); ((Component)child2.GetChild(5).GetChild(2)).gameObject.SetActive(false); Object.Destroy((Object)(object)((Component)child2.GetChild(1)).GetComponent()); Object.Destroy((Object)(object)((Component)child2.GetChild(2)).GetComponent()); Object.Destroy((Object)(object)((Component)child2.GetChild(3)).GetComponent()); Object.Destroy((Object)(object)((Component)child2.GetChild(5)).GetComponent()); child2.GetChild(1).localPosition = new Vector3(0f, -1f, 0f); child2.GetChild(2).localPosition = new Vector3(0f, -1f, 0f); child2.GetChild(3).localPosition = new Vector3(0f, -1f, 0f); child2.GetChild(5).localPosition = new Vector3(0f, -1f, 0f); object obj2 = <>O.<1>__OptionPickup_Fixes; if (obj2 == null) { hook_SetOptionsInternal val5 = OptionPickup_Fixes; <>O.<1>__OptionPickup_Fixes = val5; obj2 = (object)val5; } PickupPickerController.SetOptionsInternal += (hook_SetOptionsInternal)obj2; } public static ItemTier MeridianFragmentRedOrGreenOrWhite(bool colossus) { //IL_0009: Unknown result type (might be due to invalid IL or missing references) //IL_000f: Invalid comparison between Unknown and I4 //IL_00a2: 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_002f: 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_0084: Unknown result type (might be due to invalid IL or missing references) if (colossus || (int)MeridianEventTriggerInteraction.instance.meridianEventState >= 4) { if (MeridianEventTriggerInteraction.instance.isGoldTitanSpawned) { return (ItemTier)2; } foreach (PlayerCharacterMasterController instance in PlayerCharacterMasterController.instances) { if (Object.op_Implicit((Object)(object)instance) && Object.op_Implicit((Object)(object)instance.master) && instance.master.inventory.GetItemCount(Items.TitanGoldDuringTP) > 0) { return (ItemTier)2; } } return (ItemTier)1; } return (ItemTier)0; } private static void FalseSon_GreenOrRed(orig_GiveColossusItem orig, SkyJumpDeathState self) { //IL_0019: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) if (self.FalseSonUnlockStateMet()) { self.rewardDisplayTier = (ItemTier)2; } else { self.rewardDisplayTier = (ItemTier)1; } orig.Invoke(self); } private static void OptionPickup_Fixes(orig_SetOptionsInternal orig, PickupPickerController self, Option[] newOptions) { //IL_024c: Unknown result type (might be due to invalid IL or missing references) //IL_0251: Unknown result type (might be due to invalid IL or missing references) //IL_0281: Unknown result type (might be due to invalid IL or missing references) //IL_0286: Unknown result type (might be due to invalid IL or missing references) //IL_029d: Unknown result type (might be due to invalid IL or missing references) //IL_02a2: Unknown result type (might be due to invalid IL or missing references) //IL_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_005e: Unknown result type (might be due to invalid IL or missing references) //IL_02c6: Unknown result type (might be due to invalid IL or missing references) //IL_02cb: Unknown result type (might be due to invalid IL or missing references) //IL_02cd: Unknown result type (might be due to invalid IL or missing references) //IL_02cf: Unknown result type (might be due to invalid IL or missing references) //IL_02d1: Unknown result type (might be due to invalid IL or missing references) //IL_0300: Expected I4, but got Unknown //IL_0070: Unknown result type (might be due to invalid IL or missing references) //IL_0075: Unknown result type (might be due to invalid IL or missing references) //IL_0077: Unknown result type (might be due to invalid IL or missing references) //IL_007a: Invalid comparison between Unknown and I4 //IL_03be: Unknown result type (might be due to invalid IL or missing references) //IL_03c3: Unknown result type (might be due to invalid IL or missing references) //IL_012f: Unknown result type (might be due to invalid IL or missing references) //IL_016f: Unknown result type (might be due to invalid IL or missing references) //IL_018a: Unknown result type (might be due to invalid IL or missing references) //IL_018f: Unknown result type (might be due to invalid IL or missing references) //IL_01a6: Unknown result type (might be due to invalid IL or missing references) //IL_01ab: Unknown result type (might be due to invalid IL or missing references) //IL_01c1: 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_008c: Unknown result type (might be due to invalid IL or missing references) //IL_020e: Unknown result type (might be due to invalid IL or missing references) //IL_0213: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self, newOptions); PickupIndexNetworker component = ((Component)self).GetComponent(); bool flag = ((Object)self).name.StartsWith("Option"); bool flag2 = ((Object)self).name.StartsWith("Fragment"); if (flag2) { if (Object.op_Implicit((Object)(object)MeridianEventTriggerInteraction.instance) && component.NetworkpickupState.pickupIndex == PickupCatalog.itemTierToPickupIndex[(ItemTier)0]) { ItemTier val = MeridianFragmentRedOrGreenOrWhite(colossus: false); if ((int)val == 2) { } component.pickupIndex = PickupCatalog.itemTierToPickupIndex[val]; } if (WConfig.cfgFragmentColor.Value) { Highlight component2 = ((Component)self).GetComponent(); Transform val2 = ((Component)component2.targetRenderer).transform.Find("CloneMeshForOutline"); if ((Object)(object)val2 == (Object)null) { ((Behaviour)component2).enabled = false; val2 = Object.Instantiate(((Component)component2.targetRenderer).gameObject, ((Component)component2.targetRenderer).transform).transform; ((Object)val2).name = "CloneMeshForOutline"; ((Component)val2).transform.localScale = new Vector3(1.12f, 1.12f, 1.12f); ((Component)((Component)val2).transform.GetChild(0)).gameObject.SetActive(false); ((Component)((Component)val2).transform.GetChild(1)).gameObject.SetActive(false); component2.highlightColor = (HighlightColor)3; component2.CustomColor = new Color(0.933f, 0.791f, 0.505f, 1f); Highlight val3 = ((Component)val2).gameObject.AddComponent(); val3.pickupState = component2.pickupState; val3.isOn = component2.isOn; val3.highlightColor = (HighlightColor)2; val3.targetRenderer = ((Component)val2).GetComponent(); val3.targetRenderer.enabled = false; ((Behaviour)component2).enabled = true; } else if (Object.op_Implicit((Object)(object)val2)) { Highlight component3 = ((Component)val2).gameObject.GetComponent(); component3.pickupState = component2.pickupState; component3.isOn = component2.isOn; } } } if (!(flag || flag2)) { return; } PickupDisplay component4 = ((Component)((Component)self).transform.GetChild(0)).GetComponent(); component4.pickupState = component.pickupState; component4.modelObject = ((Component)((Component)self).transform.GetChild(0).GetChild(0).GetChild(0)).gameObject; ((Component)self).GetComponent().pickupState = component.pickupState; ((Component)self).GetComponent().isOn = true; if (!(component.pickupState.pickupIndex != PickupIndex.none)) { return; } ItemTier itemTier = ((PickupIndex)(ref component.pickupState.pickupIndex)).pickupDef.itemTier; ItemTier val4 = itemTier; switch ((int)val4) { case 0: component4.tier1ParticleEffect.SetActive(true); break; case 1: component4.tier2ParticleEffect.SetActive(true); break; case 2: component4.tier3ParticleEffect.SetActive(true); break; case 4: component4.bossParticleEffect.SetActive(true); break; case 3: component4.lunarParticleEffect.SetActive(true); break; case 6: case 7: case 8: case 9: if (!Object.op_Implicit((Object)(object)component4.voidParticleEffect)) { component4.voidParticleEffect = Object.Instantiate(LegacyResourcesAPI.Load("Prefabs/NetworkedObjects/GenericPickup").GetComponent().pickupDisplay.voidParticleEffect, ((Component)component4).transform); } component4.voidParticleEffect.SetActive(true); break; } if (((PickupIndex)(ref component.pickupState.pickupIndex)).pickupDef.itemTier == orange) { component4.equipmentParticleEffect.SetActive(true); } } } public static class VisibleHabitatFall { public static bool Should() { //IL_0017: Unknown result type (might be due to invalid IL or missing references) //IL_001d: Expected O, but got Unknown if (!WConfig.cfgLoopPM_LemurianTemple.Value) { return false; } SceneExitController val = new SceneExitController(); if ((Object)(object)val.GetLoopedStageOrDefault(SceneList.Habitat) == (Object)(object)SceneList.Habitat) { return false; } Object.Destroy((Object)(object)val); return true; } public static void LemurianTemple() { //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_001f: Unknown result type (might be due to invalid IL or missing references) //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_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_0043: Unknown result type (might be due to invalid IL or missing references) //IL_0048: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_005c: Unknown result type (might be due to invalid IL or missing references) //IL_006b: Unknown result type (might be due to invalid IL or missing references) //IL_0070: Unknown result type (might be due to invalid IL or missing references) //IL_009f: 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_00e5: 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_012a: Unknown result type (might be due to invalid IL or missing references) //IL_014c: Unknown result type (might be due to invalid IL or missing references) //IL_0151: Unknown result type (might be due to invalid IL or missing references) Color color = new Color(0.6604f, 0.3208f, 0.529f, 1f) * 1.1f; Material val = Object.Instantiate(Addressables.LoadAssetAsync((object)"58c26464c97ed5247914273e05f683c5").WaitForCompletion()); Material material = Addressables.LoadAssetAsync((object)"75319e5dc7ca5ee47ae5608402e9e977").WaitForCompletion(); Material material2 = Addressables.LoadAssetAsync((object)"c631f00ba144f1648911a6d238b200df").WaitForCompletion(); GameObject val2 = Addressables.LoadAssetAsync((object)"935ddd13feca6a04b8d7e3e9bc9701d2").WaitForCompletion(); Material val3 = Object.Instantiate(((Renderer)((Component)val2.transform.GetChild(0)).GetComponent()).material); Material val4 = val3; val3.color = color; val3.mainTexture = (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/LemurianTemple/LTFallenLeaf_Atlas.png"); val3.SetColor("_HueVariation", new Color(1f, 0.5f, 0.1f, 0.5f)); val4.color = color; val4.mainTexture = (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/LemurianTemple/LTFallenLeaf_Atlas.png"); val4.SetColor("_HueVariation", new Color(1f, 0.5f, 0.1f, 0.5f)); val.color = color; val.mainTexture = (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/LemurianTemple/BHDistantTreeP_Atlas.png"); Material val5 = Object.Instantiate(Addressables.LoadAssetAsync((object)"07c4ea42012852645847968d57881370").WaitForCompletion()); val5.SetFloat("_SnowBias", 0f); GameObject val6 = GameObject.Find("/HOLDER:Terrain/LTTerrain/meshLTCeilingRoots"); ((Renderer)val6.GetComponent()).material = val5; GameObject val7 = GameObject.Find("/HOLDER: ToggleGroups/HOLDER: TG FrontC/LTColumnTGCVine"); if (Object.op_Implicit((Object)(object)val7)) { ((Renderer)val7.GetComponent()).material = val5; } GameObject val8 = GameObject.Find("/HOLDER: Foliage"); GameObject val9 = GameObject.Find("/Weather, LemurianTemple"); Transform child = val9.transform.GetChild(5); ParticleSystemRenderer[] componentsInChildren = ((Component)child).GetComponentsInChildren(); ParticleSystemRenderer[] array = componentsInChildren; foreach (ParticleSystemRenderer val10 in array) { ((Renderer)val10).material = val; } Transform child2 = val8.transform.GetChild(1); BillboardRenderer[] componentsInChildren2 = ((Component)child2).GetComponentsInChildren(); BillboardRenderer[] array2 = componentsInChildren2; foreach (BillboardRenderer val11 in array2) { val11.billboard.material = material; } MeshRenderer[] componentsInChildren3 = ((Component)child2).GetComponentsInChildren(); MeshRenderer[] array3 = componentsInChildren3; foreach (MeshRenderer val12 in array3) { string name = ((Object)((Renderer)val12).material).name; string text = name; if (!(text == "Leaves_0_LOD0 (Instance)")) { if (text == "matBHDistantTree (Instance)") { ((Renderer)val12).material = material2; } } else { ((Renderer)val12).material = material2; } } Transform child3 = val8.transform.GetChild(4); componentsInChildren3 = ((Component)child3).GetComponentsInChildren(); MeshRenderer[] array4 = componentsInChildren3; foreach (MeshRenderer val13 in array4) { string name2 = ((Object)((Renderer)val13).material).name; string text2 = name2; if (!(text2 == "Leaves_0_LOD0 (Instance)")) { if (text2 == "Leaves_0_LOD1 (Instance)") { ((Renderer)val13).material = val4; } } else { ((Renderer)val13).material = val3; } } GameObject val14 = GameObject.Find("/HOLDER: ToggleGroups/HOLDER: TG BackA/TGBackB/LTFallenLeaf"); GameObject val15 = GameObject.Find("/HOLDER: ToggleGroups/HOLDER: TG FrontA"); GameObject val16 = GameObject.Find("/HOLDER: ToggleGroups/HOLDER: TG FrontC/LTFallenLeaf (9)"); if (Object.op_Implicit((Object)(object)val14)) { ((Renderer)((Component)val14.transform.GetChild(0)).GetComponent()).material = val3; ((Renderer)((Component)val14.transform.GetChild(1)).GetComponent()).material = val4; } if (Object.op_Implicit((Object)(object)val15)) { ((Renderer)((Component)val15.transform.GetChild(0).GetChild(0)).GetComponent()).material = val3; ((Renderer)((Component)val15.transform.GetChild(0).GetChild(1)).GetComponent()).material = val4; ((Renderer)((Component)val15.transform.GetChild(1).GetChild(0)).GetComponent()).material = val3; ((Renderer)((Component)val15.transform.GetChild(1).GetChild(1)).GetComponent()).material = val4; } if (Object.op_Implicit((Object)(object)val16)) { ((Renderer)((Component)val16.transform.GetChild(0)).GetComponent()).material = val3; ((Renderer)((Component)val16.transform.GetChild(1)).GetComponent()).material = val4; } } public static void PrimeMeridian() { //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_001a: Unknown result type (might be due to invalid IL or missing references) //IL_001f: Unknown result type (might be due to invalid IL or missing references) //IL_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_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_005b: Unknown result type (might be due to invalid IL or missing references) //IL_0060: Unknown result type (might be due to invalid IL or missing references) Material material = Addressables.LoadAssetAsync((object)"11b42e952d609ef43a3f771e8cace014").WaitForCompletion(); Material material2 = Addressables.LoadAssetAsync((object)"f5ed1a209186f114985eba4c17e7b537").WaitForCompletion(); Material material3 = Addressables.LoadAssetAsync((object)"7a1c7e89aba14dd4bb118fee877fd603").WaitForCompletion(); Material material4 = Object.Instantiate(Addressables.LoadAssetAsync((object)"75319e5dc7ca5ee47ae5608402e9e977").WaitForCompletion()); Material material5 = Addressables.LoadAssetAsync((object)"947053d63d00a6b40adf4f1bd4274995").WaitForCompletion(); GameObject val = GameObject.Find("/HOLDER: Art/Terrain"); Transform child = val.transform.GetChild(5); BillboardRenderer[] componentsInChildren = ((Component)child).GetComponentsInChildren(); BillboardRenderer[] array = componentsInChildren; foreach (BillboardRenderer val2 in array) { val2.billboard.material = material4; } MeshRenderer[] componentsInChildren2 = ((Component)child).GetComponentsInChildren(); MeshRenderer[] array2 = componentsInChildren2; foreach (MeshRenderer val3 in array2) { string name = ((Object)((Renderer)val3).material).name; string text = name; if (text == "matBHDistantTree (Instance)") { ((Renderer)val3).material = material5; } } Transform child2 = val.transform.GetChild(6); componentsInChildren2 = ((Component)child2).GetComponentsInChildren(); MeshRenderer[] array3 = componentsInChildren2; foreach (MeshRenderer val4 in array3) { switch (((Object)((Renderer)val4).material).name) { case "matBHPlatformSimple (Instance)": ((Renderer)val4).material = material; break; case "matBHFallTerrainVines (Instance)": ((Renderer)val4).material = material2; break; case "matBHDomeTrim (Instance)": ((Renderer)val4).material = material3; break; } } } } public static class VisualsMisc { public class InstantiateGameObjectAtLocation : MonoBehaviour { public GameObject objectToInstantiate; public void Start() { Object.Instantiate(objectToInstantiate, ((Component)this).transform); } } [CompilerGenerated] private static class <>O { public static Manipulator <0>__BiggerSaleStarRange; } [Serializable] [CompilerGenerated] private sealed class <>c { public static readonly <>c <>9 = new <>c(); public static hook_OnEnter <>9__0_0; public static hook_FixedUpdate <>9__0_1; public static Func <>9__2_0; public static Func <>9__2_8; public static Func <>9__2_1; public static Func <>9__2_2; public static Func <>9__2_3; public static Func <>9__2_4; public static Func <>9__2_5; public static Func <>9__2_6; public static Func <>9__2_7; internal void b__0_0(orig_OnEnter orig, ReadyMegaBlaster self) { orig.Invoke(self); ((EntityState)self).characterBody.AddSpreadBloom(0.4f); } internal void b__0_1(orig_FixedUpdate orig, ReadyMegaBlaster self) { orig.Invoke(self); ((EntityState)self).characterBody.SetSpreadBloom(0.2f, true); } internal bool b__2_0(Instruction x) { return ILPatternMatchingExt.MatchLdsfld(x, "RoR2.DLC2Content/Items", "LowerPricedChests"); } internal bool b__2_8(Instruction x) { return ILPatternMatchingExt.MatchLdfld(x, "RoR2.InteractionDriver", "currentInteractable"); } internal GameObject b__2_1(GameObject target, InteractionDriver interactionDriver) { //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_006f: Unknown result type (might be due to invalid IL or missing references) //IL_0074: Unknown result type (might be due to invalid IL or missing references) //IL_01ce: Unknown result type (might be due to invalid IL or missing references) //IL_01d5: Expected O, but got Unknown //IL_01e9: 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_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) //IL_0215: Unknown result type (might be due to invalid IL or missing references) //IL_021a: Unknown result type (might be due to invalid IL or missing references) //IL_00c2: Unknown result type (might be due to invalid IL or missing references) //IL_00c4: Unknown result type (might be due to invalid IL or missing references) //IL_00cb: Unknown result type (might be due to invalid IL or missing references) //IL_00d5: Unknown result type (might be due to invalid IL or missing references) //IL_00da: Unknown result type (might be due to invalid IL or missing references) //IL_00e2: 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_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) //IL_0089: Unknown result type (might be due to invalid IL or missing references) //IL_008e: Unknown result type (might be due to invalid IL or missing references) //IL_0093: Unknown result type (might be due to invalid IL or missing references) //IL_009b: Unknown result type (might be due to invalid IL or missing references) //IL_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_00ab: 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_00b1: 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_014b: Unknown result type (might be due to invalid IL or missing references) //IL_0150: Unknown result type (might be due to invalid IL or missing references) if (interactionDriver.networkIdentity.hasAuthority) { if (interactionDriver.characterBody.inventory.GetItemCount(Items.LowerPricedChests) > 0) { if ((Object)(object)target == (Object)null) { float num = 0f; float num2 = interactionDriver.interactor.maxInteractionDistance * 2f; Vector3 val = interactionDriver.inputBank.aimOrigin; Vector3 val2 = interactionDriver.inputBank.aimDirection; if (interactionDriver.useAimOffset) { Vector3 val3 = val + val2 * num2; val = interactionDriver.inputBank.aimOrigin + interactionDriver.aimOffset; val2 = (val3 - val) / num2; } Ray val4 = default(Ray); ((Ray)(ref val4))..ctor(val, val2); Ray val5 = CameraRigController.ModifyAimRayIfApplicable(val4, ((Component)interactionDriver).gameObject, ref num); target = interactionDriver.interactor.FindBestInteractableObject(val5, num2 + num, ((Ray)(ref val4)).origin, num2); } if (Object.op_Implicit((Object)(object)target)) { PurchaseInteraction component = target.GetComponent(); if ((Object)(object)component != (Object)null && component.saleStarCompatible && !Object.op_Implicit((Object)(object)interactionDriver.saleStarEffect)) { interactionDriver.saleStarEffect = Object.Instantiate(LegacyResourcesAPI.Load("Prefabs/Effects/LowerPricedChestsGlow"), target.transform.position, Quaternion.identity, target.transform); return null; } } else if (Object.op_Implicit((Object)(object)interactionDriver.saleStarEffect)) { Object.Destroy((Object)(object)interactionDriver.saleStarEffect); return null; } } else if (Object.op_Implicit((Object)(object)interactionDriver.saleStarEffect)) { if (!Object.op_Implicit((Object)(object)interactionDriver.saleStarEffect.GetComponent())) { AnimationCurve val6 = new AnimationCurve(); val6.keys = (Keyframe[])(object)new Keyframe[3] { new Keyframe(0f, 1f), new Keyframe(0.25f, 1.05f), new Keyframe(1f, 0f) }; val6.postWrapMode = (WrapMode)1; val6.preWrapMode = (WrapMode)1; AnimationCurve overallCurve = val6; interactionDriver.saleStarEffect.AddComponent(); ObjectScaleCurve val7 = ((Component)interactionDriver.saleStarEffect.transform.GetChild(2)).gameObject.AddComponent(); val7.overallCurve = overallCurve; val7.useOverallCurveOnly = true; val7.timeMax = 1.1f; val7 = ((Component)interactionDriver.saleStarEffect.transform.GetChild(3)).gameObject.AddComponent(); val7.overallCurve = overallCurve; val7.useOverallCurveOnly = true; val7.timeMax = 1.1f; val7 = ((Component)interactionDriver.saleStarEffect.transform.GetChild(0)).gameObject.AddComponent(); val7.overallCurve = overallCurve; val7.useOverallCurveOnly = true; val7.timeMax = 1.1f; Object.Destroy((Object)(object)interactionDriver.saleStarEffect, 1.6f); } return null; } } return null; } internal bool b__2_2(Instruction x) { return ILPatternMatchingExt.MatchLdfld(x, "RoR2.InteractionDriver", "saleStarEffect"); } internal bool b__2_3(Instruction x) { return ILPatternMatchingExt.MatchCall(x, "UnityEngine.Object", "Destroy"); } internal bool b__2_4(Instruction x) { return ILPatternMatchingExt.MatchLdfld(x, "RoR2.InteractionDriver", "saleStarEffect"); } internal bool b__2_5(Instruction x) { return ILPatternMatchingExt.MatchCall(x, "UnityEngine.Object", "Destroy"); } internal bool b__2_6(Instruction x) { return ILPatternMatchingExt.MatchLdfld(x, "RoR2.InteractionDriver", "saleStarEffect"); } internal GameObject b__2_7(GameObject target) { return null; } } public static void Start() { //IL_0043: Unknown result type (might be due to invalid IL or missing references) //IL_0048: Unknown result type (might be due to invalid IL or missing references) //IL_009a: 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_00e6: 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_0132: Unknown result type (might be due to invalid IL or missing references) //IL_013f: Unknown result type (might be due to invalid IL or missing references) //IL_0166: Unknown result type (might be due to invalid IL or missing references) //IL_0168: Unknown result type (might be due to invalid IL or missing references) //IL_0171: 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_01d6: Unknown result type (might be due to invalid IL or missing references) //IL_01db: Unknown result type (might be due to invalid IL or missing references) //IL_0246: Unknown result type (might be due to invalid IL or missing references) //IL_0281: Unknown result type (might be due to invalid IL or missing references) //IL_0291: Unknown result type (might be due to invalid IL or missing references) //IL_0296: Unknown result type (might be due to invalid IL or missing references) //IL_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_02e4: Expected O, but got Unknown //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_0037: Expected O, but got Unknown //IL_0314: Unknown result type (might be due to invalid IL or missing references) //IL_0319: Unknown result type (might be due to invalid IL or missing references) //IL_0329: Unknown result type (might be due to invalid IL or missing references) //IL_032e: Unknown result type (might be due to invalid IL or missing references) //IL_0347: Unknown result type (might be due to invalid IL or missing references) //IL_034c: Unknown result type (might be due to invalid IL or missing references) //IL_035e: Unknown result type (might be due to invalid IL or missing references) //IL_0368: 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_03e0: Unknown result type (might be due to invalid IL or missing references) //IL_03e5: Unknown result type (might be due to invalid IL or missing references) //IL_041c: Unknown result type (might be due to invalid IL or missing references) //IL_0421: Unknown result type (might be due to invalid IL or missing references) //IL_0451: Unknown result type (might be due to invalid IL or missing references) //IL_046e: Unknown result type (might be due to invalid IL or missing references) //IL_02fe: Unknown result type (might be due to invalid IL or missing references) //IL_0303: Unknown result type (might be due to invalid IL or missing references) //IL_0309: Expected O, but got Unknown if (!Chainloader.PluginInfos.ContainsKey("0p41.Sots_Items_Reworked")) { object obj = <>O.<0>__BiggerSaleStarRange; if (obj == null) { Manipulator val = BiggerSaleStarRange; <>O.<0>__BiggerSaleStarRange = val; obj = (object)val; } InteractionDriver.MyFixedUpdate += (Manipulator)obj; } Material val2 = Addressables.LoadAssetAsync((object)"RoR2/DLC2/Child/matChild.mat").WaitForCompletion(); val2.SetFloat("_EliteBrightnessMax", 1.09f); val2.SetFloat("_EliteBrightnessMin", -0.7f); GameObject val3 = LegacyResourcesAPI.Load("Prefabs/Effects/LowerPricedChestsGlow"); val3.transform.GetChild(0).localPosition = new Vector3(0f, 0.6f, 0f); val3.transform.GetChild(1).localPosition = new Vector3(0f, 0.6f, 0f); val3.transform.GetChild(2).localPosition = new Vector3(0f, 0.4f, 0f); val3.transform.GetChild(3).localPosition = new Vector3(0f, 0.7f, 0f); val3.transform.GetChild(3).localScale = new Vector3(1f, 1.4f, 1f); ItemDefInfo val4 = default(ItemDefInfo); val4.itemDef = LegacyResourcesAPI.Load("ItemDefs/LunarTrinket"); val4.count = 1; val4.dontExceedCount = true; ItemDefInfo val5 = val4; ItemDefInfo[] itemDefInfos = (ItemDefInfo[])(object)new ItemDefInfo[1] { val5 }; LegacyResourcesAPI.Load("Prefabs/charactermasters/ScavLunar1Master").AddComponent().itemDefInfos = itemDefInfos; LegacyResourcesAPI.Load("Prefabs/charactermasters/ScavLunar2Master").AddComponent().itemDefInfos = itemDefInfos; LegacyResourcesAPI.Load("Prefabs/charactermasters/ScavLunar3Master").AddComponent().itemDefInfos = itemDefInfos; LegacyResourcesAPI.Load("Prefabs/charactermasters/ScavLunar4Master").AddComponent().itemDefInfos = itemDefInfos; GameObject val6 = PrefabAPI.InstantiateClone(((Component)Addressables.LoadAssetAsync((object)"RoR2/Base/Captain/CaptainSupplyDrop, Hacking.prefab").WaitForCompletion().transform.GetChild(2).GetChild(0).GetChild(4)).gameObject, "ShockIndicator", false); Material val7 = Object.Instantiate(((Renderer)((Component)val6.transform.GetChild(0)).GetComponent()).material); val7.SetColor("_TintColor", new Color(0f, 0.4f, 0.8f, 1f)); ((Renderer)((Component)val6.transform.GetChild(0)).GetComponent()).material = val7; val6.transform.localScale = new Vector3(6.67f, 6.67f, 6.67f); GameObject val8 = Addressables.LoadAssetAsync((object)"RoR2/Base/Captain/CaptainSupplyDrop, Shocking.prefab").WaitForCompletion(); ((Component)val8.transform.GetChild(2).GetChild(0)).gameObject.AddComponent().objectToInstantiate = val6; object obj2 = <>c.<>9__0_0; if (obj2 == null) { hook_OnEnter val9 = delegate(orig_OnEnter orig, ReadyMegaBlaster self) { orig.Invoke(self); ((EntityState)self).characterBody.AddSpreadBloom(0.4f); }; <>c.<>9__0_0 = val9; obj2 = (object)val9; } ReadyMegaBlaster.OnEnter += (hook_OnEnter)obj2; object obj3 = <>c.<>9__0_1; if (obj3 == null) { hook_FixedUpdate val10 = delegate(orig_FixedUpdate orig, ReadyMegaBlaster self) { orig.Invoke(self); ((EntityState)self).characterBody.SetSpreadBloom(0.2f, true); }; <>c.<>9__0_1 = val10; obj3 = (object)val10; } ReadyMegaBlaster.FixedUpdate += (hook_FixedUpdate)obj3; SceneDef val11 = Addressables.LoadAssetAsync((object)"RoR2/Base/rootjungle/rootjungle.asset").WaitForCompletion(); MusicTrackDef bossTrack = Addressables.LoadAssetAsync((object)"RoR2/DLC1/Common/muBossfightDLC1_12.asset").WaitForCompletion(); val11.bossTrack = bossTrack; GameObject val12 = Addressables.LoadAssetAsync((object)"RoR2/DLC2/MiniGeodeBody.prefab").WaitForCompletion(); val12.transform.localScale = Vector3.one * 1.5f; Light component = ((Component)val12.transform.GetChild(0).GetChild(2)).GetComponent(); component.range = 25f; component.intensity = 8f; GameObject val13 = Addressables.LoadAssetAsync((object)"RoR2/Base/KillEliteFrenzy/NoCooldownEffect.prefab").WaitForCompletion(); val13.GetComponentInChildren().priority = 2f; PostProcessProfile sharedProfile = val13.GetComponentInChildren().sharedProfile; PostProcessProfile val14 = Addressables.LoadAssetAsync((object)"affc373eac3cb4c43b38adc2c7a61451").WaitForCompletion(); PostProcessEffectSettings obj4 = val14.settings[1]; ((ParameterOverride)(object)((ColorGrading)((obj4 is ColorGrading) ? obj4 : null)).postExposure).value = 0.2f; DifficultyColors(); GameObject val15 = Addressables.LoadAssetAsync((object)"c6f87be1350f96b4c8545a4ae7f22207").WaitForCompletion(); val15.GetComponent().DoNotPool = true; PlaySoundOnEvent val16 = val15.AddComponent(); val16.soundEvent = "Play_item_proc_extraShrineItem"; val16.triggeringEvent = (PlaySoundEvent)2; val16 = val15.AddComponent(); val16.soundEvent = "Play_item_proc_extraShrineItem"; val16.triggeringEvent = (PlaySoundEvent)2; } private static void DifficultyColors() { //IL_0023: 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_0030: Unknown result type (might be due to invalid IL or missing references) //IL_0031: Unknown result type (might be due to invalid IL or missing references) //IL_003d: Unknown result type (might be due to invalid IL or missing references) //IL_003e: Unknown result type (might be due to invalid IL or missing references) //IL_004a: Unknown result type (might be due to invalid IL or missing references) //IL_004b: 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_0058: 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_0065: 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_0073: 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_0081: Unknown result type (might be due to invalid IL or missing references) Color color = default(Color); ((Color)(ref color))..ctor(0.2f, 0.22f, 0.4f, 1f); DifficultyCatalog.difficultyDefs[3].color = color; DifficultyCatalog.difficultyDefs[4].color = color; DifficultyCatalog.difficultyDefs[5].color = color; DifficultyCatalog.difficultyDefs[6].color = color; DifficultyCatalog.difficultyDefs[7].color = color; DifficultyCatalog.difficultyDefs[8].color = color; DifficultyCatalog.difficultyDefs[9].color = color; DifficultyCatalog.difficultyDefs[10].color = color; DifficultyCatalog.difficultyDefs[3].serverTag = "e1"; DifficultyCatalog.difficultyDefs[4].serverTag = "e2"; DifficultyCatalog.difficultyDefs[5].serverTag = "e3"; DifficultyCatalog.difficultyDefs[6].serverTag = "e4"; DifficultyCatalog.difficultyDefs[7].serverTag = "e5"; DifficultyCatalog.difficultyDefs[8].serverTag = "e6"; DifficultyCatalog.difficultyDefs[9].serverTag = "e7"; DifficultyCatalog.difficultyDefs[10].serverTag = "e8"; } private static void BiggerSaleStarRange(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown //IL_0076: Unknown result type (might be due to invalid IL or missing references) ILCursor val = new ILCursor(il); if (val.TryGotoNext((MoveType)2, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchLdsfld(x, "RoR2.DLC2Content/Items", "LowerPricedChests") }) && val.TryGotoPrev((MoveType)2, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchLdfld(x, "RoR2.InteractionDriver", "currentInteractable") })) { val.Emit(OpCodes.Ldarg_0); val.EmitDelegate>((Func)delegate(GameObject target, InteractionDriver interactionDriver) { //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_006f: Unknown result type (might be due to invalid IL or missing references) //IL_0074: Unknown result type (might be due to invalid IL or missing references) //IL_01ce: Unknown result type (might be due to invalid IL or missing references) //IL_01d5: Expected O, but got Unknown //IL_01e9: 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_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) //IL_0215: Unknown result type (might be due to invalid IL or missing references) //IL_021a: Unknown result type (might be due to invalid IL or missing references) //IL_00c2: Unknown result type (might be due to invalid IL or missing references) //IL_00c4: Unknown result type (might be due to invalid IL or missing references) //IL_00cb: Unknown result type (might be due to invalid IL or missing references) //IL_00d5: Unknown result type (might be due to invalid IL or missing references) //IL_00da: Unknown result type (might be due to invalid IL or missing references) //IL_00e2: 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_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) //IL_0089: Unknown result type (might be due to invalid IL or missing references) //IL_008e: Unknown result type (might be due to invalid IL or missing references) //IL_0093: Unknown result type (might be due to invalid IL or missing references) //IL_009b: Unknown result type (might be due to invalid IL or missing references) //IL_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_00ab: 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_00b1: 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_014b: Unknown result type (might be due to invalid IL or missing references) //IL_0150: Unknown result type (might be due to invalid IL or missing references) if (interactionDriver.networkIdentity.hasAuthority) { if (interactionDriver.characterBody.inventory.GetItemCount(Items.LowerPricedChests) > 0) { if ((Object)(object)target == (Object)null) { float num = 0f; float num2 = interactionDriver.interactor.maxInteractionDistance * 2f; Vector3 val2 = interactionDriver.inputBank.aimOrigin; Vector3 val3 = interactionDriver.inputBank.aimDirection; if (interactionDriver.useAimOffset) { Vector3 val4 = val2 + val3 * num2; val2 = interactionDriver.inputBank.aimOrigin + interactionDriver.aimOffset; val3 = (val4 - val2) / num2; } Ray val5 = default(Ray); ((Ray)(ref val5))..ctor(val2, val3); Ray val6 = CameraRigController.ModifyAimRayIfApplicable(val5, ((Component)interactionDriver).gameObject, ref num); target = interactionDriver.interactor.FindBestInteractableObject(val6, num2 + num, ((Ray)(ref val5)).origin, num2); } if (Object.op_Implicit((Object)(object)target)) { PurchaseInteraction component = target.GetComponent(); if ((Object)(object)component != (Object)null && component.saleStarCompatible && !Object.op_Implicit((Object)(object)interactionDriver.saleStarEffect)) { interactionDriver.saleStarEffect = Object.Instantiate(LegacyResourcesAPI.Load("Prefabs/Effects/LowerPricedChestsGlow"), target.transform.position, Quaternion.identity, target.transform); return null; } } else if (Object.op_Implicit((Object)(object)interactionDriver.saleStarEffect)) { Object.Destroy((Object)(object)interactionDriver.saleStarEffect); return null; } } else if (Object.op_Implicit((Object)(object)interactionDriver.saleStarEffect)) { if (!Object.op_Implicit((Object)(object)interactionDriver.saleStarEffect.GetComponent())) { AnimationCurve val7 = new AnimationCurve(); val7.keys = (Keyframe[])(object)new Keyframe[3] { new Keyframe(0f, 1f), new Keyframe(0.25f, 1.05f), new Keyframe(1f, 0f) }; val7.postWrapMode = (WrapMode)1; val7.preWrapMode = (WrapMode)1; AnimationCurve overallCurve = val7; interactionDriver.saleStarEffect.AddComponent(); ObjectScaleCurve val8 = ((Component)interactionDriver.saleStarEffect.transform.GetChild(2)).gameObject.AddComponent(); val8.overallCurve = overallCurve; val8.useOverallCurveOnly = true; val8.timeMax = 1.1f; val8 = ((Component)interactionDriver.saleStarEffect.transform.GetChild(3)).gameObject.AddComponent(); val8.overallCurve = overallCurve; val8.useOverallCurveOnly = true; val8.timeMax = 1.1f; val8 = ((Component)interactionDriver.saleStarEffect.transform.GetChild(0)).gameObject.AddComponent(); val8.overallCurve = overallCurve; val8.useOverallCurveOnly = true; val8.timeMax = 1.1f; Object.Destroy((Object)(object)interactionDriver.saleStarEffect, 1.6f); } return null; } } return null; }); val.TryGotoNext((MoveType)0, new Func[2] { (Instruction x) => ILPatternMatchingExt.MatchLdfld(x, "RoR2.InteractionDriver", "saleStarEffect"), (Instruction x) => ILPatternMatchingExt.MatchCall(x, "UnityEngine.Object", "Destroy") }); val.TryGotoNext((MoveType)0, new Func[2] { (Instruction x) => ILPatternMatchingExt.MatchLdfld(x, "RoR2.InteractionDriver", "saleStarEffect"), (Instruction x) => ILPatternMatchingExt.MatchCall(x, "UnityEngine.Object", "Destroy") }); val.TryGotoPrev((MoveType)2, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchLdfld(x, "RoR2.InteractionDriver", "saleStarEffect") }); val.EmitDelegate>((Func)((GameObject target) => null)); } else { Log.LogWarning("IL Failed: Sale Star Range"); } } } public static class VisualsMain { [CompilerGenerated] private static class <>O { public static Action <0>__ModSupport; public static hook_PreStartClient <1>__VisualStageChanges; public static Action <2>__CallLate; public static Action <3>__MissingSceneColors; } public static void Start() { //IL_00ca: Unknown result type (might be due to invalid IL or missing references) //IL_00cf: Unknown result type (might be due to invalid IL or missing references) //IL_00d5: Expected O, but got Unknown if (WConfig.module_visuals_icons.Value) { BodyIcons.Start(); if (WConfig.cfgPingIcons.Value) { PingIcons.AddIcons(); PingIcons.AddHooks(); ((ResourceAvailability)(ref GameModeCatalog.availability)).CallWhenAvailable((Action)PingIcons.ModSupport); } PingIcons.MiscIcons(); BuffIcons.Awake(); Icon_Colors.Start(); MissionPointers.Start(); } if (WConfig.module_visuals_skins.Value) { SkinChanges.Start(); SkinTouchups.Start(); } if (WConfig.module_visuals_other.Value) { ColorModule.Main(); DuplicatorModel.DuplicatorModelChanger(); OptionPickup_Visuals.Start(); VisualsMisc.Start(); HoldoutZoneFlowers.FlowersForOtherHoldoutZones(); object obj = <>O.<1>__VisualStageChanges; if (obj == null) { hook_PreStartClient val = VisualStageChanges; <>O.<1>__VisualStageChanges = val; obj = (object)val; } Stage.PreStartClient += (hook_PreStartClient)obj; ((ResourceAvailability)(ref GameModeCatalog.availability)).CallWhenAvailable((Action)CallLate); } if (WConfig.module_audio.Value) { ChefOil.Start(); AudioStuff.Start(); } ((ResourceAvailability)(ref SceneCatalog.availability)).CallWhenAvailable((Action)ColorModule.MissingSceneColors); } public static void VisualStageChanges(orig_PreStartClient orig, Stage self) { //IL_02f8: Unknown result type (might be due to invalid IL or missing references) //IL_0650: Unknown result type (might be due to invalid IL or missing references) //IL_08e1: Unknown result type (might be due to invalid IL or missing references) //IL_03a4: Unknown result type (might be due to invalid IL or missing references) //IL_03ab: Expected O, but got Unknown //IL_03c1: Unknown result type (might be due to invalid IL or missing references) //IL_075c: Unknown result type (might be due to invalid IL or missing references) //IL_0763: Expected O, but got Unknown //IL_0779: Unknown result type (might be due to invalid IL or missing references) //IL_079f: Unknown result type (might be due to invalid IL or missing references) //IL_047c: Unknown result type (might be due to invalid IL or missing references) //IL_049d: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self); if (!Object.op_Implicit((Object)(object)SceneInfo.instance)) { return; } switch (SceneInfo.instance.sceneDef.baseSceneName) { case "foggyswamp": { GameObjectUnlockableFilter[] array = Object.FindObjectsOfType(typeof(GameObjectUnlockableFilter)) as GameObjectUnlockableFilter[]; for (int j = 0; j < array.Length; j++) { Log.LogMessage(array[j]); Object.Destroy((Object)(object)array[j]); } break; } case "wispgraveyard": if (WConfig.cfgSofterShadows.Value) { GameObject val13 = GameObject.Find("/Weather, Wispgraveyard/Directional Light (SUN)"); Light component2 = val13.GetComponent(); if (component2.intensity == 1.3f && component2.shadowStrength == 1f) { component2.shadowStrength = 0.8f; } } break; case "sulfurpools": if (WConfig.cfgNewGeysers.Value) { GameObject val = GameObject.Find("/HOLDER: Geysers"); Material val2 = Object.Instantiate(((Renderer)((Component)val.transform.GetChild(0).GetChild(2).GetChild(0) .GetChild(1)).GetComponent()).material); val2.SetColor("_EmissionColor", new Color(0.15f, 0.2f, 0.08f)); for (int i = 0; i < val.transform.childCount; i++) { Transform child = val.transform.GetChild(i).GetChild(2).GetChild(0); ((Renderer)((Component)child.GetChild(1)).GetComponent()).material = val2; ((Renderer)((Component)child.GetChild(2)).GetComponent()).material = val2; ((Renderer)((Component)child.GetChild(3)).GetComponent()).material = val2; } } break; case "dampcavesimple": { GameObject val15 = GameObject.Find("/TreebotUnlockInteractable"); if (Object.op_Implicit((Object)(object)val15)) { GameObject val16 = new GameObject("BrokenRexHoloPivot"); val16.transform.localPosition = new Vector3(0.8f, 4f, -0.2f); val16.transform.SetParent(val15.gameObject.transform, false); val15.gameObject.AddComponent().hologramPivot = val16.transform; val15.AddComponent().pingIconOverride = PingIcons.QuestionMarkIcon; } if (WConfig.cfgNewGeysers.Value) { GameObject val17 = GameObject.Find("/HOLDER: Geyser"); Material val18 = Object.Instantiate(((Renderer)((Component)val17.transform.GetChild(0).GetChild(2).GetChild(0) .GetChild(1)).GetComponent()).material); Material val19 = Object.Instantiate(val18); val18.SetColor("_EmissionColor", new Color(2f, 0.5f, 0f)); val19.SetColor("_EmissionColor", new Color(1.8f, 0.4f, 0f)); for (int l = 0; l < val17.transform.childCount; l++) { Transform child2 = val17.transform.GetChild(l).GetChild(2).GetChild(0); ((Renderer)((Component)child2.GetChild(1)).GetComponent()).material = val18; ((Renderer)((Component)child2.GetChild(2)).GetComponent()).material = val19; ((Renderer)((Component)child2.GetChild(3)).GetComponent()).material = val19; } } if (WConfig.cfgSofterShadows.Value) { GameObject val20 = GameObject.Find("/HOLDER: Lighting, PP, Wind, Misc/Directional Light (SUN)"); Light component4 = val20.GetComponent(); if (component4.intensity == 0.5f && component4.shadowStrength == 1f) { component4.shadowStrength = 0.8f; } } break; } case "rootjungle": { if (WConfig.cfgSofterShadows.Value) { GameObject val14 = GameObject.Find("/HOLDER: Weather Set 1/Directional Light (SUN)"); Light component3 = val14.GetComponent(); if (component3.intensity == 0.7f && component3.shadowStrength == 1f) { component3.shadowStrength = 0.6f; } } LODGroup[] componentsInChildren = GameObject.Find("HOLDER: Randomization/GROUP: Large Treasure Chests").GetComponentsInChildren(); for (int k = 0; k < componentsInChildren.Length; k++) { if (((Object)componentsInChildren[k]).name.StartsWith("RJpinkshroom")) { Object.Destroy((Object)(object)componentsInChildren[k]); } } break; } case "skymeadow": { GameObject.Find("/HOLDER: Zones/OOB Zone").GetComponent().zoneType = (ZoneType)0; Material material = ((Renderer)GameObject.Find("/HOLDER: Randomization/GROUP: Plateau 13 and Underground/Underground/Geyser (2)/mdlGeyser").GetComponent()).material; Transform transform = GameObject.Find("/HOLDER: Randomization/GROUP: Plateau 13 and Underground/Underground/Geyser").transform; ((Renderer)((Component)transform.GetChild(0)).GetComponent()).material = material; ((Renderer)((Component)transform.GetChild(1)).GetComponent()).material = material; break; } case "helminthroost": if (WConfig.cfgHelminthLightingFix.Value) { GameObject val8 = GameObject.Find("/HOLDER: Lighting/Weather, Helminthroost/PP + Amb"); PostProcessVolume component = val8.GetComponent(); component.priority = 2.1f; } break; case "moon2": { GameObject val21 = GameObject.Find("/HOLDER: Elevators"); if (Object.op_Implicit((Object)(object)val21)) { GenericInteraction[] componentsInChildren2 = val21.GetComponentsInChildren(); GenericInteraction[] array2 = componentsInChildren2; foreach (GenericInteraction val22 in array2) { ((Component)val22).gameObject.AddComponent(); } } break; } case "bazaar": { GameObject val9 = GameObject.Find("/HOLDER: Store/LunarShop/LunarRecycler"); if (Object.op_Implicit((Object)(object)val9)) { GameObject val10 = new GameObject("LunarRecyclerPivot"); val10.transform.localPosition = new Vector3(0.1f, -1f, 1f); val10.transform.localRotation = new Quaternion(0f, -0.7071f, -0.7071f, 0f); val10.transform.SetParent(val9.gameObject.transform, false); val9.gameObject.AddComponent().hologramPivot = val10.transform; val9.gameObject.GetComponent().disableHologramRotation = true; } GameObject val11 = GameObject.Find("/HOLDER: Starting Cave/HOLDER: Arena Entrance/Trigger/PortalArena/"); ((Component)val11.transform.parent.GetChild(2)).gameObject.GetComponent().radius = 130f; if (WConfig.ArtificerBazaarAlways.Value) { GameObject val12 = GameObject.Find("/HOLDER: Store/HOLDER: Store Platforms/LockedMage/"); ((Behaviour)val12.GetComponent()).enabled = false; if (!val12.GetComponent().ShouldShowGameObject()) { val12.GetComponent().Networkavailable = false; } } break; } case "meridian": { if (VisibleHabitatFall.Should()) { VisibleHabitatFall.PrimeMeridian(); } GameObject val3 = GameObject.Find("/HOLDER: Design/MeridianEventTriggerCore/"); val3.GetComponent().isPingable = false; GameObject val4 = GameObject.Find("/HOLDER: Art/Colossus Statue/PMHead/"); SphereCollider val5 = val4.AddComponent(); ((Collider)val5).isTrigger = true; val5.radius = 250f; val5.center = new Vector3(0f, 100f, 0f); ModelLocator val6 = val4.AddComponent(); val6.dontDetatchFromParent = true; val6.autoUpdateModelTransform = false; val6._modelTransform = val4.transform; CharacterModel val7 = val4.AddComponent(); break; } case "lemuriantemple": if (VisibleHabitatFall.Should()) { VisibleHabitatFall.LemurianTemple(); } break; } } public static void CallLate() { //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) OtherEnemies.CallLate(); if (WConfig.cfgColorMain.Value) { ColorModule.ModSupport(); } if (WConfig.cfgColorMain.Value) { ColorModule.AddMissingItemHighlights(); ColorModule.ChangeColorsPost(); } Equipment.HealAndReviveConsumed.pickupModelPrefab.AddComponent(); Items.MinHealthPercentage.hidden = false; ItemTierDef val = ItemTierCatalog.FindTierDef("OrangeTierDef"); if ((Object)(object)val != (Object)null) { OptionPickup_Visuals.orange = val.tier; } } } public static class WConfig { public enum ReminderChoice { Off, IfSpawned, Always } public enum MessageWho { Off, Your, Anybody } public enum Position { Off, Top, Bottom } public enum ColorOrNot { Off, White, Colored } public enum MainMenuTheme { Default, Random, RandomStatic, Acres, Sirens, Realms, Artifact } public enum Player { Off, Multiplayer, Always } [CompilerGenerated] private static class <>O { public static EventHandler <0>__ObjectiveHudSpacing_SettingChanged; public static UnityAction <1>__LoadAll; } public static ConfigFile ConfigFile_Client = new ConfigFile(Paths.ConfigPath + "\\Wolfo.WolfoQoL_Client.cfg", true); public static ConfigEntry cfgDevotedInventory; public static ConfigEntry SH_Music_Restarter; public static ConfigEntry cfgChefMenuTweak; public static ConfigEntry RealTimeTimer; public static ConfigEntry DC_RealTimeTimerStat; public static ConfigEntry cfgHelminthLightingFix; public static ConfigEntry cfgSofterShadows; public static ConfigEntry DroneMessage_Repair; public static ConfigEntry DroneMessage_Combine; public static ConfigEntry DroneMessage_RemoteOp; public static ConfigEntry cfgTempItemCyanStack; public static ConfigEntry cfgRecipesInLog; public static ConfigEntry module_visuals_skins; public static ConfigEntry module_visuals_icons; public static ConfigEntry module_visuals_other; public static ConfigEntry module_audio; public static ConfigEntry module_menu_deathscreen; public static ConfigEntry module_menu_logbook; public static ConfigEntry module_menu_other; public static ConfigEntry module_text_reminders; public static ConfigEntry module_text_chat; public static ConfigEntry module_text_general; public static ConfigEntry DC_DroneInventory; public static ConfigEntry DC_CompactStats; public static ConfigEntry DC_MoreStats; public static ConfigEntry DC_Loadout; public static ConfigEntry DC_StageRecap; public static ConfigEntry DC_LatestWave; public static ConfigEntry DC_KillerInventory; public static ConfigEntry DC_KillerInventory_EvenIfJustElite; public static ConfigEntry LogbookSimuStages; public static ConfigEntry cfgSkipItemDisplays; public static ConfigEntry cfgDarkTwisted; public static ConfigEntry cfgTwistedFire; public static ConfigEntry cfgTwistedSound; public static ConfigEntry cfgMithrixPhase4SkipFix; public static ConfigEntry cfgSmoothCaptain; public static ConfigEntry cfgSkinAcridBlight; public static ConfigEntry cfgSkinMercRed; public static ConfigEntry cfgSkinMercGreen; public static ConfigEntry cfgSkinMercPink; public static ConfigEntry cfgSkinMercSS2; public static ConfigEntry cfgSkinMercDisableCompletely; public static ConfigEntry cfgSkinBellBalls; public static ConfigEntry cfgSkinMakeBlightedAcrid; public static ConfigEntry cfgSkinOperatorAltChirp; public static ConfigEntry cfgMessageDeath; public static ConfigEntry cfgMessagePrint; public static ConfigEntry cfgMessageScrap; public static ConfigEntry cfgMessageDroneScrap; public static ConfigEntry cfgMessageVictory; public static ConfigEntry cfgMessageVoidTransform; public static ConfigEntry cfgMessageElixirWatch; public static ConfigEntry cfgMessagesColoredItemPings; public static ConfigEntry cfgMessagesVoidQuantity; public static ConfigEntry cfgMessagesShrineRevive; public static ConfigEntry cfgMessagesRevive; public static ConfigEntry cfgMessagesSaleStar; public static ConfigEntry cfgMessagesRecycler; public static ConfigEntry cfgMessageDevotion; public static ConfigEntry cfgReminder_Halcyon; public static ConfigEntry cfgReminder_AccessNode; public static ConfigEntry cfgRemindersNOTINSIMU; public static ConfigEntry cfgRemindersKeys; public static ConfigEntry cfgRemindersFreechest; public static ConfigEntry cfgReminders_VV_FreechestVoid; public static ConfigEntry cfgReminders_Quality_Collectors; public static ConfigEntry cfgRemindersRegenScrap; public static ConfigEntry cfgRemindersSaleStar; public static ConfigEntry cfgRemindersNewt; public static ConfigEntry cfgRemindersPortal; public static ConfigEntry cfgRemindersSecretGeode; public static ConfigEntry cfgChargeHalcyShrine; public static ConfigEntry cfgTextOther; public static ConfigEntry cfgAltBodyNames; public static ConfigEntry cfgPrimordialBlueText; public static ConfigEntry cfgPrimordialBlueIcon; public static ConfigEntry cfgPrimordialBlueHighlight; public static ConfigEntry Logbook_More; public static ConfigEntry Logbook_WeirdoEnemies; public static ConfigEntry Logbook_EliteEquip; public static ConfigEntry Logbook_EliteEquipEarlyViewable; public static ConfigEntry Logbook_Recipes; public static ConfigEntry cfgLogbook_Subtitles; public static ConfigEntry cfgLogbook_Drones_EngiTurret; public static ConfigEntry Logbook_AllyExpansion; public static ConfigEntry Logbook_SortBosses; public static ConfigEntry cfgNewSprintCrosshair; public static ConfigEntry cfgEquipmentDroneName; public static ConfigEntry cfgMainMenuRandomizer; public static ConfigEntry cfgMainMenuScav; public static ConfigEntry cfgUISimuBorder; public static ConfigEntry cfgUIEclipseBorder; public static ConfigEntry cfgSkinMercRedSword; public static ConfigEntry cfgSkinMercGreenGlow; public static ConfigEntry cfgSkinEngiHarpoons; public static ConfigEntry cfgSkinMisc; public static ConfigEntry OldModelDuplcators; public static ConfigEntry cfgIconsBodyIcons; public static ConfigEntry cfgTpIconDiscoveredRed; public static ConfigEntry cfgVoidAllyCyanEyes; public static ConfigEntry cfgLoopPM_LemurianTemple; public static ConfigEntry cfgNewGeysers; public static ConfigEntry cfgPingIcons; public static ConfigEntry cfgLootIcons; public static ConfigEntry cfgVoidFieldsChargeIndicator; public static ConfigEntry cfgColorMain; public static ConfigEntry cfgColorVoids; public static ConfigEntry ArtifactOutline; public static ConfigEntry cfgBuff_RepeatColors; public static ConfigEntry cfgFragmentColor; public static ConfigEntry cfgFragmentSheen; public static ConfigEntry cfgLunarSeerName; public static ConfigEntry cfgMissionPointers; public static ConfigEntry cfgMissionPointersVoid; public static ConfigEntry cfgMissionPointersLunar; public static ConfigEntry cfgMissionPointersGold; public static ConfigEntry cfgTestClient; public static ConfigEntry cfgTestDisableHostInfo; public static ConfigEntry cfgTestDisableMod; public static ConfigEntry cfgVoidPotential_ItemsInPing; public static ConfigEntry cfgAurFragment_ItemsInPing; public static ConfigEntry cfgPlayerPing; public static ConfigEntry SulfurPoolsSkin; public static ConfigEntry ArtificerBazaarAlways; public static ConfigEntry ObjectiveHudSpacing; public const string RestartNotif = "\n\n(Requires a restart)"; public static void Start() { Log.LogMessage("WQoL InitConfig"); InitConfig(); TestConfig(); } public static void InitConfig() { module_text_chat = ConfigFile_Client.Bind("Modules", "Chat Messages", true, "Enable all new chat messages.\n\n(Requires a restart)"); module_text_reminders = ConfigFile_Client.Bind("Modules", "Reminders", true, "Enable all new objectives and reminders.\n\n(Requires a restart)"); module_text_general = ConfigFile_Client.Bind("Modules", "Text Additions", true, "Enable all misc text changes.\n(ie Lunar Seer, Equipment Drone Equipment, New interactable names)\n\n(Requires a restart)"); module_menu_deathscreen = ConfigFile_Client.Bind("Modules", "Death Screen", true, "Enable the remade Death Screen:\nMore Stats\nRun Recap\nKiller's Inventory\nDrone Collection\ntop right Win Message, bigger.\n\n(Requires a restart)"); module_menu_logbook = ConfigFile_Client.Bind("Modules", "Logbook", true, "Enable Logbook Additions:\n\nDrones -> Drones & Allies\nItems entries show crafting recipes\nMonster & Survivor entries show more stats and subtitle\n\n\n(Requires a restart)"); module_menu_other = ConfigFile_Client.Bind("Modules", "Menu & Hud Tweaks", true, "Enable menu & hud tweaks:\n\nMain Menu theme randomizer\nEclipse number in lobby\nSimu Completed border\nReal time timer\n\n(Requires a restart)"); module_visuals_skins = ConfigFile_Client.Bind("Modules", "Skin & Skill Visuals", true, "Enable all skin & skill visual upgrades:\nRed Oni Merc\nGreen Frail Merc\nPurple/Yellow Blight Acrid\n\n\n(Requires a restart)"); module_visuals_icons = ConfigFile_Client.Bind("Modules", "Icons", true, "Enable all updated icons:\n\nUnique Ping Icons\nUpdated Body Icons\n\n(Requires a restart)"); module_visuals_other = ConfigFile_Client.Bind("Modules", "Visuals", true, "Enable all other visual tweaks:\n\nLarger Uncommon Printers\nSulfur & Magma Geysers\nDifferent colors for Lunar/Elite equips\n\n(Requires a restart)"); module_audio = ConfigFile_Client.Bind("Modules", "Audio", true, "Parrying effect is more noticible\nSolutional Haunt Music track restarts after boss fight.\n\n(Requires a restart)"); cfgRemindersNOTINSIMU = ConfigFile_Client.Bind("Reminders", "Disable reminders in Simulacrum", true, "Disable all reminders in Simulacrum.\n\nSale Star and Regen Scrap will always be disabled."); cfgRemindersKeys = ConfigFile_Client.Bind("Reminders", "Rusted Keys", true, "Reminder to open your Rusted & Encrusted Key lockboxes on stages where they spawn."); cfgRemindersFreechest = ConfigFile_Client.Bind("Reminders", "Shipping Request", true, "Reminder to get your free item from Shipping Request Form."); cfgRemindersRegenScrap = ConfigFile_Client.Bind("Reminders", "Regen Scrap", ReminderChoice.IfSpawned, "Reminder to use your Regenerating Scrap if you have one. Can choose to only be reminded if a Green Printer has spawned."); cfgRemindersSaleStar = ConfigFile_Client.Bind("Reminders", "Sale Star", true, "Reminder, that you have Sale Star, so you hopefully do not waste it."); cfgRemindersPortal = ConfigFile_Client.Bind("Reminders", "Portals", true, "Reminder for open portals, in case you forget one is opened and just default to the teleporter.\n\nAlso to match the leave through teleporter message."); cfgRemindersSecretGeode = ConfigFile_Client.Bind("Reminders", "Meridian Geode Secret", true, "Cracking the 6 Aurelionite Geodes while climbing Prime Meridian gives an extra reward.\nThis is to remind you to do that."); cfgChargeHalcyShrine = ConfigFile_Client.Bind("Reminders", "Charging Halcyon Shrines", true, "Shows percent. To match other waiting sections in the game.\n\n(Requires a restart)"); cfgReminder_Halcyon = ConfigFile_Client.Bind("Reminders", "Find Halcyon Shrine", false, "Reminder to find the Halcyon Shrine, if one spawned."); cfgRemindersNewt = ConfigFile_Client.Bind("Reminders", "Newt Shrine", ReminderChoice.Off, "If you, really need to got the Bazaar.\nAuto clears if Teleporter spawns with a free blue orb."); cfgReminder_AccessNode = ConfigFile_Client.Bind("Reminders", "Access Node", false, "Reminder to hit that Access Node before the teleport on Stage 3s and Repurposed Crater"); cfgReminders_VV_FreechestVoid = ConfigFile_Client.Bind("Reminders", "(Vanilla Voids) Ceaseless Cornucopia", false, "Reminder to complete the Void Holdout Zone event that spawns from (VanillaVoids) Ceaseless Cornucopia (Void Shipping Request)"); cfgReminders_Quality_Collectors = ConfigFile_Client.Bind("Reminders", "(Quality) Collectors Compulsion", true, "Reminder for Quality Collectors Compulsion in QualityMod, to open the golden stat up barrel that spawns."); cfgMessageDeath = ConfigFile_Client.Bind("Chat Messages", "Detailed Death Messages", true, "Death Messages telling you who died to what and in what way."); cfgMessagePrint = ConfigFile_Client.Bind("Chat Messages", "Printing Message", true, "When someone Prints, Reforges or Cleanses a message will be sent"); cfgMessageScrap = ConfigFile_Client.Bind("Chat Messages", "Scrapping Message", true, "When someone Scraps, a message will be sent"); cfgMessageVictory = ConfigFile_Client.Bind("Chat Messages", "Victory Messages", true, "Victory and Vanish quote will be put into chat."); cfgMessageVoidTransform = ConfigFile_Client.Bind("Chat Messages", "Benthic & Ego Transform", true, "Chat message for when;\nEgocentrism eats an item\nBenthic Bloom upgrades an item.\n(VanillaVoids) Enhancement Vials corrupts an item."); cfgMessagesRevive = ConfigFile_Client.Bind("Chat Messages", "Revive Messages", true, "Message for when someone dies and revives using an item.\n\nWith more ways to revive, might be good to know when it's because of an item."); cfgMessagesSaleStar = ConfigFile_Client.Bind("Chat Messages", "Sale Star Message", true, "Message to show when and on what someone used their Sale Stars on."); cfgMessageElixirWatch = ConfigFile_Client.Bind("Chat Messages", "Elixir & Watch lost", MessageWho.Anybody, "Chat message for when;\nAn Elixir is used\nDelicate Watches are broken\nA random item is eaten by (VanillaVoids) Clockwork Mechanism"); cfgMessagesRecycler = ConfigFile_Client.Bind("Chat Messages", "Recycler Message", true, "When an item is Recycled by anyone, a message will be displayed saying what turned into what."); DroneMessage_Repair = ConfigFile_Client.Bind("Chat Messages", "Drone Repair Message", true, "Message for repairing drones and purchasing them from a Drone Triple Shop."); DroneMessage_Combine = ConfigFile_Client.Bind("Chat Messages", "Drone Combiner Message", true, "Message for combining/upgrading drones at the Drone CombinerStation."); DroneMessage_RemoteOp = ConfigFile_Client.Bind("Chat Messages", "Drone RemoteOp Message", true, "Message for starting a remote operation / respawning as a drone."); cfgMessageDevotion = ConfigFile_Client.Bind("Chat Messages", "Devotion Message", true, "Message for recruiting and losing Devoted Lemurians, and what item was used/lost."); cfgMessagesVoidQuantity = ConfigFile_Client.Bind("Chat Messages", "Void Quantity", true, "When picking up a item or void, it will add up the quantities of the normal and void together in the message.\n\nie if you pickup a Bear with Safer Spaces itll show Tougher Times(2) in a void color"); cfgMessagesShrineRevive = ConfigFile_Client.Bind("Chat Messages", "Shaping Activated", true, "Chat message for when Shrine of Shaping is activated and who it is reviving."); ObjectiveHudSpacing = ConfigFile_Client.Bind("Menu & Hud", "Objective spacing", -2f, "Shrink or increase the spacing between each objective in the hud.\n\nThis mod may add many objectives which can look rather overwhelming, shrinking the spacing is to make it more compact."); RealTimeTimer = ConfigFile_Client.Bind("Menu & Hud", "Real Time Timer", true, "Adds a secondary timer, underneath the Run Timer / Wave Counter when Scoreboard is open.\n\nThis uses the full time of the run including time spent in Hidden Realms"); cfgNewSprintCrosshair = ConfigFile_Client.Bind("Menu & Hud", "Sprinting Crosshair Changes", true, "Should this mod replace the Sprint crosshair with a different one that works with charging abilities."); cfgDevotedInventory = ConfigFile_Client.Bind("Menu & Hud", "Devoted Lemurian Inventory", MessageWho.Anybody, "Show the inventories of Devoted Lemurians per player."); cfgMainMenuRandomizer = ConfigFile_Client.Bind("Menu & Hud", "Main Menu Colors", MainMenuTheme.Random, "Main Menu theme config.\nDuring early access the main menu changed a couple times to reflect the update, this config this back.\n\nRandom: Switches between Default/Acres/Sirens only.\nRandomStatic: Randomizes once per session."); cfgMainMenuScav = ConfigFile_Client.Bind("Menu & Hud", "Main Menu Scav", true, "Should a Scav be readded to the options screen like in a old version of the game, and a Gup added to the alternative game modes screen."); cfgChefMenuTweak = ConfigFile_Client.Bind("Menu & Hud", "Bigger Crafting Menu", true, "Make the Chef crafting menu quite a bit wider and have more columns.\n\n(Requires a restart)"); cfgTempItemCyanStack = ConfigFile_Client.Bind("Menu & Hud", "Blue Stack Number for Temps", true, "Item stacks that have temporary items in it, have their stack number slightly blue.\n\nCan't show temp items seperately like in returns."); cfgUISimuBorder = ConfigFile_Client.Bind("Menu & Hud", "Simulacrum Completed Border", true, "In Simulacrum lobby & pre-screen\nCharacters you have beaten Wave 50 with will have a pink border around their icon."); cfgUIEclipseBorder = ConfigFile_Client.Bind("Menu & Hud", "Eclipse Number", true, "In Eclipse lobby & pre-screen\nShow what the next eclipse level to beat is, as number under each character, or a border if Eclipse 8 was beaten."); cfgMissionPointers = ConfigFile_Client.Bind("Icons", "Mission Pointers", true, "Void Fields : Indicator where the next Cell is.\n\nCommencement : Lunar Pillar locations shown briefly after charging one.\n\nGilded Coast : Location of last 3 Halcyon Beacon"); cfgBuff_RepeatColors = ConfigFile_Client.Bind("Icons", "Buff Recolors", true, "Recolors buffs that use the same sprite and color as other buffs to be distinguishable.\n\nRed Whip -> Orange\nSmall Armor -> Dark Yellow\nCelestial Cloaking -> Greener."); cfgTpIconDiscoveredRed = ConfigFile_Client.Bind("Icons", "Teleporter Icon Discovered Color Red", true, "When you have the discover teleporter icon setting on. Makes the icon light red at first and only white when charged.\n\n(Requires a restart)"); cfgPingIcons = ConfigFile_Client.Bind("Icons", "Enable new Ping Icons", true, "Enable new Ping Icons"); cfgLootIcons = ConfigFile_Client.Bind("Icons", "Loot dependent Icons", true, "Certain pickups will use a different icon such as Equipment, Temp Items, Coins, Elite Aspects, Quest Items."); cfgVoidFieldsChargeIndicator = ConfigFile_Client.Bind("Icons", "Cell Vent charge icon.", true, "Add a charge indicator to Void Fields holdout zones to match, every other holdout zone."); cfgIconsBodyIcons = ConfigFile_Client.Bind("Icons", "More unique Body Icons", true, "Add new or updated Body Icons\n Engi Walker Turrets, Empathy Cores and blue outline Squid Turret & Devoted Lemurians"); cfgHelminthLightingFix = ConfigFile_Client.Bind("Visuals", "Brighter Helminth Hatchery", true, "Change Helminths lighting to be considerably brighter and to what is seemingly intended.\n\nThis happens because the lighting is set to a too low priority and/or gets improperly loaded."); cfgSofterShadows = ConfigFile_Client.Bind("Visuals", "Brighter Shadows", true, "Lessens the darkness of shadows in Scorched Acres, Sundered Grove and Abyssal Depths, increasing general visibility."); cfgColorMain = ConfigFile_Client.Bind("Visuals", "Item & Equipment Outline Color Changes", true, "Change the colors of some pickup classes to not different.\n\nLunar Equipment: Light-Blue\nElite Equipment to Orange-Yellow\nConsumed Equipment: Gray-Orange\nLunar Coin: Lunar Coin Color\nMeal: Slightly different orange.\n\n\n(Requires a restart)"); cfgColorVoids = ConfigFile_Client.Bind("Visuals", "Void Outline Color Tiered", true, "Needs the main Outline Color Change config.\n\nEach void item tier will have a slightly different shade of pink\n\nVoid 1: Slightly lighter\nVoid 2: Vanilla\nVoid 3: More saturated\nVoid Boss: Darker\n\n(Requires a restart)"); cfgFragmentColor = ConfigFile_Client.Bind("Visuals", "Fragment Gold Outline", true, "Should Aurelionite Fragments have a gold outline like it's sprite."); cfgLoopPM_LemurianTemple = ConfigFile_Client.Bind("Visuals", "Loop Meridian & Reformed", true, "Changes the colors the visible 'Treeborn Colony' parts in Prime Meridian & Reformed Altar to match Golden Dieback during loops, as it is visible from both stages."); cfgNewGeysers = ConfigFile_Client.Bind("Visuals", "Change Geyser colors", true, "Abyssal Depths will have lava-like instead of water\nSulfur Pools will have greener Geysers"); OldModelDuplcators = ConfigFile_Client.Bind("Visuals", "Large and Mili Printer Old Model", true, "Change the model of Green and Red Printers to the bigger bulkier one used before 1.0.\n\nUncommon 3D printers are the only interactable that looks exactly the same as a different one.\n\n(Requires a restart)"); cfgLunarSeerName = ConfigFile_Client.Bind("Text", "Lunar Seer include Stage Name", true, "Include Stage Name in Ping and Interact info."); cfgEquipmentDroneName = ConfigFile_Client.Bind("Text", "Equipment Name Equipment Drone", ColorOrNot.White, "Show the equipment a Equipment Drone is holding in its name."); cfgVoidPotential_ItemsInPing = ConfigFile_Client.Bind("Text", "Void Potential contents in Ping", true, "When pinged, the items inside will be in the ping message. Requested for more easy sharing in Simulacrum"); cfgAurFragment_ItemsInPing = ConfigFile_Client.Bind("Text", "Aurelionite Fragment contents in Ping", true, "When pinged, the items inside will be in the ping message."); cfgPlayerPing = ConfigFile_Client.Bind("Text", "Player Ping", true, "When pinging a player or ally, it will be blue and friendly instead of attack:"); cfgMessagesColoredItemPings = ConfigFile_Client.Bind("Text", "Colored Item names in Pings", true, "When pinging an item or something containing an item, the items name will use it's color."); cfgAltBodyNames = ConfigFile_Client.Bind("Text", "Lunar Chimera / Larva name change", true, "Adds Lunar Chimera type to Chimera names\n\nRenames Larva to Acid Larva due to their internal name."); cfgTextOther = ConfigFile_Client.Bind("Text", "Rename repeated tokens", true, "Adds a different name token for some interactables or endings dont use a unique one.\n\nLarge 3D Printers\nLarge Multishops\nEquipment Multishops\nShipping Request Multishop\nMoment Whole ending\nVoid ending"); DC_Loadout = ConfigFile_Client.Bind("Death Screen", "Skill Loadout", true, "Players skill loadouts will be shown, for sharing and inspecting."); DC_MoreStats = ConfigFile_Client.Bind("Death Screen", "More Stats", true, "Add various custom stats and make some more vanilla stats viewable."); DC_CompactStats = ConfigFile_Client.Bind("Death Screen", "Compact Stats", true, "Combine most stats into 2 per column and hide the score. Score per stat will be shown by hovering over it."); DC_RealTimeTimerStat = ConfigFile_Client.Bind("Death Screen", "Total Run Time", true, "Show the total time spent in a run in the top middle."); DC_KillerInventory = ConfigFile_Client.Bind("Death Screen", "Killer Inventory", true, "Show the Killers Inventory, if he had any items.\nIf no killer was found, tries to display Items from Artifact of Evolution & Simulacrum"); DC_StageRecap = ConfigFile_Client.Bind("Death Screen", "Stage Recap", true, "Show stages traversed during run.\nUseful for sharing if you went through various alt paths or did optional things like Void Fields\n\nInspired by Spelunky 2"); DC_LatestWave = ConfigFile_Client.Bind("Death Screen", "Latest Wave", true, "Show latest Simu Wave"); DC_KillerInventory_EvenIfJustElite = ConfigFile_Client.Bind("Death Screen", "Killer Elite Equip", false, "Show the killers inventory even if they only have a Elite Equipment and no items."); Logbook_More = ConfigFile_Client.Bind("Logbook", "Log | More Entries", true, "Add entries for some promiment content that is missing a log entry:\n\nTwisted Scav (Unlocked by having Moment Whole log)\nGeep & Gip\nSolus Mine\nFuel Array\nConsumed Equipment"); Logbook_WeirdoEnemies = ConfigFile_Client.Bind("Logbook", "Monster Spawns Entries", false, "Adds entries for more rare content, that isn't too important:\n\nMalachite Urchin\nSevered Breaker\nSevered Probe\nSevered Scorcher"); LogbookSimuStages = ConfigFile_Client.Bind("Logbook", "Log | Show Simu Stages", false, "Add Simulacrum stages to log. Unlocked if beaten once."); Logbook_EliteEquip = ConfigFile_Client.Bind("Logbook", "Log | Elite Aspects", true, "Add Elite Aspect Equipment to the logbook."); Logbook_EliteEquipEarlyViewable = ConfigFile_Client.Bind("Logbook", "Elite Aspect viewable without pickup", true, "Elite Aspects will be viewable without the need to be picked up first.\n\nInstead viewable based on progression, such as having beaten the game on Monsoon."); Logbook_AllyExpansion = ConfigFile_Client.Bind("Logbook", "Drones & Allies", false, "Expand Drones category to Drones & Allies, giving info on allies given by items.\n\nAutomatically disabled with Realer Cheats"); Logbook_Recipes = ConfigFile_Client.Bind("Logbook", "Recipe Info", true, "For Alloyed Collective; Adds Recipes info to Item entries.\n\n(Requires a restart)"); Logbook_SortBosses = ConfigFile_Client.Bind("Logbook", "Log | Sort Bosses", true, "Sort Bosses to the end of the Monster category"); cfgSkinMercRedSword = ConfigFile_Client.Bind("Skins", "Oni Merc Red Sword", true, "To fit better with his Red skin."); cfgSkinMercRed = ConfigFile_Client.Bind("Skins", "Oni Merc | Red effects", true, "Replace blue effects with red effects for Oni Merc / Mastery Skin"); cfgSkinMercGreen = ConfigFile_Client.Bind("Skins", "Frail Merc | Green effects", true, "Replace blue effects with green effects for Frail Merc / Colossus Skin"); cfgSkinMercPink = ConfigFile_Client.Bind("Skins", "Murder Merc | Pink effects", true, "Replace blue effects with pink effects for Murder Merc / Vulture Skin"); cfgSkinMercSS2 = ConfigFile_Client.Bind("Skins", "(SS2) Heel Merc | Red effects", true, "Replace blue effects with red effects for the StarStorm2 Heel skin."); cfgSkinAcridBlight = ConfigFile_Client.Bind("Skins", "Blight Acrid effects", true, "Attacks that apply blight are colored Purple/Orange instead of Green/Yellow. Includes a variant of the default skin.\n\n(Requires a restart)"); cfgSkinMakeBlightedAcrid = ConfigFile_Client.Bind("Skins", "Default Acrid Blight Recolor", false, "Simple recolor where instead of green it's more yellow-orange\n\nThis is a seperate skin as of now.\n\n(Requires a restart)"); cfgSkinOperatorAltChirp = ConfigFile_Client.Bind("Skins", "Operator Mastery Recolor Chirp", true, "Recolors Chirp to match the colors of the mastery skin.\n\n(Requires a restart)"); cfgSkinEngiHarpoons = ConfigFile_Client.Bind("Skins", "Skinned Engi Harpoons", true, "His other projectiles are skinned but not harpoons.\n\n(Requires a restart)"); cfgSkinMisc = ConfigFile_Client.Bind("Skins", "Smaller Skin Fixes", true, "REX uses colored vines when moving\nFixes Alt Engi turrets looking wrong\nMulT power mode cylinders will be skinned\nLoader m2 hand will be skinned"); SulfurPoolsSkin = ConfigFile_Client.Bind("Skins", "Sulfur Pool Beetles Skin", true, "Implement the unused SotV Sulfur Pools skin for the Beetle family"); cfgSkinBellBalls = ConfigFile_Client.Bind("Skins", "Elite attack effects", true, "Certain attacks will be elite colored to match effect.\n\nBrass Contraption balls\nTitan Fists"); cfgVoidAllyCyanEyes = ConfigFile_Client.Bind("Skins", "Void Ally Cyan Eyes", true, "Void Allies from Newly Hatched Zoea will have bright Cyan eyes for easier identification.\n\n(Requires a restart)"); ArtificerBazaarAlways = ConfigFile_Client.Bind("Other", "Artificer Always in Bazaar", false, "I just think she's a nice Decoration and REX is always there."); cfgSmoothCaptain = ConfigFile_Client.Bind("Skins", "Colossus Captain Smooth", false, "Makes the armor on the skin smooth instead of battered\n\n(Requires a restart)"); cfgTwistedFire = ConfigFile_Client.Bind("Visuals", "Fire Twisted Elites", true, "Readds the lunar fire visual effect that twisted elites once had.\n\n(Requires a restart)"); cfgDarkTwisted = ConfigFile_Client.Bind("Visuals", "Dark Twisted Elites", true, "Gives Twisted Elites a dark blue coloration instead of reusing Overloading.\n\n(Requires a restart)"); SH_Music_Restarter = ConfigFile_Client.Bind("Other", "Restart Solutional Haunt music", true, "Re-starts the Solutional Haunt music after the Solus Wing boss fight."); cfgPrimordialBlueText = ConfigFile_Client.Bind("Other", "Primordial | Blue objective", false, "Teleporter objective has blue text when it is a primordial teleporter."); cfgPrimordialBlueIcon = ConfigFile_Client.Bind("Other", "Primordial | Blue Charge Icon", false, "Charging icon will be blue instead of red."); cfgPrimordialBlueHighlight = ConfigFile_Client.Bind("Other", "Primordial | Blue Highlight", false, "Interactable highlight will be blue instead of red."); ArtifactOutline = ConfigFile_Client.Bind("Other", "Artifact Outline", false, "Should Artifact Pickups in the Artifact World have a purple (Artifact Color) outline."); } public static void TestConfig() { cfgTestClient = ConfigFile_Client.Bind("Testing", "Client Test", false, "Client work arounds wont get removed if host has mod."); cfgTestDisableHostInfo = ConfigFile_Client.Bind("Testing", "Disable Host Info", false, "Host methods will be disabled"); cfgTestDisableMod = ConfigFile_Client.Bind("Testing", "Disable mod next time", false, "Mod will not load the next time."); } private static void LoadAll() { Assets.Bundle.LoadAllAssets(); } public static void RiskConfig() { //IL_0212: Unknown result type (might be due to invalid IL or missing references) //IL_021c: Expected O, but got Unknown //IL_0248: Unknown result type (might be due to invalid IL or missing references) //IL_0252: Expected O, but got Unknown //IL_036d: Unknown result type (might be due to invalid IL or missing references) //IL_0377: Expected O, but got Unknown //IL_0362: Unknown result type (might be due to invalid IL or missing references) //IL_0367: Unknown result type (might be due to invalid IL or missing references) //IL_036d: Expected O, but got Unknown //IL_027b: Unknown result type (might be due to invalid IL or missing references) //IL_0280: Unknown result type (might be due to invalid IL or missing references) //IL_028b: Unknown result type (might be due to invalid IL or missing references) //IL_0296: Unknown result type (might be due to invalid IL or missing references) //IL_02a7: Expected O, but got Unknown //IL_02a2: Unknown result type (might be due to invalid IL or missing references) //IL_02ac: Expected O, but got Unknown //IL_02c6: Unknown result type (might be due to invalid IL or missing references) //IL_02d0: Expected O, but got Unknown ModSettingsManager.SetModIcon(Assets.Bundle.LoadAsset("Assets/WQoL/icon.png")); ModSettingsManager.SetModDescription("Random assortment of Quality of Life."); List list = new List { (ConfigEntryBase)(object)module_menu_deathscreen, (ConfigEntryBase)(object)module_menu_logbook, (ConfigEntryBase)(object)module_menu_other, (ConfigEntryBase)(object)module_text_chat, (ConfigEntryBase)(object)module_text_general, (ConfigEntryBase)(object)module_text_reminders, (ConfigEntryBase)(object)module_visuals_icons, (ConfigEntryBase)(object)module_visuals_other, (ConfigEntryBase)(object)module_visuals_skins, (ConfigEntryBase)(object)cfgMessagesVoidQuantity, (ConfigEntryBase)(object)SulfurPoolsSkin, (ConfigEntryBase)(object)cfgRemindersPortal, (ConfigEntryBase)(object)cfgChargeHalcyShrine, (ConfigEntryBase)(object)cfgTextOther, (ConfigEntryBase)(object)cfgBuff_RepeatColors, (ConfigEntryBase)(object)Logbook_EliteEquip, (ConfigEntryBase)(object)Logbook_Recipes, (ConfigEntryBase)(object)Logbook_SortBosses, (ConfigEntryBase)(object)Logbook_AllyExpansion, (ConfigEntryBase)(object)Logbook_More, (ConfigEntryBase)(object)cfgPingIcons, (ConfigEntryBase)(object)cfgIconsBodyIcons, (ConfigEntryBase)(object)cfgSkinEngiHarpoons, (ConfigEntryBase)(object)cfgTpIconDiscoveredRed, (ConfigEntryBase)(object)cfgVoidAllyCyanEyes, (ConfigEntryBase)(object)OldModelDuplcators, (ConfigEntryBase)(object)cfgColorMain, (ConfigEntryBase)(object)cfgColorVoids, (ConfigEntryBase)(object)cfgSmoothCaptain, (ConfigEntryBase)(object)cfgDarkTwisted, (ConfigEntryBase)(object)cfgTwistedFire, (ConfigEntryBase)(object)cfgChefMenuTweak, (ConfigEntryBase)(object)cfgSkinOperatorAltChirp, (ConfigEntryBase)(object)cfgSkinAcridBlight, (ConfigEntryBase)(object)cfgSkinMakeBlightedAcrid }; ConfigEntryBase[] configEntries = ConfigFile_Client.GetConfigEntries(); ConfigEntryBase[] array = configEntries; foreach (ConfigEntryBase val in array) { if (val.SettingType == typeof(bool)) { ModSettingsManager.AddOption((BaseOption)new CheckBoxOption((ConfigEntry)(object)val, list.Contains(val))); } else if (val.SettingType == typeof(int)) { ModSettingsManager.AddOption((BaseOption)new IntFieldOption((ConfigEntry)(object)val, false)); } else if (val.SettingType == typeof(float)) { ModSettingsManager.AddOption((BaseOption)new SliderOption(ObjectiveHudSpacing, new SliderConfig { max = 0f, min = -8f, FormatString = "{0:0}" })); } else if (val.SettingType.IsEnum) { ModSettingsManager.AddOption((BaseOption)new ChoiceOption(val, false)); } else { Log.LogWarning("Could not add config " + val.Definition.Key + " of type : " + val.SettingType); } } ObjectiveHudSpacing.SettingChanged += MenuMain.ObjectiveHudSpacing_SettingChanged; object obj = <>O.<1>__LoadAll; if (obj == null) { UnityAction val2 = LoadAll; <>O.<1>__LoadAll = val2; obj = (object)val2; } ModSettingsManager.AddOption((BaseOption)new GenericButtonOption("Load all Assets", "Testing", "Loads all Assets", "Load", (UnityAction)obj)); } } [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInDependency(/*Could not decode attribute arguments.*/)] [BepInPlugin("Wolfo.WolfoQoL_Client", "WolfoQualityOfLife", "5.1.6")] [NetworkCompatibility(/*Could not decode attribute arguments.*/)] public class WQoLMain : BaseUnityPlugin { public class HostPingAllClients : ChatMessageBase { public override string ConstructChatString() { HostHasMod = true; if (!NetworkServer.active) { Log.LogMessage("Host has WolfoQoL_Client: " + HostHasMod_); } if (WConfig.cfgTestClient.Value) { return null; } foreach (PlayerCharacterMasterController instance in PlayerCharacterMasterController.instances) { Object.Destroy((Object)(object)((Component)instance).GetComponent()); Object.Destroy((Object)(object)((Component)instance).GetComponent()); } return null; } } public static readonly Random random = new Random(); public static bool ServerModInstalled = false; public static bool ProperSaveInstalled = false; public static bool NoMoreMathMod = false; public static bool ZetAspects = false; public static bool QualityModInstalled; public static bool HostHasMod_ = false; public static bool NoHostInfo { get { if (!NetworkServer.active) { return WConfig.cfgTestDisableHostInfo.Value; } return false; } } public static bool HostHasMod { get { if (WConfig.cfgTestClient.Value) { return false; } return HostHasMod_; } set { HostHasMod_ = value; } } public void Awake() { //IL_0029: 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_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0056: Expected O, but got Unknown //IL_006c: Unknown result type (might be due to invalid IL or missing references) //IL_0076: Expected O, but got Unknown //IL_008c: Unknown result type (might be due to invalid IL or missing references) //IL_0096: Expected O, but got Unknown //IL_00ac: Unknown result type (might be due to invalid IL or missing references) //IL_00b6: Expected O, but got Unknown //IL_02d3: Unknown result type (might be due to invalid IL or missing references) //IL_02dd: Expected O, but got Unknown Log.log = ((BaseUnityPlugin)this).Logger; WConfig.Start(); Assets.Init(((BaseUnityPlugin)this).Info); WConfig.RiskConfig(); TMP_StyleSheet val = Addressables.LoadAssetAsync((object)"54d1085f9a2fdea4587fcfc7dddcd4bc").WaitForCompletion(); val.styles.Add(new TMP_Style("cGold", "", "")); val.styles.Add(new TMP_Style("cRebirth", "", "")); val.styles.Add(new TMP_Style("cMysterySpace", "", "")); val.styles.Add(new TMP_Style("cAlly", "", "")); if (WConfig.cfgTestDisableMod.Value) { Log.LogWarning("Disabled Mod for Test"); return; } byte b = 0; Networker.message_to_index.Add(typeof(ItemLossMessage), b); Networker.index_to_message.Add(b, typeof(ItemLossMessage)); b++; Networker.message_to_index.Add(typeof(InteractableMessage), b); Networker.index_to_message.Add(b, typeof(InteractableMessage)); b++; Networker.message_to_index.Add(typeof(DroneChatMessage), b); Networker.index_to_message.Add(b, typeof(DroneChatMessage)); b++; Networker.message_to_index.Add(typeof(DeathMessage.DetailedDeathMessage), b); Networker.index_to_message.Add(b, typeof(DeathMessage.DetailedDeathMessage)); b++; Networker.message_to_index.Add(typeof(KillerInventoryMessage), b); Networker.index_to_message.Add(b, typeof(KillerInventoryMessage)); b++; Networker.message_to_index.Add(typeof(HostPingAllClients), b); Networker.index_to_message.Add(b, typeof(HostPingAllClients)); b++; Networker.message_to_index.Add(typeof(PerPlayerMaster_ExtraStatTracker.SyncValues), b); Networker.index_to_message.Add(b, typeof(PerPlayerMaster_ExtraStatTracker.SyncValues)); b++; Networker.message_to_index.Add(typeof(DevotionDeathMessage), b); Networker.index_to_message.Add(b, typeof(DevotionDeathMessage)); ClientChecks.Start(); MenuMain.Start(); TextMain.Start(); VisualsMain.Start(); Run.onRunStartGlobal += Run_onRunStartGlobal; Run.onRunDestroyGlobal += Run_onRunDestroyGlobal; ((ResourceAvailability)(ref BodyCatalog.availability)).CallWhenAvailable((Action)WStats.MakeStats); ((BaseConVar)PreGameController.cvSvAllowMultiplayerPause).defaultValue = "1"; PauseScreenController.InstantiateMinimalPauseScreen += new hook_InstantiateMinimalPauseScreen(PauseScreenController_InstantiateMinimalPauseScreen); } private GameObject PauseScreenController_InstantiateMinimalPauseScreen(orig_InstantiateMinimalPauseScreen orig) { GameObject val = orig.Invoke(); ((Component)val.transform.GetChild(0).GetChild(0)).gameObject.SetActive(false); return val; } public void Start() { ServerModInstalled = Chainloader.PluginInfos.ContainsKey("Wolfo.WolfoQoL_Server"); ProperSaveInstalled = Chainloader.PluginInfos.ContainsKey("com.KingEnderBrine.ProperSave"); NoMoreMathMod = Chainloader.PluginInfos.ContainsKey("Gorakh.NoMoreMath"); ZetAspects = Chainloader.PluginInfos.ContainsKey("com.TPDespair.ZetAspects"); QualityModInstalled = Chainloader.PluginInfos.ContainsKey("com.Gorakh.ItemQualities"); if (ProperSaveInstalled) { AddProperSaveSupport.Start(); } } private void Run_onRunStartGlobal(Run obj) { GC.Collect(); if (NetworkServer.active) { Networker.SendWQoLMessage((ChatMessageBase)(object)new HostPingAllClients()); } } private void Run_onRunDestroyGlobal(Run obj) { HostHasMod = false; } } public static class WStats { public static ConfigFile StatsFile = new ConfigFile(Paths.ConfigPath + "\\Wolfo.WolfoQoL_StatStorage.cfg", true); public static void MakeStats() { for (int i = 0; i < BodyCatalog.bodyPrefabs.Length; i++) { StatsFile.Bind("MinionDamage", ((Object)BodyCatalog.bodyPrefabs[i]).name, 0.0, ""); } } public static void AddStat(int index, float newDamage) { //IL_0017: Unknown result type (might be due to invalid IL or missing references) //IL_0023: Expected O, but got Unknown ConfigEntry val = default(ConfigEntry); if (StatsFile.TryGetEntry(new ConfigDefinition("MinionDamage", ((Object)BodyCatalog.bodyPrefabs[index]).name), ref val)) { ConfigEntry obj = val; obj.Value += (double)newDamage; } } public static double GetStat(int index) { //IL_0017: Unknown result type (might be due to invalid IL or missing references) //IL_0023: Expected O, but got Unknown ConfigEntry val = default(ConfigEntry); if (StatsFile.TryGetEntry(new ConfigDefinition("MinionDamage", ((Object)BodyCatalog.bodyPrefabs[index]).name), ref val)) { return val.Value; } return 0.0; } } public static class ArrayUtil { public static T[] Add(this T[] array, params T[] items) { return (array ?? Enumerable.Empty()).Concat(items).ToArray(); } public static T[] Remove(this T[] array, params T[] items) { return (array ?? Enumerable.Empty()).Except(items).ToArray(); } } public static class Help { private static readonly StringBuilder stringBuilder = new StringBuilder(); public static ItemIndex FindItemWithHighestStat(StatSheet statSheet, PerItemStatDef perItemStatDef) { //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_001a: 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_0050: Unknown result type (might be due to invalid IL or missing references) //IL_0055: Unknown result type (might be due to invalid IL or missing references) //IL_0057: 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_007b: 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) StatField val = statSheet.fields[perItemStatDef.FindStatDef((ItemIndex)0).index]; ItemIndex result = (ItemIndex)0; for (int i = 1; i < ItemCatalog.itemCount; i++) { ref StatField reference = ref statSheet.fields[perItemStatDef.FindStatDef((ItemIndex)i).index]; if (((StatField)(ref val)).CompareTo(reference) < 0) { val = reference; result = (ItemIndex)i; } } if (((StatField)(ref val)).IsDefault()) { return (ItemIndex)(-1); } return result; } internal static bool IconIsNotSuitable(CharacterBody body) { if (!Object.op_Implicit((Object)(object)body.portraitIcon)) { return true; } string name = ((Object)body.portraitIcon).name; return name == "texMysteryIcon" || name == "texNullIcon"; } public static BodyIndex FindBodyWithHighestStatNotMasterless(StatSheet statSheet, PerBodyStatDef perBodyStatDef) { //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_004a: 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_00a4: 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_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) StatField val = statSheet.fields[perBodyStatDef.FindStatDef((BodyIndex)0).index]; int num = 0; for (int i = 1; i < BodyCatalog.bodyCount; i++) { ref StatField reference = ref statSheet.fields[ArrayUtils.GetSafe(perBodyStatDef.bodyIndexToStatDef, i).index]; if (((StatField)(ref reference)).ulongValue != 0 && ((StatField)(ref val)).CompareTo(reference) < 0 && !IconIsNotSuitable(BodyCatalog.bodyPrefabBodyComponents[i])) { val = reference; num = i; } } if (((StatField)(ref val)).IsDefault()) { return (BodyIndex)(-1); } return (BodyIndex)num; } public static ulong GetTotalEquipmentAcivations(StatSheet statSheet) { ulong num = 0uL; for (int i = 0; i < EquipmentCatalog.equipmentCount; i++) { num += statSheet.GetStatValueULong(PerEquipmentStatDef.totalTimesFired.FindStatDef((EquipmentIndex)i)); } Log.LogMessage($"Equipment Activations: {num}"); return num; } public static SceneDef ITtoNormal(SceneDef scene) { if (scene.cachedName == "itdampcave") { return SceneCatalog.FindSceneDef("dampcavesimple"); } string text = scene.cachedName.Remove(0, 2); return SceneCatalog.FindSceneDef(scene.cachedName.Remove(0, 2)); } public static string GetColoredName(ItemIndex index, bool temp = false) { //IL_0001: Unknown result type (might be due to invalid IL or missing references) //IL_0002: Unknown result type (might be due to invalid IL or missing references) return GetColoredName(PickupCatalog.FindPickupIndex(index), 0, temp); } public static string GetColoredName(EquipmentIndex index) { //IL_0001: Unknown result type (might be due to invalid IL or missing references) //IL_0002: Unknown result type (might be due to invalid IL or missing references) return GetColoredName(PickupCatalog.FindPickupIndex(index)); } public static string GetColoredName(DroneIndex index, int tier) { //IL_0001: Unknown result type (might be due to invalid IL or missing references) //IL_0002: Unknown result type (might be due to invalid IL or missing references) return GetColoredName(PickupCatalog.FindPickupIndex(index), tier); } public static string GetColoredName(PickupIndex index, int tier = 0, bool isTemporary = false) { //IL_0001: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Unknown result type (might be due to invalid IL or missing references) PickupDef pickupDef = PickupCatalog.GetPickupDef(index); if (pickupDef == null) { return "Null"; } StringBuilder stringBuilder = Help.stringBuilder; stringBuilder.Clear(); stringBuilder.Append(""); if (isTemporary) { stringBuilder.Append(Language.GetStringFormatted("ITEM_MODIFIER_TEMP", new object[1] { Language.GetString(pickupDef.nameToken) })); } else if (tier > 0) { stringBuilder.Append(Language.GetStringFormatted("DRONE_TIER_SUFFIX", new object[2] { Language.GetString(pickupDef.nameToken), tier + 1 })); } else { stringBuilder.Append(Language.GetString(pickupDef.nameToken)); } stringBuilder.Append(""); return stringBuilder.ToString(); } public static string GetColoredName(PickupDef def, bool isTemporary) { //IL_001c: Unknown result type (might be due to invalid IL or missing references) StringBuilder stringBuilder = Help.stringBuilder; stringBuilder.Clear(); stringBuilder.Append(""); if (isTemporary) { stringBuilder.Append(Language.GetStringFormatted("ITEM_MODIFIER_TEMP", new object[1] { Language.GetString(def.nameToken) })); } else { stringBuilder.Append(Language.GetString(def.nameToken)); } stringBuilder.Append(""); return stringBuilder.ToString(); } } public static class ItemFilters { public static readonly Func NoTierDeathItemFilterDelegate = NoTierDeathItemCopyFilter; public static readonly Func AllowAllItemFilterDelegate = AllowAllItemFilter; public static bool NoTierDeathItemCopyFilter(ItemIndex itemIndex) { //IL_0001: 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_001e: Invalid comparison between Unknown and I4 ItemDef itemDef = ItemCatalog.GetItemDef(itemIndex); if (itemDef.hidden) { return false; } if ((int)itemDef.tier != 5) { return true; } if (itemDef.isConsumed) { return true; } if (!Object.op_Implicit((Object)(object)itemDef.pickupIconSprite) || ((Object)itemDef.pickupIconSprite).name == "texNullIcon") { return false; } return true; } public static bool AllowAllItemFilter(ItemIndex itemIndex) { return true; } } public static class Courtines { [CompilerGenerated] private sealed class d__1 : IEnumerator, IEnumerator, IDisposable { private int <>1__state; private object <>2__current; public string chatMessage; public float Delay; object IEnumerator.Current { [DebuggerHidden] get { return <>2__current; } } object IEnumerator.Current { [DebuggerHidden] get { return <>2__current; } } [DebuggerHidden] public d__1(int <>1__state) { this.<>1__state = <>1__state; } [DebuggerHidden] void IDisposable.Dispose() { <>1__state = -2; } private bool MoveNext() { //IL_0027: Unknown result type (might be due to invalid IL or missing references) //IL_0031: Expected O, but got Unknown switch (<>1__state) { default: return false; case 0: <>1__state = -1; <>2__current = (object)new WaitForSeconds(Delay); <>1__state = 1; return true; case 1: <>1__state = -1; Chat.AddMessage(chatMessage); return false; } } bool IEnumerator.MoveNext() { //ILSpy generated this explicit interface implementation from .override directive in MoveNext return this.MoveNext(); } [DebuggerHidden] void IEnumerator.Reset() { throw new NotSupportedException(); } } [CompilerGenerated] private sealed class d__2 : IEnumerator, IEnumerator, IDisposable { private int <>1__state; private object <>2__current; public string token; public float delay; object IEnumerator.Current { [DebuggerHidden] get { return <>2__current; } } object IEnumerator.Current { [DebuggerHidden] get { return <>2__current; } } [DebuggerHidden] public d__2(int <>1__state) { this.<>1__state = <>1__state; } [DebuggerHidden] void IDisposable.Dispose() { <>1__state = -2; } private bool MoveNext() { //IL_0027: Unknown result type (might be due to invalid IL or missing references) //IL_0031: Expected O, but got Unknown //IL_0041: Unknown result type (might be due to invalid IL or missing references) //IL_0046: Unknown result type (might be due to invalid IL or missing references) //IL_0057: Expected O, but got Unknown switch (<>1__state) { default: return false; case 0: <>1__state = -1; <>2__current = (object)new WaitForSeconds(delay); <>1__state = 1; return true; case 1: <>1__state = -1; Networker.SendWQoLMessage((ChatMessageBase)new SimpleChatMessage { baseToken = token }); return false; } } bool IEnumerator.MoveNext() { //ILSpy generated this explicit interface implementation from .override directive in MoveNext return this.MoveNext(); } [DebuggerHidden] void IEnumerator.Reset() { throw new NotSupportedException(); } } [CompilerGenerated] private sealed class d__3 : IEnumerator, IEnumerator, IDisposable { private int <>1__state; private object <>2__current; public NetworkUser user; public float delay; private string 5__1; object IEnumerator.Current { [DebuggerHidden] get { return <>2__current; } } object IEnumerator.Current { [DebuggerHidden] get { return <>2__current; } } [DebuggerHidden] public d__3(int <>1__state) { this.<>1__state = <>1__state; } [DebuggerHidden] void IDisposable.Dispose() { 5__1 = null; <>1__state = -2; } private bool MoveNext() { //IL_0027: Unknown result type (might be due to invalid IL or missing references) //IL_0031: Expected O, but got Unknown //IL_0052: Unknown result type (might be due to invalid IL or missing references) switch (<>1__state) { default: return false; case 0: <>1__state = -1; <>2__current = (object)new WaitForSeconds(delay); <>1__state = 1; return true; case 1: <>1__state = -1; 5__1 = string.Format(Language.GetString("REBIRTH_ENDING_CHAT_ITEM_2P"), Help.GetColoredName(user.rebirthItem)); Chat.AddMessage(" " + string.Format(Language.GetString("WIN_FORMAT_REBIRTH"), 5__1)); return false; } } bool IEnumerator.MoveNext() { //ILSpy generated this explicit interface implementation from .override directive in MoveNext return this.MoveNext(); } [DebuggerHidden] void IEnumerator.Reset() { throw new NotSupportedException(); } } public static float LagDependentDelay() { return 1f; } [IteratorStateMachine(typeof(d__1))] public static IEnumerator Delayed_ChatAddMessage(string chatMessage, float Delay) { //yield-return decompiler failed: Unexpected instruction in Iterator.Dispose() return new d__1(0) { chatMessage = chatMessage, Delay = Delay }; } [IteratorStateMachine(typeof(d__2))] public static IEnumerator Delayed_ChatBroadcast(string token, float delay) { //yield-return decompiler failed: Unexpected instruction in Iterator.Dispose() return new d__2(0) { token = token, delay = delay }; } [IteratorStateMachine(typeof(d__3))] public static IEnumerator Delayed_RebirthMessage(NetworkUser user, float delay) { //yield-return decompiler failed: Unexpected instruction in Iterator.Dispose() return new d__3(0) { user = user, delay = delay }; } } internal static class Log { public static ManualLogSource log; public static void LogMessage(object message) { log.LogMessage(message); } public static void LogWarning(object message) { log.LogWarning(message); } public static void LogError(object message) { log.LogError(message); } } } namespace WolfoQoL_Client.ModSupport { public static class AddProperSaveSupport { public static string ReturnPath(string profile, string type) { return Path.Combine(Application.persistentDataPath, "ProperSave", "Saves") + "\\WQoL_" + type + profile + ".csv"; } public static void Start() { SaveFile.OnGatherSaveData += SaveFile_OnGatherSaveData; Loading.OnLoadingEnded += Loading_OnLoadingEnded; } private static void SaveFile_OnGatherSaveData(Dictionary obj) { string text = ReturnPath(LocalUserManager.GetFirstLocalUser().userProfile.fileName, "R_"); string path = ReturnPath(LocalUserManager.GetFirstLocalUser().userProfile.fileName, "P_"); RunTrackerData.Save(text); PlayerTrackerData.Save(path); if (WConfig.cfgTestMultiplayer.Value) { Debug.Log((object)text); } } private static void Loading_OnLoadingEnded(SaveFile _) { string path = ReturnPath(LocalUserManager.GetFirstLocalUser().userProfile.fileName, "R_"); string path2 = ReturnPath(LocalUserManager.GetFirstLocalUser().userProfile.fileName, "P_"); if (File.Exists(path) && File.Exists(path2)) { RunTrackerData.Load(path); PlayerTrackerData.Load(path2); Log.LogMessage("Loading WQoL save data"); } else { Log.LogMessage("No WQOL Proper Save Data for this profile."); } } } public static class RunTrackerData { public static void Load(string path) { RunExtraStatTracker runExtraStatTracker = UnityObjectExtensions.EnsureComponent(((Component)Run.instance).gameObject); runExtraStatTracker.visitedScenes = new List(); string[] array = File.ReadAllLines(path); string[] array2 = array[0].Split(','); for (int i = 0; i < array2.Length; i++) { Debug.Log((object)array2[i]); runExtraStatTracker.visitedScenes.Add(SceneCatalog.GetSceneDef((SceneIndex)int.Parse(array2[i]))); } runExtraStatTracker.missedChests = int.Parse(array[1]); runExtraStatTracker.missedDrones = int.Parse(array[2]); runExtraStatTracker.missedShrineChanceItems = int.Parse(array[3]); runExtraStatTracker.missedLemurians = int.Parse(array[4]); } public static void Save(string path) { //IL_004d: Unknown result type (might be due to invalid IL or missing references) //IL_0054: Expected I4, but got Unknown if (!Object.op_Implicit((Object)(object)RunExtraStatTracker.instance)) { File.Delete(path); return; } RunExtraStatTracker instance = RunExtraStatTracker.instance; string text = string.Empty; int num = instance.visitedScenes.Count - 1; for (int i = 0; i < num; i++) { text += (int)instance.visitedScenes[i].sceneDefIndex; if (i < num - 1) { text += ","; } } text += "\n"; text = text + instance.missedChests + "\n"; text = text + instance.missedDrones + "\n"; text = text + instance.missedShrineChanceItems + "\n"; text = text + instance.missedLemurians + "\n"; File.WriteAllText(path, text); } } public static class PlayerTrackerData { public static void Load(string path) { //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_006a: Unknown result type (might be due to invalid IL or missing references) string[] array = File.ReadAllLines(path); string[] array2 = array; foreach (string text in array2) { string[] array3 = text.Split("###"); ulong num = ulong.Parse(array3[0]); PlayerCharacterMasterController val = null; foreach (PlayerCharacterMasterController instance in PlayerCharacterMasterController.instances) { if (Object.op_Implicit((Object)(object)instance.networkUser)) { NetworkUserId id = instance.networkUser.id; if (((NetworkUserId)(ref id)).steamId.ID == num) { val = instance; break; } } } if (Object.op_Implicit((Object)(object)val)) { PerPlayerMaster_ExtraStatTracker perPlayerMaster_ExtraStatTracker = UnityObjectExtensions.EnsureComponent((Component)(object)val); perPlayerMaster_ExtraStatTracker.scrappedItems = int.Parse(array3[1]); perPlayerMaster_ExtraStatTracker.scrappedDrones = int.Parse(array3[2]); perPlayerMaster_ExtraStatTracker.minionDamageTaken = ulong.Parse(array3[3]); perPlayerMaster_ExtraStatTracker.minionHealing = ulong.Parse(array3[4]); perPlayerMaster_ExtraStatTracker.minionDeaths = int.Parse(array3[5]); perPlayerMaster_ExtraStatTracker.spentLunarCoins = int.Parse(array3[6]); perPlayerMaster_ExtraStatTracker.timesJumped = int.Parse(array3[7]); perPlayerMaster_ExtraStatTracker.lemuriansHatched = int.Parse(array3[8]); perPlayerMaster_ExtraStatTracker.dotDamageDone = ulong.Parse(array3[9]); perPlayerMaster_ExtraStatTracker.damageBlocked = ulong.Parse(array3[10]); string text2 = array3[11]; string[] array4 = text2.Split(','); for (int j = 0; j < array4.Length; j++) { perPlayerMaster_ExtraStatTracker.perMinionDamage[j] = ulong.Parse(array4[j]); } perPlayerMaster_ExtraStatTracker.timeAliveReal = float.Parse(array3[12]); } } } public static void Save(string path) { //IL_0074: Unknown result type (might be due to invalid IL or missing references) //IL_0079: Unknown result type (might be due to invalid IL or missing references) //IL_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) string text = "###"; string text2 = string.Empty; foreach (PlayerCharacterMasterController instance in PlayerCharacterMasterController.instances) { if (!Object.op_Implicit((Object)(object)instance.networkUser)) { continue; } PerPlayerMaster_ExtraStatTracker component = ((Component)instance).GetComponent(); if (!Object.op_Implicit((Object)(object)component)) { File.Delete(path); return; } string empty = string.Empty; string text3 = empty; NetworkUserId id = instance.networkUser.id; empty = text3 + ((NetworkUserId)(ref id)).steamId.ID + text; empty = empty + component.scrappedItems + text; empty = empty + component.scrappedDrones + text; empty = empty + component.minionDamageTaken + text; empty = empty + component.minionHealing + text; empty = empty + component.minionDeaths + text; empty = empty + component.spentLunarCoins + text; empty = empty + component.timesJumped + text; empty = empty + component.lemuriansHatched + text; empty = empty + component.dotDamageDone + text; empty = empty + component.damageBlocked + text; for (int i = 0; i < component.perMinionDamage.Length; i++) { empty += component.perMinionDamage[i]; if (i < component.perMinionDamage.Length - 1) { empty += ","; } } empty += text; empty = empty + component.timeAliveReal + text; empty += "\n"; text2 += empty; } File.WriteAllText(path, text2); } } public static class QualitySupport { public static bool PreBaseItemIndex(ItemIndex newItem, ItemDef isThisItem) { //IL_001a: 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_000b: Unknown result type (might be due to invalid IL or missing references) //IL_000d: Unknown result type (might be due to invalid IL or missing references) if (WQoLMain.QualityModInstalled) { return BaseItemIndex(newItem, isThisItem.itemIndex); } return newItem == isThisItem.itemIndex; } public static bool BaseItemIndex(ItemIndex newItem, ItemIndex itemIndex) { //IL_0001: Unknown result type (might be due to invalid IL or missing references) //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0007: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Unknown result type (might be due to invalid IL or missing references) //IL_000a: Invalid comparison between Unknown and I4 //IL_0014: Unknown result type (might be due to invalid IL or missing references) //IL_001a: Unknown result type (might be due to invalid IL or missing references) //IL_001f: Unknown result type (might be due to invalid IL or missing references) ItemQualityGroupIndex val = QualityCatalog.FindItemQualityGroupIndex(newItem); if ((int)val != -1) { return QualityCatalog.GetItemQualityGroup(val).BaseItemIndex == itemIndex; } return false; } public static int QualiyItemCountPermanent(ItemDef itemDef, Inventory inv, bool justQuality = false) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0007: Unknown result type (might be due to invalid IL or missing references) //IL_000c: Unknown result type (might be due to invalid IL or missing references) //IL_000d: Unknown result type (might be due to invalid IL or missing references) //IL_000f: Invalid comparison between Unknown and I4 //IL_0037: 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_001f: Unknown result type (might be due to invalid IL or missing references) //IL_0026: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) ItemQualityGroupIndex val = QualityCatalog.FindItemQualityGroupIndex(itemDef.itemIndex); if ((int)val != -1) { ItemQualityCounts itemCountsPermanent; if (justQuality) { itemCountsPermanent = QualityCatalog.GetItemQualityGroup(val).GetItemCountsPermanent(inv); return ((ItemQualityCounts)(ref itemCountsPermanent)).TotalQualityCount; } itemCountsPermanent = QualityCatalog.GetItemQualityGroup(val).GetItemCountsPermanent(inv); return ((ItemQualityCounts)(ref itemCountsPermanent)).TotalCount; } return 0; } public static int QualiyItemCountEffective(ItemDef itemDef, Inventory inv) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0007: Unknown result type (might be due to invalid IL or missing references) //IL_000c: Unknown result type (might be due to invalid IL or missing references) //IL_000d: Unknown result type (might be due to invalid IL or missing references) //IL_000f: Invalid comparison between Unknown and I4 //IL_0019: 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_0025: Unknown result type (might be due to invalid IL or missing references) ItemQualityGroupIndex val = QualityCatalog.FindItemQualityGroupIndex(itemDef.itemIndex); if ((int)val != -1) { ItemQualityCounts itemCountsPermanent = QualityCatalog.GetItemQualityGroup(val).GetItemCountsPermanent(inv); return ((ItemQualityCounts)(ref itemCountsPermanent)).TotalCount; } return 0; } } } namespace WolfoQoL_Client.Skins { public static class Acrid_Hooks { [CompilerGenerated] private static class <>O { public static hook_BeginMeleeAttackEffect <0>__AcridBlight_M1; public static hook_OnEnter <1>__AcridBlight_M2_M4; public static hook_BeginMeleeAttackEffect <2>__AcridBlight_M2Alt; public static hook_OnEnter <3>__AcridBlight_M3_Start; public static hook_DoImpactAuthority <4>__AcridBlight_M3_Pool; } public static GameObject CrocoDiseaseOrbEffect = LegacyResourcesAPI.Load("Prefabs/effects/orbeffects/CrocoDiseaseOrbEffect"); public static GameObject CrocoDiseaseImpactEffect = Addressables.LoadAssetAsync((object)"RoR2/Base/Croco/CrocoDiseaseImpactEffect.prefab").WaitForCompletion(); public static void Start() { //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_002e: Expected O, but got Unknown //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_004f: Expected O, but got Unknown //IL_0065: Unknown result type (might be due to invalid IL or missing references) //IL_006a: Unknown result type (might be due to invalid IL or missing references) //IL_0070: Expected O, but got Unknown //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) //IL_0091: Expected O, but got Unknown //IL_00a7: Unknown result type (might be due to invalid IL or missing references) //IL_00ac: Unknown result type (might be due to invalid IL or missing references) //IL_00b2: Expected O, but got Unknown if (WConfig.cfgSkinAcridBlight.Value) { object obj = <>O.<0>__AcridBlight_M1; if (obj == null) { hook_BeginMeleeAttackEffect val = AcridBlight_M1; <>O.<0>__AcridBlight_M1 = val; obj = (object)val; } Slash.BeginMeleeAttackEffect += (hook_BeginMeleeAttackEffect)obj; object obj2 = <>O.<1>__AcridBlight_M2_M4; if (obj2 == null) { hook_OnEnter val2 = AcridBlight_M2_M4; <>O.<1>__AcridBlight_M2_M4 = val2; obj2 = (object)val2; } FireSpit.OnEnter += (hook_OnEnter)obj2; object obj3 = <>O.<2>__AcridBlight_M2Alt; if (obj3 == null) { hook_BeginMeleeAttackEffect val3 = AcridBlight_M2Alt; <>O.<2>__AcridBlight_M2Alt = val3; obj3 = (object)val3; } Bite.BeginMeleeAttackEffect += (hook_BeginMeleeAttackEffect)obj3; object obj4 = <>O.<3>__AcridBlight_M3_Start; if (obj4 == null) { hook_OnEnter val4 = AcridBlight_M3_Start; <>O.<3>__AcridBlight_M3_Start = val4; obj4 = (object)val4; } BaseLeap.OnEnter += (hook_OnEnter)obj4; object obj5 = <>O.<4>__AcridBlight_M3_Pool; if (obj5 == null) { hook_DoImpactAuthority val5 = AcridBlight_M3_Pool; <>O.<4>__AcridBlight_M3_Pool = val5; obj5 = (object)val5; } Leap.DoImpactAuthority += (hook_DoImpactAuthority)obj5; } } private static void BlightedOrbEffect_HostOnly(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown //IL_003d: Unknown result type (might be due to invalid IL or missing references) ILCursor val = new ILCursor(il); if (val.TryGotoNext((MoveType)2, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchLdstr(x, "Prefabs/Effects/OrbEffects/CrocoDiseaseOrbEffect") })) { val.Emit(OpCodes.Ldarg_0); val.EmitDelegate>((Func)delegate(string target, LightningOrb orb) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0007: Unknown result type (might be due to invalid IL or missing references) //IL_0011: Invalid comparison between Unknown and I4 if ((int)DamageTypeCombo.op_Implicit(orb.damageType) == 1048576) { EffectReplacer.Activate(CrocoDiseaseOrbEffect, 1); } else { EffectReplacer.Activate(CrocoDiseaseOrbEffect, 0); } return target; }); } else { Log.LogWarning("IL Failed: Blight: IL.RoR2.Orbs.LightningOrb.Begin"); } } private static void AcridBlight_M3_Start(orig_OnEnter orig, BaseLeap self) { if (self is Leap && Object.op_Implicit((Object)(object)((Component)((EntityState)self).outer).GetComponent())) { self.fistEffectPrefab = Effects_Blight.CrocoFistEffectBlight; } orig.Invoke(self); } private static void AcridBlight_M3_Pool(orig_DoImpactAuthority orig, Leap self) { EffectReplacer.ActivateAcrid(((BaseLeap)self).blastEffectPrefab, ((Component)((EntityState)self).outer).gameObject); orig.Invoke(self); } private static void AcridBlight_M2Alt(orig_BeginMeleeAttackEffect orig, Bite self) { if (Object.op_Implicit((Object)(object)((Component)((EntityState)self).outer).GetComponent())) { ((BasicMeleeAttack)self).swingEffectPrefab = Effects_Blight.CrocoBiteEffectBlight; } orig.Invoke(self); } private static void AcridBlight_M2_M4(orig_OnEnter orig, FireSpit self) { EffectReplacer.ActivateAcrid(self.effectPrefab, ((Component)((EntityState)self).outer).gameObject); orig.Invoke(self); } private static void AcridBlight_M1(orig_BeginMeleeAttackEffect orig, Slash self) { if (Object.op_Implicit((Object)(object)((Component)((EntityState)self).outer).GetComponent())) { if (self.isComboFinisher) { ((BasicMeleeAttack)self).swingEffectPrefab = Effects_Blight.CrocoComboFinisherSlashBlight; } else { ((BasicMeleeAttack)self).swingEffectPrefab = Effects_Blight.CrocoSlashBlight; } } orig.Invoke(self); } } public static class Acrid_Main { [CompilerGenerated] private static class <>O { public static Action <0>__EffectReplacements; public static Action <1>__CrocoBlightSkin; public static hook_OnEnable <2>__SpawnBlightPuddleInLobby; public static hook_OnLoadoutChangedGlobal <3>__UpdateBlightPuddleLobby; } public static bool justSpawned = true; public static void Start() { //IL_001d: Unknown result type (might be due to invalid IL or missing references) //IL_0022: Unknown result type (might be due to invalid IL or missing references) //IL_00ae: Unknown result type (might be due to invalid IL or missing references) //IL_00b3: Unknown result type (might be due to invalid IL or missing references) //IL_00b9: Expected O, but got Unknown //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_00da: Expected O, but got Unknown if (WConfig.cfgSkinAcridBlight.Value) { Addressables.LoadAssetAsync((object)"RoR2/Base/Croco/CrocoBody.prefab").WaitForCompletion().AddComponent(); Effects_Blight.Start(); Acrid_Hooks.Start(); Effects_Blight.GhostReplacements(); ((ResourceAvailability)(ref GameModeCatalog.availability)).CallWhenAvailable((Action)EffectReplacements); if (WConfig.cfgSkinMakeBlightedAcrid.Value) { ((ResourceAvailability)(ref BodyCatalog.availability)).CallWhenAvailable((Action)CrocoBlightSkin); } object obj = <>O.<2>__SpawnBlightPuddleInLobby; if (obj == null) { hook_OnEnable val = SpawnBlightPuddleInLobby; <>O.<2>__SpawnBlightPuddleInLobby = val; obj = (object)val; } CharacterSelectSurvivorPreviewDisplayController.OnEnable += (hook_OnEnable)obj; object obj2 = <>O.<3>__UpdateBlightPuddleLobby; if (obj2 == null) { hook_OnLoadoutChangedGlobal val2 = UpdateBlightPuddleLobby; <>O.<3>__UpdateBlightPuddleLobby = val2; obj2 = (object)val2; } CharacterSelectSurvivorPreviewDisplayController.OnLoadoutChangedGlobal += (hook_OnLoadoutChangedGlobal)obj2; } } private static void UpdateBlightPuddleLobby(orig_OnLoadoutChangedGlobal orig, CharacterSelectSurvivorPreviewDisplayController self, NetworkUser changedNetworkUser) { //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_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_0078: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self, changedNetworkUser); if (!((Object)(object)changedNetworkUser != (Object)(object)self.networkUser) && ((Object)self).name.StartsWith("CrocoD")) { Loadout loadout = self.networkUser.networkLoadout.loadout; BodyIndex val = BodyCatalog.FindBodyIndexCaseInsensitive("CrocoBody"); if (loadout != null && self.networkUser.bodyIndexPreference == val) { uint skillVariant = loadout.bodyLoadoutManager.GetSkillVariant(val, 0); bool flag = skillVariant == 1; bool active = justSpawned; justSpawned = false; Transform val2 = ((Component)self).transform.GetChild(0).Find("CrocoDisplaySpawnEffect(Clone)"); Transform val3 = ((Component)self).transform.GetChild(0).Find("SpawnEffect_Blight"); ((Component)val2).gameObject.SetActive(!flag); ((Component)val3).gameObject.SetActive(flag); ((Component)val2.GetChild(1)).gameObject.SetActive(active); ((Component)val3.GetChild(1)).gameObject.SetActive(active); } } } private static void SpawnBlightPuddleInLobby(orig_OnEnable orig, CharacterSelectSurvivorPreviewDisplayController self) { orig.Invoke(self); if (((Object)self).name.StartsWith("CrocoD")) { justSpawned = true; GameObject val = Object.Instantiate(Effects_Blight.lobbyPool, ((Component)self).transform.GetChild(0)); ((Object)val).name = "SpawnEffect_Blight"; } } public static void EffectReplacements() { //IL_0008: Unknown result type (might be due to invalid IL or missing references) //IL_000d: Unknown result type (might be due to invalid IL or missing references) //IL_0028: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_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_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) GameObject val = null; val = Addressables.LoadAssetAsync((object)"RoR2/Base/Croco/MuzzleflashCroco.prefab").WaitForCompletion(); EffectReplacer.SetupComponent(val, Effects_Blight.MuzzleflashCroco_Blight); val = Addressables.LoadAssetAsync((object)"RoR2/Base/Croco/CrocoDiseaseImpactEffect.prefab").WaitForCompletion(); EffectReplacer.SetupComponent(val, Effects_Blight.CrocoDiseaseImpactEffect_Blight); val = Addressables.LoadAssetAsync((object)"RoR2/Base/Croco/CrocoDiseaseOrbEffect.prefab").WaitForCompletion(); EffectReplacer.SetupComponent(val, Effects_Blight.CrocoDiseaseOrbEffect_Blight); val = Addressables.LoadAssetAsync((object)"RoR2/Base/Croco/CrocoLeapExplosion.prefab").WaitForCompletion(); EffectReplacer.SetupComponent(val, Effects_Blight.CrocoLeapExplosion_Blight); } public static void CrocoBlightSkin() { //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_001a: Unknown result type (might be due to invalid IL or missing references) //IL_001f: Unknown result type (might be due to invalid IL or missing references) //IL_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_00e7: Unknown result type (might be due to invalid IL or missing references) SkinDefParams val = Addressables.LoadAssetAsync((object)"e067d66a43eb8e245a1ecc10e24974bc").WaitForCompletion(); SkinDef val2 = Addressables.LoadAssetAsync((object)"186040c993aa5f240809215921b730be").WaitForCompletion(); int num = val.rendererInfos.Length; RendererInfo[] array = (RendererInfo[])(object)new RendererInfo[num]; Array.Copy(val.rendererInfos, array, num); Material val3 = Object.Instantiate(Addressables.LoadAssetAsync((object)"16459c0089d3ebd4198f3d43d5510301").WaitForCompletion()); val3.mainTexture = (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/SkinScalable/texCrocoDiffuseBlight.png"); val3.SetTexture("_EmTex", (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/SkinScalable/texCrocoEmissionBlight.png")); val3.SetTexture("_FlowHeightmap", (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/SkinScalable/texCrocoPoisonMaskBlight.png")); val3.SetTexture("_FlowHeightRamp", (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/SkinRamps/texRampCrocoDiseaseDarkLessDark.png")); val3.SetColor("_EmColor", new Color(1.2f, 1.2f, 0.75f, 1f)); array[0].defaultMaterial = val3; array[0].defaultMaterialAddress = null; array[1].defaultMaterial = Effects_Blight.matCrocoDiseaseDrippingsBlight; array[1].defaultMaterialAddress = null; SkinDef val4 = ScriptableObject.CreateInstance(); ((Object)val4).name = "skinCrocoDefault_Blight"; val4.nameToken = "SKIN_CROCO_BLIGHT"; val4.unlockableDef = LegacyResourcesAPI.Load("unlockabledefs/Skills.Croco.PassivePoisonLethal"); val4.icon = Assets.Bundle.LoadAsset("Assets/WQoL/General/texCrocoBlightSkin.png"); val4.rendererInfos = array; val4.rootObject = val2.rootObject; val4.baseSkins = (SkinDef[])(object)new SkinDef[1] { val2 }; Skins.AddSkinToCharacter(LegacyResourcesAPI.Load("Prefabs/CharacterBodies/CrocoBody"), val4); } } public static class Effects_Blight { public static Material matCrocoDiseaseDrippingsBlight; public static GameObject CrocoBiteEffectBlight = null; public static GameObject CrocoSlashBlight = null; public static GameObject CrocoComboFinisherSlashBlight = null; public static GameObject CrocoDiseaseOrbEffect_Blight = PrefabAPI.InstantiateClone(LegacyResourcesAPI.Load("Prefabs/effects/orbeffects/CrocoDiseaseOrbEffect"), "CrocoDiseaseOrbEffect_Blight", false); public static GameObject CrocoDiseaseGhostBlight = PrefabAPI.InstantiateClone(LegacyResourcesAPI.Load("Prefabs/projectileghosts/CrocoDiseaseGhost"), "CrocoDiseaseProjectileGhost_Blight", false); public static GameObject CrocoSpitGhostBlight = PrefabAPI.InstantiateClone(LegacyResourcesAPI.Load("Prefabs/projectileghosts/CrocoSpitGhost"), "CrocoSpitGhost_Blight", false); public static GameObject CrocoDiseaseImpactEffect_Blight = null; public static GameObject MuzzleflashCroco_Blight = null; public static GameObject CrocoLeapExplosion_Blight = PrefabAPI.InstantiateClone(LegacyResourcesAPI.Load("Prefabs/effects/impacteffects/CrocoLeapExplosion"), "CrocoLeapExplosion_Blight", false); public static GameObject CrocoFistEffectBlight = null; public static GameObject CrocoLeapAcid_GhostBlight = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Croco/CrocoLeapAcidGhost.prefab").WaitForCompletion(), "CrocoLeapAcidGhost_Blight", false); public static GameObject lobbyPool = null; public static void GhostReplacements() { //IL_006b: Unknown result type (might be due to invalid IL or missing references) //IL_0070: Unknown result type (might be due to invalid IL or missing references) GameObject val = LegacyResourcesAPI.Load("Prefabs/projectiles/CrocoDiseaseProjectile"); GameObject val2 = LegacyResourcesAPI.Load("Prefabs/projectiles/CrocoSpit"); ProjectileGhostReplacer projectileGhostReplacer = val.AddComponent(); ProjectileGhostReplacer projectileGhostReplacer2 = val2.AddComponent(); projectileGhostReplacer.condition = SkinChanges.Case.Acrid; projectileGhostReplacer2.condition = SkinChanges.Case.Acrid; projectileGhostReplacer2.ghostPrefab_1 = CrocoSpitGhostBlight; projectileGhostReplacer2.impactPrefab_1 = CrocoDiseaseImpactEffect_Blight; projectileGhostReplacer.ghostPrefab_1 = CrocoDiseaseGhostBlight; projectileGhostReplacer.impactPrefab_1 = CrocoDiseaseImpactEffect_Blight; projectileGhostReplacer.orbOnEnd = true; GameObject val3 = Addressables.LoadAssetAsync((object)"RoR2/Base/Croco/CrocoLeapAcid.prefab").WaitForCompletion(); ProjectileGhostReplacer projectileGhostReplacer3 = val3.AddComponent(); projectileGhostReplacer3.condition = SkinChanges.Case.Acrid; projectileGhostReplacer3.ghostPrefab_1 = CrocoLeapAcid_GhostBlight; projectileGhostReplacer3.useReplacement = false; } public static void Start() { //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_0028: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_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_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_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_00b0: Unknown result type (might be due to invalid IL or missing references) //IL_00b5: Unknown result type (might be due to invalid IL or missing references) CrocoFistEffectBlight = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Croco/CrocoFistEffect.prefab").WaitForCompletion(), "CrocoFistEffect_Blight", false); CrocoBiteEffectBlight = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Croco/CrocoBiteEffect.prefab").WaitForCompletion(), "CrocoBiteEffect_Blight", false); CrocoSlashBlight = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Croco/CrocoSlash.prefab").WaitForCompletion(), "CrocoSlashBlight", false); CrocoComboFinisherSlashBlight = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Croco/CrocoComboFinisherSlash.prefab").WaitForCompletion(), "CrocoComboFinisherSlash_Blight", false); CrocoDiseaseImpactEffect_Blight = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Croco/CrocoDiseaseImpactEffect.prefab").WaitForCompletion(), "CrocoDiseaseImpactEffect_Blight", false); MuzzleflashCroco_Blight = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Croco/MuzzleflashCroco.prefab").WaitForCompletion(), "MuzzleflashCroco_Blight", false); MakeEffects(); } public static void MakeEffects() { //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_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_00ab: Unknown result type (might be due to invalid IL or missing references) //IL_010d: Unknown result type (might be due to invalid IL or missing references) //IL_0132: 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_01a7: Unknown result type (might be due to invalid IL or missing references) //IL_0211: Unknown result type (might be due to invalid IL or missing references) //IL_0236: Unknown result type (might be due to invalid IL or missing references) //IL_02a0: Unknown result type (might be due to invalid IL or missing references) //IL_033f: 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_03e7: Unknown result type (might be due to invalid IL or missing references) //IL_0449: Unknown result type (might be due to invalid IL or missing references) //IL_04ae: Unknown result type (might be due to invalid IL or missing references) //IL_0503: Unknown result type (might be due to invalid IL or missing references) //IL_05a6: Unknown result type (might be due to invalid IL or missing references) //IL_061c: Unknown result type (might be due to invalid IL or missing references) //IL_0669: Unknown result type (might be due to invalid IL or missing references) //IL_075b: Unknown result type (might be due to invalid IL or missing references) //IL_0819: Unknown result type (might be due to invalid IL or missing references) //IL_0867: Unknown result type (might be due to invalid IL or missing references) //IL_08db: Unknown result type (might be due to invalid IL or missing references) //IL_090c: Unknown result type (might be due to invalid IL or missing references) //IL_0979: Unknown result type (might be due to invalid IL or missing references) //IL_0a1a: Unknown result type (might be due to invalid IL or missing references) //IL_0a1f: Unknown result type (might be due to invalid IL or missing references) //IL_0ac0: Unknown result type (might be due to invalid IL or missing references) //IL_0ac5: Unknown result type (might be due to invalid IL or missing references) //IL_0b2e: Unknown result type (might be due to invalid IL or missing references) //IL_0b33: Unknown result type (might be due to invalid IL or missing references) //IL_0b4b: Unknown result type (might be due to invalid IL or missing references) //IL_0b50: Unknown result type (might be due to invalid IL or missing references) //IL_0c06: Unknown result type (might be due to invalid IL or missing references) //IL_0c0b: Unknown result type (might be due to invalid IL or missing references) //IL_0cc0: Unknown result type (might be due to invalid IL or missing references) //IL_0cc5: Unknown result type (might be due to invalid IL or missing references) GameObject val = Addressables.LoadAssetAsync((object)"RoR2/Base/Croco/CrocoChainableFistEffect.prefab").WaitForCompletion(); Texture2D val2 = Assets.Bundle.LoadAsset("Assets/WQoL/SkinRamps/texRampCrocoDiseaseBlight.png"); Texture2D val3 = Assets.Bundle.LoadAsset("Assets/WQoL/SkinRamps/texRampCrocoDiseaseDarkDark.png"); Texture2D val4 = Assets.Bundle.LoadAsset("Assets/WQoL/SkinRamps/texRampCrocoDiseaseBlightAlt.png"); Texture2D val5 = Assets.Bundle.LoadAsset("Assets/WQoL/SkinRamps/texRampBeetleBreathBlight.png"); Color32 val6 = default(Color32); ((Color32)(ref val6))..ctor((byte)192, (byte)144, (byte)159, byte.MaxValue); Color32 val7 = default(Color32); ((Color32)(ref val7))..ctor(byte.MaxValue, (byte)223, (byte)240, byte.MaxValue); Color startColor = Color32.op_Implicit(new Color32((byte)185, (byte)22, (byte)179, byte.MaxValue)); Color val8 = default(Color); ((Color)(ref val8))..ctor(1.755f, 0.785f, 1.2f, 1f); Material val9 = Object.Instantiate(((Renderer)((Component)val.transform.GetChild(0)).GetComponent()).materials[0]); ((Object)val9).name = "matCrocoGooSmallBlight"; val9.SetColor("_EmissionColor", new Color(1.4f, 0.95f, 0.95f, 1f)); val9.SetColor("_TintColor", new Color(1.1f, 0.9f, 0.9f, 1f)); Material val10 = Object.Instantiate(((Renderer)((Component)val.transform.GetChild(0)).GetComponent()).materials[0]); ((Object)val10).name = "matCrocoGooSmallBlightD"; val10.SetColor("_EmissionColor", new Color(0.8f, 0.65f, 0.65f, 1f)); val10.SetColor("_TintColor", new Color(1f, 1f, 1f, 1f)); Material val11 = Object.Instantiate(((Renderer)((Component)CrocoBiteEffectBlight.transform.GetChild(2)).GetComponent()).materials[0]); ((Object)val11).name = "matCrocoGooLargeBlight"; val11.SetTexture("_RemapTex", val9.GetTexture("_RemapTex")); val11.SetColor("_EmissionColor", new Color(0.85f, 0.7f, 0.7f, 1f)); val11.SetColor("_TintColor", new Color(1f, 1f, 1f, 1f)); Material val12 = Object.Instantiate(((Renderer)((Component)CrocoDiseaseGhostBlight.transform.GetChild(0)).GetComponent()).materials[0]); ((Object)val12).name = "matCrocoDiseaseSporeBlight"; val12.SetTexture("_RemapTex", val9.GetTexture("_RemapTex")); val12.SetColor("_TintColor", new Color(1.7f, 0.8f, 1.25f, 1f)); matCrocoDiseaseDrippingsBlight = Object.Instantiate(((Renderer)((Component)CrocoSpitGhostBlight.transform.GetChild(3)).GetComponent()).materials[0]); ((Object)matCrocoDiseaseDrippingsBlight).name = "matCrocoDiseaseDrippingsBlight"; matCrocoDiseaseDrippingsBlight.SetTexture("_RemapTex", (Texture)(object)val5); Material val13 = Object.Instantiate(((Renderer)((Component)CrocoDiseaseGhostBlight.transform.GetChild(4).GetChild(0)).GetComponent()).materials[0]); ((Object)val13).name = "matCrocoDiseaseTrailBlight"; val13.SetTexture("_RemapTex", (Texture)(object)val4); val13.SetColor("_TintColor", val8); Material val14 = Object.Instantiate(((Renderer)((Component)CrocoDiseaseGhostBlight.transform.GetChild(4).GetChild(1)).GetComponent()).materials[0]); ((Object)val14).name = "matCrocoDiseaseTrailLesserBlight"; val14.SetTexture("_RemapTex", (Texture)(object)val4); val14.SetColor("_TintColor", val8); Material val15 = Object.Instantiate(((Renderer)((Component)CrocoDiseaseOrbEffect_Blight.transform.GetChild(1).GetChild(0)).GetComponent()).materials[0]); ((Object)val15).name = "matCrocoDiseaseTrailOrangeBlight"; val15.SetTexture("_RemapTex", (Texture)(object)val2); val15.SetColor("_TintColor", val8); Material val16 = Object.Instantiate(((Renderer)((Component)CrocoBiteEffectBlight.transform.GetChild(0)).GetComponent()).materials[0]); ((Object)val16).name = "matCrocoBiteDiseasedBlight"; val16.SetTexture("_RemapTex", (Texture)(object)val4); val16.SetColor("_TintColor", new Color(1.63f, 0.8f, 1.52f, 1f)); Material val17 = Object.Instantiate(((Renderer)((Component)CrocoDiseaseGhostBlight.transform.GetChild(2)).GetComponent()).materials[0]); ((Object)val17).name = "matCrocoDiseaseHeadBlight"; val17.SetTexture("_RemapTex", (Texture)(object)val3); val17.SetColor("_TintColor", new Color(2.5f, 1.5f, 1.5f, 1f)); Material val18 = Object.Instantiate(((Component)CrocoLeapAcid_GhostBlight.transform.GetChild(0).GetChild(0)).GetComponent().Material); ((Object)val18).name = "matCrocoGooDecalBlight"; val18.color = new Color(2f, 0.5f, 1.8f, 1.1f); Material val19 = Object.Instantiate(((Renderer)((Component)CrocoSlashBlight.transform.GetChild(0)).GetComponent()).sharedMaterial); val19.SetTexture("_RemapTex", (Texture)(object)val2); ((Renderer)((Component)CrocoSlashBlight.transform.GetChild(0)).GetComponent()).sharedMaterial = val19; Material val20 = Object.Instantiate(((Renderer)((Component)CrocoComboFinisherSlashBlight.transform.GetChild(0)).GetComponent()).sharedMaterial); val20.SetTexture("_RemapTex", (Texture)(object)val2); val20.SetColor("_TintColor", new Color(0.85f, 0.8f, 0.21f, 1f)); ((Renderer)((Component)CrocoComboFinisherSlashBlight.transform.GetChild(0)).GetComponent()).sharedMaterial = val20; ((Renderer)((Component)CrocoBiteEffectBlight.transform.GetChild(0)).GetComponent()).sharedMaterial = val16; ((Renderer)((Component)CrocoBiteEffectBlight.transform.GetChild(2)).GetComponent()).sharedMaterial = val11; ((Component)CrocoBiteEffectBlight.transform.GetChild(3)).GetComponent().startColor = startColor; ((Renderer)((Component)CrocoDiseaseGhostBlight.transform.GetChild(0)).GetComponent()).sharedMaterial = val12; ((Component)CrocoDiseaseGhostBlight.transform.GetChild(1)).GetComponent().color = new Color(0.949f, 0.8863f, 0f, 1f); ((Renderer)((Component)CrocoDiseaseGhostBlight.transform.GetChild(2)).GetComponent()).sharedMaterial = val17; ((Renderer)((Component)CrocoDiseaseGhostBlight.transform.GetChild(3)).GetComponent()).sharedMaterial = val9; ((Renderer)((Component)CrocoDiseaseGhostBlight.transform.GetChild(4).GetChild(0)).GetComponent()).sharedMaterial = val13; ((Renderer)((Component)CrocoDiseaseGhostBlight.transform.GetChild(4).GetChild(1)).GetComponent()).sharedMaterial = val14; ((Renderer)((Component)CrocoDiseaseGhostBlight.transform.GetChild(4).GetChild(2)).GetComponent()).sharedMaterial = val14; ((Renderer)((Component)CrocoSpitGhostBlight.transform.GetChild(0)).GetComponent()).sharedMaterial = val12; ((Component)CrocoSpitGhostBlight.transform.GetChild(1)).GetComponent().color = new Color(0.949f, 0.4596f, 0f, 1f); ((Renderer)((Component)CrocoSpitGhostBlight.transform.GetChild(2)).GetComponent()).sharedMaterial = val9; ((Renderer)((Component)CrocoSpitGhostBlight.transform.GetChild(3)).GetComponent()).sharedMaterial = matCrocoDiseaseDrippingsBlight; ((Renderer)((Component)CrocoSpitGhostBlight.transform.GetChild(6).GetChild(0)).GetComponent()).sharedMaterial = val13; ((Renderer)((Component)CrocoSpitGhostBlight.transform.GetChild(6).GetChild(1)).GetComponent()).sharedMaterial = val13; ((Renderer)((Component)CrocoDiseaseImpactEffect_Blight.transform.GetChild(0)).GetComponent()).sharedMaterial = val11; ((Component)CrocoDiseaseImpactEffect_Blight.transform.GetChild(1)).GetComponent().startColor = startColor; ((Renderer)((Component)CrocoDiseaseImpactEffect_Blight.transform.GetChild(2)).GetComponent()).sharedMaterial = val13; ((Component)CrocoDiseaseImpactEffect_Blight.transform.GetChild(3)).GetComponent().color = new Color(1f, 0.72f, 0f, 1f); ((Renderer)((Component)MuzzleflashCroco_Blight.transform.GetChild(0)).GetComponent()).sharedMaterial = val11; ((Renderer)((Component)MuzzleflashCroco_Blight.transform.GetChild(1)).GetComponent()).sharedMaterial = val9; ((Renderer)((Component)MuzzleflashCroco_Blight.transform.GetChild(2)).GetComponent()).sharedMaterial = val9; ((Component)MuzzleflashCroco_Blight.transform.GetChild(3)).GetComponent().startColor = startColor; ((Component)MuzzleflashCroco_Blight.transform.GetChild(4)).GetComponent().color = new Color(1f, 0.72f, 0f, 1f); ((Renderer)((Component)CrocoFistEffectBlight.transform.GetChild(0)).GetComponent()).sharedMaterial = val9; ((Renderer)((Component)CrocoFistEffectBlight.transform.GetChild(1)).GetComponent()).sharedMaterial = val13; ((Component)CrocoFistEffectBlight.transform.GetChild(2)).GetComponent().color = new Color(1f, 0.72f, 0f, 1f); ((Component)CrocoLeapAcid_GhostBlight.transform.GetChild(0).GetChild(0)).GetComponent().Material = val18; ((Renderer)((Component)CrocoLeapAcid_GhostBlight.transform.GetChild(0).GetChild(1)).GetComponent()).sharedMaterial = val12; ((Renderer)((Component)CrocoLeapAcid_GhostBlight.transform.GetChild(0).GetChild(2)).GetComponent()).sharedMaterial = matCrocoDiseaseDrippingsBlight; ((Component)CrocoLeapAcid_GhostBlight.transform.GetChild(0).GetChild(3)).GetComponent().color = Color32.op_Implicit(new Color32(byte.MaxValue, (byte)177, (byte)110, (byte)200)); ((Renderer)((Component)CrocoLeapExplosion_Blight.transform.GetChild(0)).GetComponent()).sharedMaterial = val10; ((Renderer)((Component)CrocoLeapExplosion_Blight.transform.GetChild(2)).GetComponent()).sharedMaterial = val11; ((Renderer)((Component)CrocoLeapExplosion_Blight.transform.GetChild(3)).GetComponent()).sharedMaterial = val11; ((Renderer)((Component)CrocoLeapExplosion_Blight.transform.GetChild(4)).GetComponent()).sharedMaterial = val12; ((Component)CrocoLeapExplosion_Blight.transform.GetChild(6)).GetComponent().color = Color32.op_Implicit(new Color32(byte.MaxValue, (byte)177, (byte)110, (byte)200)); ((Renderer)((Component)CrocoDiseaseOrbEffect_Blight.transform.GetChild(0).GetChild(0)).GetComponent()).sharedMaterial = val12; ((Renderer)((Component)CrocoDiseaseOrbEffect_Blight.transform.GetChild(1).GetChild(1)).GetComponent()).sharedMaterial = val14; CrocoDiseaseOrbEffect_Blight.GetComponent().endEffect = CrocoDiseaseImpactEffect_Blight; GameObject val21 = Addressables.LoadAssetAsync((object)"RoR2/Base/Croco/CrocoDisplay.prefab").WaitForCompletion(); val21.AddComponent(); GameObject val22 = Addressables.LoadAssetAsync((object)"RoR2/Base/Croco/CrocoDisplaySpawnEffect.prefab").WaitForCompletion(); lobbyPool = PrefabAPI.InstantiateClone(val22, "CrocoDisplaySpawnEffect_Blight", false); ((Component)lobbyPool.transform.GetChild(0).GetChild(0)).GetComponent().Material = val18; ((Renderer)((Component)lobbyPool.transform.GetChild(0).GetChild(1)).GetComponent()).material = val12; ((Renderer)((Component)lobbyPool.transform.GetChild(0).GetChild(2)).GetComponent()).material = matCrocoDiseaseDrippingsBlight; ((Component)lobbyPool.transform.GetChild(0).GetChild(3)).GetComponent().color = Color32.op_Implicit(new Color32(byte.MaxValue, (byte)200, (byte)150, byte.MaxValue)); ((Renderer)((Component)lobbyPool.transform.GetChild(1).GetChild(3).GetChild(0)).GetComponent()).material = val10; ((Renderer)((Component)lobbyPool.transform.GetChild(1).GetChild(3).GetChild(1)).GetComponent()).material = val11; ((Renderer)((Component)lobbyPool.transform.GetChild(1).GetChild(3).GetChild(2)).GetComponent()).material = val12; ((Component)lobbyPool.transform.GetChild(1).GetChild(3).GetChild(3)).GetComponent().color = Color32.op_Implicit(new Color32(byte.MaxValue, (byte)177, (byte)110, (byte)200)); lobbyPool.SetActive(false); Object.Destroy((Object)(object)lobbyPool.GetComponent()); } } public static class EliteBell { [CompilerGenerated] private static class <>O { public static Manipulator <0>__BellBalls_ChargeTrioBomb_FixedUpdate; } public static GameObject BellBallGhostElite; public static void Start() { //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_007e: Expected O, but got Unknown if (WConfig.cfgSkinBellBalls.Value) { GameObject val = LegacyResourcesAPI.Load("Prefabs/projectiles/BellBall"); ProjectileGhostReplacer projectileGhostReplacer = val.AddComponent(); BellBallGhostElite = PrefabAPI.InstantiateClone(LegacyResourcesAPI.Load("Prefabs/projectileghosts/BellBallGhost"), "BellBallGhostElite", false); projectileGhostReplacer.condition = SkinChanges.Case.Brass; projectileGhostReplacer.ghostPrefab_1 = BellBallGhostElite; BellBallGhostElite.AddComponent().DoNotPool = true; object obj = <>O.<0>__BellBalls_ChargeTrioBomb_FixedUpdate; if (obj == null) { Manipulator val2 = BellBalls_ChargeTrioBomb_FixedUpdate; <>O.<0>__BellBalls_ChargeTrioBomb_FixedUpdate = val2; obj = (object)val2; } ChargeTrioBomb.FixedUpdate += (Manipulator)obj; } } private static void BellBalls_ChargeTrioBomb_FixedUpdate(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown //IL_003d: Unknown result type (might be due to invalid IL or missing references) ILCursor val = new ILCursor(il); if (val.TryGotoNext((MoveType)0, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchStloc(x, 1) })) { val.Emit(OpCodes.Ldarg_0); val.EmitDelegate>((Func)delegate(GameObject ballPrep, ChargeTrioBomb entityState) { //IL_002d: Unknown result type (might be due to invalid IL or missing references) if (((EntityState)entityState).characterBody.isElite) { ((Renderer)((Component)ballPrep.transform.GetChild(0)).GetComponent()).material = ((Renderer)((EntityState)entityState).characterBody.inventory.currentEquipmentState.equipmentDef.pickupModelPrefab.GetComponentInChildren()).material; } return ballPrep; }); } else { Log.LogWarning("IL Failed: IL.EntityStates.Bell.BellWeapon.ChargeTrioBomb.FixedUpdate"); } } } public static class EliteEffects { public class CopyEliteShaderToGhost : MonoBehaviour { public void Start() { ProjectileController component = ((Component)this).GetComponent(); if (!Object.op_Implicit((Object)(object)component.ghost) || !Object.op_Implicit((Object)(object)component.owner)) { return; } ModelLocator component2 = component.owner.GetComponent(); if (!Object.op_Implicit((Object)(object)component2)) { return; } Transform modelTransform = component2.modelTransform; if (Object.op_Implicit((Object)(object)modelTransform)) { CharacterModel component3 = ((Component)modelTransform).GetComponent(); if (Object.op_Implicit((Object)(object)component3)) { ((Renderer)((Component)component.ghost).GetComponentInChildren()).material.SetFloat("_EliteIndex", (float)(component3.shaderEliteRampIndex + 1)); } } } } public class CopyEliteIndexAlt : MonoBehaviour { public Renderer renderer; public Material material; public void OnDisable() { ProjectileController component = ((Component)this).GetComponent(); if (!Object.op_Implicit((Object)(object)component.ghost) || !Object.op_Implicit((Object)(object)component.owner)) { return; } ModelLocator component2 = component.owner.GetComponent(); if (!Object.op_Implicit((Object)(object)component2)) { return; } Transform modelTransform = component2.modelTransform; if (Object.op_Implicit((Object)(object)modelTransform)) { CharacterModel component3 = ((Component)modelTransform).GetComponent(); if (Object.op_Implicit((Object)(object)component3)) { renderer.material = material; renderer.material.SetFloat("_EliteIndex", (float)(component3.shaderEliteRampIndex + 1)); } } } } [CompilerGenerated] private static class <>O { public static Manipulator <0>__BellBalls_ChargeTrioBomb_FixedUpdate; } public static void Start() { //IL_001f: Unknown result type (might be due to invalid IL or missing references) //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_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_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_005b: Unknown result type (might be due to invalid IL or missing references) //IL_0060: Unknown result type (might be due to invalid IL or missing references) //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_00e0: Unknown result type (might be due to invalid IL or missing references) //IL_00e5: Unknown result type (might be due to invalid IL or missing references) //IL_00eb: Expected O, but got Unknown if (WConfig.cfgSkinBellBalls.Value) { GameObject val = Addressables.LoadAssetAsync((object)"99151650efe03be4c9a332ffe1466cb2").WaitForCompletion(); GameObject val2 = Addressables.LoadAssetAsync((object)"30f2aa5ecd9832b4f82b1eb537c6dedf").WaitForCompletion(); GameObject val3 = Addressables.LoadAssetAsync((object)"44b979afbdb688c438bd14bcf12e249f").WaitForCompletion(); GameObject val4 = Addressables.LoadAssetAsync((object)"9858bb44cb951674f813a6a0d033e799").WaitForCompletion(); val.AddComponent(); val2.AddComponent().DoNotPool = true; val4.GetComponent().DoNotPool = true; val3.AddComponent(); val3.GetComponent().renderer = ((Component)val4.transform.GetChild(0).GetChild(0)).GetComponent(); val3.GetComponent().material = Addressables.LoadAssetAsync((object)"a56bd29548ccd9e439c5da67285a6281").WaitForCompletion(); object obj = <>O.<0>__BellBalls_ChargeTrioBomb_FixedUpdate; if (obj == null) { Manipulator val5 = BellBalls_ChargeTrioBomb_FixedUpdate; <>O.<0>__BellBalls_ChargeTrioBomb_FixedUpdate = val5; obj = (object)val5; } ChargeTrioBomb.FixedUpdate += (Manipulator)obj; } } private static void BellBalls_ChargeTrioBomb_FixedUpdate(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown //IL_003d: Unknown result type (might be due to invalid IL or missing references) ILCursor val = new ILCursor(il); if (val.TryGotoNext((MoveType)0, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchStloc(x, 1) })) { val.Emit(OpCodes.Ldarg_0); val.EmitDelegate>((Func)delegate(GameObject ballPrep, ChargeTrioBomb entityState) { if (((EntityState)entityState).characterBody.isElite) { ((Component)ballPrep.transform.GetChild(0)).GetComponent().material.SetFloat("_EliteIndex", (float)(((Component)((EntityState)entityState).GetModelTransform()).GetComponent().shaderEliteRampIndex + 1)); } return ballPrep; }); } else { Log.LogWarning("IL Failed: IL.EntityStates.Bell.BellWeapon.ChargeTrioBomb.FixedUpdate"); } } } public static class InteractableSkins { public static void Start() { //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) SkinnedMeshRenderer component = ((Component)Addressables.LoadAssetAsync((object)"7d97551ee4c1e904b9a225abc63c3f0d").WaitForCompletion().transform.GetChild(0).GetChild(1)).GetComponent(); Material val = Object.Instantiate(((Renderer)component).material); val.SetFloat("_Magnitude", 2f); ((Renderer)component).material = val; } } public static class Merc_Blue { public static GameObject MercExposeEffect = LegacyResourcesAPI.Load("Prefabs/temporaryvisualeffects/MercExposeEffect"); public static GameObject MercExposeConsumeEffect = LegacyResourcesAPI.Load("Prefabs/effects/impacteffects/MercExposeConsumeEffect"); } public static class Merc_Green { public static Material matMercEnergized_Green = Object.Instantiate(LegacyResourcesAPI.Load("materials/matMercEnergized")); public static Material matMercEvisTarget_Green = Object.Instantiate(LegacyResourcesAPI.Load("materials/matMercEvisTarget")); public static Material matHuntressFlashBright_Green = Object.Instantiate(LegacyResourcesAPI.Load("materials/matHuntressFlashBright")); public static Material matHuntressFlashExpanded_Green = Object.Instantiate(LegacyResourcesAPI.Load("materials/matHuntressFlashExpanded")); public static GameObject MercFocusedAssaultOrbEffect_Green = PrefabAPI.InstantiateClone(LegacyResourcesAPI.Load("Prefabs/effects/orbeffects/MercFocusedAssaultOrbEffect"), "MercFocusedAssaultOrbEffect_Green", false); public static GameObject OmniImpactVFXSlashMerc_Green = null; public static GameObject MercSwordSlash_Green = null; public static GameObject MercSwordFinisherSlash_Green = null; public static GameObject MercSwordSlashWhirlwind_Green = null; public static GameObject MercDashHitOverlay_Green = null; public static GameObject HuntressBlinkEffect_Green = PrefabAPI.InstantiateClone(LegacyResourcesAPI.Load("Prefabs/effects/HuntressBlinkEffect"), "HuntressBlinkEffect_Green", false); public static GameObject HuntressFireArrowRain_Green = PrefabAPI.InstantiateClone(LegacyResourcesAPI.Load("Prefabs/effects/muzzleflashes/HuntressFireArrowRain"), "HuntressFireArrowRain_Green", false); public static GameObject OmniImpactVFXSlashMercEvis_Green = PrefabAPI.InstantiateClone(LegacyResourcesAPI.Load("Prefabs/effects/omnieffect/OmniImpactVFXSlashMercEvis"), "OmniImpactVFXSlashMercEvis_Green", false); public static GameObject MercSwordUppercutSlash_Green = null; public static GameObject ImpactMercFocusedAssault_Green = null; public static GameObject ImpactMercAssaulter_Green = null; public static GameObject MercAssaulterEffect_Green = null; public static GameObject EvisProjectileGhost_Green = PrefabAPI.InstantiateClone(LegacyResourcesAPI.Load("Prefabs/projectileghosts/EvisProjectileGhost"), "EvisProjectileGhost_Green", false); public static GameObject EvisOverlapProjectileGhost_Green = PrefabAPI.InstantiateClone(LegacyResourcesAPI.Load("Prefabs/projectileghosts/EvisOverlapProjectileGhost"), "EvisOverlapProjectileGhost_Green", false); public static GameObject ImpactMercEvis_Green = PrefabAPI.InstantiateClone(LegacyResourcesAPI.Load("Prefabs/effects/impacteffects/ImpactMercEvis"), "ImpactMercEvis_Green", false); public static GameObject MercExposeEffect_Green; public static GameObject MercExposeConsumeEffect_Green; public static Material matMercIgnition_Green = null; public static void Start() { //IL_0030: Unknown result type (might be due to invalid IL or missing references) //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_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_0074: Unknown result type (might be due to invalid IL or missing references) //IL_0079: Unknown result type (might be due to invalid IL or missing references) //IL_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_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_00da: Unknown result type (might be due to invalid IL or missing references) //IL_00df: Unknown result type (might be due to invalid IL or missing references) //IL_00fc: Unknown result type (might be due to invalid IL or missing references) //IL_0101: Unknown result type (might be due to invalid IL or missing references) //IL_011e: Unknown result type (might be due to invalid IL or missing references) //IL_0123: Unknown result type (might be due to invalid IL or missing references) //IL_0140: Unknown result type (might be due to invalid IL or missing references) //IL_0145: Unknown result type (might be due to invalid IL or missing references) MercExposeEffect_Green = PrefabAPI.InstantiateClone(Merc_Blue.MercExposeEffect, "MercExposeEffect_Green", false); MercExposeConsumeEffect_Green = PrefabAPI.InstantiateClone(Merc_Blue.MercExposeConsumeEffect, "MercExposeConsumeEffect_Green", false); MercSwordSlash_Green = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/MercSwordSlash.prefab").WaitForCompletion(), "MercSwordSlash_Green", false); MercSwordFinisherSlash_Green = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/MercSwordFinisherSlash.prefab").WaitForCompletion(), "MercSwordFinisherSlash_Green", false); MercSwordSlashWhirlwind_Green = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/MercSwordSlashWhirlwind.prefab").WaitForCompletion(), "MercSwordSlashWhirlwind_Green", false); MercSwordUppercutSlash_Green = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/MercSwordUppercutSlash.prefab").WaitForCompletion(), "MercSwordUppercutSlash_Green", false); OmniImpactVFXSlashMerc_Green = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/OmniImpactVFXSlashMerc.prefab").WaitForCompletion(), "OmniImpactVFXSlashMerc_Green", false); MercAssaulterEffect_Green = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/MercAssaulterEffect.prefab").WaitForCompletion(), "MercAssaulterEffect_Green", false); MercDashHitOverlay_Green = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/MercDashHitOverlay.prefab").WaitForCompletion(), "MercDashHitOverlay_Green", false); ImpactMercAssaulter_Green = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/ImpactMercAssaulter.prefab").WaitForCompletion(), "ImpactMercAssaulter_Green", false); ImpactMercFocusedAssault_Green = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/ImpactMercFocusedAssault.prefab").WaitForCompletion(), "ImpactMercFocusedAssault_Green", false); } [Obsolete] public static void Merc_GreenEffects() { //IL_0047: 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_00fe: 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_019a: 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_036b: Unknown result type (might be due to invalid IL or missing references) //IL_03a3: Unknown result type (might be due to invalid IL or missing references) //IL_03db: Unknown result type (might be due to invalid IL or missing references) //IL_043e: Unknown result type (might be due to invalid IL or missing references) //IL_047f: Unknown result type (might be due to invalid IL or missing references) //IL_04b3: Unknown result type (might be due to invalid IL or missing references) //IL_0557: Unknown result type (might be due to invalid IL or missing references) //IL_058f: Unknown result type (might be due to invalid IL or missing references) //IL_05e8: Unknown result type (might be due to invalid IL or missing references) //IL_0620: Unknown result type (might be due to invalid IL or missing references) //IL_071f: Unknown result type (might be due to invalid IL or missing references) //IL_0783: Unknown result type (might be due to invalid IL or missing references) //IL_07c8: Unknown result type (might be due to invalid IL or missing references) //IL_0806: Unknown result type (might be due to invalid IL or missing references) //IL_0813: Unknown result type (might be due to invalid IL or missing references) //IL_0818: Unknown result type (might be due to invalid IL or missing references) //IL_0856: Unknown result type (might be due to invalid IL or missing references) //IL_0970: Unknown result type (might be due to invalid IL or missing references) //IL_0a5d: Unknown result type (might be due to invalid IL or missing references) //IL_0af5: Unknown result type (might be due to invalid IL or missing references) //IL_0b29: Unknown result type (might be due to invalid IL or missing references) //IL_0bb4: Unknown result type (might be due to invalid IL or missing references) //IL_0be8: Unknown result type (might be due to invalid IL or missing references) //IL_0cad: Unknown result type (might be due to invalid IL or missing references) //IL_0d0d: Unknown result type (might be due to invalid IL or missing references) //IL_0de9: Unknown result type (might be due to invalid IL or missing references) //IL_0e8c: Unknown result type (might be due to invalid IL or missing references) Material val = null; Material val2 = null; Material val3 = null; Material val4 = null; Material val5 = null; Material val6 = null; Material val7 = null; Material particleSystemOverrideMaterial = null; Material val8 = null; Material particleSystemOverrideMaterial2 = null; Material val9 = LegacyResourcesAPI.Load("materials/matMercHologram"); matHuntressFlashBright_Green.SetColor("_TintColor", new Color(0.6f, 1.3f, 0.6f, 1f)); matHuntressFlashExpanded_Green.SetColor("_TintColor", new Color(0.2f, 0.58f, 0.2f, 1f)); Texture2D val10 = Assets.Bundle.LoadAsset("Assets/WQoL/SkinRamps/texRampFallbootsGreen.png"); Texture2D val11 = Assets.Bundle.LoadAsset("Assets/WQoL/SkinRamps/texRampMercDustGreen.png"); Texture2D val12 = Assets.Bundle.LoadAsset("Assets/WQoL/SkinRamps/texRampHuntressSoftGreen.png"); Texture2D val13 = Assets.Bundle.LoadAsset("Assets/WQoL/SkinRamps/texRampHuntressGreen.png"); matMercEvisTarget_Green = Object.Instantiate(LegacyResourcesAPI.Load("Materials/matMercEvisTarget")); matMercEvisTarget_Green.SetTexture("_RemapTex", (Texture)(object)val12); matMercEvisTarget_Green.SetColor("_TintColor", new Color(0.35f, 0.44f, 0f)); ParticleSystemRenderer component = ((Component)MercSwordSlash_Green.transform.GetChild(0)).GetComponent(); val4 = Object.Instantiate(((Renderer)component).material); val4.SetTexture("_RemapTex", (Texture)(object)val10); val4.SetColor("_TintColor", new Color(0f, 1f, 0f, 1f)); ((Renderer)component).material = val4; ParticleSystem component2 = ((Component)MercSwordFinisherSlash_Green.transform.GetChild(0)).GetComponent(); component2.startColor = new Color(0.2f, 1f, 0.2f, 1f); ParticleSystemRenderer component3 = ((Component)MercSwordFinisherSlash_Green.transform.GetChild(1)).GetComponent(); val5 = Object.Instantiate(((Renderer)component3).material); val5.SetTexture("_RemapTex", (Texture)(object)val10); val5.SetColor("_TintColor", new Color(0.22f, 1f, 0.22f, 1f)); ((Renderer)component3).material = val5; ParticleSystemRenderer component4 = ((Component)MercSwordSlashWhirlwind_Green.transform.GetChild(0)).GetComponent(); ((Renderer)component4).material = val4; ParticleSystemRenderer component5 = ((Component)MercSwordUppercutSlash_Green.transform.GetChild(0)).GetComponent(); ParticleSystemRenderer component6 = ((Component)MercSwordUppercutSlash_Green.transform.GetChild(1)).GetComponent(); ((Renderer)component5).material = val5; ((Renderer)component6).material = val4; OmniEffect component7 = OmniImpactVFXSlashMerc_Green.GetComponent(); Material val14 = Object.Instantiate(component7.omniEffectGroups[3].omniEffectElements[1].particleSystemOverrideMaterial); val14.SetTexture("_RemapTex", (Texture)(object)val11); component7.omniEffectGroups[3].omniEffectElements[1].particleSystemOverrideMaterial = val14; Material val15 = Object.Instantiate(component7.omniEffectGroups[4].omniEffectElements[1].particleSystemOverrideMaterial); val15.SetTexture("_RemapTex", (Texture)(object)val11); component7.omniEffectGroups[4].omniEffectElements[1].particleSystemOverrideMaterial = val15; Material val16 = Object.Instantiate(component7.omniEffectGroups[6].omniEffectElements[0].particleSystemOverrideMaterial); val16.SetTexture("_RemapTex", (Texture)(object)val11); component7.omniEffectGroups[6].omniEffectElements[0].particleSystemOverrideMaterial = val16; ParticleSystem component8 = ((Component)OmniImpactVFXSlashMerc_Green.transform.GetChild(1)).GetComponent(); component8.startColor = new Color(0.3f, 0.7264f, 0.3f, 1f); ParticleSystem component9 = ((Component)OmniImpactVFXSlashMerc_Green.transform.GetChild(2)).GetComponent(); component9.startColor = new Color(0.2f, 0.9333f, 0.2f, 1f); ParticleSystem component10 = ((Component)OmniImpactVFXSlashMerc_Green.transform.GetChild(3)).GetComponent(); component10.startColor = new Color(0.4245f, 0.5f, 0.0501f, 1f); ParticleSystemRenderer component11 = ((Component)MercAssaulterEffect_Green.transform.GetChild(5)).GetComponent(); matMercIgnition_Green = Object.Instantiate(((Renderer)component11).material); matMercIgnition_Green.SetTexture("_RemapTex", (Texture)(object)val13); matMercIgnition_Green.SetColor("_TintColor", new Color(0.06f, 0.8867924f, 0.06f, 1f)); ((Renderer)component11).material = matMercIgnition_Green; ((Component)MercAssaulterEffect_Green.transform.GetChild(6)).GetComponent().startColor = new Color(0.3f, 1f, 0.3f, 1f); ((Component)MercAssaulterEffect_Green.transform.GetChild(8)).GetComponent().color = new Color(0.3765f, 0.9804f, 0.4868f, 1f); ((Renderer)((Component)MercAssaulterEffect_Green.transform.GetChild(9)).GetComponent()).material = val4; ((Renderer)((Component)MercAssaulterEffect_Green.transform.GetChild(10).GetChild(2)).GetComponent()).material = matMercIgnition_Green; ((Renderer)((Component)MercAssaulterEffect_Green.transform.GetChild(10).GetChild(3)).GetComponent()).material = matMercIgnition_Green; ParticleSystem component12 = ((Component)ImpactMercAssaulter_Green.transform.GetChild(0)).GetComponent(); component12.startColor = new Color(0.45f, 1f, 0.45f, 1f); component12 = ((Component)ImpactMercAssaulter_Green.transform.GetChild(1)).GetComponent(); component12.startColor = new Color(0.575f, 1f, 0.575f, 1f); ParticleSystemRenderer component13 = ((Component)ImpactMercAssaulter_Green.transform.GetChild(2)).GetComponent(); ((Renderer)component13).material = val4; component12 = ((Component)ImpactMercFocusedAssault_Green.transform.GetChild(0)).GetComponent(); component12.startColor = new Color(0.45f, 1f, 0.45f, 0.2667f); component12 = ((Component)ImpactMercFocusedAssault_Green.transform.GetChild(1)).GetComponent(); component12.startColor = new Color(0.26f, 0.934f, 0.26f, 1f); component13 = ((Component)ImpactMercFocusedAssault_Green.transform.GetChild(2)).GetComponent(); val6 = Object.Instantiate(((Renderer)component13).material); val6.SetTexture("_RemapTex", (Texture)(object)val11); ((Renderer)component13).material = val6; component13 = ((Component)MercFocusedAssaultOrbEffect_Green.transform.GetChild(0)).GetComponent(); val = Object.Instantiate(((Renderer)component13).material); val.SetTexture("_RemapTex", (Texture)(object)val11); ((Renderer)component13).material = val; component13 = ((Component)MercFocusedAssaultOrbEffect_Green.transform.GetChild(1)).GetComponent(); val2 = Object.Instantiate(((Renderer)component13).material); val2.SetTexture("_RemapTex", (Texture)(object)val11); ((Renderer)component13).material = val2; component13 = ((Component)MercFocusedAssaultOrbEffect_Green.transform.GetChild(2)).GetComponent(); val3 = Object.Instantiate(((Renderer)component13).material); val3.SetColor("_TintColor", new Color(-2f, 3f, -2f, 0.9f)); ((Renderer)component13).material = val3; component13 = ((Component)MercFocusedAssaultOrbEffect_Green.transform.GetChild(3)).GetComponent(); val7 = Object.Instantiate(((Renderer)component13).material); val7.SetTexture("_RemapTex", (Texture)(object)val13); val7.SetColor("_TintColor", new Color(0.06f, 0.8868f, 0.06f, 1f)); ((Renderer)component13).material = val7; matMercEnergized_Green.SetTexture("_RemapTex", (Texture)(object)val12); matMercEnergized_Green.SetColor("_TintColor", new Color(0.35f, 1.8f, 0.35f, 1f)); component12 = ((Component)HuntressBlinkEffect_Green.transform.GetChild(0).GetChild(0)).GetComponent(); component12.startColor = new Color(0.154f, 0.6324f, 0.154f, 1f); ColorOverLifetimeModule colorOverLifetime = component12.colorOverLifetime; ((ColorOverLifetimeModule)(ref colorOverLifetime)).enabled = false; Light component14 = ((Component)HuntressBlinkEffect_Green.transform.GetChild(0).GetChild(2)).GetComponent(); component14.color = new Color(0.6f, 1f, 0.6f, 1f); component13 = ((Component)HuntressBlinkEffect_Green.transform.GetChild(0).GetChild(4)).GetComponent(); Material val17 = Object.Instantiate(((Renderer)component13).material); val17.SetTexture("_RemapTex", (Texture)(object)val12); ((Renderer)component13).material = val17; component13 = ((Component)HuntressBlinkEffect_Green.transform.GetChild(0).GetChild(5)).GetComponent(); ((Renderer)component13).material = val17; component13 = ((Component)HuntressFireArrowRain_Green.transform.GetChild(2)).GetComponent(); ((Renderer)component13).material = val17; component13 = ((Component)HuntressFireArrowRain_Green.transform.GetChild(3)).GetComponent(); ((Renderer)component13).material = val17; component13 = ((Component)HuntressFireArrowRain_Green.transform.GetChild(4)).GetComponent(); Material val18 = Object.Instantiate(((Renderer)component13).material); val18.SetTexture("_RemapTex", (Texture)(object)val13); ((Renderer)component13).material = val18; component14 = ((Component)HuntressFireArrowRain_Green.transform.GetChild(5)).GetComponent(); component14.color = new Color(0.55f, 1f, 0.55f, 1f); OmniEffect component15 = OmniImpactVFXSlashMercEvis_Green.GetComponent(); component15.omniEffectGroups[1].omniEffectElements[0].particleSystemOverrideMaterial = particleSystemOverrideMaterial2; val8 = Object.Instantiate(component15.omniEffectGroups[3].omniEffectElements[1].particleSystemOverrideMaterial); val8.SetTexture("_RemapTex", (Texture)(object)val11); component15.omniEffectGroups[3].omniEffectElements[1].particleSystemOverrideMaterial = val8; component15.omniEffectGroups[4].omniEffectElements[1].particleSystemOverrideMaterial = particleSystemOverrideMaterial; component15.omniEffectGroups[6].omniEffectElements[0].particleSystemOverrideMaterial = val16; component13 = ((Component)OmniImpactVFXSlashMercEvis_Green.transform.GetChild(7)).GetComponent(); val9 = Object.Instantiate(((Renderer)component13).material); val9.SetTexture("_RemapTex", (Texture)(object)val10); val9.SetColor("_TintColor", new Color(-0.25f, 1.825f, 0f, 1f)); ((Renderer)component13).material = val9; ((Renderer)((Component)EvisProjectileGhost_Green.transform.GetChild(0)).GetComponent()).material = val5; ((Renderer)((Component)EvisProjectileGhost_Green.transform.GetChild(1)).GetComponent()).material = val4; ((Renderer)((Component)EvisProjectileGhost_Green.transform.GetChild(2)).GetComponent()).material = matMercIgnition_Green; ((Component)EvisProjectileGhost_Green.transform.GetChild(3)).GetComponent().startColor = new Color(0f, 1f, 0f, 1f); ((Component)EvisProjectileGhost_Green.transform.GetChild(5)).GetComponent().color = new Color(0.3f, 1f, 0.3f, 1f); ((Renderer)((Component)EvisOverlapProjectileGhost_Green.transform.GetChild(0)).GetComponent()).material = val5; ((Renderer)((Component)EvisOverlapProjectileGhost_Green.transform.GetChild(1)).GetComponent()).material = val8; ((Renderer)((Component)EvisOverlapProjectileGhost_Green.transform.GetChild(2)).GetComponent()).material = val16; ((Component)EvisOverlapProjectileGhost_Green.transform.GetChild(3)).GetComponent().startColor = new Color(0.51f, 1f, 0.51f, 1f); ((Component)EvisOverlapProjectileGhost_Green.transform.GetChild(4)).GetComponent().color = new Color(0.3f, 1f, 0.3f, 1f); ((Renderer)((Component)EvisOverlapProjectileGhost_Green.transform.GetChild(5)).GetComponent()).material = val9; ((Renderer)((Component)EvisOverlapProjectileGhost_Green.transform.GetChild(6)).GetComponent()).material = val9; ((Renderer)((Component)ImpactMercEvis_Green.transform.GetChild(0)).GetComponent()).material = val9; ((Renderer)((Component)ImpactMercEvis_Green.transform.GetChild(1)).GetComponent()).material = val4; ((Renderer)((Component)ImpactMercEvis_Green.transform.GetChild(2)).GetComponent()).material = val4; ((Component)ImpactMercEvis_Green.transform.GetChild(3)).GetComponent().color = new Color(0.425f, 1f, 0.425f, 1f); component13 = ((Component)MercExposeEffect_Green.transform.GetChild(0).GetChild(0)).GetComponent(); Material val19 = Object.Instantiate(((Renderer)component13).material); val19.SetTexture("_RemapTex", (Texture)(object)val13); val19.SetColor("_TintColor", new Color(-1f, 0.25f, -1f, 1f)); ((Renderer)component13).material = val19; component13 = ((Component)MercExposeEffect_Green.transform.GetChild(0).GetChild(1)).GetComponent(); ((Renderer)component13).material = val3; component13 = ((Component)MercExposeConsumeEffect_Green.transform.GetChild(0).GetChild(0)).GetComponent(); ((Renderer)component13).material = val19; component13 = ((Component)MercExposeConsumeEffect_Green.transform.GetChild(0).GetChild(2)).GetComponent(); ((Renderer)component13).material = val7; ((Renderer)((Component)MercExposeEffect_Green.transform.GetChild(0).GetChild(0)).GetComponent()).material = val19; ((Component)MercExposeEffect_Green.transform.GetChild(0).GetChild(1)).GetComponent().startColor = new Color(0.1f, 0.23f, 0.08f, 0.29f); ((Renderer)((Component)MercExposeEffect_Green.transform.GetChild(0).GetChild(1)).GetComponent()).material = val3; ((Renderer)((Component)MercExposeConsumeEffect_Green.transform.GetChild(0).GetChild(0)).GetComponent()).material = val19; ((Renderer)((Component)MercExposeConsumeEffect_Green.transform.GetChild(0).GetChild(1)).GetComponent()).material = val3; ((Component)MercExposeConsumeEffect_Green.transform.GetChild(0).GetChild(1)).GetComponent().startColor = new Color(0.2f, 0.35f, 0.2f, 0.175f); ((Renderer)((Component)MercExposeConsumeEffect_Green.transform.GetChild(0).GetChild(2)).GetComponent()).material = val19; } } public static class Merc_Pink { public static Material matMercEnergized_Pink = Object.Instantiate(LegacyResourcesAPI.Load("Materials/matMercEnergized")); public static Material matMercEvisTarget_Pink = Object.Instantiate(LegacyResourcesAPI.Load("materials/matMercEvisTarget")); public static Material matHuntressFlashBright_Pink = Object.Instantiate(LegacyResourcesAPI.Load("materials/matHuntressFlashBright")); public static Material matHuntressFlashExpanded_Pink = Object.Instantiate(LegacyResourcesAPI.Load("materials/matHuntressFlashExpanded")); public static GameObject MercFocusedAssaultOrbEffect_Pink = PrefabAPI.InstantiateClone(LegacyResourcesAPI.Load("Prefabs/effects/orbeffects/MercFocusedAssaultOrbEffect"), "MercFocusedAssaultOrbEffect_Pink", false); public static GameObject OmniImpactVFXSlashMerc_Pink = null; public static GameObject MercSwordSlash_Pink = null; public static GameObject MercSwordFinisherSlash_Pink = null; public static GameObject MercSwordSlashWhirlwind_Pink = null; public static GameObject MercDashHitOverlay_Pink = null; public static GameObject HuntressBlinkEffect_Pink = PrefabAPI.InstantiateClone(LegacyResourcesAPI.Load("Prefabs/effects/HuntressBlinkEffect"), "HuntressBlinkEffect_Pink", false); public static GameObject HuntressFireArrowRain_Pink = PrefabAPI.InstantiateClone(LegacyResourcesAPI.Load("Prefabs/effects/muzzleflashes/HuntressFireArrowRain"), "HuntressFireArrowRain_Pink", false); public static GameObject OmniImpactVFXSlashMercEvis_Pink = PrefabAPI.InstantiateClone(LegacyResourcesAPI.Load("Prefabs/effects/omnieffect/OmniImpactVFXSlashMercEvis"), "OmniImpactVFXSlashMercEvis_Pink", false); public static GameObject MercSwordUppercutSlash_Pink = null; public static GameObject ImpactMercFocusedAssault_Pink = null; public static GameObject ImpactMercAssaulter_Pink = null; public static GameObject MercAssaulterEffect_Pink = null; public static GameObject EvisProjectileGhost_Pink = PrefabAPI.InstantiateClone(LegacyResourcesAPI.Load("Prefabs/projectileghosts/EvisProjectileGhost"), "EvisProjectileGhost_Pink", false); public static GameObject EvisOverlapProjectileGhost_Pink = PrefabAPI.InstantiateClone(LegacyResourcesAPI.Load("Prefabs/projectileghosts/EvisOverlapProjectileGhost"), "EvisOverlapProjectileGhost_Pink", false); public static GameObject ImpactMercEvis_Pink = PrefabAPI.InstantiateClone(LegacyResourcesAPI.Load("Prefabs/effects/impacteffects/ImpactMercEvis"), "ImpactMercEvis_Pink", false); public static GameObject MercExposeEffect_Pink; public static GameObject MercExposeConsumeEffect_Pink; public static Material matMercIgnition_Pink = null; public static void Start() { //IL_0030: Unknown result type (might be due to invalid IL or missing references) //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_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_0074: Unknown result type (might be due to invalid IL or missing references) //IL_0079: Unknown result type (might be due to invalid IL or missing references) //IL_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_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_00da: Unknown result type (might be due to invalid IL or missing references) //IL_00df: Unknown result type (might be due to invalid IL or missing references) //IL_00fc: Unknown result type (might be due to invalid IL or missing references) //IL_0101: Unknown result type (might be due to invalid IL or missing references) //IL_011e: Unknown result type (might be due to invalid IL or missing references) //IL_0123: Unknown result type (might be due to invalid IL or missing references) //IL_0140: Unknown result type (might be due to invalid IL or missing references) //IL_0145: Unknown result type (might be due to invalid IL or missing references) MercExposeEffect_Pink = PrefabAPI.InstantiateClone(Merc_Blue.MercExposeEffect, "MercExposeEffect_Pink", false); MercExposeConsumeEffect_Pink = PrefabAPI.InstantiateClone(Merc_Blue.MercExposeConsumeEffect, "MercExposeConsumeEffect_Pink", false); MercSwordSlash_Pink = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/MercSwordSlash.prefab").WaitForCompletion(), "MercSwordSlash_Pink", false); MercSwordFinisherSlash_Pink = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/MercSwordFinisherSlash.prefab").WaitForCompletion(), "MercSwordFinisherSlash_Pink", false); MercSwordSlashWhirlwind_Pink = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/MercSwordSlashWhirlwind.prefab").WaitForCompletion(), "MercSwordSlashWhirlwind_Pink", false); MercSwordUppercutSlash_Pink = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/MercSwordUppercutSlash.prefab").WaitForCompletion(), "MercSwordUppercutSlash_Pink", false); OmniImpactVFXSlashMerc_Pink = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/OmniImpactVFXSlashMerc.prefab").WaitForCompletion(), "OmniImpactVFXSlashMerc_Pink", false); MercAssaulterEffect_Pink = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/MercAssaulterEffect.prefab").WaitForCompletion(), "MercAssaulterEffect_Pink", false); MercDashHitOverlay_Pink = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/MercDashHitOverlay.prefab").WaitForCompletion(), "MercDashHitOverlay_Pink", false); ImpactMercAssaulter_Pink = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/ImpactMercAssaulter.prefab").WaitForCompletion(), "ImpactMercAssaulter_Pink", false); ImpactMercFocusedAssault_Pink = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/ImpactMercFocusedAssault.prefab").WaitForCompletion(), "ImpactMercFocusedAssault_Pink", false); } [Obsolete] public static void MakeEffects_Pink() { //IL_0045: 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_00fc: 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_0194: 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_0363: 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_03d3: Unknown result type (might be due to invalid IL or missing references) //IL_0436: Unknown result type (might be due to invalid IL or missing references) //IL_0477: Unknown result type (might be due to invalid IL or missing references) //IL_04ab: Unknown result type (might be due to invalid IL or missing references) //IL_054e: Unknown result type (might be due to invalid IL or missing references) //IL_0586: Unknown result type (might be due to invalid IL or missing references) //IL_05de: Unknown result type (might be due to invalid IL or missing references) //IL_0616: Unknown result type (might be due to invalid IL or missing references) //IL_0713: 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_07bb: Unknown result type (might be due to invalid IL or missing references) //IL_07f9: Unknown result type (might be due to invalid IL or missing references) //IL_0806: Unknown result type (might be due to invalid IL or missing references) //IL_080b: Unknown result type (might be due to invalid IL or missing references) //IL_0849: Unknown result type (might be due to invalid IL or missing references) //IL_096c: Unknown result type (might be due to invalid IL or missing references) //IL_0a59: Unknown result type (might be due to invalid IL or missing references) //IL_0af0: Unknown result type (might be due to invalid IL or missing references) //IL_0b24: Unknown result type (might be due to invalid IL or missing references) //IL_0baf: Unknown result type (might be due to invalid IL or missing references) //IL_0be3: Unknown result type (might be due to invalid IL or missing references) //IL_0ca6: Unknown result type (might be due to invalid IL or missing references) //IL_0d06: Unknown result type (might be due to invalid IL or missing references) //IL_0de1: Unknown result type (might be due to invalid IL or missing references) //IL_0e82: Unknown result type (might be due to invalid IL or missing references) Material val = null; Material val2 = null; Material val3 = null; Material val4 = null; Material val5 = null; Material val6 = null; Material val7 = null; Material particleSystemOverrideMaterial = null; Material val8 = null; Material particleSystemOverrideMaterial2 = null; Material val9 = LegacyResourcesAPI.Load("materials/matMercHologram"); matHuntressFlashBright_Pink.SetColor("_TintColor", new Color(1.3f, 0.6f, 1.17f, 1f)); matHuntressFlashExpanded_Pink.SetColor("_TintColor", new Color(0.58f, 0.2f, 0.52199996f, 1f)); Texture2D val10 = Assets.Bundle.LoadAsset("Assets/WQoL/SkinRamps/texRampFallbootsPink.png"); Texture2D val11 = Assets.Bundle.LoadAsset("Assets/WQoL/SkinRamps/texRampMercDustPink.png"); Texture2D val12 = Assets.Bundle.LoadAsset("Assets/WQoL/SkinRamps/texRampHuntressSoftPink.png"); Texture2D val13 = Assets.Bundle.LoadAsset("Assets/WQoL/SkinRamps/texRampHuntressPink.png"); matMercEvisTarget_Pink = Object.Instantiate(LegacyResourcesAPI.Load("Materials/matMercEvisTarget")); matMercEvisTarget_Pink.SetTexture("_RemapTex", (Texture)(object)val12); matMercEvisTarget_Pink.SetColor("_TintColor", new Color(1f, 0.5f, 1f)); ParticleSystemRenderer component = ((Component)MercSwordSlash_Pink.transform.GetChild(0)).GetComponent(); val4 = Object.Instantiate(((Renderer)component).material); val4.SetTexture("_RemapTex", (Texture)(object)val10); val4.SetColor("_TintColor", new Color(0.5f, 0.314f, 0.45f, 1f)); ((Renderer)component).material = val4; ParticleSystem component2 = ((Component)MercSwordFinisherSlash_Pink.transform.GetChild(0)).GetComponent(); component2.startColor = new Color(1f, 0.2f, 0.9f, 1f); ParticleSystemRenderer component3 = ((Component)MercSwordFinisherSlash_Pink.transform.GetChild(1)).GetComponent(); val5 = Object.Instantiate(((Renderer)component3).material); val5.SetTexture("_RemapTex", (Texture)(object)val10); val5.SetColor("_TintColor", new Color(0.8f, 0.366f, 0.71999997f, 1f)); ((Renderer)component3).material = val5; ParticleSystemRenderer component4 = ((Component)MercSwordSlashWhirlwind_Pink.transform.GetChild(0)).GetComponent(); ((Renderer)component4).material = val4; ParticleSystemRenderer component5 = ((Component)MercSwordUppercutSlash_Pink.transform.GetChild(0)).GetComponent(); ParticleSystemRenderer component6 = ((Component)MercSwordUppercutSlash_Pink.transform.GetChild(1)).GetComponent(); ((Renderer)component5).material = val5; ((Renderer)component6).material = val4; OmniEffect component7 = OmniImpactVFXSlashMerc_Pink.GetComponent(); Material val14 = Object.Instantiate(component7.omniEffectGroups[3].omniEffectElements[1].particleSystemOverrideMaterial); val14.SetTexture("_RemapTex", (Texture)(object)val11); component7.omniEffectGroups[3].omniEffectElements[1].particleSystemOverrideMaterial = val14; Material val15 = Object.Instantiate(component7.omniEffectGroups[4].omniEffectElements[1].particleSystemOverrideMaterial); val15.SetTexture("_RemapTex", (Texture)(object)val11); component7.omniEffectGroups[4].omniEffectElements[1].particleSystemOverrideMaterial = val15; Material val16 = Object.Instantiate(component7.omniEffectGroups[6].omniEffectElements[0].particleSystemOverrideMaterial); val16.SetTexture("_RemapTex", (Texture)(object)val11); component7.omniEffectGroups[6].omniEffectElements[0].particleSystemOverrideMaterial = val16; ParticleSystem component8 = ((Component)OmniImpactVFXSlashMerc_Pink.transform.GetChild(1)).GetComponent(); component8.startColor = new Color(0.7264f, 0.3f, 0.65376f, 1f); ParticleSystem component9 = ((Component)OmniImpactVFXSlashMerc_Pink.transform.GetChild(2)).GetComponent(); component9.startColor = new Color(0.9333f, 0.2f, 0.83997f, 1f); ParticleSystem component10 = ((Component)OmniImpactVFXSlashMerc_Pink.transform.GetChild(3)).GetComponent(); component10.startColor = new Color(0.5f, 0.4245f, 0.45f, 1f); ParticleSystemRenderer component11 = ((Component)MercAssaulterEffect_Pink.transform.GetChild(5)).GetComponent(); matMercIgnition_Pink = Object.Instantiate(((Renderer)component11).material); matMercIgnition_Pink.SetTexture("_RemapTex", (Texture)(object)val13); matMercIgnition_Pink.SetColor("_TintColor", new Color(0.44f, 0.44f, 0.396f, 1f)); ((Renderer)component11).material = matMercIgnition_Pink; ((Component)MercAssaulterEffect_Pink.transform.GetChild(6)).GetComponent().startColor = new Color(0.71f, 0.3f, 0.63899994f, 1f); ((Component)MercAssaulterEffect_Pink.transform.GetChild(8)).GetComponent().color = new Color(0.68f, 0.3765f, 0.612f, 1f); ((Renderer)((Component)MercAssaulterEffect_Pink.transform.GetChild(9)).GetComponent()).material = val4; ((Renderer)((Component)MercAssaulterEffect_Pink.transform.GetChild(10).GetChild(2)).GetComponent()).material = matMercIgnition_Pink; ((Renderer)((Component)MercAssaulterEffect_Pink.transform.GetChild(10).GetChild(3)).GetComponent()).material = matMercIgnition_Pink; ParticleSystem component12 = ((Component)ImpactMercAssaulter_Pink.transform.GetChild(0)).GetComponent(); component12.startColor = new Color(0.8f, 0.45f, 0.71999997f, 1f); component12 = ((Component)ImpactMercAssaulter_Pink.transform.GetChild(1)).GetComponent(); component12.startColor = new Color(0.72f, 0.522f, 0.648f, 1f); ParticleSystemRenderer component13 = ((Component)ImpactMercAssaulter_Pink.transform.GetChild(2)).GetComponent(); ((Renderer)component13).material = val4; component12 = ((Component)ImpactMercFocusedAssault_Pink.transform.GetChild(0)).GetComponent(); component12.startColor = new Color(0.8f, 0.4f, 0.71999997f, 0.2667f); component12 = ((Component)ImpactMercFocusedAssault_Pink.transform.GetChild(1)).GetComponent(); component12.startColor = new Color(0.7f, 0.26f, 0.63f, 1f); component13 = ((Component)ImpactMercFocusedAssault_Pink.transform.GetChild(2)).GetComponent(); val6 = Object.Instantiate(((Renderer)component13).material); val6.SetTexture("_RemapTex", (Texture)(object)val11); ((Renderer)component13).material = val6; component13 = ((Component)MercFocusedAssaultOrbEffect_Pink.transform.GetChild(0)).GetComponent(); val = Object.Instantiate(((Renderer)component13).material); val.SetTexture("_RemapTex", (Texture)(object)val11); ((Renderer)component13).material = val; component13 = ((Component)MercFocusedAssaultOrbEffect_Pink.transform.GetChild(1)).GetComponent(); val2 = Object.Instantiate(((Renderer)component13).material); val2.SetTexture("_RemapTex", (Texture)(object)val11); ((Renderer)component13).material = val2; component13 = ((Component)MercFocusedAssaultOrbEffect_Pink.transform.GetChild(2)).GetComponent(); val3 = Object.Instantiate(((Renderer)component13).material); val3.SetColor("_TintColor", new Color(1f, 0f, 1f, 0.9f)); ((Renderer)component13).material = val3; component13 = ((Component)MercFocusedAssaultOrbEffect_Pink.transform.GetChild(3)).GetComponent(); val7 = Object.Instantiate(((Renderer)component13).material); val7.SetTexture("_RemapTex", (Texture)(object)val13); val7.SetColor("_TintColor", new Color(0.512f, 0.06f, 0.512f, 1f)); ((Renderer)component13).material = val7; matMercEnergized_Pink.SetTexture("_RemapTex", (Texture)(object)val12); matMercEnergized_Pink.SetColor("_TintColor", new Color(0.66f, 0.88f, 0.88f, 1f)); component12 = ((Component)HuntressBlinkEffect_Pink.transform.GetChild(0).GetChild(0)).GetComponent(); component12.startColor = new Color(0.39f, 0.154f, 0.35099998f, 1f); ColorOverLifetimeModule colorOverLifetime = component12.colorOverLifetime; ((ColorOverLifetimeModule)(ref colorOverLifetime)).enabled = false; Light component14 = ((Component)HuntressBlinkEffect_Pink.transform.GetChild(0).GetChild(2)).GetComponent(); component14.color = new Color(1f, 0.6f, 0.9f, 1f); component13 = ((Component)HuntressBlinkEffect_Pink.transform.GetChild(0).GetChild(4)).GetComponent(); Material val17 = Object.Instantiate(((Renderer)component13).material); val17.SetTexture("_RemapTex", (Texture)(object)val12); ((Renderer)component13).material = val17; component13 = ((Component)HuntressBlinkEffect_Pink.transform.GetChild(0).GetChild(5)).GetComponent(); ((Renderer)component13).material = val17; component13 = ((Component)HuntressFireArrowRain_Pink.transform.GetChild(2)).GetComponent(); ((Renderer)component13).material = val17; component13 = ((Component)HuntressFireArrowRain_Pink.transform.GetChild(3)).GetComponent(); ((Renderer)component13).material = val17; component13 = ((Component)HuntressFireArrowRain_Pink.transform.GetChild(4)).GetComponent(); Material val18 = Object.Instantiate(((Renderer)component13).material); val18.SetTexture("_RemapTex", (Texture)(object)val13); ((Renderer)component13).material = val18; component14 = ((Component)HuntressFireArrowRain_Pink.transform.GetChild(5)).GetComponent(); component14.color = new Color(0.87f, 0.5f, 0.783f, 1f); OmniEffect component15 = OmniImpactVFXSlashMercEvis_Pink.GetComponent(); component15.omniEffectGroups[1].omniEffectElements[0].particleSystemOverrideMaterial = particleSystemOverrideMaterial2; val8 = Object.Instantiate(component15.omniEffectGroups[3].omniEffectElements[1].particleSystemOverrideMaterial); val8.SetTexture("_RemapTex", (Texture)(object)val11); component15.omniEffectGroups[3].omniEffectElements[1].particleSystemOverrideMaterial = val8; component15.omniEffectGroups[4].omniEffectElements[1].particleSystemOverrideMaterial = particleSystemOverrideMaterial; component15.omniEffectGroups[6].omniEffectElements[0].particleSystemOverrideMaterial = val16; component13 = ((Component)OmniImpactVFXSlashMercEvis_Pink.transform.GetChild(7)).GetComponent(); val9 = Object.Instantiate(((Renderer)component13).material); val9.SetTexture("_RemapTex", (Texture)(object)val10); val9.SetColor("_TintColor", new Color(1.12f, 0.3f, 1.008f, 1f)); ((Renderer)component13).material = val9; ((Renderer)((Component)EvisProjectileGhost_Pink.transform.GetChild(0)).GetComponent()).material = val5; ((Renderer)((Component)EvisProjectileGhost_Pink.transform.GetChild(1)).GetComponent()).material = val4; ((Renderer)((Component)EvisProjectileGhost_Pink.transform.GetChild(2)).GetComponent()).material = matMercIgnition_Pink; ((Component)EvisProjectileGhost_Pink.transform.GetChild(3)).GetComponent().startColor = new Color(0.63f, 0.23f, 0.63899994f, 1f); ((Component)EvisProjectileGhost_Pink.transform.GetChild(5)).GetComponent().color = new Color(0.59f, 0.25f, 0.585f, 1f); ((Renderer)((Component)EvisOverlapProjectileGhost_Pink.transform.GetChild(0)).GetComponent()).material = val5; ((Renderer)((Component)EvisOverlapProjectileGhost_Pink.transform.GetChild(1)).GetComponent()).material = val8; ((Renderer)((Component)EvisOverlapProjectileGhost_Pink.transform.GetChild(2)).GetComponent()).material = val16; ((Component)EvisOverlapProjectileGhost_Pink.transform.GetChild(3)).GetComponent().startColor = new Color(0.8f, 0.51f, 0.774f, 1f); ((Component)EvisOverlapProjectileGhost_Pink.transform.GetChild(4)).GetComponent().color = new Color(0.627f, 0.2772f, 0.63f, 1f); ((Renderer)((Component)EvisOverlapProjectileGhost_Pink.transform.GetChild(5)).GetComponent()).material = val9; ((Renderer)((Component)EvisOverlapProjectileGhost_Pink.transform.GetChild(6)).GetComponent()).material = val9; ((Renderer)((Component)ImpactMercEvis_Pink.transform.GetChild(0)).GetComponent()).material = val9; ((Renderer)((Component)ImpactMercEvis_Pink.transform.GetChild(1)).GetComponent()).material = val4; ((Renderer)((Component)ImpactMercEvis_Pink.transform.GetChild(2)).GetComponent()).material = val4; ((Component)ImpactMercEvis_Pink.transform.GetChild(3)).GetComponent().color = new Color(0.92f, 0.425f, 0.828f, 1f); component13 = ((Component)MercExposeEffect_Pink.transform.GetChild(0).GetChild(0)).GetComponent(); Material val19 = Object.Instantiate(((Renderer)component13).material); val19.SetTexture("_RemapTex", (Texture)(object)val13); val19.SetColor("_TintColor", new Color(0.25f, 0.25f, 0.225f, 1f)); ((Renderer)component13).material = val19; component13 = ((Component)MercExposeEffect_Pink.transform.GetChild(0).GetChild(1)).GetComponent(); ((Renderer)component13).material = val3; component13 = ((Component)MercExposeConsumeEffect_Pink.transform.GetChild(0).GetChild(0)).GetComponent(); ((Renderer)component13).material = val19; component13 = ((Component)MercExposeConsumeEffect_Pink.transform.GetChild(0).GetChild(2)).GetComponent(); ((Renderer)component13).material = val7; ((Renderer)((Component)MercExposeEffect_Pink.transform.GetChild(0).GetChild(0)).GetComponent()).material = val19; ((Component)MercExposeEffect_Pink.transform.GetChild(0).GetChild(1)).GetComponent().startColor = new Color(0.15f, 0.1f, 0.135f, 0.29f); ((Renderer)((Component)MercExposeEffect_Pink.transform.GetChild(0).GetChild(1)).GetComponent()).material = val3; ((Renderer)((Component)MercExposeConsumeEffect_Pink.transform.GetChild(0).GetChild(0)).GetComponent()).material = val19; ((Renderer)((Component)MercExposeConsumeEffect_Pink.transform.GetChild(0).GetChild(1)).GetComponent()).material = val3; ((Component)MercExposeConsumeEffect_Pink.transform.GetChild(0).GetChild(1)).GetComponent().startColor = new Color(0.3f, 0.11f, 0.27f, 0.175f); ((Renderer)((Component)MercExposeConsumeEffect_Pink.transform.GetChild(0).GetChild(2)).GetComponent()).material = val19; } } public static class Merc_Red { public static Material matMercEnergized_Red = Object.Instantiate(LegacyResourcesAPI.Load("materials/matMercEnergized")); public static Material matMercEvisTarget_Red = Object.Instantiate(LegacyResourcesAPI.Load("materials/matMercEvisTarget")); public static Material matHuntressFlashBright_Red = Object.Instantiate(LegacyResourcesAPI.Load("materials/matHuntressFlashBright")); public static Material matHuntressFlashExpanded_Red = Object.Instantiate(LegacyResourcesAPI.Load("materials/matHuntressFlashExpanded")); public static GameObject MercFocusedAssaultOrbEffect_Red = PrefabAPI.InstantiateClone(LegacyResourcesAPI.Load("Prefabs/effects/orbeffects/MercFocusedAssaultOrbEffect"), "MercFocusedAssaultOrbEffect_Red", false); public static GameObject OmniImpactVFXSlashMerc_Red = null; public static GameObject MercSwordSlash_Red = null; public static GameObject MercSwordFinisherSlash_Red = null; public static GameObject MercSwordSlashWhirlwind_Red = null; public static GameObject MercDashHitOverlay_Red = null; public static GameObject HuntressBlinkEffect_Red = PrefabAPI.InstantiateClone(LegacyResourcesAPI.Load("Prefabs/effects/HuntressBlinkEffect"), "HuntressBlinkEffect_Red", false); public static GameObject HuntressFireArrowRain_Red = PrefabAPI.InstantiateClone(LegacyResourcesAPI.Load("Prefabs/effects/muzzleflashes/HuntressFireArrowRain"), "HuntressFireArrowRain_Red", false); public static GameObject OmniImpactVFXSlashMercEvis_Red = PrefabAPI.InstantiateClone(LegacyResourcesAPI.Load("Prefabs/effects/omnieffect/OmniImpactVFXSlashMercEvis"), "OmniImpactVFXSlashMercEvis_Red", false); public static GameObject MercSwordUppercutSlash_Red = null; public static GameObject ImpactMercFocusedAssault_Red = null; public static GameObject ImpactMercAssaulter_Red = null; public static GameObject MercAssaulterEffect_Red = null; public static GameObject EvisProjectileGhost_Red = PrefabAPI.InstantiateClone(LegacyResourcesAPI.Load("Prefabs/projectileghosts/EvisProjectileGhost"), "EvisProjectileGhost_Red", false); public static GameObject EvisOverlapProjectileGhost_Red = PrefabAPI.InstantiateClone(LegacyResourcesAPI.Load("Prefabs/projectileghosts/EvisOverlapProjectileGhost"), "EvisOverlapProjectileGhost_Red", false); public static GameObject ImpactMercEvis_Red = PrefabAPI.InstantiateClone(LegacyResourcesAPI.Load("Prefabs/effects/impacteffects/ImpactMercEvis"), "ImpactMercEvis_Red", false); public static GameObject MercExposeEffect_Red; public static GameObject MercExposeConsumeEffect_Red; public static Material matMercIgnition_Red = null; public static void Start() { //IL_0030: Unknown result type (might be due to invalid IL or missing references) //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_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_0074: Unknown result type (might be due to invalid IL or missing references) //IL_0079: Unknown result type (might be due to invalid IL or missing references) //IL_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_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_00da: Unknown result type (might be due to invalid IL or missing references) //IL_00df: Unknown result type (might be due to invalid IL or missing references) //IL_00fc: Unknown result type (might be due to invalid IL or missing references) //IL_0101: Unknown result type (might be due to invalid IL or missing references) //IL_011e: Unknown result type (might be due to invalid IL or missing references) //IL_0123: Unknown result type (might be due to invalid IL or missing references) //IL_0140: Unknown result type (might be due to invalid IL or missing references) //IL_0145: Unknown result type (might be due to invalid IL or missing references) MercExposeEffect_Red = PrefabAPI.InstantiateClone(Merc_Blue.MercExposeEffect, "MercExposeEffect_Red", false); MercExposeConsumeEffect_Red = PrefabAPI.InstantiateClone(Merc_Blue.MercExposeConsumeEffect, "MercExposeConsumeEffect_Red", false); MercSwordSlash_Red = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/MercSwordSlash.prefab").WaitForCompletion(), "MercSwordSlash_Red", false); MercSwordFinisherSlash_Red = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/MercSwordFinisherSlash.prefab").WaitForCompletion(), "MercSwordFinisherSlash_Red", false); MercSwordSlashWhirlwind_Red = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/MercSwordSlashWhirlwind.prefab").WaitForCompletion(), "MercSwordSlashWhirlwind_Red", false); MercSwordUppercutSlash_Red = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/MercSwordUppercutSlash.prefab").WaitForCompletion(), "MercSwordUppercutSlash_Red", false); OmniImpactVFXSlashMerc_Red = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/OmniImpactVFXSlashMerc.prefab").WaitForCompletion(), "OmniImpactVFXSlashMerc_Red", false); MercAssaulterEffect_Red = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/MercAssaulterEffect.prefab").WaitForCompletion(), "MercAssaulterEffect_Red", false); MercDashHitOverlay_Red = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/MercDashHitOverlay.prefab").WaitForCompletion(), "MercDashHitOverlay_Red", false); ImpactMercAssaulter_Red = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/ImpactMercAssaulter.prefab").WaitForCompletion(), "ImpactMercAssaulter_Red", false); ImpactMercFocusedAssault_Red = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/ImpactMercFocusedAssault.prefab").WaitForCompletion(), "ImpactMercFocusedAssault_Red", false); } [Obsolete] public static void MakeEffects_Red() { //IL_0045: 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_00ed: 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_0185: Unknown result type (might be due to invalid IL or missing references) //IL_01df: Unknown result type (might be due to invalid IL or missing references) //IL_0354: Unknown result type (might be due to invalid IL or missing references) //IL_038c: Unknown result type (might be due to invalid IL or missing references) //IL_03c4: Unknown result type (might be due to invalid IL or missing references) //IL_0427: Unknown result type (might be due to invalid IL or missing references) //IL_0468: 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_053f: Unknown result type (might be due to invalid IL or missing references) //IL_0577: Unknown result type (might be due to invalid IL or missing references) //IL_05cf: Unknown result type (might be due to invalid IL or missing references) //IL_0607: Unknown result type (might be due to invalid IL or missing references) //IL_0704: 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_07ac: Unknown result type (might be due to invalid IL or missing references) //IL_07ea: Unknown result type (might be due to invalid IL or missing references) //IL_07f7: Unknown result type (might be due to invalid IL or missing references) //IL_07fc: Unknown result type (might be due to invalid IL or missing references) //IL_083a: Unknown result type (might be due to invalid IL or missing references) //IL_095d: Unknown result type (might be due to invalid IL or missing references) //IL_0a4a: Unknown result type (might be due to invalid IL or missing references) //IL_0ae1: Unknown result type (might be due to invalid IL or missing references) //IL_0b15: Unknown result type (might be due to invalid IL or missing references) //IL_0ba0: Unknown result type (might be due to invalid IL or missing references) //IL_0bd4: Unknown result type (might be due to invalid IL or missing references) //IL_0c97: Unknown result type (might be due to invalid IL or missing references) //IL_0cf7: Unknown result type (might be due to invalid IL or missing references) //IL_0dd2: Unknown result type (might be due to invalid IL or missing references) //IL_0e73: Unknown result type (might be due to invalid IL or missing references) Material val = null; Material val2 = null; Material val3 = null; Material val4 = null; Material val5 = null; Material val6 = null; Material val7 = null; Material particleSystemOverrideMaterial = null; Material val8 = null; Material particleSystemOverrideMaterial2 = null; Material val9 = LegacyResourcesAPI.Load("materials/matMercHologram"); matHuntressFlashBright_Red.SetColor("_TintColor", new Color(1.3f, 0.6f, 0.6f, 1f)); matHuntressFlashExpanded_Red.SetColor("_TintColor", new Color(0.58f, 0.2f, 0.2f, 1f)); Texture2D val10 = Assets.Bundle.LoadAsset("Assets/WQoL/SkinRamps/texRampFallbootsRed.png"); Texture2D val11 = Assets.Bundle.LoadAsset("Assets/WQoL/SkinRamps/texRampMercDustRed.png"); Texture2D val12 = Assets.Bundle.LoadAsset("Assets/WQoL/SkinRamps/texRampHuntressSoftRed.png"); Texture2D val13 = Assets.Bundle.LoadAsset("Assets/WQoL/SkinRamps/texRampHuntressRed.png"); matMercEvisTarget_Red = Object.Instantiate(LegacyResourcesAPI.Load("Materials/matMercEvisTarget")); matMercEvisTarget_Red.SetTexture("_RemapTex", (Texture)(object)val12); matMercEvisTarget_Red.SetColor("_TintColor", Color.red); ParticleSystemRenderer component = ((Component)MercSwordSlash_Red.transform.GetChild(0)).GetComponent(); val4 = Object.Instantiate(((Renderer)component).material); val4.SetTexture("_RemapTex", (Texture)(object)val10); val4.SetColor("_TintColor", new Color(1f, 0f, 0f, 1f)); ((Renderer)component).material = val4; ParticleSystem component2 = ((Component)MercSwordFinisherSlash_Red.transform.GetChild(0)).GetComponent(); component2.startColor = new Color(1f, 0.2f, 0.2f, 1f); ParticleSystemRenderer component3 = ((Component)MercSwordFinisherSlash_Red.transform.GetChild(1)).GetComponent(); val5 = Object.Instantiate(((Renderer)component3).material); val5.SetTexture("_RemapTex", (Texture)(object)val10); val5.SetColor("_TintColor", new Color(1f, 0.22f, 0.22f, 1f)); ((Renderer)component3).material = val5; ParticleSystemRenderer component4 = ((Component)MercSwordSlashWhirlwind_Red.transform.GetChild(0)).GetComponent(); ((Renderer)component4).material = val4; ParticleSystemRenderer component5 = ((Component)MercSwordUppercutSlash_Red.transform.GetChild(0)).GetComponent(); ParticleSystemRenderer component6 = ((Component)MercSwordUppercutSlash_Red.transform.GetChild(1)).GetComponent(); ((Renderer)component5).material = val5; ((Renderer)component6).material = val4; OmniEffect component7 = OmniImpactVFXSlashMerc_Red.GetComponent(); Material val14 = Object.Instantiate(component7.omniEffectGroups[3].omniEffectElements[1].particleSystemOverrideMaterial); val14.SetTexture("_RemapTex", (Texture)(object)val11); component7.omniEffectGroups[3].omniEffectElements[1].particleSystemOverrideMaterial = val14; Material val15 = Object.Instantiate(component7.omniEffectGroups[4].omniEffectElements[1].particleSystemOverrideMaterial); val15.SetTexture("_RemapTex", (Texture)(object)val11); component7.omniEffectGroups[4].omniEffectElements[1].particleSystemOverrideMaterial = val15; Material val16 = Object.Instantiate(component7.omniEffectGroups[6].omniEffectElements[0].particleSystemOverrideMaterial); val16.SetTexture("_RemapTex", (Texture)(object)val11); component7.omniEffectGroups[6].omniEffectElements[0].particleSystemOverrideMaterial = val16; ParticleSystem component8 = ((Component)OmniImpactVFXSlashMerc_Red.transform.GetChild(1)).GetComponent(); component8.startColor = new Color(0.7264f, 0.3f, 0.3f, 1f); ParticleSystem component9 = ((Component)OmniImpactVFXSlashMerc_Red.transform.GetChild(2)).GetComponent(); component9.startColor = new Color(0.9333f, 0.2f, 0.2f, 1f); ParticleSystem component10 = ((Component)OmniImpactVFXSlashMerc_Red.transform.GetChild(3)).GetComponent(); component10.startColor = new Color(0.5f, 0.4245f, 0.0501f, 1f); ParticleSystemRenderer component11 = ((Component)MercAssaulterEffect_Red.transform.GetChild(5)).GetComponent(); matMercIgnition_Red = Object.Instantiate(((Renderer)component11).material); matMercIgnition_Red.SetTexture("_RemapTex", (Texture)(object)val13); matMercIgnition_Red.SetColor("_TintColor", new Color(0.8867924f, 0.06f, 0.06f, 1f)); ((Renderer)component11).material = matMercIgnition_Red; ((Component)MercAssaulterEffect_Red.transform.GetChild(6)).GetComponent().startColor = new Color(1f, 0.3f, 0.3f, 1f); ((Component)MercAssaulterEffect_Red.transform.GetChild(8)).GetComponent().color = new Color(0.9804f, 0.3765f, 0.4868f, 1f); ((Renderer)((Component)MercAssaulterEffect_Red.transform.GetChild(9)).GetComponent()).material = val4; ((Renderer)((Component)MercAssaulterEffect_Red.transform.GetChild(10).GetChild(2)).GetComponent()).material = matMercIgnition_Red; ((Renderer)((Component)MercAssaulterEffect_Red.transform.GetChild(10).GetChild(3)).GetComponent()).material = matMercIgnition_Red; ParticleSystem component12 = ((Component)ImpactMercAssaulter_Red.transform.GetChild(0)).GetComponent(); component12.startColor = new Color(1f, 0.45f, 0.45f, 1f); component12 = ((Component)ImpactMercAssaulter_Red.transform.GetChild(1)).GetComponent(); component12.startColor = new Color(1f, 0.575f, 0.575f, 1f); ParticleSystemRenderer component13 = ((Component)ImpactMercAssaulter_Red.transform.GetChild(2)).GetComponent(); ((Renderer)component13).material = val4; component12 = ((Component)ImpactMercFocusedAssault_Red.transform.GetChild(0)).GetComponent(); component12.startColor = new Color(1f, 0.45f, 0.45f, 0.2667f); component12 = ((Component)ImpactMercFocusedAssault_Red.transform.GetChild(1)).GetComponent(); component12.startColor = new Color(0.934f, 0.26f, 0.26f, 1f); component13 = ((Component)ImpactMercFocusedAssault_Red.transform.GetChild(2)).GetComponent(); val6 = Object.Instantiate(((Renderer)component13).material); val6.SetTexture("_RemapTex", (Texture)(object)val11); ((Renderer)component13).material = val6; component13 = ((Component)MercFocusedAssaultOrbEffect_Red.transform.GetChild(0)).GetComponent(); val = Object.Instantiate(((Renderer)component13).material); val.SetTexture("_RemapTex", (Texture)(object)val11); ((Renderer)component13).material = val; component13 = ((Component)MercFocusedAssaultOrbEffect_Red.transform.GetChild(1)).GetComponent(); val2 = Object.Instantiate(((Renderer)component13).material); val2.SetTexture("_RemapTex", (Texture)(object)val11); ((Renderer)component13).material = val2; component13 = ((Component)MercFocusedAssaultOrbEffect_Red.transform.GetChild(2)).GetComponent(); val3 = Object.Instantiate(((Renderer)component13).material); val3.SetColor("_TintColor", new Color(3f, -2f, -2f, 0.9f)); ((Renderer)component13).material = val3; component13 = ((Component)MercFocusedAssaultOrbEffect_Red.transform.GetChild(3)).GetComponent(); val7 = Object.Instantiate(((Renderer)component13).material); val7.SetTexture("_RemapTex", (Texture)(object)val13); val7.SetColor("_TintColor", new Color(0.8868f, 0.06f, 0.06f, 1f)); ((Renderer)component13).material = val7; matMercEnergized_Red.SetTexture("_RemapTex", (Texture)(object)val12); matMercEnergized_Red.SetColor("_TintColor", new Color(1.8f, 0.35f, 0.35f, 1f)); component12 = ((Component)HuntressBlinkEffect_Red.transform.GetChild(0).GetChild(0)).GetComponent(); component12.startColor = new Color(0.6324f, 0.154f, 0.154f, 1f); ColorOverLifetimeModule colorOverLifetime = component12.colorOverLifetime; ((ColorOverLifetimeModule)(ref colorOverLifetime)).enabled = false; Light component14 = ((Component)HuntressBlinkEffect_Red.transform.GetChild(0).GetChild(2)).GetComponent(); component14.color = new Color(1f, 0.6f, 0.6f, 1f); component13 = ((Component)HuntressBlinkEffect_Red.transform.GetChild(0).GetChild(4)).GetComponent(); Material val17 = Object.Instantiate(((Renderer)component13).material); val17.SetTexture("_RemapTex", (Texture)(object)val12); ((Renderer)component13).material = val17; component13 = ((Component)HuntressBlinkEffect_Red.transform.GetChild(0).GetChild(5)).GetComponent(); ((Renderer)component13).material = val17; component13 = ((Component)HuntressFireArrowRain_Red.transform.GetChild(2)).GetComponent(); ((Renderer)component13).material = val17; component13 = ((Component)HuntressFireArrowRain_Red.transform.GetChild(3)).GetComponent(); ((Renderer)component13).material = val17; component13 = ((Component)HuntressFireArrowRain_Red.transform.GetChild(4)).GetComponent(); Material val18 = Object.Instantiate(((Renderer)component13).material); val18.SetTexture("_RemapTex", (Texture)(object)val13); ((Renderer)component13).material = val18; component14 = ((Component)HuntressFireArrowRain_Red.transform.GetChild(5)).GetComponent(); component14.color = new Color(1f, 0.55f, 0.55f, 1f); OmniEffect component15 = OmniImpactVFXSlashMercEvis_Red.GetComponent(); component15.omniEffectGroups[1].omniEffectElements[0].particleSystemOverrideMaterial = particleSystemOverrideMaterial2; val8 = Object.Instantiate(component15.omniEffectGroups[3].omniEffectElements[1].particleSystemOverrideMaterial); val8.SetTexture("_RemapTex", (Texture)(object)val11); component15.omniEffectGroups[3].omniEffectElements[1].particleSystemOverrideMaterial = val8; component15.omniEffectGroups[4].omniEffectElements[1].particleSystemOverrideMaterial = particleSystemOverrideMaterial; component15.omniEffectGroups[6].omniEffectElements[0].particleSystemOverrideMaterial = val16; component13 = ((Component)OmniImpactVFXSlashMercEvis_Red.transform.GetChild(7)).GetComponent(); val9 = Object.Instantiate(((Renderer)component13).material); val9.SetTexture("_RemapTex", (Texture)(object)val10); val9.SetColor("_TintColor", new Color(1.825f, -0.25f, 0f, 1f)); ((Renderer)component13).material = val9; ((Renderer)((Component)EvisProjectileGhost_Red.transform.GetChild(0)).GetComponent()).material = val5; ((Renderer)((Component)EvisProjectileGhost_Red.transform.GetChild(1)).GetComponent()).material = val4; ((Renderer)((Component)EvisProjectileGhost_Red.transform.GetChild(2)).GetComponent()).material = matMercIgnition_Red; ((Component)EvisProjectileGhost_Red.transform.GetChild(3)).GetComponent().startColor = new Color(1f, 0f, 0f, 1f); ((Component)EvisProjectileGhost_Red.transform.GetChild(5)).GetComponent().color = new Color(1f, 0.3f, 0.3f, 1f); ((Renderer)((Component)EvisOverlapProjectileGhost_Red.transform.GetChild(0)).GetComponent()).material = val5; ((Renderer)((Component)EvisOverlapProjectileGhost_Red.transform.GetChild(1)).GetComponent()).material = val8; ((Renderer)((Component)EvisOverlapProjectileGhost_Red.transform.GetChild(2)).GetComponent()).material = val16; ((Component)EvisOverlapProjectileGhost_Red.transform.GetChild(3)).GetComponent().startColor = new Color(1f, 0.51f, 0.51f, 1f); ((Component)EvisOverlapProjectileGhost_Red.transform.GetChild(4)).GetComponent().color = new Color(1f, 0.3f, 0.3f, 1f); ((Renderer)((Component)EvisOverlapProjectileGhost_Red.transform.GetChild(5)).GetComponent()).material = val9; ((Renderer)((Component)EvisOverlapProjectileGhost_Red.transform.GetChild(6)).GetComponent()).material = val9; ((Renderer)((Component)ImpactMercEvis_Red.transform.GetChild(0)).GetComponent()).material = val9; ((Renderer)((Component)ImpactMercEvis_Red.transform.GetChild(1)).GetComponent()).material = val4; ((Renderer)((Component)ImpactMercEvis_Red.transform.GetChild(2)).GetComponent()).material = val4; ((Component)ImpactMercEvis_Red.transform.GetChild(3)).GetComponent().color = new Color(1f, 0.425f, 0.425f, 1f); component13 = ((Component)MercExposeEffect_Red.transform.GetChild(0).GetChild(0)).GetComponent(); Material val19 = Object.Instantiate(((Renderer)component13).material); val19.SetTexture("_RemapTex", (Texture)(object)val13); val19.SetColor("_TintColor", new Color(0.9f, -0.1f, -0.1f, 1f)); ((Renderer)component13).material = val19; component13 = ((Component)MercExposeEffect_Red.transform.GetChild(0).GetChild(1)).GetComponent(); ((Renderer)component13).material = val3; component13 = ((Component)MercExposeConsumeEffect_Red.transform.GetChild(0).GetChild(0)).GetComponent(); ((Renderer)component13).material = val19; component13 = ((Component)MercExposeConsumeEffect_Red.transform.GetChild(0).GetChild(2)).GetComponent(); ((Renderer)component13).material = val7; ((Renderer)((Component)MercExposeEffect_Red.transform.GetChild(0).GetChild(0)).GetComponent()).material = val19; ((Component)MercExposeEffect_Red.transform.GetChild(0).GetChild(1)).GetComponent().startColor = new Color(0.23f, 0.1f, 0.08f, 0.29f); ((Renderer)((Component)MercExposeEffect_Red.transform.GetChild(0).GetChild(1)).GetComponent()).material = val3; ((Renderer)((Component)MercExposeConsumeEffect_Red.transform.GetChild(0).GetChild(0)).GetComponent()).material = val19; ((Renderer)((Component)MercExposeConsumeEffect_Red.transform.GetChild(0).GetChild(1)).GetComponent()).material = val3; ((Component)MercExposeConsumeEffect_Red.transform.GetChild(0).GetChild(1)).GetComponent().startColor = new Color(0.35f, 0.2f, 0.2f, 0.175f); ((Renderer)((Component)MercExposeConsumeEffect_Red.transform.GetChild(0).GetChild(2)).GetComponent()).material = val19; } } public static class Mercenary_Hooks { [CompilerGenerated] private static class <>O { public static hook_OnEnter <0>__GroundLight2_OnEnter; public static Manipulator <1>__Finisher_GroundLight2_OnEnter; public static Manipulator <2>__WhirlwindBase_OnEnter; public static Manipulator <3>__WhirlwindBase_FixedUpdate; public static Manipulator <4>__Uppercut_OnEnter; public static Manipulator <5>__Uppercut_FixedUpdate; public static Manipulator <6>__Assaulter2_OnEnter; public static hook_OnEnter <7>__Assaulter2_OnEnter_On; public static hook_OnEnter <8>__AltUtility_OnEnter; public static Manipulator <9>__Special_Dash; public static Manipulator <10>__EvisDash_CreateBlinkEffect; public static Manipulator <11>__MercRed_SpecialEvis; public static Manipulator <12>__Evis_FixedUpdate; public static Manipulator <13>__Evis_OnExit; public static hook_OnEnter <14>__AltSpecial_OnEnter; } public static void Hooks() { //IL_0011: 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_001c: Expected O, but got Unknown //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Unknown result type (might be due to invalid IL or missing references) //IL_003d: Expected O, but got Unknown //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_005e: Expected O, but got Unknown //IL_0074: Unknown result type (might be due to invalid IL or missing references) //IL_0079: Unknown result type (might be due to invalid IL or missing references) //IL_007f: Expected O, but got Unknown //IL_0095: 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_00a0: Expected O, but got Unknown //IL_00b6: Unknown result type (might be due to invalid IL or missing references) //IL_00bb: Unknown result type (might be due to invalid IL or missing references) //IL_00c1: Expected O, but got Unknown //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_00e2: Expected O, but got Unknown //IL_00f8: Unknown result type (might be due to invalid IL or missing references) //IL_00fd: Unknown result type (might be due to invalid IL or missing references) //IL_0103: Expected O, but got Unknown //IL_0119: Unknown result type (might be due to invalid IL or missing references) //IL_011e: Unknown result type (might be due to invalid IL or missing references) //IL_0124: Expected O, but got Unknown //IL_013a: Unknown result type (might be due to invalid IL or missing references) //IL_013f: Unknown result type (might be due to invalid IL or missing references) //IL_0145: Expected O, but got Unknown //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_0166: Expected O, but got Unknown //IL_017c: Unknown result type (might be due to invalid IL or missing references) //IL_0181: Unknown result type (might be due to invalid IL or missing references) //IL_0187: Expected O, but got Unknown //IL_019d: Unknown result type (might be due to invalid IL or missing references) //IL_01a2: Unknown result type (might be due to invalid IL or missing references) //IL_01a8: Expected O, but got Unknown //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_01c9: Expected O, but got Unknown //IL_01df: Unknown result type (might be due to invalid IL or missing references) //IL_01e4: Unknown result type (might be due to invalid IL or missing references) //IL_01ea: Expected O, but got Unknown object obj = <>O.<0>__GroundLight2_OnEnter; if (obj == null) { hook_OnEnter val = GroundLight2_OnEnter; <>O.<0>__GroundLight2_OnEnter = val; obj = (object)val; } GroundLight2.OnEnter += (hook_OnEnter)obj; object obj2 = <>O.<1>__Finisher_GroundLight2_OnEnter; if (obj2 == null) { Manipulator val2 = Finisher_GroundLight2_OnEnter; <>O.<1>__Finisher_GroundLight2_OnEnter = val2; obj2 = (object)val2; } GroundLight2.OnEnter += (Manipulator)obj2; object obj3 = <>O.<2>__WhirlwindBase_OnEnter; if (obj3 == null) { Manipulator val3 = WhirlwindBase_OnEnter; <>O.<2>__WhirlwindBase_OnEnter = val3; obj3 = (object)val3; } WhirlwindBase.OnEnter += (Manipulator)obj3; object obj4 = <>O.<3>__WhirlwindBase_FixedUpdate; if (obj4 == null) { Manipulator val4 = WhirlwindBase_FixedUpdate; <>O.<3>__WhirlwindBase_FixedUpdate = val4; obj4 = (object)val4; } WhirlwindBase.FixedUpdate += (Manipulator)obj4; object obj5 = <>O.<4>__Uppercut_OnEnter; if (obj5 == null) { Manipulator val5 = Uppercut_OnEnter; <>O.<4>__Uppercut_OnEnter = val5; obj5 = (object)val5; } Uppercut.OnEnter += (Manipulator)obj5; object obj6 = <>O.<5>__Uppercut_FixedUpdate; if (obj6 == null) { Manipulator val6 = Uppercut_FixedUpdate; <>O.<5>__Uppercut_FixedUpdate = val6; obj6 = (object)val6; } Uppercut.FixedUpdate += (Manipulator)obj6; object obj7 = <>O.<6>__Assaulter2_OnEnter; if (obj7 == null) { Manipulator val7 = Assaulter2_OnEnter; <>O.<6>__Assaulter2_OnEnter = val7; obj7 = (object)val7; } Assaulter2.OnEnter += (Manipulator)obj7; object obj8 = <>O.<7>__Assaulter2_OnEnter_On; if (obj8 == null) { hook_OnEnter val8 = Assaulter2_OnEnter_On; <>O.<7>__Assaulter2_OnEnter_On = val8; obj8 = (object)val8; } Assaulter2.OnEnter += (hook_OnEnter)obj8; object obj9 = <>O.<8>__AltUtility_OnEnter; if (obj9 == null) { hook_OnEnter val9 = AltUtility_OnEnter; <>O.<8>__AltUtility_OnEnter = val9; obj9 = (object)val9; } FocusedAssaultDash.OnEnter += (hook_OnEnter)obj9; object obj10 = <>O.<9>__Special_Dash; if (obj10 == null) { Manipulator val10 = Special_Dash; <>O.<9>__Special_Dash = val10; obj10 = (object)val10; } EvisDash.FixedUpdate += (Manipulator)obj10; object obj11 = <>O.<10>__EvisDash_CreateBlinkEffect; if (obj11 == null) { Manipulator val11 = EvisDash_CreateBlinkEffect; <>O.<10>__EvisDash_CreateBlinkEffect = val11; obj11 = (object)val11; } EvisDash.CreateBlinkEffect += (Manipulator)obj11; object obj12 = <>O.<11>__MercRed_SpecialEvis; if (obj12 == null) { Manipulator val12 = MercRed_SpecialEvis; <>O.<11>__MercRed_SpecialEvis = val12; obj12 = (object)val12; } Evis.CreateBlinkEffect += (Manipulator)obj12; object obj13 = <>O.<12>__Evis_FixedUpdate; if (obj13 == null) { Manipulator val13 = Evis_FixedUpdate; <>O.<12>__Evis_FixedUpdate = val13; obj13 = (object)val13; } Evis.FixedUpdate += (Manipulator)obj13; object obj14 = <>O.<13>__Evis_OnExit; if (obj14 == null) { Manipulator val14 = Evis_OnExit; <>O.<13>__Evis_OnExit = val14; obj14 = (object)val14; } Evis.OnExit += (Manipulator)obj14; object obj15 = <>O.<14>__AltSpecial_OnEnter; if (obj15 == null) { hook_OnEnter val15 = AltSpecial_OnEnter; <>O.<14>__AltSpecial_OnEnter = val15; obj15 = (object)val15; } ThrowEvisProjectile.OnEnter += (hook_OnEnter)obj15; } private static void EvisDash_CreateBlinkEffect(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown //IL_003d: Unknown result type (might be due to invalid IL or missing references) ILCursor val = new ILCursor(il); if (val.TryGotoNext((MoveType)2, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchLdsfld(x, "EntityStates.Merc.EvisDash", "blinkPrefab") })) { val.Emit(OpCodes.Ldarg_0); val.EmitDelegate>((Func)delegate(GameObject target, EvisDash entityState) { EffectReplacer.ActivateMerc(EvisDash.blinkPrefab, ((EntityState)entityState).gameObject); return target; }); } else { Log.LogWarning("IL Failed: Red Merc: Evis.CreateBlinkEffect"); } } private static void AltSpecial_OnEnter(orig_OnEnter orig, ThrowEvisProjectile self) { ((GenericProjectileBaseState)self).effectPrefab = null; SetExposeColor(((EntityState)self).gameObject); orig.Invoke(self); } private static void AltUtility_OnEnter(orig_OnEnter orig, FocusedAssaultDash self) { int num = SkinChanges.DetectCaseMerc(((EntityState)self).gameObject); EffectReplacer.Activate(self.delayedEffectPrefab, num); EffectReplacer.Activate(((BasicMeleeAttack)self).hitEffectPrefab, num); EffectReplacer.Activate(self.orbEffect, num); switch (num) { case 1: ((BasicMeleeAttack)self).swingEffectPrefab = Merc_Red.MercAssaulterEffect_Red; self.enterOverlayMaterial = Merc_Red.matMercEnergized_Red; break; case 2: ((BasicMeleeAttack)self).swingEffectPrefab = Merc_Green.MercAssaulterEffect_Green; self.enterOverlayMaterial = Merc_Green.matMercEnergized_Green; break; case 3: ((BasicMeleeAttack)self).swingEffectPrefab = Merc_Pink.MercAssaulterEffect_Pink; self.enterOverlayMaterial = Merc_Pink.matMercEnergized_Pink; break; } SetExposeColor(num); orig.Invoke(self); } public static void SetExposeColor(GameObject gameObject) { SetExposeColor(SkinChanges.DetectCaseMerc(gameObject)); } public static void SetExposeColor(int i) { EffectReplacer.Activate(AssetReferences.mercExposeConsumeEffectPrefab, i); switch (i) { case 0: AssetReferences.mercExposeEffectPrefab = Merc_Blue.MercExposeEffect; break; case 1: AssetReferences.mercExposeEffectPrefab = Merc_Red.MercExposeEffect_Red; break; case 2: AssetReferences.mercExposeEffectPrefab = Merc_Green.MercExposeEffect_Green; break; case 3: AssetReferences.mercExposeEffectPrefab = Merc_Pink.MercExposeEffect_Pink; break; } } private static void Assaulter2_OnEnter_On(orig_OnEnter orig, Assaulter2 self) { switch (SkinChanges.DetectCaseMerc(((EntityState)self).gameObject)) { case 0: EffectReplacer.Activate(((BasicMeleeAttack)self).hitEffectPrefab, 0); break; case 1: EffectReplacer.Activate(((BasicMeleeAttack)self).hitEffectPrefab, 1); ((BasicMeleeAttack)self).swingEffectPrefab = Merc_Red.MercAssaulterEffect_Red; break; case 2: EffectReplacer.Activate(((BasicMeleeAttack)self).hitEffectPrefab, 2); ((BasicMeleeAttack)self).swingEffectPrefab = Merc_Green.MercAssaulterEffect_Green; break; case 3: EffectReplacer.Activate(((BasicMeleeAttack)self).hitEffectPrefab, 3); ((BasicMeleeAttack)self).swingEffectPrefab = Merc_Pink.MercAssaulterEffect_Pink; break; } orig.Invoke(self); } private static void GroundLight2_OnEnter(orig_OnEnter orig, GroundLight2 self) { if (!self.isComboFinisher) { int num = SkinChanges.DetectCaseMerc(((EntityState)self).gameObject); EffectReplacer.Activate(((BasicMeleeAttack)self).hitEffectPrefab, num); switch (num) { case 1: ((BasicMeleeAttack)self).swingEffectPrefab = Merc_Red.MercSwordSlash_Red; break; case 2: ((BasicMeleeAttack)self).swingEffectPrefab = Merc_Green.MercSwordSlash_Green; break; case 3: ((BasicMeleeAttack)self).swingEffectPrefab = Merc_Pink.MercSwordSlash_Pink; break; } } orig.Invoke(self); } private static void Evis_OnExit(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown //IL_007c: Unknown result type (might be due to invalid IL or missing references) ILCursor val = new ILCursor(il); if (val.TryGotoNext((MoveType)0, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchStfld(x, "RoR2.TemporaryOverlayInstance", "originalMaterial") })) { val.Index += 4; val.TryGotoNext((MoveType)0, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchStfld(x, "RoR2.TemporaryOverlayInstance", "originalMaterial") }); val.Emit(OpCodes.Ldarg_0); val.EmitDelegate>((Func)((Material material, EvisDash entityState) => (Material)(SkinChanges.DetectCaseMercEnum(((EntityState)entityState).gameObject) switch { MercColors.Red => Merc_Red.matHuntressFlashExpanded_Red, MercColors.Green => Merc_Green.matHuntressFlashExpanded_Green, MercColors.Pink => Merc_Pink.matHuntressFlashExpanded_Pink, _ => material, }))); } else { Log.LogWarning("IL Failed: Red Merc: IL.EntityStates.Merc.Evis.OnExit"); } } private static void Finisher_GroundLight2_OnEnter(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown //IL_003d: Unknown result type (might be due to invalid IL or missing references) ILCursor val = new ILCursor(il); if (val.TryGotoNext((MoveType)2, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchLdsfld(x, "EntityStates.Merc.Weapon.GroundLight2", "comboFinisherSwingEffectPrefab") })) { val.Emit(OpCodes.Ldarg_0); val.EmitDelegate>((Func)delegate(GameObject target, GroundLight2 entityState) { int num = SkinChanges.DetectCaseMerc(((EntityState)entityState).gameObject); EffectReplacer.Activate(((BasicMeleeAttack)entityState).hitEffectPrefab, num); SetExposeColor(num); return (GameObject)(num switch { 1 => Merc_Red.MercSwordFinisherSlash_Red, 2 => Merc_Green.MercSwordFinisherSlash_Green, 3 => Merc_Pink.MercSwordFinisherSlash_Pink, _ => target, }); }); } else { Log.LogWarning("IL Failed: Red Merc: GroundLight2_OnEnter"); } } private static void WhirlwindBase_FixedUpdate(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown //IL_003d: Unknown result type (might be due to invalid IL or missing references) ILCursor val = new ILCursor(il); if (val.TryGotoNext((MoveType)2, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchLdsfld(x, "EntityStates.Merc.WhirlwindBase", "swingEffectPrefab") })) { val.Emit(OpCodes.Ldarg_0); val.EmitDelegate>((Func)delegate(GameObject target, WhirlwindBase entityState) { EffectReplacer.ActivateMerc(target, ((Component)((EntityState)entityState).outer).gameObject); return target; }); } else { Log.LogWarning("IL Failed: Red Merc: WhirlwindBase_FixedUpdate"); } } private static void WhirlwindBase_OnEnter(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown //IL_003d: Unknown result type (might be due to invalid IL or missing references) ILCursor val = new ILCursor(il); if (val.TryGotoNext((MoveType)2, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchLdsfld(x, "EntityStates.Merc.WhirlwindBase", "hitEffectPrefab") })) { val.Emit(OpCodes.Ldarg_0); val.EmitDelegate>((Func)delegate(GameObject target, WhirlwindBase entityState) { EffectReplacer.ActivateMerc(target, ((Component)((EntityState)entityState).outer).gameObject); return target; }); } else { Log.LogWarning("IL Failed: Red Merc: WhirlwindBase_OnEnter"); } } private static void Uppercut_FixedUpdate(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown //IL_003d: Unknown result type (might be due to invalid IL or missing references) ILCursor val = new ILCursor(il); if (val.TryGotoNext((MoveType)2, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchLdsfld(x, "EntityStates.Merc.Uppercut", "swingEffectPrefab") })) { val.Emit(OpCodes.Ldarg_0); val.EmitDelegate>((Func)delegate(GameObject target, Uppercut entityState) { EffectReplacer.ActivateMerc(target, ((Component)((EntityState)entityState).outer).gameObject); return target; }); } else { Log.LogWarning("IL Failed: Red Merc: Uppercut_FixedUpdate"); } } private static void Uppercut_OnEnter(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown //IL_003d: Unknown result type (might be due to invalid IL or missing references) ILCursor val = new ILCursor(il); if (val.TryGotoNext((MoveType)2, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchLdsfld(x, "EntityStates.Merc.Uppercut", "hitEffectPrefab") })) { val.Emit(OpCodes.Ldarg_0); val.EmitDelegate>((Func)delegate(GameObject target, Uppercut entityState) { EffectReplacer.ActivateMerc(target, ((Component)((EntityState)entityState).outer).gameObject); return target; }); } else { Log.LogWarning("IL Failed: Red Merc: Uppercut_OnEnter"); } } private static void Assaulter2_OnEnter(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown //IL_003d: Unknown result type (might be due to invalid IL or missing references) ILCursor val = new ILCursor(il); if (val.TryGotoNext((MoveType)0, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchStfld(x, "RoR2.TemporaryOverlayInstance", "originalMaterial") })) { val.Emit(OpCodes.Ldarg_0); val.EmitDelegate>((Func)((Material material, EvisDash entityState) => (Material)(SkinChanges.DetectCaseMercEnum(((EntityState)entityState).gameObject) switch { MercColors.Red => Merc_Red.matMercEnergized_Red, MercColors.Green => Merc_Green.matMercEnergized_Green, MercColors.Pink => Merc_Pink.matMercEnergized_Pink, _ => material, }))); } else { Log.LogWarning("IL Failed: Red Merc: Assaulter2_OnEnter"); } } private static void MercRed_SpecialEvis(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown //IL_003d: Unknown result type (might be due to invalid IL or missing references) ILCursor val = new ILCursor(il); if (val.TryGotoNext((MoveType)2, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchLdsfld(x, "EntityStates.Merc.Evis", "blinkPrefab") })) { val.Emit(OpCodes.Ldarg_0); val.EmitDelegate>((Func)delegate(GameObject target, Evis entityState) { EffectReplacer.ActivateMerc(target, ((Component)((EntityState)entityState).outer).gameObject); return target; }); } else { Log.LogWarning("IL Failed: Red Merc: Evis.CreateBlinkEffect"); } } private static void Evis_FixedUpdate(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown //IL_003d: 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) ILCursor val = new ILCursor(il); if (val.TryGotoNext((MoveType)2, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchLdsfld(x, "EntityStates.Merc.Evis", "hitEffectPrefab") })) { val.Emit(OpCodes.Ldarg_0); val.EmitDelegate>((Func)delegate(GameObject target, Evis entityState) { EffectReplacer.ActivateMerc(target, ((Component)((EntityState)entityState).outer).gameObject); return target; }); } else { Log.LogWarning("IL Failed: Red Merc: Evis_FixedUpdate"); } if (val.TryGotoNext((MoveType)0, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchStfld(x, "RoR2.TemporaryOverlayInstance", "originalMaterial") })) { val.Emit(OpCodes.Ldarg_0); val.EmitDelegate>((Func)((Material material, Evis entityState) => (Material)(SkinChanges.DetectCaseMercEnum(((EntityState)entityState).gameObject) switch { MercColors.Red => Merc_Red.matMercEvisTarget_Red, MercColors.Green => Merc_Green.matMercEvisTarget_Green, MercColors.Pink => Merc_Pink.matMercEvisTarget_Pink, _ => material, }))); } else { Log.LogWarning("IL Failed: Red Merc: Evis_FixedUpdate"); } } public static void Special_Dash(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown //IL_0040: 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) ILCursor val = new ILCursor(il); if (val.TryGotoNext((MoveType)0, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchStfld(x, "RoR2.TemporaryOverlayInstance", "originalMaterial") })) { val.Emit(OpCodes.Ldarg_0); val.EmitDelegate>((Func)((Material material, EvisDash entityState) => (Material)(SkinChanges.DetectCaseMercEnum(((EntityState)entityState).gameObject) switch { MercColors.Red => Merc_Red.matHuntressFlashBright_Red, MercColors.Green => Merc_Green.matHuntressFlashBright_Green, MercColors.Pink => Merc_Pink.matHuntressFlashBright_Pink, _ => material, }))); val.Index += 4; val.TryGotoNext((MoveType)0, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchStfld(x, "RoR2.TemporaryOverlayInstance", "originalMaterial") }); val.Emit(OpCodes.Ldarg_0); val.EmitDelegate>((Func)((Material material, EvisDash entityState) => (Material)(SkinChanges.DetectCaseMercEnum(((EntityState)entityState).gameObject) switch { MercColors.Red => Merc_Red.matHuntressFlashExpanded_Red, MercColors.Green => Merc_Green.matHuntressFlashExpanded_Green, MercColors.Pink => Merc_Pink.matHuntressFlashExpanded_Pink, _ => material, }))); } else { Log.LogWarning("IL Failed: Red Merc: Merc.EvisDash.FixedUpdate"); } } } public static class Mercenary_Main { public static void Start() { Merc_Red.Start(); Merc_Red.MakeEffects_Red(); Merc_Green.Start(); Merc_Green.Merc_GreenEffects(); Merc_Pink.Start(); Merc_Pink.MakeEffects_Pink(); Mercenary_Hooks.Hooks(); GhostReplacements(); ((ResourceAvailability)(ref GameModeCatalog.availability)).CallWhenAvailable((Action)EffectReplacements); } public static void EffectReplacements() { //IL_0008: Unknown result type (might be due to invalid IL or missing references) //IL_000d: Unknown result type (might be due to invalid IL or missing references) //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Unknown result type (might be due to invalid IL or missing references) //IL_005c: Unknown result type (might be due to invalid IL or missing references) //IL_0061: Unknown result type (might be due to invalid IL or missing references) //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) //IL_00b0: Unknown result type (might be due to invalid IL or missing references) //IL_00b5: Unknown result type (might be due to invalid IL or missing references) //IL_00da: Unknown result type (might be due to invalid IL or missing references) //IL_00df: Unknown result type (might be due to invalid IL or missing references) //IL_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_012e: Unknown result type (might be due to invalid IL or missing references) //IL_0133: Unknown result type (might be due to invalid IL or missing references) //IL_0158: Unknown result type (might be due to invalid IL or missing references) //IL_015d: Unknown result type (might be due to invalid IL or missing references) //IL_0182: Unknown result type (might be due to invalid IL or missing references) //IL_0187: Unknown result type (might be due to invalid IL or missing references) //IL_01ac: Unknown result type (might be due to invalid IL or missing references) //IL_01b1: Unknown result type (might be due to invalid IL or missing references) GameObject val = null; val = Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/MercSwordSlashWhirlwind.prefab").WaitForCompletion(); EffectReplacer.SetupComponent(val, Merc_Red.MercSwordSlashWhirlwind_Red, Merc_Green.MercSwordSlashWhirlwind_Green, Merc_Pink.MercSwordSlashWhirlwind_Pink, restart: false); val = Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/MercSwordUppercutSlash.prefab").WaitForCompletion(); EffectReplacer.SetupComponent(val, Merc_Red.MercSwordUppercutSlash_Red, Merc_Green.MercSwordUppercutSlash_Green, Merc_Pink.MercSwordUppercutSlash_Pink, restart: false); val = Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/ImpactMercAssaulter.prefab").WaitForCompletion(); EffectReplacer.SetupComponent(val, Merc_Red.ImpactMercAssaulter_Red, Merc_Green.ImpactMercAssaulter_Green, Merc_Pink.ImpactMercAssaulter_Pink, restart: false); val = Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/ImpactMercFocusedAssault.prefab").WaitForCompletion(); EffectReplacer.SetupComponent(val, Merc_Red.ImpactMercFocusedAssault_Red, Merc_Green.ImpactMercFocusedAssault_Green, Merc_Pink.ImpactMercFocusedAssault_Pink, restart: false); val = Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/MercFocusedAssaultOrbEffect.prefab").WaitForCompletion(); EffectReplacer.SetupComponent(val, Merc_Red.MercFocusedAssaultOrbEffect_Red, Merc_Green.MercFocusedAssaultOrbEffect_Green, Merc_Pink.MercFocusedAssaultOrbEffect_Pink, restart: false); val = Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/ImpactMercEvis.prefab").WaitForCompletion(); EffectReplacer.SetupComponent(val, Merc_Red.ImpactMercEvis_Red, Merc_Green.ImpactMercEvis_Green, Merc_Pink.ImpactMercEvis_Pink, restart: false); val = Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/OmniImpactVFXSlashMercEvis.prefab").WaitForCompletion(); EffectReplacer.SetupComponent(val, Merc_Red.OmniImpactVFXSlashMercEvis_Red, Merc_Green.OmniImpactVFXSlashMercEvis_Green, Merc_Pink.OmniImpactVFXSlashMercEvis_Pink, restart: false); val = Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/OmniImpactVFXSlashMerc.prefab").WaitForCompletion(); EffectReplacer.SetupComponent(val, Merc_Red.OmniImpactVFXSlashMerc_Red, Merc_Green.OmniImpactVFXSlashMerc_Green, Merc_Pink.OmniImpactVFXSlashMerc_Pink, restart: false); val = Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/MercExposeConsumeEffect.prefab").WaitForCompletion(); EffectReplacer.SetupComponent(val, Merc_Red.MercExposeConsumeEffect_Red, Merc_Green.MercExposeConsumeEffect_Green, Merc_Pink.MercExposeConsumeEffect_Pink, restart: false); val = Addressables.LoadAssetAsync((object)"RoR2/Base/Huntress/HuntressBlinkEffect.prefab").WaitForCompletion(); EffectReplacer.SetupComponent(val, Merc_Red.HuntressBlinkEffect_Red, Merc_Green.HuntressBlinkEffect_Green, Merc_Pink.HuntressBlinkEffect_Pink, restart: true); val = Addressables.LoadAssetAsync((object)"RoR2/Base/Huntress/HuntressFireArrowRain.prefab").WaitForCompletion(); EffectReplacer.SetupComponent(val, Merc_Red.HuntressFireArrowRain_Red, Merc_Green.HuntressFireArrowRain_Green, Merc_Pink.HuntressFireArrowRain_Pink, restart: true); } public static void GhostReplacements() { GameObject val = LegacyResourcesAPI.Load("Prefabs/projectiles/EvisProjectile"); GameObject val2 = LegacyResourcesAPI.Load("Prefabs/projectiles/EvisOverlapProjectile"); ProjectileGhostReplacer projectileGhostReplacer = val.AddComponent(); ProjectileGhostReplacer projectileGhostReplacer2 = val2.AddComponent(); projectileGhostReplacer.condition = SkinChanges.Case.Merc; projectileGhostReplacer2.condition = SkinChanges.Case.Merc; projectileGhostReplacer.ghostPrefab_1 = Merc_Red.EvisProjectileGhost_Red; projectileGhostReplacer.impactPrefab_1 = Merc_Red.MercSwordFinisherSlash_Red; projectileGhostReplacer.ghostPrefab_2 = Merc_Green.EvisProjectileGhost_Green; projectileGhostReplacer.impactPrefab_2 = Merc_Green.MercSwordFinisherSlash_Green; projectileGhostReplacer.ghostPrefab_3 = Merc_Pink.EvisProjectileGhost_Pink; projectileGhostReplacer.impactPrefab_3 = Merc_Pink.MercSwordFinisherSlash_Pink; projectileGhostReplacer.useReplacement = false; projectileGhostReplacer2.ghostPrefab_1 = Merc_Red.EvisOverlapProjectileGhost_Red; projectileGhostReplacer2.ghostPrefab_2 = Merc_Green.EvisOverlapProjectileGhost_Green; projectileGhostReplacer2.ghostPrefab_3 = Merc_Pink.EvisOverlapProjectileGhost_Pink; } public static void BackupSkin() { //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) SkinDef val = Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/skinMercAlt.asset").WaitForCompletion(); SkinDef val2 = Object.Instantiate(val); Sprite icon = Assets.Bundle.LoadAsset("Assets/WQoL/SkinRamps/texMercOniBlues.png"); val2.icon = icon; Skins.AddSkinToCharacter(LegacyResourcesAPI.Load("Prefabs/CharacterBodies/MercBody"), val2); } } public static class Skins_Merc { public static void Start() { //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_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_0158: Unknown result type (might be due to invalid IL or missing references) //IL_015d: Unknown result type (might be due to invalid IL or missing references) //IL_0018: Unknown result type (might be due to invalid IL or missing references) //IL_001d: Unknown result type (might be due to invalid IL or missing references) //IL_0063: Unknown result type (might be due to invalid IL or missing references) //IL_0068: Unknown result type (might be due to invalid IL or missing references) //IL_00b0: Unknown result type (might be due to invalid IL or missing references) //IL_00b5: Unknown result type (might be due to invalid IL or missing references) //IL_01bf: 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_0202: Unknown result type (might be due to invalid IL or missing references) //IL_0207: Unknown result type (might be due to invalid IL or missing references) //IL_0228: Unknown result type (might be due to invalid IL or missing references) //IL_022d: Unknown result type (might be due to invalid IL or missing references) //IL_0255: 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_0298: Unknown result type (might be due to invalid IL or missing references) //IL_029d: Unknown result type (might be due to invalid IL or missing references) //IL_02be: Unknown result type (might be due to invalid IL or missing references) //IL_02c3: Unknown result type (might be due to invalid IL or missing references) //IL_02eb: Unknown result type (might be due to invalid IL or missing references) //IL_02f0: Unknown result type (might be due to invalid IL or missing references) //IL_032e: Unknown result type (might be due to invalid IL or missing references) //IL_0333: Unknown result type (might be due to invalid IL or missing references) //IL_0354: Unknown result type (might be due to invalid IL or missing references) //IL_0359: Unknown result type (might be due to invalid IL or missing references) if (WConfig.cfgSkinMercRedSword.Value) { Material val = Object.Instantiate(Addressables.LoadAssetAsync((object)"fb5eba8da12e09749b69b1a7f24afc00").WaitForCompletion()); ((Object)val).name = "matOniMercSword"; val.mainTexture = (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/SkinScalable/texOniMercSwordDiffuse.png"); val.SetColor("_EmColor", Color32.op_Implicit(new Color32((byte)125, (byte)64, (byte)64, byte.MaxValue))); val.SetTexture("_FlowHeightRamp", (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/SkinRamps/texRampFallbootsRed.png")); val.SetTexture("_FresnelRamp", (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/SkinRamps/texRampHuntressRed.png")); SkinDefParams val2 = Addressables.LoadAssetAsync((object)"04f0dc07e902aaf4980ae949446cc6e9").WaitForCompletion(); val2.rendererInfos[1].defaultMaterialAddress = null; val2.rendererInfos[1].defaultMaterial = val; } GameObject val3 = Addressables.LoadAssetAsync((object)"c9d3d0b5ada36b74e83b3a2709467be2").WaitForCompletion(); ((Object)((Component)val3.transform.GetChild(0)).GetComponent().baseLightInfos[0].light).name = "Point Light"; ((Component)val3.transform.GetChild(0)).gameObject.AddComponent(); SkinDefParams val4 = Addressables.LoadAssetAsync((object)"47240317eb88bd240a032186e1275fbb").WaitForCompletion(); GameObject val5 = Addressables.LoadAssetAsync((object)"c9898f15e54a0194dbd2ab62ad507bd4").WaitForCompletion(); val4.lightReplacements = ((Component)val5.transform.GetChild(0).GetChild(0)).GetComponent().baseLightInfos; ((Component)val5.transform.GetChild(0).GetChild(0)).gameObject.AddComponent(); if (WConfig.cfgSkinMercRed.Value) { SkinDefParams val6 = Addressables.LoadAssetAsync((object)"04f0dc07e902aaf4980ae949446cc6e9").WaitForCompletion(); LightInfo[] array = (LightInfo[])(object)new LightInfo[2]; Array.Copy(val4.lightReplacements, array, 2); array[0].defaultColor = new Color(1f, 0.2f, 0.1f, 1f); array[1].defaultColor = new Color(1f, 0.15f, 0.15f, 1f); val6.lightReplacements = array; } if (WConfig.cfgSkinMercGreen.Value) { SkinDefParams val7 = Addressables.LoadAssetAsync((object)"5162e57e36a5758428c406bbe339fe24").WaitForCompletion(); LightInfo[] array2 = (LightInfo[])(object)new LightInfo[2]; Array.Copy(val4.lightReplacements, array2, 2); array2[0].defaultColor = new Color(0.2f, 1f, 0.1f, 1f); array2[1].defaultColor = new Color(0.15f, 0.6f, 0.15f, 1f); val7.lightReplacements = array2; } if (WConfig.cfgSkinMercPink.Value) { SkinDefParams val8 = Addressables.LoadAssetAsync((object)"RoR2/Base/Merc/skinMercAltVulture_params.asset").WaitForCompletion(); LightInfo[] array3 = (LightInfo[])(object)new LightInfo[2]; Array.Copy(val4.lightReplacements, array3, 2); array3[0].defaultColor = new Color(1f, 0.609f, 0.9f, 1f); array3[1].defaultColor = new Color(1f, 0.609f, 0.9f, 1f); val8.lightReplacements = array3; } if (WConfig.cfgSkinMercSS2.Value) { ModelSkinController component = ((Component)val5.transform.GetChild(0).GetChild(0)).GetComponent(); } } } public class SkinMercListener : MonoBehaviour { public void OnEnable() { ((Component)this).GetComponent().onSkinApplied += OnMercSkinApplied; } public void OnDisable() { ((Component)this).GetComponent().onSkinApplied -= OnMercSkinApplied; } private void OnMercSkinApplied(int skinIndex) { //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) //IL_019d: Unknown result type (might be due to invalid IL or missing references) //IL_01a2: Unknown result type (might be due to invalid IL or missing references) //IL_035e: Unknown result type (might be due to invalid IL or missing references) //IL_0373: Unknown result type (might be due to invalid IL or missing references) //IL_0388: Unknown result type (might be due to invalid IL or missing references) //IL_039d: Unknown result type (might be due to invalid IL or missing references) //IL_0309: Unknown result type (might be due to invalid IL or missing references) //IL_030e: Unknown result type (might be due to invalid IL or missing references) //IL_0333: Unknown result type (might be due to invalid IL or missing references) //IL_0338: Unknown result type (might be due to invalid IL or missing references) CharacterModel component = ((Component)this).GetComponent(); if (!Object.op_Implicit((Object)(object)component)) { return; } ChildLocator component2 = ((Component)this).GetComponent(); ModelSkinController component3 = ((Component)this).GetComponent(); SkinDef val = component3.skins[skinIndex]; bool flag = (((Object)val).name.EndsWith("Alt") && WConfig.cfgSkinMercRed.Value) || ((Object)val).name.EndsWith("Red"); bool flag2 = (((Object)val).name.EndsWith("Colossus") && WConfig.cfgSkinMercGreen.Value) || ((Object)val).name.EndsWith("Green"); bool flag3 = ((Object)val).name.EndsWith("Vulture") && WConfig.cfgSkinMercPink.Value; bool flag4 = ((Object)val).name.StartsWith("skinMercAltVestige") && WConfig.cfgSkinMercSS2.Value; if (Object.op_Implicit((Object)(object)component.body)) { ColorThisMerc colorThisMerc = UnityObjectExtensions.EnsureComponent(((Component)component.body).gameObject); if (flag || flag4) { colorThisMerc.ThisColorEnum = MercColors.Red; } else if (flag2) { colorThisMerc.ThisColorEnum = MercColors.Green; } else if (flag3) { colorThisMerc.ThisColorEnum = MercColors.Pink; } colorThisMerc.ThisColor = (int)colorThisMerc.ThisColorEnum; } if ((Object)(object)component2 == (Object)null) { Log.LogWarning("mdlMerc without childLocator"); return; } Transform val2 = component2.FindChild("PreDashEffect"); if ((Object)(object)val2 == (Object)null) { Log.LogMessage("mdlMerc without PreDashEffect"); return; } Color white = Color.white; Color white2 = Color.white; Material val3 = null; if (flag) { ((Color)(ref white))..ctor(1f, 0.5613f, 0.6875f, 1f); ((Color)(ref white2))..ctor(1f, 0.2f, 0.2f, 1f); val3 = Merc_Red.matMercIgnition_Red; } else if (flag2) { ((Color)(ref white))..ctor(0.6875f, 1f, 0.5613f, 1f); ((Color)(ref white2))..ctor(0.2f, 1f, 0.2f, 1f); val3 = Merc_Green.matMercIgnition_Green; } else if (flag3) { ((Color)(ref white))..ctor(0.844f, 0.561f, 0.844f, 1f); ((Color)(ref white2))..ctor(0.72f, 0.3f, 0.81f, 1f); val3 = Merc_Pink.matMercIgnition_Pink; } else if (flag4) { ((Color)(ref white))..ctor(1f, 0.7f, 0.5f, 1f); ((Color)(ref white2))..ctor(1f, 0.62f, 0.203f, 1f); val3 = Merc_Red.matMercIgnition_Red; if (component.baseLightInfos.Length >= 2) { component.baseLightInfos[0].defaultColor = new Color(1f, 0.609f, 0f, 1f); component.baseLightInfos[1].defaultColor = new Color(1f, 0.609f, 0f, 1f); } } if ((Object)(object)val3 != (Object)null) { ((Component)val2.GetChild(0)).GetComponent().startColor = white; ((Component)val2.GetChild(1)).GetComponent().color = white2; ((Component)val2.GetChild(2)).GetComponent().startColor = white; ((Component)val2.GetChild(3)).GetComponent().startColor = white; ((Renderer)((Component)val2.GetChild(2)).GetComponent()).material = val3; ((Renderer)((Component)val2.GetChild(3)).GetComponent()).material = val3; } } } public static class OtherEnemies { [CompilerGenerated] private static class <>O { public static Manipulator <0>__TwistedFire; } public static Material matEliteBead; public static void Start() { //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) //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_0029: 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_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_0170: Unknown result type (might be due to invalid IL or missing references) //IL_0175: Unknown result type (might be due to invalid IL or missing references) //IL_00be: Unknown result type (might be due to invalid IL or missing references) //IL_00c3: Unknown result type (might be due to invalid IL or missing references) //IL_00e9: Unknown result type (might be due to invalid IL or missing references) //IL_00f9: 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_0124: Unknown result type (might be due to invalid IL or missing references) //IL_0134: Unknown result type (might be due to invalid IL or missing references) //IL_0139: 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) if (WConfig.SulfurPoolsSkin.Value) { GameObject val = Addressables.LoadAssetAsync((object)"RoR2/Base/Beetle/BeetleBody.prefab").WaitForCompletion(); GameObject val2 = Addressables.LoadAssetAsync((object)"RoR2/Base/BeetleGuard/BeetleGuardBody.prefab").WaitForCompletion(); GameObject val3 = Addressables.LoadAssetAsync((object)"RoR2/Base/BeetleQueen/BeetleQueen2Body.prefab").WaitForCompletion(); val.AddComponent().sceneDef = SceneList.SulfurPools; val2.AddComponent().sceneDef = SceneList.SulfurPools; val3.AddComponent().sceneDef = SceneList.SulfurPools; } ChangeSkinOnStage changeSkinOnStage = Addressables.LoadAssetAsync((object)"f21a0264f74389246acbbc5e281092b1").WaitForCompletion().AddComponent(); changeSkinOnStage.sceneDef = SceneList.RootJungle; if (WConfig.cfgVoidAllyCyanEyes.Value) { Material val4 = Addressables.LoadAssetAsync((object)"RoR2/Base/Nullifier/matNullifierAlly.mat").WaitForCompletion(); val4.SetColor("_EmColor", new Color(0f, 3f, 2.25f, 1f)); val4 = Addressables.LoadAssetAsync((object)"RoR2/DLC1/VoidJailer/matVoidJailerEyesAlly.mat").WaitForCompletion(); val4.SetColor("_EmColor", new Color(0f, 1f, 0.75f, 1f)); val4 = Addressables.LoadAssetAsync((object)"RoR2/DLC1/VoidMegaCrab/matVoidMegaCrabAlly.mat").WaitForCompletion(); val4.SetColor("_EmColor", new Color(0f, 2f, 1f, 1f)); } ScorchlingController component = Addressables.LoadAssetAsync((object)"4f70f94ff7396dd43b72e0bd263f42a9").WaitForCompletion().GetComponent(); component.timeInAirToShutOffDustTrail = 9999f; } public static void CallLate() { //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_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_006d: Expected O, but got Unknown if (WConfig.cfgDarkTwisted.Value) { EliteRamp.AddRamp(Elites.Bead, Assets.Bundle.LoadAsset("Assets/WQoL/SkinRamps/RampEliteBead.png")); } Addressables.LoadAssetAsync((object)"RoR2/DLC1/edSecretSpeed.asset").WaitForCompletion().shaderEliteRampIndex = 0; if (WConfig.cfgTwistedFire.Value) { object obj = <>O.<0>__TwistedFire; if (obj == null) { Manipulator val = TwistedFire; <>O.<0>__TwistedFire = val; obj = (object)val; } AffixBeadBehavior.Update += (Manipulator)obj; } } private static void TwistedFire(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown ILCursor val = new ILCursor(il); val.TryGotoNext((MoveType)0, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchStfld(x, "RoR2.AffixBeadBehavior", "affixBeadWard") }); if (val.TryGotoPrev((MoveType)2, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchLdarg(x, 0) })) { val.EmitDelegate>((Func)delegate(AffixBeadBehavior self) { //IL_005a: 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) if ((Object)(object)self.beadHolderVFX == (Object)null && NetworkServer.active) { self.beadHolderVFX = Object.Instantiate(self.beadHolderVFXReference); self.beadHolderVFX.GetComponent().AttachToGameObjectAndSpawn(((Component)((ItemBehavior)self).body).gameObject, "Head"); Transform transform = self.beadHolderVFX.transform; transform.localScale *= ((ItemBehavior)self).body.modelLocator.modelScaleCompensation; } return self; }); } else { Log.LogWarning("TwistedFire FAILED"); } } } public class ChangeSkinOnStage : MonoBehaviour { public SceneDef sceneDef; public SceneIndex SceneIndex; public uint localSkinIndex = 1u; public void Start() { if ((Object)(object)SceneCatalog.mostRecentSceneDef == (Object)(object)sceneDef) { ((Component)this).GetComponent().skinIndex = localSkinIndex; } } } public static class Skins_Engi { public static Material matEngiTurretAlt; public static Material matEngiTurretColossus; public static Material matEngiTurretColossusProjectiles; public static Material matEngiTrail_Alt; public static void Start() { if (WConfig.cfgSkinMisc.Value) { FixedTurret(); AltTrail(); } if (WConfig.cfgSkinEngiHarpoons.Value) { Harpoons(); } } public static void AltTrail() { //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_0041: Unknown result type (might be due to invalid IL or missing references) //IL_0046: Unknown result type (might be due to invalid IL or missing references) //IL_00aa: 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_00f8: Unknown result type (might be due to invalid IL or missing references) //IL_00fd: Unknown result type (might be due to invalid IL or missing references) //IL_00fe: Unknown result type (might be due to invalid IL or missing references) //IL_0107: Unknown result type (might be due to invalid IL or missing references) //IL_0150: Unknown result type (might be due to invalid IL or missing references) //IL_0155: Unknown result type (might be due to invalid IL or missing references) //IL_015a: 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) matEngiTrail_Alt = Object.Instantiate(Addressables.LoadAssetAsync((object)"RoR2/Base/Engi/matEngiTrail.mat").WaitForCompletion()); matEngiTrail_Alt.SetTexture("_RemapTex", (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/SkinRamps/texRampEngiAlt.png")); SkinDefParams val = Addressables.LoadAssetAsync((object)"eab24449944ca9141b8da8adf7020611").WaitForCompletion(); val.rendererInfos[0].defaultMaterial = matEngiTrail_Alt; val.rendererInfos[0].defaultMaterialAddress = null; val.rendererInfos[1].defaultMaterial = matEngiTrail_Alt; val.rendererInfos[1].defaultMaterialAddress = null; val.lightReplacements = (LightInfo[])(object)new LightInfo[2] { new LightInfo { light = ((Component)((Component)val.rendererInfos[0].renderer).transform.parent.GetChild(2)).GetComponent(), defaultColor = new Color(0f, 0.77f, 0.77f, 1f) }, new LightInfo { light = ((Component)((Component)val.rendererInfos[1].renderer).transform.parent.GetChild(2)).GetComponent(), defaultColor = new Color(0f, 0.77f, 0.77f, 1f) } }; } public static void Harpoons() { //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_001f: Unknown result type (might be due to invalid IL or missing references) //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_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_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_005b: Unknown result type (might be due to invalid IL or missing references) //IL_0060: Unknown result type (might be due to invalid IL or missing references) //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_009e: 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_0121: Unknown result type (might be due to invalid IL or missing references) //IL_0150: Unknown result type (might be due to invalid IL or missing references) //IL_0155: Unknown result type (might be due to invalid IL or missing references) //IL_0194: 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_0231: Unknown result type (might be due to invalid IL or missing references) //IL_02a0: Unknown result type (might be due to invalid IL or missing references) //IL_02a5: Unknown result type (might be due to invalid IL or missing references) //IL_02bf: Unknown result type (might be due to invalid IL or missing references) //IL_02c4: Unknown result type (might be due to invalid IL or missing references) //IL_0340: Unknown result type (might be due to invalid IL or missing references) Material val = Object.Instantiate(Addressables.LoadAssetAsync((object)"RoR2/Base/Engi/matEngiTrail.mat").WaitForCompletion()); SkinDefParams val2 = Addressables.LoadAssetAsync((object)"RoR2/Base/Engi/skinEngiAlt_params.asset").WaitForCompletion(); SkinDefParams val3 = Addressables.LoadAssetAsync((object)"RoR2/Base/Engi/skinEngiAltColossus_params.asset").WaitForCompletion(); GameObject projectilePrefab = Addressables.LoadAssetAsync((object)"RoR2/Base/Engi/EngiHarpoon.prefab").WaitForCompletion(); GameObject val4 = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Engi/EngiHarpoonGhost.prefab").WaitForCompletion(), "EngiHarpoonGhostSkin_Alt", false); GameObject val5 = PrefabAPI.InstantiateClone(Addressables.LoadAssetAsync((object)"RoR2/Base/Engi/EngiHarpoonGhost.prefab").WaitForCompletion(), "EngiHarpoonGhostSkin_Sots", false); ref ProjectileGhostReplacement[] projectileGhostReplacements = ref val2.projectileGhostReplacements; ProjectileGhostReplacement val6 = new ProjectileGhostReplacement { projectileGhostReplacementPrefab = val4, projectilePrefab = projectilePrefab }; ArrayUtils.ArrayAppend(ref projectileGhostReplacements, ref val6); ref ProjectileGhostReplacement[] projectileGhostReplacements2 = ref val3.projectileGhostReplacements; val6 = new ProjectileGhostReplacement { projectileGhostReplacementPrefab = val5, projectilePrefab = projectilePrefab }; ArrayUtils.ArrayAppend(ref projectileGhostReplacements2, ref val6); ParticleSystemRenderer component = ((Component)val4.transform.GetChild(0)).GetComponent(); Material val7 = Object.Instantiate(((Renderer)component).material); val7.SetColor("_TintColor", new Color(0.1f, 1f, 1f, 1f)); ((Renderer)((Component)val4.transform.GetChild(1)).GetComponent()).material = AssetAsyncReferenceManager.LoadAsset(val2.rendererInfos[2].defaultMaterialAddress, (AsyncReferenceHandleUnloadType)1).WaitForCompletion(); TrailRenderer component2 = ((Component)val4.transform.GetChild(1).GetChild(0)).GetComponent(); component2.startColor = new Color(0.3f, 0.9f, 0.8f, 0f); component2.endColor = new Color(0.3f, 0.9f, 0.8f, 0f); Material val8 = Object.Instantiate(((Renderer)component2).material); val8.SetTexture("_RemapTex", (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/SkinRamps/texRampEngiAlt.png")); ((Renderer)component2).material = val8; component = ((Component)val4.transform.GetChild(3)).GetComponent(); Material val9 = Object.Instantiate(((Renderer)component).material); val9.SetColor("_TintColor", new Color(0.6f, 1f, 0.2f, 1f)); ((Renderer)component).material = val9; component = ((Component)val5.transform.GetChild(0)).GetComponent(); ((Renderer)((Component)val5.transform.GetChild(1)).GetComponent()).material = matEngiTurretColossusProjectiles; component2 = ((Component)val5.transform.GetChild(1).GetChild(0)).GetComponent(); component2.startColor = Color32.op_Implicit(new Color32(byte.MaxValue, (byte)160, (byte)60, (byte)0)); component2.endColor = Color32.op_Implicit(new Color32(byte.MaxValue, (byte)160, (byte)60, (byte)0)); val8 = Object.Instantiate(((Renderer)component2).material); val8.SetTexture("_RemapTex", (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/SkinRamps/texRampEngiColossus.png")); ((Renderer)component2).material = val8; component = ((Component)val5.transform.GetChild(3)).GetComponent(); val9 = Object.Instantiate(((Renderer)component).material); val9.SetColor("_TintColor", new Color(0.6f, 1f, 0.2f, 1f)); ((Renderer)component).material = val9; } public static void FixedTurret() { //IL_0026: Unknown result type (might be due to invalid IL or missing references) //IL_002b: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_003f: Unknown result type (might be due to invalid IL or missing references) //IL_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_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_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_0135: Unknown result type (might be due to invalid IL or missing references) //IL_0212: 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_0235: Unknown result type (might be due to invalid IL or missing references) //IL_023a: Unknown result type (might be due to invalid IL or missing references) //IL_02b1: Unknown result type (might be due to invalid IL or missing references) //IL_02b6: Unknown result type (might be due to invalid IL or missing references) //IL_02c6: Unknown result type (might be due to invalid IL or missing references) //IL_02cb: Unknown result type (might be due to invalid IL or missing references) //IL_02db: Unknown result type (might be due to invalid IL or missing references) //IL_02e0: 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) //IL_02f5: Unknown result type (might be due to invalid IL or missing references) Texture2D mainTexture = Assets.Bundle.LoadAsset("Assets/WQoL/SkinScalable/texEngiTurretDiffuseAlt.png"); Texture2D mainTexture2 = Assets.Bundle.LoadAsset("Assets/WQoL/SkinScalable/texEngiTurretAltColossusDiffuse.png"); Material val = Addressables.LoadAssetAsync((object)"5e174f0491412c341a6615fe95839efe").WaitForCompletion(); matEngiTurretAlt = Object.Instantiate(Addressables.LoadAssetAsync((object)"a9b91ae3f60a5d14a97ec97e5991dc57").WaitForCompletion()); matEngiTurretAlt.mainTexture = (Texture)(object)mainTexture; matEngiTurretAlt.SetColor("_EmColor", Color32.op_Implicit(new Color32((byte)28, (byte)194, (byte)182, byte.MaxValue))); ((Object)matEngiTurretAlt).name = "matEngiTurretAlt"; matEngiTurretColossusProjectiles = Object.Instantiate(Addressables.LoadAssetAsync((object)"a9b91ae3f60a5d14a97ec97e5991dc57").WaitForCompletion()); matEngiTurretColossusProjectiles.mainTexture = (Texture)(object)mainTexture2; matEngiTurretColossusProjectiles.SetColor("_EmColor", Color32.op_Implicit(new Color32(byte.MaxValue, (byte)128, (byte)0, byte.MaxValue))); ((Object)matEngiTurretColossusProjectiles).name = "matEngiTurretColossusTool"; matEngiTurretColossus = Object.Instantiate(matEngiTurretAlt); matEngiTurretColossus.mainTexture = (Texture)(object)mainTexture2; matEngiTurretColossus.SetColor("_EmColor", new Color(1f, 0.5f, -1f, 1f)); matEngiTurretColossus.SetTexture("_FresnelRamp", val.GetTexture("_FresnelRamp")); matEngiTurretColossus.SetTexture("_FresnelMask", matEngiTurretAlt.GetTexture("_EmTex")); matEngiTurretColossus.EnableKeyword("FRESNEL_EMISSION"); matEngiTurretColossus.SetFloat("_EmPower", 0.2f); matEngiTurretColossus.SetFloat("_FresnelBoost", 30f); matEngiTurretColossus.SetFloat("_FresnelPower", 3f); ((Object)matEngiTurretColossus).name = "matEngiTurretColossus"; ((Renderer)LegacyResourcesAPI.Load("Prefabs/projectileghosts/EngiGrenadeGhostSkin2").GetComponentInChildren()).material = matEngiTurretAlt; ((Renderer)LegacyResourcesAPI.Load("Prefabs/projectileghosts/EngiMineGhost2").GetComponentInChildren()).material = matEngiTurretAlt; ((Renderer)Addressables.LoadAssetAsync((object)"RoR2/Base/Engi/EngiGrenadeGhostSkin3.prefab").WaitForCompletion().GetComponentInChildren()).material = matEngiTurretColossusProjectiles; ((Renderer)Addressables.LoadAssetAsync((object)"RoR2/Base/Engi/EngiMineGhost3.prefab").WaitForCompletion().GetComponentInChildren()).material = matEngiTurretColossusProjectiles; Transform transform = ((Component)LegacyResourcesAPI.Load("Prefabs/characterdisplays/EngiDisplay").transform.Find("mdlEngi/EngiArmature/ROOT/base/stomach/chest/upper_arm.l/lower_arm.l/hand.l/IKBoneStart/IKBoneMid/MineHolder/")).transform; ((Renderer)((Component)transform.GetChild(0).GetChild(2)).GetComponentInChildren()).material = matEngiTurretAlt; ((Renderer)((Component)transform.GetChild(0).GetChild(3)).GetComponentInChildren()).material = matEngiTurretColossusProjectiles; SkinDefParams val2 = Addressables.LoadAssetAsync((object)"b98626ea4e0476344af7e02f66c2d5e0").WaitForCompletion(); SkinDefParams val3 = Addressables.LoadAssetAsync((object)"c8f3b0a0035b6734783a9fde35234ba3").WaitForCompletion(); SkinDefParams val4 = Addressables.LoadAssetAsync((object)"82a114b330c509e4c8ea6872ea789478").WaitForCompletion(); SkinDefParams val5 = Addressables.LoadAssetAsync((object)"b71e9d62b572c4b4e945699e105566e7").WaitForCompletion(); val2.rendererInfos[0].defaultMaterial = matEngiTurretAlt; val2.rendererInfos[0].defaultMaterialAddress = null; val4.rendererInfos[0].defaultMaterial = matEngiTurretAlt; val4.rendererInfos[0].defaultMaterialAddress = null; val3.rendererInfos[0].defaultMaterial = matEngiTurretColossus; val3.rendererInfos[0].defaultMaterialAddress = null; val5.rendererInfos[0].defaultMaterial = matEngiTurretColossus; val5.rendererInfos[0].defaultMaterialAddress = null; } } public static class Skins_Loader { [Serializable] [CompilerGenerated] private sealed class <>c { public static readonly <>c <>9 = new <>c(); public static hook_SetHookReference <>9__1_0; internal void b__1_0(orig_SetHookReference orig, FireHook self, GameObject hook) { if (LoaderFistAllowed[((EntityState)self).characterBody.skinIndex]) { ((Renderer)((Component)hook.transform.GetChild(0)).GetComponent()).material = ((Renderer)((Component)((EntityState)self).modelLocator.modelTransform.GetChild(1)).GetComponent()).material; } orig.Invoke(self, hook); } } public static bool[] LoaderFistAllowed; public static void Start() { //IL_0006: 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_0088: Expected O, but got Unknown SkinDef[] array = SkinCatalog.FindSkinsForBody(BodyPrefabs.LoaderBody.bodyIndex); LoaderFistAllowed = new bool[array.Length]; LoaderFistAllowed[0] = false; for (int i = 1; i < array.Length; i++) { if (!((Object)array[i]).name.Contains("Colossus")) { LoaderFistAllowed[i] = true; } else { LoaderFistAllowed[i] = false; } } object obj = <>c.<>9__1_0; if (obj == null) { hook_SetHookReference val = delegate(orig_SetHookReference orig, FireHook self, GameObject hook) { if (LoaderFistAllowed[((EntityState)self).characterBody.skinIndex]) { ((Renderer)((Component)hook.transform.GetChild(0)).GetComponent()).material = ((Renderer)((Component)((EntityState)self).modelLocator.modelTransform.GetChild(1)).GetComponent()).material; } orig.Invoke(self, hook); }; <>c.<>9__1_0 = val; obj = (object)val; } FireHook.SetHookReference += (hook_SetHookReference)obj; } } public static class Skins_REX { public static void Start() { //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_001a: Unknown result type (might be due to invalid IL or missing references) //IL_001f: Unknown result type (might be due to invalid IL or missing references) //IL_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_00a5: 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_0123: Unknown result type (might be due to invalid IL or missing references) //IL_0128: Unknown result type (might be due to invalid IL or missing references) //IL_013c: 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_0179: Unknown result type (might be due to invalid IL or missing references) //IL_017e: Unknown result type (might be due to invalid IL or missing references) //IL_0192: Unknown result type (might be due to invalid IL or missing references) //IL_01b4: Unknown result type (might be due to invalid IL or missing references) //IL_01cf: 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_01e8: 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) //IL_0214: Unknown result type (might be due to invalid IL or missing references) //IL_0219: Unknown result type (might be due to invalid IL or missing references) //IL_022d: Unknown result type (might be due to invalid IL or missing references) //IL_023e: Unknown result type (might be due to invalid IL or missing references) Material val = Addressables.LoadAssetAsync((object)"RoR2/Base/Treebot/matTreebotTreeFlower.mat").WaitForCompletion(); Material val2 = Addressables.LoadAssetAsync((object)"63e4556772c5f2d42a728d700b486682").WaitForCompletion(); Material val3 = Object.Instantiate(val); Material val4 = Object.Instantiate(val2); Texture2D mainTexture = Assets.Bundle.LoadAsset("Assets/WQoL/SkinScalable/texTreebotVineForColossus.png"); val3.mainTexture = (Texture)(object)mainTexture; SkinDef val5 = Addressables.LoadAssetAsync((object)"RoR2/Base/Treebot/skinTreebotAltColossus.asset").WaitForCompletion(); Renderer component = (Renderer)(object)((Component)val5.rootObject.transform.GetChild(5).GetChild(0).GetChild(2)).GetComponent(); val4.SetColor("_TintColor", new Color(0.1804f, 0.1804f, 0.1804f, 1f)); val4.SetColor("_VertColor", new Color(0.8784f, 0.3176f, 0.4084f, 1f)); val4.SetFloat("_GradientWidth", 144f); val4.SetFloat("_EmBoost", 0.1f); val4.SetTexture("_RemapTex", (Texture)null); val4.SetTexture("_EmTex", (Texture)null); val4.SetTexture("_ScrollTex", (Texture)null); SkinDefParams val6 = Addressables.LoadAssetAsync((object)"1ce7132e738187a4782795e7ac6a3232").WaitForCompletion(); ref RendererInfo[] rendererInfos = ref val6.rendererInfos; RendererInfo val7 = new RendererInfo { defaultMaterialAddress = val6.rendererInfos[1].defaultMaterialAddress, defaultShadowCastingMode = (ShadowCastingMode)0, renderer = component }; ArrayUtils.ArrayAppend(ref rendererInfos, ref val7); SkinDefParams val8 = Addressables.LoadAssetAsync((object)"RoR2/Base/Treebot/skinTreebotAlt_params.asset").WaitForCompletion(); ref RendererInfo[] rendererInfos2 = ref val8.rendererInfos; val7 = new RendererInfo { defaultMaterialAddress = val8.rendererInfos[1].defaultMaterialAddress, defaultShadowCastingMode = (ShadowCastingMode)0, renderer = component }; ArrayUtils.ArrayAppend(ref rendererInfos2, ref val7); SkinDefParams val9 = Addressables.LoadAssetAsync((object)"RoR2/Base/Treebot/skinTreebotAltColossus_params.asset").WaitForCompletion(); ref RendererInfo[] rendererInfos3 = ref val9.rendererInfos; val7 = new RendererInfo { defaultMaterial = val3, defaultShadowCastingMode = (ShadowCastingMode)0, renderer = component }; ArrayUtils.ArrayAppend(ref rendererInfos3, ref val7); SkinDefParams val10 = Addressables.LoadAssetAsync((object)"d5b044f71d9036441bd5d27e5aa8b9c7").WaitForCompletion(); ref RendererInfo[] rendererInfos4 = ref val10.rendererInfos; val7 = new RendererInfo { defaultMaterial = val4, defaultShadowCastingMode = (ShadowCastingMode)0, renderer = component }; ArrayUtils.ArrayAppend(ref rendererInfos4, ref val7); } } public static class SkinChanges { public enum Case { None, Merc, Acrid, Brass } [CompilerGenerated] private static class <>O { public static hook_FindProjectileGhostPrefab <0>__ApplyConditionalProjectileGhostReplacement; } public static void Start() { //IL_0011: 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_001c: Expected O, but got Unknown object obj = <>O.<0>__ApplyConditionalProjectileGhostReplacement; if (obj == null) { hook_FindProjectileGhostPrefab val = ApplyConditionalProjectileGhostReplacement; <>O.<0>__ApplyConditionalProjectileGhostReplacement = val; obj = (object)val; } ProjectileGhostReplacementManager.FindProjectileGhostPrefab += (hook_FindProjectileGhostPrefab)obj; Mercenary_Main.Start(); Acrid_Main.Start(); EliteEffects.Start(); } private static GameObject ApplyConditionalProjectileGhostReplacement(orig_FindProjectileGhostPrefab orig, ProjectileController projectileController) { ProjectileGhostReplacer component = ((Component)projectileController).GetComponent(); if (Object.op_Implicit((Object)(object)component)) { GameObject val = component.FindReplacement(projectileController); if ((Object)(object)val != (Object)null) { return val; } } return orig.Invoke(projectileController); } public static int DetectCaseMerc(GameObject owner) { ColorThisMerc colorThisMerc = default(ColorThisMerc); if (owner.TryGetComponent(ref colorThisMerc)) { return colorThisMerc.ThisColor; } return 0; } public static MercColors DetectCaseMercEnum(GameObject owner) { ColorThisMerc colorThisMerc = default(ColorThisMerc); if (owner.TryGetComponent(ref colorThisMerc)) { return colorThisMerc.ThisColorEnum; } return MercColors.Blue; } public static int DetectCaseAcrid(GameObject owner) { if (Object.op_Implicit((Object)(object)owner.GetComponent())) { return 1; } return 0; } } public class ProjectileGhostReplacer : MonoBehaviour { public GameObject ghostPrefab_1; public GameObject impactPrefab_1; public GameObject ghostPrefab_2; public GameObject impactPrefab_2; public GameObject ghostPrefab_3; public GameObject impactPrefab_3; public bool useReplacement = true; public bool orbOnEnd = false; private ProjectileController pjC = null; public SkinChanges.Case condition; public GameObject FindReplacement(ProjectileController pjCo) { //IL_01f4: Unknown result type (might be due to invalid IL or missing references) pjC = pjCo; if (!Object.op_Implicit((Object)(object)pjC.owner)) { return null; } if (condition == SkinChanges.Case.Merc) { int num = SkinChanges.DetectCaseMerc(pjC.owner); if (useReplacement) { EffectReplacer.Activate(((Component)pjC).GetComponent().impactEffect, num); } switch (num) { case 1: if (!useReplacement) { ((Component)pjC).GetComponent().impactEffect = impactPrefab_1; } return ghostPrefab_1; case 2: if (!useReplacement) { ((Component)pjC).GetComponent().impactEffect = impactPrefab_2; } return ghostPrefab_2; case 3: if (!useReplacement) { ((Component)pjC).GetComponent().impactEffect = impactPrefab_3; } return ghostPrefab_3; } } else if (condition == SkinChanges.Case.Acrid) { if (useReplacement) { EffectReplacer.ActivateAcrid(((Component)pjC).GetComponent().impactEffect, pjC.owner); } if (Object.op_Implicit((Object)(object)pjC.owner.GetComponent())) { return ghostPrefab_1; } } else if (condition == SkinChanges.Case.Brass) { CharacterBody component = pjC.owner.GetComponent(); if (Object.op_Implicit((Object)(object)component) && component.isElite) { ((Renderer)((Component)ghostPrefab_1.transform.GetChild(0)).GetComponent()).material = ((Renderer)component.inventory.currentEquipmentState.equipmentDef.pickupModelPrefab.GetComponentInChildren()).material; return ghostPrefab_1; } } return null; } public void OnDestroy() { if (orbOnEnd && condition == SkinChanges.Case.Acrid) { EffectReplacer.ActivateAcrid(Acrid_Hooks.CrocoDiseaseImpactEffect, pjC.owner); EffectReplacer.ActivateAcrid(Acrid_Hooks.CrocoDiseaseOrbEffect, pjC.owner); } } } public class EffectReplacer : MonoBehaviour { private int lastSeenCase = -1; private bool resetOnStart = false; public GameObject originalPrefab; public GameObject replacementPrefab1; public GameObject replacementPrefab2; public GameObject replacementPrefab3; public EffectDef effectDef; public void Start() { if (resetOnStart) { SetReplacement(0); } } public static void SetupComponent(GameObject main, GameObject replacementPrefab1, bool restart = false) { SetupComponent(main, replacementPrefab1, null, null, restart); } public static void SetupComponent(GameObject main, GameObject replacementPrefab1, GameObject replacementPrefab2, GameObject replacementPrefab3, bool restart) { //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Unknown result type (might be due to invalid IL or missing references) //IL_0039: Unknown result type (might be due to invalid IL or missing references) //IL_004a: 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_0061: 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_0079: 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) EffectReplacer effectReplacer = main.AddComponent(); effectReplacer.originalPrefab = main; effectReplacer.replacementPrefab1 = replacementPrefab1; effectReplacer.replacementPrefab2 = replacementPrefab2; effectReplacer.replacementPrefab3 = replacementPrefab3; effectReplacer.resetOnStart = restart; EffectIndex effectIndex = main.GetComponent().effectIndex; effectReplacer.effectDef = EffectCatalog.GetEffectDef(effectIndex); replacementPrefab1.GetComponent().effectIndex = effectIndex; if (Object.op_Implicit((Object)(object)replacementPrefab2)) { replacementPrefab2.GetComponent().effectIndex = effectIndex; } if (Object.op_Implicit((Object)(object)replacementPrefab3)) { replacementPrefab3.GetComponent().effectIndex = effectIndex; } } public static void ActivateMerc(GameObject prefab, GameObject owner) { Activate(prefab, SkinChanges.DetectCaseMerc(owner)); } public static void ActivateAcrid(GameObject prefab, GameObject owner) { if (Object.op_Implicit((Object)(object)owner.GetComponent())) { Activate(prefab, 1); } else { Activate(prefab, 0); } } public static void Activate(GameObject prefab, int i) { EffectReplacer effectReplacer = default(EffectReplacer); if (prefab.TryGetComponent(ref effectReplacer)) { effectReplacer.SetReplacement(i); } } private void SetReplacement(int i) { if (i != lastSeenCase) { lastSeenCase = i; switch (i) { case 0: effectDef.prefab = originalPrefab; break; case 1: effectDef.prefab = replacementPrefab1; break; case 2: effectDef.prefab = replacementPrefab2; break; case 3: effectDef.prefab = replacementPrefab3; break; } } } } public enum MercColors { Blue, Red, Green, Pink } public enum AcridDamageTypes { Poison, Blgith } public class ColorThisMerc : MonoBehaviour { public int ThisColor; public MercColors ThisColorEnum; } public class ColorThisAcrid : MonoBehaviour { public void Start() { //IL_0022: Unknown result type (might be due to invalid IL or missing references) //IL_0027: Unknown result type (might be due to invalid IL or missing references) //IL_0031: Invalid comparison between Unknown and I4 CrocoDamageTypeController component = ((Component)this).gameObject.GetComponent(); if ((Object)(object)component == (Object)null) { Object.Destroy((Object)(object)this); } if ((int)DamageTypeCombo.op_Implicit(component.GetDamageType()) != 1048576) { Object.Destroy((Object)(object)this); } } } public static class SkinTouchups { [CompilerGenerated] private static class <>O { public static hook_OnLoadoutChangedGlobal <0>__SkinTouchUpsLobby; public static Action <1>__Start; } [Serializable] [CompilerGenerated] private sealed class <>c { public static readonly <>c <>9 = new <>c(); public static hook_OnEnter <>9__1_0; public static hook_OnExit <>9__1_1; internal void b__1_0(orig_OnEnter orig, ToolbotDualWield self) { ((Renderer)ToolbotDualWield.coverPrefab.GetComponentInChildren()).material = ((Renderer)((Component)((EntityState)self).outer.commonComponents.modelLocator.modelTransform.GetChild(1)).GetComponent()).material; orig.Invoke(self); } internal void b__1_1(orig_OnExit orig, ToolbotDualWield self) { ((Renderer)((Component)ToolbotDualWield.coverEjectEffect.transform.GetChild(0).GetChild(0)).GetComponent()).material = ((Renderer)((Component)((EntityState)self).outer.commonComponents.modelLocator.modelTransform.GetChild(1)).GetComponent()).material; orig.Invoke(self); } } public static void Start() { //IL_0011: 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_001c: Expected O, but got Unknown //IL_00c5: Unknown result type (might be due to invalid IL or missing references) //IL_00ca: Unknown result type (might be due to invalid IL or missing references) //IL_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) object obj = <>O.<0>__SkinTouchUpsLobby; if (obj == null) { hook_OnLoadoutChangedGlobal val = SkinTouchUpsLobby; <>O.<0>__SkinTouchUpsLobby = val; obj = (object)val; } CharacterSelectSurvivorPreviewDisplayController.OnLoadoutChangedGlobal += (hook_OnLoadoutChangedGlobal)obj; Skins_Merc.Start(); Skins_Engi.Start(); if (WConfig.cfgSkinMisc.Value) { Skins_REX.Start(); ((ResourceAvailability)(ref GameModeCatalog.availability)).CallWhenAvailable((Action)Skins_Loader.Start); Skins_Toolbot(); } Skins_Operator(); OtherEnemies.Start(); InteractableSkins.Start(); if (WConfig.cfgSmoothCaptain.Value) { Material val2 = Addressables.LoadAssetAsync((object)"572c80ba738b3144f9590ef372d0b055").WaitForCompletion(); val2.SetTexture("_NormalTex", (Texture)null); val2.SetTexture("_GreenChannelNormalTex", (Texture)null); } SkinDefParams val3 = Addressables.LoadAssetAsync((object)"105cacfa3b8253c4c8cf34cb95818dff").WaitForCompletion(); val3.rendererInfos[3].defaultMaterialAddress = val3.rendererInfos[0].defaultMaterialAddress; } public static void Skins_Toolbot() { //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_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_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_0057: Expected O, but got Unknown //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_007c: Expected O, but got Unknown Addressables.LoadAssetAsync((object)"RoR2/Base/Toolbot/EjectToolbotDualWieldCover.prefab").WaitForCompletion().GetComponent() .DoNotPool = true; GameObject val = Addressables.LoadAssetAsync((object)"RoR2/Base/Toolbot/ToolbotDisplay.prefab").WaitForCompletion(); val.AddComponent(); object obj = <>c.<>9__1_0; if (obj == null) { hook_OnEnter val2 = delegate(orig_OnEnter orig, ToolbotDualWield self) { ((Renderer)ToolbotDualWield.coverPrefab.GetComponentInChildren()).material = ((Renderer)((Component)((EntityState)self).outer.commonComponents.modelLocator.modelTransform.GetChild(1)).GetComponent()).material; orig.Invoke(self); }; <>c.<>9__1_0 = val2; obj = (object)val2; } ToolbotDualWield.OnEnter += (hook_OnEnter)obj; object obj2 = <>c.<>9__1_1; if (obj2 == null) { hook_OnExit val3 = delegate(orig_OnExit orig, ToolbotDualWield self) { ((Renderer)((Component)ToolbotDualWield.coverEjectEffect.transform.GetChild(0).GetChild(0)).GetComponent()).material = ((Renderer)((Component)((EntityState)self).outer.commonComponents.modelLocator.modelTransform.GetChild(1)).GetComponent()).material; orig.Invoke(self); }; <>c.<>9__1_1 = val3; obj2 = (object)val3; } ToolbotDualWield.OnExit += (hook_OnExit)obj2; } public static void Skins_Operator() { //IL_001f: Unknown result type (might be due to invalid IL or missing references) //IL_0024: Unknown result type (might be due to invalid IL or missing references) //IL_0038: Unknown result type (might be due to invalid IL or missing references) //IL_003d: Unknown result type (might be due to invalid IL or missing references) //IL_0051: 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_00b0: 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) if (WConfig.cfgSkinOperatorAltChirp.Value) { SkinDef val = Object.Instantiate(Addressables.LoadAssetAsync((object)"a725c698056caf04790c1f808f62d948").WaitForCompletion()); SkinDefParams val2 = Object.Instantiate(Addressables.LoadAssetAsync((object)"e2f9475836a89c5499ecf3e6934fea49").WaitForCompletion()); Material val3 = Object.Instantiate(Addressables.LoadAssetAsync((object)"448eba93c01ca6046970593a3cc2d234").WaitForCompletion()); val3.mainTexture = (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/SkinScalable/texDTHauler_Mastery.png"); val3.SetTexture("_EmTex", (Texture)(object)Assets.Bundle.LoadAsset("Assets/WQoL/SkinScalable/texDTHauler_MasteryEM.png")); val3.SetColor("_EmColor", new Color(1f, 0.3377f, 0.3377f, 1f)); val.nameToken = "RAPIDEMANDSTHIS"; val.skinDefParams = val2; val.skinDefParamsAddress = new AssetReferenceT(""); val2.rendererInfos[0].defaultMaterial = val3; val2.rendererInfos[0].defaultMaterialAddress = null; Skins.AddSkinToCharacter(((Component)val.rootObject.transform.root).gameObject, val); SkinDefParams val4 = Addressables.LoadAssetAsync((object)"4c92b69e995926b46876ed3c644a2e81").WaitForCompletion(); val4.minionSkinReplacements[2].minionSkin = val; } } private static void SkinTouchUpsLobby(orig_OnLoadoutChangedGlobal orig, CharacterSelectSurvivorPreviewDisplayController self, NetworkUser changedNetworkUser) { //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_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_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_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_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_00aa: Unknown result type (might be due to invalid IL or missing references) //IL_0188: Unknown result type (might be due to invalid IL or missing references) //IL_0199: Unknown result type (might be due to invalid IL or missing references) //IL_01bf: Unknown result type (might be due to invalid IL or missing references) //IL_01c6: Expected O, but got Unknown orig.Invoke(self, changedNetworkUser); if ((Object)(object)changedNetworkUser != (Object)(object)self.networkUser) { return; } Log.LogMessage(((object)self)?.ToString() + " User: " + changedNetworkUser.id.value); if (((Object)self).name.StartsWith("EngiDisplay")) { Loadout loadout = self.networkUser.networkLoadout.loadout; BodyIndex val = BodyCatalog.FindBodyIndex("EngiBody"); if (loadout != null && self.networkUser.bodyIndexPreference == val) { switch (loadout.bodyLoadoutManager.GetSkinIndex(val)) { case 1u: ((Renderer)((Component)((Component)self).gameObject.transform.GetChild(0).GetChild(1)).gameObject.GetComponent()).material = Skins_Engi.matEngiTurretAlt; break; case 2u: ((Renderer)((Component)((Component)self).gameObject.transform.GetChild(0).GetChild(1)).gameObject.GetComponent()).material = Skins_Engi.matEngiTurretColossus; break; } } } if (!((Object)self).name.StartsWith("ToolbotDisplay")) { return; } Loadout loadout2 = self.networkUser.networkLoadout.loadout; BodyIndex val2 = BodyCatalog.FindBodyIndexCaseInsensitive("ToolbotBody"); if (loadout2 != null && self.networkUser.bodyIndexPreference == val2) { int skillVariant = (int)loadout2.bodyLoadoutManager.GetSkillVariant(val2, 0); BodyLoadout readOnlyBodyLoadout = loadout2.bodyLoadoutManager.GetReadOnlyBodyLoadout(val2); SkillFamily skillFamily = readOnlyBodyLoadout.GetSkillFamily(0); ToolbotWeaponSkillDef message = (ToolbotWeaponSkillDef)skillFamily.variants[skillVariant].skillDef; Log.LogMessage(message); Transform child = ((Component)((Component)self).transform.GetChild(0)).transform.GetChild(0); Transform val3 = child.Find("ToolbotArmature/ROOT/base/stomach/chest/upper_arm.l/lower_arm.l/toolbase"); MulTLobbySkill mulTLobbySkill = ((Component)val3).gameObject.GetComponent(); if ((Object)(object)mulTLobbySkill == (Object)null) { mulTLobbySkill = ((Component)val3).gameObject.AddComponent(); } int[] array = new int[4]; array[skillVariant] = 1; mulTLobbySkill.skill = array; } } } public class MulTLobbySkill : MonoBehaviour { public int[] skill = new int[4]; public float x; public Transform nail_New; public Transform rebar_New; public Transform rocket_New; public Transform saw_New; public Transform nailOriginal; public Transform rebarOriginal; public Transform rocketOriginal; public Transform sawOriginal; public void OnEnable() { //IL_0065: Unknown result type (might be due to invalid IL or missing references) //IL_006b: Expected O, but got Unknown //IL_00a6: Unknown result type (might be due to invalid IL or missing references) //IL_00ac: Expected O, but got Unknown //IL_00ec: Unknown result type (might be due to invalid IL or missing references) //IL_00f2: Expected O, but got Unknown //IL_0132: Unknown result type (might be due to invalid IL or missing references) //IL_0138: Expected O, but got Unknown //IL_017f: Unknown result type (might be due to invalid IL or missing references) //IL_0189: Unknown result type (might be due to invalid IL or missing references) //IL_01a0: 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_01c1: 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_01e2: 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) if (!Object.op_Implicit((Object)(object)rocketOriginal)) { rocketOriginal = ((Component)this).transform.GetChild(0); nailOriginal = ((Component)this).transform.GetChild(1); sawOriginal = ((Component)this).transform.GetChild(2); rebarOriginal = ((Component)this).transform.GetChild(3); GameObject val = new GameObject("nail_New"); nail_New = val.transform; nail_New.SetParent(((Component)this).transform, false); ((Component)nailOriginal).transform.SetParent(nail_New); GameObject val2 = new GameObject("rebar_New"); rebar_New = val2.transform; ((Component)rebar_New).transform.SetParent(((Component)this).transform, false); ((Component)rebarOriginal).transform.SetParent(rebar_New); GameObject val3 = new GameObject("rocket_New"); rocket_New = val3.transform; ((Component)rocket_New).transform.SetParent(((Component)this).transform, false); ((Component)rocketOriginal).transform.SetParent(rocket_New); GameObject val4 = new GameObject("saw_New"); saw_New = val4.transform; ((Component)saw_New).transform.SetParent(((Component)this).transform, false); ((Component)sawOriginal).transform.SetParent(saw_New); nail_New.localPosition = nailOriginal.localPosition * -1f; rebar_New.localPosition = rebarOriginal.localPosition * -100f; rocket_New.localPosition = rocketOriginal.localPosition * -100f; saw_New.localPosition = sawOriginal.localPosition * -100f; } } public void Update() { //IL_001b: 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_003b: 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_005a: 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_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) //IL_008e: 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_00a7: Unknown result type (might be due to invalid IL or missing references) //IL_00b1: Unknown result type (might be due to invalid IL or missing references) //IL_00c2: Unknown result type (might be due to invalid IL or missing references) //IL_00cd: 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_00e5: 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_0108: Unknown result type (might be due to invalid IL or missing references) //IL_011f: Unknown result type (might be due to invalid IL or missing references) //IL_012b: Unknown result type (might be due to invalid IL or missing references) //IL_0135: Unknown result type (might be due to invalid IL or missing references) //IL_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_0162: 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_0185: Unknown result type (might be due to invalid IL or missing references) //IL_018f: Unknown result type (might be due to invalid IL or missing references) if (Object.op_Implicit((Object)(object)saw_New)) { x = nailOriginal.localScale.x; nail_New.localScale = Vector3.one * x * (float)skill[0]; rebar_New.localScale = Vector3.one * x * (float)skill[1] * 100f; rocket_New.localScale = Vector3.one * x * (float)skill[2] * 100f; saw_New.localScale = Vector3.one * x * (float)skill[3] * 100f; nail_New.localPosition = nailOriginal.localPosition * (0f - x); rebar_New.localPosition = rebarOriginal.localPosition * (0f - x) * 100f; rocket_New.localPosition = rocketOriginal.localPosition * (0f - x) * 100f; saw_New.localPosition = sawOriginal.localPosition * (0f - x) * 100f; } } } } namespace WolfoQoL_Client.Reminders { public static class Objectives_General { [CompilerGenerated] private static class <>O { public static hook_PreStartClient <0>__ObjectivesOnStage; } public static void Start() { //IL_0011: 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_001c: Expected O, but got Unknown object obj = <>O.<0>__ObjectivesOnStage; if (obj == null) { hook_PreStartClient val = ObjectivesOnStage; <>O.<0>__ObjectivesOnStage = val; obj = (object)val; } Stage.PreStartClient += (hook_PreStartClient)obj; } public static void ObjectivesOnStage(orig_PreStartClient orig, Stage self) { //IL_0338: Unknown result type (might be due to invalid IL or missing references) //IL_033f: Expected O, but got Unknown //IL_01f8: Unknown result type (might be due to invalid IL or missing references) //IL_01fd: Unknown result type (might be due to invalid IL or missing references) //IL_022d: Unknown result type (might be due to invalid IL or missing references) //IL_0232: Unknown result type (might be due to invalid IL or missing references) //IL_0215: Unknown result type (might be due to invalid IL or missing references) //IL_021a: Unknown result type (might be due to invalid IL or missing references) //IL_0173: Unknown result type (might be due to invalid IL or missing references) //IL_0178: Unknown result type (might be due to invalid IL or missing references) //IL_017f: Unknown result type (might be due to invalid IL or missing references) //IL_018a: Unknown result type (might be due to invalid IL or missing references) //IL_018c: Unknown result type (might be due to invalid IL or missing references) //IL_0191: Unknown result type (might be due to invalid IL or missing references) //IL_0192: Unknown result type (might be due to invalid IL or missing references) //IL_0197: Unknown result type (might be due to invalid IL or missing references) //IL_01a3: Expected O, but got Unknown //IL_01a5: Expected O, but got Unknown //IL_0248: Unknown result type (might be due to invalid IL or missing references) //IL_024d: Unknown result type (might be due to invalid IL or missing references) //IL_0256: Unknown result type (might be due to invalid IL or missing references) //IL_02d2: Unknown result type (might be due to invalid IL or missing references) //IL_02e0: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self); if (!Object.op_Implicit((Object)(object)self.sceneDef)) { return; } switch (self.sceneDef.baseSceneName) { case "goolake": { GameObject val5 = GameObject.Find("/HOLDER: Secret Ring Area Content/Entrance/GLRuinGate/DoorIsOpenedEffect/"); GameObject val6 = GameObject.Find("/HOLDER: Secret Ring Area Content/ApproxCenter/RingEventController/"); GenericObjectiveProvider val7 = val5.AddComponent(); val7.objectiveToken = "OBJECTIVE_DESERT_ELDERS"; OnPlayerEnterEvent component3 = val6.GetComponent(); PersistentCall val8 = new PersistentCall { m_Target = (Object)(object)val7, m_MethodName = "Destroy", m_Mode = (PersistentListenerMode)2, m_Arguments = new ArgumentCache { m_ObjectArgument = (Object)(object)val7 } }; ((UnityEventBase)component3.action).m_PersistentCalls.AddListener(val8); break; } case "artifactworld": case "artifactworld01": case "artifactworld02": case "artifactworld03": { GameObject val4 = GameObject.Find("/ArtifactDisplay/SetpiecePickup"); if ((Object)(object)val4 == (Object)null) { val4 = GameObject.Find("/HOLDER: Design/ArtifactDisplay/SetpiecePickup"); } GenericPickupController component = val4.GetComponent(); string text = "ArtifactIndex.None"; if (component.pickupIndex == PickupIndex.none) { component.pickupIndex = PickupCatalog.FindPickupIndex(Items.BoostHp.itemIndex); } else if (component.pickupIndex != PickupIndex.none) { PickupIndex pickupIndex = component.pickupIndex; ArtifactDef artifactDef = ArtifactCatalog.GetArtifactDef(((PickupIndex)(ref pickupIndex)).pickupDef.artifactIndex); if (Object.op_Implicit((Object)(object)artifactDef)) { text = Language.GetString(artifactDef.nameToken); string[] array = text.Split(" "); if (array.Length != 0) { text = array[^1]; Log.LogMessage(text); } } if (WConfig.ArtifactOutline.Value) { Highlight component2 = ((Component)component).gameObject.GetComponent(); component2.pickupIndex = component.pickupIndex; component2.highlightColor = (HighlightColor)2; component2.isOn = true; } } ((Component)component).gameObject.AddComponent().objectiveToken = string.Format(Language.GetString("OBJECTIVE_ARTIFACT_TRIAL"), text); break; } case "mysteryspace": { GameObject val2 = GameObject.Find("/MS_Obelisk"); val2.AddComponent().pingIconOverride = PingIcons.QuestionMarkIcon; GameObject val3 = new GameObject("MSObjective"); val3.transform.SetParent(val2.transform); val3.AddComponent().objectiveToken = "OBJECTIVE_GLASS_YOURSELF"; break; } case "conduitcanyon": { GameObject val = GameObject.Find("/HOLDER: Stage Events"); ((Component)val.transform.GetChild(3)).gameObject.AddComponent().pedestals = ((Component)val.transform.GetChild(1).GetChild(3)).GetComponent(); ((Component)val.transform.GetChild(4)).gameObject.AddComponent().pedestals = ((Component)val.transform.GetChild(2).GetChild(0)).GetComponent(); break; } } } } public class ConduitCanyonKeysInstalledTracker : MonoBehaviour { public string baseToken; public PowerPedestalObserver pedestals; public GenericObjectiveProvider objective; public void Start() { //IL_0039: Unknown result type (might be due to invalid IL or missing references) //IL_003e: Unknown result type (might be due to invalid IL or missing references) //IL_0045: Unknown result type (might be due to invalid IL or missing references) //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_005c: Expected O, but got Unknown objective = ((Component)this).GetComponent(); baseToken = objective.objectiveToken; ((UnityEventBase)pedestals.perPedestalObserverActions[0].ActionsOnCompletion).m_PersistentCalls.AddListener(new PersistentCall { m_Target = (Object)(object)this, m_MethodName = "UpdateAmount", m_Mode = (PersistentListenerMode)1 }); ((UnityEventBase)pedestals.perPedestalObserverActions[0].ActionsOnCompletion).m_CallsDirty = true; UpdateAmount(); } public void UpdateAmount() { objective.objectiveToken = Language.GetString(baseToken) + $" ({pedestals.completedPowerPedestals.Count}/{pedestals.observedPedestals.Length})"; } } public static class Objective_Halcyonite { [CompilerGenerated] private static class <>O { public static hook_OnEnter <0>__HalcyoniteObjectives; public static Manipulator <1>__Update_Objective; } public static void Start() { //IL_0011: 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_001c: Expected O, but got Unknown //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_0059: Expected O, but got Unknown object obj = <>O.<0>__HalcyoniteObjectives; if (obj == null) { hook_OnEnter val = HalcyoniteObjectives; <>O.<0>__HalcyoniteObjectives = val; obj = (object)val; } ShrineHalcyoniteBaseState.OnEnter += (hook_OnEnter)obj; if (WConfig.cfgChargeHalcyShrine.Value && !WQoLMain.NoMoreMathMod) { object obj2 = <>O.<1>__Update_Objective; if (obj2 == null) { Manipulator val2 = Update_Objective; <>O.<1>__Update_Objective = val2; obj2 = (object)val2; } GoldSiphonNearbyBodyController.DrainGold += (Manipulator)obj2; } } private static void HalcyoniteObjectives(orig_OnEnter orig, ShrineHalcyoniteBaseState self) { orig.Invoke(self); if (self is ShrineHalcyoniteActivatedState && Object.op_Implicit((Object)(object)TreasureReminder.instance) && Object.op_Implicit((Object)(object)TreasureReminder.instance.Objective_Halcyon)) { ((Behaviour)TreasureReminder.instance.Objective_Halcyon).enabled = false; } if (!WConfig.cfgChargeHalcyShrine.Value || WQoLMain.NoMoreMathMod) { return; } if (self is ShrineHalcyoniteActivatedState) { HalcyoniteShrineObjective component = ((EntityState)self).gameObject.GetComponent(); if (!Object.op_Implicit((Object)(object)component)) { component = ((EntityState)self).gameObject.AddComponent(); component.Halc = self.parentShrineReference; component.sucker = ((EntityState)self).gameObject.GetComponentInChildren(); component.maxGoldCost = self.parentShrineReference.maxGoldCost; ((GenericObjectiveProvider)component).objectiveToken = string.Format(Language.GetString("OBJECTIVE_CHARGE_HALCSHRINE"), 0); } } if (self is ShrineHalcyoniteMaxQuality) { HalcyoniteShrineObjective component2 = ((EntityState)self).gameObject.GetComponent(); if (Object.op_Implicit((Object)(object)component2)) { if (self.parentShrineReference.Networkinteractions >= 3) { ((GenericObjectiveProvider)component2).markCompletedOnRetired = false; } else { ((GenericObjectiveProvider)component2).objectiveToken = string.Format(Language.GetString("OBJECTIVE_CHARGE_HALCSHRINE"), 100); } ((Behaviour)component2).enabled = false; component2.AddKill(); } ((Collider)((Component)((Component)((EntityState)self).outer).transform.GetChild(0).GetChild(0)).GetComponent()).enabled = false; } if (self is ShrineHalcyoniteFinished) { HalcyoniteShrineObjective component3 = ((EntityState)self).gameObject.GetComponent(); if (Object.op_Implicit((Object)(object)component3)) { Object.Destroy((Object)(object)component3.killObjective); } } } private static void ClearFindObj(orig_OnEnter orig, ShrineHalcyoniteActivatedState self) { orig.Invoke(self); if (Object.op_Implicit((Object)(object)TreasureReminder.instance.Objective_Halcyon)) { ((Behaviour)TreasureReminder.instance.Objective_Halcyon).enabled = false; } } private static void AddObjective(orig_OnEnter orig, ShrineHalcyoniteActivatedState self) { orig.Invoke(self); HalcyoniteShrineObjective component = ((EntityState)self).gameObject.GetComponent(); if (!Object.op_Implicit((Object)(object)component)) { component = ((EntityState)self).gameObject.AddComponent(); component.Halc = ((ShrineHalcyoniteBaseState)self).parentShrineReference; component.sucker = ((EntityState)self).gameObject.GetComponentInChildren(); component.maxGoldCost = ((ShrineHalcyoniteBaseState)self).parentShrineReference.maxGoldCost; ((GenericObjectiveProvider)component).objectiveToken = string.Format(Language.GetString("OBJECTIVE_CHARGE_HALCSHRINE"), 0); } } private static void Add_KillObjective(orig_OnEnter orig, ShrineHalcyoniteMaxQuality self) { orig.Invoke(self); HalcyoniteShrineObjective component = ((EntityState)self).gameObject.GetComponent(); if (Object.op_Implicit((Object)(object)component)) { if (((ShrineHalcyoniteBaseState)self).parentShrineReference.Networkinteractions >= 3) { ((GenericObjectiveProvider)component).markCompletedOnRetired = false; } else { ((GenericObjectiveProvider)component).objectiveToken = string.Format(Language.GetString("OBJECTIVE_CHARGE_HALCSHRINE"), 100); } ((Behaviour)component).enabled = false; component.AddKill(); } ((Collider)((Component)((Component)((EntityState)self).outer).transform.GetChild(0).GetChild(0)).GetComponent()).enabled = false; } private static void Clear_KillObjective(orig_OnEnter orig, ShrineHalcyoniteFinished self) { } private static void Update_Objective(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown //IL_0073: Unknown result type (might be due to invalid IL or missing references) ILCursor val = new ILCursor(il); if (val.TryGotoNext((MoveType)2, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchCall(x, "UnityEngine.Networking.NetworkServer", "get_active") }) && val.TryGotoPrev((MoveType)2, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchLdfld(x, "RoR2.HealthComponent", "body") })) { val.Emit(OpCodes.Ldarg_0); val.EmitDelegate>((Func)delegate(CharacterBody body, GoldSiphonNearbyBodyController self) { if (Object.op_Implicit((Object)(object)body)) { ((Component)self.parentShrineReference).GetComponent()?.StoreGold(); } return body; }); } else { Log.LogWarning("IL Failed: Update_Objective"); } } } public class HalcyoniteShrineObjective : GenericObjectiveProvider { public static HalcyoniteShrineObjective instance; public HalcyoniteShrineInteractable Halc; public GoldSiphonNearbyBodyController sucker; public int goldDrained; public int fraction; public int maxGoldCost = 300; public GenericObjectiveProvider killObjective; public void Awake() { instance = this; } public void StoreGold() { goldDrained += Halc.goldDrainValue; int num = goldDrained * 100 / maxGoldCost; if (num > 100) { num = 100; } if (num > fraction) { fraction = num; base.objectiveToken = string.Format(Language.GetString("OBJECTIVE_CHARGE_HALCSHRINE"), num); } } public void AddKill() { Reminders_Main.CompleteObjective((GenericObjectiveProvider)(object)this); killObjective = ((Component)this).gameObject.AddComponent(); killObjective.objectiveToken = Language.GetString("OBJECTIVE_KILL_HALCSHRINE"); ((Behaviour)this).enabled = false; } } public static class Reminders_Portal { [CompilerGenerated] private static class <>O { public static hook_Begin <0>__RemoveReminder_Host; public static hook_OnDeserialize <1>__RemoveReminder_Client; public static hook_OnEnter <2>__MissionCompleted_OnEnter; } public static void Start() { //IL_0011: 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_001c: Expected O, but got Unknown //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Unknown result type (might be due to invalid IL or missing references) //IL_003d: Expected O, but got Unknown //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_005e: Expected O, but got Unknown //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_009c: Unknown result type (might be due to invalid IL or missing references) //IL_00a1: Unknown result type (might be due to invalid IL or missing references) //IL_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_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_0113: Unknown result type (might be due to invalid IL or missing references) //IL_0118: Unknown result type (might be due to invalid IL or missing references) //IL_0134: 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_0155: 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_0183: Unknown result type (might be due to invalid IL or missing references) //IL_0188: Unknown result type (might be due to invalid IL or missing references) //IL_01a4: Unknown result type (might be due to invalid IL or missing references) //IL_01a9: Unknown result type (might be due to invalid IL or missing references) //IL_01ce: Unknown result type (might be due to invalid IL or missing references) //IL_01d3: Unknown result type (might be due to invalid IL or missing references) //IL_01ef: 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_0210: Unknown result type (might be due to invalid IL or missing references) //IL_0215: Unknown result type (might be due to invalid IL or missing references) object obj = <>O.<0>__RemoveReminder_Host; if (obj == null) { hook_Begin val = RemoveReminder_Host; <>O.<0>__RemoveReminder_Host = val; obj = (object)val; } SceneExitController.Begin += (hook_Begin)obj; object obj2 = <>O.<1>__RemoveReminder_Client; if (obj2 == null) { hook_OnDeserialize val2 = RemoveReminder_Client; <>O.<1>__RemoveReminder_Client = val2; obj2 = (object)val2; } GenericInteraction.OnDeserialize += (hook_OnDeserialize)obj2; object obj3 = <>O.<2>__MissionCompleted_OnEnter; if (obj3 == null) { hook_OnEnter val3 = MissionCompleted_OnEnter; <>O.<2>__MissionCompleted_OnEnter = val3; obj3 = (object)val3; } MissionCompleted.OnEnter += (hook_OnEnter)obj3; if (WConfig.cfgRemindersPortal.Value) { Addressables.LoadAssetAsync((object)"RoR2/Base/PortalArtifactworld/PortalArtifactworld.prefab").WaitForCompletion().AddComponent() .style = ""; Addressables.LoadAssetAsync((object)"RoR2/Base/PortalGoldshores/PortalGoldshores.prefab").WaitForCompletion().AddComponent() .style = ""; PortalObjective portalObjective = Addressables.LoadAssetAsync((object)"eadfcaf9ea3275e49858ed19f874db5a").WaitForCompletion().AddComponent(); portalObjective.style = ""; portalObjective.blacklistedScene = SceneList.MysterySpace; portalObjective.exit = true; Addressables.LoadAssetAsync((object)"RoR2/Base/PortalShop/PortalShop.prefab").WaitForCompletion().AddComponent() .style = ""; Addressables.LoadAssetAsync((object)"RoR2/Base/PortalArena/PortalArena.prefab").WaitForCompletion().AddComponent() .style = ""; Addressables.LoadAssetAsync((object)"RoR2/DLC1/PortalVoid/PortalVoid.prefab").WaitForCompletion().AddComponent() .style = ""; portalObjective = Addressables.LoadAssetAsync((object)"RoR2/DLC1/DeepVoidPortal/DeepVoidPortal.prefab").WaitForCompletion().AddComponent(); portalObjective.style = ""; portalObjective.blacklistedScene = SceneList.VoidStage; Addressables.LoadAssetAsync((object)"RoR2/DLC2/PortalColossus.prefab").WaitForCompletion().AddComponent() .style = ""; portalObjective = Addressables.LoadAssetAsync((object)"RoR2/DLC2/PM DestinationPortal.prefab").WaitForCompletion().AddComponent(); portalObjective.style = ""; portalObjective.onlyEclipse = true; Addressables.LoadAssetAsync((object)"7a6f6b9396b554745b555c02bf58ea0b").WaitForCompletion().AddComponent() .style = ""; Addressables.LoadAssetAsync((object)"aa32c88c45d3b974aba3b2cafedb5cb5").WaitForCompletion().AddComponent() .style = ""; Addressables.LoadAssetAsync((object)"9592265fcd09fc643b2495b5e4ebac8f").WaitForCompletion().AddComponent() .style = ""; } } private static void MissionCompleted_OnEnter(orig_OnEnter orig, MissionCompleted self) { orig.Invoke(self); if (WConfig.cfgRemindersPortal.Value) { GameObject val = GameObject.Find("/PortalArena"); if (Object.op_Implicit((Object)(object)val)) { val.AddComponent().style = ""; } } } private static void RemoveReminder_Host(orig_Begin orig, SceneExitController self) { orig.Invoke(self); GenericObjectiveProvider component = ((Component)self).GetComponent(); if (Object.op_Implicit((Object)(object)component)) { Object.Destroy((Object)(object)component); } } private static void RemoveReminder_Client(orig_OnDeserialize orig, GenericInteraction self, NetworkReader reader, bool initialState) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0007: Unknown result type (might be due to invalid IL or missing references) //IL_0012: Unknown result type (might be due to invalid IL or missing references) //IL_0014: Invalid comparison between Unknown and I4 //IL_0017: Unknown result type (might be due to invalid IL or missing references) //IL_001d: Invalid comparison between Unknown and I4 Interactability interactability = self.interactability; orig.Invoke(self, reader, initialState); if ((int)interactability == 2 && (int)self.interactability != 2) { GenericObjectiveProvider component = ((Component)self).GetComponent(); if (Object.op_Implicit((Object)(object)component)) { Object.Destroy((Object)(object)component); } } } } public class PortalObjective : GenericObjectiveProvider { public string style; public bool exit; public bool onlyEclipse; public SceneDef blacklistedScene; public void Awake() { //IL_001a: Unknown result type (might be due to invalid IL or missing references) //IL_0020: Invalid comparison between Unknown and I4 if (onlyEclipse && Object.op_Implicit((Object)(object)Run.instance) && (int)Run.instance.selectedDifficulty < 3) { ((Behaviour)this).enabled = false; } if (Object.op_Implicit((Object)(object)blacklistedScene) && !exit && (Object)(object)blacklistedScene == (Object)(object)SceneInfo.instance.sceneDef) { ((Behaviour)this).enabled = false; } if (!WConfig.cfgRemindersPortal.Value) { ((Behaviour)this).enabled = false; } } public void Start() { string text = "REMINDER_PORTAL_MAIN"; if (exit && Object.op_Implicit((Object)(object)blacklistedScene) && (Object)(object)blacklistedScene == (Object)(object)SceneInfo.instance.sceneDef) { text = "REMINDER_PORTAL_EXIT"; } string displayToken = ((Component)this).GetComponent().displayToken; if (Language.currentLanguage != null) { if (Language.currentLanguage.TokenIsRegistered(text)) { base.objectiveToken = Language.GetStringFormatted(text, new object[1] { style + Language.GetString(displayToken) + "" }); } else { base.objectiveToken = Language.GetStringFormatted(text, new object[1] { style + Language.english.GetLocalizedStringByToken(displayToken) + "" }); } } } } public static class Reminders_SecretGeode { [CompilerGenerated] private static class <>O { public static hook_OnEnter <0>__GeodeObjective_Add; public static hook_AdvanceGeodeSecretMission <1>__GeodeObjective_Update; public static hook_OnDeserialize <2>__MakeUpdateOnClient; } private static GeodeSecretMissionController geodeInstance; public static void Start() { //IL_0011: 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_001c: Expected O, but got Unknown //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Unknown result type (might be due to invalid IL or missing references) //IL_003d: Expected O, but got Unknown //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_005e: Expected O, but got Unknown object obj = <>O.<0>__GeodeObjective_Add; if (obj == null) { hook_OnEnter val = GeodeObjective_Add; <>O.<0>__GeodeObjective_Add = val; obj = (object)val; } GeodeSecretMissionEntityStates.OnEnter += (hook_OnEnter)obj; object obj2 = <>O.<1>__GeodeObjective_Update; if (obj2 == null) { hook_AdvanceGeodeSecretMission val2 = GeodeObjective_Update; <>O.<1>__GeodeObjective_Update = val2; obj2 = (object)val2; } GeodeSecretMissionController.AdvanceGeodeSecretMission += (hook_AdvanceGeodeSecretMission)obj2; object obj3 = <>O.<2>__MakeUpdateOnClient; if (obj3 == null) { hook_OnDeserialize val3 = MakeUpdateOnClient; <>O.<2>__MakeUpdateOnClient = val3; obj3 = (object)val3; } GeodeController.OnDeserialize += (hook_OnDeserialize)obj3; } private static void MakeUpdateOnClient(orig_OnDeserialize orig, GeodeController self, NetworkReader reader, bool initialState) { bool available = self.available; orig.Invoke(self, reader, initialState); if (available && !self.available && self.isSecretMissionGeode) { geodeInstance.AdvanceGeodeSecretMission(); } } private static void GeodeObjective_Add(orig_OnEnter orig, GeodeSecretMissionEntityStates self) { orig.Invoke(self); geodeInstance = self.geodeSecretMissionController; if (WConfig.cfgRemindersSecretGeode.Value) { Log.LogWarning("Secret Geode Start"); if (geodeInstance.geodeInteractionsTracker == 0) { string objectiveToken = string.Format(Language.GetString("REMINDER_SECRET_GEODE"), 0, self.geodeSecretMissionController.numberOfGeodesNecessary); ((EntityState)self).gameObject.AddComponent().objectiveToken = objectiveToken; } } } private static void GeodeObjective_Update(orig_AdvanceGeodeSecretMission orig, GeodeSecretMissionController self) { orig.Invoke(self); Log.LogWarning("Secret Geode Advance"); GenericObjectiveProvider component = ((Component)self).gameObject.GetComponent(); if (Object.op_Implicit((Object)(object)component)) { string objectiveToken = string.Format(Language.GetString("REMINDER_SECRET_GEODE"), self.geodeInteractionsTracker, self.numberOfGeodesNecessary); component.objectiveToken = objectiveToken; if (self.numberOfGeodesNecessary <= self.geodeInteractionsTracker) { Log.LogWarning("Secret Geode Complete"); Object.Destroy((Object)(object)component); } } } } public static class Reminders_Treasure { [CompilerGenerated] private static class <>O { public static hook_OnInteractionBegin <0>__KeyReminderUpdater_Host; public static hook_OnPurchase <1>__FreeChestReminderUpdater_Host; public static hook_PushItemTransformNotification <2>__Clear_Star_Regen; public static hook_OnEnter <3>__Quality_Barrel; } public static void Start() { //IL_0011: 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_001c: Expected O, but got Unknown //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Unknown result type (might be due to invalid IL or missing references) //IL_003d: Expected O, but got Unknown //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_005e: Expected O, but got Unknown //IL_0074: Unknown result type (might be due to invalid IL or missing references) //IL_0079: Unknown result type (might be due to invalid IL or missing references) //IL_007f: Expected O, but got Unknown object obj = <>O.<0>__KeyReminderUpdater_Host; if (obj == null) { hook_OnInteractionBegin val = KeyReminderUpdater_Host; <>O.<0>__KeyReminderUpdater_Host = val; obj = (object)val; } PurchaseInteraction.OnInteractionBegin += (hook_OnInteractionBegin)obj; object obj2 = <>O.<1>__FreeChestReminderUpdater_Host; if (obj2 == null) { hook_OnPurchase val2 = FreeChestReminderUpdater_Host; <>O.<1>__FreeChestReminderUpdater_Host = val2; obj2 = (object)val2; } MultiShopController.OnPurchase += (hook_OnPurchase)obj2; object obj3 = <>O.<2>__Clear_Star_Regen; if (obj3 == null) { hook_PushItemTransformNotification val3 = Clear_Star_Regen; <>O.<2>__Clear_Star_Regen = val3; obj3 = (object)val3; } CharacterMasterNotificationQueue.PushItemTransformNotification += (hook_PushItemTransformNotification)obj3; object obj4 = <>O.<3>__Quality_Barrel; if (obj4 == null) { hook_OnEnter val4 = Quality_Barrel; <>O.<3>__Quality_Barrel = val4; obj4 = (object)val4; } Opening.OnEnter += (hook_OnEnter)obj4; } private static void Quality_Barrel(orig_OnEnter orig, Opening self) { orig.Invoke(self); if (((Object)((EntityState)self).gameObject).name.StartsWith("SpeedOnPickup") && Object.op_Implicit((Object)(object)TreasureReminder.instance)) { TreasureReminder.Deduct(TreasureReminder.instance.Objective_Quality_Collectors, ref TreasureReminder.instance.qualityCollectors); } } private static void Clear_Star_Regen(orig_PushItemTransformNotification orig, CharacterMaster characterMaster, ItemIndex oldIndex, ItemIndex newIndex, TransformationType transformationType) { //IL_0003: Unknown result type (might be due to invalid IL or missing references) //IL_0004: 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) //IL_0020: Unknown result type (might be due to invalid IL or missing references) //IL_0023: Invalid comparison between Unknown and I4 //IL_007f: Unknown result type (might be due to invalid IL or missing references) //IL_0082: Invalid comparison between Unknown and I4 //IL_002a: 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_00c6: Invalid comparison between Unknown and I4 //IL_008b: 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_005e: 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_00e1: Invalid comparison between Unknown and I4 //IL_00e3: 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) orig.Invoke(characterMaster, oldIndex, newIndex, transformationType); if (!((NetworkBehaviour)characterMaster).hasAuthority) { return; } if ((int)transformationType == 0) { if (QualitySupport.PreBaseItemIndex(newIndex, Items.RegeneratingScrapConsumed)) { if (Object.op_Implicit((Object)(object)TreasureReminder.instance)) { Reminders_Main.CompleteObjective(TreasureReminder.instance.Objective_RegenScrap); } } else if (newIndex == MoreMessages.VanillaVoids_WatchBrokeItem) { TreasureReminder.CheckKeysVoided(); TreasureReminder.CheckItemsDestroyed(); } } else if ((int)transformationType == 6) { if (QualitySupport.PreBaseItemIndex(newIndex, Items.LowerPricedChestsConsumed) && Object.op_Implicit((Object)(object)TreasureReminder.instance)) { Reminders_Main.CompleteObjective(TreasureReminder.instance.Objective_SaleStar); } } else if ((int)transformationType == 4) { TreasureReminder.CheckKeysVoided(); TreasureReminder.CheckItemsDestroyed(); } else if ((int)transformationType == 1 && oldIndex == Items.TreasureCache.itemIndex) { TreasureReminder.CheckKeysVoided(); } } private static void FreeChestReminderUpdater_Host(orig_OnPurchase orig, MultiShopController self, PayCostContext payCostContext, PayCostResults payCostResult) { orig.Invoke(self, payCostContext, payCostResult); if (!self.available && ((Object)self).name.StartsWith("FreeChestMultiShop") && Object.op_Implicit((Object)(object)TreasureReminder.instance)) { TreasureReminder.Deduct(TreasureReminder.instance.Objective_FreeChest, ref TreasureReminder.instance.freeChestCount); } } public static void KeyReminderUpdater_Host(orig_OnInteractionBegin orig, PurchaseInteraction self, Interactor activator) { //IL_0055: Unknown result type (might be due to invalid IL or missing references) //IL_005c: Invalid comparison between Unknown and I4 //IL_0093: Unknown result type (might be due to invalid IL or missing references) //IL_009a: Invalid comparison between Unknown and I4 CharacterBody component = ((Component)activator).GetComponent(); int itemCount = component.inventory.GetItemCount(Items.LowerPricedChests); orig.Invoke(self, activator); if (itemCount > 0 && self.saleStarCompatible) { InteractableMessage obj = new InteractableMessage { interactableToken = self.displayNameToken }; ((SubjectChatMessage)obj).subjectAsCharacterBody = component; Networker.SendWQoLMessage((ChatMessageBase)(object)obj); } if ((int)self.costType == 12) { if (Object.op_Implicit((Object)(object)TreasureReminder.instance)) { TreasureReminder.Deduct(TreasureReminder.instance.Objective_Lockbox, ref TreasureReminder.instance.lockboxCount); } } else if ((int)self.costType == 13 && Object.op_Implicit((Object)(object)TreasureReminder.instance)) { TreasureReminder.Deduct(TreasureReminder.instance.Objective_LockboxVoid, ref TreasureReminder.instance.lockboxVoidCount); } } } public static class Reminders_Newt { [CompilerGenerated] private static class <>O { public static hook_PreStartClient <0>__CheckIfAnyNewtsSpawnedForReminder; public static hook_OnSyncShouldAttemptToSpawnShopPortal <1>__NewtClear_OnClient; public static hook_OnEnter <2>__UpdateAccessCodeReminder; } public static void Start() { //IL_0011: 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_001c: Expected O, but got Unknown //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Unknown result type (might be due to invalid IL or missing references) //IL_003d: Expected O, but got Unknown //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_005e: Expected O, but got Unknown object obj = <>O.<0>__CheckIfAnyNewtsSpawnedForReminder; if (obj == null) { hook_PreStartClient val = CheckIfAnyNewtsSpawnedForReminder; <>O.<0>__CheckIfAnyNewtsSpawnedForReminder = val; obj = (object)val; } PortalStatueBehavior.PreStartClient += (hook_PreStartClient)obj; object obj2 = <>O.<1>__NewtClear_OnClient; if (obj2 == null) { hook_OnSyncShouldAttemptToSpawnShopPortal val2 = NewtClear_OnClient; <>O.<1>__NewtClear_OnClient = val2; obj2 = (object)val2; } TeleporterInteraction.OnSyncShouldAttemptToSpawnShopPortal += (hook_OnSyncShouldAttemptToSpawnShopPortal)obj2; object obj3 = <>O.<2>__UpdateAccessCodeReminder; if (obj3 == null) { hook_OnEnter val3 = UpdateAccessCodeReminder; <>O.<2>__UpdateAccessCodeReminder = val3; obj3 = (object)val3; } AccessNodesBaseState.OnEnter += (hook_OnEnter)obj3; } private static void UpdateAccessCodeReminder(orig_OnEnter orig, AccessNodesBaseState self) { orig.Invoke(self); if (WConfig.cfgReminder_AccessNode.Value && Object.op_Implicit((Object)(object)TreasureReminder.instance) && Object.op_Implicit((Object)(object)TreasureReminder.instance.Objective_AccessNode)) { if (self is NodeActive) { ((Behaviour)TreasureReminder.instance.Objective_AccessNode).enabled = false; } else if (self is Off) { Reminders_Main.FailObjective(TreasureReminder.instance.Objective_AccessNode); } } } private static void NewtClear_OnClient(orig_OnSyncShouldAttemptToSpawnShopPortal orig, TeleporterInteraction self, bool newValue) { orig.Invoke(self, newValue); if (newValue && Object.op_Implicit((Object)(object)TreasureReminder.instance)) { Reminders_Main.CompleteObjective(TreasureReminder.instance.Objective_NewtShrine); } } private static void CheckIfAnyNewtsSpawnedForReminder(orig_PreStartClient orig, PortalStatueBehavior self) { //IL_000a: Unknown result type (might be due to invalid IL or missing references) //IL_0010: Invalid comparison between Unknown and I4 orig.Invoke(self); if ((int)self.portalType == 0) { TreasureReminder.instance.newtShrineSpawned++; ((Component)self).gameObject.AddComponent().interactable = SpawnListener.Interactable.newtAltar; } } private static void Clear_Newt_SpawnedWithBlue(orig_Start orig, TeleporterInteraction self) { orig.Invoke(self); if (self.Network_shouldAttemptToSpawnShopPortal && Object.op_Implicit((Object)(object)TreasureReminder.instance)) { Reminders_Main.CompleteObjective(TreasureReminder.instance.Objective_NewtShrine); } } private static void Newt_ReminderClear(orig_GrantPortalEntry orig, PortalStatueBehavior self) { //IL_000a: Unknown result type (might be due to invalid IL or missing references) //IL_0010: Invalid comparison between Unknown and I4 orig.Invoke(self); if ((int)self.portalType == 0 && Object.op_Implicit((Object)(object)TreasureReminder.instance)) { Reminders_Main.CompleteObjective(TreasureReminder.instance.Objective_NewtShrine); } } } public static class Reminders_Main { [CompilerGenerated] private static class <>O { public static hook_BeginScrapping_UniquePickup <0>__RemoveReminders_Scrapper; public static hook_OnEnable <1>__IsFreeVoidChest_ClearNewt; public static Action <2>__FailAllReminders; public static hook_OnExit <3>__ClearTreasure_OnVoidlingDeath; public static Action <4>__ClearReminders_OnFalseSon; public static hook_Awake <5>__AddReminderObject; public static Action <6>__SetupRemindersOnStart; } public static void Start() { //IL_0130: Unknown result type (might be due to invalid IL or missing references) //IL_0135: Unknown result type (might be due to invalid IL or missing references) //IL_013b: Expected O, but got Unknown //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_0058: Expected O, but got Unknown //IL_0167: Unknown result type (might be due to invalid IL or missing references) //IL_016c: Unknown result type (might be due to invalid IL or missing references) //IL_0184: Unknown result type (might be due to invalid IL or missing references) //IL_0189: Unknown result type (might be due to invalid IL or missing references) //IL_01a1: Unknown result type (might be due to invalid IL or missing references) //IL_01a6: Unknown result type (might be due to invalid IL or missing references) //IL_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_01db: Unknown result type (might be due to invalid IL or missing references) //IL_01e0: Unknown result type (might be due to invalid IL or missing references) //IL_006e: Unknown result type (might be due to invalid IL or missing references) //IL_0073: Unknown result type (might be due to invalid IL or missing references) //IL_0079: Expected O, but got Unknown //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_00f8: Expected O, but got Unknown Reminders_Treasure.Start(); Reminders_Portal.Start(); Reminders_SecretGeode.Start(); Objectives_General.Start(); Objective_Halcyonite.Start(); InteractableVisuals.Start(); Reminders_Newt.Start(); if (WConfig.module_text_reminders.Value) { object obj = <>O.<0>__RemoveReminders_Scrapper; if (obj == null) { hook_BeginScrapping_UniquePickup val = RemoveReminders_Scrapper; <>O.<0>__RemoveReminders_Scrapper = val; obj = (object)val; } ScrapperController.BeginScrapping_UniquePickup += (hook_BeginScrapping_UniquePickup)obj; object obj2 = <>O.<1>__IsFreeVoidChest_ClearNewt; if (obj2 == null) { hook_OnEnable val2 = IsFreeVoidChest_ClearNewt; <>O.<1>__IsFreeVoidChest_ClearNewt = val2; obj2 = (object)val2; } HoldoutZoneController.OnEnable += (hook_OnEnable)obj2; ExtraActions.onMithrixPhase1 = (Action)Delegate.Combine(ExtraActions.onMithrixPhase1, new Action(FailAllReminders)); ExtraActions.onFalseSonPhase1 = (Action)Delegate.Combine(ExtraActions.onFalseSonPhase1, new Action(FailAllReminders)); object obj3 = <>O.<3>__ClearTreasure_OnVoidlingDeath; if (obj3 == null) { hook_OnExit val3 = ClearTreasure_OnVoidlingDeath; <>O.<3>__ClearTreasure_OnVoidlingDeath = val3; obj3 = (object)val3; } EscapeDeath.OnExit += (hook_OnExit)obj3; MeridianEventStart.OnMeridianEventStart += ClearReminders_OnFalseSon; } object obj4 = <>O.<5>__AddReminderObject; if (obj4 == null) { hook_Awake val4 = AddReminderObject; <>O.<5>__AddReminderObject = val4; obj4 = (object)val4; } SceneInfo.Awake += (hook_Awake)obj4; Stage.onStageStartGlobal += SetupRemindersOnStart; Addressables.LoadAssetAsync((object)"e97c0cb6c5d2e3f4fb7a64cb62fe971f").WaitForCompletion().AddComponent() .interactable = SpawnListener.Interactable.lockbox; Addressables.LoadAssetAsync((object)"7cf417baadd2e8948a9645da22a57b3c").WaitForCompletion().AddComponent() .interactable = SpawnListener.Interactable.lockboxVoid; Addressables.LoadAssetAsync((object)"357435043113a944c9a477d63dc9a893").WaitForCompletion().AddComponent() .interactable = SpawnListener.Interactable.freeChest; Addressables.LoadAssetAsync((object)"f21b2c8a9cc028046935ea871dc4af54").WaitForCompletion().AddComponent() .interactable = SpawnListener.Interactable.greenPrinter; Addressables.LoadAssetAsync((object)"c10fd181efcffc24f8fed4c2f246fac8").WaitForCompletion().AddComponent() .interactable = SpawnListener.Interactable.halcyonShrine; } private static void AddReminderObject(orig_Awake orig, SceneInfo self) { orig.Invoke(self); TreasureReminder.Replace(); } private static void SetupRemindersOnStart(Stage obj) { if (Object.op_Implicit((Object)(object)SceneInfo.instance)) { if (WConfig.module_text_reminders.Value && (SceneInfo.instance.countsAsStage || SceneInfo.instance.sceneDef.allowItemsToSpawnObjects)) { TreasureReminder.SetupRemindersStatic(); } Log.LogMessage("CurrentStage: " + SceneInfo.instance.sceneDef.baseSceneName); } } private static void RemoveReminders_Scrapper(orig_BeginScrapping_UniquePickup orig, ScrapperController self, UniquePickup pickupToTake) { //IL_0003: 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_0020: Unknown result type (might be due to invalid IL or missing references) //IL_0026: Invalid comparison between Unknown and I4 //IL_0031: 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_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) orig.Invoke(self, pickupToTake); PickupDef pickupDef = PickupCatalog.GetPickupDef(pickupToTake.pickupIndex); if (pickupDef == null || (int)pickupDef.itemIndex == -1) { return; } if (pickupDef.itemIndex == Items.TreasureCache.itemIndex) { TreasureReminder.CheckKeysVoided(); } else if (pickupDef.itemIndex == Items.LowerPricedChests.itemIndex) { CharacterBody component = ((Component)self.interactor).GetComponent(); if ((Object)(object)TreasureReminder.instance != (Object)null) { TreasureReminder.instance.ScrappedSaleStar(component); } } } private static void Run_onRunStartGlobal(Run obj) { ((Component)obj).gameObject.AddComponent(); } private static void IsFreeVoidChest_ClearNewt(orig_OnEnable orig, HoldoutZoneController self) { orig.Invoke(self); if (!Object.op_Implicit((Object)(object)TreasureReminder.instance)) { return; } if (Object.op_Implicit((Object)(object)((Component)self).GetComponent())) { if (Object.op_Implicit((Object)(object)TreasureReminder.instance.Objective_NewtShrine)) { FailObjective(TreasureReminder.instance.Objective_NewtShrine); } } else if (((Object)self).name.StartsWith("VoidShellBattery") && Object.op_Implicit((Object)(object)TreasureReminder.instance.Objective_FreeChestVVVoid)) { Object.Destroy((Object)(object)TreasureReminder.instance.Objective_FreeChestVVVoid); } } private static void ClearTreasure_OnVoidlingDeath(orig_OnExit orig, EscapeDeath self) { orig.Invoke(self); FailAllReminders(); } public static void FailAllReminders() { TreasureReminder instance = TreasureReminder.instance; if (Object.op_Implicit((Object)(object)instance)) { if (Object.op_Implicit((Object)(object)instance.Objective_Lockbox)) { FailObjective(instance.Objective_Lockbox); } if (Object.op_Implicit((Object)(object)instance.Objective_LockboxVoid)) { FailObjective(instance.Objective_LockboxVoid); } if (Object.op_Implicit((Object)(object)instance.Objective_FreeChest)) { FailObjective(instance.Objective_FreeChest); } if (Object.op_Implicit((Object)(object)instance.Objective_FreeChestVVVoid)) { FailObjective(instance.Objective_FreeChestVVVoid); } if (Object.op_Implicit((Object)(object)instance.Objective_SaleStar)) { FailObjective(instance.Objective_SaleStar); } if (Object.op_Implicit((Object)(object)instance.Objective_RegenScrap)) { FailObjective(instance.Objective_RegenScrap); } if (Object.op_Implicit((Object)(object)instance.Objective_NewtShrine)) { FailObjective(instance.Objective_NewtShrine); } } } public static void FailObjective(GenericObjectiveProvider objective) { if (!Object.op_Implicit((Object)(object)objective)) { Log.LogMessage("FailObjective Null Objective"); return; } objective.markCompletedOnRetired = false; objective.objectiveToken = "" + Language.GetString(objective.objectiveToken) + ""; ((Behaviour)objective).enabled = false; } public static void CompleteObjective(GenericObjectiveProvider objective) { if (!Object.op_Implicit((Object)(object)objective)) { Log.LogMessage("CompleteObjective Null Objective"); return; } objective.objectiveToken = "" + objective.objectiveToken + ""; ((Behaviour)objective).enabled = false; } private static void ClearReminders_OnFalseSon() { GameObject val = GameObject.Find("/Meridian_Halcyonite_Encounter"); if (Object.op_Implicit((Object)(object)val)) { GenericObjectiveProvider component = val.GetComponent(); if (Object.op_Implicit((Object)(object)component)) { FailObjective(component); } } GameObject val2 = GameObject.Find("/HOLDER: Design/Objective_ReachTemple"); GameObject val3 = GameObject.Find("/HOLDER: Design/Objective_ReachArena"); if (Object.op_Implicit((Object)(object)val2)) { ((Behaviour)val2.GetComponent()).enabled = false; } if (Object.op_Implicit((Object)(object)val3)) { ((Behaviour)val3.GetComponent()).enabled = false; } } } public class SpawnListener : MonoBehaviour { public enum Interactable { None, lockbox, lockboxVoid, freeChest, vvVoidFreeChest, greenPrinter, greenPrinterQuality, QualityCollectorsBarrel, newtAltar, halcyonShrine } public Interactable interactable; public void OnEnable() { if (!Object.op_Implicit((Object)(object)TreasureReminder.instance)) { ((Behaviour)this).enabled = false; return; } switch (interactable) { case Interactable.greenPrinter: TreasureReminder.instance.greenPrinterSpawned = true; break; case Interactable.greenPrinterQuality: TreasureReminder.instance.greenQualityPrinterSpawned = true; break; case Interactable.vvVoidFreeChest: TreasureReminder.instance.voidFreeChestSpawned = true; break; case Interactable.newtAltar: TreasureReminder.instance.newtShrineSpawned++; break; case Interactable.halcyonShrine: TreasureReminder.instance.halcyonSpawned = true; break; case Interactable.lockbox: TreasureReminder.instance.lockboxCount++; break; case Interactable.lockboxVoid: TreasureReminder.instance.lockboxVoidCount++; break; case Interactable.freeChest: TreasureReminder.instance.freeChestCount++; break; case Interactable.QualityCollectorsBarrel: TreasureReminder.instance.qualityCollectors++; break; } } public void OnDisable() { if (interactable == Interactable.newtAltar && TreasureReminder.instance.newtShrineSpawned != 0) { TreasureReminder.instance.newtShrineSpawned--; } } } public class TreasureReminder : MonoBehaviour { public static TreasureReminder instance; public int lockboxCount = 0; public int lockboxVoidCount = 0; public int freeChestCount = 0; public int qualityCollectors = 0; public bool freeChestVoidBool = false; public bool localHasSaleStar = false; public bool localHasRegenScrap = false; public bool localHasRegenScrapQuality = false; public bool halcyonSpawned = false; public bool greenPrinterSpawned = false; public bool greenQualityPrinterSpawned = false; public bool voidFreeChestSpawned = false; public int newtShrineSpawned = 0; public GenericObjectiveProvider Objective_Lockbox; public GenericObjectiveProvider Objective_LockboxVoid; public GenericObjectiveProvider Objective_FreeChest; public GenericObjectiveProvider Objective_FreeChestVVVoid; public GenericObjectiveProvider Objective_SaleStar; public GenericObjectiveProvider Objective_RegenScrap; public GenericObjectiveProvider Objective_Quality_Collectors; public GenericObjectiveProvider Objective_NewtShrine; public GenericObjectiveProvider Objective_Halcyon; public GenericObjectiveProvider Objective_AccessNode; public GenericObjectiveProvider Objective_SecretGeode; public void Awake() { instance = this; } public static void SetupRemindersStatic() { if ((Object)(object)instance == (Object)null) { Replace(); } instance.SetupReminders(); } public static void Replace() { //IL_0021: Unknown result type (might be due to invalid IL or missing references) if (Object.op_Implicit((Object)(object)instance)) { Object.Destroy((Object)(object)instance); } instance = new GameObject("WQoLTreasureReminderHolder").AddComponent(); } public void SetupReminders() { bool flag = Run.instance is InfiniteTowerRun; if (flag && WConfig.cfgRemindersNOTINSIMU.Value) { return; } int num = 0; int num2 = 0; Inventory inventory = LocalUserManager.GetFirstLocalUser().cachedMaster.inventory; if (WQoLMain.QualityModInstalled) { localHasSaleStar = QualitySupport.QualiyItemCountPermanent(Items.LowerPricedChests, inventory) > 0; localHasRegenScrap = QualitySupport.QualiyItemCountPermanent(Items.RegeneratingScrap, inventory) > 0; localHasRegenScrapQuality = QualitySupport.QualiyItemCountPermanent(Items.RegeneratingScrap, inventory, justQuality: true) > 0; using IEnumerator enumerator = PlayerCharacterMasterController.instances.GetEnumerator(); while (enumerator.MoveNext()) { num += QualitySupport.QualiyItemCountPermanent(Items.TreasureCache, enumerator.Current.master.inventory); num2 += QualitySupport.QualiyItemCountPermanent(Items.TreasureCacheVoid, enumerator.Current.master.inventory); } } else { localHasSaleStar = inventory.GetItemCountPermanent(Items.LowerPricedChests) > 0; localHasRegenScrap = inventory.GetItemCountPermanent(Items.RegeneratingScrap) > 0; using IEnumerator enumerator2 = PlayerCharacterMasterController.instances.GetEnumerator(); while (enumerator2.MoveNext()) { num += enumerator2.Current.master.inventory.GetItemCountPermanent(Items.TreasureCache); num2 += enumerator2.Current.master.inventory.GetItemCountPermanent(Items.TreasureCacheVoid); } } lockboxCount = Mathf.Min(lockboxCount, num); lockboxVoidCount = Mathf.Min(lockboxVoidCount, num2); if (!flag && SceneCatalog.mostRecentSceneDef.stageOrder > 5) { localHasSaleStar = false; localHasRegenScrap = false; } if (!flag && WConfig.cfgReminder_AccessNode.Value && Object.op_Implicit((Object)(object)AccessCodesMissionController.instance) && AccessCodesMissionController.instance.nodes[0].node.activeSelf) { Objective_AccessNode = ((Component)instance).gameObject.AddComponent(); Objective_AccessNode.objectiveToken = Language.GetString("REMINDER_ACCESSNODE"); } if (!flag && WConfig.cfgRemindersNewt.Value != 0 && (newtShrineSpawned > 0 || WConfig.cfgRemindersNewt.Value == WConfig.ReminderChoice.Always) && Object.op_Implicit((Object)(object)TeleporterInteraction.instance) && !TeleporterInteraction.instance.shouldAttemptToSpawnShopPortal) { Objective_NewtShrine = ((Component)instance).gameObject.AddComponent(); Objective_NewtShrine.objectiveToken = Language.GetString("REMINDER_NEWT"); } if (WConfig.cfgReminder_Halcyon.Value && halcyonSpawned && !flag) { Objective_Halcyon = ((Component)instance).gameObject.AddComponent(); Objective_Halcyon.objectiveToken = Language.GetString("REMINDER_HALCYON"); } if (WConfig.cfgRemindersKeys.Value) { if (lockboxVoidCount > 0) { Objective_LockboxVoid = ((Component)instance).gameObject.AddComponent(); if (lockboxVoidCount > 1) { Objective_LockboxVoid.objectiveToken = string.Format(Language.GetString("REMINDER_KEYVOID_MANY"), lockboxVoidCount); } else { Objective_LockboxVoid.objectiveToken = Language.GetString("REMINDER_KEYVOID"); } } if (lockboxCount > 0) { Objective_Lockbox = ((Component)instance).gameObject.AddComponent(); if (lockboxCount > 1) { Objective_Lockbox.objectiveToken = string.Format(Language.GetString("REMINDER_KEY_MANY"), lockboxCount); } else { Objective_Lockbox.objectiveToken = Language.GetString("REMINDER_KEY"); } } } if (WConfig.cfgRemindersFreechest.Value && freeChestCount > 0) { Objective_FreeChest = ((Component)instance).gameObject.AddComponent(); if (freeChestCount > 1) { Objective_FreeChest.objectiveToken = string.Format(Language.GetString("REMINDER_FREECHEST_MANY"), freeChestCount); } else { Objective_FreeChest.objectiveToken = Language.GetString("REMINDER_FREECHEST"); } } if (WConfig.cfgReminders_VV_FreechestVoid.Value && voidFreeChestSpawned) { Objective_FreeChestVVVoid = ((Component)instance).gameObject.AddComponent(); Objective_FreeChestVVVoid.objectiveToken = Language.GetString("REMINDER_FREECHESTVOID"); } if (WConfig.cfgReminders_Quality_Collectors.Value && qualityCollectors > 0) { Objective_Quality_Collectors = ((Component)instance).gameObject.AddComponent(); if (qualityCollectors > 1) { Objective_Quality_Collectors.objectiveToken = string.Format(Language.GetString("REMINDER_QUALITY_COOLBARREL2"), qualityCollectors); } else { Objective_Quality_Collectors.objectiveToken = Language.GetString("REMINDER_QUALITY_COOLBARREL"); } } if (WConfig.cfgRemindersRegenScrap.Value != 0 && !flag && localHasRegenScrap && (greenPrinterSpawned || (localHasRegenScrapQuality && greenQualityPrinterSpawned) || WConfig.cfgRemindersRegenScrap.Value == WConfig.ReminderChoice.Always)) { Objective_RegenScrap = ((Component)instance).gameObject.AddComponent(); Objective_RegenScrap.objectiveToken = Language.GetString("REMINDER_REGENSCRAP"); } if (WConfig.cfgRemindersSaleStar.Value && localHasSaleStar) { Objective_SaleStar = ((Component)instance).gameObject.AddComponent(); Objective_SaleStar.objectiveToken = Language.GetString("REMINDER_SALESTAR"); } } public static void CheckKeysVoided() { int num = 0; int num2 = 0; using (IEnumerator enumerator = PlayerCharacterMasterController.instances.GetEnumerator()) { while (enumerator.MoveNext()) { num += enumerator.Current.master.inventory.GetItemCountPermanent(Items.TreasureCache); num2 += enumerator.Current.master.inventory.GetItemCountPermanent(Items.TreasureCacheVoid); } } ShouldRemoveKeyObjective(num, num2); } public static void CheckItemsDestroyed() { if (Object.op_Implicit((Object)(object)instance)) { bool flag = false; bool flag2 = false; if (WQoLMain.QualityModInstalled) { flag = QualitySupport.QualiyItemCountPermanent(Items.LowerPricedChests, LocalUserManager.GetFirstLocalUser().cachedMaster.inventory) > 0; flag2 = QualitySupport.QualiyItemCountPermanent(Items.RegeneratingScrap, LocalUserManager.GetFirstLocalUser().cachedMaster.inventory) > 0; } else { flag = LocalUserManager.GetFirstLocalUser().cachedMaster.inventory.GetItemCountPermanent(Items.LowerPricedChests) > 0; flag2 = LocalUserManager.GetFirstLocalUser().cachedMaster.inventory.GetItemCountPermanent(Items.RegeneratingScrap) > 0; } if (instance.localHasSaleStar && !flag) { Reminders_Main.FailObjective(instance.Objective_SaleStar); } if (instance.localHasRegenScrap && !flag2) { Reminders_Main.FailObjective(instance.Objective_RegenScrap); } } } public static void ShouldRemoveKeyObjective(int keys, int voidKeys) { if ((Object)(object)instance == (Object)null) { return; } if (keys == 0) { Reminders_Main.FailObjective(instance.Objective_Lockbox); } else if (instance.lockboxCount > keys) { for (int num = instance.lockboxCount; num > keys; num--) { Deduct(instance.Objective_Lockbox, ref instance.lockboxCount); } } if (voidKeys == 0) { Reminders_Main.FailObjective(instance.Objective_LockboxVoid); } else if (instance.lockboxVoidCount > voidKeys) { for (int num2 = instance.lockboxVoidCount; num2 > keys; num2--) { Deduct(instance.Objective_LockboxVoid, ref instance.lockboxVoidCount); } } } public static void Deduct(GenericObjectiveProvider objective, ref int number) { if (!((Object)(object)objective == (Object)null)) { if (number > 0) { string oldValue = "(" + number + "/"; number--; string newValue = "(" + number + "/"; objective.objectiveToken = objective.objectiveToken.Replace(oldValue, newValue); } if (number == 0) { Reminders_Main.CompleteObjective(objective); } } } public void ScrappedSaleStar(CharacterBody body) { CharacterMaster master = body.master; if ((Object)(object)Objective_SaleStar != (Object)null) { if (Object.op_Implicit((Object)(object)body) && Object.op_Implicit((Object)(object)body.master)) { master = body.master; } if (!Object.op_Implicit((Object)(object)master)) { Log.LogWarning("Remove Sale Star Objective No master"); } PlayerCharacterMasterController val = default(PlayerCharacterMasterController); if (Object.op_Implicit((Object)(object)master) && ((Component)master).TryGetComponent(ref val) && ((NetworkBehaviour)val.networkUser).isLocalPlayer) { Reminders_Main.FailObjective(Objective_SaleStar); } } } } } namespace WolfoQoL_Client.Text { public static class DeathMessage { public class DetailedDeathMessage : SubjectChatMessage { public string victimName; public string killerBackupName; public string damageDone; public bool crit; public bool doesNotShowEnemy; public GameObject attackerObject; public GameObject victimMaster; public override string ConstructChatString() { if (!WConfig.module_text_chat.Value) { return null; } string text = ""; if ((Object)(object)attackerObject != (Object)null) { text = Util.GetBestBodyName(attackerObject); text = text.Replace("\n", " "); } else { text = Language.GetString(killerBackupName); } string empty = string.Empty; if (((SubjectChatMessage)this).IsSecondPerson()) { base.baseToken += "_2P"; } empty += string.Format(Language.GetString(base.baseToken), victimName, text); empty += string.Format(Language.GetString("DEATH_DAMAGE"), damageDone); victimMaster.GetComponent().latestDetailedDeathMessage = empty; if (!WConfig.cfgMessageDeath.Value) { return null; } return "" + empty; } public override void Serialize(NetworkWriter writer) { ((SubjectChatMessage)this).Serialize(writer); writer.Write(victimName); writer.Write(killerBackupName); writer.Write(damageDone); writer.Write(attackerObject); writer.Write(victimMaster); writer.Write(crit); } public override void Deserialize(NetworkReader reader) { if (!WQoLMain.NoHostInfo) { ((SubjectChatMessage)this).Deserialize(reader); victimName = reader.ReadString(); killerBackupName = reader.ReadString(); damageDone = reader.ReadString(); attackerObject = reader.ReadGameObject(); victimMaster = reader.ReadGameObject(); crit = reader.ReadBoolean(); } } } public static void OnDeathMessage(orig_OnPlayerCharacterDeath orig, GlobalEventManager self, DamageReport damageReport, NetworkUser victimNetworkUser) { try { orig.Invoke(self, damageReport, victimNetworkUser); DetailedDeathMessages(damageReport); } catch (Exception ex) { Debug.LogError((object)ex); orig.Invoke(self, damageReport, victimNetworkUser); } } public static void DetailedDeathMessages(DamageReport damageReport) { //IL_0055: 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) float num = damageReport.damageInfo.damage; if (damageReport.damageInfo.crit) { num *= 2f; } if (damageReport.damageDealt > num) { num = damageReport.damageDealt; } DeathAndKillerInventoryMessage(num, damageReport.victimBody, damageReport.attackerBody, damageReport.attackerMaster, damageReport.damageInfo.damageType, damageReport.damageInfo.damageColorIndex, damageReport.damageInfo.delayedDamageSecondHalf, sendOverNetwork: true); } public static void DeathAndKillerInventoryMessage(float damage, CharacterBody victimBody, CharacterBody attackerBody, CharacterMaster attackerMaster, DamageTypeCombo damageType, DamageColorIndex dmgColor, bool echo, bool sendOverNetwork) { //IL_0094: 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_00b0: 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_007e: 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_0113: 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_012d: Unknown result type (might be due to invalid IL or missing references) //IL_0131: Invalid comparison between Unknown and I4 //IL_00ea: Unknown result type (might be due to invalid IL or missing references) //IL_00ee: Invalid comparison between Unknown and I4 //IL_014a: 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_0328: Unknown result type (might be due to invalid IL or missing references) //IL_032d: Unknown result type (might be due to invalid IL or missing references) //IL_033a: Unknown result type (might be due to invalid IL or missing references) //IL_033f: Unknown result type (might be due to invalid IL or missing references) if ((Object)(object)victimBody == (Object)null || (Object)(object)victimBody.master == (Object)null) { return; } string bestBodyName = Util.GetBestBodyName(((Component)victimBody).gameObject); string text = "UNIDENTIFIED_KILLER_NAME"; if ((Object)(object)attackerBody != (Object)null) { text = Util.GetBestBodyName(((Component)attackerBody).gameObject); text = text.Replace("\n", " "); } bool flag = Object.op_Implicit((Object)(object)attackerBody) && Object.op_Implicit((Object)(object)attackerBody.teamComponent) && attackerBody.teamComponent.teamIndex == victimBody.teamComponent.teamIndex; bool flag2 = ((Enum)damageType.damageType).HasFlag((Enum)(object)(DamageType)2097152); bool flag3 = ((Enum)damageType.damageType).HasFlag((Enum)(object)(DamageType)67108864); string text2 = ""; text2 = ((flag3 && !flag) ? ((!flag3 || (int)dmgColor != 9) ? "DEATH_DOT_GENERIC" : "DEATH_DOT_FRACTURE") : ((((Enum)damageType.damageType).HasFlag((Enum)(object)(DamageType)66) && (int)dmgColor == 9) ? "DEATH_VOID_FOG" : (((Enum)damageType.damageType).HasFlag((Enum)(object)(DamageType)65536) ? "DEATH_VOID_EXPLODE" : (flag2 ? "DEATH_FALL_DAMAGE" : (((Object)(object)attackerBody != (Object)null && flag) ? ((!((Object)(object)attackerBody == (Object)(object)victimBody)) ? "DEATH_FRIENDLY" : "DEATH_FRIENDLY_SUICIDE") : (echo ? "DEATH_ECHO" : (((Object)(object)attackerBody == (Object)null && victimBody.inLava) ? "DEATH_LAVA" : ((!victimBody.isGlass) ? "DEATH_GENERIC" : "DEATH_GLASS")))))))); string empty = string.Empty; empty = ((damage > 1000f) ? $"{damage:F0}" : ((!(damage > 100f)) ? $"{damage:F2}" : $"{damage:F1}")); DetailedDeathMessage detailedDeathMessage = new DetailedDeathMessage(); ((SubjectChatMessage)detailedDeathMessage).subjectAsCharacterBody = victimBody; ((SubjectChatMessage)detailedDeathMessage).baseToken = text2; detailedDeathMessage.victimName = bestBodyName; detailedDeathMessage.victimMaster = ((Component)victimBody.master).gameObject; detailedDeathMessage.killerBackupName = text; detailedDeathMessage.damageDone = empty; detailedDeathMessage.attackerObject = (Object.op_Implicit((Object)(object)attackerBody) ? ((Component)attackerBody).gameObject : null); DetailedDeathMessage detailedDeathMessage2 = detailedDeathMessage; KillerInventoryMessage killerInventoryMessage = new KillerInventoryMessage { killerBackupName = text, attackerObject = (Object.op_Implicit((Object)(object)attackerBody) ? ((Component)attackerBody).gameObject : null), victimMaster = (Object.op_Implicit((Object)(object)victimBody) ? ((Component)victimBody.master).gameObject : null) }; if (Object.op_Implicit((Object)(object)attackerMaster)) { killerInventoryMessage.itemStacks = attackerMaster.inventory.effectiveItemStacks; killerInventoryMessage.primaryEquipment = attackerMaster.inventory.currentEquipmentIndex; } Log.LogMessage(bestBodyName + " killed by " + text + " | Networked? " + sendOverNetwork); if (sendOverNetwork) { Networker.SendWQoLMessage((ChatMessageBase)(object)detailedDeathMessage2); if (victimBody.master.IsDeadAndOutOfLivesServer()) { Networker.SendWQoLMessage((ChatMessageBase)(object)killerInventoryMessage); } } else { Chat.AddMessage((ChatMessageBase)(object)detailedDeathMessage2); Chat.AddMessage((ChatMessageBase)(object)killerInventoryMessage); } } } public class DevotionDeathMessage : PlayerPickupChatMessage { public override string ConstructChatString() { if (!WConfig.module_text_chat.Value) { return null; } if (!WConfig.cfgMessageDevotion.Value) { return null; } return ((PlayerPickupChatMessage)this).ConstructChatString(); } } public static class DevotionLoss { [CompilerGenerated] private static class <>O { public static hook_RemoveItem <0>__Host_DevotionDeathMessage; public static hook_InitializeDevotedLemurian <1>__Host_EggMessage; public static hook_OnDeserialize <2>__Client_TryEggMessage; public static hook_PreStartClient <3>__Client_TryAssignMasterToInventory; } public static void Start() { //IL_0011: 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_001c: Expected O, but got Unknown //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Unknown result type (might be due to invalid IL or missing references) //IL_003d: Expected O, but got Unknown //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_005e: Expected O, but got Unknown //IL_0074: Unknown result type (might be due to invalid IL or missing references) //IL_0079: Unknown result type (might be due to invalid IL or missing references) //IL_007f: Expected O, but got Unknown object obj = <>O.<0>__Host_DevotionDeathMessage; if (obj == null) { hook_RemoveItem val = Host_DevotionDeathMessage; <>O.<0>__Host_DevotionDeathMessage = val; obj = (object)val; } DevotionInventoryController.RemoveItem += (hook_RemoveItem)obj; object obj2 = <>O.<1>__Host_EggMessage; if (obj2 == null) { hook_InitializeDevotedLemurian val2 = Host_EggMessage; <>O.<1>__Host_EggMessage = val2; obj2 = (object)val2; } DevotedLemurianController.InitializeDevotedLemurian += (hook_InitializeDevotedLemurian)obj2; object obj3 = <>O.<2>__Client_TryEggMessage; if (obj3 == null) { hook_OnDeserialize val3 = Client_TryEggMessage; <>O.<2>__Client_TryEggMessage = val3; obj3 = (object)val3; } PickupPickerController.OnDeserialize += (hook_OnDeserialize)obj3; object obj4 = <>O.<3>__Client_TryAssignMasterToInventory; if (obj4 == null) { hook_PreStartClient val4 = Client_TryAssignMasterToInventory; <>O.<3>__Client_TryAssignMasterToInventory = val4; obj4 = (object)val4; } DevotionInventoryController.PreStartClient += (hook_PreStartClient)obj4; } private static void Host_DevotionDeathMessage(orig_RemoveItem orig, DevotionInventoryController self, ItemIndex itedmIndex, int count) { //IL_0003: Unknown result type (might be due to invalid IL or missing references) //IL_000b: Unknown result type (might be due to invalid IL or missing references) //IL_000c: 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_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_0059: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self, itedmIndex, count); PickupIndex val = PickupCatalog.FindPickupIndex(itedmIndex); PickupDef pickupDef = ((PickupIndex)(ref val)).pickupDef; DevotionDeathMessage devotionDeathMessage = new DevotionDeathMessage(); ((SubjectChatMessage)devotionDeathMessage).subjectAsNetworkUser = self.SummonerMaster.playerCharacterMasterController.networkUser; ((SubjectChatMessage)devotionDeathMessage).baseToken = "DEVOTED_LEMURIAN_DEATH"; ((PlayerPickupChatMessage)devotionDeathMessage).pickupToken = pickupDef.nameToken; ((PlayerPickupChatMessage)devotionDeathMessage).pickupColor = Color32.op_Implicit(pickupDef.baseColor); ((PlayerPickupChatMessage)devotionDeathMessage).pickupQuantity = (uint)count; Networker.SendWQoLMessage((ChatMessageBase)(object)devotionDeathMessage); } private static void Client_TryEggMessage(orig_OnDeserialize orig, PickupPickerController self, NetworkReader reader, bool initialState) { bool available = self.available; orig.Invoke(self, reader, initialState); if (available && !self.available && Object.op_Implicit((Object)(object)((Component)self).GetComponent())) { PlayerItemLoss_ClientListener.source = ItemLossMessage.Source.LemurianEgg; PlayerItemLoss_ClientListener.token = "ITEM_LOSS_EGG"; ItemLossBase_ClientListener.TryMessage(); } } private static void Client_TryAssignMasterToInventory(orig_PreStartClient orig, DevotionInventoryController self) { orig.Invoke(self); if (Object.op_Implicit((Object)(object)ItemLossBase_ClientListener.latest)) { self.SummonerMaster = ItemLossBase_ClientListener.latest.subjectAsNetworkUser.master; DevotionItemLoss_ClientListener devotionItemLoss_ClientListener = ((Component)self).gameObject.AddComponent(); } } private static void Client_TryDeathMessage(orig_Start orig, DevotedLemurianController self) { orig.Invoke(self); if (!WQoLMain.HostHasMod) { self._lemurianMaster = ((Component)self).GetComponent(); } } private static void Host_EggMessage(orig_InitializeDevotedLemurian orig, DevotedLemurianController self, ItemIndex itemIndex, DevotionInventoryController devotionInventoryController) { //IL_0003: 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_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) orig.Invoke(self, itemIndex, devotionInventoryController); ItemLossMessage obj = new ItemLossMessage { baseToken = "ITEM_LOSS_EGG", itemCount = 1, pickupIndexOnlyOneItem = PickupCatalog.FindPickupIndex(itemIndex) }; ((SubjectChatMessage)obj).subjectAsNetworkUser = self._devotionInventoryController.SummonerMaster.playerCharacterMasterController.networkUser; Networker.SendWQoLMessage((ChatMessageBase)(object)obj); } } public static class DroneMessages { [CompilerGenerated] private static class <>O { public static hook_StartDroneCombineSequence <0>__CombinerMessage_ClientHost; public static hook_AddMinion <1>__DroneMessage_ClientOnly; public static hook_SpawnRemoteOperationDrone <2>__RemoteOP_Host; public static hook_NotifySummonerInternal <3>__DroneMessage_RepairHost; public static hook_NotifySummonerInternal <4>__DroneMessage_RepairHostShop; } public static void Start() { //IL_0011: 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_001c: Expected O, but got Unknown //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Unknown result type (might be due to invalid IL or missing references) //IL_003d: Expected O, but got Unknown //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_005e: Expected O, but got Unknown //IL_0074: Unknown result type (might be due to invalid IL or missing references) //IL_0079: Unknown result type (might be due to invalid IL or missing references) //IL_007f: Expected O, but got Unknown //IL_0095: 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_00a0: Expected O, but got Unknown object obj = <>O.<0>__CombinerMessage_ClientHost; if (obj == null) { hook_StartDroneCombineSequence val = CombinerMessage_ClientHost; <>O.<0>__CombinerMessage_ClientHost = val; obj = (object)val; } DroneCombinerCombining.StartDroneCombineSequence += (hook_StartDroneCombineSequence)obj; object obj2 = <>O.<1>__DroneMessage_ClientOnly; if (obj2 == null) { hook_AddMinion val2 = DroneMessage_ClientOnly; <>O.<1>__DroneMessage_ClientOnly = val2; obj2 = (object)val2; } MinionGroup.AddMinion += (hook_AddMinion)obj2; object obj3 = <>O.<2>__RemoteOP_Host; if (obj3 == null) { hook_SpawnRemoteOperationDrone val3 = RemoteOP_Host; <>O.<2>__RemoteOP_Host = val3; obj3 = (object)val3; } CharacterMaster.SpawnRemoteOperationDrone += (hook_SpawnRemoteOperationDrone)obj3; object obj4 = <>O.<3>__DroneMessage_RepairHost; if (obj4 == null) { hook_NotifySummonerInternal val4 = DroneMessage_RepairHost; <>O.<3>__DroneMessage_RepairHost = val4; obj4 = (object)val4; } SummonMasterBehavior.NotifySummonerInternal += (hook_NotifySummonerInternal)obj4; object obj5 = <>O.<4>__DroneMessage_RepairHostShop; if (obj5 == null) { hook_NotifySummonerInternal val5 = DroneMessage_RepairHostShop; <>O.<4>__DroneMessage_RepairHostShop = val5; obj5 = (object)val5; } DroneVendorTerminalBehavior.NotifySummonerInternal += (hook_NotifySummonerInternal)obj5; } public static void DroneMessage_ClientOnly(orig_AddMinion orig, NetworkInstanceId ownerId, MinionOwnership minion) { //IL_0002: 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_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) //IL_008d: Unknown result type (might be due to invalid IL or missing references) //IL_0090: Invalid comparison between Unknown and I4 //IL_00c2: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(ownerId, minion); if (!WConfig.DroneMessage_Repair.Value || !Object.op_Implicit((Object)(object)minion.ownerMaster) || !Object.op_Implicit((Object)(object)minion.ownerMaster.playerCharacterMasterController) || WQoLMain.HostHasMod) { return; } ((Component)minion).gameObject.AddComponent(); if (DroneCollection.isPermamentMinion(((Component)minion).gameObject)) { BodyIndex val = BodyCatalog.FindBodyIndex(((Component)minion).GetComponent().bodyPrefab); DroneIndex droneIndexFromBodyIndex = DroneCatalog.GetDroneIndexFromBodyIndex(val); if ((int)droneIndexFromBodyIndex != -1) { DroneMessage_Client(minion.group, minion.ownerMaster.playerCharacterMasterController.networkUser, ((Component)minion).GetComponent().GetItemCountPermanent(Items.DroneUpgradeHidden), droneIndexFromBodyIndex); } } } private static void CombinerMessage_ClientHost(orig_StartDroneCombineSequence orig, DroneCombinerCombining self) { //IL_009c: Unknown result type (might be due to invalid IL or missing references) //IL_00a1: Unknown result type (might be due to invalid IL or missing references) //IL_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_00c7: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self); if (!WConfig.DroneMessage_Combine.Value) { return; } CharacterBody toUpgrade = self.toUpgrade; if (!Object.op_Implicit((Object)(object)toUpgrade)) { Debug.Log((object)"DRONE COMBINING BUT NO DRONE"); return; } CharacterBody ownerBody = toUpgrade.GetOwnerBody(); if (Object.op_Implicit((Object)(object)ownerBody)) { DroneChatMessage obj = new DroneChatMessage { baseToken = "UPGRADE_DRONE", DroneTier = toUpgrade.inventory.GetItemCountEffective(Items.DroneUpgradeHidden), pickupQuantity = toUpgrade.inventory.GetItemCountEffective(Items.DroneUpgradeHidden) + 2, _DroneIndex = DroneCatalog.GetDroneIndexFromBodyIndex(toUpgrade.bodyIndex) }; ((SubjectChatMessage)obj).subjectAsCharacterBody = ownerBody; obj.noBracketQuantity = true; DroneChatMessage droneChatMessage = obj; NetworkInstanceId netId = ((NetworkBehaviour)self.vehicleSeat).netId; if (((NetworkInstanceId)(ref netId)).Value == 0) { Networker.SendWQoLMessage((ChatMessageBase)(object)droneChatMessage); } else { Chat.AddMessage((ChatMessageBase)(object)droneChatMessage); } } } private static void DroneMessage_RepairHostShop(orig_NotifySummonerInternal orig, DroneVendorTerminalBehavior self, GameObject summonerBodyObject, GameObject minionBodyObject) { orig.Invoke(self, summonerBodyObject, minionBodyObject); DroneMessage_Host(summonerBodyObject, minionBodyObject, self._cachedPickup.upgradeValue, "PURCHASE_DRONE"); } private static void DroneMessage_RepairHost(orig_NotifySummonerInternal orig, SummonMasterBehavior self, GameObject summonerBodyObject, GameObject minionBodyObject) { orig.Invoke(self, summonerBodyObject, minionBodyObject); DroneMessage_Host(summonerBodyObject, minionBodyObject, self.droneUpgradeCount, "REPAIR_DRONE"); } private static void DroneMessage_Upgrading(orig_SeatAndHideDrone orig, DroneCombinerCombining self, CharacterBody drone) { //IL_005c: Unknown result type (might be due to invalid IL or missing references) //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_0066: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self, drone); CharacterBody ownerBody = drone.GetOwnerBody(); if (Object.op_Implicit((Object)(object)ownerBody)) { DroneChatMessage obj = new DroneChatMessage { baseToken = "UPGRADE_DRONE", DroneTier = drone.inventory.GetItemCountEffective(Items.DroneUpgradeHidden), pickupQuantity = drone.inventory.GetItemCountEffective(Items.DroneUpgradeHidden) + 2, _DroneIndex = DroneCatalog.GetDroneIndexFromBodyIndex(drone.bodyIndex) }; ((SubjectChatMessage)obj).subjectAsCharacterBody = ownerBody; obj.noBracketQuantity = true; Networker.SendWQoLMessage((ChatMessageBase)(object)obj); } } private static void RemoteOP_Host(orig_SpawnRemoteOperationDrone orig, CharacterMaster self, string droneBodyToSpawn, uint moneyToUse) { //IL_003f: Unknown result type (might be due to invalid IL or missing references) //IL_0044: Unknown result type (might be due to invalid IL or missing references) //IL_0049: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self, droneBodyToSpawn, moneyToUse); if (WConfig.DroneMessage_RemoteOp.Value && !string.IsNullOrEmpty(droneBodyToSpawn)) { DroneChatMessage obj = new DroneChatMessage { baseToken = "REMOTEOP_DRONE", _DroneIndex = DroneCatalog.GetDroneIndexFromBodyIndex(BodyCatalog.FindBodyIndexCaseInsensitive(droneBodyToSpawn)) }; ((SubjectChatMessage)obj).subjectAsNetworkUser = self.playerCharacterMasterController.networkUser; Networker.SendWQoLMessage((ChatMessageBase)(object)obj); } } public static void DroneMessage_Host(GameObject summonerBodyObject, GameObject minionBodyObject, int upgradeCount, string token) { //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_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_0082: Invalid comparison between Unknown and I4 //IL_009a: 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_017b: Unknown result type (might be due to invalid IL or missing references) //IL_011c: Unknown result type (might be due to invalid IL or missing references) //IL_0120: Unknown result type (might be due to invalid IL or missing references) //IL_0125: Unknown result type (might be due to invalid IL or missing references) if (!WConfig.DroneMessage_Repair.Value || !NetworkServer.active) { return; } CharacterBody val = (((Object)(object)summonerBodyObject != (Object)null) ? summonerBodyObject.GetComponent() : null); if (!Object.op_Implicit((Object)(object)val) || !Object.op_Implicit((Object)(object)val.master) || !Object.op_Implicit((Object)(object)val.master.playerCharacterMasterController)) { return; } DroneIndex droneIndexFromBodyIndex = DroneCatalog.GetDroneIndexFromBodyIndex(minionBodyObject.GetComponent().bodyIndex); if ((int)droneIndexFromBodyIndex == -1) { return; } int num = 0; MinionGroup val2 = MinionGroup.FindGroup(((NetworkBehaviour)val.master).netId); if (val2 != null) { MinionOwnership[] members = val2.members; foreach (MinionOwnership val3 in members) { if (!Object.op_Implicit((Object)(object)val3)) { continue; } CharacterMaster component = ((Component)val3).GetComponent(); if (Object.op_Implicit((Object)(object)component)) { CharacterBody body = component.GetBody(); if (Object.op_Implicit((Object)(object)body) && Object.op_Implicit((Object)(object)component.inventory) && droneIndexFromBodyIndex == DroneCatalog.GetDroneIndexFromBodyIndex(body.bodyIndex)) { num += DroneUpgradeUtils.GetDroneCountFromUpgradeCount(component.inventory.GetItemCountEffective(Items.DroneUpgradeHidden)); } } } } DroneChatMessage obj = new DroneChatMessage { baseToken = token, DroneTier = upgradeCount, _DroneIndex = droneIndexFromBodyIndex }; ((SubjectChatMessage)obj).subjectAsNetworkUser = val.master.playerCharacterMasterController.networkUser; obj.pickupQuantity = num; Networker.SendWQoLMessage((ChatMessageBase)(object)obj); } public static void DroneMessage_Client(MinionGroup minionGroup, NetworkUser networkUser, int upgradeCount, DroneIndex droneIndex) { //IL_00d0: Unknown result type (might be due to invalid IL or missing references) //IL_00d1: Unknown result type (might be due to invalid IL or missing references) //IL_0076: 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) int num = DroneUpgradeUtils.GetDroneCountFromUpgradeCount(upgradeCount); if (minionGroup != null) { MinionOwnership[] members = minionGroup.members; foreach (MinionOwnership val in members) { if (!Object.op_Implicit((Object)(object)val)) { continue; } CharacterMaster component = ((Component)val).GetComponent(); if (Object.op_Implicit((Object)(object)component)) { CharacterBody body = component.GetBody(); if (Object.op_Implicit((Object)(object)body) && Object.op_Implicit((Object)(object)component.inventory) && droneIndex == DroneCatalog.GetDroneIndexFromBodyIndex(body.bodyIndex)) { num += DroneUpgradeUtils.GetDroneCountFromUpgradeCount(component.inventory.GetItemCountEffective(Items.DroneUpgradeHidden)); } } } } DroneChatMessage obj = new DroneChatMessage { baseToken = "REPAIR_DRONE", DroneTier = upgradeCount, _DroneIndex = droneIndex }; ((SubjectChatMessage)obj).subjectAsNetworkUser = networkUser; obj.pickupQuantity = num; Chat.AddMessage((ChatMessageBase)(object)obj); } } public class DroneChatMessage : SubjectChatMessage { public DroneIndex _DroneIndex; public int DroneTier; public int pickupQuantity; public bool noBracketQuantity = false; public override string ConstructChatString() { //IL_0046: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Invalid comparison between Unknown and I4 //IL_005a: Unknown result type (might be due to invalid IL or missing references) if (!WConfig.module_text_chat.Value) { return null; } if (((SubjectChatMessage)this).IsSecondPerson()) { base.baseToken += "_2P"; } string text = ""; if ((int)_DroneIndex != -1) { text += Help.GetColoredName(_DroneIndex, DroneTier); } string arg = ""; if (noBracketQuantity) { arg = pickupQuantity.ToString(); } else if ((long)pickupQuantity > 1L) { arg = "(" + pickupQuantity + ")"; } return string.Format(Language.GetString(base.baseToken), ((SubjectChatMessage)this).GetSubjectName(), text, arg); } public override void Serialize(NetworkWriter writer) { //IL_000b: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Expected I4, but got Unknown ((SubjectChatMessage)this).Serialize(writer); writer.Write((int)_DroneIndex); writer.Write(DroneTier); writer.Write(pickupQuantity); writer.Write(noBracketQuantity); } public override void Deserialize(NetworkReader reader) { //IL_001c: Unknown result type (might be due to invalid IL or missing references) if (!WQoLMain.NoHostInfo) { ((SubjectChatMessage)this).Deserialize(reader); _DroneIndex = (DroneIndex)reader.ReadInt32(); DroneTier = reader.ReadInt32(); pickupQuantity = reader.ReadInt32(); noBracketQuantity = reader.ReadBoolean(); } } } public static class ItemLoss_Host { [CompilerGenerated] private static class <>O { public static Manipulator <0>__ScrappingMessage; public static hook_TryDestroyDrone <1>__DroneScrapperController_TryDestroyDrone; public static Manipulator <2>__ItemGiveUpMessages; } public static void Start() { //IL_0011: 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_001c: Expected O, but got Unknown //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Unknown result type (might be due to invalid IL or missing references) //IL_003d: Expected O, but got Unknown //IL_0067: Unknown result type (might be due to invalid IL or missing references) //IL_006c: Unknown result type (might be due to invalid IL or missing references) //IL_0072: Expected O, but got Unknown object obj = <>O.<0>__ScrappingMessage; if (obj == null) { Manipulator val = ScrappingMessage; <>O.<0>__ScrappingMessage = val; obj = (object)val; } ScrapperController.BeginScrapping_UniquePickup += (Manipulator)obj; object obj2 = <>O.<1>__DroneScrapperController_TryDestroyDrone; if (obj2 == null) { hook_TryDestroyDrone val2 = DroneScrapperController_TryDestroyDrone; <>O.<1>__DroneScrapperController_TryDestroyDrone = val2; obj2 = (object)val2; } DroneScrapperController.TryDestroyDrone += (hook_TryDestroyDrone)obj2; if (WConfig.module_text_chat.Value) { object obj3 = <>O.<2>__ItemGiveUpMessages; if (obj3 == null) { Manipulator val3 = ItemGiveUpMessages; <>O.<2>__ItemGiveUpMessages = val3; obj3 = (object)val3; } PurchaseInteraction.OnInteractionBegin += (Manipulator)obj3; } } private static bool DroneScrapperController_TryDestroyDrone(orig_TryDestroyDrone orig, DroneScrapperController self, CharacterBody body) { //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_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) bool flag = orig.Invoke(self, body); if (flag && Object.op_Implicit((Object)(object)self.interactor)) { CharacterBody component = ((Component)self.interactor).GetComponent(); if (Object.op_Implicit((Object)(object)component) && Object.op_Implicit((Object)(object)component.inventory)) { ItemLossMessage obj = new ItemLossMessage { source = ItemLossMessage.Source.DroneScrapper, baseToken = "ITEM_LOSS_SCRAP", itemCount = body.inventory.GetItemCountEffective(Items.DroneUpgradeHidden), pickupIndexOnlyOneItem = PickupCatalog.FindPickupIndex(DroneCatalog.GetDroneIndexFromBodyIndex(body.bodyIndex)) }; ((SubjectChatMessage)obj).subjectAsCharacterBody = component; Networker.SendWQoLMessage((ChatMessageBase)(object)obj); } } return flag; } private static void CountDown_OnExit(orig_OnExit orig, CountDown self) { //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_0077: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self); if (Object.op_Implicit((Object)(object)((QuestVolatileBatteryBaseState)self).attachedHealthComponent.body) && Object.op_Implicit((Object)(object)((QuestVolatileBatteryBaseState)self).attachedHealthComponent.body.master) && Object.op_Implicit((Object)(object)((QuestVolatileBatteryBaseState)self).attachedHealthComponent.body.master.playerCharacterMasterController)) { ItemLossMessage obj = new ItemLossMessage { baseToken = "ITEM_LOSS_LOST", pickupIndexOnlyOneItem = new PickupIndex(Equipment.QuestVolatileBattery.equipmentIndex) }; ((SubjectChatMessage)obj).subjectAsCharacterBody = ((QuestVolatileBatteryBaseState)self).attachedHealthComponent.body; Networker.SendWQoLMessage((ChatMessageBase)(object)obj); } } private static void ScrappingMessage(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown //IL_003d: Unknown result type (might be due to invalid IL or missing references) ILCursor val = new ILCursor(il); if (val.TryGotoNext((MoveType)0, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchLdfld(x, "RoR2.Inventory/ItemTransformation/TryTransformResult", "takenItem") })) { val.Emit(OpCodes.Ldarg_0); val.EmitDelegate>((Func)delegate(TryTransformResult tryTransformResult, ScrapperController self) { //IL_0082: Unknown result type (might be due to invalid IL or missing references) //IL_0083: Unknown result type (might be due to invalid IL or missing references) //IL_0086: 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_005e: Unknown result type (might be due to invalid IL or missing references) //IL_0063: Unknown result type (might be due to invalid IL or missing references) //IL_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) if (Object.op_Implicit((Object)(object)self.interactor)) { CharacterBody component = ((Component)self.interactor).GetComponent(); if (Object.op_Implicit((Object)(object)component) && Object.op_Implicit((Object)(object)component.inventory)) { ItemLossMessage obj = new ItemLossMessage { source = ItemLossMessage.Source.Scrapper, baseToken = "ITEM_LOSS_SCRAP", itemCount = ((TryTransformResult)(ref tryTransformResult)).totalTransformed, pickupIndexOnlyOneItem = PickupCatalog.FindPickupIndex(tryTransformResult.takenItem.itemIndex) }; ((SubjectChatMessage)obj).subjectAsCharacterBody = component; Networker.SendWQoLMessage((ChatMessageBase)(object)obj); } } return tryTransformResult; }); } else { Log.LogWarning("IL Failed: IL.ScrappingMessage"); } } private static void ItemGiveUpMessages(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown //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) ILCursor val = new ILCursor(il); if (val.TryGotoNext((MoveType)0, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchCallvirt(x, "RoR2.CostTypeDef/PayCostResults", "get_itemStacksTaken") })) { val.Emit(OpCodes.Ldarg_0); val.Emit(OpCodes.Ldarg_1); val.EmitDelegate>((Func)delegate(PayCostResults payResults, PurchaseInteraction purchase, Interactor interactor) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0007: Unknown result type (might be due to invalid IL or missing references) //IL_0034: Unknown result type (might be due to invalid IL or missing references) //IL_003b: Invalid comparison between Unknown and I4 //IL_003e: Unknown result type (might be due to invalid IL or missing references) //IL_0045: Invalid comparison between Unknown and I4 //IL_0048: Unknown result type (might be due to invalid IL or missing references) //IL_004f: Invalid comparison between Unknown and I4 //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_0095: 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_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_00c6: Unknown result type (might be due to invalid IL or missing references) //IL_00cb: Unknown result type (might be due to invalid IL or missing references) //IL_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_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_00ea: 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_0193: Unknown result type (might be due to invalid IL or missing references) //IL_0198: Unknown result type (might be due to invalid IL or missing references) //IL_0107: 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_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_01a6: Unknown result type (might be due to invalid IL or missing references) //IL_01ab: Unknown result type (might be due to invalid IL or missing references) //IL_01ae: Unknown result type (might be due to invalid IL or missing references) //IL_01b0: Unknown result type (might be due to invalid IL or missing references) //IL_0155: 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_01cb: Unknown result type (might be due to invalid IL or missing references) //IL_01cd: Unknown result type (might be due to invalid IL or missing references) //IL_01d9: 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) if (payResults.itemStacksTaken.Count > 0 || payResults.equipmentTaken.Count > 0) { string text = ""; bool flag = false; if ((int)purchase.costType == 12 || (int)purchase.costType == 13 || (int)purchase.costType == 11) { flag = true; } ItemLossMessage itemLossMessage = new ItemLossMessage(); ((SubjectChatMessage)itemLossMessage).subjectAsCharacterBody = ((Component)interactor).gameObject.GetComponent(); ItemLossMessage itemLossMessage2 = itemLossMessage; if (payResults.equipmentTaken.Count > 0) { itemLossMessage2.pickupIndexOnlyOneItem = PickupCatalog.FindPickupIndex(payResults.equipmentTaken[0]); } else if (payResults.itemStacksTaken.Count == 1) { ItemDef itemDef = ItemCatalog.GetItemDef(payResults.itemStacksTaken[0].itemIndex); if (payResults.itemStacksTaken[0].stackValues.permanentStacks <= 0 && payResults.itemStacksTaken[0].stackValues.temporaryStacksValue > 0f) { itemLossMessage2.hasTempItems = true; } flag = flag || itemDef.ContainsTag((ItemTag)10) || itemDef.ContainsTag((ItemTag)14); itemLossMessage2.pickupIndexOnlyOneItem = PickupCatalog.FindPickupIndex(itemDef.itemIndex); } else if (payResults.itemStacksTaken.Count > 1) { itemLossMessage2.itemStacks = ItemCatalog.RequestItemStackArray(); foreach (ItemAndStackValues item in payResults.itemStacksTaken) { if (item.stackValues.permanentStacks > 0) { itemLossMessage2.itemStacks[item.itemIndex] += item.stackValues.permanentStacks; } } } if (((Object)((Component)purchase).gameObject).name.StartsWith("LunarCauldron")) { itemLossMessage2.source = ItemLossMessage.Source.LunarCauldron; text = "ITEM_LOSS_CAULDRON"; } else if (!((Object)((Component)purchase).gameObject).name.StartsWith("ShrineCleanse")) { text = ((!flag) ? "ITEM_LOSS_GENERIC" : "ITEM_LOSS_USED"); } else { itemLossMessage2.source = ItemLossMessage.Source.CleansingPool; text = "ITEM_LOSS_CLEANSING"; } ((SubjectChatMessage)itemLossMessage2).baseToken = text; Networker.SendWQoLMessage((ChatMessageBase)(object)itemLossMessage2); } return payResults; }); } else { Log.LogWarning("IL Failed: IL.PurchaseInteraction.OnInteractionBegin"); } } } public class ItemLossMessage : SubjectChatMessage { public enum Source { Default, Scrapper, DroneScrapper, LemurianEgg, LunarCauldron, CleansingPool, MealStation } public Source source; public int itemCount; public bool hasTempItems; public PickupIndex pickupIndexOnlyOneItem = PickupIndex.none; public PickupIndex pickupIndex2Cook = PickupIndex.none; public int[] itemStacks; public override string ConstructChatString() { //IL_013e: Unknown result type (might be due to invalid IL or missing references) //IL_0143: Unknown result type (might be due to invalid IL or missing references) //IL_018f: 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_0156: Unknown result type (might be due to invalid IL or missing references) //IL_0176: Unknown result type (might be due to invalid IL or missing references) //IL_01d4: Unknown result type (might be due to invalid IL or missing references) //IL_01b7: Unknown result type (might be due to invalid IL or missing references) PerPlayerMaster_ExtraStatTracker component = ((Component)((SubjectChatMessage)this).subjectAsNetworkUser.master).GetComponent(); if (source == Source.Scrapper) { component.scrappedItems += itemCount; if (!WConfig.cfgMessageScrap.Value) { return null; } } else if (source == Source.DroneScrapper) { component.scrappedDrones += DroneUpgradeUtils.GetDroneCountFromUpgradeCount(itemCount); if (!WConfig.cfgMessageScrap.Value) { return null; } } else if (source == Source.LemurianEgg) { component.lemuriansHatched++; if (!WConfig.cfgMessageDevotion.Value) { return null; } } else if (!WConfig.cfgMessagePrint.Value) { return null; } if (!WConfig.module_text_chat.Value) { return null; } if (((SubjectChatMessage)this).IsSecondPerson()) { base.baseToken += "_2P"; } string text = ""; if (pickupIndex2Cook != PickupIndex.none) { text += Help.GetColoredName(pickupIndexOnlyOneItem); text += " + "; text += Help.GetColoredName(pickupIndex2Cook); } else if (pickupIndexOnlyOneItem != PickupIndex.none) { if (source == Source.DroneScrapper) { text += Help.GetColoredName(pickupIndexOnlyOneItem, itemCount); } else { text += Help.GetColoredName(pickupIndexOnlyOneItem, 0, hasTempItems); if (itemCount > 1) { text = text + "(" + itemCount + ")"; } } } else { bool flag = false; for (int i = 0; i < itemStacks.Length; i++) { if (itemStacks[i] <= 0) { continue; } if (ItemCatalog.GetItemDef((ItemIndex)i).ContainsTag((ItemTag)10)) { if (flag) { text = ", " + text; } text = ((itemStacks[i] <= 1) ? (Help.GetColoredName((ItemIndex)i) + text) : (itemStacks[i] + "x " + Help.GetColoredName((ItemIndex)i) + text)); } else { if (flag) { text += ", "; } if (itemStacks[i] > 1) { text = text + itemStacks[i] + "x "; } text += Help.GetColoredName((ItemIndex)i); } flag = true; } } return string.Format(Language.GetString(base.baseToken), ((SubjectChatMessage)this).GetSubjectName(), text); } public override void Serialize(NetworkWriter writer) { //IL_0018: Unknown result type (might be due to invalid IL or missing references) //IL_0025: Unknown result type (might be due to invalid IL or missing references) //IL_004b: Unknown result type (might be due to invalid IL or missing references) //IL_0050: Unknown result type (might be due to invalid IL or missing references) ((SubjectChatMessage)this).Serialize(writer); writer.Write(itemCount); NetworkExtensions.Write(writer, pickupIndexOnlyOneItem); NetworkExtensions.Write(writer, pickupIndex2Cook); writer.Write((int)source); writer.Write(hasTempItems); if (pickupIndexOnlyOneItem == PickupIndex.none) { NetworkExtensions.WriteItemStacks(writer, itemStacks); } } public override void Deserialize(NetworkReader reader) { //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_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_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) if (!WQoLMain.NoHostInfo) { ((SubjectChatMessage)this).Deserialize(reader); itemCount = reader.ReadInt32(); pickupIndexOnlyOneItem = NetworkExtensions.ReadPickupIndex(reader); pickupIndex2Cook = NetworkExtensions.ReadPickupIndex(reader); source = (Source)reader.ReadInt32(); hasTempItems = reader.ReadBoolean(); if (pickupIndexOnlyOneItem == PickupIndex.none) { itemStacks = ItemCatalog.RequestItemStackArray(); NetworkExtensions.ReadItemStacks(reader, itemStacks); } } } } public class StoreLatestPickupindex : MonoBehaviour { public PickupIndex previousIndex; } public static class MoreMessages { [CompilerGenerated] private static class <>O { public static hook_OnPlayerCharacterDeath <0>__OnDeathMessage; public static Action <1>__WinMessage_Client; public static hook_PushItemTransformNotification <2>__TransformItem_Messages; public static hook_PushEquipmentTransformNotification <3>__TransformEquipment_Messages; public static Manipulator <4>__SendAllTransformsLol; public static hook_FireRecycle <5>__RecylerMessage_Host; public static hook_OnDeserialize <6>__RecylerMessage_Client; public static hook_BeginCookingServer <7>__MealPrepController_BeginCookingServer; public static hook_OnEnter <8>__WaitToBeginCooking_OnEnter; } public static ItemIndex VanillaVoids_WatchBrokeItem = (ItemIndex)(-3); public static void Start() { //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_0039: Expected O, but got Unknown //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: Expected O, but got Unknown //IL_009d: Unknown result type (might be due to invalid IL or missing references) //IL_00a2: Unknown result type (might be due to invalid IL or missing references) //IL_00a8: Expected O, but got Unknown //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_00c9: Expected O, but got Unknown //IL_00df: Unknown result type (might be due to invalid IL or missing references) //IL_00e4: Unknown result type (might be due to invalid IL or missing references) //IL_00ea: Expected O, but got Unknown //IL_0100: Unknown result type (might be due to invalid IL or missing references) //IL_0105: Unknown result type (might be due to invalid IL or missing references) //IL_010b: Expected O, but got Unknown //IL_0121: 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_012c: Expected O, but got Unknown //IL_0142: 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_014d: Expected O, but got Unknown ItemLoss_Host.Start(); if (WConfig.module_text_chat.Value) { object obj = <>O.<0>__OnDeathMessage; if (obj == null) { hook_OnPlayerCharacterDeath val = DeathMessage.OnDeathMessage; <>O.<0>__OnDeathMessage = val; obj = (object)val; } GlobalEventManager.OnPlayerCharacterDeath += (hook_OnPlayerCharacterDeath)obj; DevotionLoss.Start(); DroneMessages.Start(); Run.onClientGameOverGlobal += WinMessage_Client; object obj2 = <>O.<2>__TransformItem_Messages; if (obj2 == null) { hook_PushItemTransformNotification val2 = TransformItem_Messages; <>O.<2>__TransformItem_Messages = val2; obj2 = (object)val2; } CharacterMasterNotificationQueue.PushItemTransformNotification += (hook_PushItemTransformNotification)obj2; object obj3 = <>O.<3>__TransformEquipment_Messages; if (obj3 == null) { hook_PushEquipmentTransformNotification val3 = TransformEquipment_Messages; <>O.<3>__TransformEquipment_Messages = val3; obj3 = (object)val3; } CharacterMasterNotificationQueue.PushEquipmentTransformNotification += (hook_PushEquipmentTransformNotification)obj3; object obj4 = <>O.<4>__SendAllTransformsLol; if (obj4 == null) { Manipulator val4 = SendAllTransformsLol; <>O.<4>__SendAllTransformsLol = val4; obj4 = (object)val4; } CharacterMasterNotificationQueue.HandleTransformNotification += (Manipulator)obj4; object obj5 = <>O.<5>__RecylerMessage_Host; if (obj5 == null) { hook_FireRecycle val5 = RecylerMessage_Host; <>O.<5>__RecylerMessage_Host = val5; obj5 = (object)val5; } EquipmentSlot.FireRecycle += (hook_FireRecycle)obj5; object obj6 = <>O.<6>__RecylerMessage_Client; if (obj6 == null) { hook_OnDeserialize val6 = RecylerMessage_Client; <>O.<6>__RecylerMessage_Client = val6; obj6 = (object)val6; } GenericPickupController.OnDeserialize += (hook_OnDeserialize)obj6; object obj7 = <>O.<7>__MealPrepController_BeginCookingServer; if (obj7 == null) { hook_BeginCookingServer val7 = MealPrepController_BeginCookingServer; <>O.<7>__MealPrepController_BeginCookingServer = val7; obj7 = (object)val7; } MealPrepController.BeginCookingServer += (hook_BeginCookingServer)obj7; object obj8 = <>O.<8>__WaitToBeginCooking_OnEnter; if (obj8 == null) { hook_OnEnter val8 = WaitToBeginCooking_OnEnter; <>O.<8>__WaitToBeginCooking_OnEnter = val8; obj8 = (object)val8; } WaitToBeginCooking.OnEnter += (hook_OnEnter)obj8; } } private static void WaitToBeginCooking_OnEnter(orig_OnEnter orig, WaitToBeginCooking self) { orig.Invoke(self); if (!WQoLMain.HostHasMod) { PlayerItemLoss_ClientListener.token = "MEALPREP_COOKMEAL"; PlayerItemLoss_ClientListener.source = ItemLossMessage.Source.MealStation; ItemLossBase_ClientListener.TryMessage(); } } private static void MealPrepController_BeginCookingServer(orig_BeginCookingServer orig, MealPrepController self, Interactor activator, PickupIndex[] itemsToTake, PickupIndex reward, int count) { //IL_0005: Unknown result type (might be due to invalid IL or missing references) //IL_0022: Unknown result type (might be due to invalid IL or missing references) //IL_0027: Unknown result type (might be due to invalid IL or missing references) //IL_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) orig.Invoke(self, activator, itemsToTake, reward, count); ItemLossMessage obj = new ItemLossMessage { baseToken = "MEALPREP_COOKMEAL", pickupIndexOnlyOneItem = itemsToTake[0], pickupIndex2Cook = itemsToTake[1], source = ItemLossMessage.Source.MealStation }; ((SubjectChatMessage)obj).subjectAsCharacterBody = ((Component)activator).GetComponent(); Networker.SendWQoLMessage((ChatMessageBase)(object)obj); } private static void PressurePlateController_SetSwitch(orig_SetSwitch orig, PressurePlateController self, bool switchIsDown) { orig.Invoke(self, switchIsDown); } private static void RecylerMessage_Client(orig_OnDeserialize orig, GenericPickupController self, NetworkReader reader, bool initialState) { //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_001e: 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_002b: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_005d: 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_0065: Unknown result type (might be due to invalid IL or missing references) //IL_006a: Unknown result type (might be due to invalid IL or missing references) //IL_006f: 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_00b7: Unknown result type (might be due to invalid IL or missing references) //IL_00df: Unknown result type (might be due to invalid IL or missing references) //IL_00e4: Unknown result type (might be due to invalid IL or missing references) //IL_0100: Unknown result type (might be due to invalid IL or missing references) //IL_0105: Unknown result type (might be due to invalid IL or missing references) //IL_010c: Unknown result type (might be due to invalid IL or missing references) //IL_0111: Unknown result type (might be due to invalid IL or missing references) //IL_0116: Unknown result type (might be due to invalid IL or missing references) bool recycled = self.Recycled; PickupIndex pickupIndex = self.pickup.pickupIndex; orig.Invoke(self, reader, initialState); bool flag = pickupIndex != PickupIndex.none && pickupIndex != self.pickup.pickupIndex; bool flag2 = !recycled && self.Recycled; if (flag2 && flag) { Chat.AddMessage((ChatMessageBase)(object)new RecycleMessage { oldPickup = pickupIndex, newPickup = self.pickup.pickupIndex }); } else if (flag) { StoreLatestPickupindex storeLatestPickupindex = ((Component)self).gameObject.GetComponent(); if (!Object.op_Implicit((Object)(object)storeLatestPickupindex)) { storeLatestPickupindex = ((Component)self).gameObject.AddComponent(); } storeLatestPickupindex.previousIndex = pickupIndex; } else if (flag2) { StoreLatestPickupindex component = ((Component)self).gameObject.GetComponent(); if (Object.op_Implicit((Object)(object)component) && component.previousIndex != PickupIndex.none) { Chat.AddMessage((ChatMessageBase)(object)new RecycleMessage { oldPickup = component.previousIndex, newPickup = self.Network_pickupState.pickupIndex }); } } } private static bool RecylerMessage_Host(orig_FireRecycle orig, EquipmentSlot self) { //IL_0029: 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_003d: 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_004a: Unknown result type (might be due to invalid IL or missing references) //IL_004f: Unknown result type (might be due to invalid IL or missing references) //IL_0054: Unknown result type (might be due to invalid IL or missing references) GenericPickupController pickupController = self.currentTarget.pickupController; if (!Object.op_Implicit((Object)(object)pickupController) || pickupController.Recycled) { return false; } UniquePickup pickup = pickupController.pickup; bool result = orig.Invoke(self); Chat.AddMessage((ChatMessageBase)(object)new RecycleMessage { oldPickup = pickup.pickupIndex, newPickup = pickupController.pickup.pickupIndex, isTemp = ((UniquePickup)(ref pickup)).isTempItem }); return result; } private static void Interactor_RpcInteractionResult(orig_RpcInteractionResult orig, Interactor self, bool anyInteractionSucceeded) { orig.Invoke(self, anyInteractionSucceeded); if (anyInteractionSucceeded) { InteractionDriver component = ((Component)self).GetComponent(); } } private static void SendAllTransformsLol(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown ILCursor val = new ILCursor(il); if (val.TryGotoNext((MoveType)2, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchCallvirt(x, "UnityEngine.Networking.NetworkBehaviour", "get_hasAuthority") })) { val.EmitDelegate>((Func)((bool t) => true)); } else { Log.LogWarning("IL Failed : AttemptToFixClients"); } } private static void WinMessage_Client(Run self, RunReport runReport) { if ((Object)(object)runReport.gameEnding == (Object)(object)GameEndings.StandardLoss) { return; } if ((Object)(object)runReport.gameEnding == (Object)(object)GameEndings.RebirthEndingDef) { if (NetworkServer.active) { ((MonoBehaviour)self).StartCoroutine(Courtines.Delayed_RebirthMessage(runReport.playerInfos[0].networkUser, 0.1f)); } else { ((MonoBehaviour)self).StartCoroutine(Courtines.Delayed_RebirthMessage(runReport.playerInfos[0].networkUser, 0.5f)); } } else { for (int i = 0; runReport.playerInfos.Length > i; i++) { WinMessageMethod(runReport.gameEnding, runReport.playerInfos[i]); } } } private static void WinMessageMethod(GameEndingDef gameEnd, PlayerInfo playerInfo) { //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0032: Unknown result type (might be due to invalid IL or missing references) if (playerInfo == null) { return; } bool flag = false; string text = ""; string text2 = ""; string text3 = "GENERIC_OUTRO_FLAVOR"; string text4 = "GENERIC_MAIN_ENDING_ESCAPE_FAILURE_FLAVOR"; SurvivorDef survivorDef = SurvivorCatalog.GetSurvivorDef(SurvivorCatalog.GetSurvivorIndexFromBodyIndex(playerInfo.bodyIndex)); if (Object.op_Implicit((Object)(object)survivorDef)) { if (survivorDef.outroFlavorToken != null) { text3 = survivorDef.outroFlavorToken; } if (survivorDef.mainEndingEscapeFailureFlavorToken != null) { text4 = survivorDef.mainEndingEscapeFailureFlavorToken; } } if ((Object)(object)gameEnd == (Object)(object)GameEndings.MainEnding) { flag = true; if (playerInfo.isDead) { text2 = text4; text = "WIN_FORMAT_FAIL"; } else { text2 = text3; text = "WIN_FORMAT_WIN"; } } else if ((Object)(object)gameEnd == (Object)(object)GameEndings.EscapeSequenceFailed) { flag = true; text2 = text4; text = "WIN_FORMAT_FAIL"; } else if (((Object)(object)gameEnd == (Object)(object)GameEndings.LimboEnding) | ((Object)(object)gameEnd == (Object)(object)GameEndings.ObliterationEnding)) { flag = true; text2 = text4; text = "WIN_FORMAT_MS"; } else if ((Object)(object)gameEnd == (Object)(object)GameEndings.VoidEnding) { flag = true; text2 = text4; text = "WIN_FORMAT_VOID"; } if (flag) { playerInfo.finalMessageToken = text2; Chat.AddMessage(" " + string.Format(Language.GetString(text), Language.GetString(text2))); } } private static void TransformItem_Messages(orig_PushItemTransformNotification orig, CharacterMaster characterMaster, ItemIndex oldIndex, ItemIndex newIndex, TransformationType transformationType) { //IL_0003: Unknown result type (might be due to invalid IL or missing references) //IL_0004: 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) //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_0036: Invalid comparison between Unknown and I4 //IL_01be: Unknown result type (might be due to invalid IL or missing references) //IL_01c1: Invalid comparison between Unknown and I4 //IL_024c: Unknown result type (might be due to invalid IL or missing references) //IL_024f: Invalid comparison between Unknown and I4 //IL_0051: 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_006e: 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_01e9: Unknown result type (might be due to invalid IL or missing references) //IL_01ea: Unknown result type (might be due to invalid IL or missing references) //IL_01ef: Unknown result type (might be due to invalid IL or missing references) //IL_01f8: Unknown result type (might be due to invalid IL or missing references) //IL_0204: Unknown result type (might be due to invalid IL or missing references) //IL_027b: Unknown result type (might be due to invalid IL or missing references) //IL_0281: Invalid comparison between Unknown and I4 //IL_028f: Unknown result type (might be due to invalid IL or missing references) //IL_0290: Unknown result type (might be due to invalid IL or missing references) //IL_0295: Unknown result type (might be due to invalid IL or missing references) //IL_029e: Unknown result type (might be due to invalid IL or missing references) //IL_02aa: Unknown result type (might be due to invalid IL or missing references) //IL_02ab: Unknown result type (might be due to invalid IL or missing references) //IL_02b0: Unknown result type (might be due to invalid IL or missing references) //IL_02b9: Unknown result type (might be due to invalid IL or missing references) //IL_02c5: Unknown result type (might be due to invalid IL or missing references) //IL_02fe: 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_0142: 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_0179: 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) orig.Invoke(characterMaster, oldIndex, newIndex, transformationType); if (!Object.op_Implicit((Object)(object)characterMaster.playerCharacterMasterController)) { return; } string bestMasterName = Util.GetBestMasterName(characterMaster); ItemDef itemDef = ItemCatalog.GetItemDef(newIndex); PickupIndex val; if ((int)transformationType == 0) { if (WConfig.cfgMessagesRevive.Value) { if (QualitySupport.PreBaseItemIndex(newIndex, Items.ExtraLifeConsumed)) { Chat.AddMessage(string.Format(Language.GetString("ITEM_REVIVE_MESSAGE"), bestMasterName, Language.GetString(ItemCatalog.GetItemDef(oldIndex).nameToken))); } else if (QualitySupport.PreBaseItemIndex(newIndex, Items.ExtraLifeVoidConsumed)) { Chat.AddMessage(string.Format(Language.GetString("ITEM_REVIVE_MESSAGE"), bestMasterName, Language.GetString(ItemCatalog.GetItemDef(oldIndex).nameToken))); } } if (WConfig.cfgMessageElixirWatch.Value == WConfig.MessageWho.Anybody || (WConfig.cfgMessageElixirWatch.Value == WConfig.MessageWho.Your && ((NetworkBehaviour)characterMaster).hasAuthority)) { string text = (((NetworkBehaviour)characterMaster).hasAuthority ? "" : "_3P"); if (QualitySupport.PreBaseItemIndex(newIndex, Items.HealingPotionConsumed)) { Chat.AddMessage(Language.GetStringFormatted("ITEM_USE_ELIXIR" + text, new object[1] { bestMasterName })); } else if (QualitySupport.PreBaseItemIndex(newIndex, Items.FragileDamageBonusConsumed)) { Chat.AddMessage(Language.GetStringFormatted("ITEM_USE_WATCH" + text, new object[1] { bestMasterName })); } else if (newIndex == VanillaVoids_WatchBrokeItem) { string stringFormatted = Language.GetStringFormatted("ITEM_USE_VV_VOIDWATCH" + text, new object[2] { Help.GetColoredName(oldIndex), bestMasterName }); Chat.AddMessage(stringFormatted); } } } else if ((int)transformationType == 4) { if (WConfig.cfgMessageVoidTransform.Value && ((NetworkBehaviour)characterMaster).hasAuthority) { val = PickupCatalog.FindPickupIndex(oldIndex); string arg = ColorUtility.ToHtmlStringRGB(((PickupIndex)(ref val)).pickupDef.baseColor); string @string = Language.GetString(ItemCatalog.GetItemDef(oldIndex).nameToken); string string2 = Language.GetString("ITEM_LUNARSUN_NAME"); string string3 = Language.GetString("ITEM_TRANSFORM_EGO"); string text2 = string.Format(string3, string2, arg, @string); Chat.AddMessage(text2); } } else if ((int)transformationType == 2 && WConfig.cfgMessageVoidTransform.Value && ((NetworkBehaviour)characterMaster).hasAuthority && (int)itemDef.tier != 5) { val = PickupCatalog.FindPickupIndex(oldIndex); string text3 = ColorUtility.ToHtmlStringRGB(((PickupIndex)(ref val)).pickupDef.baseColor); val = PickupCatalog.FindPickupIndex(newIndex); string text4 = ColorUtility.ToHtmlStringRGB(((PickupIndex)(ref val)).pickupDef.baseColor); string text5 = Language.GetString(ItemCatalog.GetItemDef(oldIndex).nameToken) + ""; string text6 = Language.GetString(itemDef.nameToken) + ""; int itemCount = characterMaster.inventory.GetItemCount(newIndex); if (itemCount > 1) { text6 = text6 + "(" + itemCount + ")"; } string string4 = Language.GetString("ITEM_TRANSFORM_VOID"); string chatMessage = string.Format(string4, text3, text5, text4, text6); ((MonoBehaviour)characterMaster).StartCoroutine(Courtines.Delayed_ChatAddMessage(chatMessage, 1.1f)); } } private static void TransformEquipment_Messages(orig_PushEquipmentTransformNotification orig, CharacterMaster characterMaster, EquipmentIndex oldIndex, EquipmentIndex newIndex, TransformationType transformationType) { //IL_0003: Unknown result type (might be due to invalid IL or missing references) //IL_0004: 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) //IL_0033: Unknown result type (might be due to invalid IL or missing references) //IL_0036: Invalid comparison between Unknown and I4 //IL_004f: Unknown result type (might be due to invalid IL or missing references) //IL_0055: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(characterMaster, oldIndex, newIndex, transformationType); bool flag = Object.op_Implicit((Object)(object)((Component)characterMaster).GetComponent()); if (!(Object.op_Implicit((Object)(object)characterMaster.playerCharacterMasterController) || flag)) { return; } if ((int)transformationType == 0 && WConfig.cfgMessagesRevive.Value && newIndex == Equipment.HealAndReviveConsumed.equipmentIndex) { string bestMasterName = Util.GetBestMasterName(characterMaster); if (characterMaster.lostBodyToDeath) { Chat.AddMessage(string.Format(Language.GetString("ITEM_REVIVE_MESSAGE"), bestMasterName, Language.GetString("EQUIPMENT_HEALANDREVIVE_NAME"))); } else { Chat.AddMessage(string.Format(Language.GetString("ITEM_REVIVE_MESSAGE_TEAM"), bestMasterName, Language.GetString("EQUIPMENT_HEALANDREVIVE_NAME"))); } } if (((NetworkBehaviour)characterMaster).hasAuthority) { } } } public static class OptionsInChat { [CompilerGenerated] private static class <>O { public static hook_SetOptionsInternal <0>__ChoicesInName; public static hook_RemovePickupButtonAvailability <1>__UpdateFragmentText; public static hook_RpcHandlePickupSelected <2>__PickupPickerController_RpcHandlePickupSelected; } public static void Start() { //IL_0011: 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_001c: Expected O, but got Unknown //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Unknown result type (might be due to invalid IL or missing references) //IL_003d: Expected O, but got Unknown //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_005e: Expected O, but got Unknown object obj = <>O.<0>__ChoicesInName; if (obj == null) { hook_SetOptionsInternal val = ChoicesInName; <>O.<0>__ChoicesInName = val; obj = (object)val; } PickupPickerController.SetOptionsInternal += (hook_SetOptionsInternal)obj; object obj2 = <>O.<1>__UpdateFragmentText; if (obj2 == null) { hook_RemovePickupButtonAvailability val2 = UpdateFragmentText; <>O.<1>__UpdateFragmentText = val2; obj2 = (object)val2; } PickupPickerPanel.RemovePickupButtonAvailability += (hook_RemovePickupButtonAvailability)obj2; object obj3 = <>O.<2>__PickupPickerController_RpcHandlePickupSelected; if (obj3 == null) { hook_RpcHandlePickupSelected val3 = PickupPickerController_RpcHandlePickupSelected; <>O.<2>__PickupPickerController_RpcHandlePickupSelected = val3; obj3 = (object)val3; } PickupPickerController.RpcHandlePickupSelected += (hook_RpcHandlePickupSelected)obj3; } private static void PickupPickerController_RpcHandlePickupSelected(orig_RpcHandlePickupSelected orig, PickupPickerController self, int choiceIndex) { orig.Invoke(self, choiceIndex); if (((Object)self).name.StartsWith("Fragment")) { OptionsInPing(self, "AURELIONITE_FRAGMENT_PICKUP_NAME"); } } private static void UpdateFragmentText(orig_RemovePickupButtonAvailability orig, PickupPickerPanel self, int pickupOption) { orig.Invoke(self, pickupOption); if (((Object)self).name.StartsWith("Fragment")) { OptionsInPing(self.pickerController, "AURELIONITE_FRAGMENT_PICKUP_NAME"); } } public static void OptionsInPing(PickupPickerController self, string baseToken) { //IL_0034: Unknown result type (might be due to invalid IL or missing references) //IL_0039: Unknown result type (might be due to invalid IL or missing references) //IL_0046: Unknown result type (might be due to invalid IL or missing references) //IL_004c: Invalid comparison between Unknown and I4 //IL_0074: Unknown result type (might be due to invalid IL or missing references) //IL_007a: Invalid comparison between Unknown and I4 //IL_005a: Unknown result type (might be due to invalid IL or missing references) //IL_0088: Unknown result type (might be due to invalid IL or missing references) //IL_00b8: Unknown result type (might be due to invalid IL or missing references) string @string = Language.GetString(baseToken); @string += "\n("; for (int i = 0; i < self.options.Length; i++) { string text = ""; string text2 = "636363"; PickupIndex pickupIndex = ((Option)(ref self.options[i])).pickupIndex; PickupDef pickupDef = ((PickupIndex)(ref pickupIndex)).pickupDef; if ((int)pickupDef.itemIndex != -1) { text = Language.GetString(ItemCatalog.GetItemDef(pickupDef.itemIndex).nameToken); } else if ((int)pickupDef.equipmentIndex != -1) { text = Language.GetString(EquipmentCatalog.GetEquipmentDef(pickupDef.equipmentIndex).nameToken); } if (self.options[i].available) { text2 = ColorUtility.ToHtmlStringRGB(pickupDef.baseColor); } else { text = "" + text + ""; } @string = ((i == 0) ? (@string + "" + text + "") : (@string + " | " + text + "")); } @string += ")"; ((Component)self).GetComponent().SetDisplayToken(@string); } private static void ChoicesInName(orig_SetOptionsInternal orig, PickupPickerController self, Option[] newOptions) { orig.Invoke(self, newOptions); PickupIndexNetworker component = ((Component)self).GetComponent(); bool flag = ((Object)self).name.StartsWith("Option"); if (((Object)self).name.StartsWith("Fragment") && WConfig.cfgAurFragment_ItemsInPing.Value) { OptionsInPing(self, "AURELIONITE_FRAGMENT_PICKUP_NAME"); } if (flag && WConfig.cfgVoidPotential_ItemsInPing.Value) { if (WConfig.cfgVoidPotential_ItemsInPing.Value) { OptionsInPing(self, "OPTION_PICKUP_UNKNOWN_NAME"); } else { ((Component)self).GetComponent().SetDisplayToken("OPTION_PICKUP_UNKNOWN_NAME"); } } } } public class InteractableMessage : SubjectChatMessage { public string interactableToken; public override string ConstructChatString() { if (!WConfig.module_text_chat.Value) { return null; } if (!WConfig.cfgMessagesSaleStar.Value) { return null; } base.baseToken = "ITEM_USED_STAR"; return string.Format(Language.GetString(((SubjectChatMessage)this).GetResolvedToken()), ((SubjectChatMessage)this).GetSubjectName(), Language.GetString(interactableToken)); } public override void Serialize(NetworkWriter writer) { ((SubjectChatMessage)this).Serialize(writer); writer.Write(interactableToken); } public override void Deserialize(NetworkReader reader) { if (!WQoLMain.NoHostInfo) { ((SubjectChatMessage)this).Deserialize(reader); interactableToken = reader.ReadString(); } } } public class RecycleMessage : ChatMessageBase { public PickupIndex oldPickup; public PickupIndex newPickup; public bool isTemp; public override string ConstructChatString() { //IL_0030: 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_0049: Unknown result type (might be due to invalid IL or missing references) //IL_0055: Unknown result type (might be due to invalid IL or missing references) //IL_005b: Invalid comparison between Unknown and I4 //IL_008e: Unknown result type (might be due to invalid IL or missing references) //IL_0094: Invalid comparison between Unknown and I4 //IL_0068: 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_00a1: 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) if (!WConfig.cfgMessagesRecycler.Value) { return null; } string text = ""; string text2 = ""; string text3 = ""; PickupDef pickupDef = PickupCatalog.GetPickupDef(oldPickup); PickupDef pickupDef2 = PickupCatalog.GetPickupDef(newPickup); text3 = ColorUtility.ToHtmlStringRGB(pickupDef.baseColor); if ((int)pickupDef.itemIndex != -1) { text = ItemCatalog.GetItemDef(pickupDef.itemIndex).nameToken; text2 = ItemCatalog.GetItemDef(pickupDef2.itemIndex).nameToken; } else if ((int)pickupDef.equipmentIndex != -1) { text = EquipmentCatalog.GetEquipmentDef(pickupDef.equipmentIndex).nameToken; text2 = EquipmentCatalog.GetEquipmentDef(pickupDef2.equipmentIndex).nameToken; } if (isTemp) { text = Language.GetStringFormatted("ITEM_MODIFIER_TEMP", new object[1] { Language.GetString(text) }); text2 = Language.GetStringFormatted("ITEM_MODIFIER_TEMP", new object[1] { Language.GetString(text2) }); } else { text = Language.GetString(text); text2 = Language.GetString(text2); } return string.Format(Language.GetString("ITEM_RECYCLED_GLOBAL"), text, text2, text3); } } public static class EquipmentDrone { [CompilerGenerated] private static class <>O { public static hook_UpdateInfo <0>__AllyCardController_UpdateInfo; } public static void Start() { //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_002c: Expected O, but got Unknown LegacyResourcesAPI.Load("Prefabs/CharacterMasters/EquipmentDroneMaster").AddComponent(); object obj = <>O.<0>__AllyCardController_UpdateInfo; if (obj == null) { hook_UpdateInfo val = AllyCardController_UpdateInfo; <>O.<0>__AllyCardController_UpdateInfo = val; obj = (object)val; } AllyCardController.UpdateInfo += (hook_UpdateInfo)obj; } private static void AllyCardController_UpdateInfo(orig_UpdateInfo orig, AllyCardController self) { orig.Invoke(self); if (Object.op_Implicit((Object)(object)self.sourceMaster)) { EquipmentDroneNameComponent equipmentDroneNameComponent = null; if (((Component)self.sourceMaster).TryGetComponent(ref equipmentDroneNameComponent)) { ((HorizontalOrVerticalLayoutGroup)((Component)((Component)self).transform.GetChild(1)).GetComponent()).spacing = 0f; } } } } public class EquipmentDroneNameComponent : MonoBehaviour { public CharacterMaster master; public CharacterBody body; public Inventory inventory; private bool enigma = false; public bool setName = false; private EquipmentIndex lastEquipmentIndex = (EquipmentIndex)(-1); public void OnEnable() { //IL_0098: Unknown result type (might be due to invalid IL or missing references) //IL_009d: Unknown result type (might be due to invalid IL or missing references) if (RunArtifactManager.instance.IsArtifactEnabled(Artifacts.Enigma)) { enigma = true; } if (WConfig.cfgEquipmentDroneName.Value == WConfig.ColorOrNot.Off) { Object.Destroy((Object)(object)this); return; } master = ((Component)this).GetComponent(); master.onBodyStart += Master_onBodyStart; body = master.GetBody(); inventory = ((Component)this).GetComponent(); inventory.onEquipmentChangedClient += Inventory_onEquipmentChangedClient; lastEquipmentIndex = inventory.currentEquipmentIndex; AssignName(); } public void OnDisable() { if (Object.op_Implicit((Object)(object)master)) { master.onBodyStart -= Master_onBodyStart; } if (Object.op_Implicit((Object)(object)inventory)) { inventory.onEquipmentChangedClient -= Inventory_onEquipmentChangedClient; } } private void Master_onBodyStart(CharacterBody obj) { //IL_000f: Unknown result type (might be due to invalid IL or missing references) //IL_0014: Unknown result type (might be due to invalid IL or missing references) body = obj; lastEquipmentIndex = inventory.currentEquipmentIndex; AssignName(); } private void Inventory_onEquipmentChangedClient(EquipmentIndex arg1, uint arg2) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_000d: Unknown result type (might be due to invalid IL or missing references) //IL_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) if (lastEquipmentIndex != inventory.currentEquipmentIndex) { lastEquipmentIndex = inventory.currentEquipmentIndex; AssignName(); } } public void AssignName() { //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_001b: Invalid comparison between Unknown and I4 //IL_0029: 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_00a5: 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) if (Object.op_Implicit((Object)(object)body) && (int)lastEquipmentIndex != -1) { if (lastEquipmentIndex == Equipment.BossHunterConsumed.equipmentIndex) { body.baseNameToken = "EQUIPMENTDRONE_BODY_NAME"; return; } if (WConfig.cfgEquipmentDroneName.Value == WConfig.ColorOrNot.Colored) { body.baseNameToken = Language.GetString("EQUIPMENTDRONE_BODY_NAME") + "\n(" + Help.GetColoredName(inventory.currentEquipmentIndex) + ")"; return; } EquipmentDef equipmentDef = EquipmentCatalog.GetEquipmentDef(inventory.currentEquipmentIndex); body.baseNameToken = Language.GetString("EQUIPMENTDRONE_BODY_NAME") + "\n(" + Language.GetString(equipmentDef.nameToken) + ")"; } } } public static class LunarSeer { [CompilerGenerated] private static class <>O { public static hook_OnStartClient <0>__SeerStageName_Start; public static hook_OnTargetSceneChanged <1>__SeerStageName_SceneChanged; public static hook_SetRunNextStageToTarget <2>__FancyBazaarPortalChange; } public static void Start() { //IL_0011: 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_001c: Expected O, but got Unknown //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Unknown result type (might be due to invalid IL or missing references) //IL_003d: Expected O, but got Unknown //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_008b: Unknown result type (might be due to invalid IL or missing references) //IL_0090: Unknown result type (might be due to invalid IL or missing references) //IL_00ad: Unknown result type (might be due to invalid IL or missing references) //IL_00b2: Unknown result type (might be due to invalid IL or missing references) //IL_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_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_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_005e: Expected O, but got Unknown object obj = <>O.<0>__SeerStageName_Start; if (obj == null) { hook_OnStartClient val = SeerStageName_Start; <>O.<0>__SeerStageName_Start = val; obj = (object)val; } SeerStationController.OnStartClient += (hook_OnStartClient)obj; object obj2 = <>O.<1>__SeerStageName_SceneChanged; if (obj2 == null) { hook_OnTargetSceneChanged val2 = SeerStageName_SceneChanged; <>O.<1>__SeerStageName_SceneChanged = val2; obj2 = (object)val2; } SeerStationController.OnTargetSceneChanged += (hook_OnTargetSceneChanged)obj2; object obj3 = <>O.<2>__FancyBazaarPortalChange; if (obj3 == null) { hook_SetRunNextStageToTarget val3 = FancyBazaarPortalChange; <>O.<2>__FancyBazaarPortalChange = val3; obj3 = (object)val3; } SeerStationController.SetRunNextStageToTarget += (hook_SetRunNextStageToTarget)obj3; Addressables.LoadAssetAsync((object)"RoR2/Base/bazaar/matBazaarSeerGolemplains.mat").WaitForCompletion().SetFloat("_Boost", 1.5f); Addressables.LoadAssetAsync((object)"RoR2/Base/bazaar/matBazaarSeerGoolake.mat").WaitForCompletion().SetFloat("_Boost", 1.5f); Addressables.LoadAssetAsync((object)"RoR2/DLC1/ancientloft/matBazaarSeerAncientloft.mat").WaitForCompletion().SetFloat("_Boost", 2f); Addressables.LoadAssetAsync((object)"RoR2/DLC2/lemuriantemple/matBazaarSeerLemurianTemple.mat").WaitForCompletion().SetFloat("_Boost", 2.5f); Addressables.LoadAssetAsync((object)"RoR2/DLC2/habitat/matBazaarSeerHabitat.mat").WaitForCompletion().SetFloat("_Boost", 2.5f); } private static void FancyBazaarPortalChange(orig_SetRunNextStageToTarget orig, SeerStationController self) { //IL_0076: 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_03de: Unknown result type (might be due to invalid IL or missing references) //IL_03ee: Unknown result type (might be due to invalid IL or missing references) //IL_03f3: Unknown result type (might be due to invalid IL or missing references) //IL_0422: Unknown result type (might be due to invalid IL or missing references) //IL_0427: Unknown result type (might be due to invalid IL or missing references) //IL_043c: Unknown result type (might be due to invalid IL or missing references) //IL_0441: Unknown result type (might be due to invalid IL or missing references) //IL_0456: Unknown result type (might be due to invalid IL or missing references) //IL_045b: 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_039f: Unknown result type (might be due to invalid IL or missing references) //IL_04d1: Unknown result type (might be due to invalid IL or missing references) //IL_04e1: Unknown result type (might be due to invalid IL or missing references) //IL_04e6: Unknown result type (might be due to invalid IL or missing references) //IL_04f8: Unknown result type (might be due to invalid IL or missing references) //IL_04fd: Unknown result type (might be due to invalid IL or missing references) //IL_0521: Unknown result type (might be due to invalid IL or missing references) //IL_052c: Unknown result type (might be due to invalid IL or missing references) //IL_03b4: Unknown result type (might be due to invalid IL or missing references) //IL_03b9: Unknown result type (might be due to invalid IL or missing references) //IL_0470: Unknown result type (might be due to invalid IL or missing references) //IL_0475: Unknown result type (might be due to invalid IL or missing references) //IL_049a: Unknown result type (might be due to invalid IL or missing references) //IL_04aa: Unknown result type (might be due to invalid IL or missing references) //IL_04af: Unknown result type (might be due to invalid IL or missing references) //IL_0408: Unknown result type (might be due to invalid IL or missing references) //IL_040d: Unknown result type (might be due to invalid IL or missing references) if (Object.op_Implicit((Object)(object)SceneInfo.instance) && SceneInfo.instance.sceneDef.baseSceneName == "bazaar") { GameObject val = GameObject.Find("/PortalShop"); SceneDef sceneDef = SceneCatalog.GetSceneDef((SceneIndex)self.NetworktargetSceneDefIndex); if (Object.op_Implicit((Object)(object)sceneDef) && Object.op_Implicit((Object)(object)val)) { val.transform.localScale = new Vector3(0.7f, 1.26f, 0.7f); val.transform.position = new Vector3(12.88f, -5.53f, -7.34f); GameObject val2 = null; GameObject val3 = null; switch (sceneDef.baseSceneName) { case "goldshores": val2 = Addressables.LoadAssetAsync((object)"RoR2/Base/PortalGoldshores/PortalGoldshores.prefab").WaitForCompletion(); break; case "mysteryspace": case "limbo": val2 = Addressables.LoadAssetAsync((object)"RoR2/Base/PortalMS/PortalMS.prefab").WaitForCompletion(); break; case "artifactworld": case "artifactworld01": case "artifactworld02": case "artifactworld03": val.transform.localPosition = new Vector3(12.88f, 0f, -7.34f); val2 = Addressables.LoadAssetAsync((object)"RoR2/Base/PortalArtifactworld/PortalArtifactworld.prefab").WaitForCompletion(); break; case "arena": val2 = Addressables.LoadAssetAsync((object)"RoR2/Base/PortalArena/PortalArena.prefab").WaitForCompletion(); break; case "voidstage": val2 = Addressables.LoadAssetAsync((object)"RoR2/DLC1/PortalVoid/PortalVoid.prefab").WaitForCompletion(); break; case "voidraid": val2 = Addressables.LoadAssetAsync((object)"RoR2/DLC1/DeepVoidPortal/DeepVoidPortal.prefab").WaitForCompletion(); break; case "lemuriantemple": case "habitat": case "habitatfall": case "meridian": val2 = Addressables.LoadAssetAsync((object)"RoR2/DLC2/PortalColossus.prefab").WaitForCompletion(); break; case "conduitcanyon": case "solutionalhaunt": val2 = Addressables.LoadAssetAsync((object)"RoR2/DLC3/HardwareProgPortal.prefab").WaitForCompletion(); break; case "computationalexchange": val.transform.localPosition = new Vector3(12.88f, 0f, -7.34f); val2 = Addressables.LoadAssetAsync((object)"RoR2/DLC3/CompExchangePortal.prefab").WaitForCompletion(); break; case "solusweb": val.transform.localPosition = new Vector3(12.88f, 0f, -7.34f); val2 = Addressables.LoadAssetAsync((object)"RoR2/DLC3/SolusWebPortal.prefab").WaitForCompletion(); break; default: val2 = Addressables.LoadAssetAsync((object)"RoR2/Base/PortalShop/PortalShop.prefab").WaitForCompletion(); break; } if ((Object)(object)val2 != (Object)null) { val3 = Object.Instantiate(val2, val.transform.position, val.transform.rotation); NetworkServer.Spawn(val3); val3.GetComponent().destinationScene = sceneDef; val3.GetComponent().useRunNextStageScene = false; ((Object)val3).name = ((Object)val).name; Object.Destroy((Object)(object)val); } } } orig.Invoke(self); } private static void SeerStageName_SceneChanged(orig_OnTargetSceneChanged orig, SeerStationController self, SceneDef targetScene) { //IL_0031: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self, targetScene); if (WConfig.cfgLunarSeerName.Value && (Object)(object)targetScene != (Object)null) { SeerName(((Component)self).gameObject, targetScene.sceneDefIndex); } } public static void SeerName(GameObject self, SceneIndex index) { //IL_000f: Unknown result type (might be due to invalid IL or missing references) PurchaseTokenOverwrite purchaseTokenOverwrite = UnityObjectExtensions.EnsureComponent(self); purchaseTokenOverwrite.checkForLang = false; string @string = Language.GetString(SceneCatalog.GetSceneDef(index).nameToken); @string = @string.Replace("Hidden Realm: ", ""); purchaseTokenOverwrite.contextToken = Language.GetString("BAZAAR_SEER_CONTEXT") + " of " + @string; purchaseTokenOverwrite.displayNameToken = Language.GetString("BAZAAR_SEER_NAME") + " (" + @string + ")"; } private static void SeerStageName_Start(orig_OnStartClient orig, SeerStationController self) { orig.Invoke(self); if (WConfig.cfgLunarSeerName.Value && self.NetworktargetSceneDefIndex != -1) { SeerName(((Component)self).gameObject, (SceneIndex)self.NetworktargetSceneDefIndex); } } } public static class PrayerBeads { [CompilerGenerated] private static class <>O { public static hook_SetItemIndex_ItemIndex_int_float <0>__Consumed_OverrideTooltip; public static hook_ItemClicked <1>__Consumed_OverrideInspect; public static hook_SetItem <2>__GenericNotification_SetItem; public static hook_OnBeadReset <3>__OverlayForTransformationMessage; } public static LanguageOverlay BeadsOverlay_Pickup; public static LanguageOverlay BeadsOverlay_Desc; public static ItemIndex moffeine = (ItemIndex)(-2); public static ItemIndex usedBeads = (ItemIndex)(-2); public static bool justRemovedBeadsLocal = false; internal static void SetDescription(ItemIcon self) { ItemInventoryDisplay componentInParent = ((Component)self).GetComponentInParent(); if (Object.op_Implicit((Object)(object)componentInParent) && Object.op_Implicit((Object)(object)componentInParent.inventory)) { self.tooltipProvider.overrideBodyText = GetPrayerBeadsToken(componentInParent.inventory, ((Component)componentInParent.inventory).GetComponent().bodyPrefab.GetComponent(), "OVERLAY_EXTRASTATSONLEVELUP_CONSUMED_DESC"); } } private static void Consumed_OverrideInspect(orig_ItemClicked orig, ItemIcon self) { //IL_000a: Unknown result type (might be due to invalid IL or missing references) //IL_000f: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self); if (self.itemIndex == usedBeads && self.userProfile.useInspectFeature) { ItemInventoryDisplay componentInParent = ((Component)self).GetComponentInParent(); if (Object.op_Implicit((Object)(object)componentInParent) && Object.op_Implicit((Object)(object)componentInParent.inventory)) { self.inspectPanel.InspectDescription.token = GetPrayerBeadsToken(componentInParent.inventory, ((Component)componentInParent.inventory).GetComponent().bodyPrefab.GetComponent(), "OVERLAY_EXTRASTATSONLEVELUP_CONSUMED_DESC"); } } } public static void Start() { //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_006c: Expected O, but got Unknown //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: Expected O, but got Unknown //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_0047: Expected O, but got Unknown //IL_0083: Unknown result type (might be due to invalid IL or missing references) //IL_0088: Unknown result type (might be due to invalid IL or missing references) //IL_008e: Expected O, but got Unknown if (WQoLMain.ServerModInstalled) { object obj = <>O.<0>__Consumed_OverrideTooltip; if (obj == null) { hook_SetItemIndex_ItemIndex_int_float val = Consumed_OverrideTooltip; <>O.<0>__Consumed_OverrideTooltip = val; obj = (object)val; } ItemIcon.SetItemIndex_ItemIndex_int_float += (hook_SetItemIndex_ItemIndex_int_float)obj; object obj2 = <>O.<1>__Consumed_OverrideInspect; if (obj2 == null) { hook_ItemClicked val2 = Consumed_OverrideInspect; <>O.<1>__Consumed_OverrideInspect = val2; obj2 = (object)val2; } ItemIcon.ItemClicked += (hook_ItemClicked)obj2; } else { object obj3 = <>O.<2>__GenericNotification_SetItem; if (obj3 == null) { hook_SetItem val3 = GenericNotification_SetItem; <>O.<2>__GenericNotification_SetItem = val3; obj3 = (object)val3; } GenericNotification.SetItem += (hook_SetItem)obj3; } object obj4 = <>O.<3>__OverlayForTransformationMessage; if (obj4 == null) { hook_OnBeadReset val4 = OverlayForTransformationMessage; <>O.<3>__OverlayForTransformationMessage = val4; obj4 = (object)val4; } CharacterMaster.OnBeadReset += (hook_OnBeadReset)obj4; } private static void Consumed_OverrideTooltip(orig_SetItemIndex_ItemIndex_int_float orig, ItemIcon self, ItemIndex newItemIndex, int newItemCount, float newDurationPercent) { //IL_0003: Unknown result type (might be due to invalid IL or missing references) //IL_000d: Unknown result type (might be due to invalid IL or missing references) //IL_000e: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self, newItemIndex, newItemCount, newDurationPercent); if (newItemIndex == usedBeads) { SetDescription(self); } } private static void GenericNotification_SetItem(orig_SetItem orig, GenericNotification self, ItemDef itemDef) { //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_0087: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self, itemDef); if (justRemovedBeadsLocal && (Object)(object)itemDef == (Object)(object)Items.ExtraStatsOnLevelUp) { justRemovedBeadsLocal = false; self.titleText.token = itemDef.nameToken; self.descriptionText.token = Language.GetString("BEADS_TEMP_"); if ((Object)(object)itemDef.pickupIconTexture != (Object)null) { ((Component)self.iconImage).gameObject.SetActive(false); } ((Graphic)self.titleTMP).color = Color32.op_Implicit(ColorCatalog.GetColor(itemDef.colorIndex)); } } private static void OverlayForTransformationMessage(orig_OnBeadReset orig, CharacterMaster self, bool gainedStats) { CharacterBody body = self.GetBody(); if (Object.op_Implicit((Object)(object)body) && gainedStats) { PrayerBeads_Ovelay(self.inventory, self, body); } orig.Invoke(self, gainedStats); } public static string GetPrayerBeadsToken(Inventory inventory, CharacterBody body, string tokenIn) { //IL_0040: Unknown result type (might be due to invalid IL or missing references) //IL_0046: Invalid comparison between Unknown and I4 //IL_0053: Unknown result type (might be due to invalid IL or missing references) if ((Object)(object)body == (Object)null) { body = ((Component)inventory).GetComponent().bodyPrefab.GetComponent(); } float num = inventory.beadAppliedDamage; float num2 = inventory.beadAppliedHealth; float num3 = inventory.beadAppliedRegen; float num4 = num / body.levelDamage; if ((int)moffeine != -1) { float num5 = inventory.GetItemCount(moffeine); num4 = num5 / 5f; num5 *= 0.05f; num = body.levelDamage * num5; num2 = body.levelMaxHealth * num5; num3 = body.levelRegen * num5; } string text = num4.ToString("0.##"); string text2 = num2.ToString("0.##"); string text3 = num3.ToString("0.##"); string text4 = num.ToString("0.##"); return string.Format(Language.GetString(tokenIn), text, text2, text3, text4); } public static void PrayerBeads_Ovelay(Inventory inventory, CharacterMaster master, CharacterBody body) { //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_00fa: Unknown result type (might be due to invalid IL or missing references) //IL_0101: Expected O, but got Unknown //IL_0106: 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_011b: Expected O, but got Unknown if ((Object)(object)body == (Object)null) { Log.LogMessage("PrayerBeads_Ovelay NullBody"); } else if (((NetworkBehaviour)master).hasAuthority) { if (BeadsOverlay_Pickup != null) { BeadsOverlay_Pickup.Remove(); } if (BeadsOverlay_Desc != null) { BeadsOverlay_Desc.Remove(); } if (WQoLMain.ServerModInstalled) { string prayerBeadsToken = GetPrayerBeadsToken(inventory, body, "OVERLAY_EXTRASTATSONLEVELUP_CONSUMED_PICKUP"); BeadsOverlay_Pickup = LanguageAPI.AddOverlay("ITEM_EXTRASTATSONLEVELUP_CONSUMED_PICKUP", prayerBeadsToken); BeadsOverlay_Desc = LanguageAPI.AddOverlay("ITEM_EXTRASTATSONLEVELUP_CONSUMED_DESC", prayerBeadsToken); CharacterMasterNotificationQueue.PushItemTransformNotification(master, Items.ExtraStatsOnLevelUp.itemIndex, usedBeads, (TransformationType)0); } else if (!WQoLMain.ServerModInstalled) { justRemovedBeadsLocal = true; string prayerBeadsToken2 = GetPrayerBeadsToken(inventory, body, "OVERLAY_EXTRASTATSONLEVELUP_DESC"); BeadsOverlay_Pickup = LanguageAPI.AddOverlay("BEADS_TEMP_", prayerBeadsToken2); CharacterMasterNotificationQueue notificationQueueForMaster = CharacterMasterNotificationQueue.GetNotificationQueueForMaster(master); TransformationInfo val = new TransformationInfo((TransformationType)0, (object)Items.ExtraStatsOnLevelUp); NotificationInfo val2 = new NotificationInfo((object)ItemCatalog.GetItemDef(Items.ExtraStatsOnLevelUp.itemIndex), val, false, 0); notificationQueueForMaster.PushNotification(val2, 12f); } } } } public static class ShrineShapingMessage { [CompilerGenerated] private static class <>O { public static hook_RpcUpdateInteractionClients <0>__ShrineShapingMessage_Client; public static hook_ReviveAlliedPlayers <1>__ShrineShapingMessage_Host; } public static void Start() { //IL_0011: 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_001c: Expected O, but got Unknown //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Unknown result type (might be due to invalid IL or missing references) //IL_003d: Expected O, but got Unknown object obj = <>O.<0>__ShrineShapingMessage_Client; if (obj == null) { hook_RpcUpdateInteractionClients val = ShrineShapingMessage_Client; <>O.<0>__ShrineShapingMessage_Client = val; obj = (object)val; } ShrineColossusAccessBehavior.RpcUpdateInteractionClients += (hook_RpcUpdateInteractionClients)obj; object obj2 = <>O.<1>__ShrineShapingMessage_Host; if (obj2 == null) { hook_ReviveAlliedPlayers val2 = ShrineShapingMessage_Host; <>O.<1>__ShrineShapingMessage_Host = val2; obj2 = (object)val2; } ShrineColossusAccessBehavior.ReviveAlliedPlayers += (hook_ReviveAlliedPlayers)obj2; } private static void ShrineShapingMessage_Host(orig_ReviveAlliedPlayers orig, ShrineColossusAccessBehavior self) { try { ShrineShaping_Message(); } catch (Exception ex) { Debug.LogError((object)ex); orig.Invoke(self); return; } orig.Invoke(self); } public static string NameOfAllDeadPlayers(out int anyDead) { string text = ""; anyDead = 0; foreach (PlayerCharacterMasterController instance in PlayerCharacterMasterController.instances) { if (instance.master.lostBodyToDeath) { anyDead++; text = text + Util.EscapeRichTextForTextMeshPro(instance.networkUser.userName) + "'s"; } } return text; } public static void ShrineShaping_Message() { if (!WConfig.cfgMessagesShrineRevive.Value) { return; } Chat.AddMessage(Language.GetString("SHRINE_REVIVE_USE_MESSAGE")); List list = new List(); int num = 0; bool flag = false; foreach (PlayerCharacterMasterController instance in PlayerCharacterMasterController.instances) { if (!instance.isConnected) { continue; } CharacterMaster master = instance.master; if (!Object.op_Implicit((Object)(object)master)) { continue; } GameObject bodyObject = master.GetBodyObject(); Log.LogMessage(master.lostBodyToDeath + " " + (object)bodyObject); if (instance.master.lostBodyToDeath || (Object)(object)bodyObject == (Object)null) { if (((NetworkBehaviour)master).hasAuthority) { flag = true; } else { list.Add(Util.EscapeRichTextForTextMeshPro(instance.networkUser.userName)); } num++; } } if (num > 0) { string text = ""; string text2 = ""; for (int i = 0; i < list.Count; i++) { text2 = ((i == 0 && !flag) ? (text2 + list[i]) : ((i + 1 != list.Count) ? (text2 + ", " + list[i]) : (text2 + " & " + list[i]))); } if (num == 1 && flag) { text = "SHRINE_REVIVE_MESSAGE_DEAD_YOU"; text = Language.GetString(text); } else if (flag) { text = "SHRINE_REVIVE_MESSAGE_DEAD_YOUAND"; text = string.Format(Language.GetString(text), text2); } else { text = "SHRINE_REVIVE_MESSAGE_DEAD"; text = string.Format(Language.GetString(text), text2); } Chat.AddMessage(text); } } private static void ShrineShapingMessage_Client(orig_RpcUpdateInteractionClients orig, ShrineColossusAccessBehavior self) { orig.Invoke(self); if (!NetworkServer.active) { ShrineShaping_Message(); } } } public class PurchaseTokenOverwrite : MonoBehaviour { public string displayNameToken; public string contextToken; public bool checkForLang = true; public void OnEnable() { if (checkForLang && !Language.currentLanguage.TokenIsRegistered(displayNameToken)) { Object.Destroy((Object)(object)this); } } } public static class TextChanges { [CompilerGenerated] private static class <>O { public static hook_Start <0>__BlueTeleporterObjective; public static hook_ConstructChatString <1>__AddVoidQuantity; public static hook_GetDisplayName <2>__PurchaseTokenOverwrite_PurchaseInteraction_GetDisplayName; public static Manipulator <3>__PurchaseTokenOverwrite_PurchaseInteraction_GetContextString; public static hook_OnEnter <4>__MithrixPhase2OverrideLunarChimeraHordeName; } public static LanguageOverlay TPLunar1; public static LanguageOverlay TPLunar2; public static LanguageOverlay TPLunar3; public static LanguageOverlay TPLunar4; public static bool LunaredAllOverIt; public static void Main() { //IL_002d: Unknown result type (might be due to invalid IL or missing references) //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0038: Expected O, but got Unknown //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_0090: Expected O, but got Unknown //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_0068: Expected O, but got Unknown //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_00b1: Expected O, but got Unknown EndingText(); if (WConfig.cfgTextOther.Value) { OtherText(); } object obj = <>O.<0>__BlueTeleporterObjective; if (obj == null) { hook_Start val = BlueTeleporterObjective; <>O.<0>__BlueTeleporterObjective = val; obj = (object)val; } TeleporterInteraction.Start += (hook_Start)obj; if (WConfig.cfgMessagesVoidQuantity.Value) { object obj2 = <>O.<1>__AddVoidQuantity; if (obj2 == null) { hook_ConstructChatString val2 = AddVoidQuantity; <>O.<1>__AddVoidQuantity = val2; obj2 = (object)val2; } PlayerPickupChatMessage.ConstructChatString += (hook_ConstructChatString)obj2; } OptionPickup_Visuals.Start(); object obj3 = <>O.<2>__PurchaseTokenOverwrite_PurchaseInteraction_GetDisplayName; if (obj3 == null) { hook_GetDisplayName val3 = PurchaseTokenOverwrite_PurchaseInteraction_GetDisplayName; <>O.<2>__PurchaseTokenOverwrite_PurchaseInteraction_GetDisplayName = val3; obj3 = (object)val3; } PurchaseInteraction.GetDisplayName += (hook_GetDisplayName)obj3; object obj4 = <>O.<3>__PurchaseTokenOverwrite_PurchaseInteraction_GetContextString; if (obj4 == null) { Manipulator val4 = PurchaseTokenOverwrite_PurchaseInteraction_GetContextString; <>O.<3>__PurchaseTokenOverwrite_PurchaseInteraction_GetContextString = val4; obj4 = (object)val4; } PurchaseInteraction.GetContextString += (Manipulator)obj4; } private static string AddVoidQuantity(orig_ConstructChatString orig, PlayerPickupChatMessage self) { //IL_0052: 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_008c: Unknown result type (might be due to invalid IL or missing references) //IL_0092: Invalid comparison between Unknown and I4 //IL_0095: Unknown result type (might be due to invalid IL or missing references) //IL_009c: Invalid comparison between Unknown and I4 //IL_013e: Unknown result type (might be due to invalid IL or missing references) //IL_0143: Unknown result type (might be due to invalid IL or missing references) //IL_0148: Unknown result type (might be due to invalid IL or missing references) //IL_014a: Unknown result type (might be due to invalid IL or missing references) //IL_014d: Invalid comparison between Unknown and I4 //IL_0164: 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_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_00ed: Unknown result type (might be due to invalid IL or missing references) //IL_0106: Unknown result type (might be due to invalid IL or missing references) //IL_0108: Unknown result type (might be due to invalid IL or missing references) if (!Object.op_Implicit((Object)(object)((SubjectChatMessage)self).subjectAsCharacterBody)) { return orig.Invoke(self); } if (!Object.op_Implicit((Object)(object)((SubjectChatMessage)self).subjectAsCharacterBody.inventory)) { return orig.Invoke(self); } PickupDef pickupDef = PickupCatalog.GetPickupDef(GenericPickupController.pickupMessageInstance.pickupState.pickupIndex); ItemDef itemDef = ItemCatalog.GetItemDef((ItemIndex)((pickupDef == null) ? (-1) : ((int)pickupDef.itemIndex))); if (Object.op_Implicit((Object)(object)itemDef)) { int pickupQuantity = (int)self.pickupQuantity; int num = pickupQuantity; if ((int)itemDef.tier >= 6 && (int)itemDef.tier <= 9) { if (((SubjectChatMessage)self).subjectAsCharacterBody.inventory.GetItemCountPermanent(itemDef) <= 1) { TransformationInfo[] transformationInfos = ContagiousItemManager._transformationInfos; foreach (TransformationInfo val in transformationInfos) { if (itemDef.itemIndex == val.transformedItem) { int itemCountEffective = ((SubjectChatMessage)self).subjectAsCharacterBody.inventory.GetItemCountEffective(val.originalItem); if (itemCountEffective > 0) { num += itemCountEffective; } } } } } else { ItemIndex transformedItemIndex = ContagiousItemManager.GetTransformedItemIndex(itemDef.itemIndex); if ((int)transformedItemIndex != -1) { int itemCountEffective2 = ((SubjectChatMessage)self).subjectAsCharacterBody.inventory.GetItemCountEffective(transformedItemIndex); if (itemCountEffective2 > 0) { num += itemCountEffective2; } } } if (num > pickupQuantity) { self.pickupQuantity = 1u; return orig.Invoke(self) + "(" + num + ")"; } } return orig.Invoke(self); } public static void AutoGeneratedText() { //IL_0127: 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_0152: Unknown result type (might be due to invalid IL or missing references) //IL_0157: Unknown result type (might be due to invalid IL or missing references) //IL_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_01a8: Unknown result type (might be due to invalid IL or missing references) //IL_01ad: Unknown result type (might be due to invalid IL or missing references) //IL_01d3: Unknown result type (might be due to invalid IL or missing references) //IL_01d8: Unknown result type (might be due to invalid IL or missing references) //IL_01f3: Unknown result type (might be due to invalid IL or missing references) //IL_01f8: Unknown result type (might be due to invalid IL or missing references) //IL_0213: Unknown result type (might be due to invalid IL or missing references) //IL_0218: Unknown result type (might be due to invalid IL or missing references) //IL_0233: Unknown result type (might be due to invalid IL or missing references) //IL_0238: Unknown result type (might be due to invalid IL or missing references) //IL_0253: Unknown result type (might be due to invalid IL or missing references) //IL_0258: Unknown result type (might be due to invalid IL or missing references) //IL_0273: Unknown result type (might be due to invalid IL or missing references) //IL_0278: Unknown result type (might be due to invalid IL or missing references) //IL_009d: Unknown result type (might be due to invalid IL or missing references) //IL_00a2: Unknown result type (might be due to invalid IL or missing references) //IL_00a8: Expected O, but got Unknown if (WConfig.cfgAltBodyNames.Value && Language.currentLanguage.TokenIsRegistered("LUNARGOLEM_BODY_NAME_")) { string name = Language.currentLanguage.name; LanguageAPI.Add("LUNARGOLEM_BODY_NAME", Language.GetString("LUNARGOLEM_BODY_NAME_"), name); LanguageAPI.Add("LUNARWISP_BODY_NAME", Language.GetString("LUNARWISP_BODY_NAME_"), name); LanguageAPI.Add("LUNAREXPLODER_BODY_NAME", Language.GetString("LUNAREXPLODER_BODY_NAME_"), name); LanguageAPI.Add("ACIDLARVA_BODY_NAME", Language.GetString("ACIDLARVA_BODY_NAME_"), name); object obj = <>O.<4>__MithrixPhase2OverrideLunarChimeraHordeName; if (obj == null) { hook_OnEnter val = MithrixPhase2OverrideLunarChimeraHordeName; <>O.<4>__MithrixPhase2OverrideLunarChimeraHordeName = val; obj = (object)val; } Phase2.OnEnter += (hook_OnEnter)obj; } if (WConfig.cfgTextOther.Value) { LanguageAPI.Add("PROPER_SAVE_CHAT_SAVE", "" + Language.GetString("PROPER_SAVE_CHAT_SAVE").Replace("", "") + ""); LanguageAPI.Add("VULTUREHUNTER_DIALOGUE_FORMAT", Language.GetString("VULTUREHUNTER_DIALOGUE_FORMAT").Replace("c6d5ff", "87E5C0")); SkillDef val2 = null; val2 = Addressables.LoadAssetAsync((object)"RoR2/DLC1/VoidSurvivor/FireCorruptBeam.asset").WaitForCompletion(); BoostedNameToken(val2, "VOIDFIEND_BOOSTED_FORMAT"); val2.skillDescriptionToken = "SKILL_VOIDFIEND_CORRUPT_M1"; val2 = Addressables.LoadAssetAsync((object)"RoR2/DLC1/VoidSurvivor/FireCorruptDisk.asset").WaitForCompletion(); BoostedNameToken(val2, "VOIDFIEND_BOOSTED_FORMAT"); val2.skillDescriptionToken = "SKILL_VOIDFIEND_CORRUPT_M2"; val2 = Addressables.LoadAssetAsync((object)"RoR2/DLC1/VoidSurvivor/VoidBlinkDown.asset").WaitForCompletion(); BoostedNameToken(val2, "VOIDFIEND_BOOSTED_FORMAT"); val2.skillDescriptionToken = "SKILL_VOIDFIEND_CORRUPT_M3"; val2 = Addressables.LoadAssetAsync((object)"RoR2/DLC1/VoidSurvivor/CrushHealth.asset").WaitForCompletion(); BoostedNameToken(val2, "VOIDFIEND_BOOSTED_FORMAT"); val2.skillDescriptionToken = "SKILL_VOIDFIEND_CORRUPT_M4"; val2 = Addressables.LoadAssetAsync((object)"RoR2/DLC2/Chef/ChefDiceBoosted.asset").WaitForCompletion(); BoostedNameToken(val2, "CHEF_BOOSTED_FORMAT"); val2 = Addressables.LoadAssetAsync((object)"RoR2/DLC2/Chef/ChefSearBoosted.asset").WaitForCompletion(); BoostedNameToken(val2, "CHEF_BOOSTED_FORMAT"); val2 = Addressables.LoadAssetAsync((object)"RoR2/DLC2/Chef/ChefIceBoxBoosted.asset").WaitForCompletion(); BoostedNameToken(val2, "CHEF_BOOSTED_FORMAT"); val2 = Addressables.LoadAssetAsync((object)"RoR2/DLC2/Chef/ChefRolyPolyBoosted.asset").WaitForCompletion(); BoostedNameToken(val2, "CHEF_BOOSTED_FORMAT"); val2 = Addressables.LoadAssetAsync((object)"RoR2/DLC2/Chef/ChefOilSpillBoosted.asset").WaitForCompletion(); BoostedNameToken(val2, "CHEF_BOOSTED_FORMAT"); val2 = Addressables.LoadAssetAsync((object)"dacc509e9126ce5488645a54da6a8509").WaitForCompletion(); val2.skillNameToken = "FALSESON_PRIMARY_NAME"; val2.skillDescriptionToken = "FALSESON_PRIMARY_DESCRIPTION"; Items.FragileDamageBonusConsumed.descriptionToken = Items.FragileDamageBonusConsumed.pickupToken; Items.HealingPotionConsumed.descriptionToken = Items.HealingPotionConsumed.pickupToken; } } private static void MithrixPhase2OverrideLunarChimeraHordeName(orig_OnEnter orig, Phase2 self) { orig.Invoke(self); if (Object.op_Implicit((Object)(object)((BrotherEncounterPhaseBaseState)self).phaseBossGroup)) { bool flag = ((BrotherEncounterPhaseBaseState)self).phaseScriptedCombatEncounter.spawns.Length == 1; bool flag2 = Chainloader.PluginInfos.ContainsKey("com.Nuxlar.UmbralMithrix"); if (!flag && !flag2 && Language.currentLanguage.TokenIsRegistered("LUNAR_CHIMERA")) { BossGroup component = ((Component)((BrotherEncounterPhaseBaseState)self).phaseBossGroup).GetComponent(); component.lastDisplayedPriority = 0f; component.currentPriority = 0f; component.bestObservedName = Language.GetString("LUNAR_CHIMERA"); component.bestObservedSubtitle = " " + Language.GetString("LUNARGOLEM_BODY_SUBTITLE") + " "; } } } public static void BoostedNameToken(SkillDef skill, string format) { LanguageAPI.Add(skill.skillNameToken + "_B", string.Format(Language.GetString(format), Language.GetString(skill.skillNameToken))); skill.skillNameToken += "_B"; } private static void PurchaseTokenOverwrite_PurchaseInteraction_GetContextString(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown //IL_003d: Unknown result type (might be due to invalid IL or missing references) ILCursor val = new ILCursor(il); if (val.TryGotoNext((MoveType)2, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchLdfld(x, "RoR2.PurchaseInteraction", "contextToken") })) { val.Emit(OpCodes.Ldarg_0); val.EmitDelegate>((Func)delegate(string ret, PurchaseInteraction self) { PurchaseTokenOverwrite component = ((Component)self).GetComponent(); return Object.op_Implicit((Object)(object)component) ? component.contextToken : ret; }); } else { Log.LogWarning("IL Failed: PurchaseInteraction_GetContextString"); } } private static string PurchaseTokenOverwrite_PurchaseInteraction_GetDisplayName(orig_GetDisplayName orig, PurchaseInteraction self) { PurchaseTokenOverwrite component = ((Component)self).GetComponent(); if (Object.op_Implicit((Object)(object)component)) { return Language.GetString(component.displayNameToken); } return orig.Invoke(self); } public static void EndingText() { //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_0040: Unknown result type (might be due to invalid IL or missing references) //IL_0045: Unknown result type (might be due to invalid IL or missing references) //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_0063: Unknown result type (might be due to invalid IL or missing references) //IL_0068: Unknown result type (might be due to invalid IL or missing references) //IL_0082: 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_00a3: Unknown result type (might be due to invalid IL or missing references) //IL_00a8: Unknown result type (might be due to invalid IL or missing references) //IL_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_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_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_012f: Unknown result type (might be due to invalid IL or missing references) //IL_0134: Unknown result type (might be due to invalid IL or missing references) //IL_0139: Unknown result type (might be due to invalid IL or missing references) //IL_013b: Unknown result type (might be due to invalid IL or missing references) //IL_0140: Unknown result type (might be due to invalid IL or missing references) //IL_0149: Unknown result type (might be due to invalid IL or missing references) //IL_0153: Unknown result type (might be due to invalid IL or missing references) //IL_0158: Unknown result type (might be due to invalid IL or missing references) //IL_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_01b9: Unknown result type (might be due to invalid IL or missing references) //IL_01be: Unknown result type (might be due to invalid IL or missing references) //IL_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_01d0: 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) GameEndingDef val = LegacyResourcesAPI.Load("GameEndingDefs/PrismaticTrialEnding"); val.backgroundColor = new Color(0.7f, 0.3f, 0.7f, 0.615f); val.foregroundColor = new Color(0.9f, 0.6f, 0.9f, 0.833f); GameEndingDef val2 = Addressables.LoadAssetAsync((object)"RoR2/Base/ClassicRun/MainEnding.asset").WaitForCompletion(); GameEndingDef val3 = Addressables.LoadAssetAsync((object)"RoR2/Base/ClassicRun/EscapeSequenceFailed.asset").WaitForCompletion(); GameEndingDef val4 = LegacyResourcesAPI.Load("gameendingdefs/LimboEnding"); GameEndingDef val5 = Addressables.LoadAssetAsync((object)"RoR2/DLC1/GameModes/VoidEnding.asset").WaitForCompletion(); GameEndingDef val6 = LegacyResourcesAPI.Load("gameendingdefs/ObliterationEnding"); GameEndingDef val7 = Addressables.LoadAssetAsync((object)"RoR2/DLC2/ClassicRun/Endings/RebirthEndingDef.asset").WaitForCompletion(); GameEndingDef val8 = Addressables.LoadAssetAsync((object)"bdddeb53086a7c8409359b7179f3a507").WaitForCompletion(); val3.icon = val2.icon; Color val9 = default(Color); ((Color)(ref val9))..ctor(0.9f, 0.9f, 1f, 1f); val4.backgroundColor = Color32.op_Implicit(new Color32((byte)227, (byte)236, (byte)252, (byte)215)) * val9; val4.foregroundColor = Color32.op_Implicit(new Color32((byte)232, (byte)239, byte.MaxValue, (byte)190)) * val9; val6.foregroundColor = val6.backgroundColor * 1.1f; val6.backgroundColor = ((Color)(ref val6.backgroundColor)).AlphaMultiplied(0.75f); val5.icon = Assets.Bundle.LoadAsset("Assets/WQoL/General/texGameResultRebirth_SotV.png"); val7.icon = Assets.Bundle.LoadAsset("Assets/WQoL/General/texGameResult_SotS.png"); val8.icon = Assets.Bundle.LoadAsset("Assets/WQoL/General/texGameResult_AC.png"); Color foregroundColor = val8.foregroundColor; val8.foregroundColor = val8.backgroundColor; val8.backgroundColor = foregroundColor; if (WConfig.cfgTextOther.Value) { val.endingTextToken = "ACHIEVEMENT_COMPLETEPRISMATICTRIAL_NAME"; val4.endingTextToken = "GAME_RESULT_LIMBOWIN"; val5.endingTextToken = "GAME_RESULT_VOIDWIN"; val3.endingTextToken = "GAME_RESULT_ESCAPEFAILED"; } } private static void BlueTeleporterObjective(orig_Start orig, TeleporterInteraction self) { orig.Invoke(self); if (!WConfig.cfgPrimordialBlueText.Value) { return; } if (((Object)self).name.StartsWith("Lunar")) { if (TPLunar1 == null) { LunaredAllOverIt = true; TPLunar1 = LanguageAPI.AddOverlay("OBJECTIVE_FIND_TELEPORTER", Language.GetString("OBJECTIVE_FIND_TELEPORTER").Replace("cDeath", "cLunarObjective")); TPLunar2 = LanguageAPI.AddOverlay("OBJECTIVE_CHARGE_TELEPORTER", Language.GetString("OBJECTIVE_CHARGE_TELEPORTER").Replace("cDeath", "cLunarObjective")); TPLunar3 = LanguageAPI.AddOverlay("OBJECTIVE_CHARGE_TELEPORTER_OOB", Language.GetString("OBJECTIVE_CHARGE_TELEPORTER_OOB").Replace("cDeath", "cLunarObjective")); TPLunar4 = LanguageAPI.AddOverlay("OBJECTIVE_FINISH_TELEPORTER", Language.GetString("OBJECTIVE_FINISH_TELEPORTER").Replace("cDeath", "cLunarObjective")); } } else if (TPLunar1 != null) { TPLunar1.Remove(); TPLunar2.Remove(); TPLunar3.Remove(); TPLunar4.Remove(); } } internal static void OtherText() { //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_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_006a: Unknown result type (might be due to invalid IL or missing references) //IL_006f: Unknown result type (might be due to invalid IL or missing references) //IL_008b: Unknown result type (might be due to invalid IL or missing references) //IL_0090: Unknown result type (might be due to invalid IL or missing references) //IL_00b9: Unknown result type (might be due to invalid IL or missing references) //IL_00be: Unknown result type (might be due to invalid IL or missing references) //IL_00da: Unknown result type (might be due to invalid IL or missing references) //IL_00df: Unknown result type (might be due to invalid IL or missing references) //IL_0108: Unknown result type (might be due to invalid IL or missing references) //IL_010d: Unknown result type (might be due to invalid IL or missing references) //IL_0148: Unknown result type (might be due to invalid IL or missing references) //IL_014d: Unknown result type (might be due to invalid IL or missing references) //IL_0169: Unknown result type (might be due to invalid IL or missing references) //IL_016e: Unknown result type (might be due to invalid IL or missing references) //IL_018a: Unknown result type (might be due to invalid IL or missing references) //IL_018f: Unknown result type (might be due to invalid IL or missing references) //IL_01ab: Unknown result type (might be due to invalid IL or missing references) //IL_01b0: Unknown result type (might be due to invalid IL or missing references) //IL_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_01ed: Unknown result type (might be due to invalid IL or missing references) //IL_01f2: Unknown result type (might be due to invalid IL or missing references) //IL_020e: Unknown result type (might be due to invalid IL or missing references) //IL_0213: Unknown result type (might be due to invalid IL or missing references) //IL_022f: Unknown result type (might be due to invalid IL or missing references) //IL_0234: Unknown result type (might be due to invalid IL or missing references) //IL_0250: Unknown result type (might be due to invalid IL or missing references) //IL_0255: Unknown result type (might be due to invalid IL or missing references) LanguageAPI.Add("KEYWORD_SLOWING", "SlowingApply a slowing debuff reducing enemy movement speed by 50%.", "en"); Addressables.LoadAssetAsync((object)"357435043113a944c9a477d63dc9a893").WaitForCompletion().GetComponent() .bestName = "FREECHEST_TERMINAL_NAME"; PurchaseTokenOverwrite purchaseTokenOverwrite = Addressables.LoadAssetAsync((object)"0af0551c0f67fe249b04af841608a41c").WaitForCompletion().AddComponent(); purchaseTokenOverwrite.displayNameToken = "FREECHEST_TERMINAL_NAME"; purchaseTokenOverwrite.contextToken = "FREECHEST_TERMINAL_CONTEXT"; Addressables.LoadAssetAsync((object)"c814170ba819d7b45934c0fc54fd99d1").WaitForCompletion().GetComponent() .bestName = "MULTISHOP_LARGE_TERMINAL_NAME"; purchaseTokenOverwrite = Addressables.LoadAssetAsync((object)"c87d4eb171e0ee44cb2d4ec714c58c72").WaitForCompletion().AddComponent(); purchaseTokenOverwrite.displayNameToken = "MULTISHOP_LARGE_TERMINAL_NAME"; purchaseTokenOverwrite.contextToken = "MULTISHOP_TERMINAL_CONTEXT"; Addressables.LoadAssetAsync((object)"e992781bd4b52804c8d340a56db49a06").WaitForCompletion().GetComponent() .bestName = "MULTISHOP_EQUIPMENT_TERMINAL_NAME"; purchaseTokenOverwrite = Addressables.LoadAssetAsync((object)"63251d66a257b1a4c8eed4de5dd89561").WaitForCompletion().AddComponent(); purchaseTokenOverwrite.displayNameToken = "MULTISHOP_EQUIPMENT_TERMINAL_NAME"; purchaseTokenOverwrite.contextToken = "MULTISHOP_TERMINAL_CONTEXT"; GameObject val = Addressables.LoadAssetAsync((object)"f21b2c8a9cc028046935ea871dc4af54").WaitForCompletion(); val.GetComponent().bestName = "DUPLICATOR_LARGE_NAME"; purchaseTokenOverwrite = val.AddComponent(); purchaseTokenOverwrite.displayNameToken = "DUPLICATOR_LARGE_NAME"; purchaseTokenOverwrite.contextToken = "DUPLICATOR_LARGE_CONTEXT"; Addressables.LoadAssetAsync((object)"RoR2/Base/Vagrant/VagrantTrackingBomb.prefab").WaitForCompletion().GetComponent() .baseNameToken = "VagrantTrackingBomb"; Addressables.LoadAssetAsync((object)"RoR2/Base/Scav/ScavSackProjectile.prefab").WaitForCompletion().GetComponent() .baseNameToken = "ScavSackProjectile"; Addressables.LoadAssetAsync((object)"RoR2/DLC2/Scorchling/ScorchlingBombProjectile.prefab").WaitForCompletion().GetComponent() .baseNameToken = "ScorchlingBombProjectile"; Addressables.LoadAssetAsync((object)"RoR2/DLC2/MiniGeodeBody.prefab").WaitForCompletion().GetComponent() .baseNameToken = "MiniGeodeBody"; Addressables.LoadAssetAsync((object)"RoR2/Base/LunarWisp/LunarWispTrackingBomb.prefab").WaitForCompletion().GetComponent() .baseNameToken = "LunarWispTrackingBomb"; Addressables.LoadAssetAsync((object)"RoR2/Base/Gravekeeper/GravekeeperTrackingFireball.prefab").WaitForCompletion().GetComponent() .baseNameToken = "GravekeeperTrackingFireball"; Addressables.LoadAssetAsync((object)"RoR2/DLC2/Elites/EliteBead/BeadProjectileTrackingBomb.prefab").WaitForCompletion().GetComponent() .baseNameToken = "BeadProjectileTrackingBomb"; Addressables.LoadAssetAsync((object)"RoR2/Base/AltarSkeleton/AltarSkeletonBody.prefab").WaitForCompletion().GetComponent() .baseNameToken = "AltarSkeletonBody"; Addressables.LoadAssetAsync((object)"34d770816ffbf0d468728c48853fd5f6").WaitForCompletion().GetComponent() .contextToken = "PORTAL_DESTINATION_CONTEXT"; } public static void UntieredItemTokens() { Items.TeamSizeDamageBonus.AutoPopulateTokens(); Items.UseAmbientLevel.AutoPopulateTokens(); Items.MinHealthPercentage.AutoPopulateTokens(); Items.VoidmanPassiveItem.AutoPopulateTokens(); Items.TeleportWhenOob.AutoPopulateTokens(); Equipment.EliteYellowEquipment.AutoPopulateTokens(); Items.DroneUpgradeHidden.AutoPopulateTokens(); } } public static class TextMain { public static BodyIndex LemurianBruiser = (BodyIndex)(-1); public static void Start() { if (WConfig.module_text_reminders.Value) { Reminders_Main.Start(); } if (WConfig.module_text_chat.Value) { MoreMessages.Start(); } if (WConfig.module_text_general.Value) { LunarSeer.Start(); EquipmentDrone.Start(); OptionsInChat.Start(); ShrineShapingMessage.Start(); TextChanges.Main(); } ((ResourceAvailability)(ref ItemCatalog.availability)).CallWhenAvailable((Action)TextChanges.UntieredItemTokens); ((ResourceAvailability)(ref GameModeCatalog.availability)).CallWhenAvailable((Action)CallLate); } public static void CallLate() { //IL_006e: Unknown result type (might be due to invalid IL or missing references) //IL_0073: Unknown result type (might be due to invalid IL or missing references) //IL_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_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_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) Debug.Log((object)NetworkMessageHandlerAttribute.clientMessageHandlers.Count); Debug.Log((object)NetworkMessageHandlerAttribute.serverMessageHandlers.Count); foreach (NetworkMessageHandlerAttribute clientMessageHandler in NetworkMessageHandlerAttribute.clientMessageHandlers) { Debug.Log(((SearchableAttribute)clientMessageHandler).target); } MoreMessages.VanillaVoids_WatchBrokeItem = ItemCatalog.FindItemIndex("VV_ITEM_BROKEN_MESS"); PrayerBeads.moffeine = ItemCatalog.FindItemIndex("MoffeinBeadStatItem"); PrayerBeads.usedBeads = ItemCatalog.FindItemIndex("ExtraStatsOnLevelUpConsumed"); LemurianBruiser = BodyCatalog.FindBodyIndex("LemurianBruiserBody"); if (WConfig.module_text_general.Value) { PrayerBeads.Start(); TextChanges.AutoGeneratedText(); } } private static string IncludeEliteTypeInSubjectName(orig_GetSubjectName orig, SubjectChatMessage self) { if ((Object)(object)self.subjectAsNetworkUser == (Object)null && Object.op_Implicit((Object)(object)self.subjectAsCharacterBody)) { return Util.GetBestBodyName(((Component)self.subjectAsCharacterBody).gameObject); } return orig.Invoke(self); } public static string MarriedLemurianNameHook(orig_GetBestBodyName orig, GameObject bodyObject) { //IL_001f: Unknown result type (might be due to invalid IL or missing references) //IL_0024: Unknown result type (might be due to invalid IL or missing references) if (Object.op_Implicit((Object)(object)bodyObject)) { CharacterBody component = bodyObject.GetComponent(); if (Object.op_Implicit((Object)(object)component) && component.bodyIndex == LemurianBruiser && component.inventory.GetItemCount(Items.Clover) >= 20) { if (component.inventory.GetItemCount(Items.FireRing) > 0) { return "Kjaro"; } if (component.inventory.GetItemCount(Items.IceRing) > 0) { return "Runald"; } } } return orig.Invoke(bodyObject); } } } namespace WolfoQoL_Client.Menu { public static class MenuMain { [CompilerGenerated] private static class <>O { public static hook_Start <0>__MainMenuExtras; public static Action <1>__CallLate; public static hook_ctor <2>__StripExitAnimation_ctor; public static hook_SetPercentComplete <3>__StripExitAnimation_SetPercentComplete; } private static int themeStatic = -1; public static void Start() { //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_0057: Expected O, but got Unknown if (WConfig.module_menu_deathscreen.Value) { DeathScreen_Main.Start(); } if (WConfig.module_menu_logbook.Value) { LogbookStuff.Start(); } if (WConfig.module_menu_other.Value) { object obj = <>O.<0>__MainMenuExtras; if (obj == null) { hook_Start val = MainMenuExtras; <>O.<0>__MainMenuExtras = val; obj = (object)val; } MainMenuController.Start += (hook_Start)obj; UIBorders.Start(); UI_Stuff.Start(); UI_RealTimeTimer.Start(); UI_Color.Start(); } ((ResourceAvailability)(ref GameModeCatalog.availability)).CallWhenAvailable((Action)CallLate); } private static void CallLate() { //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_0024: Expected O, but got Unknown //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_0045: Expected O, but got Unknown ObjectiveHudSpacing_SettingChanged(null, null); object obj = <>O.<2>__StripExitAnimation_ctor; if (obj == null) { hook_ctor val = StripExitAnimation_ctor; <>O.<2>__StripExitAnimation_ctor = val; obj = (object)val; } StripExitAnimation.ctor += (hook_ctor)obj; object obj2 = <>O.<3>__StripExitAnimation_SetPercentComplete; if (obj2 == null) { hook_SetPercentComplete val2 = StripExitAnimation_SetPercentComplete; <>O.<3>__StripExitAnimation_SetPercentComplete = val2; obj2 = (object)val2; } StripExitAnimation.SetPercentComplete += (hook_SetPercentComplete)obj2; } private static void StripExitAnimation_ctor(orig_ctor orig, StripExitAnimation self, ObjectiveTracker objectiveTracker) { orig.Invoke(self, objectiveTracker); if (Object.op_Implicit((Object)(object)objectiveTracker.stripObject)) { self.originalHeight += WConfig.ObjectiveHudSpacing.Value; } } private static void StripExitAnimation_SetPercentComplete(orig_SetPercentComplete orig, StripExitAnimation self, float newPercentComplete) { orig.Invoke(self, newPercentComplete); if (Object.op_Implicit((Object)(object)((ObjectiveStripAnimation)self).objectiveTracker.stripObject)) { LayoutElement layoutElement = ((ObjectiveStripAnimation)self).layoutElement; layoutElement.preferredHeight -= WConfig.ObjectiveHudSpacing.Value; } } public static void ObjectiveHudSpacing_SettingChanged(object sender, EventArgs e) { Run val = GameModeCatalog.FindGameModePrefabComponent("ClassicRun"); Run val2 = GameModeCatalog.FindGameModePrefabComponent("InfiniteTowerRun"); ((HorizontalOrVerticalLayoutGroup)((Component)val.uiPrefab.transform.Find("RightInfoBar/ObjectivePanel/StripContainer")).GetComponent()).spacing = WConfig.ObjectiveHudSpacing.Value; ((HorizontalOrVerticalLayoutGroup)((Component)val2.uiPrefab.transform.Find("RightInfoBar/ObjectivePanel/StripContainer")).GetComponent()).spacing = WConfig.ObjectiveHudSpacing.Value; if (Object.op_Implicit((Object)(object)Run.instance)) { ((HorizontalOrVerticalLayoutGroup)((Component)Run.instance.uiInstances[0].transform.Find("RightInfoBar/ObjectivePanel/StripContainer")).GetComponent()).spacing = WConfig.ObjectiveHudSpacing.Value; } } public static void MainMenuExtras(orig_Start orig, MainMenuController self) { //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_0290: Unknown result type (might be due to invalid IL or missing references) //IL_02ac: Unknown result type (might be due to invalid IL or missing references) //IL_00b0: Unknown result type (might be due to invalid IL or missing references) //IL_00b5: Unknown result type (might be due to invalid IL or missing references) //IL_03b5: Unknown result type (might be due to invalid IL or missing references) //IL_03ba: Unknown result type (might be due to invalid IL or missing references) //IL_03cf: Unknown result type (might be due to invalid IL or missing references) //IL_03d4: Unknown result type (might be due to invalid IL or missing references) //IL_02e7: Unknown result type (might be due to invalid IL or missing references) //IL_02ec: Unknown result type (might be due to invalid IL or missing references) //IL_030f: Unknown result type (might be due to invalid IL or missing references) //IL_0314: Unknown result type (might be due to invalid IL or missing references) //IL_0337: Unknown result type (might be due to invalid IL or missing references) //IL_033c: Unknown result type (might be due to invalid IL or missing references) //IL_0186: Unknown result type (might be due to invalid IL or missing references) //IL_01a7: 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_0201: Unknown result type (might be due to invalid IL or missing references) //IL_0222: 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_035f: Unknown result type (might be due to invalid IL or missing references) //IL_0364: Unknown result type (might be due to invalid IL or missing references) orig.Invoke(self); if (WConfig.cfgMainMenuScav.Value) { GameObject val = GameObject.Find("/HOLDER: Title Background"); GameObject val2 = Object.Instantiate(Addressables.LoadAssetAsync((object)"RoR2/Base/title/CU3 Props.prefab").WaitForCompletion(), val.transform); Object.Destroy((Object)(object)((Component)val2.transform.GetChild(3)).gameObject); Object.Destroy((Object)(object)((Component)val2.transform.GetChild(1)).gameObject); Object.Destroy((Object)(object)((Component)val2.transform.GetChild(0)).gameObject); val2.SetActive(true); if (((BaseUserEntitlementTracker)(object)EntitlementManager.localUserEntitlementTracker).AnyUserHasEntitlement(DLCS.entitlementDLC1)) { GameObject val3 = Addressables.LoadAssetAsync((object)"RoR2/DLC1/Gup/GupBody.prefab").WaitForCompletion(); GameObject val4 = Object.Instantiate(((Component)val3.transform.GetChild(0).GetChild(0)).gameObject); ModelSkinController component = val4.GetComponent(); if (!component.DelayLoadingAnimatorUntilMaterialsHaveCompleted && Object.op_Implicit((Object)(object)component.animator)) { if (component.avatarRef != null) { component.avatarRef.SetUnloadType((AsyncReferenceHandleUnloadType)3); } if (component.animatorControllerRef != null) { component.animatorControllerRef.SetUnloadType((AsyncReferenceHandleUnloadType)3); } } ((MonoBehaviour)self).StartCoroutine(component.ApplySkinAsync(0, (AsyncReferenceHandleUnloadType)3)); val4.GetComponent().Play("Spawn1", 0, 1f); val4.transform.localScale = new Vector3(7f, 7f, 7f); val4.transform.localPosition = new Vector3(55.2f, -1f, 11.5f); val4.transform.localEulerAngles = new Vector3(7f, 262f, 0f); val4.GetComponent().Play("Spawn1", 0, 1f); val4.transform.localScale = new Vector3(7f, 7f, 7f); val4.transform.localPosition = new Vector3(52f, -1.2f, 160f); val4.transform.localEulerAngles = new Vector3(7f, 157f, 345f); } Transform desiredCameraTransform = self.extraGameModeMenuScreen.desiredCameraTransform; self.extraGameModeMenuScreen.desiredCameraTransform = self.moreMenuScreen.desiredCameraTransform; self.moreMenuScreen.desiredCameraTransform = desiredCameraTransform; desiredCameraTransform.localPosition = new Vector3(36.24f, 2.7204f, 3.1807f); desiredCameraTransform.localEulerAngles = new Vector3(5.2085f, 38.4904f, 0f); } WConfig.MainMenuTheme value = WConfig.cfgMainMenuRandomizer.Value; if (value >= WConfig.MainMenuTheme.Acres) { GameObject val5 = null; switch (value) { case WConfig.MainMenuTheme.Acres: val5 = Object.Instantiate(Addressables.LoadAssetAsync((object)"RoR2/Base/title/CU1 Props.prefab").WaitForCompletion()); break; case WConfig.MainMenuTheme.Sirens: val5 = Object.Instantiate(Addressables.LoadAssetAsync((object)"RoR2/Base/title/CU2 Props.prefab").WaitForCompletion()); break; case WConfig.MainMenuTheme.Realms: val5 = Object.Instantiate(Addressables.LoadAssetAsync((object)"RoR2/Base/title/CU3 Props.prefab").WaitForCompletion()); break; case WConfig.MainMenuTheme.Artifact: val5 = Object.Instantiate(Addressables.LoadAssetAsync((object)"RoR2/Base/title/CU4 Props.prefab").WaitForCompletion()); break; } if (Object.op_Implicit((Object)(object)val5)) { val5.SetActive(true); } } else { if (value < WConfig.MainMenuTheme.Random) { return; } GameObject val6 = GameObject.Find("/StormMainMenuEffect(Clone)"); GameObject val7 = Object.Instantiate(Addressables.LoadAssetAsync((object)"RoR2/Base/title/CU1 Props.prefab").WaitForCompletion()); GameObject val8 = Object.Instantiate(Addressables.LoadAssetAsync((object)"RoR2/Base/title/CU2 Props.prefab").WaitForCompletion()); int num = WQoLMain.random.Next(6); if (value == WConfig.MainMenuTheme.RandomStatic) { if (themeStatic == -1) { themeStatic = num; } num = themeStatic; } switch (num) { case 1: case 3: val7.SetActive(true); break; case 2: case 4: val8.SetActive(true); break; } if (num >= 3 && Object.op_Implicit((Object)(object)val6)) { val6.SetActive(false); } } } } } namespace WolfoQoL_Client.DeathScreen { public static class EquipOnDeathInventory { public static EquipmentIndex[] DeathEquips_Player = Array.Empty(); public static EquipmentIndex DeathEquip_Enemy1 = (EquipmentIndex)(-1); public static void AddEquipmentIcons(orig_AllocateIcons orig, ItemInventoryDisplay self, int desiredItemCount) { //IL_009b: Unknown result type (might be due to invalid IL or missing references) //IL_00a1: Invalid comparison between Unknown and I4 //IL_00af: Unknown result type (might be due to invalid IL or missing references) //IL_01f6: Unknown result type (might be due to invalid IL or missing references) //IL_015c: 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_0168: Unknown result type (might be due to invalid IL or missing references) if (((Object.op_Implicit((Object)(object)Run.instance) && Run.instance.isGameOverServer) || (Object)(object)self.inventory == (Object)null) && ((Object)self).name == "Content") { bool flag = (Object)(object)self.inventory == (Object)null; Transform parent = ((Component)self).transform.parent.parent.parent; Transform parent2 = ((Component)self).transform.parent.parent; Dictionary dictionary = new Dictionary(); if (((Object)parent).name == "KillerItemArea") { if ((int)DeathEquip_Enemy1 != -1) { dictionary.Add(DeathEquip_Enemy1, 1); } } else if (!(((Object)parent).name == "EvolutionArea") && (((Object)parent).name == "ItemArea" || ((Object)parent2).name == "ItemArea") && !DeathScreen_Main.otherMod) { for (int i = 0; i < DeathEquips_Player.Length; i++) { if ((int)DeathEquips_Player[i] != -1) { if (dictionary.ContainsKey(DeathEquips_Player[i])) { dictionary[DeathEquips_Player[i]]++; } else { dictionary.Add(DeathEquips_Player[i], 1); } } } } if (dictionary.Count == 0) { orig.Invoke(self, desiredItemCount); return; } orig.Invoke(self, desiredItemCount + dictionary.Count); for (int j = 0; j < dictionary.Count; j++) { KeyValuePair keyValuePair = dictionary.ElementAt(j); MakeEquipmentIcon(self.itemIcons[desiredItemCount + j], EquipmentCatalog.GetEquipmentDef(keyValuePair.Key), keyValuePair.Value); } } else { orig.Invoke(self, desiredItemCount); } } public static void MakeEquipmentIcon(ItemIcon equipmentIcon, EquipmentDef equipmentDef, int stack) { //IL_0082: 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_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_009d: Unknown result type (might be due to invalid IL or missing references) Log.LogMessage("Making EquipmentIcon"); ((Component)equipmentIcon).GetComponent().SetItemIndex((ItemIndex)0, stack, 0f); equipmentIcon.image.texture = equipmentDef.pickupIconTexture; TooltipProvider component = ((Component)equipmentIcon).GetComponent(); ((Object)equipmentIcon).name = "EquipmentIcon"; component.titleToken = equipmentDef.nameToken; component.bodyToken = equipmentDef.descriptionToken; component.overrideBodyText = Language.GetString(equipmentDef.descriptionToken); component.bodyColor = new Color(0.6f, 0.6f, 0.6f, 1f); component.titleColor = Color32.op_Implicit(ColorCatalog.GetColor(equipmentDef.colorIndex)); } } public static class ExtraStats { public static void PointsToolTip(orig_AssignStatToStrip orig, GameEndReportPanelController self, StatSheet srcStatSheet, StatDef statDef, GameObject destStatStrip) { //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) orig.Invoke(self, srcStatSheet, statDef, destStatStrip); if (statDef.pointValue == 0.0) { ((Component)destStatStrip.transform.Find("PointValueLabel")).gameObject.SetActive(false); return; } TooltipProvider val = destStatStrip.gameObject.GetComponent(); if ((Object)(object)val == (Object)null) { val = destStatStrip.gameObject.AddComponent(); val.titleColor = new Color(0.5339f, 0.4794f, 0.5943f, 1f); } val.titleToken = Language.GetString(statDef.displayToken); val.bodyToken = ((TMP_Text)((Component)destStatStrip.transform.GetChild(1)).GetComponent()).text; } public static void CombineStats(orig_AllocateUnlockStrips orig, GameEndReportPanelController self, int count) { orig.Invoke(self, count); for (int i = 0; i < self.statStrips.Count; i++) { if ((Object)(object)self.statStrips[i] != (Object)null) { ((Object)self.statStrips[i]).name = self.statsToDisplay[i]; if (StatDef.Find(self.statsToDisplay[i]) == null) { self.statStrips[i].SetActive(false); } } } DeathScreenExpanded component = ((Component)self).GetComponent(); if (WConfig.DC_CompactStats.Value && !component.compactedStats && !component.isLogRunReport) { component.compactedStats = true; RectTransform statContentArea = self.statContentArea; MakeCombinedStat(statContentArea, "totalTimeAlive", 3); MakeCombinedStat(statContentArea, "totalItemsCollected"); MakeCombinedStat(statContentArea, "totalDronesPurchased"); MakeCombinedStat(statContentArea, "totalDamageDealt"); MakeCombinedStat(statContentArea, "totalKills"); MakeCombinedStat(statContentArea, "totalDamageTaken"); MakeCombinedStat(statContentArea, "totalHealthHealed"); MakeCombinedStat(statContentArea, "custom_DotDamage"); MakeCombinedStat(statContentArea, "custom_DamageBlocked"); MakeCombinedStat(statContentArea, "totalDeaths"); MakeCombinedStat(statContentArea, "totalPurchases"); MakeCombinedStat(statContentArea, "custom_ChestsMissed"); MakeCombinedStat(statContentArea, "custom_LunarCoinsSpent"); MakeCombinedStat(statContentArea, "totalDistanceTraveled"); MakeCombinedStat(statContentArea, "custom_EquipUses"); } } public static void MakeCombinedStat(RectTransform statContentArea, string name, int combine = 2) { Transform val = ((Transform)statContentArea).Find(name); if ((Object)(object)val == (Object)null) { return; } int siblingIndex = val.GetSiblingIndex(); StringBuilder stringBuilder = new StringBuilder(); GameObject val2 = Object.Instantiate(DeathScreenExpanded.statHolderPrefab, (Transform)(object)statContentArea); for (int i = 0; i < combine; i++) { Transform child = ((Transform)statContentArea).GetChild(siblingIndex); child.SetParent(val2.transform); ((Component)child.GetChild(1)).gameObject.SetActive(false); if (i != 0) { stringBuilder.Append("+"); } stringBuilder.Append(((Object)child).name); } val2.transform.SetSiblingIndex(siblingIndex); ((Object)val2).name = stringBuilder.ToString(); } public static void CombineDifficultyLoadout(RectTransform statContentArea) { string text = string.Empty; GameObject val = Object.Instantiate(DeathScreenExpanded.statHolderPrefab, (Transform)(object)statContentArea); for (int i = 0; i < 2; i++) { Transform child = ((Transform)statContentArea).GetChild(0); child.SetParent(val.transform); text = text + "+" + ((Object)child).name; } val.transform.SetSiblingIndex(0); ((Object)val).name = text; } public static void DifficultyTooltip(GameEndReportPanelController self) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0004: 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_006e: Unknown result type (might be due to invalid IL or missing references) //IL_0073: Unknown result type (might be due to invalid IL or missing references) //IL_0019: 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) DifficultyIndex val = (DifficultyIndex)(-1); if (self.displayData.runReport != null) { val = self.displayData.runReport.ruleBook.FindDifficulty(); } DifficultyDef difficultyDef = DifficultyCatalog.GetDifficultyDef(val); ((Graphic)self.selectedDifficultyImage).raycastTarget = true; TooltipProvider val2 = ((Component)self.selectedDifficultyImage).gameObject.AddComponent(); val2.titleToken = difficultyDef.nameToken; val2.bodyToken = difficultyDef.descriptionToken; val2.titleColor = difficultyDef.color; Transform parent = ((Component)self.selectedDifficultyImage).transform.parent; ((Component)parent).GetComponent().preferredWidth = 300f; Transform val3 = parent.Find("StatNameLabel"); Transform val4 = parent.Find("SelectedDifficultyLabel"); ((Component)val4).transform.SetSiblingIndex(1); ((Component)val3).GetComponent().token = "RULE_HEADER_DIFFICULTY_WITH_COLON"; self.selectedDifficultyLabel = ((Component)val4).GetComponent(); self.selectedDifficultyLabel.token = difficultyDef.nameToken; } public static void TotalRunTimer(GameEndReportPanelController self) { //IL_00cb: 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) if (!((Object)(object)Run.instance == (Object)null) && WConfig.DC_RealTimeTimerStat.Value) { DeathScreenExpanded component = ((Component)self).GetComponent(); if (!((Object)(object)component == (Object)null)) { Transform val = ((Component)self).GetComponent().FindChild("HeaderArea"); Transform val2 = val.Find("DeathFlavorText"); GameObject val3 = Object.Instantiate(((Component)val2).gameObject, val); ((Object)val3).name = "TotalRunTimer"; TextMeshProUGUI component2 = val3.GetComponent(); ((TMP_Text)component2).fontStyle = (FontStyles)0; ((TMP_Text)component2).horizontalAlignment = (HorizontalAlignmentOptions)2; ((TMP_Text)component2).fontSizeMax = 24f; ((TMP_Text)component2).fontSize = 24f; ((Graphic)component2).color = new Color(0.7f, 0.75f, 0.8f, 1f); val3.transform.localPosition = new Vector3(0f, -50f, 0f); ulong num = (ulong)component.deathTimeStamp; ulong num2 = num / 60; ulong num3 = num - num2 * 60; ((TMP_Text)val3.GetComponent()).text = string.Format("{2}: {0:00}:{1:00}", num2, num3, Language.GetString("STAT_TOTAL_RUN_TIME")); val3.gameObject.SetActive(true); } } } public static void ChangeStats(GameEndReportPanelController self, RunReport runReport) { bool flag = runReport.gameMode is InfiniteTowerRun; bool flag2 = runReport.ruleBook.GetRuleChoice(RuleCatalog.FindRuleDef("Expansions.DLC1")).localIndex == 0; bool flag3 = runReport.ruleBook.GetRuleChoice(RuleCatalog.FindRuleDef("Expansions.DLC3")).localIndex == 0; bool flag4 = false; RuleDef val = RuleCatalog.FindRuleDef("Expansions.SS2"); if (val != null) { flag4 = runReport.ruleBook.GetRuleChoice(val).localIndex == 0; } bool flag5 = runReport.ruleBook.GetRuleChoice(RuleCatalog.FindRuleDef("Artifacts.Devotion")).localIndex == 0 || (Object.op_Implicit((Object)(object)RunArtifactManager.instance) && RunArtifactManager.instance.IsArtifactEnabled(Artifacts.Devotion)); bool flag6 = (Object)(object)runReport.FindFirstPlayerInfo().master == (Object)null; List list = new List(); self.statsToDisplay = new string[34] { flag ? "custom_lastSimuWave" : "", "totalTimeAlive", flag ? "" : "runTime", flag ? "highestInfiniteTowerWaveReached" : "totalStagesCompleted", "totalItemsCollected", "custom_ItemsScrapped", flag ? "null" : "totalDronesPurchased", flag ? "null" : (flag5 ? "devotion_Evolved" : (flag3 ? "custom_DronesScrapped" : "null")), "totalKills", "totalMinionKills", "totalDamageDealt", "totalMinionDamageDealt", "totalDamageTaken", "custom_MinionDamageTaken", "totalHealthHealed", "custom_MinionHealthHealed", "totalDeaths", flag ? "null" : "custom_DroneDeaths", "totalPurchases", "totalGoldCollected", flag ? "null" : "custom_ChestsMissed", flag ? "null" : "custom_DronesMissed", flag6 ? "totalLunarPurchases" : "custom_LunarCoinsSpent", "totalBloodPurchases", "totalDistanceTraveled", "custom_TimesJumped", "custom_DotDamage", "highestDamageDealt", "custom_DamageBlocked", "highestLevel", "custom_EquipUses", "custom_SkillUses", "custom_StrongestMinion", "custom_EnemyMostHurtBy" }; } public static Transform FindStatStrip(GameEndReportPanelController self, string statName) { for (int i = 0; i < self.statsToDisplay.Length; i++) { if (self.statsToDisplay[i] == statName) { if (Object.op_Implicit((Object)(object)self.statStrips[i])) { return self.statStrips[i].transform; } return null; } } return null; } public static void AddCustomStats(GameEndReportPanelController self, PlayerInfo playerInfo) { //IL_0446: Unknown result type (might be due to invalid IL or missing references) //IL_0448: Unknown result type (might be due to invalid IL or missing references) //IL_04f5: Unknown result type (might be due to invalid IL or missing references) //IL_04fb: Invalid comparison between Unknown and I4 //IL_0513: Unknown result type (might be due to invalid IL or missing references) //IL_0373: Unknown result type (might be due to invalid IL or missing references) //IL_0391: Unknown result type (might be due to invalid IL or missing references) //IL_0396: Unknown result type (might be due to invalid IL or missing references) //IL_03aa: Unknown result type (might be due to invalid IL or missing references) //IL_0415: Unknown result type (might be due to invalid IL or missing references) Log.LogMessage("ExtraStats"); Transform val = ((Transform)self.statContentArea).Find("custom_lastSimuWave"); Transform val2 = ((Transform)self.statContentArea).Find("custom_EnemyMostHurtBy"); Transform val3 = ((Transform)self.statContentArea).Find("custom_StrongestMinion"); DeathScreenExpanded component = ((Component)self).GetComponent(); if (!component.madeStats) { component.madeStats = true; GameObject val4 = Object.Instantiate(DeathScreenExpanded.difficulty_stat, val2.parent); val4.SetActive(false); val4.GetComponent().preferredHeight = 50f; ((Component)val4.transform.GetChild(3)).gameObject.AddComponent().aspectMode = (AspectMode)1; ((Component)val4.transform.GetChild(3)).gameObject.GetComponent().preferredWidth = 42f; val2 = MakeBigStat(self, val4, val2); val3 = MakeBigStat(self, val4, val3); } ((Component)val3).gameObject.SetActive(false); if (playerInfo.statSheet == null) { ((Component)val2).gameObject.SetActive(false); return; } SetupBodyStat(val2, "STAT_MOST_HURTBY", "STAT_AMOUNT_HURTBY", playerInfo, PerBodyStatDef.damageTakenFrom); ulong totalEquipmentAcivations = Help.GetTotalEquipmentAcivations(playerInfo.statSheet); int num = (int)playerInfo.statSheet.GetStatValueULong(StatDef.highestItemsCollected); int num2 = (int)playerInfo.statSheet.GetStatValueULong(StatDef.totalDronesPurchased); int num3 = (int)playerInfo.statSheet.GetStatValueULong(StatDef.totalTurretsPurchased); float num4 = playerInfo.statSheet.GetStatValueULong(StatDef.totalDamageDealt); float num5 = playerInfo.statSheet.GetStatValueULong(StatDef.totalMinionDamageDealt); float totalDamage = num4 + num5; DamagePercentTooltip(FindStatStrip(self, "totalDamageDealt"), totalDamage, num4); DamagePercentTooltip(FindStatStrip(self, "totalMinionDamageDealt"), totalDamage, num5); DamagePercentTooltip(FindStatStrip(self, "highestDamageDealt"), totalDamage, playerInfo.statSheet.GetStatValueULong(StatDef.highestDamageDealt)); if (!component.isDevotionRun) { SetupStat(self, "totalDronesPurchased", "STATNAME_TOTALDRONESPURCHASED", num2 + num3); } SetupStat(self, "custom_EquipUses", "STAT_EQUIPMENT_USED", totalEquipmentAcivations, disableIfNeg: true); if (component.isLogRunReport) { return; } if (Object.op_Implicit((Object)(object)val) && !Object.op_Implicit((Object)(object)component.lastWaveStat) && Object.op_Implicit((Object)(object)RunExtraStatTracker.instance.latestWaveUiPrefab)) { GameObject latestWaveUiPrefab = RunExtraStatTracker.instance.latestWaveUiPrefab; GameObject val5 = Object.Instantiate(DeathScreenExpanded.difficulty_stat, val.parent); ((Object)val5).name = "lastSimulacrumWave"; val5.transform.SetSiblingIndex(2); component.lastWaveStat = val5; Transform child = latestWaveUiPrefab.transform.GetChild(0); ((Component)val5.transform.GetChild(0)).GetComponent().token = "LATEST_WAVE"; string token = ((Component)child.GetChild(1).GetChild(0)).GetComponent().token; token = Language.GetString(token); string format = token; Run instance = Run.instance; token = string.Format(format, ((InfiniteTowerRun)((instance is InfiniteTowerRun) ? instance : null)).waveIndex); ((Component)val5.transform.GetChild(2)).GetComponent().token = token; Image component2 = ((Component)val5.transform.GetChild(3)).GetComponent(); Image component3 = ((Component)child.GetChild(0).GetChild(0)).GetComponent(); component2.sprite = component3.sprite; ((Graphic)component2).color = ((Graphic)component3).color; Color color = ((Graphic)((Component)child.GetChild(1).GetChild(0)).GetComponent()).color; ((Graphic)((Component)val5.transform.GetChild(2)).GetComponent()).color = color; try { if (latestWaveUiPrefab.transform.GetChild(0).childCount == 4) { GameObject val6 = Object.Instantiate(((Component)component2).gameObject, val5.transform); component3 = ((Component)child.GetChild(3).GetChild(0)).GetComponent(); component2 = val6.GetComponent(); component2.sprite = component3.sprite; ((Graphic)component2).color = ((Graphic)component3).color; } } catch (Exception message) { Log.LogError(message); } TooltipProvider val7 = val5.AddComponent(); val7.titleToken = token; val7.titleColor = color; val7.bodyToken = ((Component)child.GetChild(1).GetChild(1)).GetComponent().token; } PerPlayerMaster_ExtraStatTracker component4 = ((Component)playerInfo.master).GetComponent(); if (component4.latestDetailedDeathMessage != string.Empty) { string text = ((TMP_Text)self.finalMessageLabel).text + "\n" + component4.latestDetailedDeathMessage; ((TMP_Text)self.finalMessageLabel).SetText(text, true); } SetupTimerStat(self, "totalTimeAlive", "PERBODYSTATNAME_TOTALTIMEALIVE", component4.timeAliveReal); SetupTimerStat(self, "runTime", "STAT_RUN_TIME", Run.instance.GetRunStopwatch()); if ((int)component4.strongestMinion != -1) { SetupBodyStat(val3, component4.strongestMinionDamage, component4.strongestMinion, "STAT_MOST_MVPDRONE", "STAT_AMOUNT_MVPDRONE"); } SetupStat(self, "custom_MinionDamageTaken", "STAT_MINION_DAMAGETAKEN", component4.minionDamageTaken); SetupStat(self, "custom_MinionHealthHealed", "STAT_MINION_HEALTHHEALED", component4.minionHealing); SetupStat(self, "custom_ItemsScrapped", "STAT_SCRAPPED_ITEMS", component4.scrappedItems); if (component.isDevotionRun) { SetupStat(self, "totalDronesPurchased", "STAT_DEVOTION_SUMMON", component4.lemuriansHatched); SetupStat(self, "custom_DroneDeaths", "STAT_DEVOTION_DEATHS", component4.minionDeaths); } else { SetupStat(self, "custom_DroneDeaths", "STAT_MINION_DEATH", component4.minionDeaths); SetupStat(self, "custom_DronesScrapped", "STAT_SCRAPPED_DRONES", component4.scrappedDrones); } Transform val8 = SetupStat(self, "custom_SkillUses", "STAT_SKILLS_USED", component4.skillActivations, disableIfNeg: true); Transform val9 = SetupStat(self, "custom_TimesJumped", "STAT_TIMESJUMPED", component4.timesJumped, disableIfNeg: true); SetupStat(self, "custom_LunarCoinsSpent", "STAT_SPENT_LUNARCOIN", component4.spentLunarCoins); SetupStat(self, "custom_DotDamage", "STAT_DAMAGE_DOT", component4.dotDamageDone); Transform val10 = SetupStat(self, "custom_DamageBlocked", "STAT_DAMAGE_BLOCKED", (int)component4.damageBlocked, disableIfNeg: true); if (component4.timesJumped == -1) { if (val9 != null) { ((Component)val9).gameObject.SetActive(false); } if (val10 != null) { ((Component)val10).gameObject.SetActive(false); } if (val8 != null) { ((Component)val8).gameObject.SetActive(false); } } DamagePercentTooltip(FindStatStrip(self, "custom_DotDamage"), totalDamage, component4.dotDamageDone); DamagePercentTooltip(val3, totalDamage, component4.strongestMinionDamage); if (component.addedRunTrackedStats) { return; } component.addedRunTrackedStats = true; RunExtraStatTracker component5 = ((Component)Run.instance).GetComponent(); Transform val11 = SetupStat(self, "custom_ChestsMissed", "STAT_MISSED_CHEST", component5.missedChests); Transform stat = SetupStat(self, "custom_DronesMissed", component.isDevotionRun ? "STAT_DEVOTION_MISSED" : "STAT_MISSED_DRONE", component.isDevotionRun ? component5.missedLemurians : component5.missedDrones); if (Object.op_Implicit((Object)(object)val11)) { TooltipProvider val12 = AddDetailedTooltip_StringDict(val11, component5.missedChests_Dict); if (component5.missedShrineChanceItems > 0) { val12.bodyToken = val12.bodyToken + GetStatFormatted("STAT_MISSED_SHRINECHANCE", component5.missedShrineChanceItems) + "\n"; } AddDetailedTooltip_StringDict(stat, component5.missedDrones_Dict); } } public static Transform MakeBigStat(GameEndReportPanelController panel, GameObject toInstantiate, Transform location) { GameObject val = Object.Instantiate(toInstantiate, location.parent); val.SetActive(true); val.transform.SetSiblingIndex(location.GetSiblingIndex()); ((Object)val).name = ((Object)location).name; panel.statStrips.Add(val); panel.statStrips.Remove(((Component)location).gameObject); Object.Destroy((Object)(object)((Component)location).gameObject); return val.transform; } public static void DamagePercentTooltip(Transform stat, float TotalDamage, float thisDamage) { //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_005c: Unknown result type (might be due to invalid IL or missing references) if (Object.op_Implicit((Object)(object)stat) && TotalDamage != 0f) { TooltipProvider val = ((Component)stat).GetComponent(); if ((Object)(object)val == (Object)null) { val = ((Component)stat).gameObject.AddComponent(); val.titleColor = new Color(0.5339f, 0.4794f, 0.5943f, 1f); } val.overrideBodyText = val.bodyToken + "\n" + string.Format(Language.GetString("TOTALDAMAGE_PERCENTTIP"), $"{thisDamage / TotalDamage * 100f:F2}"); } } public static TooltipProvider AddDetailedTooltip_StringDict(Transform stat, Dictionary data) { //IL_0022: Unknown result type (might be due to invalid IL or missing references) //IL_0027: Unknown result type (might be due to invalid IL or missing references) TooltipProvider val = ((Component)stat).gameObject.AddComponent(); val.titleColor = new Color(0.5339f, 0.4794f, 0.5943f, 1f); val.titleToken = "STAT_DETAILS"; string text = string.Empty; for (int i = 0; data.Count > i; i++) { KeyValuePair keyValuePair = data.ElementAt(i); text = text + GetStatFormatted(keyValuePair.Key, keyValuePair.Value) + "\n"; } val.bodyToken = text; return val; } public static TooltipProvider AddDetailedTooltip_ItemIndex(Transform stat, Dictionary data) { //IL_002e: Unknown result type (might be due to invalid IL or missing references) TooltipProvider component = ((Component)stat).gameObject.GetComponent(); component.titleToken = "STAT_DETAILS"; string text = string.Empty; for (int i = 0; data.Count > i; i++) { KeyValuePair keyValuePair = data.ElementAt(i); text = text + GetStatFormatted(Help.GetColoredName(keyValuePair.Key), keyValuePair.Value) + "\n"; } component.bodyToken = text; return component; } public static void SetupBodyStat(Transform transform, string displayToken, string displayToken2, PlayerInfo playerInfo, PerBodyStatDef stat) { //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_000f: Unknown result type (might be due to invalid IL or missing references) //IL_0011: Invalid comparison between Unknown and I4 //IL_0028: 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) BodyIndex val = Help.FindBodyWithHighestStatNotMasterless(playerInfo.statSheet, stat); if ((int)val != -1) { ulong ulongValue = ((StatField)(ref playerInfo.statSheet.fields[stat.FindStatDef(val).index])).ulongValue; SetupBodyStat(transform, ulongValue, val, displayToken, displayToken2); } else { ((Component)transform).gameObject.SetActive(false); } } public static void SetupBodyStat(Transform transform, float value, BodyIndex bodyIndex, string displayToken, string displayToken2) { //IL_0001: Unknown result type (might be due to invalid IL or missing references) //IL_0003: Invalid comparison between Unknown and I4 //IL_002e: Unknown result type (might be due to invalid IL or missing references) if ((int)bodyIndex == -1) { ((Component)transform).gameObject.SetActive(false); return; } ((Component)transform).gameObject.SetActive(true); CharacterBody val = BodyCatalog.bodyPrefabBodyComponents[bodyIndex]; ((Component)transform.GetChild(0)).GetComponent().token = string.Format(Language.GetString(displayToken), Language.GetString(val.baseNameToken)); ((Component)transform.GetChild(2)).GetComponent().token = string.Format(Language.GetString(displayToken2), TextSerialization.ToStringNumeric(value)); Transform child = transform.GetChild(3); RawImage val2 = default(RawImage); if (!((Component)child).gameObject.TryGetComponent(ref val2)) { Object.DestroyImmediate((Object)(object)((Component)child).GetComponent()); val2 = ((Component)child).gameObject.AddComponent(); } val2.texture = val.portraitIcon; } public static string GetStatFormatted(string displayToken, object value) { return string.Format(Language.GetString("STAT_NAME_VALUE_FORMAT"), Language.GetString(displayToken), value); } public static Transform SetupStat(GameEndReportPanelController self, string lookingFor, string displayToken, float value, bool disableIfNeg = false) { //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) Transform val = FindStatStrip(self, lookingFor); if (!Object.op_Implicit((Object)(object)val)) { return null; } TooltipProvider component = ((Component)val).gameObject.GetComponent(); if ((Object)(object)component == (Object)null) { component = ((Component)val).gameObject.AddComponent(); component.titleColor = new Color(0.5339f, 0.4794f, 0.5943f, 1f); component.titleToken = displayToken; } string arg = TextSerialization.ToStringNumeric(value); if (disableIfNeg && value == -1f) { ((Component)self).gameObject.SetActive(false); } else { ((Component)val).gameObject.SetActive(true); } ((TMP_Text)((Component)val.GetChild(0)).GetComponent()).text = string.Format(Language.GetString("STAT_NAME_VALUE_FORMAT"), Language.GetString(displayToken), arg); ((Component)val.GetChild(1)).gameObject.SetActive(false); return val; } public static void SetupTimerStat(GameEndReportPanelController self, string lookingFor, string statStr, float time) { Transform val = FindStatStrip(self, lookingFor); if (Object.op_Implicit((Object)(object)Run.instance) && Object.op_Implicit((Object)(object)val)) { ulong num = (ulong)time; ulong num2 = num / 60; ulong num3 = num - num2 * 60; ((Component)val).gameObject.SetActive(true); ((TMP_Text)((Component)val.GetChild(0)).GetComponent()).text = string.Format("{2}: {0:00}:{1:00}", num2, num3, Language.GetString(statStr)); } } } public static class ExtraStatsTracking { [CompilerGenerated] private static class <>O { public static hook_RpcDeductLunarCoins <0>__LunarCoinSpentTracking; public static hook_OnStartClient <1>__Add_MinionDamageTracker; public static Action <2>__SendSyncMessages; public static Manipulator <3>__Track_DoTDamage_MinionHurt; public static Manipulator <4>__Track_MinionHealing; public static hook_GiveItemPermanent_ItemIndex_int <5>__RemovingItemDeductFromItemsCollectedStats; public static hook_OnEnter <6>__StoreItemAcqOrderOnMithrixP4; public static hook_OnEnter <7>__ReturnItemAcqOrderAfterMithrixP4; public static Action <8>__Run_onClientGameOverGlobal; public static hook_Start <9>__MissedCallback_Most; public static hook_Start <10>__MissedCallback_Shop; public static hook_Start <11>__MissedCallback_DroneShop; public static hook_OnDestroy <12>__LemurianEggController_OnDestroy; } public static void Start() { //IL_0011: 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_001c: Expected O, but got Unknown //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Unknown result type (might be due to invalid IL or missing references) //IL_003d: Expected O, but got Unknown //IL_0074: Unknown result type (might be due to invalid IL or missing references) //IL_0079: Unknown result type (might be due to invalid IL or missing references) //IL_007f: Expected O, but got Unknown //IL_0095: 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_00a0: Expected O, but got Unknown //IL_00b6: Unknown result type (might be due to invalid IL or missing references) //IL_00bb: Unknown result type (might be due to invalid IL or missing references) //IL_00c1: Expected O, but got Unknown //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_00e2: Expected O, but got Unknown //IL_00f8: Unknown result type (might be due to invalid IL or missing references) //IL_00fd: Unknown result type (might be due to invalid IL or missing references) //IL_0103: Expected O, but got Unknown object obj = <>O.<0>__LunarCoinSpentTracking; if (obj == null) { hook_RpcDeductLunarCoins val = LunarCoinSpentTracking; <>O.<0>__LunarCoinSpentTracking = val; obj = (object)val; } NetworkUser.RpcDeductLunarCoins += (hook_RpcDeductLunarCoins)obj; object obj2 = <>O.<1>__Add_MinionDamageTracker; if (obj2 == null) { hook_OnStartClient val2 = Add_MinionDamageTracker; <>O.<1>__Add_MinionDamageTracker = val2; obj2 = (object)val2; } MinionOwnership.OnStartClient += (hook_OnStartClient)obj2; Run.onClientGameOverGlobal += SendSyncMessages; object obj3 = <>O.<3>__Track_DoTDamage_MinionHurt; if (obj3 == null) { Manipulator val3 = Track_DoTDamage_MinionHurt; <>O.<3>__Track_DoTDamage_MinionHurt = val3; obj3 = (object)val3; } HealthComponent.HandleDamageDealt += (Manipulator)obj3; object obj4 = <>O.<4>__Track_MinionHealing; if (obj4 == null) { Manipulator val4 = Track_MinionHealing; <>O.<4>__Track_MinionHealing = val4; obj4 = (object)val4; } HealthComponent.HandleHeal += (Manipulator)obj4; object obj5 = <>O.<5>__RemovingItemDeductFromItemsCollectedStats; if (obj5 == null) { hook_GiveItemPermanent_ItemIndex_int val5 = RemovingItemDeductFromItemsCollectedStats; <>O.<5>__RemovingItemDeductFromItemsCollectedStats = val5; obj5 = (object)val5; } Inventory.GiveItemPermanent_ItemIndex_int += (hook_GiveItemPermanent_ItemIndex_int)obj5; object obj6 = <>O.<6>__StoreItemAcqOrderOnMithrixP4; if (obj6 == null) { hook_OnEnter val6 = StoreItemAcqOrderOnMithrixP4; <>O.<6>__StoreItemAcqOrderOnMithrixP4 = val6; obj6 = (object)val6; } SpellChannelEnterState.OnEnter += (hook_OnEnter)obj6; object obj7 = <>O.<7>__ReturnItemAcqOrderAfterMithrixP4; if (obj7 == null) { hook_OnEnter val7 = ReturnItemAcqOrderAfterMithrixP4; <>O.<7>__ReturnItemAcqOrderAfterMithrixP4 = val7; obj7 = (object)val7; } TrueDeathState.OnEnter += (hook_OnEnter)obj7; Run.onClientGameOverGlobal += Run_onClientGameOverGlobal; } private static void Run_onClientGameOverGlobal(Run arg1, RunReport arg2) { foreach (PlayerCharacterMasterController instance in PlayerCharacterMasterController.instances) { PerPlayerMaster_ExtraStatTracker component = ((Component)instance).GetComponent(); if (Object.op_Implicit((Object)(object)component)) { component.EvaluateStrongestMinion(); } } MinionMaster_ExtraStatsTracker.minionBodyToTracker.Clear(); } private static void GlobalEventManager_onClientDamageNotified(DamageDealtMessage obj) { Debug.Log((object)obj.victim); if (Object.op_Implicit((Object)(object)obj.attacker) && MinionMaster_ExtraStatsTracker.minionBodyToTracker.TryGetValue(obj.attacker, out var value) && value.bodyIndex != -1) { value.tracker.perMinionDamage[value.bodyIndex] += (ulong)obj.damage; } } private static void ReturnItemAcqOrderAfterMithrixP4(orig_OnEnter orig, TrueDeathState self) { orig.Invoke(self); if (!NetworkServer.active) { return; } foreach (PlayerCharacterMasterController instance in PlayerCharacterMasterController.instances) { ((Component)instance).gameObject.GetComponent()?.Return(); } } private static void StoreItemAcqOrderOnMithrixP4(orig_OnEnter orig, SpellChannelEnterState self) { orig.Invoke(self); if (!NetworkServer.active) { return; } foreach (PlayerCharacterMasterController instance in PlayerCharacterMasterController.instances) { UnityObjectExtensions.EnsureComponent(((Component)instance).gameObject).Store(); } } private static void RemovingItemDeductFromItemsCollectedStats(orig_GiveItemPermanent_ItemIndex_int orig, Inventory self, ItemIndex itemIndex, int countToAdd) { //IL_005e: 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_0014: 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_002b: 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_003c: 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) if (countToAdd < 0) { int itemCountPermanent = self.GetItemCountPermanent(itemIndex); orig.Invoke(self, itemIndex, countToAdd); int itemCountPermanent2 = self.GetItemCountPermanent(itemIndex); StatManager.itemCollectedEvents.Enqueue(new ItemCollectedEvent { inventory = self, itemIndex = itemIndex, quantity = itemCountPermanent2 - itemCountPermanent, newCount = 0 }); } else { orig.Invoke(self, itemIndex, countToAdd); } } private static void Track_DoTDamage_MinionHurt(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown //IL_003d: Unknown result type (might be due to invalid IL or missing references) ILCursor val = new ILCursor(il); if (val.TryGotoNext((MoveType)0, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchStloc(x, 1) })) { val.Emit(OpCodes.Ldloc_0); val.EmitDelegate>((Func)delegate(HealthComponent self, DamageDealtMessage damageEvent) { //IL_0064: Unknown result type (might be due to invalid IL or missing references) //IL_006e: Unknown result type (might be due to invalid IL or missing references) //IL_0073: Unknown result type (might be due to invalid IL or missing references) //IL_00b1: Unknown result type (might be due to invalid IL or missing references) //IL_00b7: Unknown result type (might be due to invalid IL or missing references) //IL_00bc: Unknown result type (might be due to invalid IL or missing references) if (Object.op_Implicit((Object)(object)damageEvent.attacker)) { if (MinionMaster_ExtraStatsTracker.minionBodyToTracker.TryGetValue(damageEvent.attacker, out var value) && value.bodyIndex != -1) { value.tracker.perMinionDamage[value.bodyIndex] += (ulong)damageEvent.damage; } if (DamageTypeCombo.op_Implicit(damageEvent.damageType & DamageTypeCombo.op_Implicit((DamageType)67108864)) != 0L && Object.op_Implicit((Object)(object)self) && PerPlayerMaster_ExtraStatTracker.playerBodyToTracker.TryGetValue(damageEvent.attacker, out var value2) && (self.health != 1f || DamageTypeCombo.op_Implicit(damageEvent.damageType & DamageTypeCombo.op_Implicit((DamageType)1)) == 0)) { value2.dotDamageDone += (ulong)damageEvent.damage; } } if (MinionMaster_ExtraStatsTracker.minionBodyToTracker.TryGetValue(damageEvent.victim, out var value3)) { value3.tracker.minionDamageTaken += (ulong)damageEvent.damage; } return self; }); } else { Log.LogWarning("IL Failed: Track_DoTDamage_MinionHurt"); } } private static void Track_MinionHealing(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown ILCursor val = new ILCursor(il); if (val.TryGotoNext((MoveType)0, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchStloc(x, 0) })) { val.EmitDelegate>((Func)delegate(HealMessage healEvent) { if (MinionMaster_ExtraStatsTracker.minionBodyToTracker.TryGetValue(healEvent.target, out var value)) { value.tracker.minionHealing += (ulong)healEvent.amount; } return healEvent; }); } else { Log.LogWarning("IL Failed: HealthComponent_HandleHeal"); } } public static void SendSyncMessages(Run arg1, RunReport arg2) { foreach (PlayerCharacterMasterController instance in PlayerCharacterMasterController.instances) { Networker.SendWQoLMessage((ChatMessageBase)(object)new PerPlayerMaster_ExtraStatTracker.SyncValues { masterObject = ((Component)instance).gameObject }); } } private static void Add_MinionDamageTracker(orig_OnStartClient orig, MinionOwnership self) { orig.Invoke(self); if (Object.op_Implicit((Object)(object)self.ownerMaster) && (Object)(object)self.ownerMaster.playerCharacterMasterController != (Object)null && (Object)(object)((Component)self).GetComponent() == (Object)null) { ((Component)self).gameObject.AddComponent(); } } private static void LunarCoinSpentTracking(orig_RpcDeductLunarCoins orig, NetworkUser self, uint count) { orig.Invoke(self, count); if (Object.op_Implicit((Object)(object)self.master)) { ((Component)self.master).GetComponent().spentLunarCoins += (int)count; } } public static void Start_Missed() { //IL_0011: 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_001c: Expected O, but got Unknown //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Unknown result type (might be due to invalid IL or missing references) //IL_003d: Expected O, but got Unknown //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_005e: Expected O, but got Unknown //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_00a7: Unknown result type (might be due to invalid IL or missing references) //IL_00ac: Unknown result type (might be due to invalid IL or missing references) //IL_0074: Unknown result type (might be due to invalid IL or missing references) //IL_0079: Unknown result type (might be due to invalid IL or missing references) //IL_007f: Expected O, but got Unknown object obj = <>O.<9>__MissedCallback_Most; if (obj == null) { hook_Start val = MissedCallback_Most; <>O.<9>__MissedCallback_Most = val; obj = (object)val; } PurchaseInteraction.Start += (hook_Start)obj; object obj2 = <>O.<10>__MissedCallback_Shop; if (obj2 == null) { hook_Start val2 = MissedCallback_Shop; <>O.<10>__MissedCallback_Shop = val2; obj2 = (object)val2; } MultiShopController.Start += (hook_Start)obj2; object obj3 = <>O.<11>__MissedCallback_DroneShop; if (obj3 == null) { hook_Start val3 = MissedCallback_DroneShop; <>O.<11>__MissedCallback_DroneShop = val3; obj3 = (object)val3; } DroneVendorMultiShopController.Start += (hook_Start)obj3; object obj4 = <>O.<12>__LemurianEggController_OnDestroy; if (obj4 == null) { hook_OnDestroy val4 = LemurianEggController_OnDestroy; <>O.<12>__LemurianEggController_OnDestroy = val4; obj4 = (object)val4; } LemurianEggController.OnDestroy += (hook_OnDestroy)obj4; Addressables.LoadAssetAsync((object)"fd68bfe758b25714288565a552d40d83").WaitForCompletion().AddComponent() .type = OnDestroyMissedInteractable.Cases.Chest; Addressables.LoadAssetAsync((object)"d31df5066858329458b33f21b3b22d2e").WaitForCompletion().AddComponent() .type = OnDestroyMissedInteractable.Cases.Chest; } private static void MissedCallback_Most(orig_Start orig, PurchaseInteraction self) { //IL_0068: Unknown result type (might be due to invalid IL or missing references) //IL_006e: Invalid comparison between Unknown and I4 //IL_00b5: Unknown result type (might be due to invalid IL or missing references) //IL_00bc: Invalid comparison between Unknown and I4 orig.Invoke(self); if (!((Component)self).gameObject.activeInHierarchy) { return; } ShrineChanceBehavior val = default(ShrineChanceBehavior); if (((Component)self).TryGetComponent(ref val)) { ((Component)self).gameObject.AddComponent().type = OnDestroyMissedInteractable.Cases.ShrineChance; } else if (Object.op_Implicit((Object)(object)((Component)self).GetComponent())) { ((Component)self).gameObject.AddComponent().type = OnDestroyMissedInteractable.Cases.Drone; } else { if ((int)self.costType == 3) { return; } bool flag = false; ChestBehavior val2 = default(ChestBehavior); if (((Component)self).TryGetComponent(ref val2)) { if (Object.op_Implicit((Object)(object)val2.dropTable)) { flag = true; } if (SceneCatalog.mostRecentSceneDef.isFinalStage) { flag = (int)self.costType == 12; } } if (flag || Object.op_Implicit((Object)(object)((Component)self).GetComponent())) { ((Component)self).gameObject.AddComponent().type = OnDestroyMissedInteractable.Cases.Chest; } } } private static void LemurianEggController_OnDestroy(orig_OnDestroy orig, LemurianEggController self) { orig.Invoke(self); if (((Component)self).GetComponent().available && Object.op_Implicit((Object)(object)RunExtraStatTracker.instance)) { RunExtraStatTracker.instance.missedLemurians++; } } private static void MissedCallback_DroneShop(orig_Start orig, DroneVendorMultiShopController self) { orig.Invoke(self); if (((Component)self).gameObject.activeInHierarchy) { ((Component)self).gameObject.AddComponent().type = OnDestroyMissedInteractable.Cases.DroneShop; } } private static void MissedCallback_Shop(orig_Start orig, MultiShopController self) { orig.Invoke(self); if (((Component)self).gameObject.activeInHierarchy) { ((Component)self).gameObject.AddComponent().type = OnDestroyMissedInteractable.Cases.MultiShop; } } } public class RunExtraStatTracker : MonoBehaviour { public static RunExtraStatTracker instance; public bool alreadyCountedDronesForStage = false; public Dictionary missedChests_Dict; public Dictionary missedDrones_Dict; public GameObject latestWaveUiPrefab; public int missedChests = 0; public int missedShrineChanceItems = 0; public int missedDrones; public int missedLemurians; public bool expectingLoop = false; public bool isSaveAndContinuedRun = false; public List visitedScenes; public int lastSeenLoopCount = 0; public void OnEnable() { instance = this; missedChests_Dict = new Dictionary(); missedDrones_Dict = new Dictionary(); visitedScenes = new List(); SceneCatalog.onMostRecentSceneDefChanged += HandleMostRecentSceneDefChanged; isSaveAndContinuedRun = ((Component)this).GetComponent().stageClearCount != 0; } public void OnDisable() { instance = null; SceneCatalog.onMostRecentSceneDefChanged -= HandleMostRecentSceneDefChanged; } public void TestUnlocks(int amount = 5) { int num = 0; while (num < amount) { int num2 = Run.instance.runRNG.RangeInt(0, UnlockableCatalog.unlockableCount); UnlockableDef unlockableDef = UnlockableCatalog.GetUnlockableDef((UnlockableIndex)num2); if (unlockableDef.hidden) { continue; } num++; foreach (NetworkUser readOnlyInstances in NetworkUser.readOnlyInstancesList) { if (readOnlyInstances.isParticipating) { readOnlyInstances.ServerHandleUnlock(unlockableDef); } } } } public unsafe void TestStageList(int amount = 19) { //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_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_003b: Unknown result type (might be due to invalid IL or missing references) //IL_0040: Unknown result type (might be due to invalid IL or missing references) //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) int num = 0; int num2 = 2; while (num < amount) { SceneDef val = (SceneDef)Unsafe.Read((void*)SceneCatalog.allStageSceneDefs[Run.instance.runRNG.RangeInt(0, SceneCatalog.allStageSceneDefs.Length)]); while (val.stageOrder != num2) { val = (SceneDef)Unsafe.Read((void*)SceneCatalog.allStageSceneDefs[Run.instance.runRNG.RangeInt(0, SceneCatalog.allStageSceneDefs.Length)]); } num++; num2++; if (num2 == 6) { num2 = 1; } visitedScenes.Add(val); } } public void TestStageList_LongestLegitRun() { visitedScenes = new List { SceneCatalog.FindSceneDef("golemplains"), SceneCatalog.FindSceneDef("bazaar"), SceneCatalog.FindSceneDef("goldshores"), SceneCatalog.FindSceneDef("goolake"), SceneCatalog.FindSceneDef("bazaar"), SceneCatalog.FindSceneDef("arena"), SceneCatalog.FindSceneDef("frozenwall"), SceneCatalog.FindSceneDef("bazaar"), SceneCatalog.FindSceneDef("meridian"), SceneCatalog.FindSceneDef("conduitcanyon"), SceneCatalog.FindSceneDef("solutionalhaunt"), SceneCatalog.FindSceneDef("computationalexchange"), SceneCatalog.FindSceneDef("solusweb"), SceneCatalog.FindSceneDef("skymeadow"), SceneCatalog.FindSceneDef("moon2"), SceneCatalog.FindSceneDef("voidraid") }; } private void HandleMostRecentSceneDefChanged(SceneDef newSceneDef) { //IL_0015: 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: Invalid comparison between Unknown and I4 //IL_0026: Unknown result type (might be due to invalid IL or missing references) //IL_002c: Invalid comparison between Unknown and I4 //IL_004c: Unknown result type (might be due to invalid IL or missing references) //IL_0052: Invalid comparison between Unknown and I4 if (newSceneDef.stageOrder == 0 || (int)newSceneDef.sceneType == 0 || (int)newSceneDef.sceneType == 3 || (int)newSceneDef.sceneType == -1) { return; } alreadyCountedDronesForStage = false; if ((int)Run.instance.ruleBook.stageOrder == 0) { if (newSceneDef.stageOrder == 5) { expectingLoop = true; lastSeenLoopCount = Run.instance.loopClearCount; } else if (newSceneDef.stageOrder == 1 && expectingLoop) { expectingLoop = false; } } else { if (lastSeenLoopCount != Run.instance.loopClearCount) { expectingLoop = true; lastSeenLoopCount = Run.instance.loopClearCount; } if (expectingLoop && newSceneDef.stageOrder < 6) { expectingLoop = false; } } visitedScenes.Add(newSceneDef); } } public class PerPlayerMaster_ExtraStatTracker : MonoBehaviour { public class SyncValues : ChatMessageBase { public GameObject masterObject; public override string ConstructChatString() { return null; } public override void Serialize(NetworkWriter writer) { ((ChatMessageBase)this).Serialize(writer); writer.Write(masterObject); PerPlayerMaster_ExtraStatTracker perPlayerMaster_ExtraStatTracker = UnityObjectExtensions.EnsureComponent(masterObject); writer.Write(perPlayerMaster_ExtraStatTracker.skillActivations); writer.Write(perPlayerMaster_ExtraStatTracker.timesJumped); writer.Write(perPlayerMaster_ExtraStatTracker.damageBlocked); } public override void Deserialize(NetworkReader reader) { if (!WQoLMain.NoHostInfo) { ((ChatMessageBase)this).Deserialize(reader); masterObject = reader.ReadGameObject(); if ((Object)(object)masterObject == (Object)null) { Log.LogWarning("No Master"); return; } PerPlayerMaster_ExtraStatTracker perPlayerMaster_ExtraStatTracker = UnityObjectExtensions.EnsureComponent(masterObject); perPlayerMaster_ExtraStatTracker.skillActivations = Mathf.Max(perPlayerMaster_ExtraStatTracker.skillActivations, reader.ReadInt32()); perPlayerMaster_ExtraStatTracker.timesJumped = Mathf.Max(perPlayerMaster_ExtraStatTracker.timesJumped, reader.ReadInt32()); perPlayerMaster_ExtraStatTracker.damageBlocked = Math.Max(perPlayerMaster_ExtraStatTracker.damageBlocked, reader.ReadUInt64()); } } } public static Dictionary playerBodyToTracker = new Dictionary(); public bool gameOverWhileDisabled = false; public float timeAliveReal; public int skillActivations; public ulong[] perMinionDamage; public BodyIndex strongestMinion = (BodyIndex)(-2); public ulong strongestMinionDamage; public int timesJumped; public ulong minionDamageTaken; public ulong minionHealing; public int minionDeaths; public int spentLunarCoins; public int scrappedItems; public int scrappedDrones; public int lemuriansHatched; public ulong dotDamageDone; public ulong damageBlocked; public string latestDetailedDeathMessage; public float[] itemDurationPercent; public Dictionary scrappedItemsDict; public Dictionary scrappedDronesDict; public List equipmentHistory; public EquipmentIndex lastSeenEquip = (EquipmentIndex)(-1); public CharacterMaster master; private int checkEquipSwap = 0; private GameObject lastSeenBody; public void OnEnable() { //IL_0047: Unknown result type (might be due to invalid IL or missing references) //IL_0051: Expected O, but got Unknown perMinionDamage = new ulong[BodyCatalog.bodyCount]; master = ((Component)this).GetComponent(); master.onBodyStart += OnBodyStart; master.onBodyDeath.AddListener(new UnityAction(OnBodyDeath)); scrappedItemsDict = new Dictionary(); scrappedDronesDict = new Dictionary(); equipmentHistory = new List(); } private void EquipmentHistoryOrSmth() { //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_0027: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Invalid comparison between Unknown and I4 //IL_0045: 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_006e: 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_00bc: Unknown result type (might be due to invalid IL or missing references) if (!master.inventory.wasRecentlyExtraEquipmentSwapped && (int)master.inventory.currentEquipmentIndex != -1 && master.inventory.currentEquipmentIndex != lastSeenEquip) { equipmentHistory.Add(master.inventory.currentEquipmentIndex); if (checkEquipSwap < equipmentHistory.Count && equipmentHistory[equipmentHistory.Count - 3] == equipmentHistory[equipmentHistory.Count - 1]) { Log.LogMessage("Swapped Equips"); equipmentHistory.RemoveAt(equipmentHistory.Count - 2); equipmentHistory.RemoveAt(equipmentHistory.Count - 1); } } lastSeenEquip = master.inventory.currentEquipmentIndex; } public void OnDisable() { //IL_0023: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Expected O, but got Unknown if (Object.op_Implicit((Object)(object)master)) { master.onBodyDeath.RemoveListener(new UnityAction(OnBodyDeath)); master.onBodyStart -= OnBodyStart; } } private void OnBodyStart(CharacterBody body) { latestDetailedDeathMessage = string.Empty; itemDurationPercent = null; checkEquipSwap = equipmentHistory.Count + 2; ((Component)body).gameObject.AddComponent().tracker = this; if (Object.op_Implicit((Object)(object)lastSeenBody)) { playerBodyToTracker.Remove(lastSeenBody); } else { GameObject[] array = playerBodyToTracker.Keys.ToArray(); foreach (GameObject val in array) { if ((Object)(object)val == (Object)null) { playerBodyToTracker.Remove(val); } } } lastSeenBody = ((Component)body).gameObject; playerBodyToTracker.Add(((Component)body).gameObject, this); } public void OnBodyDeath() { if (Object.op_Implicit((Object)(object)master)) { Inventory inventory = master.inventory; if ((Object)(object)inventory != (Object)null) { itemDurationPercent = new float[ItemCatalog.itemCount]; inventory.WriteAllTempItemDecayValues((Span)itemDurationPercent); } } } public void FixedUpdate() { if (master.hasBody) { timeAliveReal += Time.fixedDeltaTime; } } public void Start() { if (!master.hasEffectiveAuthority) { skillActivations = -1; timesJumped = -1; damageBlocked = 0uL; } } public void CombineSimiliarMinions() { //IL_0006: Unknown result type (might be due to invalid IL or missing references) //IL_000c: Expected I4, but got Unknown //IL_0011: Unknown result type (might be due to invalid IL or missing references) //IL_0017: Expected I4, but got Unknown //IL_001c: Unknown result type (might be due to invalid IL or missing references) //IL_0022: Expected I4, but got Unknown //IL_0093: Unknown result type (might be due to invalid IL or missing references) //IL_009a: Expected I4, but got Unknown //IL_009f: Unknown result type (might be due to invalid IL or missing references) //IL_00a6: Expected I4, but got Unknown int num = (int)BodyPrefabs.NullifierAllyBody.bodyIndex; int num2 = (int)BodyPrefabs.VoidJailerAllyBody.bodyIndex; int num3 = (int)BodyPrefabs.VoidMegaCrabAllyBody.bodyIndex; ulong num4 = perMinionDamage[num] + perMinionDamage[num2] + perMinionDamage[num3]; if (perMinionDamage[num] != 0) { perMinionDamage[num] = num4; } if (perMinionDamage[num2] != 0) { perMinionDamage[num2] = num4; } if (perMinionDamage[num3] != 0) { perMinionDamage[num3] = num4; } int num5 = (int)BodyPrefabs.RoboBallRedBuddyBody.bodyIndex; int num6 = (int)BodyPrefabs.RoboBallGreenBuddyBody.bodyIndex; ulong num7 = perMinionDamage[num5] + perMinionDamage[num6]; perMinionDamage[num5] = num7; perMinionDamage[num6] = num7; } public void EvaluateStrongestMinion() { //IL_003f: Unknown result type (might be due to invalid IL or missing references) ulong num = 0uL; int num2 = -1; for (int i = 0; i < perMinionDamage.Length; i++) { if (perMinionDamage[i] > num) { num = perMinionDamage[i]; num2 = i; } } strongestMinion = (BodyIndex)num2; strongestMinionDamage = num; } public void AddAllMinionDamageToStats() { for (int i = 0; i < perMinionDamage.Length; i++) { if (perMinionDamage[i] != 0) { WStats.AddStat(i, perMinionDamage[i]); } } } } public class PerPlayerBody_Tracker : MonoBehaviour, IOnTakeDamageServerReceiver, IOnIncomingDamageServerReceiver { public PerPlayerMaster_ExtraStatTracker tracker; public CharacterBody body; public void OnEnable() { //IL_0057: Unknown result type (might be due to invalid IL or missing references) //IL_0061: Expected O, but got Unknown //IL_0061: Unknown result type (might be due to invalid IL or missing references) //IL_006b: Expected O, but got Unknown ((Component)this).GetComponent().onIncomingDamageReceivers = ((Component)this).GetComponents(); ((Component)this).GetComponent().onTakeDamageReceivers = ((Component)this).GetComponents(); body = ((Component)this).GetComponent(); if (body.master.hasEffectiveAuthority) { CharacterBody obj = body; obj.onJump = (JumpDelegate)Delegate.Combine((Delegate?)(object)obj.onJump, (Delegate?)new JumpDelegate(OnJump)); body.onSkillActivatedAuthority += onSkillActivatedAuthority; } } public void OnDisable() { //IL_004b: Unknown result type (might be due to invalid IL or missing references) //IL_0055: Expected O, but got Unknown //IL_0055: Unknown result type (might be due to invalid IL or missing references) //IL_005f: Expected O, but got Unknown if (Object.op_Implicit((Object)(object)body) && Object.op_Implicit((Object)(object)body.master) && body.master.hasEffectiveAuthority) { CharacterBody obj = body; obj.onJump = (JumpDelegate)Delegate.Remove((Delegate?)(object)obj.onJump, (Delegate?)new JumpDelegate(OnJump)); body.onSkillActivatedAuthority -= onSkillActivatedAuthority; } } private void onSkillActivatedAuthority(GenericSkill obj) { tracker.skillActivations++; } public void OnJump() { tracker.timesJumped++; } public void OnIncomingDamageServer(DamageInfo damageInfo) { if (damageInfo.rejected) { tracker.damageBlocked += (ulong)damageInfo.damage; } } public void OnTakeDamageServer(DamageReport damageReport) { if (damageReport.damageInfo.damage != damageReport.damageDealt) { tracker.damageBlocked += (ulong)(damageReport.damageInfo.damage - damageReport.damageDealt); } } } public class MinionMaster_ExtraStatsTracker : MonoBehaviour { public static Dictionary minionBodyToTracker = new Dictionary(); public PerPlayerMaster_ExtraStatTracker tracker; public CharacterMaster master; public GameObject bodyObject; public int bodyIndex = -1; public void OnEnable() { //IL_0052: Unknown result type (might be due to invalid IL or missing references) //IL_005c: Expected O, but got Unknown master = ((Component)this).GetComponent(); tracker = ((Component)master.minionOwnership.ownerMaster).GetComponent(); master.onBodyStart += OnBodyStart; master.onBodyDeath.AddListener(new UnityAction(OnBodyDeath)); } public void OnDisable() { //IL_0023: Unknown result type (might be due to invalid IL or missing references) //IL_002d: Expected O, but got Unknown if (Object.op_Implicit((Object)(object)master)) { master.onBodyDeath.RemoveListener(new UnityAction(OnBodyDeath)); } } private void OnBodyStart(CharacterBody newBody) { //IL_0075: Unknown result type (might be due to invalid IL or missing references) //IL_007f: Expected I4, but got Unknown if (Object.op_Implicit((Object)(object)bodyObject)) { minionBodyToTracker.Remove(bodyObject); } else { GameObject[] array = minionBodyToTracker.Keys.ToArray(); foreach (GameObject val in array) { if ((Object)(object)val == (Object)null) { minionBodyToTracker.Remove(val); } } } bodyObject = ((Component)newBody).gameObject; bodyIndex = (int)newBody.bodyIndex; minionBodyToTracker.Add(bodyObject, this); } public void OnBodyDeath() { if (Object.op_Implicit((Object)(object)bodyObject) && DroneCollection.isPermamentMinion(((Component)this).gameObject)) { Log.LogMessage(((Object)((Component)this).gameObject).name + " died"); tracker.minionDeaths++; } } } public class OnDestroyMissedInteractable : MonoBehaviour { public enum Cases { None = -1, Chest, Drone, ShrineChance, LemEgg, MultiShop, DroneShop } public Cases type; public void OnDestroy() { if (!Object.op_Implicit((Object)(object)RunExtraStatTracker.instance)) { return; } Cases cases = Cases.None; IDisplayNameProvider component = ((Component)this).GetComponent(); if (component == null) { return; } string displayName = component.GetDisplayName(); if (type < Cases.LemEgg) { if (((Component)this).GetComponent().available) { switch (type) { case Cases.Chest: cases = Cases.Chest; break; case Cases.Drone: cases = Cases.Drone; break; case Cases.ShrineChance: { ShrineChanceBehavior component2 = ((Component)this).GetComponent(); RunExtraStatTracker.instance.missedShrineChanceItems += component2.maxPurchaseCount - component2.successfulPurchaseCount; break; } } } } else if (type == Cases.MultiShop) { if (((Component)this).GetComponent().available) { cases = Cases.Chest; } } else if (type == Cases.Drone && ((Component)this).GetComponent().available) { cases = Cases.Drone; } switch (cases) { case Cases.Chest: RunExtraStatTracker.instance.missedChests++; if (RunExtraStatTracker.instance.missedChests_Dict.ContainsKey(displayName)) { RunExtraStatTracker.instance.missedChests_Dict[displayName]++; } else { RunExtraStatTracker.instance.missedChests_Dict.Add(displayName, 1); } break; case Cases.Drone: RunExtraStatTracker.instance.missedDrones++; if (RunExtraStatTracker.instance.missedDrones_Dict.ContainsKey(displayName)) { RunExtraStatTracker.instance.missedDrones_Dict[displayName]++; } else { RunExtraStatTracker.instance.missedDrones_Dict.Add(displayName, 1); } break; } } } public static class Inventory_Killer { public static void AddKillerInventory(GameEndReportPanelController self, PlayerInfo playerInfo) { //IL_0154: Unknown result type (might be due to invalid IL or missing references) //IL_0185: Unknown result type (might be due to invalid IL or missing references) //IL_018b: Invalid comparison between Unknown and I4 //IL_0171: 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_020e: 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_0320: Unknown result type (might be due to invalid IL or missing references) //IL_0250: Unknown result type (might be due to invalid IL or missing references) //IL_027f: Unknown result type (might be due to invalid IL or missing references) if (!Object.op_Implicit((Object)(object)Run.instance)) { return; } DeathScreenExpanded component = ((Component)self).GetComponent(); if ((Object)(object)component.killerInventory == (Object)null) { GameObject val = component.MakeInventory(); ((Object)val).name = "KillerItemArea"; component.killerInventory = val; val.SetActive(true); } if ((Object)(object)playerInfo.networkUser == (Object)null) { component.killerInventory.SetActive(false); Log.LogWarning("Killer Inventory : No NetworkUser"); return; } KillerInventoryInfoStorage killerInventoryInfoStorage = ((Component)playerInfo.master).GetComponent(); if ((Object)(object)killerInventoryInfoStorage == (Object)null) { Log.LogMessage("No GameEndInventoryHelper Found, Making One"); killerInventoryInfoStorage = ((Component)playerInfo.master).gameObject.AddComponent(); killerInventoryInfoStorage.victimMaster = ((Component)playerInfo.master).gameObject; } Log.LogMessage("Applying Killer Inventory Screen"); if (killerInventoryInfoStorage.killerName != "") { string text = string.Format(Language.GetString("STAT_KILLER_NAME_FORMAT"), killerInventoryInfoStorage.killerName); ((TMP_Text)self.killerBodyLabel).SetText(text, true); } ((TMP_Text)self.playerBodyLabel).alignment = (TextAlignmentOptions)513; if (!WConfig.DC_KillerInventory.Value) { component.killerInventory.SetActive(false); return; } if (self.displayData.runReport.gameEnding.isWin) { killerInventoryInfoStorage.primaryEquipment = (EquipmentIndex)(-1); killerInventoryInfoStorage.itemAcquisitionOrder = new List(); } bool flag = false; bool flag2 = (int)killerInventoryInfoStorage.primaryEquipment != -1 && ((Object)(object)EquipmentCatalog.GetEquipmentDef(killerInventoryInfoStorage.primaryEquipment).passiveBuffDef == (Object)null || WConfig.DC_KillerInventory_EvenIfJustElite.Value); if (killerInventoryInfoStorage.itemAcquisitionOrder.Count == 0 && !flag2) { Log.LogMessage("Could not find Killer Inventory or Inventory empty"); if (RunArtifactManager.instance.IsArtifactEnabled(Artifacts.monsterTeamGainsItemsArtifactDef)) { flag = true; if (Object.op_Implicit((Object)(object)MonsterTeamGainsItemsArtifactManager.monsterTeamInventory)) { killerInventoryInfoStorage.AddItemsFrom(MonsterTeamGainsItemsArtifactManager.monsterTeamInventory.permanentItemStacks, ItemFilters.AllowAllItemFilterDelegate); } } if (Object.op_Implicit((Object)(object)Run.instance) && Run.instance is InfiniteTowerRun) { flag = true; killerInventoryInfoStorage.AddItemsFrom(((Component)Run.instance).GetComponent().permanentItemStacks, ItemFilters.AllowAllItemFilterDelegate); } if (Object.op_Implicit((Object)(object)ArenaMissionController.instance)) { flag = true; killerInventoryInfoStorage.AddItemsFrom(((Component)ArenaMissionController.instance).GetComponent().permanentItemStacks, ItemFilters.AllowAllItemFilterDelegate); } } component.IsEvoInventory = flag; if (flag) { ((Component)component.killerInventory.transform.GetChild(0).GetChild(0)).GetComponent().token = "INVENTORY_MONSTER"; } else { ((Component)component.killerInventory.transform.GetChild(0).GetChild(0)).GetComponent().token = "INVENTORY_KILLER"; } if (killerInventoryInfoStorage.itemAcquisitionOrder.Count != 0 || flag2) { self.itemInventoryDisplay.maxHeight = 256f; EquipOnDeathInventory.DeathEquip_Enemy1 = killerInventoryInfoStorage.primaryEquipment; component.killerInventory.SetActive(true); ItemInventoryDisplay componentInChildren = component.killerInventory.GetComponentInChildren(); componentInChildren.SetItems(killerInventoryInfoStorage.itemAcquisitionOrder, killerInventoryInfoStorage.itemStacks); componentInChildren.UpdateDisplay(); } else { component.killerInventory.SetActive(false); if (Object.op_Implicit((Object)(object)component.killerInventory)) { ItemInventoryDisplay componentInChildren2 = component.killerInventory.GetComponentInChildren(); componentInChildren2.ResetItems(); } } } } public class KillerInventoryMessage : ChatMessageBase { public string killerBackupName; public GameObject attackerObject; public GameObject victimMaster; public ItemCollection itemStacks = ItemCollection.Create(); public EquipmentIndex[] equipmentStacks; public EquipmentIndex primaryEquipment = (EquipmentIndex)(-1); public EquipmentIndex secondaryEquipment = (EquipmentIndex)(-1); public override string ConstructChatString() { //IL_0067: 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_0073: Unknown result type (might be due to invalid IL or missing references) if ((Object)(object)attackerObject != (Object)null) { killerBackupName = Util.GetBestBodyName(attackerObject); killerBackupName = killerBackupName.Replace("\n", " "); } else { killerBackupName = Language.GetString(killerBackupName); } KillerInventoryInfoStorage.SetupFromData(killerBackupName, attackerObject, victimMaster, itemStacks, primaryEquipment, secondaryEquipment, killerNoMaster: false); return null; } public override void Serialize(NetworkWriter writer) { //IL_0032: 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) ((ChatMessageBase)this).Serialize(writer); writer.Write(killerBackupName); writer.Write(attackerObject); writer.Write(victimMaster); NetworkExtensions.Write(writer, primaryEquipment); NetworkExtensions.Write(writer, secondaryEquipment); ((ItemCollection)(ref itemStacks)).Serialize(writer); } public override void Deserialize(NetworkReader reader) { //IL_003b: Unknown result type (might be due to invalid IL or missing references) //IL_0040: Unknown result type (might be due to invalid IL or missing references) //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) if (!WQoLMain.NoHostInfo) { ((ChatMessageBase)this).Deserialize(reader); killerBackupName = reader.ReadString(); attackerObject = reader.ReadGameObject(); victimMaster = reader.ReadGameObject(); primaryEquipment = NetworkExtensions.ReadEquipmentIndex(reader); secondaryEquipment = NetworkExtensions.ReadEquipmentIndex(reader); ((ItemCollection)(ref itemStacks)).Deserialize(reader); } } } public class KillerInventoryInfoStorage : MonoBehaviour { public string killerName = "The Planet"; public GameObject killerObject; public GameObject victimMaster; public List itemAcquisitionOrder = new List(); public int[] itemStacks = ItemCatalog.RequestItemStackArray(); public EquipmentIndex primaryEquipment = (EquipmentIndex)(-1); public EquipmentIndex secondaryEquipment = (EquipmentIndex)(-1); private bool overwrittenByWin = false; public bool killerNoMaster = false; public static void SetupFromData(string killerName, GameObject killerObject, GameObject victimMaster, ItemCollection itemStacks, EquipmentIndex primaryEquipment, EquipmentIndex secondaryEquipment, bool killerNoMaster) { //IL_0080: Unknown result type (might be due to invalid IL or missing references) //IL_0082: Unknown result type (might be due to invalid IL or missing references) //IL_0088: 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_0090: Unknown result type (might be due to invalid IL or missing references) Log.LogMessage("GameEndInventoryHelp : SetupFromData"); if ((Object)(object)victimMaster == (Object)null) { Log.LogWarning("GameEndInventoryHelper : Victim Object is null"); return; } KillerInventoryInfoStorage[] components = victimMaster.GetComponents(); if (components.Length != 0) { for (int i = 0; i < components.Length; i++) { Object.DestroyImmediate((Object)(object)components[i]); } } KillerInventoryInfoStorage killerInventoryInfoStorage = victimMaster.AddComponent(); killerInventoryInfoStorage.victimMaster = victimMaster; killerInventoryInfoStorage.killerName = killerName; killerInventoryInfoStorage.killerObject = killerObject; killerInventoryInfoStorage.killerNoMaster = killerNoMaster; killerInventoryInfoStorage.primaryEquipment = primaryEquipment; killerInventoryInfoStorage.secondaryEquipment = secondaryEquipment; killerInventoryInfoStorage.AddItemsFrom(itemStacks, ItemFilters.NoTierDeathItemFilterDelegate); } public void AddItemsFrom(ItemCollection otherItemStacks, Func filter) { //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_001a: Unknown result type (might be due to invalid IL or missing references) //IL_001f: Unknown result type (might be due to invalid IL or missing references) //IL_0022: 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_004c: 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_005e: Unknown result type (might be due to invalid IL or missing references) List list = default(List); DisposableRental> val = CollectionPool>.RentCollection(ref list); try { ((ItemCollection)(ref otherItemStacks)).GetNonZeroIndices(list); for (int i = 0; i < otherItemStacks.inner.nonDefaultIndicesCount; i++) { ItemIndex val2 = list[i]; int stackValue = ((ItemCollection)(ref otherItemStacks)).GetStackValue(val2); if (stackValue > 0 && filter(list[i])) { if (itemStacks[val2] == 0) { itemAcquisitionOrder.Add(val2); } itemStacks[val2] += stackValue; } } } finally { val.Dispose(); } } } public static class Inventory_Minions { public static void Hooks() { Run.onClientGameOverGlobal += CountOnGameover; ExtraActions.onMithrixPhase1 = (Action)Delegate.Combine(ExtraActions.onMithrixPhase1, new Action(Count)); ExtraActions.onVoidlingPhase1 = (Action)Delegate.Combine(ExtraActions.onVoidlingPhase1, new Action(Count)); ExtraActions.onFalseSonPhase1 = (Action)Delegate.Combine(ExtraActions.onFalseSonPhase1, new Action(Count)); ExtraActions.onSolusWing = (Action)Delegate.Combine(ExtraActions.onSolusWing, new Action(Count)); ExtraActions.onSolusHeart = (Action)Delegate.Combine(ExtraActions.onSolusHeart, new Action(Count)); } public static void Count() { if (!Object.op_Implicit((Object)(object)RunExtraStatTracker.instance) || RunExtraStatTracker.instance.alreadyCountedDronesForStage) { return; } RunExtraStatTracker.instance.alreadyCountedDronesForStage = true; foreach (PlayerCharacterMasterController instance in PlayerCharacterMasterController.instances) { if (Object.op_Implicit((Object)(object)instance)) { UnityObjectExtensions.EnsureComponent(((Component)instance).gameObject).CountDrones(); } } } public static void CountOnGameover(Run run, RunReport runReport) { Count(); } public static void AddMinionInventory(GameEndReportPanelController self, PlayerInfo playerInfo) { if (!Object.op_Implicit((Object)(object)Run.instance)) { return; } DeathScreenExpanded component = ((Component)self).GetComponent(); if ((Object)(object)component.minionInventory == (Object)null) { GameObject val = component.MakeInventory(); ((Object)val).name = "DroneCollection"; LayoutElement component2 = val.GetComponent(); ItemInventoryDisplay componentInChildren = val.GetComponentInChildren(); component.minionInventory = val; DroneCollectionDisplay droneCollectionDisplay = ((Component)componentInChildren).gameObject.AddComponent(); droneCollectionDisplay.root = val; } if ((Object)(object)playerInfo.master == (Object)null) { component.minionInventory.SetActive(false); return; } DroneCollection component3 = ((Component)playerInfo.master).GetComponent(); if ((Object)(object)component3 == (Object)null) { component.minionInventory.SetActive(false); return; } if (component3.hasDevotion && component3.hasDrones) { ((Component)component.minionInventory.transform.GetChild(0).GetChild(0)).GetComponent().token = "INVENTORY_DEVOTIONDRONE"; } else if (component3.hasDevotion) { ((Component)component.minionInventory.transform.GetChild(0).GetChild(0)).GetComponent().token = "INVENTORY_DEVOTION"; } else { ((Component)component.minionInventory.transform.GetChild(0).GetChild(0)).GetComponent().token = "INVENTORY_DRONES"; } component.minionInventory.GetComponentInChildren().Display(component3); } } public class DroneCollectionDisplay : MonoBehaviour { public ItemInventoryDisplay itemDisplay; public GameObject root; public DroneCollection latest; public int equipDroneIt; public int icon = 0; public void OnEnable() { itemDisplay = ((Component)this).GetComponent(); } public void Display(DroneCollection droneCollection) { latest = droneCollection; if ((Object)(object)droneCollection == (Object)null) { root.SetActive(false); return; } if (droneCollection.noMinions) { root.SetActive(false); return; } root.SetActive(true); ((Component)root.transform.parent).gameObject.SetActive(true); itemDisplay = ((Component)this).GetComponent(); ((Behaviour)itemDisplay).enabled = false; int num = droneCollection.droneDict.Count + droneCollection.bodyDict_Devotion.Count; num += droneCollection.itemDict_Devotion.Count; num += droneCollection.equipmentDrones.Count + droneCollection.equipmentDict_Devotion.Count; Log.LogMessage("Drone Display " + num); icon = 0; itemDisplay.AllocateIcons(num); if (droneCollection.droneDict.Count > 0) { AssignDroneIcon(droneCollection); } if (droneCollection.bodyDict_Devotion.Count > 0) { AssignDevotionIcon(droneCollection); } if (icon != 0) { } } public void AssignDroneIcon(DroneCollection droneCollection) { //IL_0042: Unknown result type (might be due to invalid IL or missing references) //IL_00a9: Unknown result type (might be due to invalid IL or missing references) //IL_00ae: Unknown result type (might be due to invalid IL or missing references) //IL_0192: Unknown result type (might be due to invalid IL or missing references) for (int i = 0; i < droneCollection.droneDict.Count; i++) { ItemIcon val = itemDisplay.itemIcons[icon]; icon++; KeyValuePair<(BodyIndex, int), int> keyValuePair = droneCollection.droneDict.ElementAt(i); CharacterBody bodyPrefabBodyComponent = BodyCatalog.GetBodyPrefabBodyComponent(keyValuePair.Key.Item1); int item = keyValuePair.Key.Item2; DroneDef val2 = DroneCatalog.FindDroneDefFromBody(((Component)bodyPrefabBodyComponent).gameObject); val.SetItemIndex((ItemIndex)0, keyValuePair.Value, 0f); val.image.texture = bodyPrefabBodyComponent.portraitIcon; TooltipProvider component = ((Component)val).GetComponent(); bodyPrefabBodyComponent.bodyColor.a = 1f; component.titleColor = bodyPrefabBodyComponent.bodyColor; component.titleToken = bodyPrefabBodyComponent.baseNameToken; component.overrideTitleText = string.Empty; component.overrideBodyText = string.Empty; if (Object.op_Implicit((Object)(object)val2)) { component.bodyToken = val2.skillDescriptionToken; } else { component.bodyToken = string.Empty; } if (item > 0) { item++; component.overrideTitleText = Language.GetStringFormatted("DRONE_TIER_SUFFIX", new object[2] { Language.GetString(bodyPrefabBodyComponent.baseNameToken), item }); ((Component)val.stackText).gameObject.SetActive(true); ((TMP_Text)val.stackText).text = "T" + item; ((TMP_Text)val.stackText).transform.localPosition = new Vector3(63.8f, -104f, 0f); ((TMP_Text)val.stackText).fontSizeMax = 18f; } else { ((Component)val.stackText).gameObject.SetActive(false); } if (!((Object)(object)val2 == (Object)(object)DroneDefs.EquipmentDrone)) { continue; } foreach (EquipmentDef equipmentDrone in droneCollection.equipmentDrones) { EquipOnDeathInventory.MakeEquipmentIcon(itemDisplay.itemIcons[icon], equipmentDrone, 1); icon++; } } } public void AssignDevotionIcon(DroneCollection droneCollection) { //IL_003d: 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_00c2: 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) for (int i = 0; i < droneCollection.bodyDict_Devotion.Count; i++) { ItemIcon val = itemDisplay.itemIcons[icon]; icon++; KeyValuePair keyValuePair = droneCollection.bodyDict_Devotion.ElementAt(i); CharacterBody bodyPrefabBodyComponent = BodyCatalog.GetBodyPrefabBodyComponent(keyValuePair.Key); val.SetItemIndex((ItemIndex)0, keyValuePair.Value, 0f); val.image.texture = bodyPrefabBodyComponent.portraitIcon; TooltipProvider component = ((Component)val).GetComponent(); component.titleToken = bodyPrefabBodyComponent.baseNameToken; component.overrideBodyText = ""; component.bodyToken = ""; component.titleColor = bodyPrefabBodyComponent.bodyColor; ((Component)val.spriteAsNumberManager).transform.localPosition = new Vector3(41.944f, -48.39f, 0f); } for (int j = 0; j < droneCollection.itemDict_Devotion.Count; j++) { KeyValuePair keyValuePair2 = droneCollection.itemDict_Devotion.ElementAt(j); itemDisplay.itemIcons[icon].SetItemIndex(keyValuePair2.Key.itemIndex, keyValuePair2.Value, 0f); icon++; } for (int k = 0; k < droneCollection.equipmentDict_Devotion.Count; k++) { KeyValuePair keyValuePair3 = droneCollection.equipmentDict_Devotion.ElementAt(k); itemDisplay.itemIcons[icon].SetItemIndex((ItemIndex)0, keyValuePair3.Value, 0f); itemDisplay.itemIcons[icon].image.texture = keyValuePair3.Key.pickupIconTexture; EquipOnDeathInventory.MakeEquipmentIcon(itemDisplay.itemIcons[icon], keyValuePair3.Key, keyValuePair3.Value); icon++; } } } public class DroneCollection : MonoBehaviour { public Dictionary<(BodyIndex, int), int> droneDict; public List<(BodyIndex, int)> droneList; public List equipmentDrones; public Dictionary bodyDict_Devotion; public Dictionary itemDict_Devotion; public Dictionary equipmentDict_Devotion; public bool hasDrones = false; public bool hasDevotion = false; public bool noMinions = true; public static bool isPermamentMinion(GameObject minion) { if (!Object.op_Implicit((Object)(object)minion.GetComponent())) { return false; } if (Object.op_Implicit((Object)(object)minion.GetComponent())) { return false; } Inventory component = minion.GetComponent(); if (!Object.op_Implicit((Object)(object)component)) { return false; } if (component.GetItemCountPermanent(Items.HealthDecay) > 0) { return false; } if (component.GetItemCountPermanent(Items.Ghost) > 0) { return false; } if (component.GetItemCountPermanent(Items.GummyCloneIdentifier) > 0) { return false; } return true; } public void CountDrones() { try { CharacterMaster component = ((Component)this).GetComponent(); MinionGroupDestroyer component2 = ((Component)this).GetComponent(); if ((Object)(object)component2 == (Object)null || component2.group == null || component2.group.memberCount == 0) { return; } droneList = new List<(BodyIndex, int)>(); droneDict = new Dictionary<(BodyIndex, int), int>(); equipmentDrones = new List(); bodyDict_Devotion = new Dictionary(); itemDict_Devotion = new Dictionary(); equipmentDict_Devotion = new Dictionary(); for (int i = 0; i < component2.group.memberCount; i++) { AddToCollection(component2.group.members[i]); } foreach (DevotionInventoryController instance in DevotionInventoryController.InstanceList) { if ((Object)(object)instance.SummonerMaster == (Object)(object)component) { hasDevotion = true; AddItemsFrom(instance._devotionMinionInventory, isDevotion: true); } } hasDrones = droneDict.Count > 0; noMinions = !hasDrones && !hasDevotion; } catch (Exception message) { Debug.LogError((object)"REPORT TO WOLFO"); Log.LogError(message); } } public void Reset() { RunExtraStatTracker.instance.alreadyCountedDronesForStage = false; noMinions = true; droneDict = null; equipmentDrones = null; bodyDict_Devotion = null; itemDict_Devotion = null; equipmentDict_Devotion = null; } public void AddToCollection(MinionOwnership minion) { //IL_00b0: Unknown result type (might be due to invalid IL or missing references) //IL_00b5: Unknown result type (might be due to invalid IL or missing references) //IL_00fb: 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_00dc: Unknown result type (might be due to invalid IL or missing references) //IL_00df: Unknown result type (might be due to invalid IL or missing references) //IL_00e8: Unknown result type (might be due to invalid IL or missing references) if (!Object.op_Implicit((Object)(object)minion) || !isPermamentMinion(((Component)minion).gameObject)) { return; } CharacterMaster component = ((Component)minion).GetComponent(); if ((Object)(object)component == (Object)null || (Object)(object)component.bodyPrefab == (Object)null || component.inventory.GetItemCountPermanent(Items.HealthDecay) > 0) { return; } bool flag = Object.op_Implicit((Object)(object)((Component)component).GetComponent()); if (!flag) { hasDrones = true; } AddEquipmentFrom(component.inventory, flag); BodyIndex bodyIndex = component.bodyPrefab.GetComponent().bodyIndex; if (flag) { if (!bodyDict_Devotion.TryAdd(bodyIndex, 1)) { bodyDict_Devotion[bodyIndex]++; } return; } (BodyIndex, int) key = (bodyIndex, component.inventory.GetItemCountPermanent(Items.DroneUpgradeHidden)); if (!droneDict.TryAdd(key, 1)) { droneDict[key]++; } } public void AddItemsFrom(Inventory inventory, bool isDevotion) { //IL_0010: Unknown result type (might be due to invalid IL or missing references) //IL_0015: Unknown result type (might be due to invalid IL or missing references) //IL_0017: 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_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0040: Invalid comparison between Unknown and I4 for (int i = 0; i < inventory.itemAcquisitionOrder.Count; i++) { ItemIndex val = inventory.itemAcquisitionOrder[i]; int itemCountPermanent = inventory.GetItemCountPermanent(val); if (itemCountPermanent > 0) { ItemDef itemDef = ItemCatalog.GetItemDef(val); if (!itemDef.hidden && (int)itemDef.tier != 5 && isDevotion && !itemDict_Devotion.TryAdd(itemDef, itemCountPermanent)) { itemDict_Devotion[itemDef] += itemCountPermanent; } } } } public void AddEquipmentFrom(Inventory inventory, bool isDevotion) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0007: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Unknown result type (might be due to invalid IL or missing references) //IL_0067: 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_003e: Unknown result type (might be due to invalid IL or missing references) EquipmentState currentEquipmentState = inventory.currentEquipmentState; if (!Object.op_Implicit((Object)(object)currentEquipmentState.equipmentDef)) { return; } if (isDevotion) { if (!equipmentDict_Devotion.TryAdd(currentEquipmentState.equipmentDef, 1)) { equipmentDict_Devotion[currentEquipmentState.equipmentDef]++; } } else { equipmentDrones.Add(currentEquipmentState.equipmentDef); } } } public static class LoadoutStat { public static void Add_Loadout(GameEndReportPanelController self, PlayerInfo playerInfo) { //IL_00a1: Unknown result type (might be due to invalid IL or missing references) if (!WConfig.DC_Loadout.Value) { return; } if ((Object)(object)playerInfo.master == (Object)null) { Log.LogWarning("Loadout Inventory : Null Master"); return; } if (playerInfo.master.loadout == null) { Log.LogWarning("Loadout Inventory : Null Loadout"); return; } if (playerInfo.master.loadout.bodyLoadoutManager == null) { Log.LogWarning("Loadout Inventory : Null BodyLoadoutManager"); return; } Log.LogMessage("Add Loadout to run death screen"); BodyLoadout orCreateModifiedBodyLoadout = playerInfo.master.loadout.bodyLoadoutManager.GetOrCreateModifiedBodyLoadout(playerInfo.bodyIndex); GameEndLoadoutAsStat gameEndLoadoutAsStat = ((Component)self).gameObject.GetComponent(); if ((Object)(object)gameEndLoadoutAsStat == (Object)null) { gameEndLoadoutAsStat = ((Component)self).gameObject.AddComponent(); } gameEndLoadoutAsStat.panel = self; gameEndLoadoutAsStat.SetLoadout(orCreateModifiedBodyLoadout, playerInfo.itemStacks); } } public class GameEndLoadoutAsStat : MonoBehaviour { public GameEndReportPanelController panel; public GameObject rootObject; public GameObject skillRoot; public GameObject backgroundObject; public Transform skills; public RectTransform background; public BodyLoadout latest; public static float scale = 40f; public float scaleBig = 50f; private bool setup = false; public void SetupStruct() { //IL_0140: Unknown result type (might be due to invalid IL or missing references) //IL_0147: Expected O, but got Unknown //IL_016d: Unknown result type (might be due to invalid IL or missing references) //IL_0174: Expected O, but got Unknown //IL_019f: Unknown result type (might be due to invalid IL or missing references) //IL_01b0: Unknown result type (might be due to invalid IL or missing references) //IL_01ba: Expected O, but got Unknown //IL_01d9: Unknown result type (might be due to invalid IL or missing references) //IL_01e3: Expected O, but got Unknown //IL_0232: Unknown result type (might be due to invalid IL or missing references) //IL_0237: Unknown result type (might be due to invalid IL or missing references) //IL_0265: Unknown result type (might be due to invalid IL or missing references) //IL_036e: Unknown result type (might be due to invalid IL or missing references) //IL_0384: Unknown result type (might be due to invalid IL or missing references) //IL_031c: Unknown result type (might be due to invalid IL or missing references) //IL_0332: Unknown result type (might be due to invalid IL or missing references) if ((Object)(object)panel == (Object)null) { panel = ((Component)this).GetComponent(); } if ((Object)(object)rootObject == (Object)null) { GameObject difficulty_stat = DeathScreenExpanded.difficulty_stat; rootObject = Object.Instantiate(difficulty_stat); ((Object)rootObject).name = "LoadoutRootStrip"; rootObject.transform.SetParent((Transform)(object)panel.statContentArea, false); rootObject.GetComponent().preferredWidth = 300f; MPEventSystemLocator component = difficulty_stat.GetComponent(); MPEventSystemLocator component2 = rootObject.GetComponent(); component2.eventSystemProvider = component.eventSystemProvider; component2.eventSystem = component.eventSystem; LanguageTextMeshController component3 = ((Component)rootObject.transform.GetChild(0)).GetComponent(); component3.token = Language.GetString("SURVIVOR_LOADOUT") + ":"; component3.OnEnable(); Object.Destroy((Object)(object)((Component)rootObject.transform.Find("SelectedDifficultyLabel")).gameObject); Object.Destroy((Object)(object)((Component)rootObject.transform.Find("SelectedDifficultyIcon")).gameObject); GameObject val = new GameObject("Holder"); val.transform.SetParent(rootObject.transform, false); val.AddComponent(); GameObject val2 = new GameObject("Holder2"); val2.transform.SetParent(val.transform, false); val2.transform.localPosition = new Vector3(-20f, 0f, 0f); backgroundObject = new GameObject("Background"); backgroundObject.transform.SetParent(val2.transform, false); skillRoot = new GameObject("SkillGroup"); skillRoot.transform.SetParent(val2.transform, false); skills = skillRoot.transform; background = backgroundObject.AddComponent(); Image val3 = backgroundObject.AddComponent(); val3.sprite = Addressables.LoadAssetAsync((object)"RoR2/Base/UI/texUIHighlightBoxOutline.png").WaitForCompletion(); val3.type = (Type)1; ((Graphic)val3).color = new Color(1f, 1f, 1f, 0.7f); rootObject.transform.SetSiblingIndex(1); } setup = true; scaleBig = scale * 1.25f; ((Component)panel.artifactDisplayPanelController).GetComponent().preferredHeight = 58f; Transform child = ((Component)panel.artifactDisplayPanelController).transform.GetChild(2); GridLayoutGroup component4 = ((Component)child).GetComponent(); if (((Component)panel.artifactDisplayPanelController).gameObject.activeSelf) { if (((Component)component4).transform.childCount > 15) { component4.constraintCount = 2; component4.cellSize = new Vector2(32f, 32f); component4.spacing = new Vector2(-2f, -6f); ((LayoutGroup)component4).padding.bottom = 0; ((LayoutGroup)component4).padding.top = 0; } else { component4.constraintCount = 1; component4.cellSize = new Vector2(36f, 36f); component4.spacing = new Vector2(0f, 0f); ((LayoutGroup)component4).padding.bottom = 2; ((LayoutGroup)component4).padding.top = 2; } ExtraStats.CombineDifficultyLoadout(panel.statContentArea); } } public void SetLoadout(BodyLoadout loadout, int[] inventory) { //IL_005f: 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_00ca: 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_00fc: Unknown result type (might be due to invalid IL or missing references) //IL_0101: 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_0106: Invalid comparison between Unknown and I4 //IL_0314: Unknown result type (might be due to invalid IL or missing references) //IL_033d: Unknown result type (might be due to invalid IL or missing references) //IL_0376: 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_0246: Expected O, but got Unknown //IL_027f: Unknown result type (might be due to invalid IL or missing references) //IL_0295: Unknown result type (might be due to invalid IL or missing references) //IL_0297: Unknown result type (might be due to invalid IL or missing references) //IL_02d8: Unknown result type (might be due to invalid IL or missing references) //IL_0115: Unknown result type (might be due to invalid IL or missing references) //IL_0117: Unknown result type (might be due to invalid IL or missing references) //IL_0119: 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_0134: Expected I4, but got Unknown //IL_013f: 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_018e: 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_0204: Unknown result type (might be due to invalid IL or missing references) latest = loadout; if (!setup) { SetupStruct(); } else { for (int i = 0; i < skills.childCount; i++) { Object.Destroy((Object)(object)((Component)skills.GetChild(i)).gameObject); } } GameObject bodyPrefab = BodyCatalog.GetBodyPrefab(loadout.bodyIndex); if (!Object.op_Implicit((Object)(object)bodyPrefab)) { Log.LogWarning("Null BodyPrefab"); return; } CharacterBody component = bodyPrefab.GetComponent(); component.bodyColor.a = 1f; Color bodyColor = component.bodyColor; List gameObjectComponents = GetComponentsCache.GetGameObjectComponents(bodyPrefab); SkillLocator component2 = bodyPrefab.GetComponent(); int num = loadout.skillPreferences.Length; for (int j = 0; j < num; j++) { Color titleColor = bodyColor; GenericSkill val = gameObjectComponents[j]; SkillDef val2 = val.skillFamily.variants[loadout.skillPreferences[j]].skillDef; SkillSlot val3 = component2.FindSkillSlot(val); if ((int)val3 != -1) { SkillSlot val4 = val3; SkillSlot val5 = val4; switch ((int)val5) { case 0: if (inventory[Items.LunarPrimaryReplacement.itemIndex] > 0) { val2 = CommonAssets.lunarPrimaryReplacementSkillDef; ((Color)(ref titleColor))..ctor(0.2018f, 0.182f, 0.2736f, 1f); } break; case 1: { bool flag = inventory[Items.LunarSecondaryReplacement.itemIndex] > 0; if (inventory[Items.LunarSecondaryReplacement.itemIndex] > 0) { val2 = CommonAssets.lunarSecondaryReplacementSkillDef; ((Color)(ref titleColor))..ctor(0.2018f, 0.182f, 0.2736f, 1f); } break; } case 2: if (inventory[Items.LunarUtilityReplacement.itemIndex] > 0) { val2 = CommonAssets.lunarUtilityReplacementSkillDef; ((Color)(ref titleColor))..ctor(0.2018f, 0.182f, 0.2736f, 1f); } break; case 3: if (inventory[Items.LunarSpecialReplacement.itemIndex] > 0) { val2 = CommonAssets.lunarSpecialReplacementSkillDef; ((Color)(ref titleColor))..ctor(0.2018f, 0.182f, 0.2736f, 1f); } break; } } GameObject val6 = new GameObject("SkillIcon"); val6.transform.SetParent(skills, false); val6.AddComponent().sprite = val2.icon; val6.GetComponent().sizeDelta = new Vector2(scale, scale); TooltipProvider val7 = val6.AddComponent(); val7.titleColor = titleColor; val7.titleToken = val2.skillNameToken; val7.bodyToken = val2.skillDescriptionToken; val6.transform.localPosition = new Vector3((float)(-num + j + 1) * scale, 0f, 0f); val6.SetActive(true); } background.sizeDelta = new Vector2(scaleBig, scaleBig); background.offsetMax = new Vector2(scaleBig * 0.5f, scaleBig * 0.5f); background.offsetMin = new Vector2(0f - ((float)loadout.skillPreferences.Length * scale - scale * 0.375f), scaleBig * -0.5f); } } public static class RunRecap { [CompilerGenerated] private static class <>O { public static Action <0>__Run_onRunStartGlobal; public static hook_PreStartClient <1>__PlayerCharacterMasterController_PreStartClient; public static hook_InstantiateUi <2>__SaveLatestWaveUI; } public static void Start() { //IL_0032: Unknown result type (might be due to invalid IL or missing references) //IL_0037: Unknown result type (might be due to invalid IL or missing references) //IL_003d: Expected O, but got Unknown //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_005e: Expected O, but got Unknown Run.onRunStartGlobal += Run_onRunStartGlobal; object obj = <>O.<1>__PlayerCharacterMasterController_PreStartClient; if (obj == null) { hook_PreStartClient val = PlayerCharacterMasterController_PreStartClient; <>O.<1>__PlayerCharacterMasterController_PreStartClient = val; obj = (object)val; } PlayerCharacterMasterController.PreStartClient += (hook_PreStartClient)obj; object obj2 = <>O.<2>__SaveLatestWaveUI; if (obj2 == null) { hook_InstantiateUi val2 = SaveLatestWaveUI; <>O.<2>__SaveLatestWaveUI = val2; obj2 = (object)val2; } InfiniteTowerWaveController.InstantiateUi += (hook_InstantiateUi)obj2; } private static void PlayerCharacterMasterController_PreStartClient(orig_PreStartClient orig, PlayerCharacterMasterController self) { orig.Invoke(self); ((Component)self).gameObject.AddComponent(); } private static void SaveLatestWaveUI(orig_InstantiateUi orig, InfiniteTowerWaveController self, Transform uiRoot) { orig.Invoke(self, uiRoot); ((Component)Run.instance).GetComponent().latestWaveUiPrefab = self.overlayEntries[1].prefab; } public static void Run_onRunStartGlobal(Run obj) { ((Component)obj).gameObject.AddComponent(); } public static void AddRunRecapV2(GameEndReportPanelController self, PlayerInfo playerInfo) { //IL_005e: Unknown result type (might be due to invalid IL or missing references) //IL_0064: Expected O, but got Unknown //IL_006f: Unknown result type (might be due to invalid IL or missing references) //IL_0075: Expected O, but got Unknown //IL_0080: 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_00ac: Unknown result type (might be due to invalid IL or missing references) //IL_00b3: Expected O, but got Unknown //IL_00f0: Unknown result type (might be due to invalid IL or missing references) //IL_00f7: Expected O, but got Unknown //IL_00fd: Unknown result type (might be due to invalid IL or missing references) //IL_0104: Expected O, but got Unknown //IL_0137: 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_0151: Unknown result type (might be due to invalid IL or missing references) //IL_0168: Unknown result type (might be due to invalid IL or missing references) //IL_0175: Unknown result type (might be due to invalid IL or missing references) //IL_0182: Unknown result type (might be due to invalid IL or missing references) //IL_018f: Unknown result type (might be due to invalid IL or missing references) //IL_019c: Unknown result type (might be due to invalid IL or missing references) //IL_01a9: Unknown result type (might be due to invalid IL or missing references) //IL_01ae: Unknown result type (might be due to invalid IL or missing references) //IL_01c5: Unknown result type (might be due to invalid IL or missing references) //IL_02fc: Unknown result type (might be due to invalid IL or missing references) //IL_0306: Expected O, but got Unknown //IL_047e: 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_046e: Unknown result type (might be due to invalid IL or missing references) //IL_0473: Unknown result type (might be due to invalid IL or missing references) DeathScreenExpanded component = ((Component)self).GetComponent(); if (component.isLogRunReport || component.addedRunRecap || !WConfig.DC_StageRecap.Value) { return; } component.addedRunRecap = true; RectTransform val = (RectTransform)((Component)self).transform.GetChild(0).GetChild(1); RectTransform val2 = (RectTransform)((Transform)val).Find("RightArea"); val2.anchorMin = new Vector2(0.5f, 0f); GameObject val3 = Object.Instantiate(DeathScreenExpanded.RightAreaPrefab); val3.transform.localEulerAngles = Vector3.zero; GameObject val4 = new GameObject("Holder"); val4.transform.SetParent((Transform)(object)val2, false); LayoutElement val5 = val4.AddComponent(); val5.flexibleHeight = 1f; val5.flexibleWidth = 1f; RectTransform val6 = (RectTransform)((Transform)val2).Find("InfoArea"); RectTransform val7 = (RectTransform)val3.transform; ((Transform)val6).SetParent(val4.transform, false); val3.transform.SetParent(val4.transform, false); val4.transform.SetAsFirstSibling(); val6.anchoredPosition3D = Vector3.zero; val6.offsetMax = Vector2.zero; val6.offsetMin = Vector2.zero; val6.anchorMax = new Vector2(0.8f, 1f); val6.anchorMin = Vector2.zero; val7.anchoredPosition3D = Vector3.zero; val7.offsetMax = Vector2.zero; val7.offsetMin = Vector2.zero; val7.anchorMax = Vector2.op_Implicit(Vector3.one); val7.anchorMin = new Vector2(0.8f, 0f); val3.AddComponent(); Object.Destroy((Object)(object)((Component)val3.transform.GetChild(2)).gameObject); Object.Destroy((Object)(object)((Component)val3.transform.GetChild(1)).gameObject); Transform child = val3.transform.GetChild(0); Transform child2 = ((Component)child).transform.GetChild(2); ((Component)child2.GetChild(0)).GetComponent().token = "RUN_RECAP"; ((Object)val3).name = "StageRecapMain"; RectTransform component2 = val3.GetComponent(); GameObject val8 = Object.Instantiate(DeathScreenExpanded.unlockAreaPrefab); val8.transform.SetParent(child, false); ((Object)val8).name = "StageRecapArea"; Object.Destroy((Object)(object)((Component)((Component)child).transform.GetChild(3)).gameObject); ((Component)val8.transform.GetChild(0)).gameObject.SetActive(false); component.stageRecap = val3; component.stageRecapArea = val8; val5 = ((Component)child).GetComponent(); component.stageRecapContent = val8.transform.GetChild(1).GetChild(0).GetChild(0); VerticalLayoutGroup component3 = ((Component)component.stageRecapContent).GetComponent(); ((HorizontalOrVerticalLayoutGroup)component3).childForceExpandWidth = false; ((LayoutGroup)component3).padding = new RectOffset(0, 0, 12, 0); Log.LogMessage("Stage Recap"); List visitedScenes = RunExtraStatTracker.instance.visitedScenes; float num = 60f; ((HorizontalOrVerticalLayoutGroup)component3).spacing = 12f; if (visitedScenes.Count >= 16) { ((HorizontalOrVerticalLayoutGroup)component3).spacing = 0f; num = 48f - (float)(visitedScenes.Count - 16) * 2.4f; num = Mathf.Max(num, 36f); } else if (visitedScenes.Count >= 14) { ((HorizontalOrVerticalLayoutGroup)component3).spacing = 2f; num = 48f; } else if (visitedScenes.Count >= 12) { ((HorizontalOrVerticalLayoutGroup)component3).spacing = 4f; num = 54f; } else if (visitedScenes.Count >= 10) { ((HorizontalOrVerticalLayoutGroup)component3).spacing = 9f; num = 60f; } else { ((HorizontalOrVerticalLayoutGroup)component3).spacing = 12f; num = 60f; } for (int i = 0; i < RunExtraStatTracker.instance.visitedScenes.Count; i++) { GameObject val9 = Object.Instantiate(DeathScreenExpanded.stageIconPrefab, component.stageRecapContent); TooltipProvider component4 = val9.GetComponent(); if (visitedScenes[i].environmentColor.a != 0f) { component4.titleColor = visitedScenes[i].environmentColor; } else { component4.titleColor = Color.gray; } component4.titleToken = visitedScenes[i].nameToken; component4.bodyToken = visitedScenes[i].subtitleToken; val9.GetComponent().texture = visitedScenes[i].previewTexture; val9.GetComponent().preferredHeight = num; } } } public class InventoryDisplayFitter : UIBehaviour { public ItemInventoryDisplay inv; public float previousHeight = 0f; public RectTransform rectTransform; public override void OnEnable() { ((UIBehaviour)this).OnEnable(); rectTransform = ((Component)this).GetComponent(); inv = ((Component)this).GetComponentInChildren(); } public override void OnRectTransformDimensionsChange() { //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_0050: Unknown result type (might be due to invalid IL or missing references) ((UIBehaviour)this).OnRectTransformDimensionsChange(); if (Object.op_Implicit((Object)(object)rectTransform)) { Rect rect = rectTransform.rect; float height = ((Rect)(ref rect)).height; if (height != previousHeight) { previousHeight = height; inv.maxHeight = rectTransform.sizeDelta.y; inv.LayoutAllIcons(); ((UIBehaviour)((Component)((Component)inv).transform.parent).GetComponent()).OnEnable(); } } } } public class DeathScreenExpanded : MonoBehaviour { public GameObject disabledInventory; public GameObject lastSimuWaveStat; public GameObject stageRecap; public GameObject stageRecapArea; public Transform stageRecapContent; public ChildLocator childLocator; public GameObject lastWaveStat; public bool isSaveAndContinuedRun; public bool isDevotionRun; public bool compactedStats; public bool addedRunRecap; public bool addedRunTrackedStats; public bool isLogRunReport; public float deathTimeStamp; public GameEndReportPanelController GameEndReportPanel; public Transform ItemArea; public GameObject latestWaveStrip; public GameObject bonusInventoyHolder; public GameObject killerInventory; public GameObject minionInventory; public bool IsEvoInventory; public static GameObject difficulty_stat; public static GameObject itemAreaPrefab; public static GameObject unlockAreaPrefab; public static GameObject RightAreaPrefab; public static GameObject statHolderPrefab; public bool oneTimeExtras = false; public bool madeStats = false; public bool addedStageRecap; public static GameObject stageIconPrefab; public GameObject chatToggleButton; public bool chatActive; public GameObject MakeInventory() { //IL_001c: Unknown result type (might be due to invalid IL or missing references) //IL_0023: Expected O, but got Unknown if (!Object.op_Implicit((Object)(object)bonusInventoyHolder)) { GameObject val = (bonusInventoyHolder = new GameObject("inventoryHolder")); LayoutElement val2 = val.AddComponent(); HorizontalLayoutGroup val3 = val.AddComponent(); val2.flexibleHeight = 0.1f; val2.minHeight = 124f; val2.preferredHeight = 210f; ((HorizontalOrVerticalLayoutGroup)val3).spacing = 2f; val.transform.SetParent(ItemArea.parent, false); val.transform.SetSiblingIndex(3); } GameObject val4 = Object.Instantiate(itemAreaPrefab, bonusInventoyHolder.transform); LayoutElement component = val4.GetComponent(); ItemInventoryDisplay componentInChildren = val4.GetComponentInChildren(); ((Component)val4.transform.GetChild(1)).gameObject.AddComponent(); ((Behaviour)((Component)((Component)componentInChildren).transform.parent).GetComponent()).enabled = false; component.flexibleHeight = -1f; component.preferredHeight = -1f; return val4; } public void ToggleChat() { //IL_002d: 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) Util.PlaySound("Play_UI_menuClick", ((Component)this).gameObject); chatToggleButton.transform.localScale = new Vector3(0.5f, 0f - chatToggleButton.transform.localScale.y, 0.5f); chatActive = !chatActive; ((Component)GameEndReportPanel.chatboxTransform).gameObject.SetActive(chatActive); ((Component)((Component)GameEndReportPanel.chatboxTransform).transform.GetChild(0)).GetComponent().OnEnable(); } } public class ItemAquisitionStorer : MonoBehaviour { public readonly List storedOrder = new List(); private Inventory inventory; public void Store() { //IL_0071: Unknown result type (might be due to invalid IL or missing references) inventory = ((Component)this).GetComponent(); if (!Object.op_Implicit((Object)(object)inventory)) { Debug.LogWarning((object)"Could not find an Inventory"); return; } int capacity = inventory.itemAcquisitionOrder.Capacity; storedOrder.Capacity = inventory.itemAcquisitionOrder.Capacity; for (int i = 0; i < inventory.itemAcquisitionOrder.Count; i++) { storedOrder.Add(inventory.itemAcquisitionOrder[i]); } } public void Return() { //IL_0035: 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_007d: 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_00b3: Unknown result type (might be due to invalid IL or missing references) List list = new List(); List list2 = inventory.itemAcquisitionOrder.Except(storedOrder).ToList(); for (int i = 0; i < storedOrder.Count; i++) { if (inventory.GetItemCountEffective(storedOrder[i]) > 0) { list.Add(storedOrder[i]); } } for (int j = 0; j < list2.Count; j++) { Debug.Log((object)((Object)ItemCatalog.GetItemDef(list2[j])).name); if (inventory.GetItemCountEffective(list2[j]) > 0) { list.Add(list2[j]); } } inventory.itemAcquisitionOrder = list; inventory.HandleInventoryChanged(); ((NetworkBehaviour)inventory).SetDirtyBit(8u); storedOrder.Clear(); } } public static class DeathScreen_Main { [CompilerGenerated] private static class <>O { public static hook_SetDisplayData <0>__OneTimeExtras; public static hook_SetPlayerInfo <1>__AddManyExtras; public static hook_AllocateIcons <2>__AddEquipmentIcons; public static hook_AssignStatToStrip <3>__PointsToolTip; public static hook_AllocateUnlockStrips <4>__CombineStats; public static Manipulator <5>__GameEndReportPanelController_SetPlayerInfo; public static Action <6>__Run_onClientGameOverGlobal; } public static bool otherMod; public static void Start() { //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_0036: Expected O, but got Unknown //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_0057: Expected O, but got Unknown //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_008a: Expected O, but got Unknown //IL_00a0: Unknown result type (might be due to invalid IL or missing references) //IL_00a5: Unknown result type (might be due to invalid IL or missing references) //IL_00ab: Expected O, but got Unknown //IL_00c1: Unknown result type (might be due to invalid IL or missing references) //IL_00c6: Unknown result type (might be due to invalid IL or missing references) //IL_00cc: Expected O, but got Unknown //IL_00fb: Unknown result type (might be due to invalid IL or missing references) //IL_0100: Unknown result type (might be due to invalid IL or missing references) //IL_0106: Expected O, but got Unknown otherMod = Chainloader.PluginInfos.ContainsKey("local.fix.history"); MakePrefabs(); object obj = <>O.<0>__OneTimeExtras; if (obj == null) { hook_SetDisplayData val = OneTimeExtras; <>O.<0>__OneTimeExtras = val; obj = (object)val; } GameEndReportPanelController.SetDisplayData += (hook_SetDisplayData)obj; object obj2 = <>O.<1>__AddManyExtras; if (obj2 == null) { hook_SetPlayerInfo val2 = AddManyExtras; <>O.<1>__AddManyExtras = val2; obj2 = (object)val2; } GameEndReportPanelController.SetPlayerInfo += (hook_SetPlayerInfo)obj2; RunRecap.Start(); ExtraStatsTracking.Start(); ExtraStatsTracking.Start_Missed(); object obj3 = <>O.<2>__AddEquipmentIcons; if (obj3 == null) { hook_AllocateIcons val3 = EquipOnDeathInventory.AddEquipmentIcons; <>O.<2>__AddEquipmentIcons = val3; obj3 = (object)val3; } ItemInventoryDisplay.AllocateIcons += (hook_AllocateIcons)obj3; object obj4 = <>O.<3>__PointsToolTip; if (obj4 == null) { hook_AssignStatToStrip val4 = ExtraStats.PointsToolTip; <>O.<3>__PointsToolTip = val4; obj4 = (object)val4; } GameEndReportPanelController.AssignStatToStrip += (hook_AssignStatToStrip)obj4; object obj5 = <>O.<4>__CombineStats; if (obj5 == null) { hook_AllocateUnlockStrips val5 = ExtraStats.CombineStats; <>O.<4>__CombineStats = val5; obj5 = (object)val5; } GameEndReportPanelController.AllocateUnlockStrips += (hook_AllocateUnlockStrips)obj5; StatDef.totalEliteKills.pointValue = 20.0; Inventory_Minions.Hooks(); object obj6 = <>O.<5>__GameEndReportPanelController_SetPlayerInfo; if (obj6 == null) { Manipulator val6 = GameEndReportPanelController_SetPlayerInfo; <>O.<5>__GameEndReportPanelController_SetPlayerInfo = val6; obj6 = (object)val6; } GameEndReportPanelController.SetPlayerInfo += (Manipulator)obj6; Run.onClientGameOverGlobal += Run_onClientGameOverGlobal; } private static void Run_onClientGameOverGlobal(Run arg1, RunReport arg2) { foreach (PlayerCharacterMasterController instance in PlayerCharacterMasterController.instances) { if (Object.op_Implicit((Object)(object)instance.master) && Object.op_Implicit((Object)(object)instance.master.inventory)) { PerPlayerMaster_ExtraStatTracker component = ((Component)instance).GetComponent(); component.itemDurationPercent = new float[ItemCatalog.itemCount]; instance.master.inventory.WriteAllTempItemDecayValues((Span)component.itemDurationPercent); } } } private static void GameEndReportPanelController_SetPlayerInfo(ILContext il) { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown ILCursor val = new ILCursor(il); if (val.TryGotoNext((MoveType)0, new Func[1] { (Instruction x) => ILPatternMatchingExt.MatchLdstr(x, "GameEndReportPanelController.SetStatSheet: Could not find stat def \"{0}\".") })) { val.RemoveRange(8); } else { Log.LogWarning("IL Failed: GameEndReportPanelController_SetPlayerInfo"); } } public static ChildLocator AddChildLocator(GameEndReportPanelController self) { //IL_0047: 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_0069: 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_0092: 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_009d: Unknown result type (might be due to invalid IL or missing references) //IL_00b7: Unknown result type (might be due to invalid IL or missing references) //IL_00b9: Unknown result type (might be due to invalid IL or missing references) //IL_00c2: 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_00e4: 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_010d: 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_0118: Unknown result type (might be due to invalid IL or missing references) //IL_0132: Unknown result type (might be due to invalid IL or missing references) //IL_0134: 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_015d: Unknown result type (might be due to invalid IL or missing references) //IL_015f: Unknown result type (might be due to invalid IL or missing references) Transform child = ((Component)self).transform.GetChild(0); Transform child2 = child.GetChild(1); Transform val = child2.Find("StatsAndChatArea"); Transform val2 = child2.Find("RightArea"); ChildLocator val3 = ((Component)self).gameObject.AddComponent(); val3.transformPairs = (NameTransformPair[])(object)new NameTransformPair[7] { new NameTransformPair { name = "HeaderArea", transform = child.GetChild(0) }, new NameTransformPair { name = "BodyArea", transform = child.GetChild(1) }, new NameTransformPair { name = "StatsAndChatArea", transform = val }, new NameTransformPair { name = "StatsContainer", transform = val.GetChild(0) }, new NameTransformPair { name = "ChatArea", transform = val.GetChild(1) }, new NameTransformPair { name = "RightArea", transform = val2 }, new NameTransformPair { name = "InfoArea", transform = val2.GetChild(0) } }; return val3; } public static void SizeChanges(GameEndReportPanelController self) { } public static void GeneralQuality(GameEndReportPanelController self, PlayerInfo playerInfo, bool log) { //IL_00a5: Unknown result type (might be due to invalid IL or missing references) //IL_00ac: Expected O, but got Unknown GameObject killerPanelObject = self.killerPanelObject; if ((Object)(object)killerPanelObject != (Object)null) { killerPanelObject.SetActive(true); ((Component)killerPanelObject.transform.GetChild(0)).gameObject.SetActive(playerInfo.isDead); ((Component)killerPanelObject.transform.GetChild(1)).gameObject.SetActive(playerInfo.isDead); } bool active = self.unlockStrips.Count > 0; if (log) { Transform parent = ((Transform)self.unlockContentArea).parent.parent; ((Component)parent).gameObject.SetActive(active); } else { RectTransform val = (RectTransform)((Transform)self.unlockContentArea).parent.parent.parent; ((Component)val).gameObject.SetActive(active); ((Component)val).GetComponent().flexibleHeight = Mathf.Min(0.11f * Mathf.Pow(2f, (float)self.unlockStrips.Count), 1f); } if (Object.op_Implicit((Object)(object)self.finalMessageLabel)) { ((TMP_Text)self.finalMessageLabel).fontSizeMin = ((TMP_Text)self.finalMessageLabel).fontSizeMax; } } private static void AddManyExtras(orig_SetPlayerInfo orig, GameEndReportPanelController self, PlayerInfo playerInfo, int playerIndex) { //IL_0002: 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_013e: Unknown result type (might be due to invalid IL or missing references) //IL_014b: Unknown result type (might be due to invalid IL or missing references) //IL_0169: Unknown result type (might be due to invalid IL or missing references) EquipOnDeathInventory.DeathEquip_Enemy1 = (EquipmentIndex)(-1); if (playerInfo == null) { EquipOnDeathInventory.DeathEquips_Player = Array.Empty(); orig.Invoke(self, playerInfo, playerIndex); return; } EquipOnDeathInventory.DeathEquips_Player = playerInfo.equipment; orig.Invoke(self, playerInfo, playerIndex); DeathScreenExpanded component = ((Component)self).GetComponent(); try { GeneralQuality(self, playerInfo, component.isLogRunReport); LoadoutStat.Add_Loadout(self, playerInfo); RunRecap.AddRunRecapV2(self, playerInfo); Inventory_Minions.AddMinionInventory(self, playerInfo); Inventory_Killer.AddKillerInventory(self, playerInfo); ExtraStats.AddCustomStats(self, playerInfo); if (!component.isLogRunReport) { bool active = component.killerInventory.activeSelf || component.minionInventory.activeSelf; component.bonusInventoyHolder.SetActive(active); } if (Object.op_Implicit((Object)(object)playerInfo.master) && Object.op_Implicit((Object)(object)playerInfo.master.inventory)) { PerPlayerMaster_ExtraStatTracker component2 = ((Component)playerInfo.master).GetComponent(); if (component2.itemDurationPercent != null) { component2.itemDurationPercent.CopyTo(self.itemInventoryDisplay.itemDurationPercent, 0); foreach (ItemIcon itemIcon in self.itemInventoryDisplay.itemIcons) { ItemIndex itemIndex = itemIcon.itemIndex; if (self.itemInventoryDisplay.itemDurationPercent[itemIndex] > 0f) { itemIcon.SetItemDuration(self.itemInventoryDisplay.itemDurationPercent[itemIndex]); } } } component2.gameOverWhileDisabled = component2.gameOverWhileDisabled || playerInfo.master.inventory.inventoryDisabled; component.disabledInventory.SetActive(component2.gameOverWhileDisabled); component.disabledInventory.GetComponent().pixelsPerUnitMultiplier = (component.bonusInventoyHolder.activeSelf ? 1.32f : 0.8f); } else { Array.Clear(self.itemInventoryDisplay.itemDurationPercent, 0, self.itemInventoryDisplay.itemDurationPercent.Length); component.disabledInventory.SetActive(false); } } catch (Exception ex) { Debug.LogException(ex); } } public static void MakePrefabs() { //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_011e: Unknown result type (might be due to invalid IL or missing references) //IL_0124: Expected O, but got Unknown //IL_01e8: Unknown result type (might be due to invalid IL or missing references) //IL_01ff: Unknown result type (might be due to invalid IL or missing references) //IL_0216: Unknown result type (might be due to invalid IL or missing references) GameObject val = Addressables.LoadAssetAsync((object)"RoR2/Base/UI/GameEndReportPanel.prefab").WaitForCompletion(); GameEndReportPanelController component = val.GetComponent(); ((TMP_Text)((Component)((Transform)component.statContentArea).GetChild(0).GetChild(0)).GetComponent()).fontSizeMax = 21f; ((TMP_Text)((Component)((Transform)component.statContentArea).GetChild(0).GetChild(2)).GetComponent()).fontSizeMax = 21f; ((TMP_Text)((Component)((Transform)component.statContentArea).GetChild(1).GetChild(0)).GetComponent()).fontSizeMax = 21f; ((TMP_Text)((Component)component.statStripPrefab.transform.GetChild(0)).GetComponent()).fontSizeMax = 21f; DeathScreenExpanded.difficulty_stat = ((Component)((Transform)component.statContentArea).GetChild(0)).gameObject; DeathScreenExpanded.RightAreaPrefab = ((Component)((Component)component).transform.GetChild(0).GetChild(1).GetChild(1)).gameObject; DeathScreenExpanded.unlockAreaPrefab = ((Component)((Transform)component.unlockContentArea).parent.parent.parent).gameObject; DeathScreenExpanded.itemAreaPrefab = ((Component)DeathScreenExpanded.unlockAreaPrefab.transform.parent.GetChild(2)).gameObject; GameObject val2 = new GameObject("StatHolder"); val2.AddComponent(); val2.AddComponent(); val2.AddComponent(); DeathScreenExpanded.statHolderPrefab = PrefabAPI.InstantiateClone(val2, "StatHolder", false); DeathScreenExpanded.stageIconPrefab = PrefabAPI.InstantiateClone(((Component)component.unlockStripPrefab.transform.GetChild(0)).gameObject, "stageIcon", false); GameObject stageIconPrefab = DeathScreenExpanded.stageIconPrefab; stageIconPrefab.AddComponent(); AspectRatioFitter component2 = stageIconPrefab.GetComponent(); component2.aspectRatio = 1.6666666f; component2.aspectMode = (AspectMode)2; stageIconPrefab.GetComponent().preferredHeight = 60f; RectTransform component3 = ((Component)stageIconPrefab.transform.GetChild(0)).GetComponent(); Image component4 = ((Component)stageIconPrefab.transform.GetChild(0)).GetComponent(); ((Graphic)component4).color = new Color(0.1412f, 0.1059f, 0.1099f, 1f); component3.offsetMax = new Vector2(2.5f, 2.5f); component3.offsetMin = new Vector2(-2.5f, -2.5f); component4.sprite = Assets.Bundle.LoadAsset("Assets/WQoL/General/texUIHighlightBoxOutline.png"); } private static void OneTimeExtras(orig_SetDisplayData orig, GameEndReportPanelController self, DisplayData newDisplayData) { //IL_01ea: 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_00a3: Unknown result type (might be due to invalid IL or missing references) //IL_02b1: Unknown result type (might be due to invalid IL or missing references) //IL_02b6: Unknown result type (might be due to invalid IL or missing references) //IL_02cd: Unknown result type (might be due to invalid IL or missing references) //IL_02d2: Unknown result type (might be due to invalid IL or missing references) //IL_02e9: Unknown result type (might be due to invalid IL or missing references) //IL_02f0: Expected O, but got Unknown //IL_0302: Unknown result type (might be due to invalid IL or missing references) //IL_0309: Expected O, but got Unknown //IL_0315: Unknown result type (might be due to invalid IL or missing references) //IL_031c: Expected O, but got Unknown //IL_0328: Unknown result type (might be due to invalid IL or missing references) //IL_032f: Expected O, but got Unknown //IL_0376: Unknown result type (might be due to invalid IL or missing references) //IL_038d: 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_0406: Unknown result type (might be due to invalid IL or missing references) //IL_0428: Unknown result type (might be due to invalid IL or missing references) //IL_0467: Unknown result type (might be due to invalid IL or missing references) //IL_0471: Expected O, but got Unknown //IL_00fc: 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) DeathScreenExpanded deathScreenExpanded = ((Component)self).GetComponent(); if ((Object)(object)deathScreenExpanded == (Object)null) { deathScreenExpanded = ((Component)self).gameObject.AddComponent(); deathScreenExpanded.isLogRunReport = (Object)(object)newDisplayData.runReport.FindFirstPlayerInfo().master == (Object)null; if (!deathScreenExpanded.isLogRunReport) { deathScreenExpanded.childLocator = AddChildLocator(self); } deathScreenExpanded.isSaveAndContinuedRun = Object.op_Implicit((Object)(object)RunExtraStatTracker.instance) && RunExtraStatTracker.instance.isSaveAndContinuedRun; deathScreenExpanded.GameEndReportPanel = self; deathScreenExpanded.ItemArea = ((Component)self.itemInventoryDisplay).transform.parent.parent.parent; deathScreenExpanded.isDevotionRun = newDisplayData.runReport.ruleBook.GetRuleChoice(RuleCatalog.FindRuleDef("Artifacts.Devotion")).localIndex == 0 || (Object.op_Implicit((Object)(object)RunArtifactManager.instance) && RunArtifactManager.instance.IsArtifactEnabled(Artifacts.Devotion)); if (WConfig.DC_MoreStats.Value) { ExtraStats.ChangeStats(self, newDisplayData.runReport); } ((Component)deathScreenExpanded.ItemArea.GetChild(1)).gameObject.AddComponent(); if (Object.op_Implicit((Object)(object)Run.instance)) { deathScreenExpanded.deathTimeStamp = Run.instance.fixedTime; } GameObject val = Addressables.LoadAssetAsync((object)"d79990e6848003d438cabcf79e7e5bf7").WaitForCompletion(); GameObject hideInventoryImage = val.GetComponent().itemInventoryDisplay.hideInventoryImage; GameObject val2 = (deathScreenExpanded.disabledInventory = Object.Instantiate(hideInventoryImage, ((Component)self.itemInventoryDisplay).gameObject.transform.parent)); ((Graphic)val2.GetComponent()).raycastTarget = false; ((Component)val2.transform.GetChild(0)).gameObject.SetActive(false); ((Graphic)((Component)val2.transform.GetChild(1)).GetComponent()).raycastTarget = false; Color val3 = default(Color); ((Color)(ref val3))..ctor(0.9683f, 0.8443f, 1f, 0.3922f); } orig.Invoke(self, newDisplayData); if (Object.op_Implicit((Object)(object)self.chatboxTransform)) { if (!deathScreenExpanded.oneTimeExtras) { deathScreenExpanded.chatActive = ((Component)self.chatboxTransform).gameObject.activeSelf; } else { ((Component)self.chatboxTransform).gameObject.SetActive(deathScreenExpanded.chatActive); ((Component)((Component)self.chatboxTransform).transform.GetChild(0)).GetComponent().OnEnable(); } } try { if (!deathScreenExpanded.oneTimeExtras && !deathScreenExpanded.isLogRunReport) { deathScreenExpanded.oneTimeExtras = true; ExtraStats.DifficultyTooltip(self); MakeChatToggleBotton(deathScreenExpanded); RectTransform component = ((Component)self).GetComponent(); component.anchorMax = Vector2.op_Implicit(new Vector3(0.96f, 0.95f)); component.anchorMin = Vector2.op_Implicit(new Vector3(0.04f, 0.05f)); RectTransform val4 = (RectTransform)((Component)self).transform.GetChild(0); RectTransform val5 = (RectTransform)((Component)self).transform.GetChild(0).GetChild(1); RectTransform val6 = (RectTransform)((Transform)val5).Find("StatsAndChatArea"); RectTransform val7 = (RectTransform)((Transform)val5).Find("RightArea"); component = ((Component)val6).GetComponent(); component = ((Component)val7).GetComponent(); LayoutElement component2 = ((Component)((Transform)val4).GetChild(0)).GetComponent(); component2.minHeight = 64f; component2.preferredHeight = 72f; val4.offsetMin = new Vector2(4f, -20f); val4.offsetMax = new Vector2(4f, 12f); Transform child = ((Transform)val4).GetChild(1); LayoutElement component3 = ((Component)deathScreenExpanded.childLocator.FindChild("StatsContainer").GetChild(2)).GetComponent(); component3.preferredHeight = 48f; Transform parent = ((TMP_Text)self.playerUsernameLabel).transform.parent; RectTransform val8 = (RectTransform)(object)((parent is RectTransform) ? parent : null); val8.offsetMax = new Vector2(-32f, -8f); val8.offsetMin = new Vector2(32f, 8f); ((Component)child.GetChild(0)).GetComponent().sizeDelta = new Vector2(0f, -28f); Transform child2 = deathScreenExpanded.childLocator.FindChild("InfoArea").GetChild(3); VerticalLayoutGroup component4 = ((Component)child2).GetComponent(); ((HorizontalOrVerticalLayoutGroup)component4).spacing = 12f; ((LayoutGroup)component4).padding = new RectOffset(8, 8, 8, 8); LayoutElement component5 = ((Component)child2.GetChild(0)).GetComponent(); component5.preferredHeight += 4f; ((LayoutGroup)((Component)child2.GetChild(0)).GetComponent()).padding.left = 24; ((LayoutGroup)((Component)child2.GetChild(1)).GetComponent()).padding.right = 24; } } catch (Exception message) { Log.LogError(message); } } public static void MakeChatToggleBotton(DeathScreenExpanded extras) { //IL_0006: Unknown result type (might be due to invalid IL or missing references) //IL_000c: Expected O, but got Unknown //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_0075: 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_0097: Expected O, but got Unknown //IL_00ba: Unknown result type (might be due to invalid IL or missing references) //IL_00df: Unknown result type (might be due to invalid IL or missing references) //IL_0149: 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_0186: Unknown result type (might be due to invalid IL or missing references) GameObject val = new GameObject("ChatToggle"); Image val2 = val.AddComponent(); Button val3 = val.AddComponent