push changes

This commit is contained in:
Misha 2024-01-13 18:30:07 -05:00
parent 8b34b38ac0
commit c6dc8021b6
No known key found for this signature in database
GPG Key ID: 8441D12AEF33FED8
3 changed files with 29 additions and 3 deletions

View File

@ -28,6 +28,12 @@ class LegoWorldList : public MxPtrList<LegoWorld> {
}; // vtable+0x14
};
// VTABLE: LEGO1 0x100d75a0
class LegoWorldListCursor : public MxListCursor<LegoWorld*> {
public:
LegoWorldListCursor(LegoWorldList* p_list) : MxListCursor<LegoWorld*>(p_list){};
};
// TEMPLATE: LEGO1 0x100598f0
// MxCollection<LegoWorld *>::Compare
@ -52,4 +58,7 @@ class LegoWorldList : public MxPtrList<LegoWorld> {
// SYNTHETIC: LEGO1 0x10059be0
// MxPtrList<LegoWorld>::`scalar deleting destructor'
// SYNTHETIC: LEGO1 0x1003e870
// LegoWorldListCursor::`scalar deleting destructor'
#endif // LEGOWORLDLIST_H

View File

@ -597,11 +597,25 @@ void LegoOmni::RemoveWorld(const MxAtomId&, MxLong)
// TODO
}
// STUB: LEGO1 0x1005b0c0
// FUNCTION: LEGO1 0x1005b0c0
LegoEntity* LegoOmni::FindByEntityIdOrAtomId(const MxAtomId& p_atom, MxS32 p_entityid)
{
// TODO
return NULL;
if (m_worldList) {
LegoWorld* world;
LegoWorldListCursor cursor(m_worldList);
while (cursor.Next()) {
if ((p_entityid != -1 && world->GetEntityId() == p_entityid) ||
(p_atom.GetInternal() && world->GetAtom() == p_atom)) {
return world;
}
}
return NULL;
}
else {
return NULL;
}
}
// STUB: LEGO1 0x1005b1d0

View File

@ -45,6 +45,9 @@ class MxEntity : public MxCore {
return SUCCESS;
}
inline MxS32 GetEntityId() { return m_mxEntityId; }
inline MxAtomId& GetAtom() { return m_atom; }
protected:
MxS32 m_mxEntityId; // 0x8
MxAtomId m_atom; // 0xc