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

ANCS stubs and initial readers

This commit is contained in:
Jack Andersen
2016-04-10 11:22:59 -10:00
parent 457ee8f3af
commit fc6cb2ec33
64 changed files with 1073 additions and 2 deletions

View File

@@ -0,0 +1,33 @@
#include "CMetaAnimFactory.hpp"
#include "CMetaAnimPlay.hpp"
#include "CMetaAnimBlend.hpp"
#include "CMetaAnimPhaseBlend.hpp"
#include "CMetaAnimRandom.hpp"
#include "CMetaAnimSequence.hpp"
namespace urde
{
std::shared_ptr<IMetaAnim> CMetaAnimFactory::CreateMetaAnim(CInputStream& in)
{
EMetaAnimType type = EMetaAnimType(in.readUint32Big());
switch (type)
{
case EMetaAnimType::Primitive:
return std::make_shared<CMetaAnimPlay>(in);
case EMetaAnimType::Blend:
return std::make_shared<CMetaAnimBlend>(in);
case EMetaAnimType::PhaseBlend:
return std::make_shared<CMetaAnimPhaseBlend>(in);
case EMetaAnimType::Random:
return std::make_shared<CMetaAnimRandom>(in);
case EMetaAnimType::Sequence:
return std::make_shared<CMetaAnimSequence>(in);
default: break;
}
return {};
}
}