Godot Xocde -AddInstanceForFactory: No factory registered for id

I am woking through the Godot for mobile course. So far everything has worked as expected. I am now trying to export to Xcode and run on my iPhone and when the game starts to run it crashs and the following errors are in Xcode.

AddInstanceForFactory: No factory registered for id <CFUUID 0x60000027a500> F8BB1C28-BAE8-11D6-9C31-00039315CD46

ERROR: AudioOutputUnitStart failed, code: -50
at: start (drivers/coreaudio/audio_driver_coreaudio.cpp:251)

It appears to be audio related. Some Googling is referencing the AVFoundation framework, but I don’t have enough experience with Xcode to track down if that is an issue.

This is happening on a Macbook Air with the M2 processor.

I did some digging and it looks like there is a strong chance there’s no clean solution for this, not least because most of the Engine Contributors have no access to Mac hardware. I also don’t have any Mac stuff, and I was able to find out that this problem may or may not show up on an emulator. As a direct result of that, there isn’t realistically anything I can do to try things on my end. That said, there are a few things I found that might be useful:

  • First of all, the problem is very likely to be completely independent of any actual use of audio in your project (users have submitted min-repro projects that were basically empty). I say “very likely” because there have been several issues identified that result in this error (some have been fixed and some haven’t), and not all of them had a dedicated min-repro project associated with them.
  • Ensure you are using Godot 4.2.2 or later, as 4.2.2 merged several PRs that fix similar audio-related issues on iOS. In the process of testing other bugs in the past, I’ve upgraded my copy of the repo project to 4.3 and didn’t notice any migration problems so far.
  • Set Project Settings–>General–>Audio–>General–>iOS–>Session Category to Playback (you could also try Play and Record, but I wouldn’t expect this to make a difference if Playback doesn’t work). You must tick Advanced Settings to see this.
  • Although I didn’t find anything suggesting this since the setting is disabled by default, I would ensure that Project Settings–>General–>Audio–>Driver–>Enable Input is disabled. This is because Godot did (and as far as I was able to tell, still does) have severe issues with accepting microphone input in iOS apps.

Best of luck and let us know what happens =)

Privacy & Terms