unity-save-system
Installation
SKILL.md
Save/Load Systems -- Decision Patterns
Prerequisite skills:
unity-lifecycle(OnApplicationPause, OnApplicationQuit, quit sequence),unity-data-driven(JSON serialization, versioning),unity-packages-services(Cloud Save API),unity-async-patterns(BackgroundThreadAsync)
These patterns address the most common save system failure: Claude uses PlayerPrefs for everything, produces brittle serialization with no versioning, and ignores mobile-specific persistence requirements.
PATTERN: Serialization Format Selection
WHEN: Choosing how to serialize save data to disk
DECISION:
- JSON (
JsonUtility) -- Human-readable, debuggable, small save files. No dictionary/polymorphism. Best default for most games. - JSON (Newtonsoft) -- Full JSON features (dictionaries, polymorphism, LINQ). Slightly larger dependency. Best when save data is complex.
- Binary (custom or MessagePack) -- Performance-critical, large saves, anti-cheat (harder to edit). Not human-readable. Best for competitive games or very large worlds.
- BinaryFormatter -- NEVER USE. Security vulnerability (arbitrary code execution on deserialization). Deprecated by Unity and Microsoft.
Related skills