Skip to content

Commit

Permalink
Fix more particle culling issues (neoforged#951)
Browse files Browse the repository at this point in the history
  • Loading branch information
embeddedt authored May 10, 2024
1 parent 03e346b commit 018e104
Show file tree
Hide file tree
Showing 2 changed files with 16 additions and 0 deletions.
Original file line number Diff line number Diff line change
@@ -0,0 +1,14 @@
--- a/net/minecraft/client/particle/ItemPickupParticle.java
+++ b/net/minecraft/client/particle/ItemPickupParticle.java
@@ -103,4 +_,11 @@
this.targetYOld = this.targetY;
this.targetZOld = this.targetZ;
}
+
+ // Neo: Computing a bounding box for the pickup animation is annoying to patch in, and probably slower than
+ // always rendering it
+ @Override
+ public net.minecraft.world.phys.AABB getRenderBoundingBox(float partialTicks) {
+ return net.minecraft.world.phys.AABB.INFINITE;
+ }
}
Original file line number Diff line number Diff line change
Expand Up @@ -45,6 +45,8 @@ public static void onRenderLevelStage(RenderLevelStageEvent event) {
}
});

Minecraft.getInstance().renderBuffers().bufferSource().endBatch(RenderType.lines());

poseStack.popPose();
}

Expand Down

0 comments on commit 018e104

Please sign in to comment.