tweak new API method name

This commit is contained in:
Jesse Plamondon-Willard 2018-12-13 01:26:54 -05:00
parent e447ce225f
commit 11787f9fea
No known key found for this signature in database
GPG Key ID: 7D7C8097B62033CE
4 changed files with 8 additions and 5 deletions

View File

@ -43,7 +43,7 @@ namespace StardewModdingAPI.Framework.ModHelpers
public IContentPack CreateFake(string directoryPath)
{
string id = Guid.NewGuid().ToString("N");
return this.CreateFake(directoryPath, id, id, id, id, new SemanticVersion(1, 0, 0));
return this.CreateTemporary(directoryPath, id, id, id, id, new SemanticVersion(1, 0, 0));
}
/// <summary>Create a temporary content pack to read files from a directory. Temporary content packs will not appear in the SMAPI log and update checks will not be performed.</summary>
@ -53,7 +53,7 @@ namespace StardewModdingAPI.Framework.ModHelpers
/// <param name="description">The content pack description.</param>
/// <param name="author">The content pack author's name.</param>
/// <param name="version">The content pack version.</param>
public IContentPack CreateFake(string directoryPath, string id, string name, string description, string author, ISemanticVersion version)
public IContentPack CreateTemporary(string directoryPath, string id, string name, string description, string author, ISemanticVersion version)
{
// validate
if (string.IsNullOrWhiteSpace(directoryPath))

View File

@ -174,7 +174,7 @@ namespace StardewModdingAPI.Framework.ModHelpers
/// <param name="description">The content pack description.</param>
/// <param name="author">The content pack author's name.</param>
/// <param name="version">The content pack version.</param>
[Obsolete("Use " + nameof(IModHelper) + "." + nameof(IModHelper.ContentPacks) + "." + nameof(IContentPackHelper.CreateFake) + " instead")]
[Obsolete("Use " + nameof(IModHelper) + "." + nameof(IModHelper.ContentPacks) + "." + nameof(IContentPackHelper.CreateTemporary) + " instead")]
public IContentPack CreateTransitionalContentPack(string directoryPath, string id, string name, string description, string author, ISemanticVersion version)
{
this.DeprecationManager.Warn($"{nameof(IModHelper)}.{nameof(IModHelper.CreateTransitionalContentPack)}", "2.5", DeprecationLevel.Notice);

View File

@ -22,6 +22,6 @@ namespace StardewModdingAPI
/// <param name="description">The content pack description.</param>
/// <param name="author">The content pack author's name.</param>
/// <param name="version">The content pack version.</param>
IContentPack CreateFake(string directoryPath, string id, string name, string description, string author, ISemanticVersion version);
IContentPack CreateTemporary(string directoryPath, string id, string name, string description, string author, ISemanticVersion version);
}
}

View File

@ -77,6 +77,9 @@ namespace StardewModdingAPI
[Obsolete("Use " + nameof(IModHelper.Data) + "." + nameof(IDataHelper.WriteJsonFile) + " instead")]
void WriteJsonFile<TModel>(string path, TModel model) where TModel : class;
/****
** Content packs
****/
/// <summary>Manually create a transitional content pack to support pre-SMAPI content packs. This provides a way to access legacy content packs using the SMAPI content pack APIs, but the content pack will not be visible in the log or validated by SMAPI.</summary>
/// <param name="directoryPath">The absolute directory path containing the content pack files.</param>
/// <param name="id">The content pack's unique ID.</param>
@ -84,7 +87,7 @@ namespace StardewModdingAPI
/// <param name="description">The content pack description.</param>
/// <param name="author">The content pack author's name.</param>
/// <param name="version">The content pack version.</param>
[Obsolete("Use " + nameof(IModHelper) + "." + nameof(IModHelper.ContentPacks) + "." + nameof(IContentPackHelper.CreateFake) + " instead")]
[Obsolete("Use " + nameof(IModHelper) + "." + nameof(IModHelper.ContentPacks) + "." + nameof(IContentPackHelper.CreateTemporary) + " instead")]
IContentPack CreateTransitionalContentPack(string directoryPath, string id, string name, string description, string author, ISemanticVersion version);
/// <summary>Get all content packs loaded for this mod.</summary>