PathOfBuilding icon indicating copy to clipboard operation
PathOfBuilding copied to clipboard

Update tree data and asset handeling

Open Regisle opened this issue 1 year ago • 0 comments

"minor" rework to how we handle and store tree data and assets

The 4 main goals with this are to

  1. make the file structure less cluttered (this isnt entirely achieved with the folder src\TreeData\assets\non_sprite still having alot of loose files, this can be cleaned up more if desired)
  2. dedupe alot of files, this takes the file size for treeData from 258 MB to 142 MB, this is likely something that would continue being a bigger and bigger problem and this helps with that
  3. improve caching and loading of trees, this does slow down the initial load by a tiny amount, but gives over 50x as big a speedup to loading any other trees which arnt the latest tree (mostly helpful for things like ruthless or looking at old builds), this also makes it easier to reduce loading on headless by separating alot of the asset / spritesheet logic out, but likely requires them to fix issues There are many other changes that could improve this more, eg not having to redo spritesheets which are duplicates across multiple tree versions, but I have decided to limit the scope of this a bit to make it easier to merge
  4. make it easier to add new trees, this adds logic for moving and renaming of assets, making it easier to just dump the full zip file from GGG every league and more easily have it figure out correct asset files, this could still use some improvements

I have a followup PR which moves most of the logic over to use spritesheets (that were introduced in 3.19), but again I have decided to limit the scope of this a bit to make it easier to merge, and will open that PR once this is merged

Regisle avatar Sep 10 '24 05:09 Regisle