Hi,
I have modify my build.cs to add some librairies and includes to my project and now i have this error : 'The game module ‘myProjet’ could not be loaded. I can’t find the solution please help me.
using System.IO;
using UnrealBuildTool;
public class CurubiShowroomv01 : ModuleRules
{
public CurubiShowroomv01(TargetInfo Target)
{
PublicDependencyModuleNames.AddRange(new string[] { "Core", "CoreUObject", "Engine", "InputCore", "UMG", "Slate", "SlateCore" });
}
private string ModulePath
{
get
{
RulesAssembly r;
FileReference CheckProjectFile;
UProjectInfo.TryGetProjectForTarget("CurubiShowroomv01", out CheckProjectFile);
r = RulesCompiler.CreateProjectRulesAssembly(CheckProjectFile);
FileReference f = r.GetModuleFileName(this.GetType().Name);
//File.WriteAllText("c:/temp/qqq2.txt", f.CanonicalName );
string ModulePath = Path.GetDirectoryName(f.CanonicalName);
return ModulePath;
}
}
private string ThirdPartyPath
{
get { return Path.GetFullPath(Path.Combine(ModulePath, "../../ThirdParty/")); }
}
public bool LoadMySql(TargetInfo Target)
{
bool isLibrarySupported = false;
if ((Target.Platform == UnrealTargetPlatform.Win64) || (Target.Platform == UnrealTargetPlatform.Win32))
{
isLibrarySupported = true;
string PlatformString = (Target.Platform == UnrealTargetPlatform.Win64) ? "x64" : "x86";
string LibrariesPath = Path.Combine(ThirdPartyPath, "MySql", "Libraries");
PublicAdditionalLibraries.Add(Path.Combine(LibrariesPath, "libmysql.lib"));
PublicAdditionalLibraries.Add(Path.Combine(LibrariesPath, "mysqlclient.lib"));
}
if (isLibrarySupported)
{
// Include path
PublicIncludePaths.Add(Path.Combine(ThirdPartyPath, "MySql", "Includes"));
}
Definitions.Add(string.Format("WITH_My_Sql_BINDING={0}", isLibrarySupported ? 1 : 0));
return isLibrarySupported;
}
}
Thanks.