From 1f9c8811d2cba4da04cf419d3a9106e5e582d6db Mon Sep 17 00:00:00 2001 From: Jack Andersen Date: Wed, 30 Sep 2015 14:40:21 -1000 Subject: [PATCH] Work on cooking features --- DataSpec/Blender/BlenderSupport.cpp | 2 +- DataSpec/DNACommon/ANCS.hpp | 5 ++--- DataSpec/DNACommon/CMDL.hpp | 1 - DataSpec/DNAMP1/ANCS.cpp | 30 +++++++++++++++++++++++++++++ DataSpec/DNAMP1/CMDL.hpp | 2 +- DataSpec/DNAMP1/MREA.cpp | 5 ++--- DataSpec/DNAMP1/STRG.cpp | 5 +++++ DataSpec/DNAMP2/ANCS.cpp | 15 +++++++++++++++ DataSpec/DNAMP2/CMDL.hpp | 2 +- DataSpec/DNAMP2/MREA.cpp | 5 ++--- DataSpec/DNAMP2/STRG.cpp | 5 +++++ DataSpec/DNAMP3/CHAR.cpp | 10 ++++++++++ DataSpec/DNAMP3/CMDL.hpp | 6 +++--- DataSpec/DNAMP3/MREA.cpp | 5 ++--- DataSpec/DNAMP3/STRG.cpp | 5 +++++ DataSpec/SpecBase.cpp | 22 ++++++++++++++++++++- DataSpec/SpecBase.hpp | 3 ++- DataSpec/SpecMP1.cpp | 14 +++++++++++++- DataSpec/SpecMP2.cpp | 14 +++++++++++++- DataSpec/SpecMP3.cpp | 21 +++++++++++++++++--- hecl | 2 +- 21 files changed, 152 insertions(+), 27 deletions(-) diff --git a/DataSpec/Blender/BlenderSupport.cpp b/DataSpec/Blender/BlenderSupport.cpp index d930756e6..4f489ed8b 100644 --- a/DataSpec/Blender/BlenderSupport.cpp +++ b/DataSpec/Blender/BlenderSupport.cpp @@ -13,7 +13,7 @@ namespace Blender bool BuildMasterShader(const HECL::ProjectPath& path) { HECL::BlenderConnection& conn = HECL::BlenderConnection::SharedConnection(); - if (!conn.createBlend(path.getAbsolutePath())) + if (!conn.createBlend(path.getAbsolutePath(), HECL::BlenderConnection::TypeNone)) return false; { HECL::BlenderConnection::PyOutStream os = conn.beginPythonOut(true); diff --git a/DataSpec/DNACommon/ANCS.hpp b/DataSpec/DNACommon/ANCS.hpp index 2196ca75c..174b47adf 100644 --- a/DataSpec/DNACommon/ANCS.hpp +++ b/DataSpec/DNACommon/ANCS.hpp @@ -51,7 +51,7 @@ bool ReadANCSToBlender(HECL::BlenderConnection& conn, HECL::ProjectPath cmdlPath = pakRouter.getWorking(cmdlE); if (force || cmdlPath.getPathType() == HECL::ProjectPath::PT_NONE) { - if (!conn.createBlend(cmdlPath.getAbsolutePath())) + if (!conn.createBlend(cmdlPath.getAbsolutePath(), HECL::BlenderConnection::TypeMesh)) return false; HECL::SystemStringView bestNameView(pakRouter.getBestEntryName(*cmdlE)); @@ -77,14 +77,13 @@ bool ReadANCSToBlender(HECL::BlenderConnection& conn, fileChanged(bestNameView.sys_str().c_str()); /* Establish ANCS blend */ - if (!conn.createBlend(outPath.getAbsolutePath())) + if (!conn.createBlend(outPath.getAbsolutePath(), HECL::BlenderConnection::TypeActor)) return false; HECL::BlenderConnection::PyOutStream os = conn.beginPythonOut(true); os.format("import bpy\n" "from mathutils import Vector\n" "bpy.context.scene.name = '%s'\n" - "bpy.context.scene.hecl_type = 'ACTOR'\n" "bpy.context.scene.hecl_mesh_obj = bpy.context.scene.name\n" "\n" "# Using 'Blender Game'\n" diff --git a/DataSpec/DNACommon/CMDL.hpp b/DataSpec/DNACommon/CMDL.hpp index b8c106c63..b4bfc4e4b 100644 --- a/DataSpec/DNACommon/CMDL.hpp +++ b/DataSpec/DNACommon/CMDL.hpp @@ -1001,7 +1001,6 @@ bool ReadCMDLToBlender(HECL::BlenderConnection& conn, "import bmesh\n" "\n" "bpy.context.scene.name = '%s'\n" - "bpy.context.scene.hecl_type = 'MESH'\n" "bpy.context.scene.hecl_mesh_obj = bpy.context.scene.name\n", pakRouter.getBestEntryName(entry).c_str()); InitGeomBlenderContext(os, dataspec.getMasterShaderPath()); diff --git a/DataSpec/DNAMP1/ANCS.cpp b/DataSpec/DNAMP1/ANCS.cpp index ada97289d..5e9fd49f5 100644 --- a/DataSpec/DNAMP1/ANCS.cpp +++ b/DataSpec/DNAMP1/ANCS.cpp @@ -118,6 +118,11 @@ void ANCS::CharacterSet::CharacterInfo::PASDatabase::AnimState::ParmInfo::toYAML writer.leaveSubVector(); } +const char* ANCS::CharacterSet::CharacterInfo::PASDatabase::AnimState::ParmInfo::DNAType() +{ + return "Retro::DNAMP1::ANCS::CharacterSet::CharacterInfo::PASDatabase::AnimState::ParmInfo"; +} + void ANCS::CharacterSet::CharacterInfo::PASDatabase::AnimState::read(Athena::io::IStreamReader& reader) { id = reader.readUint32Big(); @@ -274,6 +279,11 @@ void ANCS::CharacterSet::CharacterInfo::PASDatabase::AnimState::toYAML(Athena::i }); } +const char* ANCS::CharacterSet::CharacterInfo::PASDatabase::AnimState::DNAType() +{ + return "Retro::DNAMP1::ANCS::CharacterSet::CharacterInfo::PASDatabase::AnimState"; +} + void ANCS::CharacterSet::CharacterInfo::read(Athena::io::IStreamReader& reader) { idx = reader.readUint32Big(); @@ -537,6 +547,11 @@ void ANCS::CharacterSet::CharacterInfo::toYAML(Athena::io::YAMLDocWriter& writer } } +const char* ANCS::CharacterSet::CharacterInfo::DNAType() +{ + return "Retro::DNAMP1::ANCS::CharacterSet::CharacterInfo"; +} + void ANCS::AnimationSet::MetaAnimFactory::read(Athena::io::IStreamReader& reader) { IMetaAnim::Type type(IMetaAnim::Type(reader.readUint32Big())); @@ -620,6 +635,11 @@ void ANCS::AnimationSet::MetaAnimFactory::toYAML(Athena::io::YAMLDocWriter& writ m_anim->toYAML(writer); } +const char* ANCS::AnimationSet::MetaAnimFactory::DNAType() +{ + return "Retro::DNAMP1::ANCS::AnimationSet::MetaAnimFactory"; +} + void ANCS::AnimationSet::MetaTransFactory::read(Athena::io::IStreamReader& reader) { IMetaTrans::Type type(IMetaTrans::Type(reader.readUint32Big())); @@ -692,6 +712,11 @@ void ANCS::AnimationSet::MetaTransFactory::toYAML(Athena::io::YAMLDocWriter& wri m_trans->toYAML(writer); } +const char* ANCS::AnimationSet::MetaTransFactory::DNAType() +{ + return "Retro::DNAMP1::ANCS::AnimationSet::MetaTransFactory"; +} + void ANCS::AnimationSet::read(Athena::io::IStreamReader& reader) { atUint16 sectionCount = reader.readUint16Big(); @@ -846,6 +871,11 @@ void ANCS::AnimationSet::toYAML(Athena::io::YAMLDocWriter& writer) const } } +const char* ANCS::AnimationSet::DNAType() +{ + return "Retro::DNAMP1::ANCS::AnimationSet"; +} + } } diff --git a/DataSpec/DNAMP1/CMDL.hpp b/DataSpec/DNAMP1/CMDL.hpp index 7129c71ea..d0189486b 100644 --- a/DataSpec/DNAMP1/CMDL.hpp +++ b/DataSpec/DNAMP1/CMDL.hpp @@ -38,7 +38,7 @@ struct CMDL /* Do extract */ HECL::BlenderConnection& conn = HECL::BlenderConnection::SharedConnection(); - if (!conn.createBlend(outPath.getAbsolutePath())) + if (!conn.createBlend(outPath.getAbsolutePath(), HECL::BlenderConnection::TypeMesh)) return false; DNACMDL::ReadCMDLToBlender, MaterialSet, std::pair, DNACMDL::SurfaceHeader_1_2, 2> (conn, rs, pakRouter, entry, dataSpec, loadRp); diff --git a/DataSpec/DNAMP1/MREA.cpp b/DataSpec/DNAMP1/MREA.cpp index 8ce2b0669..f849ce49c 100644 --- a/DataSpec/DNAMP1/MREA.cpp +++ b/DataSpec/DNAMP1/MREA.cpp @@ -49,7 +49,7 @@ bool MREA::Extract(const SpecBase& dataSpec, rs.seekAlign32(); HECL::BlenderConnection& conn = HECL::BlenderConnection::SharedConnection(); - if (!conn.createBlend(outPath.getAbsolutePath())) + if (!conn.createBlend(outPath.getAbsolutePath(), HECL::BlenderConnection::TypeArea)) return false; /* Open Py Stream and read sections */ @@ -58,8 +58,7 @@ bool MREA::Extract(const SpecBase& dataSpec, "import bmesh\n" "from mathutils import Vector\n" "\n" - "bpy.context.scene.name = '%s'\n" - "bpy.context.scene.hecl_type = 'AREA'\n", + "bpy.context.scene.name = '%s'\n", pakRouter.getBestEntryName(entry).c_str()); DNACMDL::InitGeomBlenderContext(os, dataSpec.getMasterShaderPath()); MaterialSet::RegisterMaterialProps(os); diff --git a/DataSpec/DNAMP1/STRG.cpp b/DataSpec/DNAMP1/STRG.cpp index ddfb3b547..42931c9c7 100644 --- a/DataSpec/DNAMP1/STRG.cpp +++ b/DataSpec/DNAMP1/STRG.cpp @@ -171,5 +171,10 @@ void STRG::toYAML(Athena::io::YAMLDocWriter& writer) const } } +const char* STRG::DNAType() +{ + return "Retro::DNAMP1::STRG"; +} + } } diff --git a/DataSpec/DNAMP2/ANCS.cpp b/DataSpec/DNAMP2/ANCS.cpp index 37af24775..c98871145 100644 --- a/DataSpec/DNAMP2/ANCS.cpp +++ b/DataSpec/DNAMP2/ANCS.cpp @@ -318,6 +318,11 @@ void ANCS::CharacterSet::CharacterInfo::toYAML(Athena::io::YAMLDocWriter& writer } } +const char* ANCS::CharacterSet::CharacterInfo::DNAType() +{ + return "Retro::DNAMP2::ANCS::CharacterSet::CharacterInfo"; +} + void ANCS::AnimationSet::read(Athena::io::IStreamReader& reader) { atUint16 sectionCount = reader.readUint16Big(); @@ -472,6 +477,11 @@ void ANCS::AnimationSet::toYAML(Athena::io::YAMLDocWriter& writer) const } } +const char* ANCS::AnimationSet::DNAType() +{ + return "Retro::DNAMP2::ANCS::AnimationSet"; +} + void ANCS::AnimationSet::EVNT::read(Athena::io::IStreamReader& reader) { version = reader.readUint32Big(); @@ -554,5 +564,10 @@ void ANCS::AnimationSet::EVNT::toYAML(Athena::io::YAMLDocWriter& writer) const writer.enumerate("sfxEvents", sfxEvents); } +const char* ANCS::AnimationSet::EVNT::DNAType() +{ + return "Retro::DNAMP2::ANCS::AnimationSet::EVNT"; +} + } } diff --git a/DataSpec/DNAMP2/CMDL.hpp b/DataSpec/DNAMP2/CMDL.hpp index 47c0d05cd..39f6d1aad 100644 --- a/DataSpec/DNAMP2/CMDL.hpp +++ b/DataSpec/DNAMP2/CMDL.hpp @@ -38,7 +38,7 @@ struct CMDL /* Do extract */ HECL::BlenderConnection& conn = HECL::BlenderConnection::SharedConnection(); - if (!conn.createBlend(outPath.getAbsolutePath())) + if (!conn.createBlend(outPath.getAbsolutePath(), HECL::BlenderConnection::TypeMesh)) return false; DNACMDL::ReadCMDLToBlender, MaterialSet, std::pair, DNACMDL::SurfaceHeader_1_2, 4> (conn, rs, pakRouter, entry, dataSpec, loadRp); diff --git a/DataSpec/DNAMP2/MREA.cpp b/DataSpec/DNAMP2/MREA.cpp index 911d5c605..be97454cb 100644 --- a/DataSpec/DNAMP2/MREA.cpp +++ b/DataSpec/DNAMP2/MREA.cpp @@ -186,7 +186,7 @@ bool MREA::Extract(const SpecBase& dataSpec, /* Start up blender connection */ HECL::BlenderConnection& conn = HECL::BlenderConnection::SharedConnection(); - if (!conn.createBlend(outPath.getAbsolutePath())) + if (!conn.createBlend(outPath.getAbsolutePath(), HECL::BlenderConnection::TypeArea)) return false; /* Open Py Stream and read sections */ @@ -195,8 +195,7 @@ bool MREA::Extract(const SpecBase& dataSpec, "import bmesh\n" "from mathutils import Vector\n" "\n" - "bpy.context.scene.name = '%s'\n" - "bpy.context.scene.hecl_type = 'AREA'\n", + "bpy.context.scene.name = '%s'\n", pakRouter.getBestEntryName(entry).c_str()); DNACMDL::InitGeomBlenderContext(os, dataSpec.getMasterShaderPath()); MaterialSet::RegisterMaterialProps(os); diff --git a/DataSpec/DNAMP2/STRG.cpp b/DataSpec/DNAMP2/STRG.cpp index e2723b90c..20899763a 100644 --- a/DataSpec/DNAMP2/STRG.cpp +++ b/DataSpec/DNAMP2/STRG.cpp @@ -218,5 +218,10 @@ void STRG::toYAML(Athena::io::YAMLDocWriter& writer) const } } +const char* STRG::DNAType() +{ + return "Retro::DNAMP2::STRG"; +} + } } diff --git a/DataSpec/DNAMP3/CHAR.cpp b/DataSpec/DNAMP3/CHAR.cpp index 4b7986b50..224221735 100644 --- a/DataSpec/DNAMP3/CHAR.cpp +++ b/DataSpec/DNAMP3/CHAR.cpp @@ -61,6 +61,11 @@ void CHAR::AnimationInfo::EVNT::SFXEvent::toYAML(Athena::io::YAMLDocWriter& writ writer.writeFloat("extraFloat", extraFloat); } +const char* CHAR::AnimationInfo::EVNT::SFXEvent::DNAType() +{ + return "Retro::DNAMP3::CHAR::AnimationInfo::EVNT::SFXEvent"; +} + void CHAR::AnimationInfo::MetaAnimFactory::read(Athena::io::IStreamReader& reader) { IMetaAnim::Type type(IMetaAnim::Type(reader.readUint32Big())); @@ -144,5 +149,10 @@ void CHAR::AnimationInfo::MetaAnimFactory::toYAML(Athena::io::YAMLDocWriter& wri m_anim->toYAML(writer); } +const char* CHAR::AnimationInfo::MetaAnimFactory::DNAType() +{ + return "Retro::DNAMP3::CHAR::AnimationInfo::MetaAnimFactory"; +} + } } diff --git a/DataSpec/DNAMP3/CMDL.hpp b/DataSpec/DNAMP3/CMDL.hpp index 56edce37b..0203d7eeb 100644 --- a/DataSpec/DNAMP3/CMDL.hpp +++ b/DataSpec/DNAMP3/CMDL.hpp @@ -20,8 +20,8 @@ struct CMDL const HECL::ProjectPath& outPath, PAKRouter& pakRouter, const PAK::Entry& entry, - bool force, - std::function fileChanged) + bool, + std::function) { /* Check for RigPair */ const PAKRouter::RigPair* rp = pakRouter.lookupCMDLRigPair(entry.id); @@ -38,7 +38,7 @@ struct CMDL /* Do extract */ HECL::BlenderConnection& conn = HECL::BlenderConnection::SharedConnection(); - if (!conn.createBlend(outPath.getAbsolutePath())) + if (!conn.createBlend(outPath.getAbsolutePath(), HECL::BlenderConnection::TypeMesh)) return false; DNACMDL::ReadCMDLToBlender, MaterialSet, std::pair, DNACMDL::SurfaceHeader_3, 5> (conn, rs, pakRouter, entry, dataSpec, loadRp); diff --git a/DataSpec/DNAMP3/MREA.cpp b/DataSpec/DNAMP3/MREA.cpp index e69915994..41fb1bf24 100644 --- a/DataSpec/DNAMP3/MREA.cpp +++ b/DataSpec/DNAMP3/MREA.cpp @@ -99,7 +99,7 @@ bool MREA::Extract(const SpecBase& dataSpec, /* Start up blender connection */ HECL::BlenderConnection& conn = HECL::BlenderConnection::SharedConnection(); - if (!conn.createBlend(outPath.getAbsolutePath())) + if (!conn.createBlend(outPath.getAbsolutePath(), HECL::BlenderConnection::TypeArea)) return false; /* Open Py Stream and read sections */ @@ -108,8 +108,7 @@ bool MREA::Extract(const SpecBase& dataSpec, "import bmesh\n" "from mathutils import Vector\n" "\n" - "bpy.context.scene.name = '%s'\n" - "bpy.context.scene.hecl_type = 'AREA'\n", + "bpy.context.scene.name = '%s'\n", pakRouter.getBestEntryName(entry).c_str()); DNACMDL::InitGeomBlenderContext(os, dataSpec.getMasterShaderPath()); MaterialSet::RegisterMaterialProps(os); diff --git a/DataSpec/DNAMP3/STRG.cpp b/DataSpec/DNAMP3/STRG.cpp index e0c6b91c9..61b6c69eb 100644 --- a/DataSpec/DNAMP3/STRG.cpp +++ b/DataSpec/DNAMP3/STRG.cpp @@ -234,5 +234,10 @@ void STRG::toYAML(Athena::io::YAMLDocWriter& writer) const } } +const char* STRG::DNAType() +{ + return "Retro::DNAMP3::STRG"; +} + } } diff --git a/DataSpec/SpecBase.cpp b/DataSpec/SpecBase.cpp index b4b7f8d53..562bc335b 100644 --- a/DataSpec/SpecBase.cpp +++ b/DataSpec/SpecBase.cpp @@ -1,5 +1,6 @@ #include "SpecBase.hpp" #include "Blender/BlenderSupport.hpp" +#include "BlenderConnection.hpp" namespace Retro { @@ -52,7 +53,7 @@ void SpecBase::doExtract(const ExtractPassInfo& info, FProgress progress) if (m_isWii) { /* Extract update partition for repacking later */ - const HECL::SystemString& target = m_project.getProjectRootPath().getAbsolutePath(); + const HECL::SystemString& target = m_project.getProjectWorkingPath().getAbsolutePath(); NOD::DiscBase::IPartition* update = m_disc->getUpdatePartition(); NOD::ExtractionContext ctx = {true, info.force, nullptr}; @@ -87,6 +88,25 @@ void SpecBase::doExtract(const ExtractPassInfo& info, FProgress progress) bool SpecBase::canCook(const HECL::ProjectPath& path) { + if (HECL::IsPathBlend(path)) + { + HECL::BlenderConnection& conn = HECL::BlenderConnection::SharedConnection(); + if (!conn.openBlend(path.getAbsolutePath())) + return false; + if (conn.getBlendType() != HECL::BlenderConnection::TypeNone) + return true; + } + else if (HECL::IsPathPNG(path)) + { + return true; + } + else if (HECL::IsPathYAML(path)) + { + FILE* fp = HECL::Fopen(path.getAbsolutePath().c_str(), _S("r")); + bool retval = validateYAMLDNAType(fp); + fclose(fp); + return retval; + } return false; } diff --git a/DataSpec/SpecBase.hpp b/DataSpec/SpecBase.hpp index 49d865ebe..d73bab4f0 100644 --- a/DataSpec/SpecBase.hpp +++ b/DataSpec/SpecBase.hpp @@ -34,12 +34,13 @@ struct SpecBase : HECL::Database::IDataSpec virtual bool extractFromDisc(NOD::DiscBase& disc, bool force, FProgress progress)=0; + virtual bool validateYAMLDNAType(FILE* fp) const=0; const HECL::ProjectPath& getMasterShaderPath() const {return m_masterShader;} SpecBase(HECL::Database::Project& project) : m_project(project), - m_masterShader(project.getProjectRootPath(), ".hecl/RetroMasterShader.blend") {} + m_masterShader(project.getProjectWorkingPath(), ".hecl/RetroMasterShader.blend") {} protected: HECL::Database::Project& m_project; HECL::ProjectPath m_masterShader; diff --git a/DataSpec/SpecMP1.cpp b/DataSpec/SpecMP1.cpp index a9a8bb971..37ee72144 100644 --- a/DataSpec/SpecMP1.cpp +++ b/DataSpec/SpecMP1.cpp @@ -5,6 +5,9 @@ #include "SpecBase.hpp" #include "DNAMP1/DNAMP1.hpp" +#include "DNAMP1/MLVL.hpp" +#include "DNAMP1/STRG.hpp" + namespace Retro { @@ -30,7 +33,7 @@ struct SpecMP1 : SpecBase SpecMP1(HECL::Database::Project& project) : SpecBase(project), - m_workPath(project.getProjectRootPath(), _S("MP1")), + m_workPath(project.getProjectWorkingPath(), _S("MP1")), m_cookPath(project.getProjectCookedPath(SpecEntMP1), _S("MP1")), m_pakRouter(*this, m_workPath, m_cookPath) {} @@ -259,6 +262,15 @@ struct SpecMP1 : SpecBase return true; } + + bool validateYAMLDNAType(FILE* fp) const + { + if (BigYAML::ValidateFromYAMLFile(fp)) + return true; + if (BigYAML::ValidateFromYAMLFile(fp)) + return true; + return false; + } }; HECL::Database::DataSpecEntry SpecEntMP1 = diff --git a/DataSpec/SpecMP2.cpp b/DataSpec/SpecMP2.cpp index fb6596f8b..a0ad30469 100644 --- a/DataSpec/SpecMP2.cpp +++ b/DataSpec/SpecMP2.cpp @@ -3,6 +3,9 @@ #include "SpecBase.hpp" #include "DNAMP2/DNAMP2.hpp" +#include "DNAMP2/MLVL.hpp" +#include "DNAMP2/STRG.hpp" + namespace Retro { @@ -28,7 +31,7 @@ struct SpecMP2 : SpecBase SpecMP2(HECL::Database::Project& project) : SpecBase(project), - m_workPath(project.getProjectRootPath(), _S("MP2")), + m_workPath(project.getProjectWorkingPath(), _S("MP2")), m_cookPath(project.getProjectCookedPath(SpecEntMP2), _S("MP2")), m_pakRouter(*this, m_workPath, m_cookPath) {} @@ -251,6 +254,15 @@ struct SpecMP2 : SpecBase return true; } + + bool validateYAMLDNAType(FILE* fp) const + { + if (BigYAML::ValidateFromYAMLFile(fp)) + return true; + if (BigYAML::ValidateFromYAMLFile(fp)) + return true; + return false; + } }; HECL::Database::DataSpecEntry SpecEntMP2 diff --git a/DataSpec/SpecMP3.cpp b/DataSpec/SpecMP3.cpp index 3b385d714..d3071ac78 100644 --- a/DataSpec/SpecMP3.cpp +++ b/DataSpec/SpecMP3.cpp @@ -4,6 +4,10 @@ #include "SpecBase.hpp" #include "DNAMP3/DNAMP3.hpp" +#include "DNAMP3/MLVL.hpp" +#include "DNAMP3/STRG.hpp" +#include "DNAMP2/STRG.hpp" + namespace Retro { @@ -40,10 +44,10 @@ struct SpecMP3 : SpecBase SpecMP3(HECL::Database::Project& project) : SpecBase(project), - m_workPath(project.getProjectRootPath(), _S("MP3")), + m_workPath(project.getProjectWorkingPath(), _S("MP3")), m_cookPath(project.getProjectCookedPath(SpecEntMP3), _S("MP3")), m_pakRouter(*this, m_workPath, m_cookPath), - m_feWorkPath(project.getProjectRootPath(), _S("fe")), + m_feWorkPath(project.getProjectWorkingPath(), _S("fe")), m_feCookPath(project.getProjectCookedPath(SpecEntMP3), _S("fe")), m_fePakRouter(*this, m_feWorkPath, m_feCookPath) {} @@ -340,7 +344,7 @@ struct SpecMP3 : SpecBase }); progress(_S("Indexing PAKs"), _S(""), compIdx++, 1.0); - HECL::ProjectPath mp3WorkPath(m_project.getProjectRootPath(), "MP3"); + HECL::ProjectPath mp3WorkPath(m_project.getProjectWorkingPath(), "MP3"); mp3WorkPath.makeDir(); currentTarget = _S("MP3 Root"); progress(currentTarget.c_str(), _S(""), compIdx, 0.0); @@ -430,6 +434,17 @@ struct SpecMP3 : SpecBase } return true; } + + bool validateYAMLDNAType(FILE* fp) const + { + if (BigYAML::ValidateFromYAMLFile(fp)) + return true; + if (BigYAML::ValidateFromYAMLFile(fp)) + return true; + if (BigYAML::ValidateFromYAMLFile(fp)) + return true; + return false; + } }; HECL::Database::DataSpecEntry SpecEntMP3 diff --git a/hecl b/hecl index aae0f7390..e8544adf4 160000 --- a/hecl +++ b/hecl @@ -1 +1 @@ -Subproject commit aae0f7390ff6a7fcf81df423a7fe66091713b7da +Subproject commit e8544adf496c1aeb2b9be212fa34cfc295e807a8