From d9d9880d8b37c0cf10128575e1a9684fdfe1c64a Mon Sep 17 00:00:00 2001 From: Fabian Neundorf Date: Sat, 12 Jul 2025 02:11:12 +0200 Subject: [PATCH] Clear unknowns in `LegoAnimNodeData` (#1617) --- LEGO1/lego/legoomni/src/video/legohideanimpresenter.cpp | 8 ++++---- LEGO1/lego/sources/anim/legoanim.cpp | 2 +- LEGO1/lego/sources/anim/legoanim.h | 6 +++--- 3 files changed, 8 insertions(+), 8 deletions(-) diff --git a/LEGO1/lego/legoomni/src/video/legohideanimpresenter.cpp b/LEGO1/lego/legoomni/src/video/legohideanimpresenter.cpp index 89768b3e..60f8dce5 100644 --- a/LEGO1/lego/legoomni/src/video/legohideanimpresenter.cpp +++ b/LEGO1/lego/legoomni/src/video/legohideanimpresenter.cpp @@ -114,7 +114,7 @@ void LegoHideAnimPresenter::FUN_1006db60(LegoTreeNode* p_node, LegoTime p_time) } if (m_boundaryMap != NULL) { - LegoPathBoundary* boundary = m_boundaryMap[data->GetUnknown0x22()]; + LegoPathBoundary* boundary = m_boundaryMap[data->GetBoundaryIndex()]; if (boundary != NULL) { newB = data->GetVisibility(p_time); @@ -163,7 +163,7 @@ void LegoHideAnimPresenter::FUN_1006e3f0(LegoHideAnimStructMap& p_map, LegoTreeN FUN_1006e470(p_map, data, name, boundary); } else { - data->SetUnknown0x22(0); + data->SetBoundaryIndex(0); } } @@ -190,7 +190,7 @@ void LegoHideAnimPresenter::FUN_1006e470( animStruct.m_index = p_map.size() + 1; animStruct.m_boundary = p_boundary; - p_data->SetUnknown0x22(animStruct.m_index); + p_data->SetBoundaryIndex(animStruct.m_index); char* name = new char[strlen(p_name) + 1]; strcpy(name, p_name); @@ -198,7 +198,7 @@ void LegoHideAnimPresenter::FUN_1006e470( p_map[name] = animStruct; } else { - p_data->SetUnknown0x22((*it).second.m_index); + p_data->SetBoundaryIndex((*it).second.m_index); } } diff --git a/LEGO1/lego/sources/anim/legoanim.cpp b/LEGO1/lego/sources/anim/legoanim.cpp index 8ec3ee2d..9026c245 100644 --- a/LEGO1/lego/sources/anim/legoanim.cpp +++ b/LEGO1/lego/sources/anim/legoanim.cpp @@ -524,7 +524,7 @@ LegoAnimNodeData::LegoAnimNodeData() m_translationKeys = NULL; m_roiIndex = 0; m_rotationKeys = NULL; - m_unk0x22 = 0; + m_boundaryIndex = 0; m_scaleKeys = NULL; m_morphKeys = NULL; m_translationIndex = 0; diff --git a/LEGO1/lego/sources/anim/legoanim.h b/LEGO1/lego/sources/anim/legoanim.h index 372128b5..7a03d99c 100644 --- a/LEGO1/lego/sources/anim/legoanim.h +++ b/LEGO1/lego/sources/anim/legoanim.h @@ -190,7 +190,7 @@ public: LegoU16 GetROIIndex() { return m_roiIndex; } // FUNCTION: BETA10 0x1005d5c0 - LegoU16 GetUnknown0x22() { return m_unk0x22; } + LegoU16 GetBoundaryIndex() { return m_boundaryIndex; } // FUNCTION: BETA10 0x10073b80 LegoRotationKey* GetRotationKey(MxS32 index) { return &m_rotationKeys[index]; } @@ -217,7 +217,7 @@ public: void SetROIIndex(LegoU16 p_roiIndex) { m_roiIndex = p_roiIndex; } // FUNCTION: BETA10 0x1005f2e0 - void SetUnknown0x22(LegoU16 p_unk0x22) { m_unk0x22 = p_unk0x22; } + void SetBoundaryIndex(LegoU16 p_boundaryIndex) { m_boundaryIndex = p_boundaryIndex; } LegoResult CreateLocalTransform(LegoTime p_time, Matrix4& p_matrix) { @@ -280,7 +280,7 @@ protected: LegoScaleKey* m_scaleKeys; // 0x18 LegoMorphKey* m_morphKeys; // 0x1c LegoU16 m_roiIndex; // 0x20 - LegoU16 m_unk0x22; // 0x22 + LegoU16 m_boundaryIndex; // 0x22 LegoU32 m_translationIndex; // 0x24 LegoU32 m_rotationIndex; // 0x28 LegoU32 m_scaleIndex; // 0x2c