From 1b1d2ecde6b62610231def868fbde3870de2a6fb Mon Sep 17 00:00:00 2001 From: Christian Semmler Date: Sat, 4 May 2024 08:06:32 -0400 Subject: [PATCH] Refactor LegoOmni into LegoMain/Scripts (#883) * Refactor LegoOmni into LegoMain/Scripts * Fix guard --- CMakeLists.txt | 3 +- ISLE/isleapp.cpp | 2 +- .../include/{legoomni.h => legomain.h} | 43 +--- LEGO1/lego/legoomni/include/legoutils.h | 3 + LEGO1/lego/legoomni/include/scripts.h | 39 ++++ LEGO1/lego/legoomni/src/actors/ambulance.cpp | 2 +- LEGO1/lego/legoomni/src/actors/bike.cpp | 2 +- LEGO1/lego/legoomni/src/actors/helicopter.cpp | 2 +- LEGO1/lego/legoomni/src/actors/isleactor.cpp | 2 +- .../legoomni/src/actors/islepathactor.cpp | 2 +- .../legoomni/src/actors/jukeboxentity.cpp | 2 +- LEGO1/lego/legoomni/src/actors/radio.cpp | 2 +- LEGO1/lego/legoomni/src/actors/skateboard.cpp | 2 +- .../src/audio/mxbackgroundaudiomanager.cpp | 2 +- .../src/common/legoactioncontrolpresenter.cpp | 2 +- .../src/common/legoanimationmanager.cpp | 2 +- .../legoomni/src/common/legogamestate.cpp | 3 +- LEGO1/lego/legoomni/src/common/legoutils.cpp | 16 +- LEGO1/lego/legoomni/src/common/misc.cpp | 3 +- .../legoomni/src/entity/legonavcontroller.cpp | 2 +- .../legoomni/src/entity/legopovcontroller.cpp | 2 +- LEGO1/lego/legoomni/src/entity/legoworld.cpp | 2 +- .../src/entity/legoworldpresenter.cpp | 2 +- .../src/gasstation/gasstationentity.cpp | 2 +- .../legoomni/src/hospital/hospitalentity.cpp | 2 +- .../src/infocenter/infocenterentity.cpp | 2 +- .../legoomni/src/input/legoinputmanager.cpp | 3 +- .../legoomni/src/isle/beachhouseentity.cpp | 2 +- LEGO1/lego/legoomni/src/isle/radiostate.cpp | 2 +- .../src/main/{legoomni.cpp => legomain.cpp} | 202 +----------------- LEGO1/lego/legoomni/src/main/scripts.cpp | 189 ++++++++++++++++ .../lego/legoomni/src/police/policeentity.cpp | 2 +- .../lego/legoomni/src/police/policestate.cpp | 2 +- .../legoomni/src/race/racestandsentity.cpp | 2 +- .../src/video/legolocomotionanimpresenter.cpp | 2 +- .../legoomni/src/video/legovideomanager.cpp | 2 +- .../legoomni/src/worlds/elevatorbottom.cpp | 2 +- LEGO1/lego/legoomni/src/worlds/gasstation.cpp | 3 +- LEGO1/lego/legoomni/src/worlds/hospital.cpp | 3 +- LEGO1/lego/legoomni/src/worlds/infocenter.cpp | 3 +- .../legoomni/src/worlds/infocenterdoor.cpp | 3 +- LEGO1/lego/legoomni/src/worlds/isle.cpp | 3 +- LEGO1/lego/legoomni/src/worlds/jukebox.cpp | 2 +- LEGO1/lego/legoomni/src/worlds/police.cpp | 2 +- .../legoomni/src/worlds/registrationbook.cpp | 2 +- LEGO1/lego/legoomni/src/worlds/score.cpp | 3 +- 46 files changed, 301 insertions(+), 281 deletions(-) rename LEGO1/lego/legoomni/include/{legoomni.h => legomain.h} (84%) create mode 100644 LEGO1/lego/legoomni/include/scripts.h rename LEGO1/lego/legoomni/src/main/{legoomni.cpp => legomain.cpp} (69%) create mode 100644 LEGO1/lego/legoomni/src/main/scripts.cpp diff --git a/CMakeLists.txt b/CMakeLists.txt index 96ad9343..db8739cf 100644 --- a/CMakeLists.txt +++ b/CMakeLists.txt @@ -367,7 +367,8 @@ add_library(lego1 SHARED LEGO1/lego/legoomni/src/isle/beachhouseentity.cpp LEGO1/lego/legoomni/src/isle/jukeboxstate.cpp LEGO1/lego/legoomni/src/isle/radiostate.cpp - LEGO1/lego/legoomni/src/main/legoomni.cpp + LEGO1/lego/legoomni/src/main/legomain.cpp + LEGO1/lego/legoomni/src/main/scripts.cpp LEGO1/lego/legoomni/src/notify/legoeventnotificationparam.cpp LEGO1/lego/legoomni/src/paths/legoanimactor.cpp LEGO1/lego/legoomni/src/paths/legoextraactor.cpp diff --git a/ISLE/isleapp.cpp b/ISLE/isleapp.cpp index bb017de3..6f6296aa 100644 --- a/ISLE/isleapp.cpp +++ b/ISLE/isleapp.cpp @@ -6,8 +6,8 @@ #include "legobuildingmanager.h" #include "legogamestate.h" #include "legoinputmanager.h" +#include "legomain.h" #include "legomodelpresenter.h" -#include "legoomni.h" #include "legopartpresenter.h" #include "legovideomanager.h" #include "legoworldpresenter.h" diff --git a/LEGO1/lego/legoomni/include/legoomni.h b/LEGO1/lego/legoomni/include/legomain.h similarity index 84% rename from LEGO1/lego/legoomni/include/legoomni.h rename to LEGO1/lego/legoomni/include/legomain.h index e21e8111..1d2191d5 100644 --- a/LEGO1/lego/legoomni/include/legoomni.h +++ b/LEGO1/lego/legoomni/include/legomain.h @@ -1,5 +1,5 @@ -#ifndef LEGOOMNI_H -#define LEGOOMNI_H +#ifndef LEGOMAIN_H +#define LEGOMAIN_H #include "compat.h" #include "mxdsaction.h" @@ -27,35 +27,6 @@ class MxBackgroundAudioManager; class MxTransitionManager; class ViewLODListManager; -extern MxAtomId* g_copterScript; -extern MxAtomId* g_dunecarScript; -extern MxAtomId* g_jetskiScript; -extern MxAtomId* g_racecarScript; -extern MxAtomId* g_carraceScript; -extern MxAtomId* g_carracerScript; -extern MxAtomId* g_jetraceScript; -extern MxAtomId* g_jetracerScript; -extern MxAtomId* g_isleScript; -extern MxAtomId* g_elevbottScript; -extern MxAtomId* g_infodoorScript; -extern MxAtomId* g_infomainScript; -extern MxAtomId* g_infoscorScript; -extern MxAtomId* g_regbookScript; -extern MxAtomId* g_histbookScript; -extern MxAtomId* g_hospitalScript; -extern MxAtomId* g_policeScript; -extern MxAtomId* g_garageScript; -extern MxAtomId* g_act2mainScript; -extern MxAtomId* g_act3Script; -extern MxAtomId* g_jukeboxScript; -extern MxAtomId* g_pz5Script; -extern MxAtomId* g_introScript; -extern MxAtomId* g_testScript; -extern MxAtomId* g_jukeboxwScript; -extern MxAtomId* g_sndAnimScript; -extern MxAtomId* g_creditsScript; -extern MxAtomId* g_nocdSourceName; - // VTABLE: LEGO1 0x100d8638 // SIZE 0x140 class LegoOmni : public MxOmni { @@ -205,12 +176,4 @@ class LegoOmni : public MxOmni { MxBool m_unk0x13c; // 0x13c }; -const char* GetNoCD_SourceName(); - -LegoEntity* PickEntity(MxLong, MxLong); -LegoROI* PickROI(MxLong, MxLong); - -void CreateScripts(); -void DestroyScripts(); - -#endif // LEGOOMNI_H +#endif // LEGOMAIN_H diff --git a/LEGO1/lego/legoomni/include/legoutils.h b/LEGO1/lego/legoomni/include/legoutils.h index 687d7d24..b2a345d7 100644 --- a/LEGO1/lego/legoomni/include/legoutils.h +++ b/LEGO1/lego/legoomni/include/legoutils.h @@ -11,8 +11,11 @@ class LegoEntity; class LegoFile; class LegoAnimPresenter; class LegoNamedTexture; +class LegoROI; class LegoTreeNode; +LegoEntity* PickEntity(MxLong, MxLong); +LegoROI* PickROI(MxLong, MxLong); MxS16 CountTotalTreeNodes(LegoTreeNode* p_node); void FUN_1003e050(LegoAnimPresenter* p_presenter); Extra::ActionType MatchActionString(const char*); diff --git a/LEGO1/lego/legoomni/include/scripts.h b/LEGO1/lego/legoomni/include/scripts.h new file mode 100644 index 00000000..a47c8995 --- /dev/null +++ b/LEGO1/lego/legoomni/include/scripts.h @@ -0,0 +1,39 @@ +#ifndef SCRIPTS_H +#define SCRIPTS_H + +class MxAtomId; + +extern MxAtomId* g_copterScript; +extern MxAtomId* g_dunecarScript; +extern MxAtomId* g_jetskiScript; +extern MxAtomId* g_racecarScript; +extern MxAtomId* g_carraceScript; +extern MxAtomId* g_carracerScript; +extern MxAtomId* g_jetraceScript; +extern MxAtomId* g_jetracerScript; +extern MxAtomId* g_isleScript; +extern MxAtomId* g_elevbottScript; +extern MxAtomId* g_infodoorScript; +extern MxAtomId* g_infomainScript; +extern MxAtomId* g_infoscorScript; +extern MxAtomId* g_regbookScript; +extern MxAtomId* g_histbookScript; +extern MxAtomId* g_hospitalScript; +extern MxAtomId* g_policeScript; +extern MxAtomId* g_garageScript; +extern MxAtomId* g_act2mainScript; +extern MxAtomId* g_act3Script; +extern MxAtomId* g_jukeboxScript; +extern MxAtomId* g_pz5Script; +extern MxAtomId* g_introScript; +extern MxAtomId* g_testScript; +extern MxAtomId* g_jukeboxwScript; +extern MxAtomId* g_sndAnimScript; +extern MxAtomId* g_creditsScript; +extern MxAtomId* g_nocdSourceName; + +void CreateScripts(); +void DestroyScripts(); +const char* GetNoCD_SourceName(); + +#endif // SCRIPTS_H diff --git a/LEGO1/lego/legoomni/src/actors/ambulance.cpp b/LEGO1/lego/legoomni/src/actors/ambulance.cpp index 933f96f9..d793503b 100644 --- a/LEGO1/lego/legoomni/src/actors/ambulance.cpp +++ b/LEGO1/lego/legoomni/src/actors/ambulance.cpp @@ -4,7 +4,6 @@ #include "decomp.h" #include "legocontrolmanager.h" #include "legogamestate.h" -#include "legoomni.h" #include "legovariables.h" #include "legoworld.h" #include "misc.h" @@ -12,6 +11,7 @@ #include "mxticklemanager.h" #include "mxtimer.h" #include "mxvariabletable.h" +#include "scripts.h" DECOMP_SIZE_ASSERT(Ambulance, 0x184) diff --git a/LEGO1/lego/legoomni/src/actors/bike.cpp b/LEGO1/lego/legoomni/src/actors/bike.cpp index 14133abd..e6be2228 100644 --- a/LEGO1/lego/legoomni/src/actors/bike.cpp +++ b/LEGO1/lego/legoomni/src/actors/bike.cpp @@ -3,10 +3,10 @@ #include "isle_actions.h" #include "legocontrolmanager.h" #include "legogamestate.h" -#include "legoomni.h" #include "legoutils.h" #include "legoworld.h" #include "misc.h" +#include "scripts.h" DECOMP_SIZE_ASSERT(Bike, 0x164) diff --git a/LEGO1/lego/legoomni/src/actors/helicopter.cpp b/LEGO1/lego/legoomni/src/actors/helicopter.cpp index 3158452c..3199cebb 100644 --- a/LEGO1/lego/legoomni/src/actors/helicopter.cpp +++ b/LEGO1/lego/legoomni/src/actors/helicopter.cpp @@ -12,11 +12,11 @@ #include "legocameracontroller.h" #include "legocontrolmanager.h" #include "legogamestate.h" -#include "legoomni.h" #include "legoutils.h" #include "legoworld.h" #include "misc.h" #include "mxtransitionmanager.h" +#include "scripts.h" DECOMP_SIZE_ASSERT(Helicopter, 0x230) DECOMP_SIZE_ASSERT(Mx3DPointFloat, 0x14) diff --git a/LEGO1/lego/legoomni/src/actors/isleactor.cpp b/LEGO1/lego/legoomni/src/actors/isleactor.cpp index 5653be65..a09c62d7 100644 --- a/LEGO1/lego/legoomni/src/actors/isleactor.cpp +++ b/LEGO1/lego/legoomni/src/actors/isleactor.cpp @@ -1,10 +1,10 @@ #include "isleactor.h" #include "legoentity.h" -#include "legoomni.h" #include "legoworld.h" #include "misc.h" #include "mxnotificationparam.h" +#include "scripts.h" DECOMP_SIZE_ASSERT(IsleActor, 0x7c) diff --git a/LEGO1/lego/legoomni/src/actors/islepathactor.cpp b/LEGO1/lego/legoomni/src/actors/islepathactor.cpp index 607892bd..1fddee51 100644 --- a/LEGO1/lego/legoomni/src/actors/islepathactor.cpp +++ b/LEGO1/lego/legoomni/src/actors/islepathactor.cpp @@ -4,13 +4,13 @@ #include "jukebox_actions.h" #include "legoanimationmanager.h" #include "legonavcontroller.h" -#include "legoomni.h" #include "legopathboundary.h" #include "legoutils.h" #include "legovideomanager.h" #include "legoworld.h" #include "misc.h" #include "mxnotificationparam.h" +#include "scripts.h" DECOMP_SIZE_ASSERT(IslePathActor, 0x160) DECOMP_SIZE_ASSERT(IslePathActor::SpawnLocation, 0x38) diff --git a/LEGO1/lego/legoomni/src/actors/jukeboxentity.cpp b/LEGO1/lego/legoomni/src/actors/jukeboxentity.cpp index a1f5c430..ade45933 100644 --- a/LEGO1/lego/legoomni/src/actors/jukeboxentity.cpp +++ b/LEGO1/lego/legoomni/src/actors/jukeboxentity.cpp @@ -6,7 +6,6 @@ #include "jukebox_actions.h" #include "jukeboxstate.h" #include "legogamestate.h" -#include "legoomni.h" #include "legoutils.h" #include "misc.h" #include "mxbackgroundaudiomanager.h" @@ -14,6 +13,7 @@ #include "mxnotificationmanager.h" #include "mxnotificationparam.h" #include "mxtransitionmanager.h" +#include "scripts.h" DECOMP_SIZE_ASSERT(JukeBoxEntity, 0x6c) diff --git a/LEGO1/lego/legoomni/src/actors/radio.cpp b/LEGO1/lego/legoomni/src/actors/radio.cpp index 1d69d623..a04523b1 100644 --- a/LEGO1/lego/legoomni/src/actors/radio.cpp +++ b/LEGO1/lego/legoomni/src/actors/radio.cpp @@ -3,7 +3,6 @@ #include "isle_actions.h" #include "legocontrolmanager.h" #include "legogamestate.h" -#include "legoomni.h" #include "legoworld.h" #include "misc.h" #include "mxactionnotificationparam.h" @@ -12,6 +11,7 @@ #include "mxmisc.h" #include "mxnotificationmanager.h" #include "radiostate.h" +#include "scripts.h" DECOMP_SIZE_ASSERT(Radio, 0x10) diff --git a/LEGO1/lego/legoomni/src/actors/skateboard.cpp b/LEGO1/lego/legoomni/src/actors/skateboard.cpp index 37016797..352e0bba 100644 --- a/LEGO1/lego/legoomni/src/actors/skateboard.cpp +++ b/LEGO1/lego/legoomni/src/actors/skateboard.cpp @@ -7,7 +7,6 @@ #include "jukebox_actions.h" #include "legoanimationmanager.h" #include "legocontrolmanager.h" -#include "legoomni.h" #include "legoutils.h" #include "misc.h" #include "mxmisc.h" @@ -15,6 +14,7 @@ #include "mxstillpresenter.h" #include "mxtransitionmanager.h" #include "pizza.h" +#include "scripts.h" DECOMP_SIZE_ASSERT(SkateBoard, 0x168) diff --git a/LEGO1/lego/legoomni/src/audio/mxbackgroundaudiomanager.cpp b/LEGO1/lego/legoomni/src/audio/mxbackgroundaudiomanager.cpp index 04d8cbc8..d10888ff 100644 --- a/LEGO1/lego/legoomni/src/audio/mxbackgroundaudiomanager.cpp +++ b/LEGO1/lego/legoomni/src/audio/mxbackgroundaudiomanager.cpp @@ -1,6 +1,6 @@ #include "mxbackgroundaudiomanager.h" -#include "legoomni.h" +#include "legomain.h" #include "misc.h" #include "mxaudiopresenter.h" #include "mxcompositepresenter.h" diff --git a/LEGO1/lego/legoomni/src/common/legoactioncontrolpresenter.cpp b/LEGO1/lego/legoomni/src/common/legoactioncontrolpresenter.cpp index c0e8d07a..607a0595 100644 --- a/LEGO1/lego/legoomni/src/common/legoactioncontrolpresenter.cpp +++ b/LEGO1/lego/legoomni/src/common/legoactioncontrolpresenter.cpp @@ -2,7 +2,7 @@ #include "define.h" #include "extra.h" -#include "legoomni.h" +#include "legomain.h" #include "legoutils.h" #include "mxcompositepresenter.h" #include "mxdssubscriber.h" diff --git a/LEGO1/lego/legoomni/src/common/legoanimationmanager.cpp b/LEGO1/lego/legoomni/src/common/legoanimationmanager.cpp index 6160fd3b..8f304edf 100644 --- a/LEGO1/lego/legoomni/src/common/legoanimationmanager.cpp +++ b/LEGO1/lego/legoomni/src/common/legoanimationmanager.cpp @@ -7,7 +7,7 @@ #include "legoendanimnotificationparam.h" #include "legoextraactor.h" #include "legogamestate.h" -#include "legoomni.h" +#include "legomain.h" #include "legoroilist.h" #include "legovideomanager.h" #include "legoworld.h" diff --git a/LEGO1/lego/legoomni/src/common/legogamestate.cpp b/LEGO1/lego/legoomni/src/common/legogamestate.cpp index 3237e165..4a64743e 100644 --- a/LEGO1/lego/legoomni/src/common/legogamestate.cpp +++ b/LEGO1/lego/legoomni/src/common/legogamestate.cpp @@ -33,8 +33,8 @@ #include "legobuildingmanager.h" #include "legocharactermanager.h" #include "legofullscreenmovie.h" +#include "legomain.h" #include "legonavcontroller.h" -#include "legoomni.h" #include "legoplantmanager.h" #include "legostate.h" #include "legoutils.h" @@ -54,6 +54,7 @@ #include "racecar_actions.h" #include "regbook_actions.h" #include "roi/legoroi.h" +#include "scripts.h" #include "sndanim_actions.h" #include diff --git a/LEGO1/lego/legoomni/src/common/legoutils.cpp b/LEGO1/lego/legoomni/src/common/legoutils.cpp index ae6e3d29..0390d032 100644 --- a/LEGO1/lego/legoomni/src/common/legoutils.cpp +++ b/LEGO1/lego/legoomni/src/common/legoutils.cpp @@ -7,8 +7,8 @@ #include "legoanimpresenter.h" #include "legogamestate.h" #include "legoinputmanager.h" +#include "legomain.h" #include "legonamedtexture.h" -#include "legoomni.h" #include "legosoundmanager.h" #include "legovideomanager.h" #include "legoworld.h" @@ -23,11 +23,25 @@ #include "mxutilities.h" #include "mxvariabletable.h" #include "realtime/realtime.h" +#include "scripts.h" #include #include #include +// FUNCTION: LEGO1 0x1003dd70 +LegoROI* PickROI(MxLong p_a, MxLong p_b) +{ + return (LegoROI*) VideoManager()->Get3DManager()->GetLego3DView()->Pick(p_a, p_b); +} + +// STUB: LEGO1 0x1003ddc0 +LegoEntity* PickEntity(MxLong, MxLong) +{ + // TODO + return NULL; +} + // FUNCTION: LEGO1 0x1003df90 MxS16 CountTotalTreeNodes(LegoTreeNode* p_node) { diff --git a/LEGO1/lego/legoomni/src/common/misc.cpp b/LEGO1/lego/legoomni/src/common/misc.cpp index 9f632bf8..bf77f5e8 100644 --- a/LEGO1/lego/legoomni/src/common/misc.cpp +++ b/LEGO1/lego/legoomni/src/common/misc.cpp @@ -2,11 +2,12 @@ #include "3dmanager/lego3dmanager.h" #include "legoinputmanager.h" -#include "legoomni.h" +#include "legomain.h" #include "legovideomanager.h" #include "mxbackgroundaudiomanager.h" #include "mxmisc.h" #include "roi/legoroi.h" +#include "scripts.h" // GLOBAL: LEGO1 0x100f4c58 MxBool g_isWorldActive = TRUE; diff --git a/LEGO1/lego/legoomni/src/entity/legonavcontroller.cpp b/LEGO1/lego/legoomni/src/entity/legonavcontroller.cpp index b49c3438..fc18ea5c 100644 --- a/LEGO1/lego/legoomni/src/entity/legonavcontroller.cpp +++ b/LEGO1/lego/legoomni/src/entity/legonavcontroller.cpp @@ -7,7 +7,7 @@ #include "legocameralocations.h" #include "legogamestate.h" #include "legoinputmanager.h" -#include "legoomni.h" +#include "legomain.h" #include "legosoundmanager.h" #include "legoutils.h" #include "legovideomanager.h" diff --git a/LEGO1/lego/legoomni/src/entity/legopovcontroller.cpp b/LEGO1/lego/legoomni/src/entity/legopovcontroller.cpp index 0b226d04..0575056d 100644 --- a/LEGO1/lego/legoomni/src/entity/legopovcontroller.cpp +++ b/LEGO1/lego/legoomni/src/entity/legopovcontroller.cpp @@ -1,7 +1,7 @@ #include "3dmanager/lego3dview.h" #include "legoentity.h" +#include "legomain.h" #include "legonavcontroller.h" -#include "legoomni.h" #include "legopointofviewcontroller.h" #include "legosoundmanager.h" #include "misc.h" diff --git a/LEGO1/lego/legoomni/src/entity/legoworld.cpp b/LEGO1/lego/legoomni/src/entity/legoworld.cpp index c7d47303..28cdc611 100644 --- a/LEGO1/lego/legoomni/src/entity/legoworld.cpp +++ b/LEGO1/lego/legoomni/src/entity/legoworld.cpp @@ -11,8 +11,8 @@ #include "legogamestate.h" #include "legoinputmanager.h" #include "legolocomotionanimpresenter.h" +#include "legomain.h" #include "legonavcontroller.h" -#include "legoomni.h" #include "legoplantmanager.h" #include "legosoundmanager.h" #include "legoutils.h" diff --git a/LEGO1/lego/legoomni/src/entity/legoworldpresenter.cpp b/LEGO1/lego/legoomni/src/entity/legoworldpresenter.cpp index 591a3a3f..a4e5902b 100644 --- a/LEGO1/lego/legoomni/src/entity/legoworldpresenter.cpp +++ b/LEGO1/lego/legoomni/src/entity/legoworldpresenter.cpp @@ -5,8 +5,8 @@ #include "legoanimationmanager.h" #include "legobuildingmanager.h" #include "legoentity.h" +#include "legomain.h" #include "legomodelpresenter.h" -#include "legoomni.h" #include "legopartpresenter.h" #include "legoplantmanager.h" #include "legotexturepresenter.h" diff --git a/LEGO1/lego/legoomni/src/gasstation/gasstationentity.cpp b/LEGO1/lego/legoomni/src/gasstation/gasstationentity.cpp index 238059b1..012d9eb8 100644 --- a/LEGO1/lego/legoomni/src/gasstation/gasstationentity.cpp +++ b/LEGO1/lego/legoomni/src/gasstation/gasstationentity.cpp @@ -6,11 +6,11 @@ #include "islepathactor.h" #include "legoanimationmanager.h" #include "legogamestate.h" -#include "legoomni.h" #include "legoutils.h" #include "legoworld.h" #include "misc.h" #include "mxtransitionmanager.h" +#include "scripts.h" DECOMP_SIZE_ASSERT(GasStationEntity, 0x68) diff --git a/LEGO1/lego/legoomni/src/hospital/hospitalentity.cpp b/LEGO1/lego/legoomni/src/hospital/hospitalentity.cpp index 60fedd36..006d2d05 100644 --- a/LEGO1/lego/legoomni/src/hospital/hospitalentity.cpp +++ b/LEGO1/lego/legoomni/src/hospital/hospitalentity.cpp @@ -6,11 +6,11 @@ #include "islepathactor.h" #include "legoanimationmanager.h" #include "legogamestate.h" -#include "legoomni.h" #include "legoutils.h" #include "legoworld.h" #include "misc.h" #include "mxtransitionmanager.h" +#include "scripts.h" DECOMP_SIZE_ASSERT(HospitalEntity, 0x68) diff --git a/LEGO1/lego/legoomni/src/infocenter/infocenterentity.cpp b/LEGO1/lego/legoomni/src/infocenter/infocenterentity.cpp index 5157cb25..3ebe8e44 100644 --- a/LEGO1/lego/legoomni/src/infocenter/infocenterentity.cpp +++ b/LEGO1/lego/legoomni/src/infocenter/infocenterentity.cpp @@ -12,11 +12,11 @@ #include "legoact2state.h" #include "legoanimationmanager.h" #include "legogamestate.h" -#include "legoomni.h" #include "legoutils.h" #include "legoworld.h" #include "misc.h" #include "mxtransitionmanager.h" +#include "scripts.h" DECOMP_SIZE_ASSERT(InfoCenterEntity, 0x68) diff --git a/LEGO1/lego/legoomni/src/input/legoinputmanager.cpp b/LEGO1/lego/legoomni/src/input/legoinputmanager.cpp index 8d67c169..3d683dea 100644 --- a/LEGO1/lego/legoomni/src/input/legoinputmanager.cpp +++ b/LEGO1/lego/legoomni/src/input/legoinputmanager.cpp @@ -2,7 +2,8 @@ #include "legocameracontroller.h" #include "legocontrolmanager.h" -#include "legoomni.h" +#include "legomain.h" +#include "legoutils.h" #include "legovideomanager.h" #include "legoworld.h" #include "misc.h" diff --git a/LEGO1/lego/legoomni/src/isle/beachhouseentity.cpp b/LEGO1/lego/legoomni/src/isle/beachhouseentity.cpp index b30ae739..8f9d518c 100644 --- a/LEGO1/lego/legoomni/src/isle/beachhouseentity.cpp +++ b/LEGO1/lego/legoomni/src/isle/beachhouseentity.cpp @@ -6,11 +6,11 @@ #include "islepathactor.h" #include "legoanimationmanager.h" #include "legogamestate.h" -#include "legoomni.h" #include "legoutils.h" #include "legoworld.h" #include "misc.h" #include "mxtransitionmanager.h" +#include "scripts.h" DECOMP_SIZE_ASSERT(BeachHouseEntity, 0x68) diff --git a/LEGO1/lego/legoomni/src/isle/radiostate.cpp b/LEGO1/lego/legoomni/src/isle/radiostate.cpp index 026ece80..5927a94b 100644 --- a/LEGO1/lego/legoomni/src/isle/radiostate.cpp +++ b/LEGO1/lego/legoomni/src/isle/radiostate.cpp @@ -2,9 +2,9 @@ #include "jukebox.h" #include "jukebox_actions.h" -#include "legoomni.h" #include "mxmisc.h" #include "mxtimer.h" +#include "scripts.h" DECOMP_SIZE_ASSERT(RadioState, 0x30) diff --git a/LEGO1/lego/legoomni/src/main/legoomni.cpp b/LEGO1/lego/legoomni/src/main/legomain.cpp similarity index 69% rename from LEGO1/lego/legoomni/src/main/legoomni.cpp rename to LEGO1/lego/legoomni/src/main/legomain.cpp index 067b3b6b..0dc851a6 100644 --- a/LEGO1/lego/legoomni/src/main/legoomni.cpp +++ b/LEGO1/lego/legoomni/src/main/legomain.cpp @@ -1,4 +1,4 @@ -#include "legoomni.h" +#include "legomain.h" #include "3dmanager/lego3dmanager.h" #include "islepathactor.h" @@ -30,6 +30,7 @@ #include "mxticklemanager.h" #include "mxtransitionmanager.h" #include "mxvariabletable.h" +#include "scripts.h" #include "viewmanager/viewmanager.h" DECOMP_SIZE_ASSERT(LegoOmni, 0x140) @@ -37,209 +38,10 @@ DECOMP_SIZE_ASSERT(LegoOmni::ScriptContainer, 0x1c) DECOMP_SIZE_ASSERT(LegoWorldList, 0x18) DECOMP_SIZE_ASSERT(LegoWorldListCursor, 0x10) -// GLOBAL: LEGO1 0x100f451c -MxAtomId* g_copterScript = NULL; - -// GLOBAL: LEGO1 0x100f4520 -MxAtomId* g_dunecarScript = NULL; - -// GLOBAL: LEGO1 0x100f4524 -MxAtomId* g_jetskiScript = NULL; - -// GLOBAL: LEGO1 0x100f4528 -MxAtomId* g_racecarScript = NULL; - -// GLOBAL: LEGO1 0x100f452c -MxAtomId* g_carraceScript = NULL; - -// GLOBAL: LEGO1 0x100f4530 -MxAtomId* g_carracerScript = NULL; - -// GLOBAL: LEGO1 0x100f4534 -MxAtomId* g_jetraceScript = NULL; - -// GLOBAL: LEGO1 0x100f4538 -MxAtomId* g_jetracerScript = NULL; - -// GLOBAL: LEGO1 0x100f453c -MxAtomId* g_isleScript = NULL; - -// GLOBAL: LEGO1 0x100f4540 -MxAtomId* g_elevbottScript = NULL; - -// GLOBAL: LEGO1 0x100f4544 -MxAtomId* g_infodoorScript = NULL; - -// GLOBAL: LEGO1 0x100f4548 -MxAtomId* g_infomainScript = NULL; - -// GLOBAL: LEGO1 0x100f454c -MxAtomId* g_infoscorScript = NULL; - -// GLOBAL: LEGO1 0x100f4550 -MxAtomId* g_regbookScript = NULL; - -// GLOBAL: LEGO1 0x100f4554 -MxAtomId* g_histbookScript = NULL; - -// GLOBAL: LEGO1 0x100f4558 -MxAtomId* g_hospitalScript = NULL; - -// GLOBAL: LEGO1 0x100f455c -MxAtomId* g_policeScript = NULL; - -// GLOBAL: LEGO1 0x100f4560 -MxAtomId* g_garageScript = NULL; - -// GLOBAL: LEGO1 0x100f4564 -MxAtomId* g_act2mainScript = NULL; - -// GLOBAL: LEGO1 0x100f4568 -MxAtomId* g_act3Script = NULL; - -// GLOBAL: LEGO1 0x100f456c -MxAtomId* g_jukeboxScript = NULL; - -// GLOBAL: LEGO1 0x100f4570 -MxAtomId* g_pz5Script = NULL; - -// GLOBAL: LEGO1 0x100f4574 -MxAtomId* g_introScript = NULL; - -// GLOBAL: LEGO1 0x100f4578 -MxAtomId* g_testScript = NULL; - -// GLOBAL: LEGO1 0x100f457c -MxAtomId* g_jukeboxwScript = NULL; - -// GLOBAL: LEGO1 0x100f4580 -MxAtomId* g_sndAnimScript = NULL; - -// GLOBAL: LEGO1 0x100f4584 -MxAtomId* g_creditsScript = NULL; - -// GLOBAL: LEGO1 0x100f4588 -MxAtomId* g_nocdSourceName = NULL; - // GLOBAL: LEGO1 0x100f6718 // STRING: LEGO1 0x100f6710 const char* g_current = "current"; -// FUNCTION: LEGO1 0x1003dd70 -LegoROI* PickROI(MxLong p_a, MxLong p_b) -{ - return (LegoROI*) VideoManager()->Get3DManager()->GetLego3DView()->Pick(p_a, p_b); -} - -// STUB: LEGO1 0x1003ddc0 -LegoEntity* PickEntity(MxLong, MxLong) -{ - // TODO - return NULL; -} - -// FUNCTION: LEGO1 0x100528e0 -void CreateScripts() -{ - g_copterScript = new MxAtomId("\\lego\\scripts\\build\\copter", e_lowerCase2); - g_dunecarScript = new MxAtomId("\\lego\\scripts\\build\\dunecar", e_lowerCase2); - g_jetskiScript = new MxAtomId("\\lego\\scripts\\build\\jetski", e_lowerCase2); - g_racecarScript = new MxAtomId("\\lego\\scripts\\build\\racecar", e_lowerCase2); - g_carraceScript = new MxAtomId("\\lego\\scripts\\race\\carrace", e_lowerCase2); - g_carracerScript = new MxAtomId("\\lego\\scripts\\race\\carracer", e_lowerCase2); - g_jetraceScript = new MxAtomId("\\lego\\scripts\\race\\jetrace", e_lowerCase2); - g_jetracerScript = new MxAtomId("\\lego\\scripts\\race\\jetracer", e_lowerCase2); - g_isleScript = new MxAtomId("\\lego\\scripts\\isle\\isle", e_lowerCase2); - g_elevbottScript = new MxAtomId("\\lego\\scripts\\infocntr\\elevbott", e_lowerCase2); - g_infodoorScript = new MxAtomId("\\lego\\scripts\\infocntr\\infodoor", e_lowerCase2); - g_infomainScript = new MxAtomId("\\lego\\scripts\\infocntr\\infomain", e_lowerCase2); - g_infoscorScript = new MxAtomId("\\lego\\scripts\\infocntr\\infoscor", e_lowerCase2); - g_regbookScript = new MxAtomId("\\lego\\scripts\\infocntr\\regbook", e_lowerCase2); - g_histbookScript = new MxAtomId("\\lego\\scripts\\infocntr\\histbook", e_lowerCase2); - g_hospitalScript = new MxAtomId("\\lego\\scripts\\hospital\\hospital", e_lowerCase2); - g_policeScript = new MxAtomId("\\lego\\scripts\\police\\police", e_lowerCase2); - g_garageScript = new MxAtomId("\\lego\\scripts\\garage\\garage", e_lowerCase2); - g_act2mainScript = new MxAtomId("\\lego\\scripts\\act2\\act2main", e_lowerCase2); - g_act3Script = new MxAtomId("\\lego\\scripts\\act3\\act3", e_lowerCase2); - g_jukeboxScript = new MxAtomId("\\lego\\scripts\\isle\\jukebox", e_lowerCase2); - g_pz5Script = new MxAtomId("\\lego\\scripts\\isle\\pz5", e_lowerCase2); - g_introScript = new MxAtomId("\\lego\\scripts\\intro", e_lowerCase2); - g_testScript = new MxAtomId("\\lego\\scripts\\test\\test", e_lowerCase2); - g_jukeboxwScript = new MxAtomId("\\lego\\scripts\\isle\\jukeboxw", e_lowerCase2); - g_sndAnimScript = new MxAtomId("\\lego\\scripts\\sndanim", e_lowerCase2); - g_creditsScript = new MxAtomId("\\lego\\scripts\\credits", e_lowerCase2); - g_nocdSourceName = new MxAtomId("\\lego\\scripts\\nocd", e_lowerCase2); -} - -// FUNCTION: LEGO1 0x100530c0 -void DestroyScripts() -{ - delete g_copterScript; - delete g_dunecarScript; - delete g_jetskiScript; - delete g_racecarScript; - delete g_carraceScript; - delete g_carracerScript; - delete g_jetraceScript; - delete g_jetracerScript; - delete g_isleScript; - delete g_elevbottScript; - delete g_infodoorScript; - delete g_infomainScript; - delete g_infoscorScript; - delete g_regbookScript; - delete g_histbookScript; - delete g_hospitalScript; - delete g_policeScript; - delete g_garageScript; - delete g_act2mainScript; - delete g_act3Script; - delete g_jukeboxScript; - delete g_pz5Script; - delete g_introScript; - delete g_testScript; - delete g_jukeboxwScript; - delete g_sndAnimScript; - delete g_creditsScript; - delete g_nocdSourceName; - - g_copterScript = NULL; - g_dunecarScript = NULL; - g_jetskiScript = NULL; - g_racecarScript = NULL; - g_carraceScript = NULL; - g_carracerScript = NULL; - g_jetraceScript = NULL; - g_jetracerScript = NULL; - g_isleScript = NULL; - g_elevbottScript = NULL; - g_infodoorScript = NULL; - g_infomainScript = NULL; - g_infoscorScript = NULL; - g_regbookScript = NULL; - g_histbookScript = NULL; - g_hospitalScript = NULL; - g_policeScript = NULL; - g_garageScript = NULL; - g_act2mainScript = NULL; - g_act3Script = NULL; - g_jukeboxScript = NULL; - g_pz5Script = NULL; - g_introScript = NULL; - g_testScript = NULL; - g_testScript = NULL; - g_jukeboxwScript = NULL; - g_sndAnimScript = NULL; - g_creditsScript = NULL; - g_nocdSourceName = NULL; -} - -// FUNCTION: LEGO1 0x10053430 -const char* GetNoCD_SourceName() -{ - return g_nocdSourceName->GetInternal(); -} - // FUNCTION: LEGO1 0x10058a00 LegoOmni::LegoOmni() { diff --git a/LEGO1/lego/legoomni/src/main/scripts.cpp b/LEGO1/lego/legoomni/src/main/scripts.cpp new file mode 100644 index 00000000..32c3f86e --- /dev/null +++ b/LEGO1/lego/legoomni/src/main/scripts.cpp @@ -0,0 +1,189 @@ +#include "scripts.h" + +#include "mxatom.h" + +// GLOBAL: LEGO1 0x100f451c +MxAtomId* g_copterScript = NULL; + +// GLOBAL: LEGO1 0x100f4520 +MxAtomId* g_dunecarScript = NULL; + +// GLOBAL: LEGO1 0x100f4524 +MxAtomId* g_jetskiScript = NULL; + +// GLOBAL: LEGO1 0x100f4528 +MxAtomId* g_racecarScript = NULL; + +// GLOBAL: LEGO1 0x100f452c +MxAtomId* g_carraceScript = NULL; + +// GLOBAL: LEGO1 0x100f4530 +MxAtomId* g_carracerScript = NULL; + +// GLOBAL: LEGO1 0x100f4534 +MxAtomId* g_jetraceScript = NULL; + +// GLOBAL: LEGO1 0x100f4538 +MxAtomId* g_jetracerScript = NULL; + +// GLOBAL: LEGO1 0x100f453c +MxAtomId* g_isleScript = NULL; + +// GLOBAL: LEGO1 0x100f4540 +MxAtomId* g_elevbottScript = NULL; + +// GLOBAL: LEGO1 0x100f4544 +MxAtomId* g_infodoorScript = NULL; + +// GLOBAL: LEGO1 0x100f4548 +MxAtomId* g_infomainScript = NULL; + +// GLOBAL: LEGO1 0x100f454c +MxAtomId* g_infoscorScript = NULL; + +// GLOBAL: LEGO1 0x100f4550 +MxAtomId* g_regbookScript = NULL; + +// GLOBAL: LEGO1 0x100f4554 +MxAtomId* g_histbookScript = NULL; + +// GLOBAL: LEGO1 0x100f4558 +MxAtomId* g_hospitalScript = NULL; + +// GLOBAL: LEGO1 0x100f455c +MxAtomId* g_policeScript = NULL; + +// GLOBAL: LEGO1 0x100f4560 +MxAtomId* g_garageScript = NULL; + +// GLOBAL: LEGO1 0x100f4564 +MxAtomId* g_act2mainScript = NULL; + +// GLOBAL: LEGO1 0x100f4568 +MxAtomId* g_act3Script = NULL; + +// GLOBAL: LEGO1 0x100f456c +MxAtomId* g_jukeboxScript = NULL; + +// GLOBAL: LEGO1 0x100f4570 +MxAtomId* g_pz5Script = NULL; + +// GLOBAL: LEGO1 0x100f4574 +MxAtomId* g_introScript = NULL; + +// GLOBAL: LEGO1 0x100f4578 +MxAtomId* g_testScript = NULL; + +// GLOBAL: LEGO1 0x100f457c +MxAtomId* g_jukeboxwScript = NULL; + +// GLOBAL: LEGO1 0x100f4580 +MxAtomId* g_sndAnimScript = NULL; + +// GLOBAL: LEGO1 0x100f4584 +MxAtomId* g_creditsScript = NULL; + +// GLOBAL: LEGO1 0x100f4588 +MxAtomId* g_nocdSourceName = NULL; + +// FUNCTION: LEGO1 0x100528e0 +void CreateScripts() +{ + g_copterScript = new MxAtomId("\\lego\\scripts\\build\\copter", e_lowerCase2); + g_dunecarScript = new MxAtomId("\\lego\\scripts\\build\\dunecar", e_lowerCase2); + g_jetskiScript = new MxAtomId("\\lego\\scripts\\build\\jetski", e_lowerCase2); + g_racecarScript = new MxAtomId("\\lego\\scripts\\build\\racecar", e_lowerCase2); + g_carraceScript = new MxAtomId("\\lego\\scripts\\race\\carrace", e_lowerCase2); + g_carracerScript = new MxAtomId("\\lego\\scripts\\race\\carracer", e_lowerCase2); + g_jetraceScript = new MxAtomId("\\lego\\scripts\\race\\jetrace", e_lowerCase2); + g_jetracerScript = new MxAtomId("\\lego\\scripts\\race\\jetracer", e_lowerCase2); + g_isleScript = new MxAtomId("\\lego\\scripts\\isle\\isle", e_lowerCase2); + g_elevbottScript = new MxAtomId("\\lego\\scripts\\infocntr\\elevbott", e_lowerCase2); + g_infodoorScript = new MxAtomId("\\lego\\scripts\\infocntr\\infodoor", e_lowerCase2); + g_infomainScript = new MxAtomId("\\lego\\scripts\\infocntr\\infomain", e_lowerCase2); + g_infoscorScript = new MxAtomId("\\lego\\scripts\\infocntr\\infoscor", e_lowerCase2); + g_regbookScript = new MxAtomId("\\lego\\scripts\\infocntr\\regbook", e_lowerCase2); + g_histbookScript = new MxAtomId("\\lego\\scripts\\infocntr\\histbook", e_lowerCase2); + g_hospitalScript = new MxAtomId("\\lego\\scripts\\hospital\\hospital", e_lowerCase2); + g_policeScript = new MxAtomId("\\lego\\scripts\\police\\police", e_lowerCase2); + g_garageScript = new MxAtomId("\\lego\\scripts\\garage\\garage", e_lowerCase2); + g_act2mainScript = new MxAtomId("\\lego\\scripts\\act2\\act2main", e_lowerCase2); + g_act3Script = new MxAtomId("\\lego\\scripts\\act3\\act3", e_lowerCase2); + g_jukeboxScript = new MxAtomId("\\lego\\scripts\\isle\\jukebox", e_lowerCase2); + g_pz5Script = new MxAtomId("\\lego\\scripts\\isle\\pz5", e_lowerCase2); + g_introScript = new MxAtomId("\\lego\\scripts\\intro", e_lowerCase2); + g_testScript = new MxAtomId("\\lego\\scripts\\test\\test", e_lowerCase2); + g_jukeboxwScript = new MxAtomId("\\lego\\scripts\\isle\\jukeboxw", e_lowerCase2); + g_sndAnimScript = new MxAtomId("\\lego\\scripts\\sndanim", e_lowerCase2); + g_creditsScript = new MxAtomId("\\lego\\scripts\\credits", e_lowerCase2); + g_nocdSourceName = new MxAtomId("\\lego\\scripts\\nocd", e_lowerCase2); +} + +// FUNCTION: LEGO1 0x100530c0 +void DestroyScripts() +{ + delete g_copterScript; + delete g_dunecarScript; + delete g_jetskiScript; + delete g_racecarScript; + delete g_carraceScript; + delete g_carracerScript; + delete g_jetraceScript; + delete g_jetracerScript; + delete g_isleScript; + delete g_elevbottScript; + delete g_infodoorScript; + delete g_infomainScript; + delete g_infoscorScript; + delete g_regbookScript; + delete g_histbookScript; + delete g_hospitalScript; + delete g_policeScript; + delete g_garageScript; + delete g_act2mainScript; + delete g_act3Script; + delete g_jukeboxScript; + delete g_pz5Script; + delete g_introScript; + delete g_testScript; + delete g_jukeboxwScript; + delete g_sndAnimScript; + delete g_creditsScript; + delete g_nocdSourceName; + + g_copterScript = NULL; + g_dunecarScript = NULL; + g_jetskiScript = NULL; + g_racecarScript = NULL; + g_carraceScript = NULL; + g_carracerScript = NULL; + g_jetraceScript = NULL; + g_jetracerScript = NULL; + g_isleScript = NULL; + g_elevbottScript = NULL; + g_infodoorScript = NULL; + g_infomainScript = NULL; + g_infoscorScript = NULL; + g_regbookScript = NULL; + g_histbookScript = NULL; + g_hospitalScript = NULL; + g_policeScript = NULL; + g_garageScript = NULL; + g_act2mainScript = NULL; + g_act3Script = NULL; + g_jukeboxScript = NULL; + g_pz5Script = NULL; + g_introScript = NULL; + g_testScript = NULL; + g_testScript = NULL; + g_jukeboxwScript = NULL; + g_sndAnimScript = NULL; + g_creditsScript = NULL; + g_nocdSourceName = NULL; +} + +// FUNCTION: LEGO1 0x10053430 +const char* GetNoCD_SourceName() +{ + return g_nocdSourceName->GetInternal(); +} diff --git a/LEGO1/lego/legoomni/src/police/policeentity.cpp b/LEGO1/lego/legoomni/src/police/policeentity.cpp index 365b8ef9..d3beb0e4 100644 --- a/LEGO1/lego/legoomni/src/police/policeentity.cpp +++ b/LEGO1/lego/legoomni/src/police/policeentity.cpp @@ -6,11 +6,11 @@ #include "islepathactor.h" #include "legoanimationmanager.h" #include "legogamestate.h" -#include "legoomni.h" #include "legoutils.h" #include "legoworld.h" #include "misc.h" #include "mxtransitionmanager.h" +#include "scripts.h" DECOMP_SIZE_ASSERT(PoliceEntity, 0x68) diff --git a/LEGO1/lego/legoomni/src/police/policestate.cpp b/LEGO1/lego/legoomni/src/police/policestate.cpp index 4078de0b..c0a6e716 100644 --- a/LEGO1/lego/legoomni/src/police/policestate.cpp +++ b/LEGO1/lego/legoomni/src/police/policestate.cpp @@ -1,12 +1,12 @@ #include "policestate.h" #include "islepathactor.h" -#include "legoomni.h" #include "misc.h" #include "mxdsaction.h" #include "mxmisc.h" #include "police.h" #include "police_actions.h" +#include "scripts.h" #include diff --git a/LEGO1/lego/legoomni/src/race/racestandsentity.cpp b/LEGO1/lego/legoomni/src/race/racestandsentity.cpp index 01d64153..f7a572b0 100644 --- a/LEGO1/lego/legoomni/src/race/racestandsentity.cpp +++ b/LEGO1/lego/legoomni/src/race/racestandsentity.cpp @@ -6,11 +6,11 @@ #include "islepathactor.h" #include "legoanimationmanager.h" #include "legogamestate.h" -#include "legoomni.h" #include "legoutils.h" #include "legoworld.h" #include "misc.h" #include "mxtransitionmanager.h" +#include "scripts.h" DECOMP_SIZE_ASSERT(RaceStandsEntity, 0x68) diff --git a/LEGO1/lego/legoomni/src/video/legolocomotionanimpresenter.cpp b/LEGO1/lego/legoomni/src/video/legolocomotionanimpresenter.cpp index 81a9b921..c5da3ffe 100644 --- a/LEGO1/lego/legoomni/src/video/legolocomotionanimpresenter.cpp +++ b/LEGO1/lego/legoomni/src/video/legolocomotionanimpresenter.cpp @@ -1,6 +1,6 @@ #include "legolocomotionanimpresenter.h" -#include "legoomni.h" +#include "legomain.h" #include "legoworld.h" #include "misc.h" diff --git a/LEGO1/lego/legoomni/src/video/legovideomanager.cpp b/LEGO1/lego/legoomni/src/video/legovideomanager.cpp index 6e993d3a..f790c7da 100644 --- a/LEGO1/lego/legoomni/src/video/legovideomanager.cpp +++ b/LEGO1/lego/legoomni/src/video/legovideomanager.cpp @@ -2,7 +2,7 @@ #include "3dmanager/lego3dmanager.h" #include "legoinputmanager.h" -#include "legoomni.h" +#include "legomain.h" #include "misc.h" #include "mxdirectx/mxdirect3d.h" #include "mxdirectx/mxstopwatch.h" diff --git a/LEGO1/lego/legoomni/src/worlds/elevatorbottom.cpp b/LEGO1/lego/legoomni/src/worlds/elevatorbottom.cpp index bbec9dd0..b3184aff 100644 --- a/LEGO1/lego/legoomni/src/worlds/elevatorbottom.cpp +++ b/LEGO1/lego/legoomni/src/worlds/elevatorbottom.cpp @@ -7,7 +7,7 @@ #include "legocontrolmanager.h" #include "legogamestate.h" #include "legoinputmanager.h" -#include "legoomni.h" +#include "legomain.h" #include "legovariables.h" #include "misc.h" #include "mxmisc.h" diff --git a/LEGO1/lego/legoomni/src/worlds/gasstation.cpp b/LEGO1/lego/legoomni/src/worlds/gasstation.cpp index 9da31f68..d32b32ab 100644 --- a/LEGO1/lego/legoomni/src/worlds/gasstation.cpp +++ b/LEGO1/lego/legoomni/src/worlds/gasstation.cpp @@ -8,7 +8,7 @@ #include "legocontrolmanager.h" #include "legogamestate.h" #include "legoinputmanager.h" -#include "legoomni.h" +#include "legomain.h" #include "misc.h" #include "mxbackgroundaudiomanager.h" #include "mxmisc.h" @@ -18,6 +18,7 @@ #include "mxtimer.h" #include "mxtransitionmanager.h" #include "radio.h" +#include "scripts.h" DECOMP_SIZE_ASSERT(GasStation, 0x128) diff --git a/LEGO1/lego/legoomni/src/worlds/hospital.cpp b/LEGO1/lego/legoomni/src/worlds/hospital.cpp index 7666098b..cbc86643 100644 --- a/LEGO1/lego/legoomni/src/worlds/hospital.cpp +++ b/LEGO1/lego/legoomni/src/worlds/hospital.cpp @@ -8,7 +8,7 @@ #include "jukebox_actions.h" #include "legocontrolmanager.h" #include "legoinputmanager.h" -#include "legoomni.h" +#include "legomain.h" #include "legoutils.h" #include "misc.h" #include "mxactionnotificationparam.h" @@ -19,6 +19,7 @@ #include "mxticklemanager.h" #include "mxtimer.h" #include "mxtransitionmanager.h" +#include "scripts.h" DECOMP_SIZE_ASSERT(Hospital, 0x12c) diff --git a/LEGO1/lego/legoomni/src/worlds/infocenter.cpp b/LEGO1/lego/legoomni/src/worlds/infocenter.cpp index 1902a735..d5d68518 100644 --- a/LEGO1/lego/legoomni/src/worlds/infocenter.cpp +++ b/LEGO1/lego/legoomni/src/worlds/infocenter.cpp @@ -14,7 +14,7 @@ #include "legocontrolmanager.h" #include "legogamestate.h" #include "legoinputmanager.h" -#include "legoomni.h" +#include "legomain.h" #include "legoplantmanager.h" #include "legoutils.h" #include "legovideomanager.h" @@ -30,6 +30,7 @@ #include "mxtransitionmanager.h" #include "mxutilities.h" #include "radiostate.h" +#include "scripts.h" #include "sndanim_actions.h" #include "viewmanager/viewmanager.h" diff --git a/LEGO1/lego/legoomni/src/worlds/infocenterdoor.cpp b/LEGO1/lego/legoomni/src/worlds/infocenterdoor.cpp index a94d5f27..bc961368 100644 --- a/LEGO1/lego/legoomni/src/worlds/infocenterdoor.cpp +++ b/LEGO1/lego/legoomni/src/worlds/infocenterdoor.cpp @@ -7,13 +7,14 @@ #include "legocontrolmanager.h" #include "legogamestate.h" #include "legoinputmanager.h" -#include "legoomni.h" +#include "legomain.h" #include "misc.h" #include "mxactionnotificationparam.h" #include "mxbackgroundaudiomanager.h" #include "mxmisc.h" #include "mxnotificationmanager.h" #include "mxtransitionmanager.h" +#include "scripts.h" DECOMP_SIZE_ASSERT(InfocenterDoor, 0xfc) diff --git a/LEGO1/lego/legoomni/src/worlds/isle.cpp b/LEGO1/lego/legoomni/src/worlds/isle.cpp index ce8f559d..3b65e762 100644 --- a/LEGO1/lego/legoomni/src/worlds/isle.cpp +++ b/LEGO1/lego/legoomni/src/worlds/isle.cpp @@ -17,7 +17,7 @@ #include "legobackgroundcolor.h" #include "legocontrolmanager.h" #include "legoinputmanager.h" -#include "legoomni.h" +#include "legomain.h" #include "legoutils.h" #include "legovariables.h" #include "legovideomanager.h" @@ -31,6 +31,7 @@ #include "mxtransitionmanager.h" #include "mxvariabletable.h" #include "pizza.h" +#include "scripts.h" #include "skateboard.h" #include "towtrack.h" diff --git a/LEGO1/lego/legoomni/src/worlds/jukebox.cpp b/LEGO1/lego/legoomni/src/worlds/jukebox.cpp index 84483153..257db67b 100644 --- a/LEGO1/lego/legoomni/src/worlds/jukebox.cpp +++ b/LEGO1/lego/legoomni/src/worlds/jukebox.cpp @@ -7,7 +7,7 @@ #include "legocontrolmanager.h" #include "legogamestate.h" #include "legoinputmanager.h" -#include "legoomni.h" +#include "legomain.h" #include "misc.h" #include "mxmisc.h" #include "mxnotificationmanager.h" diff --git a/LEGO1/lego/legoomni/src/worlds/police.cpp b/LEGO1/lego/legoomni/src/worlds/police.cpp index 9080e4c1..1cf8f879 100644 --- a/LEGO1/lego/legoomni/src/worlds/police.cpp +++ b/LEGO1/lego/legoomni/src/worlds/police.cpp @@ -5,7 +5,7 @@ #include "legocontrolmanager.h" #include "legogamestate.h" #include "legoinputmanager.h" -#include "legoomni.h" +#include "legomain.h" #include "misc.h" #include "mxactionnotificationparam.h" #include "mxbackgroundaudiomanager.h" diff --git a/LEGO1/lego/legoomni/src/worlds/registrationbook.cpp b/LEGO1/lego/legoomni/src/worlds/registrationbook.cpp index b4cdd0a4..29802f23 100644 --- a/LEGO1/lego/legoomni/src/worlds/registrationbook.cpp +++ b/LEGO1/lego/legoomni/src/worlds/registrationbook.cpp @@ -5,7 +5,6 @@ #include "legocontrolmanager.h" #include "legogamestate.h" #include "legoinputmanager.h" -#include "legoomni.h" #include "misc.h" #include "mxactionnotificationparam.h" #include "mxbackgroundaudiomanager.h" @@ -17,6 +16,7 @@ #include "mxtimer.h" #include "mxtransitionmanager.h" #include "regbook_actions.h" +#include "scripts.h" DECOMP_SIZE_ASSERT(RegistrationBook, 0x2d0) diff --git a/LEGO1/lego/legoomni/src/worlds/score.cpp b/LEGO1/lego/legoomni/src/worlds/score.cpp index 33814313..0bb40ea7 100644 --- a/LEGO1/lego/legoomni/src/worlds/score.cpp +++ b/LEGO1/lego/legoomni/src/worlds/score.cpp @@ -9,7 +9,7 @@ #include "legocontrolmanager.h" #include "legogamestate.h" #include "legoinputmanager.h" -#include "legoomni.h" +#include "legomain.h" #include "misc.h" #include "misc/legocontainer.h" #include "mxactionnotificationparam.h" @@ -20,6 +20,7 @@ #include "pizzamissionstate.h" #include "racestate.h" #include "scorestate.h" +#include "scripts.h" #include "towtrackmissionstate.h" DECOMP_SIZE_ASSERT(Score, 0x104)