metaforce/DataSpec/DNAMP1/ScriptObjects/Parameters.cpp

20 lines
528 B
C++
Raw Normal View History

2015-11-10 02:07:15 +00:00
#include "Parameters.hpp"
#include "../ANCS.hpp"
2018-12-08 05:30:43 +00:00
namespace DataSpec::DNAMP1 {
2015-11-10 02:07:15 +00:00
2018-12-08 05:30:43 +00:00
UniqueID32 AnimationParameters::getCINF(PAKRouter<PAKBridge>& pakRouter) const {
2019-07-20 04:27:21 +00:00
if (!animationCharacterSet.isValid())
2018-12-08 05:30:43 +00:00
return UniqueID32();
const nod::Node* node;
const PAK::Entry* ancsEnt = pakRouter.lookupEntry(animationCharacterSet, &node);
ANCS ancs;
{
PAKEntryReadStream rs = ancsEnt->beginReadStream(*node);
ancs.read(rs);
}
return ancs.characterSet.characters.at(character).cinf;
2016-04-07 03:40:25 +00:00
}
2015-11-10 02:07:15 +00:00
2018-12-08 05:30:43 +00:00
} // namespace DataSpec::DNAMP1