Skip to content

Commit

Permalink
lunchable on 1.12.2
Browse files Browse the repository at this point in the history
  • Loading branch information
PTOM76 committed Aug 12, 2024
1 parent bf910ef commit cf3d358
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 6 deletions.
2 changes: 0 additions & 2 deletions src/main/java/net/pitan76/storagebox/StorageBoxClient.java
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,6 @@ public void onInitializeClient() {

ItemModelRegistry.registerItemModel(StorageBoxItem.instance, StorageBoxMod.id("storagebox"));



//.register(StorageBoxScreenHandler.SCREEN_HANDLER_TYPE, StorageBoxScreen::new);

/*
Expand Down
10 changes: 6 additions & 4 deletions src/main/java/net/pitan76/storagebox/mixin/ItemPickupMixin.java
Original file line number Diff line number Diff line change
@@ -1,7 +1,9 @@
package net.pitan76.storagebox.mixin;

import net.minecraft.block.Blocks;
import net.minecraft.entity.ItemEntity;
import net.minecraft.entity.player.PlayerEntity;
import net.minecraft.item.BlockItem;
import net.minecraft.item.Item;
import net.minecraft.item.ItemStack;
import net.minecraft.stat.Stats;
Expand Down Expand Up @@ -107,11 +109,11 @@ private void onPickup(PlayerEntity player, CallbackInfo ci) {
// インベントリ
for (ItemStack inStack : player.inventory.field_15082) {
// エンダーチェストが含まれていたらエンダーチェストもループ処理
/*
if (supportEnderChest && inStack.getItem() == Items.ENDER_CHEST && !checkedEnderChest) {

if (supportEnderChest && inStack.getItem() == BlockItem.fromBlock(Blocks.ENDERCHEST) && !checkedEnderChest) {
for (int i = 0; i < player.getEnderChestInventory().getInvSize(); i++) {
ItemStack enderChestStack = player.getEnderChestInventory().getInvStack(i);
if (enderChestStack.hasTag()) {
if (enderChestStack.hasNbt()) {
if (process(enderChestStack, itemStack)) {
insertedBox = true;
itemStack = ItemStack.EMPTY;
Expand All @@ -122,7 +124,7 @@ private void onPickup(PlayerEntity player, CallbackInfo ci) {
}
}

*/

if (inStack.hasNbt()) {
if (process(inStack, itemStack)) {
insertedBox = true;
Expand Down

0 comments on commit cf3d358

Please sign in to comment.