using System; using System.Collections.Generic; using System.Diagnostics; using System.IO; using System.Reflection; using System.Resources; using System.Runtime.CompilerServices; using System.Runtime.Versioning; using System.Security; using System.Security.Permissions; using Bifrost.ConstEnum; using ItemsAPI.Builders; using ItemsAPI.Descriptors; using ItemsAPI.Enums; using MelonLoader; using Microsoft.CodeAnalysis; using SomeCustomScraps; using UnityEngine; [assembly: CompilationRelaxations(8)] [assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)] [assembly: Debuggable(DebuggableAttribute.DebuggingModes.Default | DebuggableAttribute.DebuggingModes.DisableOptimizations | DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints | DebuggableAttribute.DebuggingModes.EnableEditAndContinue)] [assembly: MelonInfo(typeof(global::SomeCustomScraps.SomeCustomScraps), "SomeCustomScraps", "1.0.0", "Shlygly", null)] [assembly: MelonGame("ReLUGames", "MIMESIS")] [assembly: TargetFramework(".NETStandard,Version=v2.1", FrameworkDisplayName = ".NET Standard 2.1")] [assembly: AssemblyCompany("Shlygly")] [assembly: AssemblyConfiguration("Debug")] [assembly: AssemblyFileVersion("1.0.0.0")] [assembly: AssemblyInformationalVersion("1.0.0")] [assembly: AssemblyProduct("SomeCustomScraps")] [assembly: AssemblyTitle("SomeCustomScraps")] [assembly: NeutralResourcesLanguage("en-US")] [assembly: SecurityPermission(SecurityAction.RequestMinimum, SkipVerification = true)] [assembly: AssemblyVersion("1.0.0.0")] [module: UnverifiableCode] [module: RefSafetyRules(11)] namespace Microsoft.CodeAnalysis { [CompilerGenerated] [Microsoft.CodeAnalysis.Embedded] internal sealed class EmbeddedAttribute : Attribute { } } namespace System.Runtime.CompilerServices { [CompilerGenerated] [Microsoft.CodeAnalysis.Embedded] [AttributeUsage(AttributeTargets.Module, AllowMultiple = false, Inherited = false)] internal sealed class RefSafetyRulesAttribute : Attribute { public readonly int Version; public RefSafetyRulesAttribute(int P_0) { Version = P_0; } } } namespace SomeCustomScraps { public class SomeCustomScraps : MelonMod { private AssetBundle bundle; public override void OnInitializeMelon() { //IL_0062: Unknown result type (might be due to invalid IL or missing references) //IL_0067: Unknown result type (might be due to invalid IL or missing references) //IL_0073: Unknown result type (might be due to invalid IL or missing references) //IL_007f: Unknown result type (might be due to invalid IL or missing references) //IL_0088: Unknown result type (might be due to invalid IL or missing references) //IL_0091: Unknown result type (might be due to invalid IL or missing references) //IL_009d: Unknown result type (might be due to invalid IL or missing references) //IL_00a5: Unknown result type (might be due to invalid IL or missing references) //IL_00b1: Unknown result type (might be due to invalid IL or missing references) //IL_00b9: Unknown result type (might be due to invalid IL or missing references) //IL_01c5: Unknown result type (might be due to invalid IL or missing references) //IL_01ca: Unknown result type (might be due to invalid IL or missing references) //IL_01d6: Unknown result type (might be due to invalid IL or missing references) //IL_01e2: Unknown result type (might be due to invalid IL or missing references) //IL_01eb: Unknown result type (might be due to invalid IL or missing references) //IL_01f4: Unknown result type (might be due to invalid IL or missing references) //IL_0200: Unknown result type (might be due to invalid IL or missing references) //IL_0208: Unknown result type (might be due to invalid IL or missing references) //IL_0214: Unknown result type (might be due to invalid IL or missing references) //IL_021c: Unknown result type (might be due to invalid IL or missing references) //IL_0224: Unknown result type (might be due to invalid IL or missing references) //IL_022c: Unknown result type (might be due to invalid IL or missing references) //IL_0234: Unknown result type (might be due to invalid IL or missing references) ((MelonBase)this).LoggerInstance.Msg("Loading asset bundle..."); if (!LoadAssetBundle()) { ((MelonBase)this).LoggerInstance.Error("Can't load asset bundle !"); return; } LootItemBuilder.RegisterAssetBundle(bundle); ((MelonBase)this).LoggerInstance.Msg("Adding new scraps..."); LootItemDescriptor val = new LootItemDescriptor("miscellnary_suze", "assets/shlygly/somecustomscraps/suze/prefab_miscellnary_suze.prefab", "A Suze Bottle") { IconSpriteAssetId = "assets/shlygly/somecustomscraps/suze/suze_icon.png", PosterIconSpriteId = "", MinPrice = 20, MaxPrice = 54, Weight = 1900, KeyGroup = (KeyGroup)2, AttachSocketName = "holdWeaponSocket", PuppetHandheldState = (PuppetHandheldState)3, DefaultSpawnRate = 461 }.AddLocalizedItemName("fr", "Une bouteille de Suze").AddLocalizedItemName("ko", "수즈 병").AddLocalizedItemName("es", "Una botella de Suze") .AddLocalizedItemName("ja", "スーズのボトル") .AddLocalizedItemName("de", "Eine Flasche Suze") .AddLocalizedItemName("zh_cn", "一瓶苏兹酒") .AddLocalizedItemName("zh_tw", "一瓶蘇茲酒") .AddLocalizedItemName("pt_br", "Uma garrafa de Suze") .AddLocalizedItemName("it", "Una bottiglia di Suze") .AddLocalizedItemName("ru", "Бутылка Suze") .AddLocalizedItemName("uk", "Пляшка Suze") .AddLocalizedItemName("vi", "Một chai Suze") .AddLocalizedItemName("th", "ขวด Suze") .AddLocalizedItemName("tr", "Bir şişe Suze") .AddLocalizedItemName("pl", "Butelka Suze") .AddLocalizedItemName("ar", "زجاجة سوز"); LootItemDescriptor val2 = new LootItemDescriptor("miscellnary_jarofpunch", "assets/shlygly/somecustomscraps/jarofpunch/prefab_miscellnary_jarofpunch.prefab", "A Jar Of Punch") { IconSpriteAssetId = "assets/shlygly/somecustomscraps/jarofpunch/jarofpunch_icon.png", PosterIconSpriteId = "", MinPrice = 35, MaxPrice = 72, Weight = 6625, KeyGroup = (KeyGroup)3, AttachSocketName = "holdWeaponSocket", PuppetHandheldState = (PuppetHandheldState)4, ForbidChange = true, IsHideWhenEmote = true, IsHidingCamera = true, DefaultSpawnRate = 384 }.AddLocalizedItemName((IDictionary)new Dictionary { { "fr", "Une jarre de punch" }, { "ko", "펀치가 담긴 항아리" }, { "es", "Una jarra de ponche" }, { "ja", "パンチの壺" }, { "de", "Ein Krug voller Punsch" }, { "zh_cn", "一罐潘趣酒" }, { "zh_tw", "一罐潘趣酒" }, { "pt_br", "Uma jarra de ponche" }, { "it", "Un vaso di punch" }, { "ru", "Кувшин пунша" }, { "uk", "Глечик пуншу" }, { "vi", "Một bình punch" }, { "th", "ไหพ\u0e31นช\u0e4c" }, { "tr", "Bir kavanoz punch" }, { "pl", "Dzban ponczu" }, { "ar", "جرة من البونش" } }); LootItemBuilder.RegisterItem(val); LootItemBuilder.RegisterItem(val2); ((MelonBase)this).LoggerInstance.Msg("Scraps added !"); } public bool LoadAssetBundle() { string text = Path.Combine(Path.GetDirectoryName(((object)this).GetType().Assembly.Location), "somecustomscraps"); ((MelonBase)this).LoggerInstance.Msg("Loading AssetBundle: " + text); if (!File.Exists(text)) { ((MelonBase)this).LoggerInstance.Error("AssetBundle not found: " + text); return false; } bundle = AssetBundle.LoadFromFile(text); if ((Object)(object)bundle == (Object)null) { ((MelonBase)this).LoggerInstance.Error("Failed to load AssetBundle."); return false; } ((MelonBase)this).LoggerInstance.Msg("AssetBundle loaded."); string[] allAssetNames = bundle.GetAllAssetNames(); foreach (string text2 in allAssetNames) { ((MelonBase)this).LoggerInstance.Msg("Asset in bundle: " + text2); } return true; } } }