Class layout for LEGO1 classes (#43)

* Stubbed a bunch of classes and annotated them for later use. Heavily wip and more of pseudocode right now.

* Converted pseudocode into real code!

* Created a bunch more classes and added more information to exisiting ones
Did not error check, this was pushed just for reference

* More classes and implementation details. Still not checked for any errors

* Fixed code and decided on a way to handle virtual table stubs

* Some additional fixes

* More smaller fixes

* Added classes to project and made it compile

* Fixed function adresses that caused the python script to fail

* More classes and virtual function resolves. Builds and compares fine.

* Again more classes and virtual function resolves. Builds and compares fine.

* No clue, I guess forced update for line endings

* Finished up some work, compiles fine. All functions are STUB annotated to not pollute reccmp.py output.

* line ending change

* rename GetClassName/IsClass

Mirroring recent changes from master

* further conform to current master

* update project

* cleanup

* project only updates when you close msdev

---------

Co-authored-by: Cydra <cydra95@gmail.com>
Co-authored-by: itsmattkc <34096995+itsmattkc@users.noreply.github.com>
This commit is contained in:
Cydra
2023-06-29 10:10:08 +02:00
committed by GitHub
parent 4d200bb193
commit 07912eb05a
307 changed files with 8764 additions and 165 deletions

View File

@@ -14,9 +14,14 @@
#include "mxdsobject.h"
#include "mxomni.h"
#include "mxtransitionmanager.h"
#include "isle.h"
#include "legobuildingmanager.h"
#include "legoplantmanager.h"
class LegoSoundManager;
// VTABLE 0x100d8638
// SIZE: 0x140
class LegoOmni : public MxOmni
{
public:
@@ -32,10 +37,17 @@ public:
virtual long Notify(MxParam &p); // vtable+04
// OFFSET: LEGO1 0x10058aa0
inline virtual const char *ClassName() const { return "LegoOmni"; }; // vtable+0c
inline virtual const char *ClassName() const // vtable+0c
{
// 0x100f671c
return "LegoOmni";
}
// OFFSET: LEGO1 0x10058ab0
inline virtual MxBool IsA(const char *name) const { return !strcmp(name, LegoOmni::ClassName()) || MxOmni::IsA(name); }; // vtable+10;
inline virtual MxBool IsA(const char *name) const // vtable+10
{
return !strcmp(name, LegoOmni::ClassName()) || MxOmni::IsA(name);
}
virtual void Init(); // vtable+14
virtual MxResult Create(MxOmniCreateParam &p); // vtable+18
@@ -54,6 +66,9 @@ public:
LegoSoundManager *GetSoundManager() { return (LegoSoundManager *)m_soundManager;}
MxBackgroundAudioManager *GetBackgroundAudioManager() { return m_bkgAudioManager; }
LegoInputManager *GetInputManager() { return m_inputMgr; }
Isle *GetIsle() { return m_isle; }
LegoBuildingManager *GetLegoBuildingManager() { return m_buildingManager; }
LegoPlantManager *GetLegoPlantManager() { return m_plantManager; }
LegoGameState *GetGameState() { return m_gameState; }
LegoNavController *GetNavController() { return m_navController; }
@@ -63,11 +78,16 @@ private:
LegoInputManager *m_inputMgr; // 0x70
char m_unk74[0x10];
LegoNavController *m_navController; // 0x84
char m_unk88[0x14];
Isle* m_isle; // 0x88
char m_unk8c[0x4];
LegoPlantManager* m_plantManager; // 0x90
char m_unk94[0x4];
LegoBuildingManager* m_buildingManager; // 0x98
LegoGameState *m_gameState; // 0x9c
char m_unka0[0x94];
MxBackgroundAudioManager *m_bkgAudioManager; // 0x134
MxTransitionManager *m_transitionManager; // 0x138
int m_unk13c;
};
@@ -95,4 +115,8 @@ __declspec(dllexport) LegoVideoManager * VideoManager();
__declspec(dllexport) long Start(MxDSAction *a);
LegoBuildingManager* BuildingManager();
Isle* GetIsle();
LegoPlantManager* PlantManager();
#endif // LEGOOMNI_H