mirror of https://github.com/AxioDL/metaforce.git
Tons of dependency gathering flow
This commit is contained in:
parent
6b97fa0242
commit
341fe2c728
|
@ -290,6 +290,15 @@ void CRSM<IDType>::write(athena::io::IStreamWriter& w) const
|
||||||
w.writeBytes("_END", 4);
|
w.writeBytes("_END", 4);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
template <class IDType>
|
||||||
|
void CRSM<IDType>::gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
for (const auto& p : x0_generators)
|
||||||
|
g_curSpec->flattenDependencies(p.second.id, pathsOut);
|
||||||
|
for (const auto& p : x20_decals)
|
||||||
|
g_curSpec->flattenDependencies(p.second.id, pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
template <class IDType>
|
template <class IDType>
|
||||||
CRSM<IDType>::CRSM()
|
CRSM<IDType>::CRSM()
|
||||||
: x30_RNGE(50.f),
|
: x30_RNGE(50.f),
|
||||||
|
|
|
@ -29,6 +29,8 @@ struct CRSM : BigYAML
|
||||||
void write(athena::io::IStreamWriter& w) const;
|
void write(athena::io::IStreamWriter& w) const;
|
||||||
|
|
||||||
CRSM();
|
CRSM();
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>&) const;
|
||||||
};
|
};
|
||||||
template <class IDType>
|
template <class IDType>
|
||||||
bool ExtractCRSM(PAKEntryReadStream& rs, const hecl::ProjectPath& outPath);
|
bool ExtractCRSM(PAKEntryReadStream& rs, const hecl::ProjectPath& outPath);
|
||||||
|
|
|
@ -127,19 +127,42 @@ public:
|
||||||
template <class IDType>
|
template <class IDType>
|
||||||
static hecl::ProjectPath TranslatePakIdToPath(const IDType& id, bool silenceWarnings=false)
|
static hecl::ProjectPath TranslatePakIdToPath(const IDType& id, bool silenceWarnings=false)
|
||||||
{
|
{
|
||||||
|
/* Try PAKRouter first (only available at extract) */
|
||||||
PAKRouterBase* pakRouter = g_PakRouter.get();
|
PAKRouterBase* pakRouter = g_PakRouter.get();
|
||||||
if (!pakRouter)
|
if (pakRouter)
|
||||||
|
{
|
||||||
|
hecl::ProjectPath path = pakRouter->getWorking(id, silenceWarnings);
|
||||||
|
if (path)
|
||||||
|
return path;
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Try project cache second (populated with paths read from YAML resources) */
|
||||||
|
hecl::Database::Project* project = s_Project.get();
|
||||||
|
if (!project)
|
||||||
LogDNACommon.report(logvisor::Fatal,
|
LogDNACommon.report(logvisor::Fatal,
|
||||||
"g_PakRouter must be set to non-null before calling UniqueIDBridge::TranslatePakIdToPath");
|
"g_PakRouter or s_Project must be set to non-null before "
|
||||||
return pakRouter->getWorking(id, silenceWarnings);
|
"calling UniqueIDBridge::TranslatePakIdToPath");
|
||||||
|
|
||||||
|
const hecl::ProjectPath* search = project->lookupBridgePath(id.toUint64());
|
||||||
|
if (!search)
|
||||||
|
{
|
||||||
|
if (!silenceWarnings)
|
||||||
|
LogDNACommon.report(logvisor::Warning,
|
||||||
|
"unable to translate %s to path", id.toString().c_str());
|
||||||
|
return {};
|
||||||
|
}
|
||||||
|
return *search;
|
||||||
}
|
}
|
||||||
|
template <class IDType>
|
||||||
static hecl::ProjectPath MakePathFromString(const std::string& str)
|
static hecl::ProjectPath MakePathFromString(const std::string& str)
|
||||||
{
|
{
|
||||||
hecl::Database::Project* project = s_Project.get();
|
hecl::Database::Project* project = s_Project.get();
|
||||||
if (!project)
|
if (!project)
|
||||||
LogDNACommon.report(logvisor::Fatal,
|
LogDNACommon.report(logvisor::Fatal,
|
||||||
"UniqueIDBridge::setGlobalProject must be called before MakePathFromString");
|
"UniqueIDBridge::setGlobalProject must be called before MakePathFromString");
|
||||||
return hecl::ProjectPath(*project, str);
|
hecl::ProjectPath path = hecl::ProjectPath(*project, str);
|
||||||
|
project->addBridgePathToCache(IDType(path), path);
|
||||||
|
return path;
|
||||||
}
|
}
|
||||||
template <class IDType>
|
template <class IDType>
|
||||||
static void TransformOldHashToNewHash(IDType& id)
|
static void TransformOldHashToNewHash(IDType& id)
|
||||||
|
@ -168,7 +191,7 @@ public:
|
||||||
{writer.writeUint32Big(m_id);}
|
{writer.writeUint32Big(m_id);}
|
||||||
void read(athena::io::YAMLDocReader& reader)
|
void read(athena::io::YAMLDocReader& reader)
|
||||||
{
|
{
|
||||||
*this = UniqueIDBridge::MakePathFromString(reader.readString(nullptr));
|
*this = UniqueIDBridge::MakePathFromString<UniqueID32>(reader.readString(nullptr));
|
||||||
}
|
}
|
||||||
void write(athena::io::YAMLDocWriter& writer) const
|
void write(athena::io::YAMLDocWriter& writer) const
|
||||||
{
|
{
|
||||||
|
@ -198,6 +221,7 @@ public:
|
||||||
void clear() {m_id = 0xffffffff;}
|
void clear() {m_id = 0xffffffff;}
|
||||||
|
|
||||||
UniqueID32() = default;
|
UniqueID32() = default;
|
||||||
|
UniqueID32(uint32_t idin) : m_id(idin) {}
|
||||||
UniqueID32(athena::io::IStreamReader& reader) {read(reader);}
|
UniqueID32(athena::io::IStreamReader& reader) {read(reader);}
|
||||||
UniqueID32(const hecl::ProjectPath& path) {*this = path;}
|
UniqueID32(const hecl::ProjectPath& path) {*this = path;}
|
||||||
UniqueID32(const char* hexStr)
|
UniqueID32(const char* hexStr)
|
||||||
|
@ -260,7 +284,7 @@ public:
|
||||||
|
|
||||||
void read(athena::io::YAMLDocReader& reader)
|
void read(athena::io::YAMLDocReader& reader)
|
||||||
{
|
{
|
||||||
hecl::ProjectPath readPath = UniqueIDBridge::MakePathFromString(reader.readString(nullptr));
|
hecl::ProjectPath readPath = UniqueIDBridge::MakePathFromString<UniqueID32>(reader.readString(nullptr));
|
||||||
*this = readPath.ensureAuxInfo(m_auxStr);
|
*this = readPath.ensureAuxInfo(m_auxStr);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -295,7 +319,7 @@ public:
|
||||||
{writer.writeUint64Big(m_id);}
|
{writer.writeUint64Big(m_id);}
|
||||||
void read(athena::io::YAMLDocReader& reader)
|
void read(athena::io::YAMLDocReader& reader)
|
||||||
{
|
{
|
||||||
*this = UniqueIDBridge::MakePathFromString(reader.readString(nullptr));
|
*this = UniqueIDBridge::MakePathFromString<UniqueID64>(reader.readString(nullptr));
|
||||||
}
|
}
|
||||||
void write(athena::io::YAMLDocWriter& writer) const
|
void write(athena::io::YAMLDocWriter& writer) const
|
||||||
{
|
{
|
||||||
|
@ -324,6 +348,7 @@ public:
|
||||||
void clear() {m_id = 0xffffffffffffffff;}
|
void clear() {m_id = 0xffffffffffffffff;}
|
||||||
|
|
||||||
UniqueID64() = default;
|
UniqueID64() = default;
|
||||||
|
UniqueID64(uint64_t idin) : m_id(idin) {}
|
||||||
UniqueID64(athena::io::IStreamReader& reader) {read(reader);}
|
UniqueID64(athena::io::IStreamReader& reader) {read(reader);}
|
||||||
UniqueID64(const hecl::ProjectPath& path) {*this = path;}
|
UniqueID64(const hecl::ProjectPath& path) {*this = path;}
|
||||||
UniqueID64(const char* hexStr)
|
UniqueID64(const char* hexStr)
|
||||||
|
@ -379,7 +404,7 @@ public:
|
||||||
}
|
}
|
||||||
void read(athena::io::YAMLDocReader& reader)
|
void read(athena::io::YAMLDocReader& reader)
|
||||||
{
|
{
|
||||||
*this = UniqueIDBridge::MakePathFromString(reader.readString(nullptr));
|
*this = UniqueIDBridge::MakePathFromString<UniqueID128>(reader.readString(nullptr));
|
||||||
}
|
}
|
||||||
void write(athena::io::YAMLDocWriter& writer) const
|
void write(athena::io::YAMLDocWriter& writer) const
|
||||||
{
|
{
|
||||||
|
@ -399,6 +424,7 @@ public:
|
||||||
m_id[1] = 0;
|
m_id[1] = 0;
|
||||||
return *this;
|
return *this;
|
||||||
}
|
}
|
||||||
|
UniqueID128(const hecl::ProjectPath& path) {*this = path;}
|
||||||
|
|
||||||
bool operator!=(const UniqueID128& other) const
|
bool operator!=(const UniqueID128& other) const
|
||||||
{
|
{
|
||||||
|
@ -421,6 +447,7 @@ public:
|
||||||
#endif
|
#endif
|
||||||
}
|
}
|
||||||
void clear() {m_id[0] = 0xffffffffffffffff; m_id[1] = 0xffffffffffffffff;}
|
void clear() {m_id[0] = 0xffffffffffffffff; m_id[1] = 0xffffffffffffffff;}
|
||||||
|
uint64_t toUint64() const {return m_id[0];}
|
||||||
uint64_t toHighUint64() const {return m_id[0];}
|
uint64_t toHighUint64() const {return m_id[0];}
|
||||||
uint64_t toLowUint64() const {return m_id[1];}
|
uint64_t toLowUint64() const {return m_id[1];}
|
||||||
std::string toString() const
|
std::string toString() const
|
||||||
|
|
|
@ -404,6 +404,16 @@ void DPSM<IDType>::writeQuadDecalInfo(athena::io::IStreamWriter& w,
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
template <class IDType>
|
||||||
|
void DPSM<IDType>::gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
if (x0_quad.x14_TEX.m_elem)
|
||||||
|
x0_quad.x14_TEX.m_elem->gatherDependencies(pathsOut);
|
||||||
|
if (x1c_quad.x14_TEX.m_elem)
|
||||||
|
x1c_quad.x14_TEX.m_elem->gatherDependencies(pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(x38_DMDL.id, pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
template struct DPSM<UniqueID32>;
|
template struct DPSM<UniqueID32>;
|
||||||
template struct DPSM<UniqueID64>;
|
template struct DPSM<UniqueID64>;
|
||||||
|
|
||||||
|
|
|
@ -50,6 +50,8 @@ struct DPSM : BigYAML
|
||||||
void read(athena::io::IStreamReader& r);
|
void read(athena::io::IStreamReader& r);
|
||||||
void write(athena::io::IStreamWriter& w) const;
|
void write(athena::io::IStreamWriter& w) const;
|
||||||
void writeQuadDecalInfo(athena::io::IStreamWriter& w, const SQuadDescr& quad, bool first) const;
|
void writeQuadDecalInfo(athena::io::IStreamWriter& w, const SQuadDescr& quad, bool first) const;
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>&) const;
|
||||||
};
|
};
|
||||||
|
|
||||||
template <class IDType>
|
template <class IDType>
|
||||||
|
|
|
@ -444,6 +444,14 @@ void ELSM<IDType>::write(athena::io::IStreamWriter& w) const
|
||||||
w.writeBytes("_END", 4);
|
w.writeBytes("_END", 4);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
template <class IDType>
|
||||||
|
void ELSM<IDType>::gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(x40_SSWH.id, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(x50_GPSM.id, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(x60_EPSM.id, pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
template struct ELSM<UniqueID32>;
|
template struct ELSM<UniqueID32>;
|
||||||
template struct ELSM<UniqueID64>;
|
template struct ELSM<UniqueID64>;
|
||||||
|
|
||||||
|
|
|
@ -40,6 +40,8 @@ struct ELSM : BigYAML
|
||||||
size_t binarySize(size_t __isz) const;
|
size_t binarySize(size_t __isz) const;
|
||||||
void read(athena::io::IStreamReader& r);
|
void read(athena::io::IStreamReader& r);
|
||||||
void write(athena::io::IStreamWriter& w) const;
|
void write(athena::io::IStreamWriter& w) const;
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>&) const;
|
||||||
};
|
};
|
||||||
|
|
||||||
template <class IDType>
|
template <class IDType>
|
||||||
|
|
|
@ -109,6 +109,11 @@ struct FONT : BigYAML
|
||||||
std::vector<std::unique_ptr<IGlyph>> glyphs;
|
std::vector<std::unique_ptr<IGlyph>> glyphs;
|
||||||
Value<atUint32> kerningInfoCount;
|
Value<atUint32> kerningInfoCount;
|
||||||
Vector<KerningInfo, DNA_COUNT(kerningInfoCount)> kerningInfo;
|
Vector<KerningInfo, DNA_COUNT(kerningInfoCount)> kerningInfo;
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(textureId, pathsOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
template <class IDType>
|
template <class IDType>
|
||||||
|
|
|
@ -1532,6 +1532,23 @@ void GPSM<IDType>::write(athena::io::IStreamWriter& w) const
|
||||||
w.writeBytes("_END", 4);
|
w.writeBytes("_END", 4);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
template <class IDType>
|
||||||
|
void GPSM<IDType>::gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
if (x54_TEXR.m_elem)
|
||||||
|
x54_TEXR.m_elem->gatherDependencies(pathsOut);
|
||||||
|
if (x58_TIND.m_elem)
|
||||||
|
x58_TIND.m_elem->gatherDependencies(pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(x5c_PMDL.id, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(x8c_ICTS.id, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(xa4_IDTS.id, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(xb8_IITS.id, pathsOut);
|
||||||
|
xd0_KSSM.gatherDependencies(pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(xd4_SSWH.id, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(xec_PMLC.id, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(xd8_SELC.id, pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
template struct GPSM<UniqueID32>;
|
template struct GPSM<UniqueID32>;
|
||||||
template struct GPSM<UniqueID64>;
|
template struct GPSM<UniqueID64>;
|
||||||
|
|
||||||
|
|
|
@ -112,6 +112,8 @@ struct GPSM : BigYAML
|
||||||
size_t binarySize(size_t __isz) const;
|
size_t binarySize(size_t __isz) const;
|
||||||
void read(athena::io::IStreamReader& r);
|
void read(athena::io::IStreamReader& r);
|
||||||
void write(athena::io::IStreamWriter& w) const;
|
void write(athena::io::IStreamWriter& w) const;
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>&) const;
|
||||||
};
|
};
|
||||||
|
|
||||||
template <class IDType>
|
template <class IDType>
|
||||||
|
|
|
@ -100,7 +100,11 @@ struct EmitterElementFactory : BigYAML
|
||||||
void write(athena::io::IStreamWriter& w) const;
|
void write(athena::io::IStreamWriter& w) const;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct IUVElement : IElement {Delete _d;};
|
struct IUVElement : IElement
|
||||||
|
{
|
||||||
|
Delete _d;
|
||||||
|
virtual void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const=0;
|
||||||
|
};
|
||||||
|
|
||||||
struct BoolHelper : IElement
|
struct BoolHelper : IElement
|
||||||
{
|
{
|
||||||
|
@ -1135,6 +1139,11 @@ struct UVEConstant : IUVElement
|
||||||
tex.write(w);
|
tex.write(w);
|
||||||
}
|
}
|
||||||
const char* ClassID() const {return "CNST";}
|
const char* ClassID() const {return "CNST";}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(tex, pathsOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
template <class IDType>
|
template <class IDType>
|
||||||
|
@ -1249,6 +1258,11 @@ struct UVEAnimTexture : IUVElement
|
||||||
w.writeBool(loop);
|
w.writeBool(loop);
|
||||||
}
|
}
|
||||||
const char* ClassID() const {return "ATEX";}
|
const char* ClassID() const {return "ATEX";}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(tex, pathsOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
template <class IDType>
|
template <class IDType>
|
||||||
|
@ -1535,6 +1549,13 @@ struct SpawnSystemKeyframeData : BigYAML
|
||||||
}
|
}
|
||||||
|
|
||||||
operator bool() const {return spawns.size() != 0;}
|
operator bool() const {return spawns.size() != 0;}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
for (const auto& p : spawns)
|
||||||
|
for (const SpawnSystemKeyframeInfo& info : p.second)
|
||||||
|
g_curSpec->flattenDependencies(info.id, pathsOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
template <class IDType>
|
template <class IDType>
|
||||||
|
|
|
@ -6,6 +6,11 @@
|
||||||
namespace DataSpec
|
namespace DataSpec
|
||||||
{
|
{
|
||||||
|
|
||||||
|
void ISTRG::gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
/* TODO: parse out resource tokens */
|
||||||
|
}
|
||||||
|
|
||||||
std::unique_ptr<ISTRG> LoadSTRG(athena::io::IStreamReader& reader)
|
std::unique_ptr<ISTRG> LoadSTRG(athena::io::IStreamReader& reader)
|
||||||
{
|
{
|
||||||
uint32_t magic = reader.readUint32Big();
|
uint32_t magic = reader.readUint32Big();
|
||||||
|
|
|
@ -19,6 +19,8 @@ struct ISTRG : BigYAML
|
||||||
virtual std::wstring getUTF16(const FourCC& lang, size_t idx) const=0;
|
virtual std::wstring getUTF16(const FourCC& lang, size_t idx) const=0;
|
||||||
virtual hecl::SystemString getSystemString(const FourCC& lang, size_t idx) const=0;
|
virtual hecl::SystemString getSystemString(const FourCC& lang, size_t idx) const=0;
|
||||||
virtual int32_t lookupIdx(const std::string& name) const=0;
|
virtual int32_t lookupIdx(const std::string& name) const=0;
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const;
|
||||||
};
|
};
|
||||||
std::unique_ptr<ISTRG> LoadSTRG(athena::io::IStreamReader& reader);
|
std::unique_ptr<ISTRG> LoadSTRG(athena::io::IStreamReader& reader);
|
||||||
|
|
||||||
|
|
|
@ -538,6 +538,13 @@ void SWSH<IDType>::write(athena::io::IStreamWriter& w) const
|
||||||
w.writeBytes("_END", 4);
|
w.writeBytes("_END", 4);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
template <class IDType>
|
||||||
|
void SWSH<IDType>::gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
if (x3c_TEXR.m_elem)
|
||||||
|
x3c_TEXR.m_elem->gatherDependencies(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
template struct SWSH<UniqueID32>;
|
template struct SWSH<UniqueID32>;
|
||||||
template struct SWSH<UniqueID64>;
|
template struct SWSH<UniqueID64>;
|
||||||
|
|
||||||
|
|
|
@ -55,6 +55,8 @@ struct SWSH : public BigYAML
|
||||||
{
|
{
|
||||||
x44_25_CROS = true;
|
x44_25_CROS = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>&) const;
|
||||||
};
|
};
|
||||||
|
|
||||||
template <class IDType>
|
template <class IDType>
|
||||||
|
|
|
@ -719,6 +719,18 @@ void WPSM<IDType>::write(athena::io::IStreamWriter &w) const
|
||||||
w.writeBytes("_END", 4);
|
w.writeBytes("_END", 4);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
template <class IDType>
|
||||||
|
void WPSM<IDType>::gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(x34_APSM.id, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(x44_APS2.id, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(x54_ASW1.id, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(x64_ASW2.id, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(x74_ASW3.id, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(x84_OHEF.id, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(x94_COLR.id, pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
template struct WPSM<UniqueID32>;
|
template struct WPSM<UniqueID32>;
|
||||||
template struct WPSM<UniqueID64>;
|
template struct WPSM<UniqueID64>;
|
||||||
|
|
||||||
|
|
|
@ -59,6 +59,8 @@ struct WPSM : BigYAML
|
||||||
{
|
{
|
||||||
xa4_EWTR = true; xa5_LWTR = true; xa6_SWTR = true;
|
xa4_EWTR = true; xa5_LWTR = true; xa6_SWTR = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>&) const;
|
||||||
};
|
};
|
||||||
|
|
||||||
template <class IDType>
|
template <class IDType>
|
||||||
|
|
|
@ -145,8 +145,6 @@ void PAKBridge::build()
|
||||||
areaName.read(rs);
|
areaName.read(rs);
|
||||||
}
|
}
|
||||||
areaDeps.name = areaName.getSystemString(FOURCC('ENGL'), 0);
|
areaDeps.name = areaName.getSystemString(FOURCC('ENGL'), 0);
|
||||||
|
|
||||||
/* Trim possible trailing whitespace */
|
|
||||||
areaDeps.name = hecl::StringUtils::TrimWhitespace(areaDeps.name);
|
areaDeps.name = hecl::StringUtils::TrimWhitespace(areaDeps.name);
|
||||||
}
|
}
|
||||||
if (areaDeps.name.empty())
|
if (areaDeps.name.empty())
|
||||||
|
@ -179,14 +177,8 @@ void PAKBridge::build()
|
||||||
Level::Area::Layer& layer = areaDeps.layers.back();
|
Level::Area::Layer& layer = areaDeps.layers.back();
|
||||||
layer.name = LayerName(mlvl.layerNames[layerIdx++]);
|
layer.name = LayerName(mlvl.layerNames[layerIdx++]);
|
||||||
layer.active = layerFlags.flags >> (l-1) & 0x1;
|
layer.active = layerFlags.flags >> (l-1) & 0x1;
|
||||||
/* Trim possible trailing whitespace */
|
layer.name = hecl::StringUtils::TrimWhitespace(layer.name);
|
||||||
#if HECL_UCS2
|
|
||||||
while (layer.name.size() && iswspace(layer.name.back()))
|
|
||||||
layer.name.pop_back();
|
|
||||||
#else
|
|
||||||
while (layer.name.size() && isspace(layer.name.back()))
|
|
||||||
layer.name.pop_back();
|
|
||||||
#endif
|
|
||||||
hecl::SNPrintf(num, 16, _S("%02u "), l-1);
|
hecl::SNPrintf(num, 16, _S("%02u "), l-1);
|
||||||
layer.name = num + layer.name;
|
layer.name = num + layer.name;
|
||||||
|
|
||||||
|
|
|
@ -1,5 +1,11 @@
|
||||||
#include "MLVL.hpp"
|
#include "MLVL.hpp"
|
||||||
#include "SCLY.hpp"
|
#include "SCLY.hpp"
|
||||||
|
#include "SAVW.hpp"
|
||||||
|
#include "SCAN.hpp"
|
||||||
|
#include "ScriptObjects/MemoryRelay.hpp"
|
||||||
|
#include "ScriptObjects/SpecialFunction.hpp"
|
||||||
|
#include "ScriptObjects/DoorArea.hpp"
|
||||||
|
#include "Runtime/RetroTypes.hpp"
|
||||||
|
|
||||||
namespace DataSpec
|
namespace DataSpec
|
||||||
{
|
{
|
||||||
|
@ -17,6 +23,16 @@ bool MLVL::Extract(const SpecBase& dataSpec,
|
||||||
{
|
{
|
||||||
MLVL mlvl;
|
MLVL mlvl;
|
||||||
mlvl.read(rs);
|
mlvl.read(rs);
|
||||||
|
|
||||||
|
for (const MLVL::Area& area : mlvl.areas)
|
||||||
|
{
|
||||||
|
hecl::ProjectPath areaDir = pakRouter.getWorking(area.areaMREAId).getParentPath();
|
||||||
|
athena::io::FileWriter fw(hecl::ProjectPath(areaDir, _S("!memoryid.yaml")).getAbsolutePath());
|
||||||
|
athena::io::YAMLDocWriter w(nullptr);
|
||||||
|
w.writeUint32("memoryid", area.areaId);
|
||||||
|
w.finish(&fw);
|
||||||
|
}
|
||||||
|
|
||||||
athena::io::FileWriter writer(outPath.getWithExtension(_S(".yaml"), true).getAbsolutePath());
|
athena::io::FileWriter writer(outPath.getWithExtension(_S(".yaml"), true).getAbsolutePath());
|
||||||
mlvl.toYAMLStream(writer, static_cast<YAMLWriteMemberFn>(&MLVL::writeMeta));
|
mlvl.toYAMLStream(writer, static_cast<YAMLWriteMemberFn>(&MLVL::writeMeta));
|
||||||
hecl::BlenderConnection& conn = btok.getBlenderConnection();
|
hecl::BlenderConnection& conn = btok.getBlenderConnection();
|
||||||
|
@ -32,24 +48,41 @@ bool MLVL::Cook(const hecl::ProjectPath& outPath, const hecl::ProjectPath& inPat
|
||||||
|
|
||||||
mlvl.magic = 0xDEAFBABE;
|
mlvl.magic = 0xDEAFBABE;
|
||||||
mlvl.version = 0x11;
|
mlvl.version = 0x11;
|
||||||
mlvl.saveWorldId = inPath.ensureAuxInfo(_S(".SAVW"));
|
hecl::ProjectPath savwPath = inPath.ensureAuxInfo(_S(".SAVW"));
|
||||||
|
mlvl.saveWorldId = savwPath;
|
||||||
|
hecl::ProjectPath mapwPath = inPath.ensureAuxInfo(_S(".MAPW"));
|
||||||
|
mlvl.worldMap = mapwPath;
|
||||||
|
|
||||||
|
std::vector<urde::SObjectTag> mapaTags;
|
||||||
|
mapaTags.reserve(wld.areas.size());
|
||||||
|
|
||||||
|
SAVW savw = {};
|
||||||
|
savw.header.magic = 0xC001D00D;
|
||||||
|
savw.header.version = 0x3;
|
||||||
|
|
||||||
size_t areaIdx = 0;
|
size_t areaIdx = 0;
|
||||||
|
size_t nameOffset = 0;
|
||||||
for (const World::Area& area : wld.areas)
|
for (const World::Area& area : wld.areas)
|
||||||
{
|
{
|
||||||
if (area.path.getPathType() != hecl::ProjectPath::Type::Directory)
|
if (area.path.getPathType() != hecl::ProjectPath::Type::Directory)
|
||||||
continue;
|
continue;
|
||||||
|
|
||||||
|
hecl::ProjectPath areaPath(area.path, _S("/!area.blend"));
|
||||||
|
if (!areaPath.isFile())
|
||||||
|
continue;
|
||||||
|
|
||||||
hecl::DirectoryEnumerator dEnum(area.path.getAbsolutePath(),
|
hecl::DirectoryEnumerator dEnum(area.path.getAbsolutePath(),
|
||||||
hecl::DirectoryEnumerator::Mode::DirsSorted);
|
hecl::DirectoryEnumerator::Mode::DirsSorted);
|
||||||
bool areaInit = false;
|
bool areaInit = false;
|
||||||
|
|
||||||
|
size_t layerIdx = 0;
|
||||||
for (const hecl::DirectoryEnumerator::Entry& e : dEnum)
|
for (const hecl::DirectoryEnumerator::Entry& e : dEnum)
|
||||||
{
|
{
|
||||||
hecl::SystemString layerName;
|
hecl::SystemString layerName;
|
||||||
hecl::SystemChar* endCh = nullptr;
|
hecl::SystemChar* endCh = nullptr;
|
||||||
hecl::StrToUl(e.m_name.c_str(), &endCh, 0);
|
hecl::StrToUl(e.m_name.c_str(), &endCh, 0);
|
||||||
if (!endCh)
|
if (!endCh)
|
||||||
layerName = e.m_name;
|
layerName = hecl::StringUtils::TrimWhitespace(e.m_name);
|
||||||
else
|
else
|
||||||
layerName = hecl::StringUtils::TrimWhitespace(hecl::SystemString(endCh));
|
layerName = hecl::StringUtils::TrimWhitespace(hecl::SystemString(endCh));
|
||||||
|
|
||||||
|
@ -72,21 +105,219 @@ bool MLVL::Cook(const hecl::ProjectPath& outPath, const hecl::ProjectPath& inPat
|
||||||
layer.read(reader);
|
layer.read(reader);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/* Set active flag state */
|
||||||
hecl::ProjectPath defActivePath(area.path, e.m_name + _S("/!defaultactive"));
|
hecl::ProjectPath defActivePath(area.path, e.m_name + _S("/!defaultactive"));
|
||||||
bool active = defActivePath.isNone() ? false : true;
|
bool active = defActivePath.isNone() ? false : true;
|
||||||
|
|
||||||
if (!areaInit)
|
if (!areaInit)
|
||||||
{
|
{
|
||||||
|
/* Finish last area */
|
||||||
|
if (mlvl.areas.size())
|
||||||
|
{
|
||||||
|
MLVL::Area& areaLast = mlvl.areas.back();
|
||||||
|
areaLast.attachedAreaCount = areaLast.attachedAreas.size();
|
||||||
|
areaLast.depCount = areaLast.deps.size();
|
||||||
|
areaLast.depLayerCount = areaLast.depLayers.size();
|
||||||
|
areaLast.dockCount = areaLast.docks.size();
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Area map */
|
||||||
|
hecl::ProjectPath mapPath(area.path, _S("/!map.blend"));
|
||||||
|
if (mapPath.isFile())
|
||||||
|
mapaTags.push_back(g_curSpec->BuildTagFromPath(mapPath, hecl::SharedBlenderToken));
|
||||||
|
|
||||||
|
/* Populate area record */
|
||||||
mlvl.areas.emplace_back();
|
mlvl.areas.emplace_back();
|
||||||
MLVL::Area& areaOut = mlvl.areas.back();
|
MLVL::Area& areaOut = mlvl.areas.back();
|
||||||
|
|
||||||
|
hecl::ProjectPath namePath(area.path, _S("/!name.yaml"));
|
||||||
|
if (namePath.isFile())
|
||||||
|
areaOut.areaNameId = namePath;
|
||||||
|
|
||||||
|
areaOut.transformMtx[0] = area.transform[0];
|
||||||
|
areaOut.transformMtx[1] = area.transform[1];
|
||||||
|
areaOut.transformMtx[2] = area.transform[2];
|
||||||
|
areaOut.aabb[0] = area.aabb[0];
|
||||||
|
areaOut.aabb[1] = area.aabb[1];
|
||||||
|
areaOut.areaMREAId = areaPath;
|
||||||
|
areaOut.areaId = 0xffffffff;
|
||||||
|
|
||||||
|
hecl::ProjectPath memIdPath(area.path, _S("/!memoryid.yaml"));
|
||||||
|
if (namePath.isFile())
|
||||||
|
{
|
||||||
|
athena::io::FileReader fr(memIdPath.getAbsolutePath());
|
||||||
|
athena::io::YAMLDocReader r;
|
||||||
|
if (r.parse(&fr))
|
||||||
|
areaOut.areaId = r.readUint32("memoryid");
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Attached Areas and Docks */
|
||||||
|
{
|
||||||
|
std::unordered_set<uint32_t> addedAreas;
|
||||||
|
areaOut.dockCount = area.docks.size();
|
||||||
|
for (const World::Area::Dock& dock : area.docks)
|
||||||
|
{
|
||||||
|
areaOut.docks.emplace_back();
|
||||||
|
MLVL::Area::Dock& dockOut = areaOut.docks.back();
|
||||||
|
dockOut.endpointCount = 1;
|
||||||
|
dockOut.endpoints.emplace_back();
|
||||||
|
MLVL::Area::Dock::Endpoint& ep = dockOut.endpoints.back();
|
||||||
|
ep.areaIdx = dock.targetArea;
|
||||||
|
ep.dockIdx = dock.targetDock;
|
||||||
|
dockOut.planeVertCount = 4;
|
||||||
|
dockOut.planeVerts.push_back(dock.verts[0]);
|
||||||
|
dockOut.planeVerts.push_back(dock.verts[1]);
|
||||||
|
dockOut.planeVerts.push_back(dock.verts[2]);
|
||||||
|
dockOut.planeVerts.push_back(dock.verts[3]);
|
||||||
|
|
||||||
|
if (addedAreas.find(dock.targetArea) == addedAreas.cend())
|
||||||
|
{
|
||||||
|
addedAreas.insert(dock.targetArea);
|
||||||
|
areaOut.attachedAreas.push_back(dock.targetArea);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
areaOut.attachedAreaCount = areaOut.attachedAreas.size();
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Layer flags */
|
||||||
|
mlvl.layerFlags.emplace_back();
|
||||||
|
mlvl.layerFlags.back().layerCount = 0;
|
||||||
|
mlvl.layerFlags.back().flags = ~0;
|
||||||
|
|
||||||
|
/* Layer name offset */
|
||||||
|
mlvl.layerNameOffsets.push_back(nameOffset);
|
||||||
|
|
||||||
areaInit = true;
|
areaInit = true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
MLVL::Area& areaOut = mlvl.areas.back();
|
||||||
|
areaOut.depLayers.push_back(areaOut.deps.size());
|
||||||
|
|
||||||
|
/* Gather memory relays, scans, and dependencies */
|
||||||
|
{
|
||||||
|
std::vector<hecl::ProjectPath> depPaths;
|
||||||
|
std::vector<Scan> scans;
|
||||||
|
for (std::unique_ptr<IScriptObject>& obj : layer.objects)
|
||||||
|
{
|
||||||
|
if (obj->type == 0x13)
|
||||||
|
{
|
||||||
|
MemoryRelay& memRelay = static_cast<MemoryRelay&>(*obj);
|
||||||
|
for (IScriptObject::Connection& conn : memRelay.connections)
|
||||||
|
{
|
||||||
|
mlvl.memRelayLinks.emplace_back();
|
||||||
|
MemRelayLink& linkOut = mlvl.memRelayLinks.back();
|
||||||
|
linkOut.memRelayId = memRelay.id;
|
||||||
|
linkOut.targetId = conn.target;
|
||||||
|
linkOut.msg = conn.msg;
|
||||||
|
linkOut.active = memRelay.active;
|
||||||
|
}
|
||||||
|
savw.relays.push_back(memRelay.id);
|
||||||
|
}
|
||||||
|
else if (obj->type == 0x3A)
|
||||||
|
{
|
||||||
|
SpecialFunction& specialFunc = static_cast<SpecialFunction&>(*obj);
|
||||||
|
if (specialFunc.type == ESpecialFunctionType::CinematicSkip)
|
||||||
|
savw.skippableCutscenes.push_back(specialFunc.id);
|
||||||
|
else if (specialFunc.type == ESpecialFunctionType::ScriptLayerController)
|
||||||
|
{
|
||||||
|
savw.layers.emplace_back();
|
||||||
|
SAVWCommon::Layer& layer = savw.layers.back();
|
||||||
|
layer.areaId = specialFunc.layerSwitch.area;
|
||||||
|
layer.layer = specialFunc.layerSwitch.layerIdx;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else if (obj->type == 0x3)
|
||||||
|
{
|
||||||
|
DoorArea& doorArea = static_cast<DoorArea&>(*obj);
|
||||||
|
savw.doors.push_back(doorArea.id);
|
||||||
|
}
|
||||||
|
|
||||||
|
obj->gatherDependencies(depPaths);
|
||||||
|
obj->gatherScans(scans);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Cull duplicate paths and add typed hash to list */
|
||||||
|
std::unordered_set<hecl::Hash> addedPaths;
|
||||||
|
for (const hecl::ProjectPath& path : depPaths)
|
||||||
|
{
|
||||||
|
if (addedPaths.find(path.hash()) == addedPaths.cend())
|
||||||
|
{
|
||||||
|
addedPaths.insert(path.hash());
|
||||||
|
urde::SObjectTag tag = g_curSpec->BuildTagFromPath(path, hecl::SharedBlenderToken);
|
||||||
|
areaOut.deps.emplace_back(tag.id, tag.type);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Cull duplicate scans and add to list */
|
||||||
|
std::unordered_set<UniqueID32> addedScans;
|
||||||
|
for (const Scan& scan : scans)
|
||||||
|
{
|
||||||
|
if (addedScans.find(scan.scanId) == addedScans.cend())
|
||||||
|
{
|
||||||
|
addedScans.insert(scan.scanId);
|
||||||
|
hecl::ProjectPath scanPath = UniqueIDBridge::TranslatePakIdToPath(scan.scanId);
|
||||||
|
savw.scans.emplace_back();
|
||||||
|
Scan& scanOut = savw.scans.back();
|
||||||
|
scanOut.scanId = scan.scanId;
|
||||||
|
scanOut.category = SAVWCommon::EScanCategory(SCAN::GetCategory(scanPath));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
hecl::SystemUTF8View layerU8(layerName);
|
||||||
|
mlvl.layerNames.push_back(layerU8.str());
|
||||||
|
nameOffset += layerName.size() + 1;
|
||||||
|
|
||||||
|
MLVL::LayerFlags& thisLayFlags = mlvl.layerFlags.back();
|
||||||
|
++thisLayFlags.layerCount;
|
||||||
|
if (!active)
|
||||||
|
thisLayFlags.flags &= ~(1 << layerIdx);
|
||||||
|
|
||||||
|
++layerIdx;
|
||||||
}
|
}
|
||||||
++areaIdx;
|
++areaIdx;
|
||||||
}
|
}
|
||||||
|
|
||||||
mlvl.memRelayLinkCount = mlvl.memRelayLinks.size();
|
mlvl.memRelayLinkCount = mlvl.memRelayLinks.size();
|
||||||
mlvl.areaCount = mlvl.areas.size();
|
mlvl.areaCount = mlvl.areas.size();
|
||||||
|
mlvl.layerFlagCount = mlvl.layerFlags.size();
|
||||||
|
mlvl.layerNameCount = mlvl.layerNames.size();
|
||||||
|
mlvl.layerNameOffsetCount = mlvl.layerNameOffsets.size();
|
||||||
|
|
||||||
|
/* Write out */
|
||||||
|
{
|
||||||
|
athena::io::FileWriter fo(outPath.getAbsolutePath());
|
||||||
|
mlvl.write(fo);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Write out MAPW */
|
||||||
|
{
|
||||||
|
hecl::ProjectPath mapwCooked =
|
||||||
|
mapwPath.getCookedPath(*g_curSpec->overrideDataSpec(mapwPath, nullptr, hecl::SharedBlenderToken));
|
||||||
|
athena::io::FileWriter fo(mapwCooked.getAbsolutePath());
|
||||||
|
fo.writeUint32Big(0xDEADF00D);
|
||||||
|
fo.writeUint32Big(1);
|
||||||
|
fo.writeUint32Big(mapaTags.size());
|
||||||
|
for (const urde::SObjectTag& mapa : mapaTags)
|
||||||
|
fo.writeUint32Big(mapa.id);
|
||||||
|
}
|
||||||
|
|
||||||
|
/* Write out SAVW */
|
||||||
|
{
|
||||||
|
savw.header.areaCount = mlvl.areaCount;
|
||||||
|
savw.skippableCutsceneCount = savw.skippableCutscenes.size();
|
||||||
|
savw.relayCount = savw.relays.size();
|
||||||
|
savw.layerCount = savw.layers.size();
|
||||||
|
savw.doorCount = savw.doors.size();
|
||||||
|
savw.scanCount = savw.scans.size();
|
||||||
|
|
||||||
|
hecl::ProjectPath savwCooked =
|
||||||
|
savwPath.getCookedPath(*g_curSpec->overrideDataSpec(savwPath, nullptr, hecl::SharedBlenderToken));
|
||||||
|
athena::io::FileWriter fo(savwCooked.getAbsolutePath());
|
||||||
|
savw.write(fo);
|
||||||
|
}
|
||||||
|
|
||||||
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -51,6 +51,10 @@ struct MLVL : BigYAML
|
||||||
DECL_YAML
|
DECL_YAML
|
||||||
UniqueID32 id;
|
UniqueID32 id;
|
||||||
DNAFourCC type;
|
DNAFourCC type;
|
||||||
|
|
||||||
|
Dependency() = default;
|
||||||
|
Dependency(const UniqueID32& idin, const hecl::FourCC& fcc)
|
||||||
|
: id(idin), type(fcc) {}
|
||||||
};
|
};
|
||||||
Vector<Dependency, DNA_COUNT(depCount)> deps;
|
Vector<Dependency, DNA_COUNT(depCount)> deps;
|
||||||
|
|
||||||
|
|
|
@ -13,6 +13,9 @@ struct Scan : BigYAML
|
||||||
DECL_YAML
|
DECL_YAML
|
||||||
UniqueID32 scanId;
|
UniqueID32 scanId;
|
||||||
Value<SAVWCommon::EScanCategory> category;
|
Value<SAVWCommon::EScanCategory> category;
|
||||||
|
|
||||||
|
Scan() = default;
|
||||||
|
Scan(const UniqueID32& id) : scanId(id), category(SAVWCommon::EScanCategory::None) {}
|
||||||
};
|
};
|
||||||
|
|
||||||
struct SAVW : BigYAML
|
struct SAVW : BigYAML
|
||||||
|
|
|
@ -171,6 +171,17 @@ struct SCAN : BigYAML
|
||||||
return true;
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
static Category GetCategory(const hecl::ProjectPath& inPath)
|
||||||
|
{
|
||||||
|
SCAN scan;
|
||||||
|
athena::io::FileReader reader(inPath.getAbsolutePath());
|
||||||
|
if (reader.hasError())
|
||||||
|
return Category::None;
|
||||||
|
if (!scan.fromYAMLStream(reader))
|
||||||
|
return Category::None;
|
||||||
|
return scan.category;
|
||||||
|
}
|
||||||
|
|
||||||
static void Name(const SpecBase& dataSpec,
|
static void Name(const SpecBase& dataSpec,
|
||||||
PAKEntryReadStream& rs,
|
PAKEntryReadStream& rs,
|
||||||
PAKRouter<PAKBridge>& pakRouter,
|
PAKRouter<PAKBridge>& pakRouter,
|
||||||
|
|
|
@ -52,6 +52,18 @@ struct Actor : IScriptObject
|
||||||
animationParameters.nameANCS(pakRouter, name + "_animp");
|
animationParameters.nameANCS(pakRouter, name + "_animp");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(model, pathsOut);
|
||||||
|
animationParameters.depANCS(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -44,6 +44,18 @@ struct ActorContraption : IScriptObject
|
||||||
animationParameters.nameANCS(pakRouter, name + "_animp");
|
animationParameters.nameANCS(pakRouter, name + "_animp");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(particle, pathsOut);
|
||||||
|
animationParameters.depANCS(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -40,6 +40,17 @@ struct AmbientAI : IScriptObject
|
||||||
animationParameters.nameANCS(pakRouter, name + "_animp");
|
animationParameters.nameANCS(pakRouter, name + "_animp");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
animationParameters.depANCS(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -28,6 +28,11 @@ struct AreaAttributes : IScriptObject
|
||||||
Value<float> unknown5;
|
Value<float> unknown5;
|
||||||
UniqueID32 skybox;
|
UniqueID32 skybox;
|
||||||
Value<atUint32> unknown6;
|
Value<atUint32> unknown6;
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(skybox, pathsOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -48,6 +48,19 @@ struct AtomicAlpha : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(wpsc, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(model, pathsOut);
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -60,6 +60,20 @@ struct AtomicBeta : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(elsc, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(wpsc, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(part, pathsOut);
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -115,6 +115,28 @@ struct Babygoth : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(wpsc1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(wpsc2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(model, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(skin, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle3, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle4, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle5, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(texture, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle6, pathsOut);
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -45,6 +45,18 @@ struct Beetle : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(model, pathsOut);
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -77,6 +77,24 @@ struct BloodFlower : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(wpsc1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(wpsc2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle3, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle4, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle5, pathsOut);
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -62,6 +62,22 @@ struct Burrower : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(wpsc, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle3, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle4, pathsOut);
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -31,6 +31,11 @@ struct CameraFilterKeyframe : IScriptObject
|
||||||
ent->name = name + "_texture";
|
ent->name = name + "_texture";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(texture, pathsOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -70,6 +70,20 @@ struct ChozoGhost : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(wpsc1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(wpsc2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle, pathsOut);
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -43,6 +43,13 @@ struct DamageableTrigger : IScriptObject
|
||||||
ent->name = name + "_texture3";
|
ent->name = name + "_texture3";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(texture1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(texture2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(texture3, pathsOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -45,6 +45,18 @@ struct Debris : IScriptObject
|
||||||
}
|
}
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(model, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle, pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -76,6 +76,20 @@ struct DebrisExtended : IScriptObject
|
||||||
}
|
}
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(model, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle3, pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -38,6 +38,17 @@ struct DoorArea : IScriptObject
|
||||||
animationParameters.nameANCS(pakRouter, name + "_animp");
|
animationParameters.nameANCS(pakRouter, name + "_animp");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
animationParameters.depANCS(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -79,6 +79,23 @@ struct Drone : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(crsc, pathsOut);
|
||||||
|
flareDefinition1.depIDs(pathsOut);
|
||||||
|
flareDefinition2.depIDs(pathsOut);
|
||||||
|
flareDefinition3.depIDs(pathsOut);
|
||||||
|
flareDefinition4.depIDs(pathsOut);
|
||||||
|
flareDefinition5.depIDs(pathsOut);
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -50,6 +50,12 @@ struct Effect : IScriptObject
|
||||||
ent->name = name + "_elsc";
|
ent->name = name + "_elsc";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(part, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(elsc, pathsOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -33,6 +33,11 @@ struct ElectroMagneticPulse : IScriptObject
|
||||||
ent->name = name + "_part";
|
ent->name = name + "_part";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(particle, pathsOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -114,6 +114,29 @@ struct ElitePirate : IScriptObject
|
||||||
actorParameters2.nameIDs(pakRouter, name + "_actp2");
|
actorParameters2.nameIDs(pakRouter, name + "_actp2");
|
||||||
animationParameters.nameANCS(pakRouter, name + "_animp");
|
animationParameters.nameANCS(pakRouter, name + "_animp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(particle1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(model, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle3, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle4, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle5, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle6, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle7, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(elsc, pathsOut);
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters1.depIDs(pathsOut);
|
||||||
|
actorParameters2.depIDs(pathsOut);
|
||||||
|
animationParameters.depANCS(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters1.scanIDs(scansOut);
|
||||||
|
actorParameters2.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -64,6 +64,21 @@ struct EnergyBall : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(texture, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(elsc, pathsOut);
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -70,6 +70,22 @@ struct Eyeball : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(wpsc, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(texture1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(texture2, pathsOut);
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -33,6 +33,17 @@ struct FireFlea : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -58,6 +58,12 @@ struct FishCloud : IScriptObject
|
||||||
}
|
}
|
||||||
animationParameters.nameANCS(pakRouter, name + "_animp");
|
animationParameters.nameANCS(pakRouter, name + "_animp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(model, pathsOut);
|
||||||
|
animationParameters.depANCS(pathsOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -70,6 +70,24 @@ struct Flaahgra : IScriptObject
|
||||||
actorParameters2.nameIDs(pakRouter, name + "_actp2");
|
actorParameters2.nameIDs(pakRouter, name + "_actp2");
|
||||||
animationParameters.nameANCS(pakRouter, name + "_animp");
|
animationParameters.nameANCS(pakRouter, name + "_animp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(wpsc1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(wpsc2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(dependencyGroup, pathsOut);
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters1.depIDs(pathsOut);
|
||||||
|
actorParameters2.depIDs(pathsOut);
|
||||||
|
animationParameters.depANCS(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters1.scanIDs(scansOut);
|
||||||
|
actorParameters2.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -30,6 +30,17 @@ struct FlaahgraTentacle : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -34,6 +34,17 @@ struct FlickerBat : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -95,6 +95,24 @@ struct FlyingPirate : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(wpsc1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(wpsc2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(wpsc3, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle3, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle4, pathsOut);
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -40,6 +40,17 @@ struct Geemer : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -117,6 +117,26 @@ struct GunTurret : IScriptObject
|
||||||
animationParameters.nameANCS(pakRouter, name + "_animp");
|
animationParameters.nameANCS(pakRouter, name + "_animp");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath> &pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(unknown18, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(model, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle3, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle4, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle5, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle6, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle7, pathsOut);
|
||||||
|
animationParameters.depANCS(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -27,6 +27,11 @@ struct HUDMemo : IScriptObject
|
||||||
ent->name = name + "_message";
|
ent->name = name + "_message";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath> &pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(message, pathsOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,6 +2,7 @@
|
||||||
#define __DNAMP1_SCRIPTOBJECT_HPP
|
#define __DNAMP1_SCRIPTOBJECT_HPP
|
||||||
#include "../../DNACommon/DNACommon.hpp"
|
#include "../../DNACommon/DNACommon.hpp"
|
||||||
#include "../DNAMP1.hpp"
|
#include "../DNAMP1.hpp"
|
||||||
|
#include "../SAVW.hpp"
|
||||||
#include <stdio.h>
|
#include <stdio.h>
|
||||||
|
|
||||||
namespace DataSpec
|
namespace DataSpec
|
||||||
|
@ -27,10 +28,10 @@ struct IScriptObject : BigYAML
|
||||||
virtual ~IScriptObject() = default;
|
virtual ~IScriptObject() = default;
|
||||||
|
|
||||||
virtual void addCMDLRigPairs(PAKRouter<PAKBridge>&,
|
virtual void addCMDLRigPairs(PAKRouter<PAKBridge>&,
|
||||||
std::unordered_map<UniqueID32, std::pair<UniqueID32, UniqueID32>>&) const
|
std::unordered_map<UniqueID32, std::pair<UniqueID32, UniqueID32>>&) const {}
|
||||||
{
|
|
||||||
}
|
|
||||||
virtual void nameIDs(PAKRouter<PAKBridge>& pakRouter) const {}
|
virtual void nameIDs(PAKRouter<PAKBridge>& pakRouter) const {}
|
||||||
|
virtual void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const {}
|
||||||
|
virtual void gatherScans(std::vector<Scan>& scansOut) const {}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -111,6 +111,27 @@ struct IceSheegoth : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath> &pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(wpsc1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(wpsc2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle3, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle4, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle5, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(elsc, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(texture, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle6, pathsOut);
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -40,6 +40,17 @@ struct IceZoomer : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath> &pathsOut) const
|
||||||
|
{
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -44,6 +44,17 @@ struct JellyZap : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath> &pathsOut) const
|
||||||
|
{
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -74,6 +74,20 @@ struct Magdolite : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath> &pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(model, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(skin, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(magdoliteParameters.particle, pathsOut);
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -36,6 +36,17 @@ struct MetareeAlpha : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath> &pathsOut) const
|
||||||
|
{
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -48,6 +48,21 @@ struct MetroidAlpha : IScriptObject
|
||||||
animationParameters3.nameANCS(pakRouter, name + "_animp3");
|
animationParameters3.nameANCS(pakRouter, name + "_animp3");
|
||||||
animationParameters4.nameANCS(pakRouter, name + "_animp4");
|
animationParameters4.nameANCS(pakRouter, name + "_animp4");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath> &pathsOut) const
|
||||||
|
{
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
animationParameters1.depANCS(pathsOut);
|
||||||
|
animationParameters2.depANCS(pathsOut);
|
||||||
|
animationParameters3.depANCS(pathsOut);
|
||||||
|
animationParameters4.depANCS(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -72,6 +72,22 @@ struct MetroidBeta : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath> &pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(particle1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle3, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle4, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(swhc, pathsOut);
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -144,6 +144,13 @@ struct MetroidPrimeStage1 : IScriptObject
|
||||||
ent->name = name + "_unk4";
|
ent->name = name + "_unk4";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void depIDs(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(unknown1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(unknown3, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(unknown4, pathsOut);
|
||||||
|
}
|
||||||
} primeStruct5;
|
} primeStruct5;
|
||||||
Value<float> unknown14;
|
Value<float> unknown14;
|
||||||
DamageInfo damageInfo2;
|
DamageInfo damageInfo2;
|
||||||
|
@ -177,6 +184,16 @@ struct MetroidPrimeStage1 : IScriptObject
|
||||||
}
|
}
|
||||||
primeStruct5.nameIDs(pakRouter, name + "_prime5");
|
primeStruct5.nameIDs(pakRouter, name + "_prime5");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void depIDs(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(particle1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(texture1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(texture2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(wpsc, pathsOut);
|
||||||
|
primeStruct5.depIDs(pathsOut);
|
||||||
|
}
|
||||||
} primeStruct4_1, primeStruct4_2, primeStruct4_3, primeStruct4_4;
|
} primeStruct4_1, primeStruct4_2, primeStruct4_3, primeStruct4_4;
|
||||||
|
|
||||||
UniqueID32 wpsc1;
|
UniqueID32 wpsc1;
|
||||||
|
@ -287,6 +304,34 @@ struct MetroidPrimeStage1 : IScriptObject
|
||||||
primeStruct4_3.nameIDs(pakRouter, name + "_prime43");
|
primeStruct4_3.nameIDs(pakRouter, name + "_prime43");
|
||||||
primeStruct4_4.nameIDs(pakRouter, name + "_prime44");
|
primeStruct4_4.nameIDs(pakRouter, name + "_prime44");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void depIDs(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(particle1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle3, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle4, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle5, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle6, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle7, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle8, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(swhc, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(texture1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(texture2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(wpsc1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(wpsc2, pathsOut);
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
primeStruct4_1.depIDs(pathsOut);
|
||||||
|
primeStruct4_2.depIDs(pathsOut);
|
||||||
|
primeStruct4_3.depIDs(pathsOut);
|
||||||
|
primeStruct4_4.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void scanIDs(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
} massivePrimeStruct;
|
} massivePrimeStruct;
|
||||||
|
|
||||||
void addCMDLRigPairs(PAKRouter<PAKBridge>& pakRouter,
|
void addCMDLRigPairs(PAKRouter<PAKBridge>& pakRouter,
|
||||||
|
@ -300,6 +345,16 @@ struct MetroidPrimeStage1 : IScriptObject
|
||||||
{
|
{
|
||||||
massivePrimeStruct.nameIDs(pakRouter, name + "_massiveStruct");
|
massivePrimeStruct.nameIDs(pakRouter, name + "_massiveStruct");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath> &pathsOut) const
|
||||||
|
{
|
||||||
|
massivePrimeStruct.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
massivePrimeStruct.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -50,6 +50,20 @@ struct MetroidPrimeStage2 : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath> &pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(particle1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(elsc, pathsOut);
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -27,6 +27,11 @@ struct Midi : IScriptObject
|
||||||
ent->name = name + "_song";
|
ent->name = name + "_song";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath> &pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(song, pathsOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -57,6 +57,21 @@ struct NewIntroBoss : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath> &pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(particle1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(texture1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(texture2, pathsOut);
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -216,6 +216,17 @@ struct Oculus : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath> &pathsOut) const
|
||||||
|
{
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -134,6 +134,32 @@ struct OmegaPirate : IScriptObject
|
||||||
actorParameters2.nameIDs(pakRouter, name + "_actp2");
|
actorParameters2.nameIDs(pakRouter, name + "_actp2");
|
||||||
animationParameters.nameANCS(pakRouter, name + "_animp");
|
animationParameters.nameANCS(pakRouter, name + "_animp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath> &pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(particle1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle3, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle4, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle5, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle6, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle7, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(elsc, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(model1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(model2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(skin, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(rig, pathsOut);
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters1.depIDs(pathsOut);
|
||||||
|
actorParameters2.depIDs(pathsOut);
|
||||||
|
animationParameters.depANCS(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters1.scanIDs(scansOut);
|
||||||
|
actorParameters2.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,6 +3,7 @@
|
||||||
|
|
||||||
#include "../../DNACommon/DNACommon.hpp"
|
#include "../../DNACommon/DNACommon.hpp"
|
||||||
#include "../DNAMP1.hpp"
|
#include "../DNAMP1.hpp"
|
||||||
|
#include "../SAVW.hpp"
|
||||||
|
|
||||||
namespace DataSpec
|
namespace DataSpec
|
||||||
{
|
{
|
||||||
|
@ -68,7 +69,7 @@ enum class ESpecialFunctionType : atUint32
|
||||||
EndGame,
|
EndGame,
|
||||||
HUDFadeIn,
|
HUDFadeIn,
|
||||||
CinematicSkip,
|
CinematicSkip,
|
||||||
ScriptLyaerController,
|
ScriptLayerController,
|
||||||
RainSimulator,
|
RainSimulator,
|
||||||
AreaDamage,
|
AreaDamage,
|
||||||
ObjectFollowObject,
|
ObjectFollowObject,
|
||||||
|
@ -104,6 +105,11 @@ struct AnimationParameters : BigYAML
|
||||||
if (ancsEnt->name.empty())
|
if (ancsEnt->name.empty())
|
||||||
ancsEnt->name = name;
|
ancsEnt->name = name;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void depANCS(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(animationCharacterSet, pathsOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
struct BehaveChance : BigYAML
|
struct BehaveChance : BigYAML
|
||||||
|
@ -189,6 +195,11 @@ struct FlareDefinition : BigYAML
|
||||||
ent->name = name + "_texture";
|
ent->name = name + "_texture";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void depIDs(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(texture, pathsOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
struct GrappleParameters : BigYAML
|
struct GrappleParameters : BigYAML
|
||||||
|
@ -299,6 +310,14 @@ struct PatternedInfo : BigYAML
|
||||||
ent->name = name + "_part2";
|
ent->name = name + "_part2";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void depIDs(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
animationParameters.depANCS(pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(stateMachine, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle2, pathsOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
struct PlayerHintParameters : BigYAML
|
struct PlayerHintParameters : BigYAML
|
||||||
|
@ -336,6 +355,16 @@ struct ScannableParameters : BigYAML
|
||||||
scanEnt->name = name + "_scan";
|
scanEnt->name = name + "_scan";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void depIDs(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(scanId, pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void scanIDs(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
scansOut.emplace_back(scanId);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
struct VisorParameters : BigYAML
|
struct VisorParameters : BigYAML
|
||||||
|
@ -407,6 +436,20 @@ struct ActorParameters : BigYAML
|
||||||
xsEnt->name = name + "_thermalskin";
|
xsEnt->name = name + "_thermalskin";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void depIDs(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
scannableParameters.depIDs(pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(xrayModel, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(xraySkin, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(thermalModel, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(thermalSkin, pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void scanIDs(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
scannableParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -49,6 +49,17 @@ struct Parasite : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -38,6 +38,18 @@ struct PhazonHealingNodule : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(elsc, pathsOut);
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -54,6 +54,14 @@ struct PhazonPool : IScriptObject
|
||||||
ent->name = name + "_model2";
|
ent->name = name + "_model2";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(particle1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(model1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(model2, pathsOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -52,6 +52,19 @@ struct Pickup : IScriptObject
|
||||||
animationParameters.nameANCS(pakRouter, name + "_animp");
|
animationParameters.nameANCS(pakRouter, name + "_animp");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(particle, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(model, pathsOut);
|
||||||
|
animationParameters.depANCS(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -53,6 +53,19 @@ struct Platform : IScriptObject
|
||||||
animationParameters.nameANCS(pakRouter, name + "_animp");
|
animationParameters.nameANCS(pakRouter, name + "_animp");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(dcln, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(model, pathsOut);
|
||||||
|
animationParameters.depANCS(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -48,6 +48,18 @@ struct PlayerActor : IScriptObject
|
||||||
animationParameters.nameANCS(pakRouter, name + "_animp");
|
animationParameters.nameANCS(pakRouter, name + "_animp");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(model, pathsOut);
|
||||||
|
animationParameters.depANCS(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -23,6 +23,16 @@ struct PointOfInterest : IScriptObject
|
||||||
{
|
{
|
||||||
scannableParameters.nameIDs(pakRouter, name + "_scanp");
|
scannableParameters.nameIDs(pakRouter, name + "_scanp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
scannableParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
scannableParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -50,6 +50,19 @@ struct PuddleSpore : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(particle, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(wpsc, pathsOut);
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -46,6 +46,18 @@ struct PuddleToadGamma : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(dcln, pathsOut);
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -50,6 +50,19 @@ struct Puffer : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(particle, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(texture, pathsOut);
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -81,6 +81,14 @@ struct Ridley : IScriptObject
|
||||||
ent->name = name + "_tex2";
|
ent->name = name + "_tex2";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void depIDs(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(particle1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(texture1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(texture2, pathsOut);
|
||||||
|
}
|
||||||
} ridleyStruct1;
|
} ridleyStruct1;
|
||||||
|
|
||||||
Value<atUint32> soundID1;
|
Value<atUint32> soundID1;
|
||||||
|
@ -716,6 +724,36 @@ struct Ridley : IScriptObject
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
ridleyStruct1.nameIDs(pakRouter, name + "_ridley1");
|
ridleyStruct1.nameIDs(pakRouter, name + "_ridley1");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(particle, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(model1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(model2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(model3, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(model4, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(model5, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(model6, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(model7, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(model8, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(model9, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(model10, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(model11, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(model12, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(wpsc1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(wpsc2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(wpsc3, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(wpsc4, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(elsc, pathsOut);
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
ridleyStruct1.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -32,6 +32,17 @@ struct Ripper : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -61,6 +61,14 @@ struct ScriptBeam : IScriptObject
|
||||||
ent->name = name + "_tex2";
|
ent->name = name + "_tex2";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void depIDs(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(particle1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(texture1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(texture2, pathsOut);
|
||||||
|
}
|
||||||
} beamParametrs;
|
} beamParametrs;
|
||||||
DamageInfo damageInfo;
|
DamageInfo damageInfo;
|
||||||
|
|
||||||
|
@ -73,6 +81,12 @@ struct ScriptBeam : IScriptObject
|
||||||
}
|
}
|
||||||
beamParametrs.nameIDs(pakRouter, name + "_beamp");
|
beamParametrs.nameIDs(pakRouter, name + "_beamp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(wpsc, pathsOut);
|
||||||
|
beamParametrs.depIDs(pathsOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -48,6 +48,19 @@ struct Seedling : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(unknown1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(unknown2, pathsOut);
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -49,6 +49,17 @@ struct SnakeWeedSwarm : IScriptObject
|
||||||
animationParameters.nameANCS(pakRouter, name + "_animp");
|
animationParameters.nameANCS(pakRouter, name + "_animp");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
animationParameters.depANCS(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -70,6 +70,19 @@ struct SpacePirate : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(wpsc1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(wpsc2, pathsOut);
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -35,6 +35,17 @@ struct SpankWeed : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -34,6 +34,11 @@ struct Steam : IScriptObject
|
||||||
ent->name = name + "_texture";
|
ent->name = name + "_texture";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(texture, pathsOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -178,6 +178,26 @@ struct Thardus : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
for (int i=0 ; i<14 ; ++i)
|
||||||
|
g_curSpec->flattenDependencies(models[i], pathsOut);
|
||||||
|
for (int i=0 ; i<3 ; ++i)
|
||||||
|
g_curSpec->flattenDependencies(particles1[i], pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(stateMachine, pathsOut);
|
||||||
|
for (int i=0 ; i<6 ; ++i)
|
||||||
|
g_curSpec->flattenDependencies(particles2[i], pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(texture, pathsOut);
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -45,6 +45,19 @@ struct ThardusRockProjectile : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(model, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(stateMachine, pathsOut);
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -34,6 +34,17 @@ struct Tryclops : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -31,6 +31,12 @@ struct VisorFlare : IScriptObject
|
||||||
flareDefinitions[3].nameIDs(pakRouter, name + "_flare4");
|
flareDefinitions[3].nameIDs(pakRouter, name + "_flare4");
|
||||||
flareDefinitions[4].nameIDs(pakRouter, name + "_flare5");
|
flareDefinitions[4].nameIDs(pakRouter, name + "_flare5");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
for (int i=0 ; i<5 ; ++i)
|
||||||
|
flareDefinitions[i].depIDs(pathsOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -32,6 +32,11 @@ struct VisorGoo : IScriptObject
|
||||||
ent->name = name + "_part";
|
ent->name = name + "_part";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(particle, pathsOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -73,6 +73,19 @@ struct WallCrawlerSwarm : IScriptObject
|
||||||
animationParameters.nameANCS(pakRouter, name + "_animp");
|
animationParameters.nameANCS(pakRouter, name + "_animp");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(particle1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle2, pathsOut);
|
||||||
|
animationParameters.depANCS(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -47,6 +47,19 @@ struct Warwasp : IScriptObject
|
||||||
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
patternedInfo.nameIDs(pakRouter, name + "_patterned");
|
||||||
actorParameters.nameIDs(pakRouter, name + "_actp");
|
actorParameters.nameIDs(pakRouter, name + "_actp");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(wpsc1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle, pathsOut);
|
||||||
|
patternedInfo.depIDs(pathsOut);
|
||||||
|
actorParameters.depIDs(pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
void gatherScans(std::vector<Scan>& scansOut) const
|
||||||
|
{
|
||||||
|
actorParameters.scanIDs(scansOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -157,6 +157,22 @@ struct Water : IScriptObject
|
||||||
ent->name = name + "_part5";
|
ent->name = name + "_part5";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(texture1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(texture2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(texture3, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(texture4, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(texture5, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(texture6, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(texture34, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle3, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle4, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(particle5, pathsOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -321,6 +321,13 @@ struct WorldTeleporter : IScriptObject
|
||||||
ent->name = name + "_strg";
|
ent->name = name + "_strg";
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void gatherDependencies(std::vector<hecl::ProjectPath>& pathsOut) const
|
||||||
|
{
|
||||||
|
g_curSpec->flattenDependencies(model1, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(model2, pathsOut);
|
||||||
|
g_curSpec->flattenDependencies(strg, pathsOut);
|
||||||
|
}
|
||||||
};
|
};
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
|
@ -120,8 +120,6 @@ void PAKBridge::build()
|
||||||
areaName.read(rs);
|
areaName.read(rs);
|
||||||
}
|
}
|
||||||
areaDeps.name = areaName.getSystemString(FOURCC('ENGL'), 0);
|
areaDeps.name = areaName.getSystemString(FOURCC('ENGL'), 0);
|
||||||
|
|
||||||
/* Trim possible trailing whitespace */
|
|
||||||
areaDeps.name = hecl::StringUtils::TrimWhitespace(areaDeps.name);
|
areaDeps.name = hecl::StringUtils::TrimWhitespace(areaDeps.name);
|
||||||
}
|
}
|
||||||
if (areaDeps.name.empty())
|
if (areaDeps.name.empty())
|
||||||
|
@ -145,14 +143,7 @@ void PAKBridge::build()
|
||||||
Level::Area::Layer& layer = areaDeps.layers.back();
|
Level::Area::Layer& layer = areaDeps.layers.back();
|
||||||
layer.name = LayerName(mlvl.layerNames[layerIdx++]);
|
layer.name = LayerName(mlvl.layerNames[layerIdx++]);
|
||||||
layer.active = layerFlags.flags >> (l-1) & 0x1;
|
layer.active = layerFlags.flags >> (l-1) & 0x1;
|
||||||
/* Trim possible trailing whitespace */
|
layer.name = hecl::StringUtils::TrimWhitespace(layer.name);
|
||||||
#if HECL_UCS2
|
|
||||||
while (layer.name.size() && iswspace(layer.name.back()))
|
|
||||||
layer.name.pop_back();
|
|
||||||
#else
|
|
||||||
while (layer.name.size() && isspace(layer.name.back()))
|
|
||||||
layer.name.pop_back();
|
|
||||||
#endif
|
|
||||||
hecl::SNPrintf(num, 16, _S("%02u "), l-1);
|
hecl::SNPrintf(num, 16, _S("%02u "), l-1);
|
||||||
layer.name = num + layer.name;
|
layer.name = num + layer.name;
|
||||||
|
|
||||||
|
|
|
@ -126,8 +126,6 @@ void PAKBridge::build()
|
||||||
areaName.read(rs);
|
areaName.read(rs);
|
||||||
}
|
}
|
||||||
areaDeps.name = areaName.getSystemString(FOURCC('ENGL'), 0);
|
areaDeps.name = areaName.getSystemString(FOURCC('ENGL'), 0);
|
||||||
|
|
||||||
/* Trim possible trailing whitespace */
|
|
||||||
areaDeps.name = hecl::StringUtils::TrimWhitespace(areaDeps.name);
|
areaDeps.name = hecl::StringUtils::TrimWhitespace(areaDeps.name);
|
||||||
}
|
}
|
||||||
if (areaDeps.name.empty())
|
if (areaDeps.name.empty())
|
||||||
|
@ -153,14 +151,7 @@ void PAKBridge::build()
|
||||||
Level::Area::Layer& layer = areaDeps.layers.back();
|
Level::Area::Layer& layer = areaDeps.layers.back();
|
||||||
layer.name = LayerName(mlvl.layerNames[layerIdx++]);
|
layer.name = LayerName(mlvl.layerNames[layerIdx++]);
|
||||||
layer.active = layerFlags.flags >> (l-1) & 0x1;
|
layer.active = layerFlags.flags >> (l-1) & 0x1;
|
||||||
/* Trim possible trailing whitespace */
|
layer.name = hecl::StringUtils::TrimWhitespace(layer.name);
|
||||||
#if HECL_UCS2
|
|
||||||
while (layer.name.size() && iswspace(layer.name.back()))
|
|
||||||
layer.name.pop_back();
|
|
||||||
#else
|
|
||||||
while (layer.name.size() && isspace(layer.name.back()))
|
|
||||||
layer.name.pop_back();
|
|
||||||
#endif
|
|
||||||
hecl::SNPrintf(num, 16, _S("%02u "), l-1);
|
hecl::SNPrintf(num, 16, _S("%02u "), l-1);
|
||||||
layer.name = num + layer.name;
|
layer.name = num + layer.name;
|
||||||
}
|
}
|
||||||
|
|
|
@ -288,16 +288,97 @@ void SpecBase::doCook(const hecl::ProjectPath& path, const hecl::ProjectPath& co
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void SpecBase::flattenDependencies(const hecl::ProjectPath& path,
|
||||||
|
std::vector<hecl::ProjectPath>& pathsOut,
|
||||||
|
hecl::BlenderToken& btok)
|
||||||
|
{
|
||||||
|
DataSpec::g_curSpec.reset(this);
|
||||||
|
|
||||||
|
hecl::ProjectPath asBlend;
|
||||||
|
if (path.getPathType() == hecl::ProjectPath::Type::Glob)
|
||||||
|
asBlend = path.getWithExtension(_S(".blend"), true);
|
||||||
|
else
|
||||||
|
asBlend = path;
|
||||||
|
|
||||||
|
if (hecl::IsPathBlend(asBlend))
|
||||||
|
{
|
||||||
|
hecl::BlenderConnection& conn = btok.getBlenderConnection();
|
||||||
|
if (!conn.openBlend(asBlend))
|
||||||
|
return;
|
||||||
|
switch (conn.getBlendType())
|
||||||
|
{
|
||||||
|
case hecl::BlenderConnection::BlendType::Mesh:
|
||||||
|
{
|
||||||
|
hecl::BlenderConnection::DataStream ds = conn.beginData();
|
||||||
|
std::vector<hecl::ProjectPath> texs = ds.getTextures();
|
||||||
|
for (const hecl::ProjectPath& tex : texs)
|
||||||
|
pathsOut.push_back(tex);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
case hecl::BlenderConnection::BlendType::Actor:
|
||||||
|
{
|
||||||
|
hecl::BlenderConnection::DataStream ds = conn.beginData();
|
||||||
|
hecl::BlenderConnection::DataStream::Actor actor = ds.compileActor();
|
||||||
|
for (auto& sub : actor.subtypes)
|
||||||
|
{
|
||||||
|
if (sub.armature >= 0)
|
||||||
|
{
|
||||||
|
pathsOut.push_back(sub.mesh);
|
||||||
|
|
||||||
|
hecl::SystemStringView chSysName(sub.name);
|
||||||
|
pathsOut.push_back(path.ensureAuxInfo(chSysName.sys_str() + _S(".CSKR")));
|
||||||
|
|
||||||
|
const auto& arm = actor.armatures[sub.armature];
|
||||||
|
hecl::SystemStringView armSysName(arm.name);
|
||||||
|
pathsOut.push_back(path.ensureAuxInfo(armSysName.sys_str() + _S(".CINF")));
|
||||||
|
if (sub.overlayMeshes.size())
|
||||||
|
{
|
||||||
|
pathsOut.push_back(sub.overlayMeshes[0].second);
|
||||||
|
pathsOut.push_back(path.ensureAuxInfo(chSysName.sys_str() + _S(".over.CSKR")));
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
case hecl::BlenderConnection::BlendType::Area:
|
||||||
|
{
|
||||||
|
hecl::BlenderConnection::DataStream ds = conn.beginData();
|
||||||
|
std::vector<hecl::ProjectPath> texs = ds.getTextures();
|
||||||
|
for (const hecl::ProjectPath& tex : texs)
|
||||||
|
pathsOut.push_back(tex);
|
||||||
|
break;
|
||||||
|
}
|
||||||
|
default: break;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else if (hecl::IsPathYAML(path))
|
||||||
|
{
|
||||||
|
athena::io::FileReader reader(path.getAbsolutePath());
|
||||||
|
flattenDependenciesYAML(reader, pathsOut);
|
||||||
|
}
|
||||||
|
|
||||||
|
pathsOut.push_back(path);
|
||||||
|
}
|
||||||
|
|
||||||
|
void SpecBase::flattenDependencies(const UniqueID32& id, std::vector<hecl::ProjectPath>& pathsOut)
|
||||||
|
{
|
||||||
|
hecl::ProjectPath path = UniqueIDBridge::TranslatePakIdToPath(id);
|
||||||
|
if (path)
|
||||||
|
flattenDependencies(path, pathsOut, hecl::SharedBlenderToken);
|
||||||
|
}
|
||||||
|
|
||||||
|
void SpecBase::flattenDependencies(const UniqueID64& id, std::vector<hecl::ProjectPath>& pathsOut)
|
||||||
|
{
|
||||||
|
hecl::ProjectPath path = UniqueIDBridge::TranslatePakIdToPath(id);
|
||||||
|
if (path)
|
||||||
|
flattenDependencies(path, pathsOut, hecl::SharedBlenderToken);
|
||||||
|
}
|
||||||
|
|
||||||
bool SpecBase::canPackage(const PackagePassInfo& info)
|
bool SpecBase::canPackage(const PackagePassInfo& info)
|
||||||
{
|
{
|
||||||
return false;
|
return false;
|
||||||
}
|
}
|
||||||
|
|
||||||
void SpecBase::gatherDependencies(const PackagePassInfo& info,
|
|
||||||
std::unordered_set<hecl::ProjectPath>& implicitsOut)
|
|
||||||
{
|
|
||||||
}
|
|
||||||
|
|
||||||
void SpecBase::doPackage(const PackagePassInfo& info)
|
void SpecBase::doPackage(const PackagePassInfo& info)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
|
@ -7,6 +7,11 @@
|
||||||
#include <nod/nod.hpp>
|
#include <nod/nod.hpp>
|
||||||
#include "hecl/Blender/BlenderConnection.hpp"
|
#include "hecl/Blender/BlenderConnection.hpp"
|
||||||
|
|
||||||
|
namespace urde
|
||||||
|
{
|
||||||
|
struct SObjectTag;
|
||||||
|
}
|
||||||
|
|
||||||
namespace DataSpec
|
namespace DataSpec
|
||||||
{
|
{
|
||||||
|
|
||||||
|
@ -25,8 +30,6 @@ struct SpecBase : hecl::Database::IDataSpec
|
||||||
bool fast, hecl::BlenderToken& btok, FCookProgress progress);
|
bool fast, hecl::BlenderToken& btok, FCookProgress progress);
|
||||||
|
|
||||||
bool canPackage(const PackagePassInfo& info);
|
bool canPackage(const PackagePassInfo& info);
|
||||||
void gatherDependencies(const PackagePassInfo& info,
|
|
||||||
std::unordered_set<hecl::ProjectPath>& implicitsOut);
|
|
||||||
void doPackage(const PackagePassInfo& info);
|
void doPackage(const PackagePassInfo& info);
|
||||||
|
|
||||||
/* Extract handlers */
|
/* Extract handlers */
|
||||||
|
@ -42,6 +45,10 @@ struct SpecBase : hecl::Database::IDataSpec
|
||||||
virtual bool extractFromDisc(nod::DiscBase& disc, bool force,
|
virtual bool extractFromDisc(nod::DiscBase& disc, bool force,
|
||||||
FProgress progress)=0;
|
FProgress progress)=0;
|
||||||
|
|
||||||
|
/* Convert path to object tag */
|
||||||
|
virtual urde::SObjectTag BuildTagFromPath(const hecl::ProjectPath& path,
|
||||||
|
hecl::BlenderToken& btok) const=0;
|
||||||
|
|
||||||
/* Even if PC spec is being cooked, this will return the vanilla GCN spec */
|
/* Even if PC spec is being cooked, this will return the vanilla GCN spec */
|
||||||
virtual const hecl::Database::DataSpecEntry* getOriginalSpec() const=0;
|
virtual const hecl::Database::DataSpecEntry* getOriginalSpec() const=0;
|
||||||
|
|
||||||
|
@ -77,6 +84,14 @@ struct SpecBase : hecl::Database::IDataSpec
|
||||||
virtual void cookSong(const hecl::ProjectPath& out, const hecl::ProjectPath& in,
|
virtual void cookSong(const hecl::ProjectPath& out, const hecl::ProjectPath& in,
|
||||||
FCookProgress progress)=0;
|
FCookProgress progress)=0;
|
||||||
|
|
||||||
|
/* Dependency flatteners */
|
||||||
|
void flattenDependencies(const hecl::ProjectPath& in,
|
||||||
|
std::vector<hecl::ProjectPath>& pathsOut,
|
||||||
|
hecl::BlenderToken& btok);
|
||||||
|
void flattenDependencies(const class UniqueID32& id, std::vector<hecl::ProjectPath>& pathsOut);
|
||||||
|
void flattenDependencies(const class UniqueID64& id, std::vector<hecl::ProjectPath>& pathsOut);
|
||||||
|
virtual void flattenDependenciesYAML(athena::io::IStreamReader& fin, std::vector<hecl::ProjectPath>& pathsOut)=0;
|
||||||
|
|
||||||
const hecl::ProjectPath& getMasterShaderPath() const {return m_masterShader;}
|
const hecl::ProjectPath& getMasterShaderPath() const {return m_masterShader;}
|
||||||
|
|
||||||
/* Support functions for resolving paths from IDs */
|
/* Support functions for resolving paths from IDs */
|
||||||
|
|
|
@ -373,6 +373,158 @@ struct SpecMP1 : SpecBase
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
urde::SObjectTag BuildTagFromPath(const hecl::ProjectPath& path, hecl::BlenderToken& btok) const
|
||||||
|
{
|
||||||
|
if (hecl::StringUtils::EndsWith(path.getAuxInfo(), _S(".CINF")))
|
||||||
|
return {SBIG('CINF'), path.hash().val32()};
|
||||||
|
else if (hecl::StringUtils::EndsWith(path.getAuxInfo(), _S(".CSKR")))
|
||||||
|
return {SBIG('CSKR'), path.hash().val32()};
|
||||||
|
else if (hecl::StringUtils::EndsWith(path.getAuxInfo(), _S(".ANIM")))
|
||||||
|
return {SBIG('ANIM'), path.hash().val32()};
|
||||||
|
|
||||||
|
hecl::ProjectPath asBlend;
|
||||||
|
if (path.getPathType() == hecl::ProjectPath::Type::Glob)
|
||||||
|
asBlend = path.getWithExtension(_S(".blend"), true);
|
||||||
|
else
|
||||||
|
asBlend = path;
|
||||||
|
|
||||||
|
if (hecl::IsPathBlend(asBlend))
|
||||||
|
{
|
||||||
|
hecl::BlenderConnection& conn = btok.getBlenderConnection();
|
||||||
|
if (!conn.openBlend(asBlend))
|
||||||
|
return {};
|
||||||
|
|
||||||
|
switch (conn.getBlendType())
|
||||||
|
{
|
||||||
|
case hecl::BlenderConnection::BlendType::Mesh:
|
||||||
|
return {SBIG('CMDL'), path.hash().val32()};
|
||||||
|
case hecl::BlenderConnection::BlendType::Actor:
|
||||||
|
if (path.getAuxInfo().size())
|
||||||
|
{
|
||||||
|
if (hecl::StringUtils::EndsWith(path.getAuxInfo(), _S(".CINF")))
|
||||||
|
return {SBIG('CINF'), path.hash().val32()};
|
||||||
|
else if (hecl::StringUtils::EndsWith(path.getAuxInfo(), _S(".CSKR")))
|
||||||
|
return {SBIG('CSKR'), path.hash().val32()};
|
||||||
|
else if (hecl::StringUtils::EndsWith(path.getAuxInfo(), _S(".ANIM")))
|
||||||
|
return {SBIG('ANIM'), path.hash().val32()};
|
||||||
|
}
|
||||||
|
return {SBIG('ANCS'), path.hash().val32()};
|
||||||
|
case hecl::BlenderConnection::BlendType::Area:
|
||||||
|
return {SBIG('MREA'), path.hash().val32()};
|
||||||
|
case hecl::BlenderConnection::BlendType::World:
|
||||||
|
{
|
||||||
|
if (path.getAuxInfo().size())
|
||||||
|
{
|
||||||
|
if (hecl::StringUtils::EndsWith(path.getAuxInfo(), _S(".MAPW")))
|
||||||
|
return {SBIG('MAPW'), path.hash().val32()};
|
||||||
|
else if (hecl::StringUtils::EndsWith(path.getAuxInfo(), _S(".SAVW")))
|
||||||
|
return {SBIG('SAVW'), path.hash().val32()};
|
||||||
|
}
|
||||||
|
return {SBIG('MLVL'), path.hash().val32()};
|
||||||
|
}
|
||||||
|
case hecl::BlenderConnection::BlendType::MapArea:
|
||||||
|
return {SBIG('MAPA'), path.hash().val32()};
|
||||||
|
case hecl::BlenderConnection::BlendType::MapUniverse:
|
||||||
|
return {SBIG('MAPU'), path.hash().val32()};
|
||||||
|
case hecl::BlenderConnection::BlendType::Frame:
|
||||||
|
return {SBIG('FRME'), path.hash().val32()};
|
||||||
|
default:
|
||||||
|
return {};
|
||||||
|
}
|
||||||
|
}
|
||||||
|
else if (hecl::IsPathPNG(path))
|
||||||
|
{
|
||||||
|
return {SBIG('TXTR'), path.hash().val32()};
|
||||||
|
}
|
||||||
|
else if (hecl::IsPathYAML(path))
|
||||||
|
{
|
||||||
|
FILE* fp = hecl::Fopen(path.getAbsolutePath().c_str(), _S("r"));
|
||||||
|
if (!fp)
|
||||||
|
return {};
|
||||||
|
|
||||||
|
athena::io::YAMLDocReader reader;
|
||||||
|
yaml_parser_set_input_file(reader.getParser(), fp);
|
||||||
|
|
||||||
|
urde::SObjectTag resTag;
|
||||||
|
if (reader.ClassTypeOperation([&](const char* className) -> bool
|
||||||
|
{
|
||||||
|
if (!strcmp(className, "GPSM"))
|
||||||
|
{
|
||||||
|
resTag.type = SBIG('PART');
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
if (!strcmp(className, "SWSH"))
|
||||||
|
{
|
||||||
|
resTag.type = SBIG('SWHC');
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
if (!strcmp(className, "ELSM"))
|
||||||
|
{
|
||||||
|
resTag.type = SBIG('ELSC');
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
if (!strcmp(className, "WPSM"))
|
||||||
|
{
|
||||||
|
resTag.type = SBIG('WPSC');
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
if (!strcmp(className, "CRSM"))
|
||||||
|
{
|
||||||
|
resTag.type = SBIG('CRSC');
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
if (!strcmp(className, "DPSM"))
|
||||||
|
{
|
||||||
|
resTag.type = SBIG('DPSC');
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
else if (!strcmp(className, "FONT"))
|
||||||
|
{
|
||||||
|
resTag.type = SBIG('FONT');
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
else if (!strcmp(className, "urde::DNAMP1::EVNT"))
|
||||||
|
{
|
||||||
|
resTag.type = SBIG('EVNT');
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
else if (!strcmp(className, "urde::DGRP"))
|
||||||
|
{
|
||||||
|
resTag.type = SBIG('DGRP');
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
else if (!strcmp(className, "urde::DNAMP1::STRG"))
|
||||||
|
{
|
||||||
|
resTag.type = SBIG('STRG');
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
else if (!strcmp(className, "DataSpec::DNAMP1::CTweakPlayerRes") ||
|
||||||
|
!strcmp(className, "DataSpec::DNAMP1::CTweakGunRes") ||
|
||||||
|
!strcmp(className, "DataSpec::DNAMP1::CTweakSlideShow") ||
|
||||||
|
!strcmp(className, "DataSpec::DNAMP1::CTweakPlayer") ||
|
||||||
|
!strcmp(className, "DataSpec::DNAMP1::CTweakCameraBob"))
|
||||||
|
{
|
||||||
|
resTag.type = SBIG('CTWK');
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
else if (!strcmp(className, "DataSpec::DNAMP1::HINT"))
|
||||||
|
{
|
||||||
|
resTag.type = SBIG('HINT');
|
||||||
|
return true;
|
||||||
|
}
|
||||||
|
|
||||||
|
return false;
|
||||||
|
}))
|
||||||
|
{
|
||||||
|
resTag.id = path.hash().val32();
|
||||||
|
fclose(fp);
|
||||||
|
return resTag;
|
||||||
|
}
|
||||||
|
fclose(fp);
|
||||||
|
}
|
||||||
|
return {};
|
||||||
|
}
|
||||||
|
|
||||||
void cookMesh(const hecl::ProjectPath& out, const hecl::ProjectPath& in,
|
void cookMesh(const hecl::ProjectPath& out, const hecl::ProjectPath& in,
|
||||||
BlendStream& ds, bool fast, hecl::BlenderToken& btok,
|
BlendStream& ds, bool fast, hecl::BlenderToken& btok,
|
||||||
FCookProgress progress)
|
FCookProgress progress)
|
||||||
|
@ -554,6 +706,66 @@ struct SpecMP1 : SpecBase
|
||||||
progress(_S("Done"));
|
progress(_S("Done"));
|
||||||
}
|
}
|
||||||
|
|
||||||
|
void flattenDependenciesYAML(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.empty())
|
||||||
|
return;
|
||||||
|
|
||||||
|
if (!classStr.compare(DNAMP1::STRG::DNAType()))
|
||||||
|
{
|
||||||
|
DNAMP1::STRG strg;
|
||||||
|
strg.read(reader);
|
||||||
|
strg.gatherDependencies(pathsOut);
|
||||||
|
}
|
||||||
|
else if (!classStr.compare(DNAParticle::GPSM<UniqueID32>::DNAType()))
|
||||||
|
{
|
||||||
|
DNAParticle::GPSM<UniqueID32> gpsm;
|
||||||
|
gpsm.read(reader);
|
||||||
|
gpsm.gatherDependencies(pathsOut);
|
||||||
|
}
|
||||||
|
else if (!classStr.compare(DNAParticle::SWSH<UniqueID32>::DNAType()))
|
||||||
|
{
|
||||||
|
DNAParticle::SWSH<UniqueID32> swsh;
|
||||||
|
swsh.read(reader);
|
||||||
|
swsh.gatherDependencies(pathsOut);
|
||||||
|
}
|
||||||
|
else if (!classStr.compare(DNAParticle::ELSM<UniqueID32>::DNAType()))
|
||||||
|
{
|
||||||
|
DNAParticle::ELSM<UniqueID32> elsm;
|
||||||
|
elsm.read(reader);
|
||||||
|
elsm.gatherDependencies(pathsOut);
|
||||||
|
}
|
||||||
|
else if (!classStr.compare(DNAParticle::WPSM<UniqueID32>::DNAType()))
|
||||||
|
{
|
||||||
|
DNAParticle::WPSM<UniqueID32> wpsm;
|
||||||
|
wpsm.read(reader);
|
||||||
|
wpsm.gatherDependencies(pathsOut);
|
||||||
|
}
|
||||||
|
else if (!classStr.compare(DNAParticle::CRSM<UniqueID32>::DNAType()))
|
||||||
|
{
|
||||||
|
DNAParticle::CRSM<UniqueID32> crsm;
|
||||||
|
crsm.read(reader);
|
||||||
|
crsm.gatherDependencies(pathsOut);
|
||||||
|
}
|
||||||
|
else if (!classStr.compare(DNAParticle::DPSM<UniqueID32>::DNAType()))
|
||||||
|
{
|
||||||
|
DNAParticle::DPSM<UniqueID32> dpsm;
|
||||||
|
dpsm.read(reader);
|
||||||
|
dpsm.gatherDependencies(pathsOut);
|
||||||
|
}
|
||||||
|
else if (!classStr.compare(DNAFont::FONT<UniqueID32>::DNAType()))
|
||||||
|
{
|
||||||
|
DNAFont::FONT<UniqueID32> font;
|
||||||
|
font.read(reader);
|
||||||
|
font.gatherDependencies(pathsOut);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
void cookAudioGroup(const hecl::ProjectPath& out, const hecl::ProjectPath& in,
|
void cookAudioGroup(const hecl::ProjectPath& out, const hecl::ProjectPath& in,
|
||||||
FCookProgress progress)
|
FCookProgress progress)
|
||||||
{
|
{
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue