mirror of
https://github.com/Winds-Studio/Leaf.git
synced 2025-12-27 10:59:16 +00:00
Upstream has released updates that appear to apply and compile correctly Paper Changes: PaperMC/Paper@b0da38c2 Repository details in RuntimeException for MavenLibraryResolver#addRepository (#12939) PaperMC/Paper@1922be90 Update custom tags (#12183) PaperMC/Paper@79cf1353 Ignore HopperInventorySearchEvent when it has no listeners (#13009) PaperMC/Paper@ea014f7a feat: add stuckEntityPoiRetryDelay config (#12949) PaperMC/Paper@a9e76749 Support for showNotification in PlayerRecipeDiscoverEvent (#12992) PaperMC/Paper@5622c9dd Expose attribute sentiment (#12974) PaperMC/Paper@42b653b1 Expose more argument types (#12665) PaperMC/Paper@52d9a221 [ci/skip] Fix typo in Display javadoc (#13010) PaperMC/Paper@614e9acf Improve APIs around riptide tridents (#12996) PaperMC/Paper@51706e5a Fixed DyeItem sheep dye hunk
28 lines
1.6 KiB
Diff
28 lines
1.6 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: Dreeam <61569423+Dreeam-qwq@users.noreply.github.com>
|
|
Date: Fri, 7 Jun 2024 17:43:43 +0800
|
|
Subject: [PATCH] Remove stream in BlockBehaviour cache blockstate
|
|
|
|
|
|
diff --git a/net/minecraft/world/level/block/state/BlockBehaviour.java b/net/minecraft/world/level/block/state/BlockBehaviour.java
|
|
index 3741afd1b2a5cb5cfce5e14cb78aa5ff5c3b218e..331474bb33c8612283a0ec478c1ae8768180b22d 100644
|
|
--- a/net/minecraft/world/level/block/state/BlockBehaviour.java
|
|
+++ b/net/minecraft/world/level/block/state/BlockBehaviour.java
|
|
@@ -1064,8 +1064,14 @@ public abstract class BlockBehaviour implements FeatureElement {
|
|
)
|
|
);
|
|
} else {
|
|
- this.largeCollisionShape = Arrays.stream(Direction.Axis.values())
|
|
- .anyMatch(dir -> this.collisionShape.min(dir) < 0.0 || this.collisionShape.max(dir) > 1.0);
|
|
+ // Leaf start - Remove stream in BlockBehaviour cache blockstate
|
|
+ for (Direction.Axis axis : Direction.Axis.values()) {
|
|
+ if (this.collisionShape.min(axis) < 0.0 || this.collisionShape.max(axis) > 1.0) {
|
|
+ this.largeCollisionShape = true;
|
|
+ break;
|
|
+ }
|
|
+ }
|
|
+ // Leaf end - Remove stream in BlockBehaviour cache blockstate
|
|
this.faceSturdy = new boolean[DIRECTIONS.length * SUPPORT_TYPE_COUNT];
|
|
|
|
for (Direction direction : DIRECTIONS) {
|