AnchorSave is a lightweight, JSON-based save system for Unity.
It is designed to be simple, explicit, and safe, without using deprecated APIs like BinaryFormatter, reflection-heavy magic, or opaque serialization pipelines.
If you want full control over what gets saved — and the ability to inspect and debug save files — AnchorSave is built for that.
- Explicit save/load via ISaveable
- Human-readable JSON save files
- Slot-based saving support
- Works in builds and in the Editor
- No BinaryFormatter
- No reflection-based auto-serialization
- Demo scene included
Full documentation: Documentation
AnchorSave follows a simple rule:
Only objects that implement ISaveable are saved.
Each saveable object:
- Provides a stable UID
- Returns a plain serializable data structure
- Restores itself from JSON during load
The save system:
- Iterates over all active ISaveable components
- Stores their data as JSON, keyed by UID
- Restores state by matching UIDs on load
There is no automatic scene scanning, guessing, or hidden behavior.
public class Player : MonoBehaviour, ISaveable
{
public string UID => "Player";
public object CaptureState()
{
return new PlayerSaveData
{
position = new float[]
{
transform.position.x,
transform.position.y,
transform.position.z
}
};
}
public void RestoreState(object state)
{
PlayerSaveData data =
JsonUtility.FromJson<PlayerSaveData>((string)state);
transform.position = new Vector3(
data.position[0],
data.position[1],
data.position[2]
);
}
}