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 goldbees v1.1.0
goldbees.dll
Decompiled 2 years agousing System; using System.Diagnostics; using System.Linq; using System.Reflection; using System.Runtime.CompilerServices; using System.Runtime.InteropServices; using System.Runtime.Versioning; using System.Security; using System.Security.Permissions; using BepInEx; using HarmonyLib; 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("goldbees")] [assembly: AssemblyDescription("")] [assembly: AssemblyConfiguration("")] [assembly: AssemblyCompany("")] [assembly: AssemblyProduct("goldbees")] [assembly: AssemblyCopyright("Copyright © 2021")] [assembly: AssemblyTrademark("")] [assembly: ComVisible(false)] [assembly: Guid("3B95EEF7-4A97-4393-91A0-3626434F3631")] [assembly: AssemblyFileVersion("1.0.0.0")] [assembly: TargetFramework(".NETFramework,Version=v4.7.2", FrameworkDisplayName = ".NET Framework 4.7.2")] [assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)] [assembly: AssemblyVersion("1.0.0.0")] [module: UnverifiableCode] namespace goldbees; [BepInPlugin("1010101110.goldbees", "goldbees", "1.0.6")] [BepInDependency(/*Could not decode attribute arguments.*/)] public class Mod : BaseUnityPlugin { public static readonly Harmony harmony = new Harmony(typeof(Mod).GetCustomAttributes(typeof(BepInPlugin), inherit: false).Cast<BepInPlugin>().First() .GUID); private void Awake() { harmony.PatchAll(); PrefabManager.OnVanillaPrefabsAvailable += AddPrefabs; } private void OnDestroy() { harmony.UnpatchSelf(); } private void AddPrefabs() { //IL_002c: Unknown result type (might be due to invalid IL or missing references) //IL_0033: Expected O, but got Unknown //IL_0069: Unknown result type (might be due to invalid IL or missing references) //IL_006e: Unknown result type (might be due to invalid IL or missing references) //IL_007a: Unknown result type (might be due to invalid IL or missing references) //IL_0083: Expected O, but got Unknown //IL_0085: Unknown result type (might be due to invalid IL or missing references) //IL_008a: Unknown result type (might be due to invalid IL or missing references) //IL_0096: Unknown result type (might be due to invalid IL or missing references) //IL_00a3: Expected O, but got Unknown //IL_00ab: Unknown result type (might be due to invalid IL or missing references) //IL_00b5: Expected O, but got Unknown //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_00d9: Expected O, but got Unknown //IL_00d4: Unknown result type (might be due to invalid IL or missing references) //IL_00de: Expected O, but got Unknown //IL_00f0: Unknown result type (might be due to invalid IL or missing references) //IL_00f5: Unknown result type (might be due to invalid IL or missing references) //IL_0102: Expected O, but got Unknown //IL_00fd: Unknown result type (might be due to invalid IL or missing references) //IL_0107: Expected O, but got Unknown //IL_0119: Unknown result type (might be due to invalid IL or missing references) //IL_011e: Unknown result type (might be due to invalid IL or missing references) //IL_012b: Expected O, but got Unknown //IL_0126: Unknown result type (might be due to invalid IL or missing references) //IL_0130: Expected O, but got Unknown //IL_0142: Unknown result type (might be due to invalid IL or missing references) //IL_0147: Unknown result type (might be due to invalid IL or missing references) //IL_0154: Expected O, but got Unknown //IL_014f: Unknown result type (might be due to invalid IL or missing references) //IL_0159: Expected O, but got Unknown //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_018e: Unknown result type (might be due to invalid IL or missing references) //IL_019a: Unknown result type (might be due to invalid IL or missing references) //IL_01a2: Unknown result type (might be due to invalid IL or missing references) //IL_01aa: Unknown result type (might be due to invalid IL or missing references) //IL_01b2: Unknown result type (might be due to invalid IL or missing references) //IL_01ba: Unknown result type (might be due to invalid IL or missing references) //IL_01c6: Unknown result type (might be due to invalid IL or missing references) //IL_01d2: Unknown result type (might be due to invalid IL or missing references) //IL_01de: Unknown result type (might be due to invalid IL or missing references) //IL_01ef: Expected O, but got Unknown //IL_01ea: Unknown result type (might be due to invalid IL or missing references) //IL_01f4: Expected O, but got Unknown //IL_0206: Unknown result type (might be due to invalid IL or missing references) //IL_020b: Unknown result type (might be due to invalid IL or missing references) //IL_0213: Unknown result type (might be due to invalid IL or missing references) //IL_021f: Unknown result type (might be due to invalid IL or missing references) //IL_0227: Unknown result type (might be due to invalid IL or missing references) //IL_022f: Unknown result type (might be due to invalid IL or missing references) //IL_0237: Unknown result type (might be due to invalid IL or missing references) //IL_0243: Unknown result type (might be due to invalid IL or missing references) //IL_024f: Unknown result type (might be due to invalid IL or missing references) //IL_025b: Unknown result type (might be due to invalid IL or missing references) //IL_0267: Unknown result type (might be due to invalid IL or missing references) //IL_0273: Unknown result type (might be due to invalid IL or missing references) //IL_027f: Unknown result type (might be due to invalid IL or missing references) //IL_0290: Expected O, but got Unknown //IL_028b: Unknown result type (might be due to invalid IL or missing references) //IL_0295: Expected O, but got Unknown //IL_02a7: Unknown result type (might be due to invalid IL or missing references) //IL_02ac: Unknown result type (might be due to invalid IL or missing references) //IL_02b5: Unknown result type (might be due to invalid IL or missing references) //IL_02c1: Unknown result type (might be due to invalid IL or missing references) //IL_02c9: Unknown result type (might be due to invalid IL or missing references) //IL_02d1: Unknown result type (might be due to invalid IL or missing references) //IL_02d9: Unknown result type (might be due to invalid IL or missing references) //IL_02e1: Unknown result type (might be due to invalid IL or missing references) //IL_02ed: Unknown result type (might be due to invalid IL or missing references) //IL_02f9: Unknown result type (might be due to invalid IL or missing references) //IL_0305: Unknown result type (might be due to invalid IL or missing references) //IL_0316: Expected O, but got Unknown //IL_0311: Unknown result type (might be due to invalid IL or missing references) //IL_031b: Expected O, but got Unknown //IL_032d: Unknown result type (might be due to invalid IL or missing references) //IL_0334: Expected O, but got Unknown //IL_0365: Unknown result type (might be due to invalid IL or missing references) //IL_036a: Unknown result type (might be due to invalid IL or missing references) //IL_0376: Unknown result type (might be due to invalid IL or missing references) //IL_0380: Expected O, but got Unknown //IL_0382: Unknown result type (might be due to invalid IL or missing references) //IL_0387: Unknown result type (might be due to invalid IL or missing references) //IL_0393: Unknown result type (might be due to invalid IL or missing references) //IL_039b: Unknown result type (might be due to invalid IL or missing references) //IL_03a4: Expected O, but got Unknown //IL_03ac: Unknown result type (might be due to invalid IL or missing references) //IL_03b6: Expected O, but got Unknown //IL_03fa: Unknown result type (might be due to invalid IL or missing references) //IL_0443: Unknown result type (might be due to invalid IL or missing references) //IL_0449: Expected O, but got Unknown //IL_0498: Unknown result type (might be due to invalid IL or missing references) //IL_04e1: Unknown result type (might be due to invalid IL or missing references) //IL_04e8: Expected O, but got Unknown //IL_053d: Unknown result type (might be due to invalid IL or missing references) //IL_058d: Unknown result type (might be due to invalid IL or missing references) //IL_0594: Expected O, but got Unknown //IL_05e9: Unknown result type (might be due to invalid IL or missing references) //IL_0639: Unknown result type (might be due to invalid IL or missing references) //IL_0640: Expected O, but got Unknown //IL_0657: Unknown result type (might be due to invalid IL or missing references) //IL_065e: Expected O, but got Unknown //IL_0694: Unknown result type (might be due to invalid IL or missing references) //IL_0699: Unknown result type (might be due to invalid IL or missing references) //IL_06a5: Unknown result type (might be due to invalid IL or missing references) //IL_06ae: Expected O, but got Unknown //IL_06b0: Unknown result type (might be due to invalid IL or missing references) //IL_06b5: Unknown result type (might be due to invalid IL or missing references) //IL_06c1: Unknown result type (might be due to invalid IL or missing references) //IL_06ca: Expected O, but got Unknown //IL_06cc: Unknown result type (might be due to invalid IL or missing references) //IL_06d1: Unknown result type (might be due to invalid IL or missing references) //IL_06dd: Unknown result type (might be due to invalid IL or missing references) //IL_06e6: Expected O, but got Unknown //IL_06ee: Unknown result type (might be due to invalid IL or missing references) //IL_06f5: Expected O, but got Unknown //IL_0743: Unknown result type (might be due to invalid IL or missing references) //IL_074a: Expected O, but got Unknown //IL_078e: Unknown result type (might be due to invalid IL or missing references) //IL_0793: Unknown result type (might be due to invalid IL or missing references) //IL_079f: Unknown result type (might be due to invalid IL or missing references) //IL_07a8: Expected O, but got Unknown //IL_07b0: Unknown result type (might be due to invalid IL or missing references) //IL_07b7: Expected O, but got Unknown //IL_07c9: Unknown result type (might be due to invalid IL or missing references) //IL_084f: Unknown result type (might be due to invalid IL or missing references) //IL_0854: Unknown result type (might be due to invalid IL or missing references) //IL_0860: Unknown result type (might be due to invalid IL or missing references) //IL_086c: Unknown result type (might be due to invalid IL or missing references) //IL_087a: Expected O, but got Unknown //IL_0875: Unknown result type (might be due to invalid IL or missing references) //IL_087f: Expected O, but got Unknown //IL_088a: Unknown result type (might be due to invalid IL or missing references) //IL_0891: Expected O, but got Unknown //IL_08c7: Unknown result type (might be due to invalid IL or missing references) //IL_08cc: Unknown result type (might be due to invalid IL or missing references) //IL_08d8: Unknown result type (might be due to invalid IL or missing references) //IL_08e1: Expected O, but got Unknown //IL_08e3: Unknown result type (might be due to invalid IL or missing references) //IL_08e8: Unknown result type (might be due to invalid IL or missing references) //IL_08f4: Unknown result type (might be due to invalid IL or missing references) //IL_08fd: Expected O, but got Unknown //IL_08ff: Unknown result type (might be due to invalid IL or missing references) //IL_0904: 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_0919: Expected O, but got Unknown //IL_0921: Unknown result type (might be due to invalid IL or missing references) //IL_0928: Expected O, but got Unknown //IL_0977: Unknown result type (might be due to invalid IL or missing references) //IL_097e: Expected O, but got Unknown //IL_09c2: 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_09d3: Unknown result type (might be due to invalid IL or missing references) //IL_09dc: Expected O, but got Unknown //IL_09e4: Unknown result type (might be due to invalid IL or missing references) //IL_09eb: Expected O, but got Unknown //IL_09fd: Unknown result type (might be due to invalid IL or missing references) //IL_0a84: Unknown result type (might be due to invalid IL or missing references) //IL_0a89: Unknown result type (might be due to invalid IL or missing references) //IL_0a95: Unknown result type (might be due to invalid IL or missing references) //IL_0aa1: Unknown result type (might be due to invalid IL or missing references) //IL_0aaf: Expected O, but got Unknown //IL_0aaa: Unknown result type (might be due to invalid IL or missing references) //IL_0ab4: Expected O, but got Unknown //IL_0abf: Unknown result type (might be due to invalid IL or missing references) //IL_0ac6: Expected O, but got Unknown //IL_0afc: Unknown result type (might be due to invalid IL or missing references) //IL_0b01: Unknown result type (might be due to invalid IL or missing references) //IL_0b0d: Unknown result type (might be due to invalid IL or missing references) //IL_0b16: Expected O, but got Unknown //IL_0b18: Unknown result type (might be due to invalid IL or missing references) //IL_0b1d: Unknown result type (might be due to invalid IL or missing references) //IL_0b29: Unknown result type (might be due to invalid IL or missing references) //IL_0b32: Expected O, but got Unknown //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_0b45: Unknown result type (might be due to invalid IL or missing references) //IL_0b4e: Expected O, but got Unknown //IL_0b50: Unknown result type (might be due to invalid IL or missing references) //IL_0b55: Unknown result type (might be due to invalid IL or missing references) //IL_0b61: Unknown result type (might be due to invalid IL or missing references) //IL_0b6a: Expected O, but got Unknown //IL_0b72: Unknown result type (might be due to invalid IL or missing references) //IL_0b79: Expected O, but got Unknown //IL_0bc8: Unknown result type (might be due to invalid IL or missing references) //IL_0bcf: Expected O, but got Unknown //IL_0c13: Unknown result type (might be due to invalid IL or missing references) //IL_0c18: Unknown result type (might be due to invalid IL or missing references) //IL_0c24: Unknown result type (might be due to invalid IL or missing references) //IL_0c2d: Expected O, but got Unknown //IL_0c35: Unknown result type (might be due to invalid IL or missing references) //IL_0c3c: Expected O, but got Unknown //IL_0c4e: Unknown result type (might be due to invalid IL or missing references) //IL_0cd5: Unknown result type (might be due to invalid IL or missing references) //IL_0cda: Unknown result type (might be due to invalid IL or missing references) //IL_0ce6: Unknown result type (might be due to invalid IL or missing references) //IL_0cf2: Unknown result type (might be due to invalid IL or missing references) //IL_0d00: Expected O, but got Unknown //IL_0cfb: Unknown result type (might be due to invalid IL or missing references) //IL_0d05: Expected O, but got Unknown //IL_0d10: Unknown result type (might be due to invalid IL or missing references) //IL_0d17: Expected O, but got Unknown //IL_0d4d: Unknown result type (might be due to invalid IL or missing references) //IL_0d52: Unknown result type (might be due to invalid IL or missing references) //IL_0d5e: Unknown result type (might be due to invalid IL or missing references) //IL_0d67: Expected O, but got Unknown //IL_0d69: Unknown result type (might be due to invalid IL or missing references) //IL_0d6e: Unknown result type (might be due to invalid IL or missing references) //IL_0d7a: Unknown result type (might be due to invalid IL or missing references) //IL_0d83: Expected O, but got Unknown //IL_0d85: Unknown result type (might be due to invalid IL or missing references) //IL_0d8a: Unknown result type (might be due to invalid IL or missing references) //IL_0d96: Unknown result type (might be due to invalid IL or missing references) //IL_0d9f: Expected O, but got Unknown //IL_0da1: Unknown result type (might be due to invalid IL or missing references) //IL_0da6: Unknown result type (might be due to invalid IL or missing references) //IL_0db2: Unknown result type (might be due to invalid IL or missing references) //IL_0dbb: Expected O, but got Unknown //IL_0dc3: Unknown result type (might be due to invalid IL or missing references) //IL_0dca: Expected O, but got Unknown //IL_0e19: Unknown result type (might be due to invalid IL or missing references) //IL_0e20: Expected O, but got Unknown //IL_0e64: Unknown result type (might be due to invalid IL or missing references) //IL_0e69: Unknown result type (might be due to invalid IL or missing references) //IL_0e75: Unknown result type (might be due to invalid IL or missing references) //IL_0e7e: Expected O, but got Unknown //IL_0e86: Unknown result type (might be due to invalid IL or missing references) //IL_0e8d: Expected O, but got Unknown //IL_0e9f: Unknown result type (might be due to invalid IL or missing references) //IL_0f26: Unknown result type (might be due to invalid IL or missing references) //IL_0f2b: Unknown result type (might be due to invalid IL or missing references) //IL_0f37: Unknown result type (might be due to invalid IL or missing references) //IL_0f43: Unknown result type (might be due to invalid IL or missing references) //IL_0f51: Expected O, but got Unknown //IL_0f4c: Unknown result type (might be due to invalid IL or missing references) //IL_0f56: Expected O, but got Unknown AssetBundle val = AssetUtils.LoadAssetBundleFromResources("goldbees", typeof(Mod).Assembly); ItemManager instance = ItemManager.Instance; GameObject obj = val.LoadAsset<GameObject>("QueenBeeGold"); ItemConfig val2 = new ItemConfig(); val2.Description = "this sweetie sure is shiny"; val2.CraftingStation = "forge"; val2.MinStationLevel = 1; val2.Amount = 1; val2.Requirements = (RequirementConfig[])(object)new RequirementConfig[2] { new RequirementConfig { Item = "QueenBee", Amount = 2 }, new RequirementConfig { Item = "Coins", Amount = 999 } }; instance.AddItem(new CustomItem(obj, false, val2)); ItemManager.Instance.AddItem(new CustomItem(val.LoadAsset<GameObject>("HoneyGold"), false, new ItemConfig { Enabled = false })); ItemManager.Instance.AddItem(new CustomItem(val.LoadAsset<GameObject>("Mums"), false, new ItemConfig { Enabled = false })); ItemManager.Instance.AddItem(new CustomItem(val.LoadAsset<GameObject>("Edelweiss"), false, new ItemConfig { Enabled = false })); ItemManager.Instance.AddItem(new CustomItem(val.LoadAsset<GameObject>("Scabiosa"), false, new ItemConfig { Enabled = false })); PrefabManager.Instance.AddPrefab(val.LoadAsset<GameObject>("BeehiveGold")); ZoneManager.Instance.AddCustomVegetation(new CustomVegetation(val.LoadAsset<GameObject>("Pickable_mums"), false, new VegetationConfig { Biome = (Biome)1, Max = 0.75f, BlockCheck = true, InForest = false, GroupSizeMin = 2, GroupSizeMax = 5, GroupRadius = 4f, MinAltitude = 1f, ScaleMin = 1.3f, ScaleMax = 1.8f })); ZoneManager.Instance.AddCustomVegetation(new CustomVegetation(val.LoadAsset<GameObject>("Pickable_edelweiss"), false, new VegetationConfig { Biome = (Biome)4, Max = 1f, BlockCheck = true, GroupSizeMin = 2, GroupSizeMax = 8, GroupRadius = 4f, MinAltitude = 1f, TerrainDeltaRadius = 2f, MinTerrainDelta = 0f, MaxTerrainDelta = 3f, ScaleMin = 0.6f, ScaleMax = 0.8f })); ZoneManager.Instance.AddCustomVegetation(new CustomVegetation(val.LoadAsset<GameObject>("Pickable_scabiosa"), false, new VegetationConfig { Biome = (Biome)16, Max = 0.5f, BlockCheck = true, InForest = false, GroupSizeMin = 5, GroupSizeMax = 8, GroupRadius = 4f, MinAltitude = 1f, ScaleMin = 0.4f, ScaleMax = 0.6f })); PieceManager instance2 = PieceManager.Instance; GameObject obj2 = val.LoadAsset<GameObject>("piece_beehive_gold"); PieceConfig val3 = new PieceConfig(); val3.PieceTable = "Hammer"; val3.Category = "Crafting"; val3.CraftingStation = "piece_workbench"; val3.Requirements = (RequirementConfig[])(object)new RequirementConfig[2] { new RequirementConfig { Item = "FineWood", Amount = 10 }, new RequirementConfig { Item = "QueenBeeGold", Amount = 1, Recover = true } }; instance2.AddPiece(new CustomPiece(obj2, true, val3)); SE_Stats val4 = ScriptableObject.CreateInstance<SE_Stats>(); ((Object)val4).name = "Soothin"; ((StatusEffect)val4).m_name = "Soothin"; ((StatusEffect)val4).m_icon = PrefabManager.Instance.GetPrefab("Honey").GetComponent<ItemDrop>().m_itemData.GetIcon(); ((StatusEffect)val4).m_startMessageType = (MessageType)1; ((StatusEffect)val4).m_startMessage = "you feel soothed and comforted."; val4.m_speedModifier = -0.8f; val4.m_healthOverTime = 20f; val4.m_staminaOverTime = 20f; val4.m_healthOverTimeInterval = 2f; ((StatusEffect)val4).m_ttl = 10f; CustomStatusEffect val5 = new CustomStatusEffect((StatusEffect)(object)val4, false); ItemManager.Instance.AddStatusEffect(val5); SE_Stats val6 = ScriptableObject.CreateInstance<SE_Stats>(); ((Object)val6).name = "Golden"; ((StatusEffect)val6).m_name = "Golden"; ((StatusEffect)val6).m_icon = PrefabManager.Instance.GetPrefab("HoneyGold").GetComponent<ItemDrop>().m_itemData.GetIcon(); ((StatusEffect)val6).m_startMessageType = (MessageType)1; ((StatusEffect)val6).m_startMessage = "you feel shiny and comforted."; val6.m_speedModifier = -0.8f; val6.m_healthOverTime = 30f; val6.m_staminaOverTime = 30f; val6.m_healthOverTimeInterval = 2f; ((StatusEffect)val6).m_ttl = 10f; CustomStatusEffect val7 = new CustomStatusEffect((StatusEffect)(object)val6, false); ItemManager.Instance.AddStatusEffect(val7); SE_Stats val8 = ScriptableObject.CreateInstance<SE_Stats>(); ((Object)val8).name = "Chillin"; ((StatusEffect)val8).m_name = "Chillin"; ((StatusEffect)val8).m_icon = PrefabManager.Instance.GetPrefab("Edelweiss").GetComponent<ItemDrop>().m_itemData.GetIcon(); ((StatusEffect)val8).m_startMessageType = (MessageType)1; ((StatusEffect)val8).m_startMessage = "so refreshing! sweet and cool and comforting!"; val8.m_speedModifier = -0.8f; val8.m_healthOverTime = 69f; val8.m_healthOverTimeInterval = 1f; val8.m_staminaOverTime = 69f; ((StatusEffect)val8).m_ttl = 10f; CustomStatusEffect val9 = new CustomStatusEffect((StatusEffect)(object)val8, false); ItemManager.Instance.AddStatusEffect(val9); SE_Stats val10 = ScriptableObject.CreateInstance<SE_Stats>(); ((Object)val10).name = "Easy"; ((StatusEffect)val10).m_name = "Easy"; ((StatusEffect)val10).m_icon = PrefabManager.Instance.GetPrefab("Scabiosa").GetComponent<ItemDrop>().m_itemData.GetIcon(); ((StatusEffect)val10).m_startMessageType = (MessageType)1; ((StatusEffect)val10).m_startMessage = "just taking it easy comfortably"; val10.m_speedModifier = -0.8f; val10.m_healthOverTime = 69f; val10.m_healthOverTimeInterval = 1f; val10.m_staminaOverTime = 420f; ((StatusEffect)val10).m_ttl = 10f; CustomStatusEffect val11 = new CustomStatusEffect((StatusEffect)(object)val10, false); ItemManager.Instance.AddStatusEffect(val11); val2 = new ItemConfig(); val2.Description = "This mush smells pleasant, throw it in a fermenter?"; val2.Amount = 1; val2.CraftingStation = "piece_cauldron"; val2.MinStationLevel = 1; val2.Requirements = (RequirementConfig[])(object)new RequirementConfig[3] { new RequirementConfig { Item = "Dandelion", Amount = 5 }, new RequirementConfig { Item = "Raspberry", Amount = 5 }, new RequirementConfig { Item = "Honey", Amount = 4 } }; CustomItem val12 = new CustomItem("MushSoothing", "MeadBaseTasty", val2); val12.ItemDrop.m_itemData.m_shared.m_name = "Soothing Mush"; val12.ItemDrop.m_itemData.m_shared.m_consumeStatusEffect = val5.StatusEffect; ItemManager.Instance.AddItem(val12); val2 = new ItemConfig(); val2.Name = "Honey Tea"; val2.Description = "a soothing tea"; val2.CraftingStation = "piece_cauldron"; val2.MinStationLevel = 1; val2.Amount = 20; val2.Requirements = (RequirementConfig[])(object)new RequirementConfig[1] { new RequirementConfig { Item = "SledgeCheat", Amount = 1 } }; CustomItem val13 = new CustomItem("HoneyTea", "Tankard", val2); val13.ItemDrop.m_itemData.m_shared.m_itemType = (ItemType)2; val13.ItemDrop.m_itemData.m_shared.m_ammoType = "mead"; val13.ItemDrop.m_itemData.m_shared.m_attack.m_attackAnimation = "emote_drink"; val13.ItemDrop.m_itemData.m_shared.m_consumeStatusEffect = val5.StatusEffect; val13.ItemDrop.m_itemData.m_shared.m_maxStackSize = 30; ItemManager.Instance.AddItem(val13); ItemManager.Instance.AddItemConversion(new CustomItemConversion((ConversionConfig)new FermenterConversionConfig { FromItem = "MushSoothing", ToItem = "HoneyTea", ProducedItems = 10 })); val2 = new ItemConfig(); val2.Description = "This shiny mush, throw it in a fermenter?"; val2.Amount = 1; val2.CraftingStation = "piece_cauldron"; val2.MinStationLevel = 1; val2.Requirements = (RequirementConfig[])(object)new RequirementConfig[3] { new RequirementConfig { Item = "Mums", Amount = 5 }, new RequirementConfig { Item = "Blueberries", Amount = 5 }, new RequirementConfig { Item = "HoneyGold", Amount = 4 } }; CustomItem val14 = new CustomItem("MushGolden", "MeadBaseTasty", val2); val14.ItemDrop.m_itemData.m_shared.m_name = "Golden Mush"; val14.ItemDrop.m_itemData.m_shared.m_consumeStatusEffect = val7.StatusEffect; ItemManager.Instance.AddItem(val14); val2 = new ItemConfig(); val2.Name = "Golden Tea"; val2.Description = "a radiant tea"; val2.CraftingStation = "piece_cauldron"; val2.MinStationLevel = 2; val2.Amount = 20; val2.Requirements = (RequirementConfig[])(object)new RequirementConfig[1] { new RequirementConfig { Item = "SledgeCheat", Amount = 1 } }; CustomItem val15 = new CustomItem("GoldenTea", "Tankard", val2); val15.ItemDrop.m_itemData.m_shared.m_itemType = (ItemType)2; val15.ItemDrop.m_itemData.m_shared.m_ammoType = "mead"; val15.ItemDrop.m_itemData.m_shared.m_attack.m_attackAnimation = "emote_drink"; val15.ItemDrop.m_itemData.m_shared.m_consumeStatusEffect = val7.StatusEffect; val15.ItemDrop.m_itemData.m_shared.m_maxStackSize = 30; ItemManager.Instance.AddItem(val15); ItemManager.Instance.AddItemConversion(new CustomItemConversion((ConversionConfig)new FermenterConversionConfig { FromItem = "MushGolden", ToItem = "GoldenTea", ProducedItems = 10 })); val2 = new ItemConfig(); val2.Description = "This mush is cold, throw it in a fermenter?"; val2.Amount = 1; val2.CraftingStation = "piece_cauldron"; val2.MinStationLevel = 2; val2.Requirements = (RequirementConfig[])(object)new RequirementConfig[4] { new RequirementConfig { Item = "Edelweiss", Amount = 5 }, new RequirementConfig { Item = "Dandelion", Amount = 5 }, new RequirementConfig { Item = "Crystal", Amount = 1 }, new RequirementConfig { Item = "HoneyGold", Amount = 4 } }; CustomItem val16 = new CustomItem("MushIced", "MeadBaseTasty", val2); val16.ItemDrop.m_itemData.m_shared.m_name = "Iced Mush"; val16.ItemDrop.m_itemData.m_shared.m_consumeStatusEffect = val9.StatusEffect; ItemManager.Instance.AddItem(val16); val2 = new ItemConfig(); val2.Name = "Iced Tea"; val2.Description = "a chilly tea"; val2.CraftingStation = "piece_cauldron"; val2.MinStationLevel = 1; val2.Amount = 20; val2.Requirements = (RequirementConfig[])(object)new RequirementConfig[1] { new RequirementConfig { Item = "SledgeCheat", Amount = 1 } }; CustomItem val17 = new CustomItem("IcedTea", "Tankard", val2); val17.ItemDrop.m_itemData.m_shared.m_itemType = (ItemType)2; val17.ItemDrop.m_itemData.m_shared.m_ammoType = "mead"; val17.ItemDrop.m_itemData.m_shared.m_attack.m_attackAnimation = "emote_drink"; val17.ItemDrop.m_itemData.m_shared.m_consumeStatusEffect = val9.StatusEffect; val17.ItemDrop.m_itemData.m_shared.m_maxStackSize = 30; ItemManager.Instance.AddItem(val17); ItemManager.Instance.AddItemConversion(new CustomItemConversion((ConversionConfig)new FermenterConversionConfig { FromItem = "MushIced", ToItem = "IcedTea", ProducedItems = 10 })); val2 = new ItemConfig(); val2.Description = "This mush is flowery, throw it in a fermenter?"; val2.Amount = 1; val2.CraftingStation = "piece_cauldron"; val2.MinStationLevel = 2; val2.Requirements = (RequirementConfig[])(object)new RequirementConfig[4] { new RequirementConfig { Item = "Mums", Amount = 5 }, new RequirementConfig { Item = "Scabiosa", Amount = 5 }, new RequirementConfig { Item = "Cloudberry", Amount = 5 }, new RequirementConfig { Item = "HoneyGold", Amount = 4 } }; CustomItem val18 = new CustomItem("MushEasy", "MeadBaseTasty", val2); val18.ItemDrop.m_itemData.m_shared.m_name = "Easy Mush"; val18.ItemDrop.m_itemData.m_shared.m_consumeStatusEffect = val11.StatusEffect; ItemManager.Instance.AddItem(val18); val2 = new ItemConfig(); val2.Name = "Easy Tea"; val2.Description = "it's not easy to make but it do make you feel at ease!"; val2.CraftingStation = "piece_cauldron"; val2.MinStationLevel = 1; val2.Amount = 20; val2.Requirements = (RequirementConfig[])(object)new RequirementConfig[1] { new RequirementConfig { Item = "SledgeCheat", Amount = 1 } }; CustomItem val19 = new CustomItem("EasyTea", "Tankard", val2); val19.ItemDrop.m_itemData.m_shared.m_itemType = (ItemType)2; val19.ItemDrop.m_itemData.m_shared.m_ammoType = "mead"; val19.ItemDrop.m_itemData.m_shared.m_attack.m_attackAnimation = "emote_drink"; val19.ItemDrop.m_itemData.m_shared.m_consumeStatusEffect = val11.StatusEffect; val19.ItemDrop.m_itemData.m_shared.m_maxStackSize = 30; ItemManager.Instance.AddItem(val19); ItemManager.Instance.AddItemConversion(new CustomItemConversion((ConversionConfig)new FermenterConversionConfig { FromItem = "MushEasy", ToItem = "EasyTea", ProducedItems = 10 })); } } public class MyPatches { [HarmonyPatch(typeof(SE_Rested), "CalculateComfortLevel", new Type[] { typeof(Player) })] private class restedadditions { private static void Postfix(Player player, ref int __result) { if (((Character)player).m_seman.HaveStatusEffect(StringExtensionMethods.GetStableHashCode("Soothin"))) { __result += 5; } if (((Character)player).m_seman.HaveStatusEffect(StringExtensionMethods.GetStableHashCode("Golden"))) { __result += 5; } if (((Character)player).m_seman.HaveStatusEffect(StringExtensionMethods.GetStableHashCode("Chillin"))) { __result += 5; } if (((Character)player).m_seman.HaveStatusEffect(StringExtensionMethods.GetStableHashCode("Easy"))) { __result += 10; } } } }