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

General resource handling bug fixes

This commit is contained in:
Jack Andersen
2017-11-14 18:12:13 -10:00
parent 8cef6ce5e0
commit 2df95c01cf
34 changed files with 114 additions and 61 deletions

View File

@@ -1132,6 +1132,21 @@ struct SpecMP1 : SpecBase
}
}
void flattenDependenciesANCSYAML(athena::io::IStreamReader& fin, std::vector<hecl::ProjectPath>& pathsOut)
{
athena::io::YAMLDocReader reader;
if (reader.parse(&fin))
{
std::string classStr = reader.readString("DNAType");
if (!classStr.compare(DNAMP1::ANCS::DNAType()))
{
DNAMP1::ANCS ancs;
ancs.read(reader);
ancs.gatherDependencies(pathsOut);
}
}
}
void buildWorldPakList(const hecl::ProjectPath& worldPath,
const hecl::ProjectPath& worldPathCooked,
hecl::BlenderToken& btok,
@@ -1168,8 +1183,13 @@ struct SpecMP1 : SpecBase
nameEnt.write(w);
for (const auto& area : mlvl.areas)
{
urde::SObjectTag nameTag(FOURCC('STRG'), area.areaNameId.toUint32());
if (nameTag)
listOut.push_back(nameTag);
for (const auto& dep : area.deps)
listOut.push_back({dep.type, dep.id.toUint32()});
}
urde::SObjectTag nameTag(FOURCC('STRG'), mlvl.worldNameId.toUint32());
if (nameTag)