Previous builds of my game were around 200MB. While I did some work on it since last build, I also updated some packages in the package manager and now my build size is almost 600MB. I can see from Editor Logs that more than half of that size are fonts and images from Unity packages that I never used in any scene and as far as I know are only for in-Editor use. Specifically:
255+ MBs of fonts from Packages/com.unity.dt.app-ui/PackageResources/Fonts/
100+ MBs of images from Packages/com.unity.muse.behavior/Runtime/UI/AssetEditor/Resources/Images/
I had muse installed for a while now hoping to make use of it sometime. I thought it was supposed to work only in Editor, why is it putting so many assets into my build? Iām pretty sure it did not do that on the previous Muse versions, only after I updated it today.
I already have āManaged stripping levelā set to High.
Any way I can keep those packages installed and keep them from influencing my build size?
I uninstalled Muse package, which automatically uninstalled com.unity.dt.app-ui and now my build is back to 200MBs
Size according to the build report in the log? That is giving you false information because the sizes are uncompressed. Double check with the folder size where you create the build, excluding any ādontdistributeā subfolders or leftovers from previous builds.
Also make these assessments with a release/master build. Debug builds will always be bigger.
It is a release build with no ādont distributeā stuff. I counted fonts and images from Editor Log, but build final folder size does differ by 400MBs. From what I can see it impacts ā_Data/resources.assetsā, ā_Data/resources.assets.resSā files and those are supposed to be shipped.
I think this merits a bug report, see Bug Reporter in Help menu. Particularly the use of the Resources folder for runtime, anything in Resources is going to end up in the build, whether itās used or not. That may be unintentional.
Iām the lead engineer on Muse Behavior. Weāre aware of the problem and itās on our list to fix it, hopefully in May! We have a lot of things coming up this month and I really hope we can remove all the Resource folder and assets without breaking anything for May
Iām really sorry for the pain itās causing you.
Edit: A bit of explanation: Our tool can actually be used at runtime, and itās used in various apps / games, including Struckd to allow editing game logic in the game. This is why we have the Resource folders. That said, we need to change this so it doesnāt affect everyone