From a92ca1d07313f1569ddf2d14ed840e0909bb7511 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?L=C3=A9o=20Lam?= Date: Sun, 9 May 2021 17:46:47 +0200 Subject: [PATCH] ksys/world: Rename SkyMgr to EnvMgr EnvPalettes and other Env stuff are handled by this manager. Cloud/sky properties are handled by "CloudMgr" (which will be renamed to SkyMgr) instead. --- src/KingSystem/World/CMakeLists.txt | 4 ++-- src/KingSystem/World/worldEnvMgr.cpp | 1 + src/KingSystem/World/{worldSkyMgr.h => worldEnvMgr.h} | 8 ++++---- src/KingSystem/World/worldJob.h | 2 +- src/KingSystem/World/worldManager.cpp | 4 ++-- src/KingSystem/World/worldManager.h | 4 ++-- src/KingSystem/World/worldSkyMgr.cpp | 1 - 7 files changed, 12 insertions(+), 12 deletions(-) create mode 100644 src/KingSystem/World/worldEnvMgr.cpp rename src/KingSystem/World/{worldSkyMgr.h => worldEnvMgr.h} (68%) delete mode 100644 src/KingSystem/World/worldSkyMgr.cpp diff --git a/src/KingSystem/World/CMakeLists.txt b/src/KingSystem/World/CMakeLists.txt index d4fe4150..6c85ccd8 100644 --- a/src/KingSystem/World/CMakeLists.txt +++ b/src/KingSystem/World/CMakeLists.txt @@ -5,6 +5,8 @@ target_sources(uking PRIVATE worldCloudMgr.h worldDofMgr.cpp worldDofMgr.h + worldEnvMgr.cpp + worldEnvMgr.h worldJob.cpp worldJob.h worldManager.cpp @@ -13,8 +15,6 @@ target_sources(uking PRIVATE worldShootingStarMgr.h worldShootingStarMgrEx.cpp worldShootingStarMgrEx.h - worldSkyMgr.cpp - worldSkyMgr.h worldTempMgr.cpp worldTempMgr.h worldTimeMgr.cpp diff --git a/src/KingSystem/World/worldEnvMgr.cpp b/src/KingSystem/World/worldEnvMgr.cpp new file mode 100644 index 00000000..b5ae3d01 --- /dev/null +++ b/src/KingSystem/World/worldEnvMgr.cpp @@ -0,0 +1 @@ +#include "KingSystem/World/worldEnvMgr.h" diff --git a/src/KingSystem/World/worldSkyMgr.h b/src/KingSystem/World/worldEnvMgr.h similarity index 68% rename from src/KingSystem/World/worldSkyMgr.h rename to src/KingSystem/World/worldEnvMgr.h index 6f3b5481..b18b16c6 100644 --- a/src/KingSystem/World/worldSkyMgr.h +++ b/src/KingSystem/World/worldEnvMgr.h @@ -6,11 +6,11 @@ namespace ksys::world { // TODO -class SkyMgr : public Job { +class EnvMgr : public Job { public: - SkyMgr(); + EnvMgr(); - JobType getType() const override { return JobType::Sky; } + JobType getType() const override { return JobType::Env; } void resetForStageUnload(); @@ -19,6 +19,6 @@ public: u8 _20[0x6b618 - 0x20]; }; -KSYS_CHECK_SIZE_NX150(SkyMgr, 0x6b618); +KSYS_CHECK_SIZE_NX150(EnvMgr, 0x6b618); } // namespace ksys::world diff --git a/src/KingSystem/World/worldJob.h b/src/KingSystem/World/worldJob.h index 18714b06..5e7df2d5 100644 --- a/src/KingSystem/World/worldJob.h +++ b/src/KingSystem/World/worldJob.h @@ -14,7 +14,7 @@ enum class JobType { Weather, Temp, Wind, - Sky, + Env, Dof, Chemical, }; diff --git a/src/KingSystem/World/worldManager.cpp b/src/KingSystem/World/worldManager.cpp index dec32f73..18b24c69 100644 --- a/src/KingSystem/World/worldManager.cpp +++ b/src/KingSystem/World/worldManager.cpp @@ -333,8 +333,8 @@ static Job* makeJob(JobType type, sead::Heap* heap) { return new (heap) TempMgr; case JobType::Wind: return new (heap) WindMgr; - case JobType::Sky: - return new (heap) SkyMgr; + case JobType::Env: + return new (heap) EnvMgr; case JobType::Dof: return new (heap) DofMgr; case JobType::Chemical: diff --git a/src/KingSystem/World/worldManager.h b/src/KingSystem/World/worldManager.h index 661f5247..4ce652af 100644 --- a/src/KingSystem/World/worldManager.h +++ b/src/KingSystem/World/worldManager.h @@ -17,8 +17,8 @@ #include "KingSystem/World/worldChemicalMgr.h" #include "KingSystem/World/worldCloudMgr.h" #include "KingSystem/World/worldDofMgr.h" +#include "KingSystem/World/worldEnvMgr.h" #include "KingSystem/World/worldShootingStarMgrEx.h" -#include "KingSystem/World/worldSkyMgr.h" #include "KingSystem/World/worldTempMgr.h" #include "KingSystem/World/worldTimeMgr.h" #include "KingSystem/World/worldWeatherMgr.h" @@ -268,7 +268,7 @@ public: WeatherMgr* getWeatherMgr() const { return static_cast(mMgrs[3]); } TempMgr* getTempMgr() const { return static_cast(mMgrs[4]); } WindMgr* getWindMgr() const { return static_cast(mMgrs[5]); } - SkyMgr* getSkyMgr() const { return static_cast(mMgrs[6]); } + EnvMgr* getSkyMgr() const { return static_cast(mMgrs[6]); } DofMgr* getDofMgr() const { return static_cast(mMgrs[7]); } ChemicalMgr* getChemicalMgr() const { return static_cast(mMgrs[8]); } diff --git a/src/KingSystem/World/worldSkyMgr.cpp b/src/KingSystem/World/worldSkyMgr.cpp deleted file mode 100644 index 1c847003..00000000 --- a/src/KingSystem/World/worldSkyMgr.cpp +++ /dev/null @@ -1 +0,0 @@ -#include "KingSystem/World/worldSkyMgr.h"