Allow shift clicking to get as much as possible
This commit is contained in:
parent
fce0e3ffa1
commit
621d7514bb
@ -84,7 +84,7 @@ public class StorageScreen extends PagedGui {
|
||||
if (clickedElement != null) {
|
||||
ItemStack clickedItem = clickedElement.getItemStack();
|
||||
ItemStack noLoreStack = removeCountFromLore(clickedItem);
|
||||
if (noLoreStack.getCount() > noLoreStack.getMaxCount()) {
|
||||
if (noLoreStack.getCount() > noLoreStack.getMaxCount() && !type.shift) {
|
||||
noLoreStack.setCount(noLoreStack.getMaxCount());
|
||||
}
|
||||
int maxToInsert = canInsertItemIntoPlayerInventory(player, noLoreStack);
|
||||
@ -141,6 +141,7 @@ public class StorageScreen extends PagedGui {
|
||||
|
||||
public void doSearch(String query) {
|
||||
this.query = query;
|
||||
this.page = 0;
|
||||
this.updateDisplay();
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user