mirror of
https://github.com/PurpurMC/Purpur.git
synced 2026-02-22 10:57:43 +01:00
Updated Upstream (Paper)
Upstream has released updates that appears to apply and compile correctly Paper Changes: cc001a73b Climbing should not bypass cramming gamerule b9930b39d Add legacy plugin count to metrics 4729e6b90 Add more lightning API 5e220bcb5 [ci skip] add stale bot configuration 2a44498a5 Add PlayerItemCooldownEvent fd33bcee1 Add LivingEntity#clearActiveItem a99e0ca05 Fix Player spawnParticle x/y/z precision loss
This commit is contained in:
43
patches/server/0133-Infinite-fuel-furnace.patch
Normal file
43
patches/server/0133-Infinite-fuel-furnace.patch
Normal file
@@ -0,0 +1,43 @@
|
||||
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
||||
From: William Blake Galbreath <Blake.Galbreath@GMail.com>
|
||||
Date: Mon, 19 Oct 2020 15:14:01 -0500
|
||||
Subject: [PATCH] Infinite fuel furnace
|
||||
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/TileEntityFurnace.java b/src/main/java/net/minecraft/server/TileEntityFurnace.java
|
||||
index 1d3c2dd936..e96fc0420a 100644
|
||||
--- a/src/main/java/net/minecraft/server/TileEntityFurnace.java
|
||||
+++ b/src/main/java/net/minecraft/server/TileEntityFurnace.java
|
||||
@@ -266,6 +266,16 @@ public abstract class TileEntityFurnace extends TileEntityContainer implements I
|
||||
if (!this.world.isClientSide) {
|
||||
ItemStack itemstack = (ItemStack) this.items.get(1);
|
||||
|
||||
+ // Purpur start
|
||||
+ if (world.purpurConfig.furnaceInfiniteFuel && !isBurning() && itemstack.isEmpty() && !items.get(0).isEmpty() && world.getTime() % 20 == 0) {
|
||||
+ BlockPosition pos = getPosition().down();
|
||||
+ if (world.getBlockIfLoaded(pos).getItem() == Blocks.LAVA.getItem()) {
|
||||
+ world.setTypeAndData(pos, Blocks.AIR.getBlockData(), 3);
|
||||
+ itemstack = Items.LAVA_BUCKET.createItemStack();
|
||||
+ }
|
||||
+ }
|
||||
+ // Purpur end
|
||||
+
|
||||
if (!this.isBurning() && (itemstack.isEmpty() || ((ItemStack) this.items.get(0)).isEmpty())) {
|
||||
if (!this.isBurning() && this.cookTime > 0) {
|
||||
this.cookTime = MathHelper.clamp(this.cookTime - 2, 0, this.cookTimeTotal);
|
||||
diff --git a/src/main/java/net/pl3x/purpur/PurpurWorldConfig.java b/src/main/java/net/pl3x/purpur/PurpurWorldConfig.java
|
||||
index e64cbed34e..9a595c2f91 100644
|
||||
--- a/src/main/java/net/pl3x/purpur/PurpurWorldConfig.java
|
||||
+++ b/src/main/java/net/pl3x/purpur/PurpurWorldConfig.java
|
||||
@@ -340,6 +340,11 @@ public class PurpurWorldConfig {
|
||||
farmlandGetsMoistFromBelow = getBoolean("blocks.farmland.gets-moist-from-below", farmlandGetsMoistFromBelow);
|
||||
}
|
||||
|
||||
+ public boolean furnaceInfiniteFuel = false;
|
||||
+ private void furnaceSettings() {
|
||||
+ furnaceInfiniteFuel = getBoolean("blocks.furnace.infinite-fuel", furnaceInfiniteFuel);
|
||||
+ }
|
||||
+
|
||||
public boolean lavaInfinite = false;
|
||||
public int lavaInfiniteRequiredSources = 2;
|
||||
public int lavaSpeedNether = 10;
|
||||
Reference in New Issue
Block a user