Skip to content

Commit

Permalink
Merge pull request #26 from Cjsah/1.20.x
Browse files Browse the repository at this point in the history
break global for each
  • Loading branch information
Gu-ZT authored Jul 17, 2023
2 parents 3406c63 + d94c1fd commit d5b6be7
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -19,7 +19,7 @@ public static void autoReplenishment(Player fakePlayer) {
public static void replenishment(ItemStack itemStack, NonNullList<ItemStack> itemStackList) {
int count = itemStack.getMaxStackSize() / 2;
if (!itemStack.isEmpty() && itemStack.getCount() <= 8 && count > 8) {
for (ItemStack itemStack1 : itemStackList) {
global: for (ItemStack itemStack1 : itemStackList) {
if (itemStack1 == ItemStack.EMPTY || itemStack1 == itemStack) continue;
if (ItemStack.isSameItemSameTags(itemStack1, itemStack)) {
if (itemStack1.getCount() > count) {
Expand Down Expand Up @@ -53,7 +53,7 @@ public static void replenishment(ItemStack itemStack, NonNullList<ItemStack> ite
newTag.putByte("Slot", tag.getByte("Slot"));
tagList.set(i, newTag);
}
break;
break global;
}
}
}
Expand Down

0 comments on commit d5b6be7

Please sign in to comment.