2019-06-11 08:59:28 +02:00
|
|
|
#pragma once
|
|
|
|
|
|
|
|
#include "AnimBlendList.h"
|
|
|
|
|
|
|
|
|
|
|
|
struct AnimBlendFrameData
|
|
|
|
{
|
|
|
|
enum {
|
|
|
|
IGNORE_ROTATION = 2,
|
|
|
|
IGNORE_TRANSLATION = 4,
|
|
|
|
VELOCITY_EXTRACTION = 8,
|
|
|
|
VELOCITY_EXTRACTION_3D = 0x10,
|
|
|
|
};
|
|
|
|
|
|
|
|
uint8 flag;
|
|
|
|
RwV3d resetPos;
|
|
|
|
#ifdef PED_SKIN
|
|
|
|
union {
|
|
|
|
RwFrame *frame;
|
2020-07-24 23:28:55 +02:00
|
|
|
RpHAnimStdInterpFrame *hanimFrame;
|
2019-06-11 08:59:28 +02:00
|
|
|
};
|
|
|
|
int32 nodeID;
|
|
|
|
#else
|
|
|
|
RwFrame *frame;
|
|
|
|
#endif
|
|
|
|
};
|
|
|
|
#ifndef PED_SKIN
|
2020-05-10 17:49:33 +02:00
|
|
|
VALIDATE_SIZE(AnimBlendFrameData, 0x14);
|
2019-06-11 08:59:28 +02:00
|
|
|
#endif
|
|
|
|
|
|
|
|
|
|
|
|
class CAnimBlendClumpData
|
|
|
|
{
|
|
|
|
public:
|
|
|
|
CAnimBlendLink link;
|
|
|
|
int32 numFrames;
|
|
|
|
#ifdef PED_SKIN
|
|
|
|
int32 modelNumber; // doesn't seem to be used
|
|
|
|
#endif
|
2021-01-13 13:06:31 +01:00
|
|
|
union {
|
|
|
|
CVector2D *velocity2d;
|
|
|
|
CVector *velocity3d;
|
|
|
|
};
|
2019-06-11 08:59:28 +02:00
|
|
|
// order of frames is determined by RW hierarchy
|
|
|
|
AnimBlendFrameData *frames;
|
|
|
|
|
|
|
|
CAnimBlendClumpData(void);
|
|
|
|
~CAnimBlendClumpData(void);
|
|
|
|
void SetNumberOfFrames(int n);
|
|
|
|
#ifdef PED_SKIN
|
|
|
|
void SetNumberOfBones(int n) { SetNumberOfFrames(n); }
|
|
|
|
#endif
|
|
|
|
void ForAllFrames(void (*cb)(AnimBlendFrameData*, void*), void *arg);
|
|
|
|
};
|
2020-04-23 22:25:18 +02:00
|
|
|
#ifndef PED_SKIN
|
2020-05-10 17:49:33 +02:00
|
|
|
VALIDATE_SIZE(CAnimBlendClumpData, 0x14);
|
2020-04-23 22:25:18 +02:00
|
|
|
#endif
|