diff --git a/NewHorizons/External/NewHorizonBody.cs b/NewHorizons/External/NewHorizonBody.cs index 6fe60823..6779e526 100644 --- a/NewHorizons/External/NewHorizonBody.cs +++ b/NewHorizons/External/NewHorizonBody.cs @@ -28,11 +28,20 @@ namespace NewHorizons.External public bool RequiresDLC() { - var detailPaths = Config.Props.details.Select(x => x.path); - return Config.Cloak != null - || Config.Props?.rafts != null - || Config.Props?.slideShows != null - || detailPaths.Any(x => x.StartsWith("RingWorld_Body") || x.StartsWith("DreamWorld_Body")); + try + { + var detailPaths = Config?.Props?.details?.Select(x => x.path) ?? Array.Empty(); + return Config?.Cloak != null + || Config?.Props?.rafts != null + || Config?.Props?.slideShows != null + || detailPaths.Any(x => x.StartsWith("RingWorld_Body") || x.StartsWith("DreamWorld_Body")); + } + catch + { + NHLogger.LogWarning($"Failed to check if {Mod.ModHelper.Manifest.Name} requires the DLC"); + return false; + } + } #region Cache diff --git a/NewHorizons/manifest.json b/NewHorizons/manifest.json index c7f6ccf1..ec47461c 100644 --- a/NewHorizons/manifest.json +++ b/NewHorizons/manifest.json @@ -4,7 +4,7 @@ "author": "xen, Bwc9876, clay, MegaPiggy, John, Trifid, Hawkbar, Book", "name": "New Horizons", "uniqueName": "xen.NewHorizons", - "version": "1.18.5", + "version": "1.18.6", "owmlVersion": "2.9.8", "dependencies": [ "JohnCorby.VanillaFix", "_nebula.MenuFramework", "xen.CommonCameraUtility", "dgarro.CustomShipLogModes" ], "conflicts": [ "Raicuparta.QuantumSpaceBuddies", "PacificEngine.OW_CommonResources" ],