mirror of
https://gitlab.com/OpenMW/openmw.git
synced 2025-01-06 00:55:50 +00:00
Read NiMultiTargetTransformController
This commit is contained in:
parent
8df0587793
commit
44fbb5cdc3
@ -180,6 +180,23 @@ namespace Nif
|
||||
interpolator.post(nif);
|
||||
}
|
||||
|
||||
void NiMultiTargetTransformController::read(NIFStream *nif)
|
||||
{
|
||||
Controller::read(nif);
|
||||
size_t numTargets = nif->getUShort();
|
||||
std::vector<NodePtr> targets;
|
||||
targets.resize(numTargets);
|
||||
for (size_t i = 0; i < targets.size(); i++)
|
||||
targets[i].read(nif);
|
||||
mExtraTargets = targets;
|
||||
}
|
||||
|
||||
void NiMultiTargetTransformController::post(NIFFile *nif)
|
||||
{
|
||||
Controller::post(nif);
|
||||
mExtraTargets.post(nif);
|
||||
}
|
||||
|
||||
void NiFloatInterpController::read(NIFStream *nif)
|
||||
{
|
||||
Controller::read(nif);
|
||||
|
@ -148,6 +148,14 @@ struct NiKeyframeController : public Controller
|
||||
void post(NIFFile *nif) override;
|
||||
};
|
||||
|
||||
struct NiMultiTargetTransformController : public Controller
|
||||
{
|
||||
NodeList mExtraTargets;
|
||||
|
||||
void read(NIFStream *nif) override;
|
||||
void post(NIFFile *nif) override;
|
||||
};
|
||||
|
||||
struct NiFloatInterpController : public Controller
|
||||
{
|
||||
NiFloatDataPtr data;
|
||||
|
@ -137,6 +137,7 @@ static std::map<std::string, CreateRecord> makeFactory()
|
||||
{"NiBoolInterpolator" , &construct <NiBoolInterpolator , RC_NiBoolInterpolator >},
|
||||
{"NiPoint3Interpolator" , &construct <NiPoint3Interpolator , RC_NiPoint3Interpolator >},
|
||||
{"NiTransformController" , &construct <NiKeyframeController , RC_NiKeyframeController >},
|
||||
{"NiMultiTargetTransformController" , &construct <NiMultiTargetTransformController , RC_NiMultiTargetTransformController >},
|
||||
{"NiTransformInterpolator" , &construct <NiTransformInterpolator , RC_NiTransformInterpolator >},
|
||||
{"NiColorInterpolator" , &construct <NiColorInterpolator , RC_NiColorInterpolator >},
|
||||
{"BSShaderTextureSet" , &construct <BSShaderTextureSet , RC_BSShaderTextureSet >},
|
||||
|
@ -144,7 +144,8 @@ enum RecordType
|
||||
RC_BSLightingShaderProperty,
|
||||
RC_NiClusterAccumulator,
|
||||
RC_NiAlphaAccumulator,
|
||||
RC_NiSortAdjustNode
|
||||
RC_NiSortAdjustNode,
|
||||
RC_NiMultiTargetTransformController
|
||||
};
|
||||
|
||||
/// Base class for all records
|
||||
|
Loading…
Reference in New Issue
Block a user