diff options
Diffstat (limited to 'src/SMAPI/Events')
-rw-r--r-- | src/SMAPI/Events/IGameLoopEvents.cs | 2 | ||||
-rw-r--r-- | src/SMAPI/Events/ISpecialisedEvents.cs | 3 | ||||
-rw-r--r-- | src/SMAPI/Events/SavePreloadedEventArgs.cs | 7 |
3 files changed, 11 insertions, 1 deletions
diff --git a/src/SMAPI/Events/IGameLoopEvents.cs b/src/SMAPI/Events/IGameLoopEvents.cs index e1900f79..ea79aa74 100644 --- a/src/SMAPI/Events/IGameLoopEvents.cs +++ b/src/SMAPI/Events/IGameLoopEvents.cs @@ -26,7 +26,7 @@ namespace StardewModdingAPI.Events /// <summary>Raised after the game finishes writing data to the save file (except the initial save creation).</summary> event EventHandler<SavedEventArgs> Saved; - /// <summary>Raised after the player loads a save slot.</summary> + /// <summary>Raised after the player loads a save slot and the world is initialised.</summary> event EventHandler<SaveLoadedEventArgs> SaveLoaded; /// <summary>Raised after the game begins a new day (including when the player loads a save).</summary> diff --git a/src/SMAPI/Events/ISpecialisedEvents.cs b/src/SMAPI/Events/ISpecialisedEvents.cs index 928cd05d..2a19113c 100644 --- a/src/SMAPI/Events/ISpecialisedEvents.cs +++ b/src/SMAPI/Events/ISpecialisedEvents.cs @@ -5,6 +5,9 @@ namespace StardewModdingAPI.Events /// <summary>Events serving specialised edge cases that shouldn't be used by most mods.</summary> public interface ISpecialisedEvents { + /// <summary>Raised immediately after the player loads a save slot, but before the world is fully initialised. The save and game data are available at this point, but some in-game content (like location maps) haven't been initialised yet.</summary> + event EventHandler<SavePreloadedEventArgs> SavePreloaded; + /// <summary>Raised before the game state is updated (≈60 times per second), regardless of normal SMAPI validation. This event is not thread-safe and may be invoked while game logic is running asynchronously. Changes to game state in this method may crash the game or corrupt an in-progress save. Do not use this event unless you're fully aware of the context in which your code will be run. Mods using this event will trigger a stability warning in the SMAPI console.</summary> event EventHandler<UnvalidatedUpdateTickingEventArgs> UnvalidatedUpdateTicking; diff --git a/src/SMAPI/Events/SavePreloadedEventArgs.cs b/src/SMAPI/Events/SavePreloadedEventArgs.cs new file mode 100644 index 00000000..03990f5a --- /dev/null +++ b/src/SMAPI/Events/SavePreloadedEventArgs.cs @@ -0,0 +1,7 @@ +using System; + +namespace StardewModdingAPI.Events +{ + /// <summary>Event arguments for an <see cref="ISpecialisedEvents.SavePreloaded"/> event.</summary> + public class SavePreloadedEventArgs : EventArgs { } +} |