diff --git a/source/MenuUtils.cpp b/source/MenuUtils.cpp index 5521296..2c0575a 100644 --- a/source/MenuUtils.cpp +++ b/source/MenuUtils.cpp @@ -328,4 +328,75 @@ nn::act::SlotNo handleAccountSelectScreen(const std::vector #include +#define UPDATE_SKIP_PATH "fs:/vol/external01/wiiu/environments/skipUpdateWarn" + #define COLOR_WHITE Color(0xffffffff) #define COLOR_BLACK Color(0, 0, 0, 255) #define COLOR_BACKGROUND COLOR_BLACK +#define COLOR_BACKGROUND_WARN Color(255, 40, 0, 255) #define COLOR_TEXT COLOR_WHITE #define COLOR_TEXT2 Color(0xB3ffffff) #define COLOR_AUTOBOOT Color(0xaeea00ff) @@ -30,4 +33,6 @@ void writeAutobootOption(std::string &configPath, int32_t autobootOption); int32_t handleMenuScreen(std::string &configPath, int32_t autobootOptionInput, const std::map &menu); -nn::act::SlotNo handleAccountSelectScreen(const std::vector> &data); \ No newline at end of file +nn::act::SlotNo handleAccountSelectScreen(const std::vector> &data); + +void handleUpdateWarningScreen(); diff --git a/source/main.cpp b/source/main.cpp index 1d45388..d106302 100644 --- a/source/main.cpp +++ b/source/main.cpp @@ -5,6 +5,7 @@ #include "StorageUtils.h" #include "logger.h" #include +#include #include #include #include @@ -43,6 +44,20 @@ int32_t main(int32_t argc, char **argv) { OSFatal("AutobootModule: Mocha_InitLibrary failed"); } + FSAInit(); + auto client = FSAAddClient(nullptr); + if (client > 0) { + if (Mocha_UnlockFSClientEx(client) == MOCHA_RESULT_SUCCESS) { + // test if the update folder exists + FSStat stat; + if (FSAGetStat(client, "/vol/storage_mlc01/sys/update", &stat) >= 0) { + handleUpdateWarningScreen(); + } + } + + FSADelClient(client); + } + bool showvHBL = getVWiiHBLTitleId() != 0; bool showHBL = false; std::string configPath = "fs:/vol/external01/wiiu/autoboot.cfg";