Log error if addon manifest couldn't load (improper formatting)

This commit is contained in:
Nick 2024-02-07 11:29:00 -05:00
parent 563370119a
commit 804ef01808

View File

@ -735,6 +735,12 @@ namespace NewHorizons
var addonConfig = mod.ModHelper.Storage.Load<AddonConfig>(file, false);
if (addonConfig == null)
{
NHLogger.LogError($"Addon manifest for {mod.ModHelper.Manifest.Name} could not load, check your JSON");
return;
}
if (addonConfig.achievements != null)
{
AchievementHandler.RegisterAddon(addonConfig, mod as ModBehaviour);