isle-portable/LEGO1/lego/legoomni/include/legoworld.h

149 lines
5.7 KiB
C
Raw Normal View History

#ifndef LEGOWORLD_H
#define LEGOWORLD_H
#include "legocameracontroller.h"
2023-10-24 19:38:27 -04:00
#include "legoentity.h"
#include "legoentitylist.h"
#include "legopathcontrollerlist.h"
#include "mxcorelist.h"
#include "mxpresenter.h"
#include "mxpresenterlist.h"
class IslePathActor;
class LegoPathBoundary;
2024-01-22 10:18:46 -05:00
struct PresenterSetCompare {
int operator()(MxPresenter* const& p_a, MxPresenter* const& p_b) const { return p_a > p_b; }
};
typedef set<MxPresenter*, PresenterSetCompare> MxPresenterSet;
(Proposal) Adjustments to "decomp" language (#308) * Adjustments to "decomp" language * Fix a comment * Fix accidental clang-formatting * Fix order * Fix order * Remove junk * Fix OFFSET * Adjustments based on new suggestions * Annotate globals * Globals in ISLE * More globals * Merge from parser2 branch * Allow prepending space for exact marker match * To eliminate noise, require the 0x prefix on offset for marker match * fix test from previous * Count tab stops for indented functions to reduce MISSED_END_OF_FUNCTION noise * FUNCTION to SYNTHETIC where needed * Missed marker conversion on SetAtomId * pylint cleanup, remove unused code * Fix unexpected function end, add more unit tests * Be more strict about synthetic name syntax * Revert "Missed marker conversion on SetAtomId" This reverts commit d87d665127fae7dd6e5bd48d9af14a0a829bf9e2. * Revert "FUNCTION to SYNTHETIC where needed" This reverts commit 8c815418d261ba8c5f67a9a2cae349fe4ac92db8. * Implicit lookup by name for functions * Fix VTABLE SYNTHETIC and other decomp markers * Get vtable class name * Vtable marker should identify struct * No colon for SIZE comment * Update README.md * Update README.md * Update CONTRIBUTING.md * Update README.md * Update README.md * Update CONTRIBUTING.md * Update README.md * Update CONTRIBUTING.md * Fix destructor/annotation * Update README.md * Update README.md * Update README.md * Update README.md * Update README.md --------- Co-authored-by: disinvite <disinvite@users.noreply.github.com>
2023-12-06 07:10:45 -05:00
// VTABLE: LEGO1 0x100d6280
// SIZE 0xf8
2023-10-24 19:38:27 -04:00
class LegoWorld : public LegoEntity {
public:
2023-10-24 19:38:27 -04:00
__declspec(dllexport) LegoWorld();
__declspec(dllexport) virtual ~LegoWorld(); // vtable+0x0
virtual MxLong Notify(MxParam& p_param) override; // vtable+0x4
virtual MxResult Tickle() override; // vtable+0x8
(Proposal) Adjustments to "decomp" language (#308) * Adjustments to "decomp" language * Fix a comment * Fix accidental clang-formatting * Fix order * Fix order * Remove junk * Fix OFFSET * Adjustments based on new suggestions * Annotate globals * Globals in ISLE * More globals * Merge from parser2 branch * Allow prepending space for exact marker match * To eliminate noise, require the 0x prefix on offset for marker match * fix test from previous * Count tab stops for indented functions to reduce MISSED_END_OF_FUNCTION noise * FUNCTION to SYNTHETIC where needed * Missed marker conversion on SetAtomId * pylint cleanup, remove unused code * Fix unexpected function end, add more unit tests * Be more strict about synthetic name syntax * Revert "Missed marker conversion on SetAtomId" This reverts commit d87d665127fae7dd6e5bd48d9af14a0a829bf9e2. * Revert "FUNCTION to SYNTHETIC where needed" This reverts commit 8c815418d261ba8c5f67a9a2cae349fe4ac92db8. * Implicit lookup by name for functions * Fix VTABLE SYNTHETIC and other decomp markers * Get vtable class name * Vtable marker should identify struct * No colon for SIZE comment * Update README.md * Update README.md * Update CONTRIBUTING.md * Update README.md * Update README.md * Update CONTRIBUTING.md * Update README.md * Update CONTRIBUTING.md * Fix destructor/annotation * Update README.md * Update README.md * Update README.md * Update README.md * Update README.md --------- Co-authored-by: disinvite <disinvite@users.noreply.github.com>
2023-12-06 07:10:45 -05:00
// FUNCTION: LEGO1 0x1001d690
2023-10-24 19:38:27 -04:00
inline virtual const char* ClassName() const override // vtable+0x0c
{
// STRING: LEGO1 0x100f0058
2023-10-24 19:38:27 -04:00
return "LegoWorld";
}
(Proposal) Adjustments to "decomp" language (#308) * Adjustments to "decomp" language * Fix a comment * Fix accidental clang-formatting * Fix order * Fix order * Remove junk * Fix OFFSET * Adjustments based on new suggestions * Annotate globals * Globals in ISLE * More globals * Merge from parser2 branch * Allow prepending space for exact marker match * To eliminate noise, require the 0x prefix on offset for marker match * fix test from previous * Count tab stops for indented functions to reduce MISSED_END_OF_FUNCTION noise * FUNCTION to SYNTHETIC where needed * Missed marker conversion on SetAtomId * pylint cleanup, remove unused code * Fix unexpected function end, add more unit tests * Be more strict about synthetic name syntax * Revert "Missed marker conversion on SetAtomId" This reverts commit d87d665127fae7dd6e5bd48d9af14a0a829bf9e2. * Revert "FUNCTION to SYNTHETIC where needed" This reverts commit 8c815418d261ba8c5f67a9a2cae349fe4ac92db8. * Implicit lookup by name for functions * Fix VTABLE SYNTHETIC and other decomp markers * Get vtable class name * Vtable marker should identify struct * No colon for SIZE comment * Update README.md * Update README.md * Update CONTRIBUTING.md * Update README.md * Update README.md * Update CONTRIBUTING.md * Update README.md * Update CONTRIBUTING.md * Fix destructor/annotation * Update README.md * Update README.md * Update README.md * Update README.md * Update README.md --------- Co-authored-by: disinvite <disinvite@users.noreply.github.com>
2023-12-06 07:10:45 -05:00
// FUNCTION: LEGO1 0x1001d6a0
inline virtual MxBool IsA(const char* p_name) const override // vtable+0x10
2023-10-24 19:38:27 -04:00
{
return !strcmp(p_name, LegoWorld::ClassName()) || LegoEntity::IsA(p_name);
2023-10-24 19:38:27 -04:00
}
virtual MxResult Create(MxDSAction& p_dsAction) override; // vtable+0x18
virtual void Destroy(MxBool p_fromDestructor) override; // vtable+0x1c
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+0x60
virtual MxBool VTable0x64(); // vtable+0x64
virtual void VTable0x68(MxBool p_add); // vtable+0x68
inline LegoCameraController* GetCamera() { return m_cameraController; }
inline undefined4 GetUnknown0xec() { return m_unk0xec; }
2023-10-24 19:38:27 -04:00
undefined FUN_100220e0();
void EndAction(MxCore* p_object);
void FUN_1001fc80(IslePathActor* p_actor);
2024-01-12 19:34:38 -05:00
MxBool FUN_100727e0(MxU32, Mx3DPointFloat& p_loc, Mx3DPointFloat& p_dir, Mx3DPointFloat& p_up);
MxBool FUN_10072980(MxU32, Mx3DPointFloat& p_loc, Mx3DPointFloat& p_dir, Mx3DPointFloat& p_up);
void FUN_10073400();
void FUN_10073430();
MxS32 GetCurrPathInfo(LegoPathBoundary** p_path, MxS32& p_value);
MxPresenter* FindPresenter(const char* p_presenter, const char* p_name);
MxPresenter* FUN_10021790(MxAtomId& p_atom, MxS32 p_entityId);
// SYNTHETIC: LEGO1 0x1001dee0
// LegoWorld::`scalar deleting destructor'
protected:
LegoPathControllerList m_list0x68; // 0x68
MxPresenterList m_list0x80; // 0x80
LegoCameraController* m_cameraController; // 0x98
LegoEntityList* m_entityList; // 0x9c
MxCoreList* m_coreList; // 0xa0
2024-01-22 10:18:46 -05:00
undefined m_unk0xa4; // 0xa4
MxPresenterSet m_set0xa8; // 0xa8
MxPresenterList m_list0xb8; // 0xb8
2024-01-22 10:18:46 -05:00
MxPresenterSet m_set0xd0; // 0xd0
list<AutoROI*> m_list0xe0; // 0xe0
undefined4 m_unk0xec; // 0xec
undefined4 m_unk0xf0; // 0xf0
MxS16 m_unk0xf4; // 0xf4
MxBool m_worldStarted; // 0xf6
undefined m_unk0xf7; // 0xf7
};
2024-01-22 10:18:46 -05:00
// clang-format off
// TEMPLATE: LEGO1 0x1001d780
// _Tree<MxPresenter *,MxPresenter *,set<MxPresenter *,PresenterSetCompare,allocator<MxPresenter *> >::_Kfn,PresenterSetCompare,allocator<MxPresenter *> >::~_Tree<MxPresenter *,MxPresenter *,set<MxPresenter *,PresenterSetCompare,allocator<MxPresenter *> >::_Kfn,PresenterSetCompare,allocator<MxPresenter *> >
// TEMPLATE: LEGO1 0x1001d850
// _Tree<MxPresenter *,MxPresenter *,set<MxPresenter *,PresenterSetCompare,allocator<MxPresenter *> >::_Kfn,PresenterSetCompare,allocator<MxPresenter *> >::iterator::_Inc
// TEMPLATE: LEGO1 0x1001d890
// _Tree<MxPresenter *,MxPresenter *,set<MxPresenter *,PresenterSetCompare,allocator<MxPresenter *> >::_Kfn,PresenterSetCompare,allocator<MxPresenter *> >::erase
// TEMPLATE: LEGO1 0x1001dcf0
// _Tree<MxPresenter *,MxPresenter *,set<MxPresenter *,PresenterSetCompare,allocator<MxPresenter *> >::_Kfn,PresenterSetCompare,allocator<MxPresenter *> >::_Erase
// TEMPLATE: LEGO1 0x1001dd30
// _Tree<MxPresenter *,MxPresenter *,set<MxPresenter *,PresenterSetCompare,allocator<MxPresenter *> >::_Kfn,PresenterSetCompare,allocator<MxPresenter *> >::_Init
// TEMPLATE: LEGO1 0x1001ddf0
// list<AutoROI *,allocator<AutoROI *> >::~list<AutoROI *,allocator<AutoROI *> >
// TEMPLATE: LEGO1 0x1001df50
// List<AutoROI *>::~List<AutoROI *>
// TEMPLATE: LEGO1 0x1001de60
// list<AutoROI *,allocator<AutoROI *> >::_Buynode
// TEMPLATE: LEGO1 0x1001de90
// set<MxPresenter *,PresenterSetCompare,allocator<MxPresenter *> >::~set<MxPresenter *,PresenterSetCompare,allocator<MxPresenter *> >
// TEMPLATE: LEGO1 0x1001df00
// Set<MxPresenter *,PresenterSetCompare>::~Set<MxPresenter *,PresenterSetCompare>
// clang-format om
// SYNTHETIC: LEGO1 0x1001eed0
// MxPresenterListCursor::`scalar deleting destructor'
// TEMPLATE: LEGO1 0x1001ef40
// MxPtrListCursor<MxPresenter>::~MxPtrListCursor<MxPresenter>
// SYNTHETIC: LEGO1 0x1001ef90
// MxListCursor<MxPresenter *>::`scalar deleting destructor'
// SYNTHETIC: LEGO1 0x1001f000
// MxPtrListCursor<MxPresenter>::`scalar deleting destructor'
// TEMPLATE: LEGO1 0x1001f070
// MxListCursor<MxPresenter *>::~MxListCursor<MxPresenter *>
// FUNCTION: LEGO1 0x1001f0c0
// MxPresenterListCursor::~MxPresenterListCursor
// TEMPLATE: LEGO1 0x10020760
// MxListCursor<MxPresenter *>::MxListCursor<MxPresenter *>
2024-01-22 10:18:46 -05:00
// GLOBAL: LEGO1 0x100f11a0
// _Tree<MxPresenter *,MxPresenter *,set<MxPresenter *,PresenterSetCompare,allocator<MxPresenter *> >::_Kfn,PresenterSetCompare,allocator<MxPresenter *> >::_Nil
#endif // LEGOWORLD_H