RuntimeDependencies
If you want to have the DLL copied to the same output directory as the executable at build time, you do so via an overload of the RuntimeDependencies.Add method:
RuntimeDependencies.Add("$(TargetOutputDir)/Foo.dll", Path.Combine(PluginDirectory, "Source/ThirdParty/bin/Foo.dll"));
Other variables can be used for output paths of the DLL:
$(EngineDir) | The engine directory |
$(ProjectDir) | Directory containing the project file |
$(ModuleDir) | Directory containing the .build.cs file |
$(PluginDir) | Directory containing the .uplugin file |
$(BinaryOutputDir) | Directory containing the binary that this module is compiled into (for example, the path to the DLL for editor builds, and path to the executable (EXE) for packaged builds) |
$(TargetOutputDir) | Directory containing the executable (including in editor builds) |