2
0
mirror of https://github.com/AxioDL/metaforce.git synced 2025-05-13 22:31:21 +00:00
metaforce/Runtime/Character/CMetaAnimPlay.cpp
Lioncash 1cb289f243 RuntimeCommon: Normalize cpp inclusions
Normalizes the headers for the cpp files in the RuntimeCommon target.
Now all headers and source files within the RuntimeCommon/RuntimeCommonB
targets are normalized and consistent with one another.
2020-01-15 09:15:47 -05:00

26 lines
1.1 KiB
C++

#include "Runtime/Character/CMetaAnimPlay.hpp"
#include "Runtime/CSimplePool.hpp"
#include "Runtime/Character/CAllFormatsAnimSource.hpp"
#include "Runtime/Character/CAnimSysContext.hpp"
#include "Runtime/Character/CAnimTreeAnimReaderContainer.hpp"
namespace urde {
CMetaAnimPlay::CMetaAnimPlay(CInputStream& in) : x4_primitive(in), x1c_startTime(in) {}
void CMetaAnimPlay::GetUniquePrimitives(std::set<CPrimitive>& primsOut) const { primsOut.insert(x4_primitive); }
std::shared_ptr<CAnimTreeNode> CMetaAnimPlay::VGetAnimationTree(const CAnimSysContext& animSys,
const CMetaAnimTreeBuildOrders& orders) const {
if (orders.x0_recursiveAdvance)
return GetAnimationTree(animSys, CMetaAnimTreeBuildOrders::PreAdvanceForAll(*orders.x0_recursiveAdvance));
TLockedToken<CAllFormatsAnimSource> prim =
animSys.xc_store.GetObj(SObjectTag{FOURCC('ANIM'), x4_primitive.GetAnimResId()});
return std::make_shared<CAnimTreeAnimReaderContainer>(
x4_primitive.GetName(), CAllFormatsAnimSource::GetNewReader(prim, x1c_startTime), x4_primitive.GetAnimDbIdx());
}
} // namespace urde