A persistent class that can save the essential parts of an object : its transform data (position, rotation, scale) and its active state This inherits from MMPersistentBase and implements the IMMPersistent interface It's a good example of how to implement the interface's OnSave and OnLoad methods
More...
|
override string | OnSave () |
| On Save, we turn the object's transform data and active state to a Json string and return it to the MMPersistencyManager More...
|
|
override void | OnLoad (string data) |
| On load, we read the saved json data and apply it to our object's properties More...
|
|
virtual string | GetGuid () |
| Returns the object's GUID More...
|
|
virtual void | SetGuid (string newGUID) |
| Lets you set the object's GUID More...
|
|
virtual bool | ShouldBeSaved () |
| Lets the persistence manager know whether or not the object should be saved More...
|
|
virtual string | GenerateGuid () |
| Generates a unique ID for the object, using the scene name, the object name, and a GUID More...
|
|
virtual bool | GuidIsUnique (string guid) |
| Checks if the object's ID is unique or not More...
|
|
virtual void | ValidateGuid () |
| Validates the object's GUID, and generates a new one if needed, until a unique one is found More...
|
|
A persistent class that can save the essential parts of an object : its transform data (position, rotation, scale) and its active state This inherits from MMPersistentBase and implements the IMMPersistent interface It's a good example of how to implement the interface's OnSave and OnLoad methods
◆ GetCurrentComponents()
virtual List<ComponentData> MoreMountains.Tools.MMPersistent.GetCurrentComponents |
( |
| ) |
|
|
protectedvirtual |
Grabs all components on this object
◆ OnLoad()
override void MoreMountains.Tools.MMPersistent.OnLoad |
( |
string |
data | ) |
|
|
virtual |
◆ OnSave()
override string MoreMountains.Tools.MMPersistent.OnSave |
( |
| ) |
|
|
virtual |
On Save, we turn the object's transform data and active state to a Json string and return it to the MMPersistencyManager
- Returns
Reimplemented from MoreMountains.Tools.MMPersistentBase.
◆ SaveActiveState
bool MoreMountains.Tools.MMPersistent.SaveActiveState = true |
whether or not to save this object's active state
◆ SaveEnabledStates
bool MoreMountains.Tools.MMPersistent.SaveEnabledStates = false |
whether or not to save this object's components' enabled states
◆ SaveLocalRotation
bool MoreMountains.Tools.MMPersistent.SaveLocalRotation = true |
whether or not to save this object's rotation
◆ SaveLocalScale
bool MoreMountains.Tools.MMPersistent.SaveLocalScale = true |
whether or not to save this object's scale
◆ SavePosition
bool MoreMountains.Tools.MMPersistent.SavePosition = true |
whether or not to save this object's position
The documentation for this class was generated from the following file:
- F:/Github/Store/TopDownEngine/Assets/TopDownEngine/ThirdParty/MoreMountains/MMTools/Core/MMSaveLoad/MMPersistent.cs