Interface ISaveSection
A single, independently serializable slice of a game save (inventory, milestones, completion, or any project-defined extension). Registered with the game-save service so it is folded into every save and restored from every load.
Namespace: Serenity.GameSave.Domain.Interfaces
Assembly: Serenity.GameSave.Domain.dll
Syntax
public interface ISaveSection
Properties
SectionKey
The stable key this section is stored under within a SaveDocument.
Declaration
string SectionKey { get; }
Property Value
| Type | Description |
|---|---|
| string |
Methods
Deserialize(string)
Restores this section's state from payload. A null or empty payload
(no prior save, or a brand-new slot) resets this section to its default state.
Declaration
void Deserialize(string payload)
Parameters
| Type | Name | Description |
|---|---|---|
| string | payload |
Serialize()
Serializes this section's current state to JSON.
Declaration
string Serialize()
Returns
| Type | Description |
|---|---|
| string |