Update backend to handle newly created accounts.

This commit is contained in:
2024-02-11 23:08:14 -06:00
parent 5788123ab5
commit 2c76105ddf
5 changed files with 572 additions and 57 deletions
@@ -92,7 +92,7 @@ void Menu::InitializeConsumableInventoryWindow(){
std::vector<std::weak_ptr<MenuComponent>>&components=Component<InventoryScrollableWindowComponent>(INVENTORY_CONSUMABLES,"inventory")->GetComponents();
auto inventory=Component<InventoryScrollableWindowComponent>(INVENTORY_CONSUMABLES,"inventory");
auto foundComponent=std::find_if(components.begin(),components.end(),[&](auto&component){
if(!ISBLANK(DYNAMIC_POINTER_CAST<MenuItemButton>(component)->GetItem().lock())&&DYNAMIC_POINTER_CAST<MenuItemButton>(component)->GetItem().lock()->ActualName()==game->GetLoadoutItem(Menu::menus[type]->I(A::LOADOUT_SLOT)).lock()->ActualName()){
if(!ISBLANK(DYNAMIC_POINTER_CAST<MenuItemButton>(component)->GetItem().lock())&&!ISBLANK(game->GetLoadoutItem(Menu::menus[type]->I(A::LOADOUT_SLOT)))&&DYNAMIC_POINTER_CAST<MenuItemButton>(component)->GetItem().lock()->ActualName()==game->GetLoadoutItem(Menu::menus[type]->I(A::LOADOUT_SLOT)).lock()->ActualName()){
return true;
}
return false;