c++ Plugin fails to load on 4.14 and 4.15

I have a project that uses plugins. It compiled fine, but when I launch it in the development editor it crashes at 71% with an error that translates to “Cannot load program because computer cannot find UE4Editor-MainMenuLib.dll. Try reinstalling the program.” The next error message is “The game module ‘BugTest’ could not be loaded. There may be an operating system error or the module may not be properly set up”

The same project worked fine in 4.13. This bug appeared in 4.14 and is still active in 4.15.I tried experimenting the PluginType, LoadingPhase and other properties, but nothing worked.

How to reproduce the bug:

  1. Create a new C++ project.
  2. Copy the plugin to the “Plugins” folder, register it in the BugTest.Build.cs.
  3. Make sure the source code calls any plugin method.

I uploaded a sample project with 2 plugins: File Dropper - Online file sharing . Method that I use to test the bug is called ABugTestGameModeBase::BugDemo().

Can someone from Epic please confirm this bug?
Just launch the attached demo project from Visual Studio and you’ll see it.

The problem was with the “EnabledByDefault” plugin setting, which should be true for Unreal Engine v4.14+

Hi Da Stranger,

Sorry for the delayed response. We recently fixed an issue where the Engine was ignoring the EnabledByDefault setting in a plugin. This meant that even if this was set to false, the Engine would still always enable the plugin. Unfortunately, when we fixed this it resulted in some difficulties with plugins like the one that you mentioned. Some Engine users either assumed that plugins were being enabled implicitly when they were used, or didn’t realize that the plugins were not set to be enabled by default. Setting EnabledByDefault to true should resolve this issue.