Please disclose if any significant portion of your mod was created 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 AdventureBackpacks HD v1.0.0
plugins/AdventureBackpacksHD.dll
Decompiled a day agousing System; using System.Collections.Generic; using System.Diagnostics; using System.IO; using System.Reflection; using System.Runtime.CompilerServices; using System.Runtime.Versioning; using AdventureBackpacks.API.Client; using BepInEx; using Microsoft.CodeAnalysis; using UnityEngine; [assembly: CompilationRelaxations(8)] [assembly: RuntimeCompatibility(WrapNonExceptionThrows = true)] [assembly: Debuggable(DebuggableAttribute.DebuggingModes.IgnoreSymbolStoreSequencePoints)] [assembly: TargetFramework(".NETFramework,Version=v4.8", FrameworkDisplayName = ".NET Framework 4.8")] [assembly: AssemblyCompany("AdventureBackpacksHD")] [assembly: AssemblyConfiguration("Release")] [assembly: AssemblyFileVersion("1.0.0.0")] [assembly: AssemblyInformationalVersion("1.0.0+425bc0d05d51340873988092aac4b8284d57a4e4")] [assembly: AssemblyProduct("AdventureBackpacksHD")] [assembly: AssemblyTitle("AdventureBackpacksHD")] [assembly: AssemblyVersion("1.0.0.0")] [module: RefSafetyRules(11)] namespace Microsoft.CodeAnalysis { [CompilerGenerated] [Embedded] internal sealed class EmbeddedAttribute : Attribute { } } namespace System.Runtime.CompilerServices { [CompilerGenerated] [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 AdventureBackpacks.API.Client { public static class ABAPIClient { public enum ModelStyle { Modern, Classic } public enum BackpackName { Meadows, BlackForest, Swamp, Mountains, Plains, Mistlands, Ashlands, DeepNorth } private static bool _initialized; private static bool _isAvailable; private static Type _apiType; private static MethodInfo _isLoadedMethod; private static MethodInfo _isBackpackMethod; private static MethodInfo _isBackpackEquippedMethod; private static MethodInfo _canOpenBackpackMethod; private static MethodInfo _isBackpackOpenMethod; private static MethodInfo _isThisBackpackEquippedMethod; private static MethodInfo _getEquippedBackpackInventoryMethod; private static MethodInfo _tryGetEquippedBackpackInventoryMethod; private static MethodInfo _getBackpackInventoryMethod; private static MethodInfo _tryGetBackpackInventoryMethod; private static MethodInfo _getAllBackpackInventoriesMethod; private static MethodInfo _tryGetAllBackpackInventoriesMethod; private static MethodInfo _openBackpackMethod; private static MethodInfo _openBackpackWithGroupMethod; private static MethodInfo _isOpenWithCraftingStationEnabledMethod; private static MethodInfo _isOpenWithInventoryEnabledMethod; private static MethodInfo _isEnableContainerTabsEnabledMethod; private static MethodInfo _hasActiveExternalContainerMethod; private static MethodInfo _isCraftFromBackpackEnabledMethod; private static MethodInfo _isCraftingContextActiveMethod; private static MethodInfo _getConsumptionPriorityMethod; private static MethodInfo _isLeaveOneItemInBackpackEnabledMethod; private static MethodInfo _isDisplayTotalIngredientCountEnabledMethod; private static MethodInfo _suppressNativeCraftingMethod; private static MethodInfo _unsuppressNativeCraftingMethod; private static MethodInfo _wouldStorePickupMethod; private static MethodInfo _wouldStorePickupWithInventoryMethod; private static MethodInfo _registerVisualBundleMethod; private static MethodInfo _registerVisualBundleWithDefaultMethod; private static Type _modelStyleType; private static MethodInfo _registerVisualBundleStyleMethod; private static MethodInfo _registerVisualBundleStyleWithDefaultMethod; public static bool IsAvailable { get { EnsureInitialized(); return _isAvailable; } } private static void EnsureInitialized() { if (_initialized) { return; } _initialized = true; Assembly[] assemblies = AppDomain.CurrentDomain.GetAssemblies(); for (int i = 0; i < assemblies.Length; i++) { if (!(assemblies[i].GetName().Name == "AdventureBackpacks")) { continue; } _apiType = assemblies[i].GetType("AdventureBackpacks.API.ABAPI"); if (_apiType != null) { _isAvailable = true; _isLoadedMethod = _apiType.GetMethod("IsLoaded", BindingFlags.Static | BindingFlags.Public); _isBackpackMethod = _apiType.GetMethod("IsBackpack", BindingFlags.Static | BindingFlags.Public, null, new Type[1] { typeof(ItemData) }, null); _isBackpackEquippedMethod = _apiType.GetMethod("IsBackpackEquipped", BindingFlags.Static | BindingFlags.Public, null, new Type[1] { typeof(Player) }, null); _canOpenBackpackMethod = _apiType.GetMethod("CanOpenBackpack", BindingFlags.Static | BindingFlags.Public, null, new Type[1] { typeof(Player) }, null); _isBackpackOpenMethod = _apiType.GetMethod("IsBackpackOpen", BindingFlags.Static | BindingFlags.Public); _isThisBackpackEquippedMethod = _apiType.GetMethod("IsThisBackpackEquipped", BindingFlags.Static | BindingFlags.Public, null, new Type[2] { typeof(Player), typeof(ItemData) }, null); _getEquippedBackpackInventoryMethod = _apiType.GetMethod("GetEquippedBackpackInventory", BindingFlags.Static | BindingFlags.Public, null, new Type[1] { typeof(Player) }, null); _tryGetEquippedBackpackInventoryMethod = _apiType.GetMethod("TryGetEquippedBackpackInventory", BindingFlags.Static | BindingFlags.Public, null, new Type[2] { typeof(Player), typeof(Inventory).MakeByRefType() }, null); _getBackpackInventoryMethod = _apiType.GetMethod("GetBackpackInventory", BindingFlags.Static | BindingFlags.Public, null, new Type[1] { typeof(ItemData) }, null); _tryGetBackpackInventoryMethod = _apiType.GetMethod("TryGetBackpackInventory", BindingFlags.Static | BindingFlags.Public, null, new Type[2] { typeof(ItemData), typeof(Inventory).MakeByRefType() }, null); _getAllBackpackInventoriesMethod = _apiType.GetMethod("GetAllBackpackInventories", BindingFlags.Static | BindingFlags.Public, null, new Type[1] { typeof(Player) }, null); _tryGetAllBackpackInventoriesMethod = _apiType.GetMethod("TryGetAllBackpackInventories", BindingFlags.Static | BindingFlags.Public, null, new Type[2] { typeof(Player), typeof(List<Inventory>).MakeByRefType() }, null); _openBackpackMethod = _apiType.GetMethod("OpenBackpack", BindingFlags.Static | BindingFlags.Public, null, new Type[2] { typeof(Player), typeof(InventoryGui) }, null); _openBackpackWithGroupMethod = _apiType.GetMethod("OpenBackpack", BindingFlags.Static | BindingFlags.Public, null, new Type[3] { typeof(Player), typeof(InventoryGui), typeof(int) }, null); _isOpenWithCraftingStationEnabledMethod = _apiType.GetMethod("IsOpenWithCraftingStationEnabled", BindingFlags.Static | BindingFlags.Public); _isOpenWithInventoryEnabledMethod = _apiType.GetMethod("IsOpenWithInventoryEnabled", BindingFlags.Static | BindingFlags.Public); _isEnableContainerTabsEnabledMethod = _apiType.GetMethod("IsEnableContainerTabsEnabled", BindingFlags.Static | BindingFlags.Public); _hasActiveExternalContainerMethod = _apiType.GetMethod("HasActiveExternalContainer", BindingFlags.Static | BindingFlags.Public); _isCraftFromBackpackEnabledMethod = _apiType.GetMethod("IsCraftFromBackpackEnabled", BindingFlags.Static | BindingFlags.Public); _isCraftingContextActiveMethod = _apiType.GetMethod("IsCraftingContextActive", BindingFlags.Static | BindingFlags.Public); _getConsumptionPriorityMethod = _apiType.GetMethod("GetConsumptionPriority", BindingFlags.Static | BindingFlags.Public); _isLeaveOneItemInBackpackEnabledMethod = _apiType.GetMethod("IsLeaveOneItemInBackpackEnabled", BindingFlags.Static | BindingFlags.Public); _isDisplayTotalIngredientCountEnabledMethod = _apiType.GetMethod("IsDisplayTotalIngredientCountEnabled", BindingFlags.Static | BindingFlags.Public); _suppressNativeCraftingMethod = _apiType.GetMethod("SuppressNativeCrafting", BindingFlags.Static | BindingFlags.Public, null, new Type[1] { typeof(string) }, null); _unsuppressNativeCraftingMethod = _apiType.GetMethod("UnsuppressNativeCrafting", BindingFlags.Static | BindingFlags.Public, null, new Type[1] { typeof(string) }, null); _wouldStorePickupMethod = _apiType.GetMethod("WouldStorePickup", BindingFlags.Static | BindingFlags.Public, null, new Type[2] { typeof(Player), typeof(ItemData) }, null); _wouldStorePickupWithInventoryMethod = _apiType.GetMethod("WouldStorePickup", BindingFlags.Static | BindingFlags.Public, null, new Type[3] { typeof(Player), typeof(ItemData), typeof(Inventory).MakeByRefType() }, null); _registerVisualBundleMethod = _apiType.GetMethod("RegisterVisualBundle", BindingFlags.Static | BindingFlags.Public, null, new Type[3] { typeof(string), typeof(string), typeof(AssetBundle) }, null); _registerVisualBundleWithDefaultMethod = _apiType.GetMethod("RegisterVisualBundle", BindingFlags.Static | BindingFlags.Public, null, new Type[4] { typeof(string), typeof(string), typeof(AssetBundle), typeof(bool) }, null); _modelStyleType = assemblies[i].GetType("AdventureBackpacks.API.ModelStyle"); if (_modelStyleType != null) { _registerVisualBundleStyleMethod = _apiType.GetMethod("RegisterVisualBundle", BindingFlags.Static | BindingFlags.Public, null, new Type[4] { typeof(string), typeof(string), _modelStyleType, typeof(AssetBundle) }, null); _registerVisualBundleStyleWithDefaultMethod = _apiType.GetMethod("RegisterVisualBundle", BindingFlags.Static | BindingFlags.Public, null, new Type[5] { typeof(string), typeof(string), _modelStyleType, typeof(AssetBundle), typeof(bool) }, null); } } break; } } public static bool IsLoaded() { EnsureInitialized(); if (_isLoadedMethod != null) { return (bool)_isLoadedMethod.Invoke(null, null); } return false; } public static bool IsBackpack(ItemData itemData) { EnsureInitialized(); if (_isBackpackMethod != null && itemData != null) { return (bool)_isBackpackMethod.Invoke(null, new object[1] { itemData }); } return false; } public static bool IsBackpackEquipped(Player player) { EnsureInitialized(); if (_isBackpackEquippedMethod != null && (Object)(object)player != (Object)null) { return (bool)_isBackpackEquippedMethod.Invoke(null, new object[1] { player }); } return false; } public static bool CanOpenBackpack(Player player) { EnsureInitialized(); if (_canOpenBackpackMethod != null && (Object)(object)player != (Object)null) { return (bool)_canOpenBackpackMethod.Invoke(null, new object[1] { player }); } return false; } public static bool IsBackpackOpen() { EnsureInitialized(); if (_isBackpackOpenMethod != null) { return (bool)_isBackpackOpenMethod.Invoke(null, null); } return false; } public static bool IsThisBackpackEquipped(Player player, ItemData itemData) { EnsureInitialized(); if (_isThisBackpackEquippedMethod != null && (Object)(object)player != (Object)null && itemData != null) { return (bool)_isThisBackpackEquippedMethod.Invoke(null, new object[2] { player, itemData }); } return false; } public static Inventory GetEquippedBackpackInventory(Player player) { //IL_0030: Unknown result type (might be due to invalid IL or missing references) //IL_0036: Expected O, but got Unknown EnsureInitialized(); if (_getEquippedBackpackInventoryMethod != null && (Object)(object)player != (Object)null) { return (Inventory)_getEquippedBackpackInventoryMethod.Invoke(null, new object[1] { player }); } return null; } public static bool TryGetEquippedBackpackInventory(Player player, out Inventory inventory) { //IL_003e: Unknown result type (might be due to invalid IL or missing references) //IL_0044: Expected O, but got Unknown inventory = null; EnsureInitialized(); if (_tryGetEquippedBackpackInventoryMethod != null && (Object)(object)player != (Object)null) { object[] array = new object[2] { player, null }; bool result = (bool)_tryGetEquippedBackpackInventoryMethod.Invoke(null, array); inventory = (Inventory)array[1]; return result; } return false; } public static Inventory GetBackpackInventory(ItemData itemData) { //IL_002a: Unknown result type (might be due to invalid IL or missing references) //IL_0030: Expected O, but got Unknown EnsureInitialized(); if (_getBackpackInventoryMethod != null && itemData != null) { return (Inventory)_getBackpackInventoryMethod.Invoke(null, new object[1] { itemData }); } return null; } public static bool TryGetBackpackInventory(ItemData itemData, out Inventory inventory) { //IL_0038: Unknown result type (might be due to invalid IL or missing references) //IL_003e: Expected O, but got Unknown inventory = null; EnsureInitialized(); if (_tryGetBackpackInventoryMethod != null && itemData != null) { object[] array = new object[2] { itemData, null }; bool result = (bool)_tryGetBackpackInventoryMethod.Invoke(null, array); inventory = (Inventory)array[1]; return result; } return false; } public static List<Inventory> GetAllBackpackInventories(Player player) { EnsureInitialized(); if (_getAllBackpackInventoriesMethod != null && (Object)(object)player != (Object)null) { return (List<Inventory>)_getAllBackpackInventoriesMethod.Invoke(null, new object[1] { player }); } return new List<Inventory>(); } public static bool TryGetAllBackpackInventories(Player player, out List<Inventory> inventories) { inventories = null; EnsureInitialized(); if (_tryGetAllBackpackInventoriesMethod != null && (Object)(object)player != (Object)null) { object[] array = new object[2] { player, null }; bool result = (bool)_tryGetAllBackpackInventoriesMethod.Invoke(null, array); inventories = (List<Inventory>)array[1]; return result; } return false; } public static void OpenBackpack(Player player, InventoryGui gui) { EnsureInitialized(); if (_openBackpackMethod != null && (Object)(object)player != (Object)null && (Object)(object)gui != (Object)null) { _openBackpackMethod.Invoke(null, new object[2] { player, gui }); } } public static void OpenBackpack(Player player, InventoryGui gui, int activeGroup) { EnsureInitialized(); if (_openBackpackWithGroupMethod != null && (Object)(object)player != (Object)null && (Object)(object)gui != (Object)null) { _openBackpackWithGroupMethod.Invoke(null, new object[3] { player, gui, activeGroup }); } else if (_openBackpackMethod != null && (Object)(object)player != (Object)null && (Object)(object)gui != (Object)null) { _openBackpackMethod.Invoke(null, new object[2] { player, gui }); } } public static bool IsOpenWithCraftingStationEnabled() { EnsureInitialized(); if (_isOpenWithCraftingStationEnabledMethod != null) { return (bool)_isOpenWithCraftingStationEnabledMethod.Invoke(null, null); } return false; } public static bool IsOpenWithInventoryEnabled() { EnsureInitialized(); if (_isOpenWithInventoryEnabledMethod != null) { return (bool)_isOpenWithInventoryEnabledMethod.Invoke(null, null); } return false; } public static bool IsEnableContainerTabsEnabled() { EnsureInitialized(); if (_isEnableContainerTabsEnabledMethod != null) { return (bool)_isEnableContainerTabsEnabledMethod.Invoke(null, null); } return false; } public static bool HasActiveExternalContainer() { EnsureInitialized(); if (_hasActiveExternalContainerMethod != null) { return (bool)_hasActiveExternalContainerMethod.Invoke(null, null); } return false; } public static bool IsCraftFromBackpackEnabled() { EnsureInitialized(); if (_isCraftFromBackpackEnabledMethod != null) { return (bool)_isCraftFromBackpackEnabledMethod.Invoke(null, null); } return false; } public static bool IsCraftingContextActive() { EnsureInitialized(); if (_isCraftingContextActiveMethod != null) { return (bool)_isCraftingContextActiveMethod.Invoke(null, null); } return false; } public static string GetConsumptionPriority() { EnsureInitialized(); if (_getConsumptionPriorityMethod != null) { return (string)_getConsumptionPriorityMethod.Invoke(null, null); } return "PlayerInventoryFirst"; } public static bool IsLeaveOneItemInBackpackEnabled() { EnsureInitialized(); if (_isLeaveOneItemInBackpackEnabledMethod != null) { return (bool)_isLeaveOneItemInBackpackEnabledMethod.Invoke(null, null); } return false; } public static bool IsDisplayTotalIngredientCountEnabled() { EnsureInitialized(); if (_isDisplayTotalIngredientCountEnabledMethod != null) { return (bool)_isDisplayTotalIngredientCountEnabledMethod.Invoke(null, null); } return false; } public static void SuppressNativeCrafting(string modIdentifier) { EnsureInitialized(); if (_suppressNativeCraftingMethod != null && !string.IsNullOrEmpty(modIdentifier)) { _suppressNativeCraftingMethod.Invoke(null, new object[1] { modIdentifier }); } } public static void UnsuppressNativeCrafting(string modIdentifier) { EnsureInitialized(); if (_unsuppressNativeCraftingMethod != null && !string.IsNullOrEmpty(modIdentifier)) { _unsuppressNativeCraftingMethod.Invoke(null, new object[1] { modIdentifier }); } } public static bool WouldStorePickup(Player player, ItemData item) { EnsureInitialized(); if (!_isAvailable || _wouldStorePickupMethod == null) { return false; } try { return (bool)_wouldStorePickupMethod.Invoke(null, new object[2] { player, item }); } catch { return false; } } public static bool WouldStorePickup(Player player, ItemData item, out Inventory backpackInventory) { backpackInventory = null; EnsureInitialized(); if (!_isAvailable || _wouldStorePickupWithInventoryMethod == null) { return false; } try { object[] array = new object[3] { player, item, null }; bool num = (bool)_wouldStorePickupWithInventoryMethod.Invoke(null, array); if (num) { object obj = array[2]; backpackInventory = (Inventory)((obj is Inventory) ? obj : null); } return num; } catch { return false; } } public static bool RegisterVisualBundle(string packName, string targetBundleName, AssetBundle overrideBundle) { return RegisterVisualBundle(packName, targetBundleName, overrideBundle, isDefault: false); } public static bool RegisterVisualBundle(string packName, string targetBundleName, AssetBundle overrideBundle, bool isDefault) { EnsureInitialized(); if (!_isAvailable) { return false; } try { if (_registerVisualBundleWithDefaultMethod != null) { _registerVisualBundleWithDefaultMethod.Invoke(null, new object[4] { packName, targetBundleName, overrideBundle, isDefault }); return true; } if (_registerVisualBundleMethod != null) { _registerVisualBundleMethod.Invoke(null, new object[3] { packName, targetBundleName, overrideBundle }); return true; } return false; } catch { return false; } } public static bool RegisterVisualBundle(string packName, string backpackId, ModelStyle modelStyle, AssetBundle overrideBundle, bool isDefault = false) { EnsureInitialized(); if (!_isAvailable || _modelStyleType == null) { return false; } try { object obj = Enum.ToObject(_modelStyleType, (int)modelStyle); if (_registerVisualBundleStyleWithDefaultMethod != null) { _registerVisualBundleStyleWithDefaultMethod.Invoke(null, new object[5] { packName, backpackId, obj, overrideBundle, isDefault }); return true; } if (_registerVisualBundleStyleMethod != null) { _registerVisualBundleStyleMethod.Invoke(null, new object[4] { packName, backpackId, obj, overrideBundle }); return true; } return false; } catch { return false; } } public static bool RegisterVisualBundle(string packName, BackpackName backpack, ModelStyle modelStyle, AssetBundle overrideBundle, bool isDefault = false) { return RegisterVisualBundle(packName, backpack.ToBackpackId(), modelStyle, overrideBundle, isDefault); } } public static class BackpackExtensions { public static string ToBackpackId(this ABAPIClient.BackpackName backpack) { return backpack switch { ABAPIClient.BackpackName.Meadows => "backpack_meadows", ABAPIClient.BackpackName.BlackForest => "backpack_black_forest", ABAPIClient.BackpackName.Swamp => "backpack_swamp", ABAPIClient.BackpackName.Mountains => "backpack_mountains", ABAPIClient.BackpackName.Plains => "backpack_plains", ABAPIClient.BackpackName.Mistlands => "backpack_mistlands", ABAPIClient.BackpackName.Ashlands => "backpack_ashlands", ABAPIClient.BackpackName.DeepNorth => "backpack_deepnorth", _ => "backpack_meadows", }; } } } namespace AdventureBackpacks.HD { [BepInPlugin("vapok.mods.adventurebackpackshd", "Adventure Backpacks HD", "1.0.0")] [BepInDependency(/*Could not decode attribute arguments.*/)] public class AdventureBackpacksHD : BaseUnityPlugin { public const string ModId = "vapok.mods.adventurebackpackshd"; public const string ModName = "Adventure Backpacks HD"; public const string ModVersion = "1.0.0"; public const string PackName = "Native HD"; private void Awake() { string assetsDirectory = Path.Combine(Path.GetDirectoryName(((BaseUnityPlugin)this).Info.Location) ?? string.Empty, "Assets"); RegisterBundle(ABAPIClient.BackpackName.Meadows, ABAPIClient.ModelStyle.Modern, "hd_backpack_meadows", assetsDirectory); RegisterBundle(ABAPIClient.BackpackName.BlackForest, ABAPIClient.ModelStyle.Modern, "hd_backpack_black_forest", assetsDirectory); RegisterBundle(ABAPIClient.BackpackName.Swamp, ABAPIClient.ModelStyle.Modern, "hd_backpack_swamp", assetsDirectory); RegisterBundle(ABAPIClient.BackpackName.Mountains, ABAPIClient.ModelStyle.Modern, "hd_backpack_mountains", assetsDirectory); RegisterBundle(ABAPIClient.BackpackName.Plains, ABAPIClient.ModelStyle.Modern, "hd_backpack_plains", assetsDirectory); RegisterBundle(ABAPIClient.BackpackName.Mistlands, ABAPIClient.ModelStyle.Modern, "hd_backpack_mistlands", assetsDirectory); RegisterBundle(ABAPIClient.BackpackName.Ashlands, ABAPIClient.ModelStyle.Modern, "hd_backpack_ashlands", assetsDirectory); RegisterBundle(ABAPIClient.BackpackName.DeepNorth, ABAPIClient.ModelStyle.Modern, "hd_backpack_deepnorth", assetsDirectory); RegisterBundle(ABAPIClient.BackpackName.Meadows, ABAPIClient.ModelStyle.Classic, "hd_classic_backpack_meadows", assetsDirectory); RegisterBundle(ABAPIClient.BackpackName.BlackForest, ABAPIClient.ModelStyle.Classic, "hd_classic_backpack_black_forest", assetsDirectory); RegisterBundle(ABAPIClient.BackpackName.Swamp, ABAPIClient.ModelStyle.Classic, "hd_classic_backpack_swamp", assetsDirectory); RegisterBundle(ABAPIClient.BackpackName.Mountains, ABAPIClient.ModelStyle.Classic, "hd_classic_backpack_mountains", assetsDirectory); RegisterBundle(ABAPIClient.BackpackName.Plains, ABAPIClient.ModelStyle.Classic, "hd_classic_backpack_plains", assetsDirectory); RegisterBundle(ABAPIClient.BackpackName.Mistlands, ABAPIClient.ModelStyle.Classic, "hd_classic_backpack_mistlands", assetsDirectory); } private void RegisterBundle(ABAPIClient.BackpackName backpack, ABAPIClient.ModelStyle modelStyle, string bundleFileName, string assetsDirectory) { string text = Path.Combine(assetsDirectory, bundleFileName); if (!File.Exists(text)) { return; } try { AssetBundle val = AssetBundle.LoadFromFile(text); if ((Object)(object)val != (Object)null) { if (ABAPIClient.RegisterVisualBundle("Native HD", backpack, modelStyle, val, isDefault: true)) { ((BaseUnityPlugin)this).Logger.LogInfo((object)$"Registered visual override for '{backpack}' ({modelStyle}) from '{bundleFileName}'."); } else { ((BaseUnityPlugin)this).Logger.LogWarning((object)$"Failed to register visual override for '{backpack}' ({modelStyle}). Is AdventureBackpacks active?"); } } } catch (Exception ex) { ((BaseUnityPlugin)this).Logger.LogWarning((object)("Failed to load companion bundle '" + bundleFileName + "': " + ex.Message)); } } } }