Skip to content

Commit

Permalink
allow using inventory Preview on Empty Block Entities.
Browse files Browse the repository at this point in the history
  • Loading branch information
sakura-ryoko committed Dec 7, 2024
1 parent 30a8173 commit c747acf
Show file tree
Hide file tree
Showing 2 changed files with 2 additions and 3 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -191,7 +191,7 @@ else if (context.nbt() != null)
}
}

//Tweakeroo.logger.warn("renderInventoryOverlay: type [{}] // Nbt Type [{}]", type.toString(), context.nbt() != null ? InventoryOverlay.getInventoryType(context.nbt()) : "INVALID");
//Tweakeroo.logger.warn("renderInventoryOverlay: type [{}] // Nbt Type [{}] // inv.isEmpty({})", type.toString(), context.nbt() != null ? InventoryOverlay.getInventoryType(context.nbt()) : "INVALID", inv.isEmpty());

if (context.be() != null && context.be().getCachedState().getBlock() instanceof ShulkerBoxBlock sbb)
{
Expand Down
3 changes: 1 addition & 2 deletions src/main/java/fi/dy/masa/tweakeroo/util/RayTraceUtils.java
Original file line number Diff line number Diff line change
Expand Up @@ -167,8 +167,7 @@ public static HitResult getRayTraceFromEntity(World worldIn, Entity entityIn, bo
lastBlockEntityContext = null;
}

if (ctx != null &&
(ctx.inv() != null && !ctx.inv().isEmpty()))
if (ctx != null && ctx.inv() != null)
{
lastBlockEntityContext = Pair.of(pos, ctx);
return ctx;
Expand Down

0 comments on commit c747acf

Please sign in to comment.