naninovel / docs

Documentation website
https://naninovel.com/guide
77 stars 29 forks source link

Addressable resources not unloaded within bundle #159

Closed elringus closed 3 months ago

elringus commented 1 year ago

Caused by the Unity bug: https://issuetracker.unity3d.com/product/unity/issues/guid/UUM-37775

Please vote on the tracker to make it fixed as soon as possible.

Associated forum thread: https://forum.unity.com/threads/resources-unloadunusedassets-cannot-unload-assets-without-any-references.1088116/#post-8991523

Use Package Separately for a temporary workaround.

Artein commented 1 year ago

Most probably you need to update this Issue and documentation, cause the ticket was closed with "by design", and Unity updated Addressables documentation

elringus commented 1 year ago

I know, I'm in touch with them. They've already closed it twice before and then re-opened.

elringus commented 3 months ago

Looks like this won't be resolved on the Unity side any time soon, so I've added Label By Scripts option to the resource provider configuration in v1.20.

When the option is enabled (default) all the Naninovel addressable assets will be labeled by the scripts in which they’re used. Given Bundle Mode of the addressable group is set to Pack Together By Label, asset bundles will then be optimized for the project scenario structure improving load times and RAM usage.

Documentation: https://pre.naninovel.com/guide/resource-providers#script-labels