diff options
Diffstat (limited to 'src/SMAPI/Framework/ModHelpers/ContentHelper.cs')
-rw-r--r-- | src/SMAPI/Framework/ModHelpers/ContentHelper.cs | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/SMAPI/Framework/ModHelpers/ContentHelper.cs b/src/SMAPI/Framework/ModHelpers/ContentHelper.cs index 94a30bf1..3c2441e8 100644 --- a/src/SMAPI/Framework/ModHelpers/ContentHelper.cs +++ b/src/SMAPI/Framework/ModHelpers/ContentHelper.cs @@ -118,6 +118,17 @@ namespace StardewModdingAPI.Framework.ModHelpers switch (source) { case ContentSource.GameContent: + if (assetName.Name.EndsWith(".xnb", StringComparison.OrdinalIgnoreCase)) + { + assetName = this.ContentCore.ParseAssetName(assetName.Name[..^4], allowLocales: true); + SCore.DeprecationManager.Warn( + this.Mod, + "loading assets from the Content folder with a .xnb file extension", + "3.14.0", + DeprecationLevel.Notice + ); + } + return this.GameContentManager.LoadLocalized<T>(assetName, this.CurrentLocaleConstant, useCache: false); case ContentSource.ModFolder: |