Skip to content

Commit

Permalink
Revert "Now I'm starting to have second thoughts."
Browse files Browse the repository at this point in the history
This reverts commit d1654f5.
  • Loading branch information
noobanidus committed Jan 24, 2024
1 parent 10972fc commit 5aebf49
Showing 1 changed file with 0 additions and 18 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@
import net.minecraft.world.level.Level;
import net.minecraft.world.level.block.entity.BaseContainerBlockEntity;
import net.minecraft.world.level.block.entity.BlockEntity;
import noobanidus.mods.lootr.api.LootrAPI;
import noobanidus.mods.lootr.api.MenuBuilder;
import noobanidus.mods.lootr.api.inventory.ILootrInventory;
import noobanidus.mods.lootr.entity.LootrChestMinecartEntity;
Expand Down Expand Up @@ -237,21 +236,4 @@ public String writeName() {
public NonNullList<ItemStack> getInventoryContents() {
return this.contents;
}

public void setSize (int size) {
if (size < getContainerSize()) {
LootrAPI.LOG.error("Tried to reduce container size from {} to {}", getContainerSize(), size);
return;
}
if (size == getContainerSize()) {
return;
}

NonNullList<ItemStack> newContents = NonNullList.withSize(size, ItemStack.EMPTY);
for (int i = 0; i < contents.size(); i++) {
newContents.set(i, contents.get(i));
}
this.contents = newContents;
setChanged();
}
}

0 comments on commit 5aebf49

Please sign in to comment.