mirror of
https://github.com/isledecomp/isle-portable.git
synced 2024-11-22 15:37:55 -05:00
Implement/match LegoAnimationManager ctor/dtor (#857)
This commit is contained in:
parent
53ef6bdd81
commit
00f5eff792
2 changed files with 64 additions and 7 deletions
|
@ -73,7 +73,6 @@ class LegoAnimationManager : public MxCore {
|
||||||
MxBool FindVehicle(const char* p_name, MxU32& p_index);
|
MxBool FindVehicle(const char* p_name, MxU32& p_index);
|
||||||
MxResult ReadAnimInfo(LegoFile* p_file, AnimInfo* p_info);
|
MxResult ReadAnimInfo(LegoFile* p_file, AnimInfo* p_info);
|
||||||
MxResult ReadModelInfo(LegoFile* p_file, ModelInfo* p_info);
|
MxResult ReadModelInfo(LegoFile* p_file, ModelInfo* p_info);
|
||||||
void DeleteAnimations();
|
|
||||||
void FUN_10060570(MxBool);
|
void FUN_10060570(MxBool);
|
||||||
MxResult StartEntityAction(MxDSAction& p_dsAction, LegoEntity* p_entity);
|
MxResult StartEntityAction(MxDSAction& p_dsAction, LegoEntity* p_entity);
|
||||||
MxResult FUN_10060dc0(
|
MxResult FUN_10060dc0(
|
||||||
|
@ -118,6 +117,8 @@ class LegoAnimationManager : public MxCore {
|
||||||
undefined
|
undefined
|
||||||
);
|
);
|
||||||
MxResult FUN_100609f0(MxU32 p_objectId, MxMatrix* p_matrix, MxBool p_und1, MxBool p_und2);
|
MxResult FUN_100609f0(MxU32 p_objectId, MxMatrix* p_matrix, MxBool p_und1, MxBool p_und2);
|
||||||
|
void DeleteAnimations();
|
||||||
|
void FUN_10063aa0();
|
||||||
|
|
||||||
MxU32 m_scriptIndex; // 0x08
|
MxU32 m_scriptIndex; // 0x08
|
||||||
MxU16 m_animCount; // 0x0c
|
MxU16 m_animCount; // 0x0c
|
||||||
|
@ -141,14 +142,17 @@ class LegoAnimationManager : public MxCore {
|
||||||
MxLong m_unk0x404; // 0x404
|
MxLong m_unk0x404; // 0x404
|
||||||
undefined m_unk0x408[0x18]; // 0x408
|
undefined m_unk0x408[0x18]; // 0x408
|
||||||
AnimState* m_animState; // 0x420
|
AnimState* m_animState; // 0x420
|
||||||
undefined4 m_unk0x424; // 0x424
|
LegoROIList* m_unk0x424; // 0x424
|
||||||
undefined m_unk0x428; // 0x428
|
undefined m_unk0x428; // 0x428
|
||||||
undefined m_unk0x429; // 0x429
|
undefined m_unk0x429; // 0x429
|
||||||
undefined m_unk0x42a; // 0x42a
|
undefined m_unk0x42a; // 0x42a
|
||||||
undefined m_unk0x42b; // 0x42b
|
undefined m_unk0x42b; // 0x42b
|
||||||
undefined4 m_unk0x42c; // 0x42c
|
undefined4 m_unk0x42c; // 0x42c
|
||||||
undefined m_unk0x430; // 0x430
|
undefined m_unk0x430; // 0x430
|
||||||
undefined m_unk0x431[0xcf]; // 0x431
|
undefined4 m_unk0x434[2]; // 0x434
|
||||||
|
MxMatrix m_unk0x43c; // 0x43c
|
||||||
|
MxMatrix m_unk0x484; // 0x484
|
||||||
|
UnknownMx4DPointFloat m_unk0x4cc; // 0x4cc
|
||||||
};
|
};
|
||||||
|
|
||||||
#endif // LEGOANIMATIONMANAGER_H
|
#endif // LEGOANIMATIONMANAGER_H
|
||||||
|
|
|
@ -1,12 +1,15 @@
|
||||||
#include "legoanimationmanager.h"
|
#include "legoanimationmanager.h"
|
||||||
|
|
||||||
#include "define.h"
|
#include "define.h"
|
||||||
|
#include "islepathactor.h"
|
||||||
#include "legocharactermanager.h"
|
#include "legocharactermanager.h"
|
||||||
#include "legogamestate.h"
|
#include "legogamestate.h"
|
||||||
#include "legoomni.h"
|
#include "legoomni.h"
|
||||||
|
#include "legoroilist.h"
|
||||||
#include "misc.h"
|
#include "misc.h"
|
||||||
#include "mxbackgroundaudiomanager.h"
|
#include "mxbackgroundaudiomanager.h"
|
||||||
#include "mxmisc.h"
|
#include "mxmisc.h"
|
||||||
|
#include "mxticklemanager.h"
|
||||||
#include "mxtimer.h"
|
#include "mxtimer.h"
|
||||||
#include "mxutilities.h"
|
#include "mxutilities.h"
|
||||||
#include "roi/legoroi.h"
|
#include "roi/legoroi.h"
|
||||||
|
@ -90,16 +93,59 @@ void LegoAnimationManager::configureLegoAnimationManager(MxS32 p_legoAnimationMa
|
||||||
g_legoAnimationManagerConfig = p_legoAnimationManagerConfig;
|
g_legoAnimationManagerConfig = p_legoAnimationManagerConfig;
|
||||||
}
|
}
|
||||||
|
|
||||||
// STUB: LEGO1 0x1005eb60
|
// FUNCTION: LEGO1 0x1005eb60
|
||||||
|
// FUNCTION: BETA10 0x1003f940
|
||||||
LegoAnimationManager::LegoAnimationManager()
|
LegoAnimationManager::LegoAnimationManager()
|
||||||
{
|
{
|
||||||
// TODO
|
m_unk0x1c = 0;
|
||||||
|
m_animState = NULL;
|
||||||
|
m_unk0x424 = NULL;
|
||||||
|
|
||||||
|
Init();
|
||||||
|
|
||||||
|
NotificationManager()->Register(this);
|
||||||
|
TickleManager()->RegisterClient(this, 10);
|
||||||
}
|
}
|
||||||
|
|
||||||
// STUB: LEGO1 0x1005ed30
|
// FUNCTION: LEGO1 0x1005ed30
|
||||||
|
// FUNCTION: BETA10 0x1003fa27
|
||||||
LegoAnimationManager::~LegoAnimationManager()
|
LegoAnimationManager::~LegoAnimationManager()
|
||||||
{
|
{
|
||||||
// TODO
|
TickleManager()->UnregisterClient(this);
|
||||||
|
|
||||||
|
FUN_10061010(0);
|
||||||
|
|
||||||
|
for (MxS32 i = 0; i < (MxS32) _countof(m_unk0x3c); i++) {
|
||||||
|
LegoROI* roi = m_unk0x3c[i].m_roi;
|
||||||
|
|
||||||
|
if (roi != NULL) {
|
||||||
|
LegoPathActor* actor = CharacterManager()->GetActor(roi->GetName());
|
||||||
|
|
||||||
|
if (actor != NULL && actor->GetController() != NULL && CurrentWorld() != NULL) {
|
||||||
|
CurrentWorld()->FUN_1001fc80((IslePathActor*) actor);
|
||||||
|
actor->ClearController();
|
||||||
|
}
|
||||||
|
|
||||||
|
CharacterManager()->FUN_10083db0(roi);
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
|
if (m_tranInfoList != NULL) {
|
||||||
|
delete m_tranInfoList;
|
||||||
|
}
|
||||||
|
|
||||||
|
if (m_tranInfoList2 != NULL) {
|
||||||
|
delete m_tranInfoList2;
|
||||||
|
}
|
||||||
|
|
||||||
|
DeleteAnimations();
|
||||||
|
|
||||||
|
if (m_unk0x424 != NULL) {
|
||||||
|
FUN_10063aa0();
|
||||||
|
delete m_unk0x424;
|
||||||
|
}
|
||||||
|
|
||||||
|
NotificationManager()->Unregister(this);
|
||||||
}
|
}
|
||||||
|
|
||||||
// STUB: LEGO1 0x1005ee80
|
// STUB: LEGO1 0x1005ee80
|
||||||
|
@ -121,6 +167,7 @@ void LegoAnimationManager::FUN_1005f0b0()
|
||||||
}
|
}
|
||||||
|
|
||||||
// STUB: LEGO1 0x1005f130
|
// STUB: LEGO1 0x1005f130
|
||||||
|
// FUNCTION: BETA10 0x1003ffb7
|
||||||
void LegoAnimationManager::Init()
|
void LegoAnimationManager::Init()
|
||||||
{
|
{
|
||||||
// TODO
|
// TODO
|
||||||
|
@ -684,6 +731,12 @@ void LegoAnimationManager::FUN_10063780(LegoROIList*)
|
||||||
// TODO
|
// TODO
|
||||||
}
|
}
|
||||||
|
|
||||||
|
// STUB: LEGO1 0x10063aa0
|
||||||
|
void LegoAnimationManager::FUN_10063aa0()
|
||||||
|
{
|
||||||
|
// TODO
|
||||||
|
}
|
||||||
|
|
||||||
// STUB: LEGO1 0x10064670
|
// STUB: LEGO1 0x10064670
|
||||||
void LegoAnimationManager::FUN_10064670(MxBool)
|
void LegoAnimationManager::FUN_10064670(MxBool)
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in a new issue