This commit is contained in:
Phillip Stephens 2021-06-11 23:45:27 -07:00
parent 3be5b38f82
commit a525c57278
Signed by: Antidote
GPG Key ID: F8BEE4C83DACA60D
7 changed files with 10 additions and 5 deletions

View File

@ -107,6 +107,7 @@ REAL_ENTRY('ADV5', x11c_ADV5)
REAL_ENTRY('ADV6', x120_ADV6)
REAL_ENTRY('ADV7', x124_ADV7)
REAL_ENTRY('ADV8', x128_ADV8)
REAL_ENTRY('ADV9', x164_ADV9) // Added in MP3
BOOL_ENTRY('SORT', x44_28_SORT, false)
BOOL_ENTRY('MBLR', x44_30_MBLR, false)

View File

@ -363,7 +363,7 @@ void CElementGen::UpdateAdvanceAccessParameters(u32 activeParticleCount, s32 par
x60_advValues.size());
}
std::array<float, 8>& arr = x60_advValues[activeParticleCount];
std::array<float, 9>& arr = x60_advValues[activeParticleCount];
CParticleGlobals::instance()->m_particleAccessParameters = &arr;
if (CRealElement* adv1 = desc->x10c_ADV1.get()) {
@ -390,6 +390,9 @@ void CElementGen::UpdateAdvanceAccessParameters(u32 activeParticleCount, s32 par
if (CRealElement* adv8 = desc->x128_ADV8.get()) {
adv8->GetValue(particleFrame, arr[7]);
}
if (CRealElement* adv9 = desc->x164_ADV9.get()) {
adv9->GetValue(particleFrame, arr[8]);
}
}
bool CElementGen::UpdateVelocitySource(size_t idx, s32 particleFrame, CParticle& particle) {

View File

@ -55,7 +55,7 @@ private:
std::vector<CParticle> x30_particles;
std::vector<u32> x40;
std::vector<zeus::CMatrix3f> x50_parentMatrices;
std::vector<std::array<float, 8>> x60_advValues;
std::vector<std::array<float, 9>> x60_advValues;
int x70_internalStartFrame = 0;
int x74_curFrame = 0;

View File

@ -94,6 +94,7 @@ public:
std::unique_ptr<CRealElement> x120_ADV6;
std::unique_ptr<CRealElement> x124_ADV7;
std::unique_ptr<CRealElement> x128_ADV8;
std::unique_ptr<CRealElement> x164_ADV9;
s32 x174_DFLG = 0; // Added in MP2
s32 x178_ = 0; // In MP3, need to check MP2
s32 x17c_ = 0; // In MP3, need to check MP2

View File

@ -42,7 +42,7 @@ public:
m_ParticleLifetimePercentage = zeus::clamp(0, m_ParticleLifetimePercentage, 100);
}
const std::array<float, 8>* m_particleAccessParameters = nullptr;
const std::array<float, 9>* m_particleAccessParameters = nullptr;
struct SParticleSystem {
FourCC x0_type;

View File

@ -26,7 +26,7 @@ CSpawnSystemKeyframeData::CSpawnSystemKeyframeData(CInputStream& in) {
}
CSpawnSystemKeyframeData::CSpawnSystemKeyframeInfo::CSpawnSystemKeyframeInfo(CInputStream& in) {
x0_id = in.readUint32Big();
x0_id = CAssetId(in);
x4 = in.readUint32Big();
x8 = in.readUint32Big();
xc = in.readUint32Big();

View File

@ -15,7 +15,7 @@ class CSpawnSystemKeyframeData {
public:
class CSpawnSystemKeyframeInfo {
friend class CSpawnSystemKeyframeData;
u32 x0_id;
CAssetId x0_id;
u32 x4;
u32 x8;
u32 xc;