Clear unknowns in LegoActionControlPresenter

This commit is contained in:
Fabian Neundorf 2026-01-13 22:25:28 +01:00
parent 600079215f
commit e25289a02b
2 changed files with 12 additions and 12 deletions

View File

@ -10,7 +10,7 @@
// SIZE 0x68 // SIZE 0x68
class LegoActionControlPresenter : public MxMediaPresenter { class LegoActionControlPresenter : public MxMediaPresenter {
public: public:
LegoActionControlPresenter() : m_unk0x50(Extra::ActionType::e_none) {} LegoActionControlPresenter() : m_actionType(Extra::ActionType::e_none) {}
~LegoActionControlPresenter() override { Destroy(TRUE); } // vtable+0x00 ~LegoActionControlPresenter() override { Destroy(TRUE); } // vtable+0x00
// FUNCTION: BETA10 0x100a7840 // FUNCTION: BETA10 0x100a7840
@ -40,9 +40,9 @@ class LegoActionControlPresenter : public MxMediaPresenter {
virtual void Destroy(MxBool p_fromDestructor); // vtable+0x5c virtual void Destroy(MxBool p_fromDestructor); // vtable+0x5c
private: private:
Extra::ActionType m_unk0x50; // 0x50 Extra::ActionType m_actionType; // 0x50
MxString m_unk0x54; // 0x54 MxString m_sourceName; // 0x54
undefined4 m_unk0x64; // 0x64 undefined4 m_streamId; // 0x64
}; };
// SYNTHETIC: LEGO1 0x1000d1d0 // SYNTHETIC: LEGO1 0x1000d1d0

View File

@ -36,11 +36,11 @@ void LegoActionControlPresenter::ReadyTickle()
void LegoActionControlPresenter::RepeatingTickle() void LegoActionControlPresenter::RepeatingTickle()
{ {
if (IsEnabled()) { if (IsEnabled()) {
if (m_unk0x50 == 0) { if (m_actionType == 0) {
ParseExtra(); ParseExtra();
} }
InvokeAction(m_unk0x50, MxAtomId(m_unk0x54.GetData(), e_lowerCase2), m_unk0x64, NULL); InvokeAction(m_actionType, MxAtomId(m_sourceName.GetData(), e_lowerCase2), m_streamId, NULL);
ProgressTickleState(e_done); ProgressTickleState(e_done);
} }
} }
@ -84,15 +84,15 @@ void LegoActionControlPresenter::ParseExtra()
char output[1024]; char output[1024];
if (KeyValueStringParse(output, g_strACTION, extraCopy)) { if (KeyValueStringParse(output, g_strACTION, extraCopy)) {
m_unk0x50 = MatchActionString(strtok(output, g_parseExtraTokens)); m_actionType = MatchActionString(strtok(output, g_parseExtraTokens));
if (m_unk0x50 != Extra::ActionType::e_exit) { if (m_actionType != Extra::ActionType::e_exit) {
MakeSourceName(extraCopy, strtok(NULL, g_parseExtraTokens)); MakeSourceName(extraCopy, strtok(NULL, g_parseExtraTokens));
m_unk0x54 = extraCopy; m_sourceName = extraCopy;
m_unk0x54.ToLowerCase(); m_sourceName.ToLowerCase();
if (m_unk0x50 != Extra::ActionType::e_run) { if (m_actionType != Extra::ActionType::e_run) {
m_unk0x64 = atoi(strtok(NULL, g_parseExtraTokens)); m_streamId = atoi(strtok(NULL, g_parseExtraTokens));
} }
} }
} }