Is FMOD trying to copy banks to the wrong folder?

I can’t run my project due to the banks failing to copy over to StreamingAssets. The exact errors are at the bottom of this post. The IOException show that FMOD Studio attempted to move the banks to StreamingAssetsC: instead of StreamingAssets. Am I understanding this right? Why was “C:” added to the end of StreamingAssets, and how can I correct this?

1 Like

I have the exact same problem but on Mac, it is only happening when using Fmod 2.0 and building to a single bank.

1 Like

I found this FMOD issue that is pretty similar

So I then replaced EventManager.cs with the version here on github, and I also deleted my FMODstudioCache.asset to let it regenerate

The new script off github still did not fix my problem, though.

Make sure browse the commit history and grab all the updated files: https://github.com/fmod/UnityIntegration/commits/master

There were 3 commits related to this issue, and, if memory serves, I think 4 files were changed, not just EventManager.cs - but it did seem to solve the issue for us.

1 Like

Thanks for the recommendation, but I’ve updated all files to ones in the github repo and it hasn’t solved the issue.

Could you try also manually deleting the FMODStudioCache.asset.

I just deleted it. The issue is still there.

I’m currently debugging EventManager.cs. On the line where sourcePath is defined, I see that bankSourceFolder is the relative folder path (no Master Bank at the end), and bankRef.Name is a full system path (and Master Bank at the end). So combining these will not be a valid path.

bankRef.Name shouldn’t be the full system path (anymore), it should only be the file name plus any sub-directory.

We are very close to releasing 2.00.01, so I have uploaded the source code to Github which includes many other fixes as well.

Cool! I might be the first user trying it out right now. It’s giving me some simpler errors now.

Assets/Plugins/FMOD/src/Runtime/StudioEventEmitter.cs(7,18): error CS0509: FMODUnity.StudioEventEmitter': cannot derive from sealed typeSystem.EventHandler’

(Filename: Assets/Plugins/FMOD/src/Runtime/StudioEventEmitter.cs Line: 7)

Assets/Plugins/FMOD/src/Runtime/StudioGlobalParameterTrigger.cs(7,18): error CS0509: FMODUnity.StudioGlobalParameterTrigger': cannot derive from sealed typeSystem.EventHandler’

(Filename: Assets/Plugins/FMOD/src/Runtime/StudioGlobalParameterTrigger.cs Line: 7)

Assets/Plugins/FMOD/src/Runtime/StudioParameterTrigger.cs(14,18): error CS0509: FMODUnity.StudioParameterTrigger': cannot derive from sealed typeSystem.EventHandler’

(Filename: Assets/Plugins/FMOD/src/Runtime/StudioParameterTrigger.cs Line: 14)

Assets/Plugins/FMOD/src/Runtime/RuntimeManager.cs(466,9): error CS0246: The type or namespace name `FMODRuntimeManagerOnGUIHelper’ could not be found. Are you missing an assembly reference?

(Filename: Assets/Plugins/FMOD/src/Runtime/RuntimeManager.cs Line: 466)

Assets/Plugins/FMOD/src/Runtime/StudioEventEmitter.cs(83,33): error CS0115: `FMODUnity.StudioEventEmitter.HandleGameEvent(FMODUnity.EmitterGameEvent)’ is marked as an override but no suitable method found to override

(Filename: Assets/Plugins/FMOD/src/Runtime/StudioEventEmitter.cs Line: 83)

Assets/Plugins/FMOD/src/Runtime/StudioGlobalParameterTrigger.cs(31,33): error CS0115: `FMODUnity.StudioGlobalParameterTrigger.HandleGameEvent(FMODUnity.EmitterGameEvent)’ is marked as an override but no suitable method found to override

(Filename: Assets/Plugins/FMOD/src/Runtime/StudioGlobalParameterTrigger.cs Line: 31)

Assets/Plugins/FMOD/src/Runtime/StudioParameterTrigger.cs(39,33): error CS0115: `FMODUnity.StudioParameterTrigger.HandleGameEvent(FMODUnity.EmitterGameEvent)’ is marked as an override but no suitable method found to override

(Filename: Assets/Plugins/FMOD/src/Runtime/StudioParameterTrigger.cs Line: 39)

Whoops, sorry I was in too much of a rush and missed the new files that needed to be added. They should be in the repo now.

Thanks! I’m still getting the full system path in bankRef.Name sometimes. I mean this code in EventManager.cs is being hit two times, and the first iteration correctly contains “Master Bank.strings”. But the second time around, bankRef.Name contains the full system path and produces the same old error.

If you haven’t already, try deleting the FMODStudioCache.asset again.

How are you linking the integration to the banks? (Project, Single Platform, Multi Platform)

Not sure, but I think Multi Platform. Should I be looking in FMOD > Edit Settings?

Using ‘FMOD > Edit Settings’ will give you a nicer UI.

On a side note, I don’t think it will have any effect on the current issue:
It looks like you have the Studio Project inside your Unity projects Assets folder, normally we wouldn’t recommend this as it can bloat your Unity project. I would recommend at least moving it up a level so it is next to the Assets folder, rather than in it.

Good tip. That was a poor assumption on my part. And yes, getting it out of Assets didn’t fix anything.

I was actually able to reproduce the issue by having the project/banks inside the Assets folder, then as soon as I moved them out of there it worked again. The pathing doesn’t seem to handle that very well, but are you certain that yours still doesn’t work?

I’m certain. And I deleted FMODStudioCache.asset. Do settings seem correct?

The Source Project Path should be the full system path to the Studio project, are you inputting this manually? If you change the UI mode back to normal, you can use the browser to select the Studio project.