Closed loukylor closed 1 month ago
When opening the editor tool it hangs.
looking at the code it is trying to read every single file in the Application.dataPath. I am not sure why it is looking there.
Applidation.dataPath points to the BasSDK\Assets
folder in the project.
I've got lots of assets and stuff in my SDK project, so it searching through every file to find any json files is very inefficient
We keep all of the CatalogDatas in BasSDK\BuildStaging\Catalogs
anyway.
I would recommending looking at our existing tool for loading the CatalogDatas under ThunderRoad (SDK)/Load All JSON
. You can just call that to load all the json, then you can read the Categories and the data in the catalog in the Catalog.data
I've changed it to grab and save files to BuildStaging/Mods
rather than Assets
, and optimized rendering performance when handling a lot of files as per our discussion on Discord. However, I still insist on deserializing and loading files using my own implementation due to the merging issue I brought up. I understand this is unideal, but will work.
Adds an editor that allows the user to edit catalog files that aren't in the![image](https://github.com/KospY/BasSDK/assets/46853114/a38fc2b3-867e-4441-94ac-f6eee2bfb764)
BuildStaging
folder using a nice UI. Most importantly, it doesn't rely on Odin Editor and uses Unity UI methods only.A few data classes needed the
SerializeReference
andSerializable
attributes added, however they are only needed in editor and a preprocessor command was included to make sure they aren't compiled out of editor.