Implement a few legoworld methods (#430)

* Push changes

* Update legoworld.cpp

* Update legoworld.cpp

* Minor style fixes

---------

Co-authored-by: Christian Semmler <mail@csemmler.com>
This commit is contained in:
Misha
2024-01-13 15:00:11 -05:00
committed by GitHub
parent 7d2629318c
commit c2da041f40
23 changed files with 120 additions and 51 deletions

View File

@@ -37,7 +37,7 @@ public:
return !strcmp(p_name, Helicopter::ClassName()) || IslePathActor::IsA(p_name);
}
virtual MxResult Create(MxDSObject& p_dsObject) override; // vtable+0x18
virtual MxResult Create(MxDSAction& p_dsAction) override; // vtable+0x18
void VTable0x70(float p_float) override; // vtable+0x70
void VTable0x74(Matrix4& p_transform) override; // vtable+0x74
virtual MxU32 VTable0xcc() override; // vtable+0xcc

View File

@@ -26,7 +26,7 @@ public:
return !strcmp(p_name, Infocenter::ClassName()) || LegoWorld::IsA(p_name);
}
virtual MxResult Create(MxDSObject& p_dsObject) override; // vtable+0x18
virtual MxResult Create(MxDSAction& p_dsAction) override; // vtable+0x18
virtual void VTable0x50() override; // vtable+0x50
virtual MxBool VTable0x5c() override; // vtable+0x5c
virtual MxBool VTable0x64() override; // vtable+0x64

View File

@@ -40,7 +40,7 @@ public:
return !strcmp(p_name, Isle::ClassName()) || LegoWorld::IsA(p_name);
}
virtual MxResult Create(MxDSObject& p_dsObject) override; // vtable+0x18
virtual MxResult Create(MxDSAction& p_dsAction) override; // vtable+0x18
virtual void VTable0x50() override; // vtable+50
virtual void VTable0x58(MxCore* p_object) override; // vtable+58
// FUNCTION: LEGO1 0x10030900

View File

@@ -28,7 +28,7 @@ public:
return !strcmp(p_name, IslePathActor::ClassName()) || LegoPathActor::IsA(p_name);
}
virtual MxResult Create(MxDSObject& p_dsObject) override; // vtable+0x18
virtual MxResult Create(MxDSAction& p_dsAction) override; // vtable+0x18
// FUNCTION: LEGO1 0x10002e70
virtual MxU32 VTable0xcc() { return 0; } // vtable+0xcc
// FUNCTION: LEGO1 0x10002df0

View File

@@ -2,6 +2,7 @@
#define LEGOCONTROLMANAGER_H
#include "mxcore.h"
#include "mxpresenterlist.h"
// VTABLE: LEGO1 0x100d6a80
class LegoControlManager : public MxCore {
@@ -24,6 +25,7 @@ public:
return !strcmp(p_name, LegoControlManager::ClassName()) || MxCore::IsA(p_name);
}
void FUN_10028df0(MxPresenterList* p_presenterList);
void Register(MxCore* p_listener);
void Unregister(MxCore* p_listener);
};

View File

@@ -32,7 +32,7 @@ public:
return !strcmp(p_name, LegoEntity::ClassName()) || MxEntity::IsA(p_name);
}
virtual MxResult Create(MxDSObject& p_dsObject); // vtable+0x18
virtual MxResult Create(MxDSAction& p_dsAction); // vtable+0x18
virtual void Destroy(MxBool p_fromDestructor); // vtable+0x1c
virtual void ParseAction(char*); // vtable+0x20
virtual void SetROI(LegoROI* p_roi, MxBool p_bool1, MxBool p_bool2); // vtable+0x24

View File

@@ -116,7 +116,7 @@ public:
MxDSAction& GetCurrentAction() { return m_action; }
inline void SetNavController(LegoNavController* p_navController) { m_navController = p_navController; }
inline void SetWorld(LegoWorld* p_currentWorld) { m_currentWorld = p_currentWorld; }
inline void SetExit(MxBool p_exit) { m_exit = p_exit; };
private:
@@ -167,5 +167,6 @@ void SetIsWorldActive(MxBool p_isWorldActive);
void DeleteObjects(MxAtomId* p_id, MxS32 p_first, MxS32 p_last);
void RegisterScripts();
void UnregisterScripts();
void SetCurrentWorld(LegoWorld* p_world);
#endif // LEGOOMNI_H

View File

