diff --git a/LEGO1/lego/legoomni/include/legopathcontroller.h b/LEGO1/lego/legoomni/include/legopathcontroller.h index 4636b928..ba8674e1 100644 --- a/LEGO1/lego/legoomni/include/legopathcontroller.h +++ b/LEGO1/lego/legoomni/include/legopathcontroller.h @@ -4,6 +4,7 @@ #include "decomp.h" #include "legopathactor.h" #include "mxcore.h" + class LegoPathBoundary; class LegoWorld; @@ -38,7 +39,7 @@ class LegoPathController : public MxCore { undefined4 FUN_10046770(LegoPathActor* p_actor); MxResult FUN_10046b30(LegoPathBoundary** p_path, MxS32& p_value); void Enable(MxBool p_enable); - void FUN_10046bb0(LegoWorld* world); + void FUN_10046bb0(LegoWorld* p_world); private: undefined4 m_unk0x08; // 0x08 diff --git a/LEGO1/lego/legoomni/src/paths/legopathpresenter.cpp b/LEGO1/lego/legoomni/src/paths/legopathpresenter.cpp index a191bffd..82048534 100644 --- a/LEGO1/lego/legoomni/src/paths/legopathpresenter.cpp +++ b/LEGO1/lego/legoomni/src/paths/legopathpresenter.cpp @@ -9,7 +9,7 @@ DECOMP_SIZE_ASSERT(LegoPathPresenter, 0x54) // STRING: LEGO1 0x10101ef0 // GLOBAL: LEGO1 0x101020c4 -char* g_triggersSource = "TRIGGERS_SOURCE"; +const char* g_triggersSource = "TRIGGERS_SOURCE"; // FUNCTION: LEGO1 0x100448d0 LegoPathPresenter::LegoPathPresenter() @@ -68,11 +68,14 @@ void LegoPathPresenter::Destroy() void LegoPathPresenter::ReadyTickle() { LegoWorld* currentWorld = CurrentWorld(); + if (currentWorld) { MxStreamChunk* chunk = m_subscriber->PopData(); + if (chunk) { LegoPathController* controller = new LegoPathController(); - if (controller == NULL) { + + if (controller != NULL) { EndAction(); } else { @@ -126,7 +129,7 @@ void LegoPathPresenter::ParseExtra() strupr(extraCopy); - if (KeyValueStringParse(output, g_triggersSource, extraCopy) != 0) { + if (KeyValueStringParse(output, g_triggersSource, extraCopy) != FALSE) { m_trigger = MxAtomId(output, e_lowerCase2); } }