CavePVP-Stuff/cSpigot-master/spigot-server-Patches/0104-Optimize-idle-furnaces.patch

23 lines
1.1 KiB
Diff
Raw Normal View History

2023-05-01 20:59:40 +02:00
From a2e66fb0e5bda4848d6cbc8b8592c4dcbf349cb2 Mon Sep 17 00:00:00 2001
From: Poweruser_rs <poweruser.rs@hotmail.com>
Date: Thu, 5 Nov 2015 13:20:55 +0100
Subject: [PATCH] Optimize idle furnaces
diff --git a/src/main/java/net/minecraft/server/TileEntityFurnace.java b/src/main/java/net/minecraft/server/TileEntityFurnace.java
index 430fc69c9..3fdd796cf 100644
--- a/src/main/java/net/minecraft/server/TileEntityFurnace.java
+++ b/src/main/java/net/minecraft/server/TileEntityFurnace.java
@@ -187,7 +187,7 @@ public class TileEntityFurnace extends TileEntity implements IWorldInventory {
}
if (!this.world.isStatic) {
- if (this.burnTime != 0 || this.items[1] != null && this.items[0] != null) {
+ if (this.burnTime != 0 || (this.items[1] != null && this.items[1].getItem() != Items.BUCKET) && this.items[0] != null) { // Poweruser - check for an empty bucket
// CraftBukkit start - Handle multiple elapsed ticks
if (this.burnTime <= 0 && this.canBurn()) { // CraftBukkit - == to <=
CraftItemStack fuel = CraftItemStack.asCraftMirror(this.items[1]);
--
2.13.3