-
Notifications
You must be signed in to change notification settings - Fork 38
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Bank changes are ignored in Addressables Content Update #48
Comments
Our team is currently experimenting with FMOD and Addressables for mobile games, and this issue sounds critical since it will break the sound asset update flow. @jungsooPark-dev , have you found any workarounds? Any temporary fixes or code snippets would be greatly appreciated. |
@phanphantz You can just comment out BuildStatusWatcher.OnBuildEnded += () => {
- UpdateBankStubAssets(EditorUserBuildSettings.activeBuildTarget);
+ //UpdateBankStubAssets(EditorUserBuildSettings.activeBuildTarget);
}; and call it manually in your code, after var result = ContentUpdateScript.BuildContentUpdate(settings, contentStateDataPath);
Debug.Log($"[Build Update] Addressable Assets UpdateTime: result.Duration}");
EventManager.UpdateBankStubAssets(EditorUserBuildSettings.activeBuildTarget); |
@jungsooPark-dev Much appreciated! I tried using your solution to build a content update for the Local Asset Group that has a modified bank inside, but unfortunately, it's still not working for me. The hash doesn't change when I perform an update build. Have you had success with Local Asset Group, or am I missing something? Another thing to mention is the issue does not happen with Remote Asset Group that is hosted on the CDN. (We use Unity CCD) |
When using Addressables with FMOD for Unity, there is a feature that automatically executes
EventManager.CopyToStreamingAssets
andEventManager.UpdateBankStubAssets
using Scriptable Build Pipeline PostDependencyCallback and PostWritingCallback. However, this causes issues when utilizing Addressables' Content Update feature.To use the Content Update feature, the hash values of all individual entries going into Addressables are recorded in the
addressables_content_state.bin
file. However, referring to the BuildScriptPackedMode.cs script, the action of recording hash values occurs after the AssetBundle build. After the AssetBundle build is complete, FMOD automatically callsEventManager.UpdateBankStubAssets
through PostWritingCallback. As a result, the hashes recorded in theaddressables_content_state.bin
file are all hashes of Stub Assets. Therefore, it becomes impossible to record the hash value of the FMOD Bank, and any changes to the FMOD Bank are omitted from all content updates.To address this issue most simply, it would be preferable to make the automatic functionalities of EventManager.CopyToStreamingAssets and EventManager.UpdateBankStubAssets using Scriptable Build Pipeline optional. Currently, when using Addressables and FMOD simultaneously while trying to utilize the Content Update feature, it is inconvenient as it requires modifying scripts within FMOD for Unity.
The text was updated successfully, but these errors were encountered: