UniStore v2! (#36)

* Do not build here.

* WIP: UniStoreV2!

This implementation is ugly and a big cleanup is needed.

* [UniStoreV2]: Add `Lang::get(...)`.

* Add back UniStore autobooting.

* UniStoreV2: Add List Layout.

* Some more UniStore work.

Also constify vector's.

* Some more spritesheet checks.

* oops.. forgot to do `Config::fading`.

* Display UniStore version on the Store list bar.

* version now needs to be `0` or `1` or not included.

versions with 2, 3, 4 and up shows an error now.

* You can now also scroll to the next page with D-Pad Left/D-Pad Right!

* Last fix before merge?
This commit is contained in:
StackZ
2020-06-19 04:54:05 +02:00
committed by GitHub
parent d86f612d09
commit 2641e4922b
23 changed files with 1598 additions and 798 deletions
+4 -5
View File
@@ -25,7 +25,6 @@
*/
#include "config.hpp"
#include "exiting.hpp"
#include "ftpScreen.hpp"
#include "mainMenu.hpp"
#include "scriptHelper.hpp"
@@ -68,9 +67,9 @@ void MainMenu::Draw(void) const {
void MainMenu::Logic(u32 hDown, u32 hHeld, touchPosition touch) {
if ((hDown & KEY_START) || (hDown & KEY_TOUCH && touching(touch, mainButtons[4]))) {
exiting = true;
Gui::setScreen(std::make_unique<Exiting>(), Config::fading, true);
fadeout = true;
fadecolor = 0;
exiting = true;
}
// Navigation.
@@ -87,7 +86,7 @@ void MainMenu::Logic(u32 hDown, u32 hHeld, touchPosition touch) {
if (hDown & KEY_A) {
switch(Selection) {
case 0:
Gui::setScreen(std::make_unique<UniStore>(), Config::fading, true);
Gui::setScreen(std::make_unique<UniStore>(false, "NOT_USED"), Config::fading, true);
break;
case 1:
Gui::setScreen(std::make_unique<ScriptList>(), Config::fading, true);
@@ -103,7 +102,7 @@ void MainMenu::Logic(u32 hDown, u32 hHeld, touchPosition touch) {
if (hDown & KEY_TOUCH) {
if (touching(touch, mainButtons[0])) {
Gui::setScreen(std::make_unique<UniStore>(), Config::fading, true);
Gui::setScreen(std::make_unique<UniStore>(false, "NOT_USED"), Config::fading, true);
} else if (touching(touch, mainButtons[1])) {
Gui::setScreen(std::make_unique<ScriptList>(), Config::fading, true);
} else if (touching(touch, mainButtons[2])) {