isle-portable/LEGO1/mxactionnotificationparam.h

68 lines
1.6 KiB
C
Raw Normal View History

#ifndef MXACTIONNOTIFICATIONPARAM_H
#define MXACTIONNOTIFICATIONPARAM_H
#include "mxdsaction.h"
2023-10-24 19:38:27 -04:00
#include "mxnotificationparam.h"
// VTABLE 0x100d8350
// SIZE 0x14
2023-10-24 19:38:27 -04:00
class MxActionNotificationParam : public MxNotificationParam {
public:
2023-10-24 19:38:27 -04:00
inline MxActionNotificationParam(MxParamType p_type, MxCore* p_sender, MxDSAction* p_action, MxBool p_reallocAction)
: MxNotificationParam(p_type, p_sender)
{
MxDSAction* oldAction = p_action;
this->m_realloc = p_reallocAction;
2023-10-24 19:38:27 -04:00
if (p_reallocAction)
this->m_action = new MxDSAction();
else {
this->m_action = oldAction;
return;
}
2023-10-24 19:38:27 -04:00
this->m_action->SetAtomId(oldAction->GetAtomId());
this->m_action->SetObjectId(oldAction->GetObjectId());
this->m_action->SetUnknown24(oldAction->GetUnknown24());
}
2023-10-24 19:38:27 -04:00
// OFFSET: LEGO1 0x10051050
inline virtual ~MxActionNotificationParam() override
{
if (!this->m_realloc)
return;
2023-10-24 19:38:27 -04:00
if (this->m_action)
delete this->m_action;
}
2023-10-24 19:38:27 -04:00
virtual MxNotificationParam* Clone() override; // vtable+0x4
2023-10-24 19:38:27 -04:00
inline MxDSAction* GetAction() { return m_action; }
protected:
2023-10-24 19:38:27 -04:00
MxDSAction* m_action; // 0xc
MxBool m_realloc; // 0x10
};
// VTABLE 0x100d8358
// SIZE 0x14
2023-10-24 19:38:27 -04:00
class MxEndActionNotificationParam : public MxActionNotificationParam {
public:
2023-10-24 19:38:27 -04:00
inline MxEndActionNotificationParam(
MxParamType p_type,
MxCore* p_sender,
MxDSAction* p_action,
MxBool p_reallocAction
)
: MxActionNotificationParam(p_type, p_sender, p_action, p_reallocAction)
{
}
2023-10-24 19:38:27 -04:00
inline virtual ~MxEndActionNotificationParam() override{}; // 0x100513a0
2023-10-24 19:38:27 -04:00
virtual MxNotificationParam* Clone() override; // vtable+0x4
};
2023-10-24 19:24:29 -04:00
#endif