Saving Data - Serialization

MSDN Reference Example: Binary Serialization

"Serialization can be defined as the process of storing the state of an object to a storage medium. During this process, the public and private fields of the object and the name of the class, including the assembly containing the class, are converted to a stream of bytes, which is then written to a data stream. When the object is subsequently deserialized, an exact clone of the original object is created."

"Why would you want to use serialization? The two most important reasons are to persist the state of an object to a storage medium so an exact copy can be re-created at a later stage, and to send the object by value from one application domain to another. " MSDN Serialization Concepts

Script Serialization in Unity - Reference Manual

In Unity, objects that are marked with the Serialized Attribute, or fields marked with SerializeField Attribute, are persisted by the Unity serialization process. This serialization allows for saving of data between the unity editor system, where objects are created using C# or UnityScript, for design-time use, and the Unity game-engine for game-play mode, which uses C++ S However there may be cases when we want more customized control over serialization of game data.

Unity Blog on Serialization In Unity

Unity SerializeField Reference

Tutorial on Saving - Loading Game Data - TutsPlus

Tutorial on Saving - Loading Game Data - SitePoint

Class Demo Project -Spring 17: MiniGame with Binary Serialization

Last updated