diff --git a/include/screens/unistore.hpp b/include/screens/unistore.hpp index 4d8d36ad1..e6fcc3e02 100644 --- a/include/screens/unistore.hpp +++ b/include/screens/unistore.hpp @@ -56,9 +56,10 @@ class UniStore : public screen void execute(); void descript(); + void updateStore(int selectedStore); bool handleIfDisplayText(); int mode = 0; - std::string selectedOptionAppStore; + int selectedOptionAppStore = 0; mutable bool displayInformations = true; // Stuff for the GitHub Store Search function and Full URL. @@ -90,11 +91,14 @@ class UniStore : public screen }; std::vector URLBtn = { - {10, 100, 140, 35, -1}, // FULL URL. - {170, 100, 140, 35, -1}, // Github. + {10, 70, 140, 40, -1}, // FULL URL. + {170, 70, 140, 40, -1}, // Github. + {10, 145, 140, 40, -1}, // TinyDB. + {170, 145, 140, 40, -1}, // QR Code? }; std::vector GitHubPos = { + {30, 50, 260, 30, -1}, // Owner & Repo. {30, 130, 260, 30, -1}, // Filename. {135, 180, 50, 30, -1}, // OK. diff --git a/source/screens/unistore.cpp b/source/screens/unistore.cpp index 85e6cab4f..4f20ef0ac 100644 --- a/source/screens/unistore.cpp +++ b/source/screens/unistore.cpp @@ -262,7 +262,7 @@ void UniStore::DrawStoreList(void) const { } void UniStore::DrawStore(void) const { - std::string entryAmount = std::to_string(selection2+1) + " / " + std::to_string(appStoreList.size()); + std::string entryAmount = std::to_string(selectedOptionAppStore+1) + " / " + std::to_string((int)appStoreJson.at("storeContent").size()); std::string info; Gui::DrawTop(); // Top Background. @@ -271,11 +271,11 @@ void UniStore::DrawStore(void) const { } // Icon. - if (appStoreJson.at(selectedOptionAppStore).at("info").contains("iconIndex") && sheetHasLoaded == true) { - if (appStoreJson.at(selectedOptionAppStore).at("info").contains("posX") && appStoreJson.at(selectedOptionAppStore).at("info").contains("posY")) { - drawNormal(appStoreJson[selectedOptionAppStore]["info"]["iconIndex"], appStoreJson[selectedOptionAppStore]["info"]["posX"], appStoreJson[selectedOptionAppStore]["info"]["posY"]); + if (appStoreJson.at("storeContent").at(selectedOptionAppStore).at("info").contains("iconIndex") && sheetHasLoaded == true) { + if (appStoreJson.at("storeContent").at(selectedOptionAppStore).at("info").contains("posX") && appStoreJson.at("storeContent").at(selectedOptionAppStore).at("info").contains("posY")) { + drawNormal(appStoreJson["storeContent"][selectedOptionAppStore]["info"]["iconIndex"], appStoreJson["storeContent"][selectedOptionAppStore]["info"]["posX"], appStoreJson["storeContent"][selectedOptionAppStore]["info"]["posY"]); } else { - drawNormal(appStoreJson[selectedOptionAppStore]["info"]["iconIndex"], 175, 155); + drawNormal(appStoreJson["storeContent"][selectedOptionAppStore]["info"]["iconIndex"], 175, 155); } } @@ -288,18 +288,18 @@ void UniStore::DrawStore(void) const { Gui::DrawString(397-Gui::GetStringWidth(0.6f, entryAmount), 237-Gui::GetStringHeight(0.6f, entryAmount), 0.6f, TextColor, entryAmount); } - Gui::DrawStringCentered(0, 32, 0.6f, TextColor, Lang::get("TITLE") + std::string(appStoreList[selection2]), 400); - Gui::DrawStringCentered(0, 57, 0.6f, TextColor, Lang::get("AUTHOR") + std::string(appStoreJson[selectedOptionAppStore]["info"]["author"]), 400); - Gui::DrawStringCentered(0, 82, 0.6f, TextColor, Lang::get("DESC") + std::string(appStoreJson[selectedOptionAppStore]["info"]["description"]), 400); + Gui::DrawStringCentered(0, 32, 0.6f, TextColor, Lang::get("TITLE") + std::string(appStoreJson["storeContent"][selectedOptionAppStore]["info"]["title"]), 400); + Gui::DrawStringCentered(0, 57, 0.6f, TextColor, Lang::get("AUTHOR") + std::string(appStoreJson["storeContent"][selectedOptionAppStore]["info"]["author"]), 400); + Gui::DrawStringCentered(0, 82, 0.6f, TextColor, Lang::get("DESC") + std::string(appStoreJson["storeContent"][selectedOptionAppStore]["info"]["description"]), 400); - if (appStoreJson[selectedOptionAppStore]["info"]["version"] != "") { - Gui::DrawStringCentered(0, 107, 0.6f, TextColor, Lang::get("VERSION") + std::string(appStoreJson[selectedOptionAppStore]["info"]["version"]), 400); + if (appStoreJson["storeContent"][selectedOptionAppStore]["info"]["version"] != "") { + Gui::DrawStringCentered(0, 107, 0.6f, TextColor, Lang::get("VERSION") + std::string(appStoreJson["storeContent"][selectedOptionAppStore]["info"]["version"]), 400); } else { Gui::DrawStringCentered(0, 107, 0.6f, TextColor, Lang::get("VERSION") + Lang::get("UNKNOWN"), 400); } - if (appStoreJson[selectedOptionAppStore]["info"]["fileSize"] != 0) { - Gui::DrawStringCentered(0, 132, 0.6f, TextColor, Lang::get("FILE_SIZE") + formatBytes(int64_t(appStoreJson[selectedOptionAppStore]["info"]["fileSize"])), 400); + if (appStoreJson["storeContent"][selectedOptionAppStore]["info"]["fileSize"] != 0) { + Gui::DrawStringCentered(0, 132, 0.6f, TextColor, Lang::get("FILE_SIZE") + formatBytes(int64_t(appStoreJson["storeContent"][selectedOptionAppStore]["info"]["fileSize"])), 400); } else { Gui::DrawStringCentered(0, 132, 0.6f, TextColor, Lang::get("FILE_SIZE") + Lang::get("UNKNOWN"), 400); } @@ -317,9 +317,9 @@ void UniStore::DrawStore(void) const { Gui::spriteBlend(sprites_view_idx, arrowPos[3].x, arrowPos[3].y); if (Config::viewMode == 0) { - for(int i=0;i 40+(i*57) && touch.py < 40+(i*57)+45) { if (ScriptHelper::checkIfValid(dirContents[screenPos + i].name, 1) == true) { + updateStore(screenPos + i); currentStoreFile = dirContents[screenPos + i].name; DisplayMsg(Lang::get("PREPARE_STORE")); if (storeInfo[screenPos + i].storeSheet != "" || storeInfo[screenPos + i].storeSheet != "MISSING: storeInfo.sheet") { @@ -589,7 +595,7 @@ void UniStore::StoreSelectionLogic(u32 hDown, u32 hHeld, touchPosition touch) { appStoreJson = openStoreFile(); appStoreList = parseStoreObjects(currentStoreFile); loadStoreColors(appStoreJson); - selectedOptionAppStore = appStoreList[0]; + selectedOptionAppStore = 0; displayInformations = handleIfDisplayText(); isScriptSelected = true; mode = 2; @@ -600,6 +606,7 @@ void UniStore::StoreSelectionLogic(u32 hDown, u32 hHeld, touchPosition touch) { for(int i=0;i (i+1)*27 && touch.py < (i+2)*27) { if (ScriptHelper::checkIfValid(dirContents[screenPosList + i].name, 1) == true) { + updateStore(screenPosList + i); currentStoreFile = dirContents[screenPosList + i].name; DisplayMsg(Lang::get("PREPARE_STORE")); if (storeInfo[screenPosList + i].storeSheet != "" || storeInfo[screenPosList + i].storeSheet != "MISSING: storeInfo.sheet") { @@ -610,7 +617,7 @@ void UniStore::StoreSelectionLogic(u32 hDown, u32 hHeld, touchPosition touch) { appStoreJson = openStoreFile(); appStoreList = parseStoreObjects(currentStoreFile); loadStoreColors(appStoreJson); - selectedOptionAppStore = appStoreList[0]; + selectedOptionAppStore = 0; displayInformations = handleIfDisplayText(); isScriptSelected = true; mode = 2; @@ -644,12 +651,10 @@ void UniStore::StoreLogic(u32 hDown, u32 hHeld, touchPosition touch) { // Go one entry up. if ((hHeld & KEY_UP && !keyRepeatDelay) || (hDown & KEY_TOUCH && touching(touch, arrowPos[0]))) { - if (selection2 > 0) { - selection2--; - selectedOptionAppStore = appStoreList[selection2]; + if (selectedOptionAppStore > 0) { + selectedOptionAppStore--; } else { - selection2 = (int)appStoreList.size()-1; - selectedOptionAppStore = appStoreList[selection2]; + selectedOptionAppStore = (int)appStoreJson.at("storeContent").size()-1; } if (fastMode == true) { keyRepeatDelay = 3; @@ -660,12 +665,10 @@ void UniStore::StoreLogic(u32 hDown, u32 hHeld, touchPosition touch) { // Go one entry down. if ((hHeld & KEY_DOWN && !keyRepeatDelay) || (hDown & KEY_TOUCH && touching(touch, arrowPos[1]))) { - if (selection2 < (int)appStoreList.size()-1) { - selection2++; - selectedOptionAppStore = appStoreList[selection2]; + if (selectedOptionAppStore < (int)appStoreJson.at("storeContent").size()-1) { + selectedOptionAppStore++; } else { - selection2 = 0; - selectedOptionAppStore = appStoreList[selection2]; + selectedOptionAppStore = 0; } if (fastMode == true) { keyRepeatDelay = 3; @@ -677,18 +680,16 @@ void UniStore::StoreLogic(u32 hDown, u32 hHeld, touchPosition touch) { // Execute touched Entry. if (hDown & KEY_TOUCH) { if (Config::viewMode == 0) { - for(int i=0;i 40+(i*57) && touch.py < 40+(i*57)+45) { - selection2 = screenPos2 + i; - selectedOptionAppStore = appStoreList[screenPos2 + i]; + selectedOptionAppStore = screenPos2 + i; execute(); } } } else if (Config::viewMode == 1) { - for(int i=0;i (i+1)*27 && touch.py < (i+2)*27) { - selection2 = screenPosList2 + i; - selectedOptionAppStore = appStoreList[screenPosList2 + i]; + selectedOptionAppStore = screenPosList2 + i; execute(); } } @@ -700,16 +701,16 @@ void UniStore::StoreLogic(u32 hDown, u32 hHeld, touchPosition touch) { } if (Config::viewMode == 0) { - if(selection2 < screenPos2) { - screenPos2 = selection2; - } else if (selection2 > screenPos2 + ENTRIES_PER_SCREEN - 1) { - screenPos2 = selection2 - ENTRIES_PER_SCREEN + 1; + if(selectedOptionAppStore < screenPos2) { + screenPos2 = selectedOptionAppStore; + } else if (selectedOptionAppStore > screenPos2 + ENTRIES_PER_SCREEN - 1) { + screenPos2 = selectedOptionAppStore - ENTRIES_PER_SCREEN + 1; } } else if (Config::viewMode == 1) { - if(selection2 < screenPosList2) { - screenPosList2 = selection2; - } else if (selection2 > screenPosList2 + ENTRIES_PER_LIST - 1) { - screenPosList2 = selection2 - ENTRIES_PER_LIST + 1; + if(selectedOptionAppStore < screenPosList2) { + screenPosList2 = selectedOptionAppStore; + } else if (selectedOptionAppStore > screenPosList2 + ENTRIES_PER_LIST - 1) { + screenPosList2 = selectedOptionAppStore - ENTRIES_PER_LIST + 1; } } } @@ -741,71 +742,71 @@ void UniStore::Logic(u32 hDown, u32 hHeld, touchPosition touch) { // Execute Entry. void UniStore::execute() { - for(int i=0;i<(int)appStoreJson.at(selectedOptionAppStore).at("script").size();i++) { - std::string type = appStoreJson.at(selectedOptionAppStore).at("script").at(i).at("type"); + for(int i=0;i<(int)appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").size();i++) { + std::string type = appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).at("type"); if(type == "deleteFile") { bool missing = false; std::string file, message; - if(appStoreJson.at(selectedOptionAppStore).at("script").at(i).contains("file")) file = appStoreJson.at(selectedOptionAppStore).at("script").at(i).at("file"); + if(appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).contains("file")) file = appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).at("file"); else missing = true; - if(appStoreJson.at(selectedOptionAppStore).at("script").at(i).contains("message")) message = appStoreJson.at(selectedOptionAppStore).at("script").at(i).at("message"); + if(appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).contains("message")) message = appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).at("message"); if(!missing) ScriptHelper::removeFile(file, message); } else if(type == "downloadFile") { bool missing = false; std::string file, output, message; - if(appStoreJson.at(selectedOptionAppStore).at("script").at(i).contains("file")) file = appStoreJson.at(selectedOptionAppStore).at("script").at(i).at("file"); + if(appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).contains("file")) file = appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).at("file"); else missing = true; - if(appStoreJson.at(selectedOptionAppStore).at("script").at(i).contains("output")) output = appStoreJson.at(selectedOptionAppStore).at("script").at(i).at("output"); + if(appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).contains("output")) output = appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).at("output"); else missing = true; - if(appStoreJson.at(selectedOptionAppStore).at("script").at(i).contains("message")) message = appStoreJson.at(selectedOptionAppStore).at("script").at(i).at("message"); + if(appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).contains("message")) message = appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).at("message"); if(!missing) ScriptHelper::downloadFile(file, output, message); } else if(type == "downloadRelease") { bool missing = false, includePrereleases = false; std::string repo, file, output, message; - if(appStoreJson.at(selectedOptionAppStore).at("script").at(i).contains("repo")) repo = appStoreJson.at(selectedOptionAppStore).at("script").at(i).at("repo"); + if(appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).contains("repo")) repo = appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).at("repo"); else missing = true; - if(appStoreJson.at(selectedOptionAppStore).at("script").at(i).contains("file")) file = appStoreJson.at(selectedOptionAppStore).at("script").at(i).at("file"); + if(appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).contains("file")) file = appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).at("file"); else missing = true; - if(appStoreJson.at(selectedOptionAppStore).at("script").at(i).contains("output")) output = appStoreJson.at(selectedOptionAppStore).at("script").at(i).at("output"); + if(appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).contains("output")) output = appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).at("output"); else missing = true; - if(appStoreJson.at(selectedOptionAppStore).at("script").at(i).contains("includePrereleases") && appStoreJson.at(selectedOptionAppStore).at("script").at(i).at("includePrereleases").is_boolean()) + if(appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).contains("includePrereleases") && appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).at("includePrereleases").is_boolean()) includePrereleases = appStoreJson.at(selectedOptionAppStore).at("script").at(i).at("includePrereleases"); - if(appStoreJson.at(selectedOptionAppStore).at("script").at(i).contains("message")) message = appStoreJson.at(selectedOptionAppStore).at("script").at(i).at("message"); + if(appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).contains("message")) message = appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).at("message"); if(!missing) ScriptHelper::downloadRelease(repo, file, output, includePrereleases, message); } else if(type == "extractFile") { bool missing = false; std::string file, input, output, message; - if(appStoreJson.at(selectedOptionAppStore).at("script").at(i).contains("file")) file = appStoreJson.at(selectedOptionAppStore).at("script").at(i).at("file"); + if(appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).contains("file")) file = appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).at("file"); else missing = true; - if(appStoreJson.at(selectedOptionAppStore).at("script").at(i).contains("input")) input = appStoreJson.at(selectedOptionAppStore).at("script").at(i).at("input"); + if(appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).contains("input")) input = appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).at("input"); else missing = true; - if(appStoreJson.at(selectedOptionAppStore).at("script").at(i).contains("output")) output = appStoreJson.at(selectedOptionAppStore).at("script").at(i).at("output"); + if(appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).contains("output")) output = appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).at("output"); else missing = true; - if(appStoreJson.at(selectedOptionAppStore).at("script").at(i).contains("message")) message = appStoreJson.at(selectedOptionAppStore).at("script").at(i).at("message"); + if(appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).contains("message")) message = appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).at("message"); if(!missing) ScriptHelper::extractFile(file, input, output, message); } else if(type == "installCia") { bool missing = false; std::string file, message; - if(appStoreJson.at(selectedOptionAppStore).at("script").at(i).contains("file")) file = appStoreJson.at(selectedOptionAppStore).at("script").at(i).at("file"); + if(appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).contains("file")) file = appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).at("file"); else missing = true; - if(appStoreJson.at(selectedOptionAppStore).at("script").at(i).contains("message")) message = appStoreJson.at(selectedOptionAppStore).at("script").at(i).at("message"); + if(appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).contains("message")) message = appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).at("message"); if(!missing) ScriptHelper::installFile(file, message); } else if (type == "mkdir") { bool missing = false; std::string directory, message; - if(appStoreJson.at(selectedOptionAppStore).at("script").at(i).contains("directory")) directory = appStoreJson.at(selectedOptionAppStore).at("script").at(i).at("directory"); + if(appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).contains("directory")) directory = appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).at("directory"); else missing = true; if(!missing) makeDirs(directory.c_str()); } else if (type == "rmdir") { bool missing = false; std::string directory, message, promptmsg; - if(appStoreJson.at(selectedOptionAppStore).at("script").at(i).contains("directory")) directory = appStoreJson.at(selectedOptionAppStore).at("script").at(i).at("directory"); + if(appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).contains("directory")) directory = appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).at("directory"); else missing = true; promptmsg = Lang::get("DELETE_PROMPT") + "\n" + directory; if(!missing) { @@ -817,7 +818,7 @@ void UniStore::execute() { } else if (type == "mkfile") { bool missing = false; std::string file; - if(appStoreJson.at(selectedOptionAppStore).at("script").at(i).contains("file")) file = appStoreJson.at(selectedOptionAppStore).at("script").at(i).at("file"); + if(appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).contains("file")) file = appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).at("file"); else missing = true; if(!missing) ScriptHelper::createFile(file.c_str()); @@ -825,10 +826,10 @@ void UniStore::execute() { bool missing = false; std::string message; int seconds; - if(appStoreJson.at(selectedOptionAppStore).at("script").at(i).contains("message")) message = appStoreJson.at(selectedOptionAppStore).at("script").at(i).at("message"); + if(appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).contains("message")) message = appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).at("message"); else missing = true; - if(appStoreJson.at(selectedOptionAppStore).at("script").at(i).contains("seconds") && appStoreJson.at(selectedOptionAppStore).at("script").at(i).at("seconds").is_number()) - seconds = appStoreJson.at(selectedOptionAppStore).at("script").at(i).at("seconds"); + if(appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).contains("seconds") && appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).at("seconds").is_number()) + seconds = appStoreJson.at("storeContent").at(selectedOptionAppStore).at("script").at(i).at("seconds"); else missing = true; if(!missing) ScriptHelper::displayTimeMsg(message, seconds); } else if (type == "saveConfig") { @@ -852,7 +853,7 @@ void UniStore::DrawSearch(void) const { Gui::DrawBottom(); Gui::DrawArrow(0, 218, 0, 1); - for (int i = 0; i < 2; i++) { + for (int i = 0; i < 3; i++) { if (searchSelection == i) { Gui::Draw_Rect(URLBtn[i].x, URLBtn[i].y, URLBtn[i].w, URLBtn[i].h, Config::SelectedColor); } else { @@ -860,8 +861,9 @@ void UniStore::DrawSearch(void) const { } } - Gui::DrawStringCentered(-80, 110, 0.6f, Config::TxtColor, Lang::get("FULL_URL"), 130); - Gui::DrawStringCentered(80, 110, 0.6f, Config::TxtColor, Lang::get("GITHUB"), 130); + Gui::DrawStringCentered(-80, URLBtn[0].y+12, 0.6f, Config::TxtColor, Lang::get("FULL_URL"), 130); + Gui::DrawStringCentered(80, URLBtn[1].y+12, 0.6f, Config::TxtColor, Lang::get("GITHUB"), 130); + Gui::DrawStringCentered(-80, URLBtn[2].y+12, 0.6f, Config::TxtColor, "TinyDB", 130); } void UniStore::SearchLogic(u32 hDown, u32 hHeld, touchPosition touch) { @@ -876,11 +878,21 @@ void UniStore::SearchLogic(u32 hDown, u32 hHeld, touchPosition touch) { if (searchSelection == 1) searchSelection = 0; } + if (hDown & KEY_DOWN) { + if (searchSelection == 0) searchSelection = 2; + } + + if (hDown & KEY_UP) { + if (searchSelection == 2) searchSelection = 0; + } + if (hDown & KEY_A) { if (searchSelection == 0) { mode = 4; } else if (searchSelection == 1) { mode = 5; + } else if (searchSelection == 2) { + ScriptHelper::downloadFile("https://tinydb.eiphax.tech/api/tinydb.unistore", Config::StorePath + "TinyDB.unistore", Lang::get("DOWNLOADING") + "TinyDB"); } } @@ -888,6 +900,8 @@ void UniStore::SearchLogic(u32 hDown, u32 hHeld, touchPosition touch) { mode = 4; } else if (hDown & KEY_TOUCH && touching(touch, URLBtn[1])) { mode = 5; + } else if (hDown & KEY_TOUCH && touching(touch, URLBtn[2])) { + ScriptHelper::downloadFile("https://tinydb.eiphax.tech/api/tinydb.unistore", Config::StorePath + "TinyDB.unistore", Lang::get("DOWNLOADING") + "TinyDB"); } }