a4647a8a71
Fix empty `ench` tags being wiped by the meta system SpigotMC/Spigot@cc9a1a417f Add Hunger Config Values SpigotMC/Spigot@2cd515e224 Make debug logging togglable SpigotMC/Spigot@d31b1d616f Spigot has implemented a system of hunger exhaustion similar to ours, as such a lot of config values have been moved there. Our exhaustion patch has been trimmed and only a few values for exhaustion remain in paper.yml, the others now sit in spigot.yml
37 lines
1.7 KiB
Diff
37 lines
1.7 KiB
Diff
From 8260d6efa8936d75822c4b324ecae9e4ac299033 Mon Sep 17 00:00:00 2001
|
|
From: Jedediah Smith <jedediah@silencegreys.com>
|
|
Date: Wed, 6 Aug 2014 18:17:41 -0500
|
|
Subject: [PATCH] Center TNT grid sample points
|
|
|
|
More information at https://bugs.mojang.com/browse/MC-65697
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/World.java b/src/main/java/net/minecraft/server/World.java
|
|
index 0358c7c..717be3b 100644
|
|
--- a/src/main/java/net/minecraft/server/World.java
|
|
+++ b/src/main/java/net/minecraft/server/World.java
|
|
@@ -1911,6 +1911,12 @@ public abstract class World implements IBlockAccess {
|
|
double d1 = 1.0D / ((axisalignedbb.e - axisalignedbb.b) * 2.0D + 1.0D);
|
|
double d2 = 1.0D / ((axisalignedbb.f - axisalignedbb.c) * 2.0D + 1.0D);
|
|
|
|
+ // PaperSpigot start - Center TNT sample points for more accurate calculations
|
|
+ // Shift the sample points so they are centered on the BB
|
|
+ double xOffset = (1.0 - Math.floor(1.0 / d0) * d0) / 2.0;
|
|
+ double zOffset = (1.0 - Math.floor(1.0 / d2) * d2) / 2.0;
|
|
+ // PaperSpigot end
|
|
+
|
|
if (d0 >= 0.0D && d1 >= 0.0D && d2 >= 0.0D) {
|
|
int i = 0;
|
|
int j = 0;
|
|
@@ -1923,7 +1929,7 @@ public abstract class World implements IBlockAccess {
|
|
double d4 = axisalignedbb.b + (axisalignedbb.e - axisalignedbb.b) * (double) f1;
|
|
double d5 = axisalignedbb.c + (axisalignedbb.f - axisalignedbb.c) * (double) f2;
|
|
|
|
- if (this.a(vec3d2.b(d3, d4, d5), vec3d) == null) { // CraftBukkit
|
|
+ if (this.a(vec3d2.b(xOffset + d3, d4, zOffset + d5), vec3d) == null) { // CraftBukkit // PaperSpigot
|
|
++i;
|
|
}
|
|
|
|
--
|
|
1.9.1
|
|
|