Teammates' Unity is auto-deleting the Bank files


#1

I am working on a team of 5 people. I am the only one using FMOD Studio and I am the sole audio designer. My project is working as expected. The project is stored in Github and each of my other 4 teammates is pulling down the code through Git’s command line client. All 4 of their Unity clients deletes the StreamingAsstes/bank files. Replacing the file only results in another automatic deletion as soon as Unity gets focus. Other files inside the StreamAssets folder are not automatically deleted, so there is code somewhere that is causing this.

Unity version: 2018.2.18f1
FMOD Unity Integration version: 1.10.09
FMOD Studio version: 1.10.09


#2

This is most likely caused by the integration trying to get new banks from the Studio project, which I’m assuming they either don’t have or haven’t built the banks.

The quickest and easiest solution for this may be to do the following:

  • Change the FMOD-Unity settings to point to a single platform/folder.
  • Point it at the streaming assets folder.
  • Copy or build your banks directly into the streaming assets folder.
  • Submit the banks over Github for the others to use.

Unity CloudBuild missing banks in StreamingAssets
#3

I did the much more painful workaround of having everyone install FMOD studio locally and build the bank file each time a new sound was in the project… @cameron-fmod, your workaround seems like a nicer way to do this.

This was not an issue 3 months ago. It just worked. If the integration is forcing projects to be built locally just to use a bank file, that sounds like a bug.


#4

Sorry, I didn’t realize that there was a change in behavior.

I will do some testing and look into this further.


#5

Want me to setup a simple Unity project with the bank file in it on Github and you can just clone it down and reproduce it that way?


#6

That would be great, thank you!


#7

I tried to make an example project for you. I had my roommate test it out before sending it your way and… the integration all worked like it was supposed to. I could go back to my LD 43 project and get it back to the broken state, but I don’t even know if that is worth it at this point. I think I will just get the Fmod integration working first thing on group projects from now on. Thanks for getting back to me on this. If it happens again in Global Game Jam 2019 (late January), I will really put the time into getting the reproduction steps perfect and add it to this thread.


#8

Sounds good, in the meantime I will see if I can set some internal tests up just in case.


#9

I have a fairly simple project available now for you to see the issue first hand. Can I link you to the github here and have you clone it down on your end to see if the bank files get auto-deleted?


#10

I also found this:
Git by default ignores folders that are named “Build”. So every time I pushed, it would ignore the build folder where I had the banks.

So to make it work, in unity-fmod setting i switched to single platform build.
I renamed the builds folder into something else (DataBuild for example)
In fmod>preferences>builds i switched the directory to the new folder above.
Build one more time
Switched the directory folder in unity-fmod settings to the new folder (you have to select the folder inside the new folder)
And then pushed.
Works so far.


#11

Hey thanks for helping with the issue, @Harris894. @cameron-fmod and I continued talking over email about this issue and he cloned down my project and found the same thing you found: my project was not tracking the FMOD project’s build folder! It turns out the FMOD project’s build folder is used to refresh the bank file in the Unity StreamingAssets folder via the integration (like you said).

The solution I found was to open up my .gitignore file and remove the regex that was ignoring all folders titled “Build”. This solution allowed me to leave the FMOD Unity integration alone almost entirely!

This is a word of caution to anyone reading this: be careful about doing blanket string matches for your .gitignore! In my team’s case, the original writer of the .gitignore file didn’t want to track Unity’s build folder. He should have done a full path match instead of a blanket regex match so that the Unity build folder was explicitly targeted.