diff --git a/LEGO1/mxcompositepresenter.cpp b/LEGO1/mxcompositepresenter.cpp index 342f3d96..06477c94 100644 --- a/LEGO1/mxcompositepresenter.cpp +++ b/LEGO1/mxcompositepresenter.cpp @@ -1,17 +1,18 @@ #include "mxcompositepresenter.h" #include "decomp.h" +#include "mxnotificationmanager.h" DECOMP_SIZE_ASSERT(MxCompositePresenter, 0x4c); -// OFFSET: LEGO1 0x100b60b0 STUB +// OFFSET: LEGO1 0x100b60b0 MxCompositePresenter::MxCompositePresenter() { - // TODO + NotificationManager()->Register(this); } -// OFFSET: LEGO1 0x100b6390 STUB +// OFFSET: LEGO1 0x100b6390 MxCompositePresenter::~MxCompositePresenter() { - // TODO + NotificationManager()->Unregister(this); } diff --git a/LEGO1/mxcompositepresenter.h b/LEGO1/mxcompositepresenter.h index 9f517652..0be080f0 100644 --- a/LEGO1/mxcompositepresenter.h +++ b/LEGO1/mxcompositepresenter.h @@ -2,6 +2,7 @@ #define MXCOMPOSITEPRESENTER_H #include "mxpresenter.h" +#include "mxunklist.h" // VTABLE 0x100dc618 // SIZE 0x4c @@ -24,9 +25,7 @@ public: return !strcmp(name, MxCompositePresenter::ClassName()) || MxPresenter::IsA(name); } - undefined m_unk40; - undefined4 *m_unk44; - undefined4 m_unk48; + MxUnkList m_list; }; #endif // MXCOMPOSITEPRESENTER_H diff --git a/LEGO1/mxdiskstreamprovider.h b/LEGO1/mxdiskstreamprovider.h index b6ff8c18..c797a0de 100644 --- a/LEGO1/mxdiskstreamprovider.h +++ b/LEGO1/mxdiskstreamprovider.h @@ -5,6 +5,7 @@ #include "mxstreamprovider.h" #include "mxthread.h" #include "mxcriticalsection.h" +#include "mxunklist.h" class MxDiskStreamProvider; @@ -23,32 +24,6 @@ private: MxDiskStreamProvider *m_target; }; -// TODO -struct MxDiskStreamListNode { - MxDiskStreamListNode *m_unk00; - MxDiskStreamListNode *m_unk04; - undefined4 m_unk08; -}; - -// TODO -struct MxDiskStreamList { - inline MxDiskStreamList() { - undefined unk; - this->m_unk00 = unk; - - MxDiskStreamListNode *node = new MxDiskStreamListNode(); - node->m_unk00 = node; - node->m_unk04 = node; - - this->m_head = node; - this->m_count = 0; - } - - undefined m_unk00; - MxDiskStreamListNode *m_head; - MxU32 m_count; -}; - // VTABLE 0x100dd138 class MxDiskStreamProvider : public MxStreamProvider { @@ -80,7 +55,7 @@ private: undefined m_remainingWork; // 0x34 undefined m_unk35; // 0x35 MxCriticalSection m_criticalSection; // 0x38 - MxDiskStreamList m_list; + MxUnkList m_list; }; #endif // MXDISKSTREAMPROVIDER_H diff --git a/LEGO1/mxunklist.h b/LEGO1/mxunklist.h new file mode 100644 index 00000000..af59f47b --- /dev/null +++ b/LEGO1/mxunklist.h @@ -0,0 +1,37 @@ +#ifndef MXUNKLIST_H +#define MXUNKLIST_H + +#include "decomp.h" +#include "mxtypes.h" + +/* +* This is an as-of-yet unknown list-like data structure. +* The class hierarchy/structure isn't quite correct yet. +*/ + +struct MxUnkListNode { + MxUnkListNode *m_unk00; + MxUnkListNode *m_unk04; + undefined4 m_unk08; +}; + +class MxUnkList { +public: + inline MxUnkList() { + undefined unk; + this->m_unk00 = unk; + + MxUnkListNode *node = new MxUnkListNode(); + node->m_unk00 = node; + node->m_unk04 = node; + + this->m_head = node; + this->m_count = 0; + } + + undefined m_unk00; + MxUnkListNode *m_head; + MxU32 m_count; +}; + +#endif // MXUNKLIST_H \ No newline at end of file