ZionGames Docs

Home / Zion Tools

🧰 Zion Tools

Unity Editor Asset Tools

Save Diff 1.1

The Compare ▾ button diffs the tree currently open in the editor - including unsaved edits - against a second payload, and answers the question the raw files can't: what actually changed?

Comparison targets

Menu itemCompares against
With BackupThe source's automatic backup - the .bak sibling for file saves, the EditorPrefs stash for PlayerPrefs. Available whenever the current source implements ISaveBackupProvider and a backup exists.
With Another SaveAny other entry in the current source.
With File…An arbitrary file picked from disk - for example, a save emailed in with a bug report.

How it compares

The comparison payload is parsed with the best-matching format, then both trees are flattened to dotted paths (stats.health, inventory[2].id) and compared. Object members compare by name - order-insensitive - while array elements compare by index.

The Save Diff window

Row badgeMeaning
ADDEDPresent only in the current save.
REMOVEDPresent only in the comparison payload.
CHANGEDSame path and kind, different scalar value.
TYPESame path, different node kind - e.g. a number that became a string.

Before and after values sit side by side; container rows summarise child counts. Per-category filter toggles and a path search field narrow long diffs, and Copy as Markdown exports the whole diff as a table for a bug tracker or pull request.

Two workflows worth knowing

  • Pre-save preview. Because unsaved edits are included, running Compare > With Backup right before Save Changes shows exactly what the write will modify - a safety net for aggressive editing sessions.
  • Bug triage. Compare a player's broken save against a known-good slot (or file) to pinpoint the divergence in seconds instead of reading two JSON files line by line.
Custom sources light up With Backup by implementing ISaveBackupProvider - one method. See Custom Source.
Continue to Schema & Reports.