Savegame Class |
Namespace: SavegamePro
public class Savegame
The Savegame type exposes the following members.
| Name | Description | |
|---|---|---|
| Savegame(SavegameSettings) |
Creates a savegame with settings and default UnitySurrogateSelector.
| |
| Savegame(SavegameSettings, SurrogateSelector) |
Creates a savegame with the settings and selector.
|
| Name | Description | |
|---|---|---|
| FullFilePath |
Returns the full filepath to the savegame file
| |
| FullFilePathSurrogates |
Return the full filepath to the file containing additionally saved types
| |
| SurrogateSelector |
Returns the SurrogateSelector of this Savegame
|
| Name | Description | |
|---|---|---|
| AddSurrogateForType |
Add a default surrogate for type
| |
| Clear |
Removes all saved gamedata.
| |
| DeleteFromDisk |
Deletes the savefile from disk and clears all saved gamedata.
| |
| Equals | Determines whether the specified object is equal to the current object. (Inherited from Object.) | |
| Finalize | Allows an object to try to free resources and perform other cleanup operations before it is reclaimed by garbage collection. (Inherited from Object.) | |
| GetHashCode | Serves as the default hash function. (Inherited from Object.) | |
| GetType | Gets the Type of the current instance. (Inherited from Object.) | |
| LoadT(String) |
Load an object with its unique key. If the key is not found, this method throws an ArgumentException.
| |
| LoadT(String, T) |
Load GameObjects, Components and other UnityEngine types with their unique key. If the key is not found, this method throws an ArgumentException.
| |
| MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object.) | |
| ReadFromDisk |
Reads gamedata from disk and makes it available to load.
| |
| Remove |
Removes saved gamedata with the given key.
| |
| Save |
Save an object with a unique key. If the key already exists, the value is overwritten.
The object must be serializable. If the object is not serializable and does not have a serialization surrogate, an ArgumentException will be thrown.
| |
| ToString | Returns a string that represents the current object. (Inherited from Object.) | |
| WriteToDisk |
Writes all gamedata to disk. Will create a directory and/or file if needed.
|
| Name | Description | |
|---|---|---|
| Logging |
Sets the LogLevel when saving or loading. Default is LogLevel.ReadingWriting.
|