Fix up new stages, configure stage plates, add bonus boss stage, add levels to configuration files. Change Class selection window to include an online character checkbox to toggle between online and offline saving. Fix online/offline file IDs that were incorrectly loading due to no callbacks for async file retrieval.
This commit is contained in:
@@ -40,6 +40,7 @@ All rights reserved.
|
||||
#include "MenuLabel.h"
|
||||
#include "TextEntryLabel.h"
|
||||
#include "SaveFile.h"
|
||||
#include "Checkbox.h"
|
||||
|
||||
using A=Attribute;
|
||||
|
||||
@@ -51,21 +52,14 @@ void Menu::InitializeUserIDWindow(){
|
||||
Component<MenuComponent>(USER_ID,"Submit Button")->SetGrayedOut(newLabel.length()==0);
|
||||
},true,24U,1.f,ComponentAttr::BACKGROUND|ComponentAttr::FIT_TO_LABEL|ComponentAttr::OUTLINE|ComponentAttr::SHADOW)END;
|
||||
userIDWindow->ADD("Back Button",MenuComponent)(geom2d::rect<float>{{18,110},{48,12}},"Back",[](MenuFuncData data){
|
||||
SaveFile::SetOnlineMode(false); //We declined the online saving, so don't allow it.
|
||||
Component<Checkbox>(CLASS_SELECTION,"Online Character Checkbox")->Click(); //Since the checkbox is currently checked, we have to click it to toggle it.
|
||||
Menu::CloseMenu();
|
||||
return true;
|
||||
})END;
|
||||
userIDWindow->ADD("Submit Button",MenuComponent)(geom2d::rect<float>{{102,110},{48,12}},"Submit",[](MenuFuncData data){
|
||||
SaveFile::SetUserID(Component<TextEntryLabel>(USER_ID,"User ID Input")->GetLabel());
|
||||
if(Menu::menus[MAIN_MENU]->S(A::NEXT_MENU)=="New Game"){
|
||||
Menu::CloseMenu();
|
||||
Component<MenuComponent>(MAIN_MENU,"New Game Button")->Click();
|
||||
}else
|
||||
if(Menu::menus[MAIN_MENU]->S(A::NEXT_MENU)=="Load Game"){
|
||||
Menu::CloseMenu();
|
||||
Component<MenuComponent>(MAIN_MENU,"Load Game Button")->Click();
|
||||
}else{
|
||||
ERR("WARNING! Unknown Next Menu set! Current Value:"<<std::quoted(Menu::menus[MAIN_MENU]->S(A::NEXT_MENU)));
|
||||
}
|
||||
Menu::CloseMenu();
|
||||
return true;
|
||||
})END
|
||||
->SetGrayedOut(true);
|
||||
|
||||
Reference in New Issue
Block a user