mirror of
https://github.com/isledecomp/isle.git
synced 2024-11-22 07:37:59 -05:00
Implement/match LegoAnimPresenter::FUN_1006b900 (#844)
This commit is contained in:
parent
67c9736953
commit
b789a15d0b
4 changed files with 35 additions and 9 deletions
|
@ -97,7 +97,7 @@ class LegoAnimPresenter : public MxVideoPresenter {
|
||||||
LegoBool FUN_1006aba0();
|
LegoBool FUN_1006aba0();
|
||||||
MxBool FUN_1006abb0(LegoTreeNode* p_node, LegoROI* p_roi);
|
MxBool FUN_1006abb0(LegoTreeNode* p_node, LegoROI* p_roi);
|
||||||
void FUN_1006ac90();
|
void FUN_1006ac90();
|
||||||
void FUN_1006b900(LegoAnim* p_anim, MxS32 p_und, MxMatrix* p_matrix);
|
void FUN_1006b900(LegoAnim* p_anim, MxLong p_time, Matrix4* p_matrix);
|
||||||
void FUN_1006b9a0(LegoAnim* p_anim, MxLong p_time, Matrix4* p_matrix);
|
void FUN_1006b9a0(LegoAnim* p_anim, MxLong p_time, Matrix4* p_matrix);
|
||||||
void FUN_1006c8a0(MxBool p_bool);
|
void FUN_1006c8a0(MxBool p_bool);
|
||||||
|
|
||||||
|
|
|
@ -741,11 +741,29 @@ const char* LegoAnimPresenter::GetActionObjectName()
|
||||||
return m_action->GetObjectName();
|
return m_action->GetObjectName();
|
||||||
}
|
}
|
||||||
|
|
||||||
// STUB: LEGO1 0x1006b900
|
// FUNCTION: LEGO1 0x1006b900
|
||||||
// FUNCTION: BETA10 0x100510d8
|
// FUNCTION: BETA10 0x100510d8
|
||||||
void LegoAnimPresenter::FUN_1006b900(LegoAnim* p_anim, MxS32 p_und, MxMatrix* p_matrix)
|
void LegoAnimPresenter::FUN_1006b900(LegoAnim* p_anim, MxLong p_time, Matrix4* p_matrix)
|
||||||
{
|
{
|
||||||
// TODO
|
LegoTreeNode* root = p_anim->GetRoot();
|
||||||
|
MxMatrix mat;
|
||||||
|
LegoAnimNodeData* data = (LegoAnimNodeData*) root->GetData();
|
||||||
|
|
||||||
|
if (p_matrix != NULL) {
|
||||||
|
mat = *p_matrix;
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
LegoROI* roi = m_roiMap[data->GetUnknown0x20()];
|
||||||
|
|
||||||
|
if (roi != NULL) {
|
||||||
|
mat = roi->GetLocal2World();
|
||||||
|
}
|
||||||
|
else {
|
||||||
|
mat.SetIdentity();
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
LegoROI::FUN_100a8fd0(root, mat, p_time, m_roiMap);
|
||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x1006b9a0
|
// FUNCTION: LEGO1 0x1006b9a0
|
||||||
|
|
|
@ -405,14 +405,14 @@ LegoResult LegoROI::FUN_100a8da0(LegoTreeNode* p_node, const Matrix4& p_matrix,
|
||||||
}
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x100a8e80
|
// FUNCTION: LEGO1 0x100a8e80
|
||||||
void LegoROI::FUN_100a8e80(LegoTreeNode* p_node, Matrix4& p_matrix, LegoTime p_time, LegoROI** p_rois)
|
void LegoROI::FUN_100a8e80(LegoTreeNode* p_node, Matrix4& p_matrix, LegoTime p_time, LegoROI** p_roiMap)
|
||||||
{
|
{
|
||||||
MxMatrix mat;
|
MxMatrix mat;
|
||||||
|
|
||||||
LegoAnimNodeData* data = (LegoAnimNodeData*) p_node->GetData();
|
LegoAnimNodeData* data = (LegoAnimNodeData*) p_node->GetData();
|
||||||
FUN_100a8cb0(data, p_time, mat);
|
FUN_100a8cb0(data, p_time, mat);
|
||||||
|
|
||||||
LegoROI* roi = p_rois[data->GetUnknown0x20()];
|
LegoROI* roi = p_roiMap[data->GetUnknown0x20()];
|
||||||
if (roi != NULL) {
|
if (roi != NULL) {
|
||||||
roi->m_local2world.Product(mat, p_matrix);
|
roi->m_local2world.Product(mat, p_matrix);
|
||||||
roi->VTable0x1c();
|
roi->VTable0x1c();
|
||||||
|
@ -421,7 +421,7 @@ void LegoROI::FUN_100a8e80(LegoTreeNode* p_node, Matrix4& p_matrix, LegoTime p_t
|
||||||
roi->SetVisibility(und);
|
roi->SetVisibility(und);
|
||||||
|
|
||||||
for (LegoU32 i = 0; i < p_node->GetNumChildren(); i++) {
|
for (LegoU32 i = 0; i < p_node->GetNumChildren(); i++) {
|
||||||
FUN_100a8e80(p_node->GetChild(i), roi->m_local2world, p_time, p_rois);
|
FUN_100a8e80(p_node->GetChild(i), roi->m_local2world, p_time, p_roiMap);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
|
@ -429,11 +429,18 @@ void LegoROI::FUN_100a8e80(LegoTreeNode* p_node, Matrix4& p_matrix, LegoTime p_t
|
||||||
local2world.Product(mat, p_matrix);
|
local2world.Product(mat, p_matrix);
|
||||||
|
|
||||||
for (LegoU32 i = 0; i < p_node->GetNumChildren(); i++) {
|
for (LegoU32 i = 0; i < p_node->GetNumChildren(); i++) {
|
||||||
FUN_100a8e80(p_node->GetChild(i), local2world, p_time, p_rois);
|
FUN_100a8e80(p_node->GetChild(i), local2world, p_time, p_roiMap);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// STUB: LEGO1 0x100a8fd0
|
||||||
|
// FUNCTION: BETA10 0x1018ac81
|
||||||
|
void LegoROI::FUN_100a8fd0(LegoTreeNode* p_node, Matrix4& p_matrix, LegoTime p_time, LegoROI** p_roiMap)
|
||||||
|
{
|
||||||
|
// TODO
|
||||||
|
}
|
||||||
|
|
||||||
// FUNCTION: LEGO1 0x100a90f0
|
// FUNCTION: LEGO1 0x100a90f0
|
||||||
LegoResult LegoROI::SetFrame(LegoAnim* p_anim, LegoTime p_time)
|
LegoResult LegoROI::SetFrame(LegoAnim* p_anim, LegoTime p_time)
|
||||||
{
|
{
|
||||||
|
|
|
@ -32,7 +32,8 @@ class LegoROI : public ViewROI {
|
||||||
);
|
);
|
||||||
LegoROI* FindChildROI(const LegoChar* p_name, LegoROI* p_roi);
|
LegoROI* FindChildROI(const LegoChar* p_name, LegoROI* p_roi);
|
||||||
LegoResult FUN_100a8da0(LegoTreeNode* p_node, const Matrix4& p_matrix, LegoTime p_time, LegoROI* p_roi);
|
LegoResult FUN_100a8da0(LegoTreeNode* p_node, const Matrix4& p_matrix, LegoTime p_time, LegoROI* p_roi);
|
||||||
static void FUN_100a8e80(LegoTreeNode* p_node, Matrix4& p_matrix, LegoTime p_time, LegoROI** p_rois);
|
static void FUN_100a8e80(LegoTreeNode* p_node, Matrix4& p_matrix, LegoTime p_time, LegoROI** p_roiMap);
|
||||||
|
static void FUN_100a8fd0(LegoTreeNode* p_node, Matrix4& p_matrix, LegoTime p_time, LegoROI** p_roiMap);
|
||||||
LegoResult SetFrame(LegoAnim* p_anim, LegoTime p_time);
|
LegoResult SetFrame(LegoAnim* p_anim, LegoTime p_time);
|
||||||
LegoResult FUN_100a9170(LegoFloat p_red, LegoFloat p_green, LegoFloat p_blue, LegoFloat p_alpha);
|
LegoResult FUN_100a9170(LegoFloat p_red, LegoFloat p_green, LegoFloat p_blue, LegoFloat p_alpha);
|
||||||
LegoResult FUN_100a9210(LegoTextureInfo* p_textureInfo);
|
LegoResult FUN_100a9210(LegoTextureInfo* p_textureInfo);
|
||||||
|
|
Loading…
Reference in a new issue