2
0
mirror of https://github.com/AxioDL/metaforce.git synced 2025-12-10 05:07:43 +00:00

Cook path directories properly created

This commit is contained in:
Jack Andersen
2016-03-31 08:56:43 -10:00
parent d5ff5e3ace
commit 372e11e190
5 changed files with 15 additions and 19 deletions

View File

@@ -85,11 +85,10 @@ struct CMDL
const hecl::ProjectPath& inPath,
const DNACMDL::Mesh& mesh)
{
hecl::ProjectPath tempOut = outPath.getWithExtension(_S(".recook"));
if (mesh.skins.size())
{
DNACMDL::Mesh skinMesh = mesh.getContiguousSkinningVersion();
if (!DNACMDL::WriteCMDL<MaterialSet, DNACMDL::SurfaceHeader_1, 2>(tempOut, inPath, skinMesh))
if (!DNACMDL::WriteCMDL<MaterialSet, DNACMDL::SurfaceHeader_1, 2>(outPath, inPath, skinMesh))
return false;
/* Output skinning intermediate */
@@ -111,7 +110,7 @@ struct CMDL
for (const std::string& boneName : skinMesh.boneNames)
writer.writeString(boneName);
}
else if (!DNACMDL::WriteCMDL<MaterialSet, DNACMDL::SurfaceHeader_1, 2>(tempOut, inPath, mesh))
else if (!DNACMDL::WriteCMDL<MaterialSet, DNACMDL::SurfaceHeader_1, 2>(outPath, inPath, mesh))
return false;
return true;
}
@@ -120,10 +119,9 @@ struct CMDL
const hecl::ProjectPath& inPath,
const DNACMDL::Mesh& mesh)
{
hecl::ProjectPath tempOut = outPath.getWithExtension(_S(".recook"));
if (mesh.skins.size())
{
if (!DNACMDL::WriteHMDLCMDL<HMDLMaterialSet, DNACMDL::SurfaceHeader_1, 2>(tempOut, inPath, mesh))
if (!DNACMDL::WriteHMDLCMDL<HMDLMaterialSet, DNACMDL::SurfaceHeader_1, 2>(outPath, inPath, mesh))
return false;
/* Output skinning intermediate */
@@ -139,7 +137,7 @@ struct CMDL
for (const std::string& boneName : mesh.boneNames)
writer.writeString(boneName);
}
else if (!DNACMDL::WriteHMDLCMDL<HMDLMaterialSet, DNACMDL::SurfaceHeader_1, 2>(tempOut, inPath, mesh))
else if (!DNACMDL::WriteHMDLCMDL<HMDLMaterialSet, DNACMDL::SurfaceHeader_1, 2>(outPath, inPath, mesh))
return false;
return true;
}