Please disclose if your mod was created primarily using AI tools by adding the 'AI Generated' category. Failing to do so may result in the mod being removed from Thunderstore.
Decompiled source of LegendaryWeapons v1.0.5
plugins/LegendaryWeapons.dll
Decompiled 7 months agousing System; using System.Collections.Generic; using System.Diagnostics; using System.IO; using System.Reflection; using System.Runtime.CompilerServices; using System.Runtime.InteropServices; using System.Runtime.Versioning; using System.Security.Permissions; using System.Text.RegularExpressions; using BepInEx; using BepInEx.Configuration; using Jotunn; using Jotunn.Configs; using Jotunn.Entities; using Jotunn.Managers; using Jotunn.Utils; using UnityEngine; [assembly: CompilationRelaxations(8)] [assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)] [assembly: Debuggable(DebuggableAttribute.DebuggingModes.Default | DebuggableAttribute.DebuggingModes.DisableOptimizations | DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints | DebuggableAttribute.DebuggingModes.EnableEditAndContinue)] [assembly: AssemblyTitle("LegendaryWeapons")] [assembly: AssemblyDescription("")] [assembly: AssemblyConfiguration("")] [assembly: AssemblyCompany("")] [assembly: AssemblyProduct("LegendaryWeapons")] [assembly: AssemblyCopyright("Copyright © 2021")] [assembly: AssemblyTrademark("")] [assembly: ComVisible(false)] [assembly: Guid("e3243d22-4307-4008-ba36-9f326008cde5")] [assembly: AssemblyFileVersion("0.0.1.0")] [assembly: TargetFramework(".NETFramework,Version=v4.8", FrameworkDisplayName = ".NET Framework 4.8")] [assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)] [assembly: AssemblyVersion("0.0.1.0")] namespace LegendaryWeapons; internal class RecipeHelper { private static readonly Regex nukeWhiteSpaceRegex = new Regex("\\s+"); private static readonly Regex recipeEntryRegex = new Regex("^([a-zA-Z]+:[0-9]+)$"); public static RequirementConfig[] GetAsRequirementConfigArray(string configRecipe, string upgradeRecipe, int multiplier) { return GetAsRequirementConfigList(configRecipe, upgradeRecipe, multiplier).ToArray(); } public static Requirement[] GetAsPieceRequirementArray(string configRecipe, string upgradeRecipe, int multiplier) { //IL_004f: Unknown result type (might be due to invalid IL or missing references) //IL_0056: Expected O, but got Unknown try { List<RequirementConfig> asRequirementConfigList = GetAsRequirementConfigList(configRecipe, upgradeRecipe, multiplier); List<Requirement> list = new List<Requirement>(); foreach (RequirementConfig item in asRequirementConfigList) { GameObject prefab = PrefabManager.Instance.GetPrefab(item.Item); if ((Object)(object)prefab == (Object)null) { throw new Exception("Could not find item, please check config!"); } Requirement val = new Requirement(); val.m_resItem = prefab.GetComponent<ItemDrop>(); val.m_amount = item.Amount; val.m_amountPerLevel = item.AmountPerLevel; val.m_recover = item.Recover; list.Add(val); } return list.ToArray(); } catch (Exception ex) { Logger.LogError((object)("Could not convert recipe to Piece.Requirement array: " + ex)); return null; } } public static List<RequirementConfig> GetAsRequirementConfigList(string configRecipe, string upgradeRecipe, int multiplier) { //IL_006e: Unknown result type (might be due to invalid IL or missing references) //IL_0075: Expected O, but got Unknown try { configRecipe = nukeWhiteSpaceRegex.Replace(configRecipe, ""); upgradeRecipe = nukeWhiteSpaceRegex.Replace(upgradeRecipe, ""); if (!IsConfigRecipeValid(configRecipe, upgradeRecipe)) { throw new Exception("Config is not valid, please check the values!"); } List<RequirementConfig> list = new List<RequirementConfig>(); string[] array = configRecipe.Trim().Split(new char[1] { ',' }); string[] array2 = array; foreach (string text in array2) { RequirementConfig val = new RequirementConfig(); string[] array3 = text.Split(new char[1] { ':' }); val.Item = array3[0]; val.Amount = int.Parse(array3[1]); val.Recover = true; if (!Utility.IsNullOrWhiteSpace(upgradeRecipe)) { string[] array4 = upgradeRecipe.Trim().Split(new char[1] { ',' }); string[] array5 = array4; foreach (string text2 in array5) { string[] array6 = text2.Split(new char[1] { ':' }); if (val.Item == array6[0]) { val.AmountPerLevel = int.Parse(array6[1]) * multiplier; break; } } } list.Add(val); } return list; } catch (Exception ex) { Logger.LogError((object)("Could not convert recipe to RequirementConfig list: " + ex)); return null; } } public static bool IsConfigRecipeValid(string configRecipe, string upgradeRecipe) { try { bool result = true; string[] array = configRecipe.Split(new char[1] { ',' }); string[] array2 = array; foreach (string text in array2) { if (!recipeEntryRegex.IsMatch(text)) { result = false; Logger.LogError((object)("Cannot resolve " + text + " from the crafting recipe")); } } if (Utility.IsNullOrWhiteSpace(upgradeRecipe)) { return result; } string[] array3 = upgradeRecipe.Split(new char[1] { ',' }); string[] array4 = array3; foreach (string text2 in array4) { if (!recipeEntryRegex.IsMatch(text2)) { result = false; Logger.LogError((object)("Cannot resolve " + text2 + " from the upgrade recipe")); } } return result; } catch (Exception ex) { Logger.LogError((object)("Could not validate recipe due to an error: " + ex)); return false; } } } [BepInPlugin("DeathWizsh.LegendaryWeapons", "Legendary Weapons", "1.0.5")] [BepInDependency(/*Could not decode attribute arguments.*/)] [NetworkCompatibility(/*Could not decode attribute arguments.*/)] internal class LegendaryWeapons : BaseUnityPlugin { public const string PluginGUID = "DeathWizsh.LegendaryWeapons"; public const string PluginName = "Legendary Weapons"; public const string PluginVersion = "1.0.5"; private static string configFileName = "DeathWizsh.LegendaryWeapons.cfg"; private static string configFileFullPath; private AssetBundle legendaryWeaponsBundle; private GameObject demoHammerHammerPrefab; private GameObject demoHammerAtgeirPrefab; private GameObject cultivatorAtgeirAtgeirPrefab; private GameObject cultivatorAtgeirSpearPrefab; private GameObject cultivatorProjectilePrefab; private GameObject triSwordLightningPrefab; private GameObject triSwordFirePrefab; private GameObject triSwordFrostPrefab; private Sprite demolisherSprite; private Sprite himminAflSprite; private Sprite lightningSprite; private Sprite swordFireSprite; private Sprite frostSprite; private Sprite spearCarapaceSprite; private string[] configCraftingStationOptions = new string[9] { "None", "Disabled", "Workbench", "Forge", "Stonecutter", "Cauldron", "ArtisanTable", "BlackForge", "GaldrTable" }; private string defaultRecipeDemoHammer = "YggdrasilWood:15, BlackMarble:20, Eitr:15, Thunderstone:10"; private string defaultUpgradeRecipeDemoHammer = "YggdrasilWood:5,BlackMarble:5,Eitr:5,Thunderstone:5"; private string defaultRecipeTriSword = "YggdrasilWood:10,Thunderstone:10,Bilebag:10,FreezeGland:30"; private string defaultUpgradeRecipeTriSword = "YggdrasilWood:5,Thunderstone:5,Bilebag:2,FreezeGland:10"; private string defaultRecipeCultivatorAtgeir = "YggdrasilWood:15,Silver:25,Eitr:15,Thunderstone:10"; private string defaultUpgradeRecipeCultivatorAtgeir = "YggdrasilWood:5,Silver:5,Eitr:5,Thunderstone:5"; private string sectionGeneral = "1. General"; private ConfigEntry<bool> configEnable; private ConfigEntry<KeyboardShortcut> configWeaponModeKey; private string sectionDemoHammer = "2. Demolition Hammer"; private static ConfigEntry<bool> configDemoHammerEnable; private static ConfigEntry<string> configDemoHammerName; private static ConfigEntry<string> configDemoHammerDescription; private static ConfigEntry<string> configDemoHammerCraftingStation; private static ConfigEntry<int> configDemoHammerMinStationLevel; private static ConfigEntry<string> configDemoHammerRecipe; private static ConfigEntry<string> configDemoHammerRecipeUpgrade; private static ConfigEntry<int> configDemoHammerRecipeMultiplier; private static ConfigEntry<int> configDemoHammerMaxQuality; private static ConfigEntry<float> configDemoHammerMovementSpeed; private static ConfigEntry<float> configDemoHammerDamageMultiplier; private static ConfigEntry<int> configDemoHammerBlockArmor; private static ConfigEntry<int> configDemoHammerBlockForce; private static ConfigEntry<int> configDemoHammerKnockBack; private static ConfigEntry<int> configDemoHammerBackStab; private static ConfigEntry<int> configDemoHammerUseStamina; private static ConfigEntry<int> configDemoHammerUseStaminaHammer; private static ConfigEntry<int> configDemoHammerUseStaminaAtgeir; private string sectionTriSword = "3. Tri Sword"; private static ConfigEntry<bool> configTriSwordEnable; private static ConfigEntry<string> configTriSwordName; private static ConfigEntry<string> configTriSwordDescription; private static ConfigEntry<string> configTriSwordCraftingStation; private static ConfigEntry<int> configTriSwordMinStationLevel; private static ConfigEntry<string> configTriSwordRecipe; private static ConfigEntry<string> configTriSwordRecipeUpgrade; private static ConfigEntry<int> configTriSwordRecipeMultiplier; private static ConfigEntry<int> configTriSwordMaxQuality; private static ConfigEntry<float> configTriSwordMovementSpeed; private static ConfigEntry<float> configTriSwordDamageMultiplier; private static ConfigEntry<int> configTriSwordBlockArmor; private static ConfigEntry<int> configTriSwordBlockForce; private static ConfigEntry<int> configTriSwordKnockBack; private static ConfigEntry<int> configTriSwordFrostKnockBack; private static ConfigEntry<int> configTriSwordBackStab; private static ConfigEntry<int> configTriSwordUseStamina; private static ConfigEntry<int> configTriSwordUseStaminaLightning; private static ConfigEntry<int> configTriSwordUseStaminaFire; private static ConfigEntry<int> configTriSwordUseStaminaFrost; private string sectionCultivatorAtgeir = "4. Cultivator Atgeir"; private static ConfigEntry<bool> configCultivatorAtgeirEnable; private static ConfigEntry<string> configCultivatorAtgeirName; private static ConfigEntry<string> configCultivatorAtgeirDescription; private static ConfigEntry<string> configCultivatorAtgeirCraftingStation; private static ConfigEntry<int> configCultivatorAtgeirMinStationLevel; private static ConfigEntry<string> configCultivatorAtgeirRecipe; private static ConfigEntry<string> configCultivatorAtgeirRecipeUpgrade; private static ConfigEntry<int> configCultivatorAtgeirRecipeMultiplier; private static ConfigEntry<int> configCultivatorAtgeirMaxQuality; private static ConfigEntry<float> configCultivatorAtgeirMovementSpeed; private static ConfigEntry<float> configCultivatorAtgeirDamageMultiplier; private static ConfigEntry<int> configCultivatorAtgeirBlockArmor; private static ConfigEntry<int> configCultivatorAtgeirBlockForce; private static ConfigEntry<int> configCultivatorAtgeirKnockBack; private static ConfigEntry<int> configCultivatorAtgeirBackStab; private static ConfigEntry<int> configCultivatorAtgeirUseStamina; private static ConfigEntry<int> configCultivatorAtgeirUseStaminaAtgeir; private static ConfigEntry<int> configCultivatorAtgeirUseStaminaSpear; private ButtonConfig weaponModeButton; private CustomStatusEffect demoHammerHammerStatusEffect; private CustomStatusEffect demoHammerAtgeirStatusEffect; private CustomStatusEffect triSwordLightningStatusEffect; private CustomStatusEffect triSwordFireStatusEffect; private CustomStatusEffect triSwordFrostStatusEffect; private CustomStatusEffect cultivatorAtgeirAtgeirStatusEffect; private CustomStatusEffect cultivatorAtgeirSpearStatusEffect; private void Awake() { InitConfig(); if (!configEnable.Value) { return; } if (configEnable.Value && !configDemoHammerEnable.Value && !configTriSwordEnable.Value && !configCultivatorAtgeirEnable.Value) { Logger.LogWarning((object)"Mod is enabled but all weapons are disabled, skipping initialisation..."); return; } InitAssetBundle(); InitInputs(); InitStatusEffects(); if (configDemoHammerEnable.Value) { PrefabManager.OnVanillaPrefabsAvailable += AddDemoHammer; } if (configTriSwordEnable.Value) { PrefabManager.OnVanillaPrefabsAvailable += AddTriSword; } if (configCultivatorAtgeirEnable.Value) { PrefabManager.OnVanillaPrefabsAvailable += AddCultivatorAtgeir; } } private void OnDestroy() { ((BaseUnityPlugin)this).Config.Save(); } private void Update() { if (ZInput.instance == null || weaponModeButton == null || !((Object)(object)MessageHud.instance != (Object)null) || !ZInput.GetButtonDown(weaponModeButton.Name) || MessageHud.instance.m_msgQeue.Count != 0 || !Object.op_Implicit((Object)(object)Player.m_localPlayer)) { return; } ItemData currentWeapon = ((Humanoid)Player.m_localPlayer).GetCurrentWeapon(); if (currentWeapon != null) { string text = null; float drawDurationMin = currentWeapon.m_shared.m_attack.m_drawDurationMin; if (drawDurationMin == 8900f) { ItemDrop component = demoHammerAtgeirPrefab.GetComponent<ItemDrop>(); currentWeapon.m_dropPrefab = demoHammerAtgeirPrefab; currentWeapon.m_shared = component.m_itemData.m_shared; text = "Atgeir"; } else if (drawDurationMin == 8901f) { ItemDrop component2 = demoHammerHammerPrefab.GetComponent<ItemDrop>(); currentWeapon.m_dropPrefab = demoHammerHammerPrefab; currentWeapon.m_shared = component2.m_itemData.m_shared; text = "Hammer"; } else if (drawDurationMin == 8902f) { ItemDrop component3 = triSwordFirePrefab.GetComponent<ItemDrop>(); currentWeapon.m_dropPrefab = triSwordFirePrefab; currentWeapon.m_shared = component3.m_itemData.m_shared; text = "Fire"; } else if (drawDurationMin == 8903f) { ItemDrop component4 = triSwordFrostPrefab.GetComponent<ItemDrop>(); currentWeapon.m_dropPrefab = triSwordFrostPrefab; currentWeapon.m_shared = component4.m_itemData.m_shared; text = "Frost"; } else if (drawDurationMin == 8904f) { ItemDrop component5 = triSwordLightningPrefab.GetComponent<ItemDrop>(); currentWeapon.m_dropPrefab = triSwordLightningPrefab; currentWeapon.m_shared = component5.m_itemData.m_shared; text = "Lightning"; } else if (drawDurationMin == 8905f) { ItemDrop component6 = cultivatorAtgeirSpearPrefab.GetComponent<ItemDrop>(); currentWeapon.m_shared = component6.m_itemData.m_shared; text = "Spear"; } else if (drawDurationMin == 8906f) { ItemDrop component7 = cultivatorAtgeirAtgeirPrefab.GetComponent<ItemDrop>(); currentWeapon.m_shared = component7.m_itemData.m_shared; text = "Atgeir"; } if (text != null) { ((Humanoid)Player.m_localPlayer).UnequipItem(currentWeapon, true); ((Humanoid)Player.m_localPlayer).EquipItem(currentWeapon, true); MessageHud.instance.ShowMessage((MessageType)2, "Changed mode to " + text, 0, (Sprite)null, false); } } } private void AddDemoHammer() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown //IL_00b3: Unknown result type (might be due to invalid IL or missing references) //IL_00ba: Expected O, but got Unknown //IL_00c7: Unknown result type (might be due to invalid IL or missing references) //IL_00ce: Expected O, but got Unknown //IL_00e7: Unknown result type (might be due to invalid IL or missing references) //IL_00ee: Expected O, but got Unknown //IL_0154: Unknown result type (might be due to invalid IL or missing references) //IL_015e: Expected O, but got Unknown //IL_016b: Unknown result type (might be due to invalid IL or missing references) //IL_0175: Expected O, but got Unknown //IL_0170: Unknown result type (might be due to invalid IL or missing references) //IL_017a: Expected O, but got Unknown try { ItemConfig val = new ItemConfig(); val.CraftingStation = configDemoHammerCraftingStation.Value; val.MinStationLevel = configDemoHammerMinStationLevel.Value; val.Requirements = RecipeHelper.GetAsRequirementConfigArray(configDemoHammerRecipe.Value, configDemoHammerRecipeUpgrade.Value, configDemoHammerRecipeMultiplier.Value); ItemDrop component = demoHammerHammerPrefab.GetComponent<ItemDrop>(); GameObject val2 = PrefabManager.Instance.CreateClonedPrefab("lightningAOE_Hammer_DW", "lightningAOE"); Transform val3 = val2.transform.Find("AOE_ROD"); Transform val4 = val2.transform.Find("AOE_AREA"); ((Component)val3).gameObject.SetActive(false); ((Component)val4).gameObject.SetActive(false); GameObject val5 = new GameObject(); ((Object)val5).name = "JVLmock_fx_sledge_demolisher_hit"; EffectData val6 = new EffectData(); val6.m_prefab = val5; val6.m_enabled = true; val6.m_variant = -1; EffectData val7 = new EffectData(); val7.m_prefab = val2; val7.m_enabled = true; val7.m_variant = -1; List<EffectData> list = new List<EffectData> { val6, val7 }; component.m_itemData.m_shared.m_secondaryAttack.m_triggerEffect.m_effectPrefabs = list.ToArray(); PatchHammerStats(); ItemManager.Instance.AddItem(new CustomItem(demoHammerHammerPrefab, true, val)); ItemManager.Instance.AddItem(new CustomItem(demoHammerAtgeirPrefab, true, new ItemConfig())); PrefabManager.OnVanillaPrefabsAvailable -= AddDemoHammer; } catch (Exception ex) { Logger.LogError((object)("Could not initialise the Demolition Hammer: " + ex)); } } private void AddTriSword() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown //IL_0068: Unknown result type (might be due to invalid IL or missing references) //IL_0072: Expected O, but got Unknown //IL_007f: Unknown result type (might be due to invalid IL or missing references) //IL_0089: Expected O, but got Unknown //IL_0084: Unknown result type (might be due to invalid IL or missing references) //IL_008e: Expected O, but got Unknown //IL_009b: Unknown result type (might be due to invalid IL or missing references) //IL_00a5: Expected O, but got Unknown //IL_00a0: Unknown result type (might be due to invalid IL or missing references) //IL_00aa: Expected O, but got Unknown try { ItemConfig val = new ItemConfig(); val.CraftingStation = configTriSwordCraftingStation.Value; val.MinStationLevel = configTriSwordMinStationLevel.Value; val.Requirements = RecipeHelper.GetAsRequirementConfigArray(configTriSwordRecipe.Value, configTriSwordRecipeUpgrade.Value, configTriSwordRecipeMultiplier.Value); PatchTriSwordStats(); ItemManager.Instance.AddItem(new CustomItem(triSwordLightningPrefab, true, val)); ItemManager.Instance.AddItem(new CustomItem(triSwordFirePrefab, true, new ItemConfig())); ItemManager.Instance.AddItem(new CustomItem(triSwordFrostPrefab, true, new ItemConfig())); PrefabManager.OnVanillaPrefabsAvailable -= AddTriSword; } catch (Exception ex) { Logger.LogError((object)("Could not initialise the Tri Sword: " + ex)); } } private void AddCultivatorAtgeir() { //IL_0002: Unknown result type (might be due to invalid IL or missing references) //IL_0008: Expected O, but got Unknown //IL_00cb: Unknown result type (might be due to invalid IL or missing references) //IL_00d2: Expected O, but got Unknown //IL_0120: Unknown result type (might be due to invalid IL or missing references) //IL_012a: Expected O, but got Unknown //IL_0137: Unknown result type (might be due to invalid IL or missing references) //IL_0141: Expected O, but got Unknown //IL_013c: Unknown result type (might be due to invalid IL or missing references) //IL_0146: Expected O, but got Unknown try { ItemConfig val = new ItemConfig(); val.CraftingStation = configCultivatorAtgeirCraftingStation.Value; val.MinStationLevel = configCultivatorAtgeirMinStationLevel.Value; val.Requirements = RecipeHelper.GetAsRequirementConfigArray(configCultivatorAtgeirRecipe.Value, configCultivatorAtgeirRecipeUpgrade.Value, configCultivatorAtgeirRecipeMultiplier.Value); Projectile component = cultivatorProjectilePrefab.GetComponent<Projectile>(); GameObject val2 = PrefabManager.Instance.CreateClonedPrefab("lightningAOE_Projectile_DW", "lightningAOE"); Transform val3 = val2.transform.Find("AOE_ROD"); Transform val4 = val2.transform.Find("AOE_AREA"); Aoe component2 = ((Component)val4).GetComponent<Aoe>(); ((Component)val3).gameObject.SetActive(false); component2.m_damage.m_lightning = 27f; component2.m_radius = 3f; EffectData val5 = new EffectData(); val5.m_prefab = val2; val5.m_enabled = true; val5.m_variant = -1; List<EffectData> list = new List<EffectData> { val5 }; component.m_hitEffects.m_effectPrefabs = list.ToArray(); PatchCultivatorAtgeirStats(); ItemManager.Instance.AddItem(new CustomItem(cultivatorAtgeirAtgeirPrefab, true, val)); ItemManager.Instance.AddItem(new CustomItem(cultivatorAtgeirSpearPrefab, true, new ItemConfig())); PrefabManager.OnVanillaPrefabsAvailable -= AddCultivatorAtgeir; } catch (Exception ex) { Logger.LogError((object)("Could not initialise the Cultivator Atgeir: " + ex)); } } private void PatchHammerStats() { if (configDemoHammerEnable.Value) { ItemDrop component = demoHammerHammerPrefab.GetComponent<ItemDrop>(); component.m_itemData.m_shared.m_name = configDemoHammerName.Value; component.m_itemData.m_shared.m_description = configDemoHammerDescription.Value; component.m_itemData.m_shared.m_maxQuality = configDemoHammerMaxQuality.Value; component.m_itemData.m_shared.m_equipStatusEffect = demoHammerHammerStatusEffect.StatusEffect; component.m_itemData.m_shared.m_movementModifier = configDemoHammerMovementSpeed.Value; component.m_itemData.m_shared.m_damages.m_blunt = component.m_itemData.m_shared.m_damages.m_blunt * configDemoHammerDamageMultiplier.Value; component.m_itemData.m_shared.m_damages.m_lightning = component.m_itemData.m_shared.m_damages.m_lightning * configDemoHammerDamageMultiplier.Value; component.m_itemData.m_shared.m_blockPower = configDemoHammerBlockArmor.Value; component.m_itemData.m_shared.m_deflectionForce = configDemoHammerBlockForce.Value; component.m_itemData.m_shared.m_attackForce = configDemoHammerKnockBack.Value; component.m_itemData.m_shared.m_backstabBonus = configDemoHammerBackStab.Value; component.m_itemData.m_shared.m_attack.m_attackStamina = configDemoHammerUseStamina.Value; component.m_itemData.m_shared.m_secondaryAttack.m_attackStamina = configDemoHammerUseStaminaHammer.Value; ItemDrop component2 = demoHammerAtgeirPrefab.GetComponent<ItemDrop>(); component2.m_itemData.m_shared.m_name = configDemoHammerName.Value; component2.m_itemData.m_shared.m_description = configDemoHammerDescription.Value; component2.m_itemData.m_shared.m_maxQuality = configDemoHammerMaxQuality.Value; component2.m_itemData.m_shared.m_equipStatusEffect = demoHammerAtgeirStatusEffect.StatusEffect; component2.m_itemData.m_shared.m_movementModifier = configDemoHammerMovementSpeed.Value; component2.m_itemData.m_shared.m_damages.m_blunt = component2.m_itemData.m_shared.m_damages.m_blunt * configDemoHammerDamageMultiplier.Value; component2.m_itemData.m_shared.m_damages.m_lightning = component2.m_itemData.m_shared.m_damages.m_lightning * configDemoHammerDamageMultiplier.Value; component2.m_itemData.m_shared.m_blockPower = configDemoHammerBlockArmor.Value; component2.m_itemData.m_shared.m_deflectionForce = configDemoHammerBlockForce.Value; component2.m_itemData.m_shared.m_attackForce = configDemoHammerKnockBack.Value; component2.m_itemData.m_shared.m_backstabBonus = configDemoHammerBackStab.Value; component2.m_itemData.m_shared.m_attack.m_attackStamina = configDemoHammerUseStamina.Value; component2.m_itemData.m_shared.m_secondaryAttack.m_attackStamina = configDemoHammerUseStaminaAtgeir.Value; } } private void PatchTriSwordStats() { if (configTriSwordEnable.Value) { ItemDrop component = triSwordLightningPrefab.GetComponent<ItemDrop>(); component.m_itemData.m_shared.m_name = configTriSwordName.Value; component.m_itemData.m_shared.m_description = configTriSwordDescription.Value; component.m_itemData.m_shared.m_maxQuality = configTriSwordMaxQuality.Value; component.m_itemData.m_shared.m_equipStatusEffect = triSwordLightningStatusEffect.StatusEffect; component.m_itemData.m_shared.m_movementModifier = configTriSwordMovementSpeed.Value; component.m_itemData.m_shared.m_damages.m_slash = component.m_itemData.m_shared.m_damages.m_slash * configTriSwordDamageMultiplier.Value; component.m_itemData.m_shared.m_damages.m_lightning = component.m_itemData.m_shared.m_damages.m_lightning * configTriSwordDamageMultiplier.Value; component.m_itemData.m_shared.m_blockPower = configTriSwordBlockArmor.Value; component.m_itemData.m_shared.m_deflectionForce = configTriSwordBlockForce.Value; component.m_itemData.m_shared.m_attackForce = configTriSwordKnockBack.Value; component.m_itemData.m_shared.m_backstabBonus = configTriSwordBackStab.Value; component.m_itemData.m_shared.m_attack.m_attackStamina = configTriSwordUseStamina.Value; component.m_itemData.m_shared.m_secondaryAttack.m_attackStamina = configTriSwordUseStaminaLightning.Value; ItemDrop component2 = triSwordFirePrefab.GetComponent<ItemDrop>(); component2.m_itemData.m_shared.m_name = configTriSwordName.Value; component2.m_itemData.m_shared.m_description = configTriSwordDescription.Value; component2.m_itemData.m_shared.m_maxQuality = configTriSwordMaxQuality.Value; component2.m_itemData.m_shared.m_equipStatusEffect = triSwordFireStatusEffect.StatusEffect; component2.m_itemData.m_shared.m_movementModifier = configTriSwordMovementSpeed.Value; component2.m_itemData.m_shared.m_damages.m_slash = component2.m_itemData.m_shared.m_damages.m_slash * configTriSwordDamageMultiplier.Value; component2.m_itemData.m_shared.m_damages.m_fire = component2.m_itemData.m_shared.m_damages.m_fire * configTriSwordDamageMultiplier.Value; component2.m_itemData.m_shared.m_blockPower = configTriSwordBlockArmor.Value; component2.m_itemData.m_shared.m_deflectionForce = configTriSwordBlockForce.Value; component2.m_itemData.m_shared.m_attackForce = configTriSwordKnockBack.Value; component2.m_itemData.m_shared.m_backstabBonus = configTriSwordBackStab.Value; component2.m_itemData.m_shared.m_attack.m_attackStamina = configTriSwordUseStamina.Value; component2.m_itemData.m_shared.m_secondaryAttack.m_attackStamina = configTriSwordUseStaminaFire.Value; ItemDrop component3 = triSwordFrostPrefab.GetComponent<ItemDrop>(); component3.m_itemData.m_shared.m_name = configTriSwordName.Value; component3.m_itemData.m_shared.m_description = configTriSwordDescription.Value; component3.m_itemData.m_shared.m_maxQuality = configTriSwordMaxQuality.Value; component3.m_itemData.m_shared.m_equipStatusEffect = triSwordFrostStatusEffect.StatusEffect; component3.m_itemData.m_shared.m_movementModifier = configTriSwordMovementSpeed.Value; component3.m_itemData.m_shared.m_damages.m_slash = component3.m_itemData.m_shared.m_damages.m_slash * configTriSwordDamageMultiplier.Value; component3.m_itemData.m_shared.m_damages.m_frost = component3.m_itemData.m_shared.m_damages.m_frost * configTriSwordDamageMultiplier.Value; component3.m_itemData.m_shared.m_blockPower = configTriSwordBlockArmor.Value; component3.m_itemData.m_shared.m_deflectionForce = configTriSwordBlockForce.Value; component3.m_itemData.m_shared.m_attackForce = configTriSwordFrostKnockBack.Value; component3.m_itemData.m_shared.m_backstabBonus = configTriSwordBackStab.Value; component3.m_itemData.m_shared.m_attack.m_attackStamina = configTriSwordUseStamina.Value; component3.m_itemData.m_shared.m_secondaryAttack.m_attackStamina = configTriSwordUseStaminaFrost.Value; } } private void PatchCultivatorAtgeirStats() { if (configCultivatorAtgeirEnable.Value) { ItemDrop component = cultivatorAtgeirAtgeirPrefab.GetComponent<ItemDrop>(); component.m_itemData.m_shared.m_name = configCultivatorAtgeirName.Value; component.m_itemData.m_shared.m_description = configCultivatorAtgeirDescription.Value; component.m_itemData.m_shared.m_maxQuality = configCultivatorAtgeirMaxQuality.Value; component.m_itemData.m_shared.m_equipStatusEffect = cultivatorAtgeirAtgeirStatusEffect.StatusEffect; component.m_itemData.m_shared.m_movementModifier = configCultivatorAtgeirMovementSpeed.Value; component.m_itemData.m_shared.m_damages.m_pierce = component.m_itemData.m_shared.m_damages.m_pierce * configCultivatorAtgeirDamageMultiplier.Value; component.m_itemData.m_shared.m_damages.m_lightning = component.m_itemData.m_shared.m_damages.m_lightning * configCultivatorAtgeirDamageMultiplier.Value; component.m_itemData.m_shared.m_blockPower = configCultivatorAtgeirBlockArmor.Value; component.m_itemData.m_shared.m_deflectionForce = configCultivatorAtgeirBlockForce.Value; component.m_itemData.m_shared.m_attackForce = configCultivatorAtgeirKnockBack.Value; component.m_itemData.m_shared.m_backstabBonus = configCultivatorAtgeirBackStab.Value; component.m_itemData.m_shared.m_attack.m_attackStamina = configCultivatorAtgeirUseStamina.Value; component.m_itemData.m_shared.m_secondaryAttack.m_attackStamina = configCultivatorAtgeirUseStaminaAtgeir.Value; ItemDrop component2 = cultivatorAtgeirSpearPrefab.GetComponent<ItemDrop>(); component2.m_itemData.m_shared.m_name = configCultivatorAtgeirName.Value; component2.m_itemData.m_shared.m_description = configCultivatorAtgeirDescription.Value; component2.m_itemData.m_shared.m_maxQuality = configCultivatorAtgeirMaxQuality.Value; component2.m_itemData.m_shared.m_equipStatusEffect = cultivatorAtgeirSpearStatusEffect.StatusEffect; component2.m_itemData.m_shared.m_movementModifier = configCultivatorAtgeirMovementSpeed.Value; component2.m_itemData.m_shared.m_damages.m_pierce = component2.m_itemData.m_shared.m_damages.m_pierce * configCultivatorAtgeirDamageMultiplier.Value; component2.m_itemData.m_shared.m_damages.m_lightning = component2.m_itemData.m_shared.m_damages.m_lightning * configCultivatorAtgeirDamageMultiplier.Value; component2.m_itemData.m_shared.m_blockPower = configCultivatorAtgeirBlockArmor.Value; component2.m_itemData.m_shared.m_deflectionForce = configCultivatorAtgeirBlockForce.Value; component2.m_itemData.m_shared.m_attackForce = configCultivatorAtgeirKnockBack.Value; component2.m_itemData.m_shared.m_backstabBonus = configCultivatorAtgeirBackStab.Value; component2.m_itemData.m_shared.m_attack.m_attackStamina = configCultivatorAtgeirUseStamina.Value; component2.m_itemData.m_shared.m_secondaryAttack.m_attackStamina = configCultivatorAtgeirUseStaminaSpear.Value; } } private void PatchRecipe(WeaponType weaponType, RecipeUpdateType updateType = RecipeUpdateType.Recipe, bool disableOverride = false) { try { CustomRecipe val; if (disableOverride) { val = (CustomRecipe)(weaponType switch { WeaponType.Hammer => ItemManager.Instance.GetRecipe("Recipe_Demo_Hammer_Hammer_DW"), WeaponType.TriSword => ItemManager.Instance.GetRecipe("Recipe_Trisword_Lightning_DW"), WeaponType.CultivatorAtgeir => ItemManager.Instance.GetRecipe("Recipe_Cultivator_Atgeir_Atgeir_DW"), _ => throw new Exception("Could not find weapon type!"), }); if (val == null) { throw new Exception("Could not find recipe!"); } val.Recipe.m_craftingStation = null; val.Recipe.m_enabled = false; return; } bool value; string value2; int value3; string value4; string value5; int value6; switch (weaponType) { case WeaponType.Hammer: val = ItemManager.Instance.GetRecipe("Recipe_Demo_Hammer_Hammer_DW"); value = configDemoHammerEnable.Value; value2 = configDemoHammerCraftingStation.Value; value3 = configDemoHammerMinStationLevel.Value; value4 = configDemoHammerRecipe.Value; value5 = configDemoHammerRecipeUpgrade.Value; value6 = configDemoHammerRecipeMultiplier.Value; break; case WeaponType.TriSword: val = ItemManager.Instance.GetRecipe("Recipe_Trisword_Lightning_DW"); value = configTriSwordEnable.Value; value2 = configTriSwordCraftingStation.Value; value3 = configTriSwordMinStationLevel.Value; value4 = configTriSwordRecipe.Value; value5 = configTriSwordRecipeUpgrade.Value; value6 = configTriSwordRecipeMultiplier.Value; break; case WeaponType.CultivatorAtgeir: val = ItemManager.Instance.GetRecipe("Recipe_Cultivator_Atgeir_Atgeir_DW"); value = configCultivatorAtgeirEnable.Value; value2 = configCultivatorAtgeirCraftingStation.Value; value3 = configCultivatorAtgeirMinStationLevel.Value; value4 = configCultivatorAtgeirRecipe.Value; value5 = configCultivatorAtgeirRecipeUpgrade.Value; value6 = configCultivatorAtgeirRecipeMultiplier.Value; break; default: throw new Exception("Could not find weapon type!"); } if (!value) { return; } if (val == null) { throw new Exception("Could not find recipe!"); } switch (updateType) { case RecipeUpdateType.Recipe: { Requirement[] asPieceRequirementArray = RecipeHelper.GetAsPieceRequirementArray(value4, value5, value6); if (asPieceRequirementArray == null) { throw new Exception("Requirements is null"); } val.Recipe.m_resources = asPieceRequirementArray; break; } case RecipeUpdateType.CraftingStation: if (value2 == "None") { val.Recipe.m_craftingStation = null; val.Recipe.m_enabled = true; } else if (value2 == "Disabled") { val.Recipe.m_craftingStation = null; val.Recipe.m_enabled = false; } else { string internalName = CraftingStations.GetInternalName(value2); val.Recipe.m_enabled = true; val.Recipe.m_craftingStation = PrefabManager.Instance.GetPrefab(internalName).GetComponent<CraftingStation>(); } break; case RecipeUpdateType.MinRequiredLevel: val.Recipe.m_minStationLevel = value3; break; } } catch (Exception ex) { Logger.LogError((object)("Could not update recipe: " + ex)); } } private void InitConfig() { //IL_0021: Unknown result type (might be due to invalid IL or missing references) //IL_0035: Unknown result type (might be due to invalid IL or missing references) //IL_003a: Unknown result type (might be due to invalid IL or missing references) //IL_0043: Expected O, but got Unknown //IL_0043: Unknown result type (might be due to invalid IL or missing references) //IL_004d: Expected O, but got Unknown //IL_004d: Expected O, but got Unknown //IL_0083: 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_009d: Expected O, but got Unknown //IL_00b3: 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_00d5: Expected O, but got Unknown //IL_00d5: Unknown result type (might be due to invalid IL or missing references) //IL_00df: Expected O, but got Unknown //IL_00df: Expected O, but got Unknown //IL_010c: 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_0132: Expected O, but got Unknown //IL_0132: Unknown result type (might be due to invalid IL or missing references) //IL_013c: Expected O, but got Unknown //IL_013c: Expected O, but got Unknown //IL_0169: 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_018f: Expected O, but got Unknown //IL_018f: Unknown result type (might be due to invalid IL or missing references) //IL_0199: Expected O, but got Unknown //IL_0199: Expected O, but got Unknown //IL_01c7: 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_01f7: Expected O, but got Unknown //IL_01f7: Unknown result type (might be due to invalid IL or missing references) //IL_0201: Expected O, but got Unknown //IL_0201: Expected O, but got Unknown //IL_022e: Unknown result type (might be due to invalid IL or missing references) //IL_0242: Unknown result type (might be due to invalid IL or missing references) //IL_0247: Unknown result type (might be due to invalid IL or missing references) //IL_0250: Expected O, but got Unknown //IL_0250: Unknown result type (might be due to invalid IL or missing references) //IL_025a: Expected O, but got Unknown //IL_025a: Expected O, but got Unknown //IL_0287: 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_02ae: Expected O, but got Unknown //IL_02ae: Unknown result type (might be due to invalid IL or missing references) //IL_02b8: Expected O, but got Unknown //IL_02b8: Expected O, but got Unknown //IL_02e5: 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_030c: Expected O, but got Unknown //IL_030c: Unknown result type (might be due to invalid IL or missing references) //IL_0316: Expected O, but got Unknown //IL_0316: Expected O, but got Unknown //IL_0343: Unknown result type (might be due to invalid IL or missing references) //IL_0357: Unknown result type (might be due to invalid IL or missing references) //IL_035c: Unknown result type (might be due to invalid IL or missing references) //IL_0365: Expected O, but got Unknown //IL_0365: Unknown result type (might be due to invalid IL or missing references) //IL_036f: Expected O, but got Unknown //IL_036f: Expected O, but got Unknown //IL_039c: Unknown result type (might be due to invalid IL or missing references) //IL_03b0: 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_03be: Expected O, but got Unknown //IL_03be: Unknown result type (might be due to invalid IL or missing references) //IL_03c8: Expected O, but got Unknown //IL_03c8: Expected O, but got Unknown //IL_03f5: 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) //IL_0412: Unknown result type (might be due to invalid IL or missing references) //IL_041b: Expected O, but got Unknown //IL_041b: Unknown result type (might be due to invalid IL or missing references) //IL_0425: Expected O, but got Unknown //IL_0425: Expected O, but got Unknown //IL_0452: Unknown result type (might be due to invalid IL or missing references) //IL_046a: Unknown result type (might be due to invalid IL or missing references) //IL_046f: Unknown result type (might be due to invalid IL or missing references) //IL_0478: Expected O, but got Unknown //IL_0478: Unknown result type (might be due to invalid IL or missing references) //IL_0482: Expected O, but got Unknown //IL_0482: Expected O, but got Unknown //IL_04af: Unknown result type (might be due to invalid IL or missing references) //IL_04c4: Unknown result type (might be due to invalid IL or missing references) //IL_04c9: Unknown result type (might be due to invalid IL or missing references) //IL_04d2: Expected O, but got Unknown //IL_04d2: Unknown result type (might be due to invalid IL or missing references) //IL_04dc: Expected O, but got Unknown //IL_04dc: Expected O, but got Unknown //IL_0509: Unknown result type (might be due to invalid IL or missing references) //IL_051e: Unknown result type (might be due to invalid IL or missing references) //IL_0523: Unknown result type (might be due to invalid IL or missing references) //IL_052c: Expected O, but got Unknown //IL_052c: Unknown result type (might be due to invalid IL or missing references) //IL_0536: Expected O, but got Unknown //IL_0536: Expected O, but got Unknown //IL_0563: Unknown result type (might be due to invalid IL or missing references) //IL_0578: Unknown result type (might be due to invalid IL or missing references) //IL_057d: Unknown result type (might be due to invalid IL or missing references) //IL_0586: Expected O, but got Unknown //IL_0586: Unknown result type (might be due to invalid IL or missing references) //IL_0590: Expected O, but got Unknown //IL_0590: Expected O, but got Unknown //IL_05bd: Unknown result type (might be due to invalid IL or missing references) //IL_05d1: Unknown result type (might be due to invalid IL or missing references) //IL_05d6: Unknown result type (might be due to invalid IL or missing references) //IL_05df: Expected O, but got Unknown //IL_05df: Unknown result type (might be due to invalid IL or missing references) //IL_05e9: Expected O, but got Unknown //IL_05e9: Expected O, but got Unknown //IL_0616: Unknown result type (might be due to invalid IL or missing references) //IL_062b: Unknown result type (might be due to invalid IL or missing references) //IL_0630: Unknown result type (might be due to invalid IL or missing references) //IL_0639: Expected O, but got Unknown //IL_0639: Unknown result type (might be due to invalid IL or missing references) //IL_0643: Expected O, but got Unknown //IL_0643: Expected O, but got Unknown //IL_0670: Unknown result type (might be due to invalid IL or missing references) //IL_0685: Unknown result type (might be due to invalid IL or missing references) //IL_068a: Unknown result type (might be due to invalid IL or missing references) //IL_0693: Expected O, but got Unknown //IL_0693: Unknown result type (might be due to invalid IL or missing references) //IL_069d: Expected O, but got Unknown //IL_069d: Expected O, but got Unknown //IL_06ca: Unknown result type (might be due to invalid IL or missing references) //IL_06df: Unknown result type (might be due to invalid IL or missing references) //IL_06e4: Unknown result type (might be due to invalid IL or missing references) //IL_06ed: Expected O, but got Unknown //IL_06ed: Unknown result type (might be due to invalid IL or missing references) //IL_06f7: Expected O, but got Unknown //IL_06f7: Expected O, but got Unknown //IL_0724: Unknown result type (might be due to invalid IL or missing references) //IL_0738: Unknown result type (might be due to invalid IL or missing references) //IL_073d: Unknown result type (might be due to invalid IL or missing references) //IL_0746: Expected O, but got Unknown //IL_0746: Unknown result type (might be due to invalid IL or missing references) //IL_0750: Expected O, but got Unknown //IL_0750: Expected O, but got Unknown //IL_077d: Unknown result type (might be due to invalid IL or missing references) //IL_0795: Unknown result type (might be due to invalid IL or missing references) //IL_079a: Unknown result type (might be due to invalid IL or missing references) //IL_07a3: Expected O, but got Unknown //IL_07a3: Unknown result type (might be due to invalid IL or missing references) //IL_07ad: Expected O, but got Unknown //IL_07ad: Expected O, but got Unknown //IL_07da: Unknown result type (might be due to invalid IL or missing references) //IL_07f2: 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_0800: Expected O, but got Unknown //IL_0800: Unknown result type (might be due to invalid IL or missing references) //IL_080a: Expected O, but got Unknown //IL_080a: Expected O, but got Unknown //IL_0837: Unknown result type (might be due to invalid IL or missing references) //IL_0859: Unknown result type (might be due to invalid IL or missing references) //IL_085e: Unknown result type (might be due to invalid IL or missing references) //IL_0867: Expected O, but got Unknown //IL_0867: Unknown result type (might be due to invalid IL or missing references) //IL_0871: Expected O, but got Unknown //IL_0871: Expected O, but got Unknown //IL_089e: Unknown result type (might be due to invalid IL or missing references) //IL_08b2: Unknown result type (might be due to invalid IL or missing references) //IL_08b7: Unknown result type (might be due to invalid IL or missing references) //IL_08c0: Expected O, but got Unknown //IL_08c0: Unknown result type (might be due to invalid IL or missing references) //IL_08ca: Expected O, but got Unknown //IL_08ca: Expected O, but got Unknown //IL_08f7: Unknown result type (might be due to invalid IL or missing references) //IL_0910: Unknown result type (might be due to invalid IL or missing references) //IL_0915: Unknown result type (might be due to invalid IL or missing references) //IL_091e: Expected O, but got Unknown //IL_091e: Unknown result type (might be due to invalid IL or missing references) //IL_0928: Expected O, but got Unknown //IL_0928: Expected O, but got Unknown //IL_0955: Unknown result type (might be due to invalid IL or missing references) //IL_096e: Unknown result type (might be due to invalid IL or missing references) //IL_0973: Unknown result type (might be due to invalid IL or missing references) //IL_097c: Expected O, but got Unknown //IL_097c: Unknown result type (might be due to invalid IL or missing references) //IL_0986: Expected O, but got Unknown //IL_0986: Expected O, but got Unknown //IL_09b3: Unknown result type (might be due to invalid IL or missing references) //IL_09c7: Unknown result type (might be due to invalid IL or missing references) //IL_09cc: Unknown result type (might be due to invalid IL or missing references) //IL_09d5: Expected O, but got Unknown //IL_09d5: Unknown result type (might be due to invalid IL or missing references) //IL_09df: Expected O, but got Unknown //IL_09df: Expected O, but got Unknown //IL_0a0c: Unknown result type (might be due to invalid IL or missing references) //IL_0a20: Unknown result type (might be due to invalid IL or missing references) //IL_0a25: Unknown result type (might be due to invalid IL or missing references) //IL_0a2e: Expected O, but got Unknown //IL_0a2e: Unknown result type (might be due to invalid IL or missing references) //IL_0a38: Expected O, but got Unknown //IL_0a38: Expected O, but got Unknown //IL_0a65: Unknown result type (might be due to invalid IL or missing references) //IL_0a7d: Unknown result type (might be due to invalid IL or missing references) //IL_0a82: Unknown result type (might be due to invalid IL or missing references) //IL_0a8b: Expected O, but got Unknown //IL_0a8b: Unknown result type (might be due to invalid IL or missing references) //IL_0a95: Expected O, but got Unknown //IL_0a95: Expected O, but got Unknown //IL_0ac2: Unknown result type (might be due to invalid IL or missing references) //IL_0ada: Unknown result type (might be due to invalid IL or missing references) //IL_0adf: Unknown result type (might be due to invalid IL or missing references) //IL_0ae8: Expected O, but got Unknown //IL_0ae8: Unknown result type (might be due to invalid IL or missing references) //IL_0af2: Expected O, but got Unknown //IL_0af2: Expected O, but got Unknown //IL_0b1f: Unknown result type (might be due to invalid IL or missing references) //IL_0b34: Unknown result type (might be due to invalid IL or missing references) //IL_0b39: Unknown result type (might be due to invalid IL or missing references) //IL_0b42: Expected O, but got Unknown //IL_0b42: Unknown result type (might be due to invalid IL or missing references) //IL_0b4c: Expected O, but got Unknown //IL_0b4c: Expected O, but got Unknown //IL_0b79: Unknown result type (might be due to invalid IL or missing references) //IL_0b8e: Unknown result type (might be due to invalid IL or missing references) //IL_0b93: Unknown result type (might be due to invalid IL or missing references) //IL_0b9c: Expected O, but got Unknown //IL_0b9c: Unknown result type (might be due to invalid IL or missing references) //IL_0ba6: Expected O, but got Unknown //IL_0ba6: Expected O, but got Unknown //IL_0bd3: 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_0bed: Unknown result type (might be due to invalid IL or missing references) //IL_0bf6: Expected O, but got Unknown //IL_0bf6: Unknown result type (might be due to invalid IL or missing references) //IL_0c00: Expected O, but got Unknown //IL_0c00: Expected O, but got Unknown //IL_0c2d: Unknown result type (might be due to invalid IL or missing references) //IL_0c42: Unknown result type (might be due to invalid IL or missing references) //IL_0c47: Unknown result type (might be due to invalid IL or missing references) //IL_0c50: Expected O, but got Unknown //IL_0c50: Unknown result type (might be due to invalid IL or missing references) //IL_0c5a: Expected O, but got Unknown //IL_0c5a: Expected O, but got Unknown //IL_0c87: Unknown result type (might be due to invalid IL or missing references) //IL_0c9b: Unknown result type (might be due to invalid IL or missing references) //IL_0ca0: Unknown result type (might be due to invalid IL or missing references) //IL_0ca9: Expected O, but got Unknown //IL_0ca9: Unknown result type (might be due to invalid IL or missing references) //IL_0cb3: Expected O, but got Unknown //IL_0cb3: Expected O, but got Unknown //IL_0ce0: Unknown result type (might be due to invalid IL or missing references) //IL_0cf5: Unknown result type (might be due to invalid IL or missing references) //IL_0cfa: Unknown result type (might be due to invalid IL or missing references) //IL_0d03: Expected O, but got Unknown //IL_0d03: Unknown result type (might be due to invalid IL or missing references) //IL_0d0d: Expected O, but got Unknown //IL_0d0d: Expected O, but got Unknown //IL_0d3a: Unknown result type (might be due to invalid IL or missing references) //IL_0d4f: Unknown result type (might be due to invalid IL or missing references) //IL_0d54: Unknown result type (might be due to invalid IL or missing references) //IL_0d5d: Expected O, but got Unknown //IL_0d5d: Unknown result type (might be due to invalid IL or missing references) //IL_0d67: Expected O, but got Unknown //IL_0d67: Expected O, but got Unknown //IL_0d94: Unknown result type (might be due to invalid IL or missing references) //IL_0da9: Unknown result type (might be due to invalid IL or missing references) //IL_0dae: Unknown result type (might be due to invalid IL or missing references) //IL_0db7: Expected O, but got Unknown //IL_0db7: Unknown result type (might be due to invalid IL or missing references) //IL_0dc1: Expected O, but got Unknown //IL_0dc1: Expected O, but got Unknown //IL_0dee: Unknown result type (might be due to invalid IL or missing references) //IL_0e03: Unknown result type (might be due to invalid IL or missing references) //IL_0e08: Unknown result type (might be due to invalid IL or missing references) //IL_0e11: Expected O, but got Unknown //IL_0e11: Unknown result type (might be due to invalid IL or missing references) //IL_0e1b: Expected O, but got Unknown //IL_0e1b: Expected O, but got Unknown //IL_0e48: Unknown result type (might be due to invalid IL or missing references) //IL_0e5c: Unknown result type (might be due to invalid IL or missing references) //IL_0e61: Unknown result type (might be due to invalid IL or missing references) //IL_0e6a: Expected O, but got Unknown //IL_0e6a: Unknown result type (might be due to invalid IL or missing references) //IL_0e74: Expected O, but got Unknown //IL_0e74: Expected O, but got Unknown //IL_0ea1: Unknown result type (might be due to invalid IL or missing references) //IL_0eb9: Unknown result type (might be due to invalid IL or missing references) //IL_0ebe: Unknown result type (might be due to invalid IL or missing references) //IL_0ec7: Expected O, but got Unknown //IL_0ec7: Unknown result type (might be due to invalid IL or missing references) //IL_0ed1: Expected O, but got Unknown //IL_0ed1: Expected O, but got Unknown //IL_0efe: Unknown result type (might be due to invalid IL or missing references) //IL_0f16: Unknown result type (might be due to invalid IL or missing references) //IL_0f1b: Unknown result type (might be due to invalid IL or missing references) //IL_0f24: Expected O, but got Unknown //IL_0f24: Unknown result type (might be due to invalid IL or missing references) //IL_0f2e: Expected O, but got Unknown //IL_0f2e: Expected O, but got Unknown //IL_0f5b: Unknown result type (might be due to invalid IL or missing references) //IL_0f7d: Unknown result type (might be due to invalid IL or missing references) //IL_0f82: Unknown result type (might be due to invalid IL or missing references) //IL_0f8b: Expected O, but got Unknown //IL_0f8b: Unknown result type (might be due to invalid IL or missing references) //IL_0f95: Expected O, but got Unknown //IL_0f95: Expected O, but got Unknown //IL_0fc2: Unknown result type (might be due to invalid IL or missing references) //IL_0fd6: Unknown result type (might be due to invalid IL or missing references) //IL_0fdb: Unknown result type (might be due to invalid IL or missing references) //IL_0fe4: Expected O, but got Unknown //IL_0fe4: Unknown result type (might be due to invalid IL or missing references) //IL_0fee: Expected O, but got Unknown //IL_0fee: Expected O, but got Unknown //IL_101b: Unknown result type (might be due to invalid IL or missing references) //IL_1034: Unknown result type (might be due to invalid IL or missing references) //IL_1039: Unknown result type (might be due to invalid IL or missing references) //IL_1042: Expected O, but got Unknown //IL_1042: Unknown result type (might be due to invalid IL or missing references) //IL_104c: Expected O, but got Unknown //IL_104c: Expected O, but got Unknown //IL_1079: Unknown result type (might be due to invalid IL or missing references) //IL_1092: Unknown result type (might be due to invalid IL or missing references) //IL_1097: Unknown result type (might be due to invalid IL or missing references) //IL_10a0: Expected O, but got Unknown //IL_10a0: Unknown result type (might be due to invalid IL or missing references) //IL_10aa: Expected O, but got Unknown //IL_10aa: Expected O, but got Unknown //IL_10d7: Unknown result type (might be due to invalid IL or missing references) //IL_10eb: Unknown result type (might be due to invalid IL or missing references) //IL_10f0: Unknown result type (might be due to invalid IL or missing references) //IL_10f9: Expected O, but got Unknown //IL_10f9: Unknown result type (might be due to invalid IL or missing references) //IL_1103: Expected O, but got Unknown //IL_1103: Expected O, but got Unknown //IL_1130: Unknown result type (might be due to invalid IL or missing references) //IL_1144: Unknown result type (might be due to invalid IL or missing references) //IL_1149: Unknown result type (might be due to invalid IL or missing references) //IL_1152: Expected O, but got Unknown //IL_1152: Unknown result type (might be due to invalid IL or missing references) //IL_115c: Expected O, but got Unknown //IL_115c: Expected O, but got Unknown //IL_1189: Unknown result type (might be due to invalid IL or missing references) //IL_11a1: Unknown result type (might be due to invalid IL or missing references) //IL_11a6: Unknown result type (might be due to invalid IL or missing references) //IL_11af: Expected O, but got Unknown //IL_11af: Unknown result type (might be due to invalid IL or missing references) //IL_11b9: Expected O, but got Unknown //IL_11b9: Expected O, but got Unknown //IL_11e6: Unknown result type (might be due to invalid IL or missing references) //IL_11fe: Unknown result type (might be due to invalid IL or missing references) //IL_1203: Unknown result type (might be due to invalid IL or missing references) //IL_120c: Expected O, but got Unknown //IL_120c: Unknown result type (might be due to invalid IL or missing references) //IL_1216: Expected O, but got Unknown //IL_1216: Expected O, but got Unknown //IL_1243: Unknown result type (might be due to invalid IL or missing references) //IL_1258: Unknown result type (might be due to invalid IL or missing references) //IL_125d: Unknown result type (might be due to invalid IL or missing references) //IL_1266: Expected O, but got Unknown //IL_1266: Unknown result type (might be due to invalid IL or missing references) //IL_1270: Expected O, but got Unknown //IL_1270: Expected O, but got Unknown //IL_129d: Unknown result type (might be due to invalid IL or missing references) //IL_12b2: Unknown result type (might be due to invalid IL or missing references) //IL_12b7: Unknown result type (might be due to invalid IL or missing references) //IL_12c0: Expected O, but got Unknown //IL_12c0: Unknown result type (might be due to invalid IL or missing references) //IL_12ca: Expected O, but got Unknown //IL_12ca: Expected O, but got Unknown //IL_12f7: Unknown result type (might be due to invalid IL or missing references) //IL_130c: Unknown result type (might be due to invalid IL or missing references) //IL_1311: Unknown result type (might be due to invalid IL or missing references) //IL_131a: Expected O, but got Unknown //IL_131a: Unknown result type (might be due to invalid IL or missing references) //IL_1324: Expected O, but got Unknown //IL_1324: Expected O, but got Unknown //IL_1351: Unknown result type (might be due to invalid IL or missing references) //IL_1365: Unknown result type (might be due to invalid IL or missing references) //IL_136a: Unknown result type (might be due to invalid IL or missing references) //IL_1373: Expected O, but got Unknown //IL_1373: Unknown result type (might be due to invalid IL or missing references) //IL_137d: Expected O, but got Unknown //IL_137d: Expected O, but got Unknown //IL_13aa: Unknown result type (might be due to invalid IL or missing references) //IL_13bf: Unknown result type (might be due to invalid IL or missing references) //IL_13c4: Unknown result type (might be due to invalid IL or missing references) //IL_13cd: Expected O, but got Unknown //IL_13cd: Unknown result type (might be due to invalid IL or missing references) //IL_13d7: Expected O, but got Unknown //IL_13d7: Expected O, but got Unknown //IL_1404: Unknown result type (might be due to invalid IL or missing references) //IL_1419: Unknown result type (might be due to invalid IL or missing references) //IL_141e: Unknown result type (might be due to invalid IL or missing references) //IL_1427: Expected O, but got Unknown //IL_1427: Unknown result type (might be due to invalid IL or missing references) //IL_1431: Expected O, but got Unknown //IL_1431: Expected O, but got Unknown //IL_146b: Unknown result type (might be due to invalid IL or missing references) //IL_1480: Unknown result type (might be due to invalid IL or missing references) //IL_1485: Unknown result type (might be due to invalid IL or missing references) //IL_148e: Expected O, but got Unknown //IL_148e: Unknown result type (might be due to invalid IL or missing references) //IL_1498: Expected O, but got Unknown //IL_1498: Expected O, but got Unknown try { ((BaseUnityPlugin)this).Config.SaveOnConfigSet = false; configEnable = ((BaseUnityPlugin)this).Config.Bind<bool>(new ConfigDefinition(sectionGeneral, "Enable"), true, new ConfigDescription("Enable this mod", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configEnable.SettingChanged += delegate { if (configEnable.Value) { PatchRecipe(WeaponType.Hammer, RecipeUpdateType.CraftingStation); PatchRecipe(WeaponType.TriSword, RecipeUpdateType.CraftingStation); PatchRecipe(WeaponType.CultivatorAtgeir, RecipeUpdateType.CraftingStation); } else { PatchRecipe(WeaponType.Hammer, RecipeUpdateType.CraftingStation, disableOverride: true); PatchRecipe(WeaponType.TriSword, RecipeUpdateType.CraftingStation, disableOverride: true); PatchRecipe(WeaponType.CultivatorAtgeir, RecipeUpdateType.CraftingStation, disableOverride: true); Logger.LogWarning((object)"LegendaryWeapons is now disabled! The weapons can no longer be crafted or upgraded and will be deleted when players relog!"); } }; configWeaponModeKey = ((BaseUnityPlugin)this).Config.Bind<KeyboardShortcut>(sectionGeneral, "Weapon mode key", new KeyboardShortcut((KeyCode)121, Array.Empty<KeyCode>()), new ConfigDescription("Key to change the weaponmode (applies to all weapons)", (AcceptableValueBase)null, Array.Empty<object>())); configDemoHammerEnable = ((BaseUnityPlugin)this).Config.Bind<bool>(new ConfigDefinition(sectionDemoHammer, "Enable"), true, new ConfigDescription("Enable the Demolition Hammer", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configDemoHammerEnable.SettingChanged += delegate { if (configDemoHammerEnable.Value) { PatchRecipe(WeaponType.Hammer, RecipeUpdateType.CraftingStation); } else { PatchRecipe(WeaponType.Hammer, RecipeUpdateType.CraftingStation, disableOverride: true); Logger.LogWarning((object)("The " + configDemoHammerName.Value + " is now disabled! The weapon can no longer be crafted or upgraded and will be deleted when players relog!")); } }; configDemoHammerName = ((BaseUnityPlugin)this).Config.Bind<string>(new ConfigDefinition(sectionDemoHammer, "Name"), "Tordenvær", new ConfigDescription("The name given to the item", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configDemoHammerName.SettingChanged += delegate { PatchHammerStats(); }; configDemoHammerDescription = ((BaseUnityPlugin)this).Config.Bind<string>(new ConfigDefinition(sectionDemoHammer, "Description"), "It might not be Mjölnir, but it still hits like a thunderstorm!", new ConfigDescription("The description given to the item", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configDemoHammerDescription.SettingChanged += delegate { PatchHammerStats(); }; configDemoHammerCraftingStation = ((BaseUnityPlugin)this).Config.Bind<string>(new ConfigDefinition(sectionDemoHammer, "Crafting station"), "Forge", new ConfigDescription("The crafting station the item can be created in", (AcceptableValueBase)(object)new AcceptableValueList<string>(configCraftingStationOptions), new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configDemoHammerCraftingStation.SettingChanged += delegate { PatchRecipe(WeaponType.Hammer, RecipeUpdateType.CraftingStation); }; configDemoHammerMinStationLevel = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionDemoHammer, "Required station level"), 1, new ConfigDescription("The required station level to craft the item", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configDemoHammerMinStationLevel.SettingChanged += delegate { PatchRecipe(WeaponType.Hammer, RecipeUpdateType.MinRequiredLevel); }; configDemoHammerRecipe = ((BaseUnityPlugin)this).Config.Bind<string>(new ConfigDefinition(sectionDemoHammer, "Crafting costs"), defaultRecipeDemoHammer, new ConfigDescription("The items required to craft the item", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configDemoHammerRecipe.SettingChanged += delegate { PatchRecipe(WeaponType.Hammer); }; configDemoHammerRecipeUpgrade = ((BaseUnityPlugin)this).Config.Bind<string>(new ConfigDefinition(sectionDemoHammer, "Upgrade costs"), defaultUpgradeRecipeDemoHammer, new ConfigDescription("The costs to upgrade the item", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configDemoHammerRecipeUpgrade.SettingChanged += delegate { PatchRecipe(WeaponType.Hammer); }; configDemoHammerRecipeMultiplier = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionDemoHammer, "Upgrade multiplier"), 1, new ConfigDescription("The multiplier applied to the upgrade costs", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configDemoHammerRecipeMultiplier.SettingChanged += delegate { PatchRecipe(WeaponType.Hammer); }; configDemoHammerMaxQuality = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionDemoHammer, "Max quality"), 4, new ConfigDescription("The maximum quality the item can become", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configDemoHammerMaxQuality.SettingChanged += delegate { PatchHammerStats(); }; configDemoHammerMovementSpeed = ((BaseUnityPlugin)this).Config.Bind<float>(new ConfigDefinition(sectionDemoHammer, "Movement speed"), -0.05f, new ConfigDescription("The movement speed stat on the item", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configDemoHammerMovementSpeed.SettingChanged += delegate { PatchHammerStats(); }; configDemoHammerDamageMultiplier = ((BaseUnityPlugin)this).Config.Bind<float>(new ConfigDefinition(sectionDemoHammer, "Damage multiplier"), 1f, new ConfigDescription("Multiplier to adjust the damage on the item (90 blunt, 30 lightning)", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configDemoHammerDamageMultiplier.SettingChanged += delegate { PatchHammerStats(); }; configDemoHammerBlockArmor = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionDemoHammer, "Block armor"), 47, new ConfigDescription("The block armor on the item", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configDemoHammerBlockArmor.SettingChanged += delegate { PatchHammerStats(); }; configDemoHammerBlockForce = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionDemoHammer, "Block force"), 30, new ConfigDescription("The block force on the item", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configDemoHammerBlockForce.SettingChanged += delegate { PatchHammerStats(); }; configDemoHammerKnockBack = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionDemoHammer, "Knockback"), 75, new ConfigDescription("The knockback on the item", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configDemoHammerKnockBack.SettingChanged += delegate { PatchHammerStats(); }; configDemoHammerBackStab = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionDemoHammer, "Backstab"), 3, new ConfigDescription("The backstab on the item", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configDemoHammerBackStab.SettingChanged += delegate { PatchHammerStats(); }; configDemoHammerUseStamina = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionDemoHammer, "Attack stamina"), 22, new ConfigDescription("Normal attack stamina usage", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configDemoHammerUseStamina.SettingChanged += delegate { PatchHammerStats(); }; configDemoHammerUseStaminaHammer = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionDemoHammer, "Secondary hammer ability stamina"), 32, new ConfigDescription("The secondary hammer attack stamina usage", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configDemoHammerUseStaminaHammer.SettingChanged += delegate { PatchHammerStats(); }; configDemoHammerUseStaminaAtgeir = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionDemoHammer, "Secondary atgeir ability stamina"), 40, new ConfigDescription("The secondary atgeir attack stamina usage", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configDemoHammerUseStaminaAtgeir.SettingChanged += delegate { PatchHammerStats(); }; configTriSwordEnable = ((BaseUnityPlugin)this).Config.Bind<bool>(new ConfigDefinition(sectionTriSword, "Enable"), true, new ConfigDescription("Enable the Tri Sword", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configTriSwordEnable.SettingChanged += delegate { if (configTriSwordEnable.Value) { PatchRecipe(WeaponType.TriSword, RecipeUpdateType.CraftingStation); } else { PatchRecipe(WeaponType.TriSword, RecipeUpdateType.CraftingStation, disableOverride: true); Logger.LogWarning((object)("The " + configTriSwordName.Value + " is now disabled! The weapon can no longer be crafted or upgraded and will be deleted when players relog!")); } }; configTriSwordName = ((BaseUnityPlugin)this).Config.Bind<string>(new ConfigDefinition(sectionTriSword, "Name"), "Tresverd", new ConfigDescription("The name given to the item", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configTriSwordName.SettingChanged += delegate { PatchTriSwordStats(); }; configTriSwordDescription = ((BaseUnityPlugin)this).Config.Bind<string>(new ConfigDefinition(sectionTriSword, "Description"), "Sometimes it seems as if the blade is phasing in and out from different dimensions...", new ConfigDescription("The description given to the item", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configTriSwordDescription.SettingChanged += delegate { PatchTriSwordStats(); }; configTriSwordCraftingStation = ((BaseUnityPlugin)this).Config.Bind<string>(new ConfigDefinition(sectionTriSword, "Crafting station"), "Forge", new ConfigDescription("The crafting station the item can be created in", (AcceptableValueBase)(object)new AcceptableValueList<string>(configCraftingStationOptions), new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configTriSwordCraftingStation.SettingChanged += delegate { PatchRecipe(WeaponType.TriSword, RecipeUpdateType.CraftingStation); }; configTriSwordMinStationLevel = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionTriSword, "Required station level"), 1, new ConfigDescription("The required station level to craft the item", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configTriSwordMinStationLevel.SettingChanged += delegate { PatchRecipe(WeaponType.TriSword, RecipeUpdateType.MinRequiredLevel); }; configTriSwordRecipe = ((BaseUnityPlugin)this).Config.Bind<string>(new ConfigDefinition(sectionTriSword, "Crafting costs"), defaultRecipeTriSword, new ConfigDescription("The items required to craft the item", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configTriSwordRecipe.SettingChanged += delegate { PatchRecipe(WeaponType.TriSword); }; configTriSwordRecipeUpgrade = ((BaseUnityPlugin)this).Config.Bind<string>(new ConfigDefinition(sectionTriSword, "Upgrade costs"), defaultUpgradeRecipeTriSword, new ConfigDescription("The costs to upgrade the item", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configTriSwordRecipeUpgrade.SettingChanged += delegate { PatchRecipe(WeaponType.TriSword); }; configTriSwordRecipeMultiplier = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionTriSword, "Upgrade multiplier"), 1, new ConfigDescription("The multiplier applied to the upgrade costs", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configTriSwordRecipeMultiplier.SettingChanged += delegate { PatchRecipe(WeaponType.TriSword); }; configTriSwordMaxQuality = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionTriSword, "Max quality"), 4, new ConfigDescription("The maximum quality the item can become", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configTriSwordMaxQuality.SettingChanged += delegate { PatchTriSwordStats(); }; configTriSwordMovementSpeed = ((BaseUnityPlugin)this).Config.Bind<float>(new ConfigDefinition(sectionTriSword, "Movement speed"), -0.05f, new ConfigDescription("The movement speed stat on the item", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configTriSwordMovementSpeed.SettingChanged += delegate { PatchTriSwordStats(); }; configTriSwordDamageMultiplier = ((BaseUnityPlugin)this).Config.Bind<float>(new ConfigDefinition(sectionTriSword, "Damage multiplier"), 1f, new ConfigDescription("Multiplier to adjust the damage on the item (65-75-55 slash, 40 lightning)", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configTriSwordDamageMultiplier.SettingChanged += delegate { PatchTriSwordStats(); }; configTriSwordBlockArmor = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionTriSword, "Block armor"), 48, new ConfigDescription("The block armor on the item", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configTriSwordBlockArmor.SettingChanged += delegate { PatchTriSwordStats(); }; configTriSwordBlockForce = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionTriSword, "Block force"), 20, new ConfigDescription("The block force on the item", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configTriSwordBlockForce.SettingChanged += delegate { PatchTriSwordStats(); }; configTriSwordKnockBack = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionTriSword, "Knockback"), 40, new ConfigDescription("The knockback on the item", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configTriSwordKnockBack.SettingChanged += delegate { PatchTriSwordStats(); }; configTriSwordFrostKnockBack = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionTriSword, "Frost Knockback"), 100, new ConfigDescription("The knockback on the item (Frost variant)", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configTriSwordFrostKnockBack.SettingChanged += delegate { PatchTriSwordStats(); }; configTriSwordBackStab = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionTriSword, "Backstab"), 3, new ConfigDescription("The block armor on the item", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configTriSwordBackStab.SettingChanged += delegate { PatchTriSwordStats(); }; configTriSwordUseStamina = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionTriSword, "Attack stamina"), 16, new ConfigDescription("Normal attack stamina usage", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configTriSwordUseStamina.SettingChanged += delegate { PatchTriSwordStats(); }; configTriSwordUseStaminaLightning = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionTriSword, "Secondary lightning ability stamina"), 32, new ConfigDescription("The secondary attack stamina usage (Lightning)", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configTriSwordUseStaminaLightning.SettingChanged += delegate { PatchTriSwordStats(); }; configTriSwordUseStaminaFire = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionTriSword, "Secondary Fire ability stamina"), 32, new ConfigDescription("The secondary attack stamina usage (Fire)", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configTriSwordUseStaminaFire.SettingChanged += delegate { PatchTriSwordStats(); }; configTriSwordUseStaminaFrost = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionTriSword, "Secondary Frost ability stamina"), 24, new ConfigDescription("The secondary attack stamina usage (Frost)", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configTriSwordUseStaminaFrost.SettingChanged += delegate { PatchTriSwordStats(); }; configCultivatorAtgeirEnable = ((BaseUnityPlugin)this).Config.Bind<bool>(new ConfigDefinition(sectionCultivatorAtgeir, "Enable"), true, new ConfigDescription("Enable the Cultivator Atgeir", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configCultivatorAtgeirEnable.SettingChanged += delegate { if (configCultivatorAtgeirEnable.Value) { PatchRecipe(WeaponType.CultivatorAtgeir, RecipeUpdateType.CraftingStation); } else { PatchRecipe(WeaponType.CultivatorAtgeir, RecipeUpdateType.CraftingStation, disableOverride: true); Logger.LogWarning((object)("The " + configCultivatorAtgeirName.Value + " is now disabled! The weapon can no longer be crafted or upgraded and will be deleted when players relog!")); } }; configCultivatorAtgeirName = ((BaseUnityPlugin)this).Config.Bind<string>(new ConfigDefinition(sectionCultivatorAtgeir, "Name"), "Lynrake", new ConfigDescription("The name given to the item", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configCultivatorAtgeirName.SettingChanged += delegate { PatchCultivatorAtgeirStats(); }; configCultivatorAtgeirDescription = ((BaseUnityPlugin)this).Config.Bind<string>(new ConfigDefinition(sectionCultivatorAtgeir, "Description"), "Apparently a cousin to Tordenvær, how peculiar! Seems to be very well made and sharp.", new ConfigDescription("The description given to the item", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configCultivatorAtgeirDescription.SettingChanged += delegate { PatchCultivatorAtgeirStats(); }; configCultivatorAtgeirCraftingStation = ((BaseUnityPlugin)this).Config.Bind<string>(new ConfigDefinition(sectionCultivatorAtgeir, "Crafting station"), "Forge", new ConfigDescription("The crafting station the item can be created in", (AcceptableValueBase)(object)new AcceptableValueList<string>(configCraftingStationOptions), new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configCultivatorAtgeirCraftingStation.SettingChanged += delegate { PatchRecipe(WeaponType.CultivatorAtgeir, RecipeUpdateType.CraftingStation); }; configCultivatorAtgeirMinStationLevel = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionCultivatorAtgeir, "Required station level"), 1, new ConfigDescription("The required station level to craft the item", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configCultivatorAtgeirMinStationLevel.SettingChanged += delegate { PatchRecipe(WeaponType.CultivatorAtgeir, RecipeUpdateType.MinRequiredLevel); }; configCultivatorAtgeirRecipe = ((BaseUnityPlugin)this).Config.Bind<string>(new ConfigDefinition(sectionCultivatorAtgeir, "Crafting costs"), defaultRecipeCultivatorAtgeir, new ConfigDescription("The items required to craft the item", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configCultivatorAtgeirRecipe.SettingChanged += delegate { PatchRecipe(WeaponType.CultivatorAtgeir); }; configCultivatorAtgeirRecipeUpgrade = ((BaseUnityPlugin)this).Config.Bind<string>(new ConfigDefinition(sectionCultivatorAtgeir, "Upgrade costs"), defaultUpgradeRecipeCultivatorAtgeir, new ConfigDescription("The costs to upgrade the item", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configCultivatorAtgeirRecipeUpgrade.SettingChanged += delegate { PatchRecipe(WeaponType.CultivatorAtgeir); }; configCultivatorAtgeirRecipeMultiplier = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionCultivatorAtgeir, "Upgrade multiplier"), 1, new ConfigDescription("The multiplier applied to the upgrade costs", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configCultivatorAtgeirRecipeMultiplier.SettingChanged += delegate { PatchRecipe(WeaponType.CultivatorAtgeir); }; configCultivatorAtgeirMaxQuality = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionCultivatorAtgeir, "Max quality"), 4, new ConfigDescription("The maximum quality the item can become", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configCultivatorAtgeirMaxQuality.SettingChanged += delegate { PatchCultivatorAtgeirStats(); }; configCultivatorAtgeirMovementSpeed = ((BaseUnityPlugin)this).Config.Bind<float>(new ConfigDefinition(sectionCultivatorAtgeir, "Movement speed"), 0f, new ConfigDescription("The movement speed stat on the item", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configCultivatorAtgeirMovementSpeed.SettingChanged += delegate { PatchCultivatorAtgeirStats(); }; configCultivatorAtgeirDamageMultiplier = ((BaseUnityPlugin)this).Config.Bind<float>(new ConfigDefinition(sectionCultivatorAtgeir, "Damage multiplier"), 1f, new ConfigDescription("Multiplier to adjust the damage on the item (85, 40 lightning)", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configCultivatorAtgeirDamageMultiplier.SettingChanged += delegate { PatchCultivatorAtgeirStats(); }; configCultivatorAtgeirBlockArmor = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionCultivatorAtgeir, "Block armor"), 64, new ConfigDescription("The block armor on the item", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configCultivatorAtgeirBlockArmor.SettingChanged += delegate { PatchCultivatorAtgeirStats(); }; configCultivatorAtgeirBlockForce = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionCultivatorAtgeir, "Block force"), 40, new ConfigDescription("The block force on the item", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configCultivatorAtgeirBlockForce.SettingChanged += delegate { PatchCultivatorAtgeirStats(); }; configCultivatorAtgeirKnockBack = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionCultivatorAtgeir, "Knockback"), 40, new ConfigDescription("The knockback on the item", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configCultivatorAtgeirKnockBack.SettingChanged += delegate { PatchCultivatorAtgeirStats(); }; configCultivatorAtgeirBackStab = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionCultivatorAtgeir, "Backstab"), 3, new ConfigDescription("The block armor on the item", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configCultivatorAtgeirBackStab.SettingChanged += delegate { PatchCultivatorAtgeirStats(); }; configCultivatorAtgeirUseStamina = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionCultivatorAtgeir, "Attack stamina"), 20, new ConfigDescription("Normal attack stamina usage", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configCultivatorAtgeirUseStamina.SettingChanged += delegate { PatchCultivatorAtgeirStats(); }; configCultivatorAtgeirUseStaminaAtgeir = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionCultivatorAtgeir, "Secondary atgeir ability stamina"), 40, new ConfigDescription("The secondary atgeir attack stamina usage", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configCultivatorAtgeirUseStaminaAtgeir.SettingChanged += delegate { PatchCultivatorAtgeirStats(); }; ((BaseUnityPlugin)this).Config.SaveOnConfigSet = true; configCultivatorAtgeirUseStaminaSpear = ((BaseUnityPlugin)this).Config.Bind<int>(new ConfigDefinition(sectionCultivatorAtgeir, "Secondary spear ability stamina"), 20, new ConfigDescription("The secondary spear attack stamina usage", (AcceptableValueBase)null, new object[1] { (object)new ConfigurationManagerAttributes { IsAdminOnly = true } })); configCultivatorAtgeirUseStaminaSpear.SettingChanged += delegate { PatchCultivatorAtgeirStats(); }; FileSystemWatcher fileSystemWatcher = new FileSystemWatcher(Paths.ConfigPath, configFileName); fileSystemWatcher.Changed += OnConfigFileChange; fileSystemWatcher.Created += OnConfigFileChange; fileSystemWatcher.Renamed += OnConfigFileChange; fileSystemWatcher.IncludeSubdirectories = true; fileSystemWatcher.SynchronizingObject = ThreadingHelper.SynchronizingObject; fileSystemWatcher.EnableRaisingEvents = true; } catch (Exception ex) { Logger.LogError((object)("Could not initialise config: " + ex)); } } private void OnConfigFileChange(object sender, FileSystemEventArgs e) { if (!File.Exists(configFileFullPath)) { return; } try { ((BaseUnityPlugin)this).Config.Reload(); } catch (Exception ex) { Logger.LogError((object)("Something went wrong while reloading the config, please check if the file exists and the entries are valid! " + ex)); } } private void InitStatusEffects() { //IL_002d: 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_005d: Unknown result type (might be due to invalid IL or missing references) //IL_0067: Expected O, but got Unknown //IL_00a3: 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_00d3: Unknown result type (might be due to invalid IL or missing references) //IL_00dd: Expected O, but got Unknown //IL_0119: 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_0149: Unknown result type (might be due to invalid IL or missing references) //IL_0153: Expected O, but got Unknown //IL_018f: 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_01bf: Unknown result type (might be due to invalid IL or missing references) //IL_01c9: Expected O, but got Unknown //IL_020a: Unknown result type (might be due to invalid IL or missing references) //IL_021e: 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_0249: Expected O, but got Unknown //IL_028a: 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_02bf: Unknown result type (might be due to invalid IL or missing references) //IL_02c9: Expected O, but got Unknown //IL_030a: Unknown result type (might be due to invalid IL or missing references) //IL_031e: Unknown result type (might be due to invalid IL or missing references) //IL_033f: Unknown result type (might be due to invalid IL or missing references) //IL_0349: Expected O, but got Unknown try { StatusEffect val = ScriptableObject.CreateInstance<StatusEffect>(); ((Object)val).name = "DemoHammerHammerEffect"; val.m_name = "Hammer Mode"; val.m_icon = demolisherSprite; val.m_startMessageType = (MessageType)2; val.m_startMessage = ""; val.m_stopMessageType = (MessageType)2; val.m_stopMessage = ""; val.m_tooltip = "Hammer Time!"; demoHammerHammerStatusEffect = new CustomStatusEffect(val, false); ItemManager.Instance.AddStatusEffect(demoHammerHammerStatusEffect); StatusEffect val2 = ScriptableObject.CreateInstance<StatusEffect>(); ((Object)val2).name = "DemoHammerAtgeirEffect"; val2.m_name = "Atgeir Mode"; val2.m_icon = himminAflSprite; val2.m_startMessageType = (MessageType)2; val2.m_startMessage = ""; val2.m_stopMessageType = (MessageType)2; val2.m_stopMessage = ""; val2.m_tooltip = "Swirl that Hammer around as if it was an Atgeir!"; demoHammerAtgeirStatusEffect = new CustomStatusEffect(val2, false); ItemManager.Instance.AddStatusEffect(demoHammerAtgeirStatusEffect); StatusEffect val3 = ScriptableObject.CreateInstance<StatusEffect>(); ((Object)val3).name = "TriSwordLightningEffect"; val3.m_name = "Lightning Mode"; val3.m_icon = lightningSprite; val3.m_startMessageType = (MessageType)2; val3.m_startMessage = ""; val3.m_stopMessageType = (MessageType)2; val3.m_stopMessage = ""; val3.m_tooltip = "The power of Thor flows through the blade!"; triSwordLightningStatusEffect = new CustomStatusEffect(val3, false); ItemManager.Instance.AddStatusEffect(triSwordLightningStatusEffect); StatusEffect val4 = ScriptableObject.CreateInstance<StatusEffect>(); ((Object)val4).name = "TriSwordFireEffect"; val4.m_name = "Fire Mode"; val4.m_icon = swordFireSprite; val4.m_startMessageType = (MessageType)2; val4.m_startMessage = ""; val4.m_stopMessageType = (MessageType)2; val4.m_stopMessage = ""; val4.m_tooltip = "Your blade is on fire!"; triSwordFireStatusEffect = new CustomStatusEffect(val4, false); ItemManager.Instance.AddStatusEffect(triSwordFireStatusEffect); StatusEffect val5 = ScriptableObject.CreateInstance<StatusEffect>(); ((Object)val5).name = "TriSwordFrostEffect"; val5.m_name = "Frost Mode"; val5.m_icon = frostSprite; val5.m_startMessageType = (MessageType)2; val5.m_startMessage = ""; val5.m_stopMessageType = (MessageType)2; val5.m_stopMessage = ""; val5.m_tooltip = "Your blade feels as cold as Jotunheim!"; triSwordFrostStatusEffect = new CustomStatusEffect(val5, false); ItemManager.Instance.AddStatusEffect(triSwordFrostStatusEffect); StatusEffect val6 = ScriptableObject.CreateInstance<StatusEffect>(); ((Object)val6).name = "CultivatorAtgeirAtgeirEffect"; val6.m_name = "Atgeir Mode"; val6.m_icon = himminAflSprite; val6.m_startMessageType = (MessageType)2; val6.m_startMessage = ""; val6.m_stopMessageType = (MessageType)2; val6.m_stopMessage = ""; val6.m_tooltip = "Its not a reaper... but just as effective!"; cultivatorAtgeirAtgeirStatusEffect = new CustomStatusEffect(val6, false); ItemManager.Instance.AddStatusEffect(cultivatorAtgeirAtgeirStatusEffect); StatusEffect val7 = ScriptableObject.CreateInstance<StatusEffect>(); ((Object)val7).name = "CultivatorAtgeirSpearEffect"; val7.m_name = "Spear Mode"; val7.m_icon = spearCarapaceSprite; val7.m_startMessageType = (MessageType)2; val7.m_startMessage = ""; val7.m_stopMessageType = (MessageType)2; val7.m_stopMessage = ""; val7.m_tooltip = "You feel like throwing this!"; cultivatorAtgeirSpearStatusEffect = new CustomStatusEffect(val7, false); ItemManager.Instance.AddStatusEffect(cultivatorAtgeirSpearStatusEffect); } catch (Exception ex) { Logger.LogError((object)("Could not initialise status effects: " + ex)); } } private void InitAssetBundle() { //IL_008c: Unknown result type (might be due to invalid IL or missing references) //IL_0096: Expected O, but got Unknown try { legendaryWeaponsBundle = AssetUtils.LoadAssetBundleFromResources("legendaryweapons_dw"); demoHammerHammerPrefab = legendaryWeaponsBundle.LoadAsset<GameObject>("Demo_Hammer_Hammer_DW"); demoHammerAtgeirPrefab = legendaryWeaponsBundle.LoadAsset<GameObject>("Demo_Hammer_Atgeir_DW"); cultivatorAtgeirAtgeirPrefab = legendaryWeaponsBundle.LoadAsset<GameObject>("Cultivator_Atgeir_Atgeir_DW"); cultivatorAtgeirSpearPrefab = legendaryWeaponsBundle.LoadAsset<GameObject>("Cultivator_Atgeir_Spear_DW"); cultivatorProjectilePrefab = legendaryWeaponsBundle.LoadAsset<GameObject>("projectile_cultivator_DW"); PrefabManager.Instance.AddPrefab(new CustomPrefab(cultivatorProjectilePrefab, true)); triSwordLightningPrefab = legendaryWeaponsBundle.LoadAsset<GameObject>("TriSword_Lightning_DW"); triSwordFirePrefab = legendaryWeaponsBundle.LoadAsset<GameObject>("TriSword_Fire_DW"); triSwordFrostPrefab = legendaryWeaponsBundle.LoadAsset<GameObject>("TriSword_Frost_DW"); demolisherSprite = legendaryWeaponsBundle.LoadAsset<Sprite>("SledgeDemolisher_DW"); himminAflSprite = legendaryWeaponsBundle.LoadAsset<Sprite>("AtgeirHimminAfl_DW"); lightningSprite = legendaryWeaponsBundle.LoadAsset<Sprite>("Lightning_DW"); swordFireSprite = legendaryWeaponsBundle.LoadAsset<Sprite>("SwordFire_DW"); frostSprite = legendaryWeaponsBundle.LoadAsset<Sprite>("Frost_DW"); spearCarapaceSprite = legendaryWeaponsBundle.LoadAsset<Sprite>("SpearCarapace_DW"); } catch (Exception ex) { Logger.LogError((object)("Could not initialise asset bundle: " + ex)); } } private void InitInputs() { //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_0014: Unknown result type (might be due to invalid IL or missing references) //IL_0026: Expected O, but got Unknown try { weaponModeButton = new ButtonConfig { Name = "Weapon mode", ShortcutConfig = configWeaponModeKey }; InputManager.Instance.AddButton("DeathWizsh.LegendaryWeapons", weaponModeButton); } catch (Exception ex) { Logger.LogError((object)("Could not initialise inputs: " + ex)); } } static LegendaryWeapons() { string configPath = Paths.ConfigPath; char directorySeparatorChar = Path.DirectorySeparatorChar; configFileFullPath = configPath + directorySeparatorChar + configFileName; } } internal enum RecipeUpdateType { Recipe, CraftingStation, MinRequiredLevel } internal enum WeaponType { Hammer, TriSword, CultivatorAtgeir }