@@ -83,6 +83,7 @@ public:
virtual void SetEntity(LegoEntity* p_entity); // vtable+0x2c
MxResult Create(Lego3DView* p_lego3DView);
void OnViewSize(int p_width, int p_height);
inline LegoEntity* GetEntity() { return m_entity; }

View File

@@ -28,7 +28,7 @@ public:
return !strcmp(p_name, LegoRace::ClassName()) || LegoWorld::IsA(p_name);
}
virtual MxResult Create(MxDSObject& p_dsObject) override; // vtable+0x18
virtual MxResult Create(MxDSAction& p_dsAction) override; // vtable+0x18
virtual MxBool VTable0x5c() override; // vtable+0x5c
virtual MxBool VTable0x64() override; // vtable+0x64
virtual void VTable0x68(MxBool p_add) override; // vtable+0x68

View File

@@ -33,20 +33,20 @@ public:
return !strcmp(p_name, LegoWorld::ClassName()) || LegoEntity::IsA(p_name);
}
virtual void VTable0x50(); // vtable+50
virtual void VTable0x54(); // vtable+54
virtual void VTable0x58(MxCore* p_object); // vtable+58
virtual MxBool VTable0x5c(); // vtable+5c
virtual MxResult Create(MxDSAction& p_dsAction) override; // vtable+0x18
virtual void VTable0x50(); // vtable+0x50
virtual LegoCameraController* VTable0x54(); // vtable+0x54
virtual void VTable0x58(MxCore* p_object); // vtable+0x58
virtual MxBool VTable0x5c(); // vtable+0x5c
// FUNCTION: LEGO1 0x100010a0
virtual void VTable0x60() {} // vtable+60
virtual MxBool VTable0x64(); // vtable+64
virtual void VTable0x68(MxBool p_add); // vtable+68
virtual void VTable0x60() {} // vtable+0x60
virtual MxBool VTable0x64(); // vtable+0x64
virtual void VTable0x68(MxBool p_add); // vtable+0x68
inline LegoCameraController* GetCamera() { return m_camera; }
inline LegoCameraController* GetCamera() { return m_cameraController; }
inline undefined4 GetUnknown0xec() { return m_unk0xec; }
undefined FUN_100220e0();
MxResult SetAsCurrentWorld(MxDSObject& p_dsObject);
void EndAction(MxCore* p_object);
void FUN_1001fc80(IslePathActor* p_actor);
MxBool FUN_100727e0(MxU32, Mx3DPointFloat& p_loc, Mx3DPointFloat& p_dir, Mx3DPointFloat& p_up);
@@ -56,17 +56,17 @@ public:
MxS32 GetCurrPathInfo(LegoPathBoundary** p_path, MxS32& p_value);
protected:
LegoPathControllerList m_list0x68; // 0x68
MxPresenterList m_list0x80; // 0x80
LegoCameraController* m_camera; // 0x98
undefined m_unk0x9c[0x1c]; // 0x9c
MxPresenterList m_list0xb8; // 0xb8
undefined m_unk0xd0[0x1c]; // 0xd0
undefined4 m_unk0xec; // 0xec
undefined4 m_unk0xf0; // 0xf0
MxS16 m_unk0xf4; // 0xf4
MxBool m_worldStarted; // 0xf6
undefined m_unk0xf7; // 0xf7
LegoPathControllerList m_list0x68; // 0x68
MxPresenterList m_list0x80; // 0x80
LegoCameraController* m_cameraController; // 0x98
undefined m_unk0x9c[0x1c]; // 0x9c
MxPresenterList m_list0xb8; // 0xb8
undefined m_unk0xd0[0x1c]; // 0xd0
undefined4 m_unk0xec; // 0xec
undefined4 m_unk0xf0; // 0xf0
MxS16 m_unk0xf4; // 0xf4
MxBool m_worldStarted; // 0xf6
undefined m_unk0xf7; // 0xf7
};
// SYNTHETIC: LEGO1 0x1001eed0

View File

@@ -31,7 +31,7 @@ public:
// SYNTHETIC: LEGO1 0x100011e0
// Score::`scalar deleting destructor'
virtual MxResult Create(MxDSObject& p_dsObject) override; // vtable+18
virtual MxResult Create(MxDSAction& p_dsAction) override; // vtable+18
virtual void VTable0x50() override; // vtable+50
virtual MxBool VTable0x5c() override; // vtable+5c
virtual MxBool VTable0x64() override; // vtable+64