|
|
@ -39,6 +39,9 @@ All rights reserved. |
|
|
|
#include "Menu.h" |
|
|
|
#include "Menu.h" |
|
|
|
#include "MenuComponent.h" |
|
|
|
#include "MenuComponent.h" |
|
|
|
#include "GameState.h" |
|
|
|
#include "GameState.h" |
|
|
|
|
|
|
|
#include "AdventuresInLestoria.h" |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
INCLUDE_game |
|
|
|
|
|
|
|
|
|
|
|
void Menu::InitializeShermanWindow(){ |
|
|
|
void Menu::InitializeShermanWindow(){ |
|
|
|
Menu*shermanWindow=CreateMenu(SHERMAN,CENTERED,vi2d{144,88}); |
|
|
|
Menu*shermanWindow=CreateMenu(SHERMAN,CENTERED,vi2d{144,88}); |
|
|
@ -56,4 +59,27 @@ void Menu::InitializeShermanWindow(){ |
|
|
|
Menu::CloseMenu(); |
|
|
|
Menu::CloseMenu(); |
|
|
|
return true; |
|
|
|
return true; |
|
|
|
},vf2d{2.f,2.f},ButtonAttr::FIT_TO_LABEL)END; |
|
|
|
},vf2d{2.f,2.f},ButtonAttr::FIT_TO_LABEL)END; |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
shermanWindow->SetupKeyboardNavigation( |
|
|
|
|
|
|
|
[](MenuType type,Data&returnData){ //On Open
|
|
|
|
|
|
|
|
returnData="Leave Button"; |
|
|
|
|
|
|
|
}, |
|
|
|
|
|
|
|
{ //Button Key
|
|
|
|
|
|
|
|
{game->KEY_SCROLL,{"Navigate",[](MenuType type){}}}, |
|
|
|
|
|
|
|
{game->KEY_BACK,{"Stay",[](MenuType type){ |
|
|
|
|
|
|
|
Menu::CloseMenu(); |
|
|
|
|
|
|
|
}}}, |
|
|
|
|
|
|
|
{game->KEY_CONFIRM,{"Select",[](MenuType type){}}}, |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
,{ //Button Navigation Rules
|
|
|
|
|
|
|
|
{"Leave Button",{ |
|
|
|
|
|
|
|
.up="Stay Button", |
|
|
|
|
|
|
|
.down="Consumable Crafting Button",}}, |
|
|
|
|
|
|
|
{"Consumable Crafting Button",{ |
|
|
|
|
|
|
|
.up="Leave Button", |
|
|
|
|
|
|
|
.down="Stay Button",}}, |
|
|
|
|
|
|
|
{"Stay Button",{ |
|
|
|
|
|
|
|
.up="Consumable Crafting Button", |
|
|
|
|
|
|
|
.down="Leave Button",}}, |
|
|
|
|
|
|
|
}); |
|
|
|
} |
|
|
|
} |