You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
UnityBinaryFormat["<b>UnityBinaryFormat</b><br/>C# parsers & helpers<br/>for Archives / SerializedFiles"]
55
+
UnityDataModels["<b>UnityDataModels</b><br/>schemas for build reporting file formats"]
56
+
57
+
CLI --> Analyzer
58
+
CLI --> TextDumper
59
+
CLI --> ReferenceFinder
60
+
CLI --> UnityBinaryFormat
61
+
CLI --> UnityFileSystem
62
+
63
+
Analyzer --> UnityFileSystem
64
+
Analyzer --> UnityBinaryFormat
65
+
Analyzer --> UnityDataModels
66
+
TextDumper --> UnityFileSystem
67
+
TextDumper --> UnityBinaryFormat
68
+
UnityBinaryFormat --> UnityFileSystem
69
+
70
+
ReferenceFinder -. "reads the SQLite database" .-> Analyzer
71
+
```
72
+
73
+
**Command-line tool**
74
+
*[UnityDataTool](Documentation/unitydatatool.md): the command-line tool. It wires the feature
75
+
libraries together and exposes them as commands (`analyze`, `dump`, `find-refs`, and more), so most
76
+
users only ever interact with this executable. It also directly contains the implementation of the
77
+
`archive` and `serialized-file` commands — critical features for working with the file formats,
78
+
built mostly on top of UnityBinaryFormat.
79
+
80
+
**Feature libraries**
81
+
*[Analyzer](Documentation/analyzer.md): extracts key information from Unity data files into a SQLite
82
+
database for detailed analysis. It also parses Addressables build reports.
83
+
*[TextDumper](Documentation/textdumper.md): dumps SerializedFiles into a human-readable format
84
+
(similar to Unity's binary2text).
85
+
*[ReferenceFinder](Documentation/referencefinder.md): finds reference chains from one object to
86
+
another by querying a database produced by the Analyzer (a data dependency rather than a code one).
87
+
88
+
**Base libraries**
89
+
* UnityFileSystem: a .NET class library, with source and binaries, that wraps the native
90
+
`UnityFileSystemApi` to mount Unity Archives and read SerializedFiles.
91
+
* UnityBinaryFormat: C# parsers and helpers for reading data out of Unity Archives and SerializedFiles.
92
+
* UnityDataModels: shared C# models for the reading JSON format files produced by the build (Addressables BuildLayout.json, Content Directory ContentLayout.json).
93
+
94
+
## Purpose of UnityFileSystemApi
95
+
96
+
UnityFileSystemApi is compiled from the Unity source code and exposes the core functionality to open and read the Unity Archive and Serialized File formats, exposed as a flexible, performant library. It exposes ability to navigates the TypeTrees inside a SerializedFile so objects can be read generically, without hardcoded type knowledge.
97
+
98
+
It enables custom tools for binary2text-like output and efficient SQLite database generation.
99
+
100
+
### Tests and test data
101
+
102
+
The automated tests are not shown in the diagram above. Each library has its own test project, and the
103
+
shared test data doubles as convenient sample content for ad hoc use of the tool.
104
+
105
+
* TestCommon: a helper library whose `Data/` folder holds small reference files extracted from real
106
+
Unity builds (Player, AssetBundles, content directory etc). These back the automated tests and are also handy for trying out the tool by hand.
107
+
* Analyzer.Tests, UnityDataTool.Tests, UnityFileSystem.Tests: the per-library test suites.
108
+
* UnityProjects: two Unity projects (`Baseline` and `LeadingEdge`) used to regenerate some of the test
109
+
data as Unity evolves.
53
110
54
111
## Downloads
55
112
@@ -63,7 +120,7 @@ Refer to the [commit history](https://github.com/Unity-Technologies/UnityDataToo
63
120
64
121
## Getting UnityFileSystemApi
65
122
66
-
UnityDataTool uses the native`UnityFileSystemApi` library to read Unity Archives and SerializedFiles. **Normally you don't need to do anything with this library.** The repository already includes a recent Windows, Mac, and Linux copy in the [`UnityFileSystem/`](https://github.com/Unity-Technologies/UnityDataTools/tree/main/UnityFileSystem) directory, and using that bundled copy is the recommended way to run the tool.
123
+
UnityDataTool uses the pre-compiled`UnityFileSystemApi` library to read Unity Archives and SerializedFiles. **Normally you don't need to do anything with this library.** The repository already includes a recent Windows, Mac, and Linux copy in the [`UnityFileSystem/`](https://github.com/Unity-Technologies/UnityDataTools/tree/main/UnityFileSystem) directory, and using that bundled copy is the recommended way to run the tool.
67
124
68
125
The library is backward compatible but not forward compatible: a given version can read content from the same or older Unity versions, but may be unable to read content produced by a newer Unity Editor than the library itself. The bundled copy is updated periodically as Unity evolves, so in practice it can read content from just about any Unity version.
69
126
@@ -84,10 +141,6 @@ On Windows, the executable is written to `UnityDataTool\bin\Release\net9.0`. Add
84
141
85
142
See the [command-line tool documentation](./Documentation/unitydatatool.md) for usage instructions.
86
143
87
-
## Purpose of UnityFileSystemApi
88
-
89
-
UnityFileSystemApi exposes the core functionality of WebExtract and binary2text to open and read the Unity Archive and Serialized File formats, exposed as a flexible, performant library. It enables custom tools for binary2text-like output and efficient SQLite database generation.
90
-
91
144
## Origins
92
145
93
146
This tool is the evolution of the [AssetBundle Analyzer](https://github.com/faelenor/asset-bundle-analyzer)
0 commit comments