Returning to camp no longer rewards you stage items. Changed CloseAllMenus() to actually call CloseMenu() multiple times instead to prevent lockouts while holding down menu buttons and having menus closed on (such as getting hit by enemy attacks while in the pause menu). Release Build 7646.

pull/35/head
sigonasr2 11 months ago
parent e8ac5a957f
commit 08aa7a309d
  1. 7
      Adventures in Lestoria/Menu.cpp
  2. 3
      Adventures in Lestoria/State_LevelComplete.cpp
  3. 2
      Adventures in Lestoria/Version.h
  4. BIN
      x64/Release/Adventures in Lestoria.exe

@ -639,10 +639,9 @@ std::pair<MenuType,std::string>Menu::GetMemoryLeakReportInfo(){
}
void Menu::CloseAllMenus(){
if(stack.size()>0){
stack.clear();
}else{
ERR("WARNING! Trying to close out no menu?? Why are we doing this?")
if(stack.size()==0)ERR("WARNING! Trying to close out no menu?? Why are we doing this?");
while(stack.size()>0){
CloseMenu();
}
}

@ -61,6 +61,8 @@ void State_LevelComplete::OnStateChange(GameState*prevState){
Component<ProgressBar>(MenuType::LEVEL_COMPLETE,"XP Bar")->ResetProgressBar(game->GetPlayer()->CurrentXP(),game->GetPlayer()->NextLevelXPRequired());
accumulatedXP=game->GetPlayer()->GetAccumulatedXP();
game->GetPlayer()->AddXP(game->GetPlayer()->GetAccumulatedXP());
if(Component<MenuLabel>(LEVEL_COMPLETE,"Stage Complete Label")->GetLabel()!="Stage Summary"){ //If the label says stage summary, we didn't actually the level. Don't reward any stage items to the player.
for(const ItemMapData&data:game->GetCurrentMap().GetStageLoot()){
uint8_t amountDiff=data.maxAmt-data.minAmt;
uint8_t randomAmt=data.maxAmt;
@ -73,6 +75,7 @@ void State_LevelComplete::OnStateChange(GameState*prevState){
}
}
}
}
game->GetPlayer()->SetState(State::NORMAL);
Menu::OpenMenu(LEVEL_COMPLETE);
};

@ -39,7 +39,7 @@ All rights reserved.
#define VERSION_MAJOR 0
#define VERSION_MINOR 3
#define VERSION_PATCH 0
#define VERSION_BUILD 7644
#define VERSION_BUILD 7646
#define stringify(a) stringify_(a)
#define stringify_(a) #a

Loading…
Cancel
Save