remove warning for mods which use `dynamic`
This commit is contained in:
parent
a9cadc7f32
commit
3a4758dfa6
|
@ -1,6 +1,11 @@
|
|||
← [README](README.md)
|
||||
|
||||
# Release notes
|
||||
## Upcoming release
|
||||
* For mod authors:
|
||||
* Removed warning for mods which use `dynamic`.
|
||||
_This no longer causes errors on Linux/macOS after Stardew Valley 1.5.5._
|
||||
|
||||
## 3.14.3
|
||||
Released 12 May 2022 for Stardew Valley 1.5.6 or later.
|
||||
|
||||
|
|
|
@ -19,6 +19,7 @@ namespace StardewModdingAPI.Toolkit.Framework.ModData
|
|||
PatchesGame = 4,
|
||||
|
||||
/// <summary>The mod uses the <c>dynamic</c> keyword which won't work on Linux/macOS.</summary>
|
||||
[Obsolete("This value is no longer used by SMAPI and will be removed in the upcoming SMAPI 4.0.0.")]
|
||||
UsesDynamic = 8,
|
||||
|
||||
/// <summary>The mod references specialized 'unvalidated update tick' events which may impact stability.</summary>
|
||||
|
|
|
@ -511,11 +511,6 @@ namespace StardewModdingAPI.Framework.Logging
|
|||
"These mods have no update keys in their manifest. SMAPI may not notify you about updates for these",
|
||||
"mods. Consider notifying the mod authors about this problem."
|
||||
);
|
||||
|
||||
// not crossplatform
|
||||
this.LogModWarningGroup(modsWithWarnings, ModWarning.UsesDynamic, LogLevel.Debug, "Not crossplatform",
|
||||
"These mods use the 'dynamic' keyword, and won't work on Linux/macOS."
|
||||
);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -414,11 +414,6 @@ namespace StardewModdingAPI.Framework.ModLoading
|
|||
mod.SetWarning(ModWarning.UsesUnvalidatedUpdateTick);
|
||||
break;
|
||||
|
||||
case InstructionHandleResult.DetectedDynamic:
|
||||
template = $"{logPrefix}Detected 'dynamic' keyword ($phrase) in assembly {filename}.";
|
||||
mod.SetWarning(ModWarning.UsesDynamic);
|
||||
break;
|
||||
|
||||
case InstructionHandleResult.DetectedConsoleAccess:
|
||||
template = $"{logPrefix}Detected direct console access ($phrase) in assembly {filename}.";
|
||||
mod.SetWarning(ModWarning.AccessesConsole);
|
||||
|
|
|
@ -20,9 +20,6 @@ namespace StardewModdingAPI.Framework.ModLoading
|
|||
/// <summary>The instruction is compatible, but affects the save serializer in a way that may make saves unloadable without the mod.</summary>
|
||||
DetectedSaveSerializer,
|
||||
|
||||
/// <summary>The instruction is compatible, but uses the <c>dynamic</c> keyword which won't work on Linux/macOS.</summary>
|
||||
DetectedDynamic,
|
||||
|
||||
/// <summary>The instruction is compatible, but references <see cref="ISpecializedEvents.UnvalidatedUpdateTicking"/> or <see cref="ISpecializedEvents.UnvalidatedUpdateTicked"/> which may impact stability.</summary>
|
||||
DetectedUnvalidatedUpdateTick,
|
||||
|
||||
|
|
|
@ -67,7 +67,6 @@ namespace StardewModdingAPI.Metadata
|
|||
/****
|
||||
** detect code which may impact game stability
|
||||
****/
|
||||
yield return new TypeFinder("System.Runtime.CompilerServices.CallSite", InstructionHandleResult.DetectedDynamic);
|
||||
yield return new FieldFinder(typeof(SaveGame).FullName!, new[] { nameof(SaveGame.serializer), nameof(SaveGame.farmerSerializer), nameof(SaveGame.locationSerializer) }, InstructionHandleResult.DetectedSaveSerializer);
|
||||
yield return new EventFinder(typeof(ISpecializedEvents).FullName!, new[] { nameof(ISpecializedEvents.UnvalidatedUpdateTicked), nameof(ISpecializedEvents.UnvalidatedUpdateTicking) }, InstructionHandleResult.DetectedUnvalidatedUpdateTick);
|
||||
|
||||
|
|
Loading…
Reference in New Issue