Fix a bug with loadout item slots not being properly handled when items are selected while they're blank.

pull/28/head
sigonasr2 1 year ago
parent f427928ca6
commit c05f76cdfd
  1. 2
      Crawler/InventoryScrollableWindowComponent.h
  2. 2
      Crawler/Version.h

@ -105,7 +105,6 @@ protected:
MenuFunc useItemFunc=[&](MenuFuncData data){
MenuItemButton*button=(MenuItemButton*)data.component;
if(!data.game->GetLoadoutItem(data.menu.I(A::LOADOUT_SLOT)).IsBlank()){ //This loadout slot seems to have an item in it already, so deselect that one first.
data.game->ClearLoadoutItem(data.menu.I(A::LOADOUT_SLOT));
for(MenuComponent*component:components){
if(component->GetName().starts_with("item")){
@ -121,7 +120,6 @@ protected:
}
}
}
}
button->selected=data.menu.I(A::LOADOUT_SLOT);
data.game->SetLoadoutItem(button->selected,button->GetItem().Name());
return true;

@ -33,7 +33,7 @@ SUCH DAMAGE.
#define VERSION_MAJOR 0
#define VERSION_MINOR 2
#define VERSION_PATCH 1
#define VERSION_BUILD 2854
#define VERSION_BUILD 2856
#define stringify(a) stringify_(a)
#define stringify_(a) #a

Loading…
Cancel
Save