Skip to content

Commit

Permalink
expand cache if inventory size changed
Browse files Browse the repository at this point in the history
closes #110
  • Loading branch information
deirn committed Sep 25, 2021
1 parent 5f635e4 commit fa305aa
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -505,6 +505,7 @@ open class RequestScreenHandler(
val stacks = it.value

for (i in 0 until inventory.size()) {
if (i >= stacks.size) stacks.add(ItemStack.EMPTY)
val before = stacks[i]
val after = inventory.getStack(i)
if (!before.isItemAndTagEqual(after) || before.count != after.count) {
Expand Down

0 comments on commit fa305aa

Please sign in to comment.