summaryrefslogtreecommitdiff
path: root/src/SMAPI/Framework/IModMetadata.cs
diff options
context:
space:
mode:
Diffstat (limited to 'src/SMAPI/Framework/IModMetadata.cs')
-rw-r--r--src/SMAPI/Framework/IModMetadata.cs22
1 files changed, 18 insertions, 4 deletions
diff --git a/src/SMAPI/Framework/IModMetadata.cs b/src/SMAPI/Framework/IModMetadata.cs
index a36994fd..d1e8eb7d 100644
--- a/src/SMAPI/Framework/IModMetadata.cs
+++ b/src/SMAPI/Framework/IModMetadata.cs
@@ -1,4 +1,4 @@
-using StardewModdingAPI.Framework.Models;
+using StardewModdingAPI.Framework.ModData;
using StardewModdingAPI.Framework.ModLoading;
namespace StardewModdingAPI.Framework
@@ -18,8 +18,8 @@ namespace StardewModdingAPI.Framework
/// <summary>The mod manifest.</summary>
IManifest Manifest { get; }
- /// <summary>>Metadata about the mod from SMAPI's internal data (if any).</summary>
- ModDataRecord DataRecord { get; }
+ /// <summary>Metadata about the mod from SMAPI's internal data (if any).</summary>
+ ParsedModDataRecord DataRecord { get; }
/// <summary>The metadata resolution status.</summary>
ModMetadataStatus Status { get; }
@@ -27,12 +27,21 @@ namespace StardewModdingAPI.Framework
/// <summary>The reason the metadata is invalid, if any.</summary>
string Error { get; }
- /// <summary>The mod instance (if it was loaded).</summary>
+ /// <summary>The mod instance (if loaded and <see cref="IsContentPack"/> is false).</summary>
IMod Mod { get; }
+ /// <summary>The content pack instance (if loaded and <see cref="IsContentPack"/> is true).</summary>
+ IContentPack ContentPack { get; }
+
+ /// <summary>Writes messages to the console and log file as this mod.</summary>
+ IMonitor Monitor { get; }
+
/// <summary>The mod-provided API (if any).</summary>
object Api { get; }
+ /// <summary>Whether the mod is a content pack.</summary>
+ bool IsContentPack { get; }
+
/*********
** Public methods
@@ -47,6 +56,11 @@ namespace StardewModdingAPI.Framework
/// <param name="mod">The mod instance to set.</param>
IModMetadata SetMod(IMod mod);
+ /// <summary>Set the mod instance.</summary>
+ /// <param name="contentPack">The contentPack instance to set.</param>
+ /// <param name="monitor">Writes messages to the console and log file.</param>
+ IModMetadata SetMod(IContentPack contentPack, IMonitor monitor);
+
/// <summary>Set the mod-provided API instance.</summary>
/// <param name="api">The mod-provided API.</param>
IModMetadata SetApi(object api);