Skip to content

Commit

Permalink
Order until LegoCarBuildAnimPresenter (#1365)
Browse files Browse the repository at this point in the history
* Order until `Infocenter`

* Order until RaceSkel

* More order

* Order until `LegoCarBuildAnimPresenter`

* Add blank line

* Add BETA annotation
  • Loading branch information
foxtacles authored Jan 21, 2025
1 parent 9480fd9 commit 5a7df7f
Show file tree
Hide file tree
Showing 19 changed files with 108 additions and 116 deletions.
6 changes: 3 additions & 3 deletions CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -363,14 +363,12 @@ function(add_lego_libraries NAME)
LEGO1/lego/legoomni/src/entity/legonavcontroller.cpp
LEGO1/lego/legoomni/src/paths/legopathboundary.cpp
LEGO1/lego/legoomni/src/main/legomain.cpp
LEGO1/lego/legoomni/src/entity/legojetskiraceactor.cpp
LEGO1/lego/legoomni/src/input/legoinputmanager.cpp
LEGO1/lego/legoomni/src/race/legoracemap.cpp
LEGO1/lego/legoomni/src/worlds/jukebox.cpp
LEGO1/lego/legoomni/src/video/legoflctexturepresenter.cpp
LEGO1/lego/legoomni/src/worlds/police.cpp
LEGO1/lego/legoomni/src/common/legoanimationmanager.cpp
LEGO1/lego/legoomni/src/build/legocarbuildpresenter.cpp
LEGO1/lego/legoomni/src/entity/legopovcontroller.cpp
LEGO1/lego/legoomni/src/common/legotextureinfo.cpp
LEGO1/lego/legoomni/src/actors/doors.cpp
Expand All @@ -383,12 +381,14 @@ function(add_lego_libraries NAME)
LEGO1/lego/legoomni/src/worlds/infocenter.cpp
LEGO1/lego/legoomni/src/race/raceskel.cpp
LEGO1/lego/legoomni/src/worlds/act3.cpp
LEGO1/lego/legoomni/src/video/legomodelpresenter.cpp
LEGO1/lego/legoomni/src/common/mxcompositemediapresenter.cpp
LEGO1/lego/legoomni/src/worlds/hospital.cpp
LEGO1/lego/legoomni/src/actors/bike.cpp
LEGO1/lego/legoomni/src/entity/legoactorpresenter.cpp
LEGO1/lego/legoomni/src/worlds/registrationbook.cpp
LEGO1/lego/legoomni/src/build/legocarbuildpresenter.cpp
LEGO1/lego/legoomni/src/entity/legojetskiraceactor.cpp
LEGO1/lego/legoomni/src/video/legomodelpresenter.cpp
LEGO1/lego/legoomni/src/video/legopalettepresenter.cpp
LEGO1/lego/legoomni/src/entity/act2brick.cpp
LEGO1/lego/legoomni/src/video/legovideomanager.cpp
Expand Down
4 changes: 3 additions & 1 deletion LEGO1/lego/legoomni/include/act3.h
Original file line number Diff line number Diff line change
Expand Up @@ -92,6 +92,9 @@ class Act3 : public LegoWorld {
MxLong Notify(MxParam& p_param) override; // vtable+0x04
MxResult Tickle() override; // vtable+0x08

// FUNCTION: LEGO1 0x10072500
MxBool VTable0x5c() override { return TRUE; } // vtable+0x5c

// FUNCTION: LEGO1 0x10072510
// FUNCTION: BETA10 0x10017550
const char* ClassName() const override // vtable+0x0c
Expand All @@ -109,7 +112,6 @@ class Act3 : public LegoWorld {
MxResult Create(MxDSAction& p_dsAction) override; // vtable+0x18
void Destroy(MxBool p_fromDestructor) override; // vtable+0x1c
void ReadyWorld() override; // vtable+0x50
MxBool VTable0x5c() override; // vtable+0x5c
void VTable0x60() override; // vtable+0x60
MxBool Escape() override; // vtable+0x64
void Enable(MxBool p_enable) override; // vtable+0x68
Expand Down
23 changes: 10 additions & 13 deletions LEGO1/lego/legoomni/include/hospital.h
Original file line number Diff line number Diff line change
Expand Up @@ -16,11 +16,6 @@ class MxStillPresenter;
// SIZE 0x18
class HospitalState : public LegoState {
public:
// SIZE 0x04
struct Unknown0x08 {
undefined4 m_unk0x00; // 0x00
};

HospitalState();
~HospitalState() override {}

Expand All @@ -45,13 +40,13 @@ class HospitalState : public LegoState {

// TODO: Most likely getters/setters are not used according to BETA.

Unknown0x08 m_unk0x08; // 0x08
MxS16 m_unk0x0c; // 0x0c
MxS16 m_unk0x0e; // 0x0e
MxS16 m_unk0x10; // 0x10
MxS16 m_unk0x12; // 0x12
MxS16 m_unk0x14; // 0x14
MxS16 m_unk0x16; // 0x16
undefined4 m_unk0x08; // 0x08
MxS16 m_unk0x0c; // 0x0c
MxS16 m_unk0x0e; // 0x0e
MxS16 m_unk0x10; // 0x10
MxS16 m_unk0x12; // 0x12
MxS16 m_unk0x14; // 0x14
MxS16 m_unk0x16; // 0x16
};

// VTABLE: LEGO1 0x100d9730
Expand All @@ -65,6 +60,9 @@ class Hospital : public LegoWorld {
MxLong Notify(MxParam& p_param) override; // vtable+0x04
MxResult Tickle() override; // vtable+0x08

// FUNCTION: LEGO1 0x100746a0
MxBool VTable0x5c() override { return TRUE; } // vtable+0x5c

// FUNCTION: LEGO1 0x100746b0
// FUNCTION: BETA10 0x1002e1a0
const char* ClassName() const override // vtable+0x0c
Expand All @@ -81,7 +79,6 @@ class Hospital : public LegoWorld {

MxResult Create(MxDSAction& p_dsAction) override; // vtable+0x18
void ReadyWorld() override; // vtable+0x50
MxBool VTable0x5c() override; // vtable+0x5c
MxBool Escape() override; // vtable+0x64
void Enable(MxBool p_enable) override; // vtable+0x68

Expand Down
9 changes: 4 additions & 5 deletions LEGO1/lego/legoomni/include/infocenter.h
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,9 @@ class InfocenterState : public LegoState {
InfocenterState();
~InfocenterState() override;

// FUNCTION: LEGO1 0x10071830
MxBool IsSerializable() override { return FALSE; } // vtable+0x14

// FUNCTION: LEGO1 0x10071840
// FUNCTION: BETA10 0x10031ee0
const char* ClassName() const override // vtable+0x0c
Expand All @@ -34,9 +37,6 @@ class InfocenterState : public LegoState {
return !strcmp(p_name, InfocenterState::ClassName()) || LegoState::IsA(p_name);
}

// FUNCTION: LEGO1 0x10071830
MxBool IsSerializable() override { return FALSE; } // vtable+0x14

MxS16 GetMaxNameLength() { return sizeOfArray(m_letters); }
MxStillPresenter* GetNameLetter(MxS32 p_index) { return m_letters[p_index]; }
void SetNameLetter(MxS32 p_index, MxStillPresenter* p_letter) { m_letters[p_index] = p_letter; }
Expand Down Expand Up @@ -66,8 +66,7 @@ class InfocenterState : public LegoState {

// SIZE 0x18
struct InfocenterMapEntry {
// FUNCTION: LEGO1 0x1006ec80
InfocenterMapEntry() {}
InfocenterMapEntry();

MxStillPresenter* m_destCtl; // 0x00
undefined4 m_unk0x04; // 0x04
Expand Down
4 changes: 3 additions & 1 deletion LEGO1/lego/legoomni/include/jukebox.h
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,9 @@ class JukeBox : public LegoWorld {
MxLong Notify(MxParam& p_param) override; // vtable+0x04
MxResult Tickle() override; // vtable+0x08

// FUNCTION: LEGO1 0x1005d6e0
MxBool VTable0x5c() override { return TRUE; } // vtable+0x5c

// FUNCTION: LEGO1 0x1005d6f0
// FUNCTION: BETA10 0x100388d0
const char* ClassName() const override // vtable+0x0c
Expand All @@ -75,7 +78,6 @@ class JukeBox : public LegoWorld {

MxResult Create(MxDSAction& p_dsAction) override; // vtable+0x18
void ReadyWorld() override; // vtable+0x50
MxBool VTable0x5c() override; // vtable+0x5c
MxBool Escape() override; // vtable+0x64
void Enable(MxBool p_enable) override; // vtable+0x68

Expand Down
6 changes: 5 additions & 1 deletion LEGO1/lego/legoomni/include/legocarbuildpresenter.h
Original file line number Diff line number Diff line change
Expand Up @@ -44,6 +44,9 @@ class LegoCarBuildAnimPresenter : public LegoAnimPresenter {
return "LegoCarBuildAnimPresenter";
}

// FUNCTION: LEGO1 0x10078500
void RepeatingTickle() override {} // vtable+0x24

// FUNCTION: LEGO1 0x10078510
// FUNCTION: BETA10 0x10073260
const char* ClassName() const override // vtable+0x0c
Expand All @@ -59,10 +62,11 @@ class LegoCarBuildAnimPresenter : public LegoAnimPresenter {

void ReadyTickle() override; // vtable+0x18
void StreamingTickle() override; // vtable+0x20
void RepeatingTickle() override; // vtable+0x24
void EndAction() override; // vtable+0x40
void PutFrame() override; // vtable+0x6c

virtual MxResult Serialize(LegoStorage* p_storage);

void FUN_10079050(MxS16 p_index);
void SwapNodesByName(LegoChar* p_param1, LegoChar* p_param2);
void FUN_10079160();
Expand Down
8 changes: 6 additions & 2 deletions LEGO1/lego/legoomni/include/legohideanimpresenter.h
Original file line number Diff line number Diff line change
Expand Up @@ -25,6 +25,12 @@ class LegoHideAnimPresenter : public LegoLoopingAnimPresenter {
LegoHideAnimPresenter();
~LegoHideAnimPresenter() override;

// FUNCTION: LEGO1 0x1006d860
void VTable0x8c() override {} // vtable+0x8c

// FUNCTION: LEGO1 0x1006d870
void VTable0x90() override {} // vtable+0x90

// FUNCTION: BETA10 0x1005d4a0
static const char* HandlerClassName()
{
Expand All @@ -51,8 +57,6 @@ class LegoHideAnimPresenter : public LegoLoopingAnimPresenter {
void Destroy() override; // vtable+0x38
void EndAction() override; // vtable+0x40
void PutFrame() override; // vtable+0x6c
void VTable0x8c() override; // vtable+0x8c
void VTable0x90() override; // vtable+0x90

void FUN_1006db40(LegoTime p_time);

Expand Down
7 changes: 6 additions & 1 deletion LEGO1/lego/legoomni/include/legoinputmanager.h
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,12 @@ class LegoInputManager : public MxPresenter {
void Register(MxCore*);
void UnRegister(MxCore*);

MxResult Tickle() override; // vtable+0x08
// FUNCTION: LEGO1 0x1005b8b0
MxResult Tickle() override
{
ProcessEvents();
return SUCCESS;
} // vtable+0x08

// FUNCTION: LEGO1 0x1005b8c0
MxResult PutData() override { return SUCCESS; } // vtable+0x4c
Expand Down
4 changes: 3 additions & 1 deletion LEGO1/lego/legoomni/include/police.h
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,9 @@ class Police : public LegoWorld {

MxLong Notify(MxParam& p_param) override; // vtable+0x04

// FUNCTION: LEGO1 0x1005e1d0
MxBool VTable0x5c() override { return TRUE; } // vtable+0x5c

// FUNCTION: LEGO1 0x1005e1e0
// FUNCTION: BETA10 0x100f0c50
const char* ClassName() const override // vtable+0x0c
Expand All @@ -75,7 +78,6 @@ class Police : public LegoWorld {

MxResult Create(MxDSAction& p_dsAction) override; // vtable+0x18
void ReadyWorld() override; // vtable+0x50
MxBool VTable0x5c() override; // vtable+0x5c
MxBool Escape() override; // vtable+0x64
void Enable(MxBool p_enable) override; // vtable+0x68

Expand Down
2 changes: 2 additions & 0 deletions LEGO1/lego/legoomni/include/raceskel.h
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,8 @@ class RaceSkel : public LegoAnimActor {

MxResult FUN_1001c360(float p_und, Matrix4& p_transform) override;

virtual void FUN_10071c80(Vector3& p_vec);

void GetCurrentAnimData(float* p_outCurAnimPosition, float* p_outCurAnimDuration);

// SYNTHETIC: LEGO1 0x10071cf0
Expand Down
14 changes: 8 additions & 6 deletions LEGO1/lego/legoomni/src/build/legocarbuildpresenter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -39,12 +39,6 @@ LegoCarBuildAnimPresenter::LegoCarBuildAnimPresenter()
m_mainSourceId = NULL;
}

// FUNCTION: LEGO1 0x10078500
void LegoCarBuildAnimPresenter::RepeatingTickle()
{
// empty
}

// FUNCTION: LEGO1 0x10078680
// FUNCTION: BETA10 0x1007091e
LegoCarBuildAnimPresenter::~LegoCarBuildAnimPresenter()
Expand Down Expand Up @@ -294,6 +288,14 @@ void LegoCarBuildAnimPresenter::EndAction()
}
}

// STUB: LEGO1 0x10078e30
// STUB: BETA10 0x10071387
MxResult LegoCarBuildAnimPresenter::Serialize(LegoStorage* p_storage)
{
// TODO
return SUCCESS;
}

// FUNCTION: LEGO1 0x10079050
// FUNCTION: BETA10 0x1007151e
void LegoCarBuildAnimPresenter::FUN_10079050(MxS16 p_index)
Expand Down
7 changes: 0 additions & 7 deletions LEGO1/lego/legoomni/src/input/legoinputmanager.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -52,13 +52,6 @@ LegoInputManager::LegoInputManager()
m_autoDragTime = 1000;
}

// FUNCTION: LEGO1 0x1005b8b0
MxResult LegoInputManager::Tickle()
{
ProcessEvents();
return SUCCESS;
}

// FUNCTION: LEGO1 0x1005b8f0
LegoInputManager::~LegoInputManager()
{
Expand Down
9 changes: 9 additions & 0 deletions LEGO1/lego/legoomni/src/race/raceskel.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,15 @@ void RaceSkel::ParseAction(char* p_extra)
m_roi->SetBoundingSphere(sphere);
}

// FUNCTION: LEGO1 0x10071c80
// FUNCTION: BETA10 0x100f1531
void RaceSkel::FUN_10071c80(Vector3& p_vec)
{
p_vec[0] = -630.0f;
p_vec[1] = -4.688f;
p_vec[2] = 323.0f;
}

// FUNCTION: LEGO1 0x10071cb0
// FUNCTION: BETA10 0x100f158b
void RaceSkel::GetCurrentAnimData(float* p_outCurAnimPosition, float* p_outCurAnimDuration)
Expand Down
10 changes: 0 additions & 10 deletions LEGO1/lego/legoomni/src/video/legohideanimpresenter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -14,16 +14,6 @@ LegoHideAnimPresenter::LegoHideAnimPresenter()
Init();
}

// FUNCTION: LEGO1 0x1006d860
void LegoHideAnimPresenter::VTable0x8c()
{
}

// FUNCTION: LEGO1 0x1006d870
void LegoHideAnimPresenter::VTable0x90()
{
}

// FUNCTION: LEGO1 0x1006d9f0
LegoHideAnimPresenter::~LegoHideAnimPresenter()
{
Expand Down
6 changes: 0 additions & 6 deletions LEGO1/lego/legoomni/src/worlds/act3.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -241,12 +241,6 @@ Act3::Act3()
NotificationManager()->Register(this);
}

// FUNCTION: LEGO1 0x10072500
MxBool Act3::VTable0x5c()
{
return TRUE;
}

// FUNCTION: LEGO1 0x100726a0
// FUNCTION: BETA10 0x100155da
Act3::~Act3()
Expand Down
Loading

0 comments on commit 5a7df7f

Please sign in to comment.