21 protected TargetModel? Model;
22 public string TemplateSubfolder =>
"Target";
24 public void Generate(AbsolutePath templatesPath, AbsolutePath currentFolder,
string name)
33 if(!Directory.Exists(templatesPath / TemplateSubfolder))
34 templatesPath = DefaultTemplateFolder;
36 var templateDir = templatesPath / TemplateSubfolder;
40 var srcFolder = currentFolder /
"Source";
41 Directory.CreateDirectory(srcFolder);
45 .Generate(templatesPath, srcFolder, name);
48 protected void CheckInsideSourceFolder(AbsolutePath currentFolder)
50 if(!currentFolder.ToString().Contains(
"Source", StringComparison.InvariantCultureIgnoreCase))
52 throw new InvalidOperationException(
53 $
"{currentFolder} doesn't contain a Source folder. Unreal Engine requires Module to be inside the project or plugin Source folder."