mirror of
https://github.com/PaperMC/Paper.git
synced 2024-11-22 18:45:54 +01:00
1ab021ddca
Upstream has released updates that appears to apply and compile correctly.
This update has not been tested by PaperMC and as with ANY update, please do your own testing
Bukkit Changes:
565a5727 #533: Add consumed item, hand and consumeItem boolean to EntityShootBowEvent
CraftBukkit Changes:
927200a9
#718: Add consumed item, hand and consumeItem boolean to EntityShootBowEvent
20 lines
1.1 KiB
Diff
20 lines
1.1 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: BrodyBeckwith <brody@beckwith.dev>
|
|
Date: Tue, 14 Jan 2020 17:49:03 -0500
|
|
Subject: [PATCH] Optimize call to getFluid for explosions
|
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/Explosion.java b/src/main/java/net/minecraft/server/Explosion.java
|
|
index b7d635ca2cbe9bf7e2e3a2ae5fa7a20f39dd913b..9823fb5eebbfee026d3173c81368cf6e3e901f92 100644
|
|
--- a/src/main/java/net/minecraft/server/Explosion.java
|
|
+++ b/src/main/java/net/minecraft/server/Explosion.java
|
|
@@ -125,7 +125,7 @@ public class Explosion {
|
|
for (float f1 = 0.3F; f > 0.0F; f -= 0.22500001F) {
|
|
BlockPosition blockposition = new BlockPosition(d4, d5, d6);
|
|
IBlockData iblockdata = this.world.getType(blockposition);
|
|
- Fluid fluid = this.world.getFluid(blockposition);
|
|
+ Fluid fluid = iblockdata.getFluid(); // Paper
|
|
Optional<Float> optional = this.l.a(this, this.world, blockposition, iblockdata, fluid);
|
|
|
|
if (optional.isPresent()) {
|