NF! 1.13 - more fixes
This commit is contained in:
parent
c99e4a22aa
commit
3bcba64d28
|
@ -1,4 +1,4 @@
|
|||
From 5fb4ac36f7ca32dd67392c2ad7e9fb5b3ad90cb7 Mon Sep 17 00:00:00 2001
|
||||
From 602dc96cc78e46affde033a48393ca3c722a7c75 Mon Sep 17 00:00:00 2001
|
||||
From: Aikar <aikar@aikar.co>
|
||||
Date: Mon, 28 Mar 2016 20:55:47 -0400
|
||||
Subject: [PATCH] MC Utils
|
||||
|
@ -18,7 +18,7 @@ index c3e990bdf..e2a7b4be2 100644
|
|||
}
|
||||
}
|
||||
diff --git a/src/main/java/net/minecraft/server/BlockPosition.java b/src/main/java/net/minecraft/server/BlockPosition.java
|
||||
index 002da2a19..b04ca5071 100644
|
||||
index 002da2a19..80cdf5528 100644
|
||||
--- a/src/main/java/net/minecraft/server/BlockPosition.java
|
||||
+++ b/src/main/java/net/minecraft/server/BlockPosition.java
|
||||
@@ -10,7 +10,7 @@ import org.apache.logging.log4j.Logger;
|
||||
|
@ -30,6 +30,14 @@ index 002da2a19..b04ca5071 100644
|
|||
public static final BlockPosition ZERO = new BlockPosition(0, 0, 0);
|
||||
private static final int c = 1 + MathHelper.e(MathHelper.c(30000000));
|
||||
private static final int d = BlockPosition.c;
|
||||
@@ -45,6 +45,7 @@ public class BlockPosition extends BaseBlockPosition {
|
||||
return d0 == 0.0D && d1 == 0.0D && d2 == 0.0D ? this : new BlockPosition((double) this.getX() + d0, (double) this.getY() + d1, (double) this.getZ() + d2);
|
||||
}
|
||||
|
||||
+ public BlockPosition add(int i, int j, int k) {return a(i, j, k);} // Paper - OBFHELPER
|
||||
public BlockPosition a(int i, int j, int k) {
|
||||
return i == 0 && j == 0 && k == 0 ? this : new BlockPosition(this.getX() + i, this.getY() + j, this.getZ() + k);
|
||||
}
|
||||
diff --git a/src/main/java/net/minecraft/server/Chunk.java b/src/main/java/net/minecraft/server/Chunk.java
|
||||
index 0ae780c8e..3b97981bc 100644
|
||||
--- a/src/main/java/net/minecraft/server/Chunk.java
|
||||
|
@ -438,7 +446,7 @@ index b3c944d70..e56d4836d 100644
|
|||
- }
|
||||
}
|
||||
diff --git a/src/main/java/net/minecraft/server/PlayerConnection.java b/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||
index 3cb868299..227bc857e 100644
|
||||
index fa4a7fa63..749be86fe 100644
|
||||
--- a/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||
+++ b/src/main/java/net/minecraft/server/PlayerConnection.java
|
||||
@@ -66,9 +66,9 @@ public class PlayerConnection implements PacketListenerPlayIn, ITickable {
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
From 67514f1f5435a6fecdeaa029189972d8d9cc6419 Mon Sep 17 00:00:00 2001
|
||||
From d251f7e298b065e5da84fe228f169a2437a09823 Mon Sep 17 00:00:00 2001
|
||||
From: Aikar <aikar@aikar.co>
|
||||
Date: Thu, 3 Mar 2016 02:07:55 -0600
|
||||
Subject: [PATCH] Optimize isValidLocation, getType and getBlockData for inling
|
||||
|
@ -12,7 +12,7 @@ Replace all calls to the new place to the unnecessary forward.
|
|||
Optimize getType and getBlockData to manually inline and optimize the calls
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/BaseBlockPosition.java b/src/main/java/net/minecraft/server/BaseBlockPosition.java
|
||||
index c3e990bdf..d190144a1 100644
|
||||
index e2a7b4be2..58f8b4b72 100644
|
||||
--- a/src/main/java/net/minecraft/server/BaseBlockPosition.java
|
||||
+++ b/src/main/java/net/minecraft/server/BaseBlockPosition.java
|
||||
@@ -10,6 +10,14 @@ public class BaseBlockPosition implements Comparable<BaseBlockPosition> {
|
||||
|
@ -31,10 +31,10 @@ index c3e990bdf..d190144a1 100644
|
|||
public BaseBlockPosition(int i, int j, int k) {
|
||||
this.a = i;
|
||||
diff --git a/src/main/java/net/minecraft/server/BlockPosition.java b/src/main/java/net/minecraft/server/BlockPosition.java
|
||||
index 002da2a19..0fddd916b 100644
|
||||
index 80cdf5528..39252ad9a 100644
|
||||
--- a/src/main/java/net/minecraft/server/BlockPosition.java
|
||||
+++ b/src/main/java/net/minecraft/server/BlockPosition.java
|
||||
@@ -338,6 +338,16 @@ public class BlockPosition extends BaseBlockPosition {
|
||||
@@ -339,6 +339,16 @@ public class BlockPosition extends BaseBlockPosition {
|
||||
protected int b;
|
||||
protected int c;
|
||||
protected int d;
|
||||
|
@ -52,7 +52,7 @@ index 002da2a19..0fddd916b 100644
|
|||
public MutableBlockPosition() {
|
||||
this(0, 0, 0);
|
||||
diff --git a/src/main/java/net/minecraft/server/Chunk.java b/src/main/java/net/minecraft/server/Chunk.java
|
||||
index f376b3a34..75fcc693d 100644
|
||||
index fb27dcac2..1c0580f79 100644
|
||||
--- a/src/main/java/net/minecraft/server/Chunk.java
|
||||
+++ b/src/main/java/net/minecraft/server/Chunk.java
|
||||
@@ -430,12 +430,24 @@ public class Chunk implements IChunkAccess {
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
From 1a5effd5460ca5dcba227eecfb2387ad4c170a57 Mon Sep 17 00:00:00 2001
|
||||
From 7e2d632e56746887a6524793b2e17150e67202ae Mon Sep 17 00:00:00 2001
|
||||
From: Aikar <aikar@aikar.co>
|
||||
Date: Wed, 4 May 2016 23:59:38 -0400
|
||||
Subject: [PATCH] Implement getI18NDisplayName
|
||||
|
@ -8,7 +8,7 @@ Currently the server only supports the English language. To override this,
|
|||
You must replace the language file embedded in the server jar.
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemFactory.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemFactory.java
|
||||
index 27a264f54..6fc0ce050 100644
|
||||
index 27a264f54..1cdbdf6d0 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemFactory.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemFactory.java
|
||||
@@ -293,5 +293,18 @@ public final class CraftItemFactory implements ItemFactory {
|
||||
|
@ -26,7 +26,7 @@ index 27a264f54..6fc0ce050 100644
|
|||
+ nms = CraftItemStack.asNMSCopy(item);
|
||||
+ }
|
||||
+
|
||||
+ return nms != null ? nms.getName() : null;
|
||||
+ return nms != null ? nms.getItem().getName() : null;
|
||||
+ }
|
||||
// Paper end
|
||||
}
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
From 0530d0a31a3a726c633b09f58e383402b3f291a6 Mon Sep 17 00:00:00 2001
|
||||
From 54dbc7e31f0938139214ce0e2591c9589ab7f119 Mon Sep 17 00:00:00 2001
|
||||
From: Zach Brown <zach.brown@destroystokyo.com>
|
||||
Date: Sat, 27 Jan 2018 17:04:14 -0500
|
||||
Subject: [PATCH] Add ArmorStand Item Meta
|
||||
|
@ -13,7 +13,7 @@ starting point for future additions in this area.
|
|||
Fixes GH-559
|
||||
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemFactory.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemFactory.java
|
||||
index 6fc0ce050..152a677e5 100644
|
||||
index 1cdbdf6d0..da109e35a 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemFactory.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftItemFactory.java
|
||||
@@ -184,6 +184,8 @@ public final class CraftItemFactory implements ItemFactory {
|
||||
|
@ -350,7 +350,7 @@ index 000000000..dc372f6db
|
|||
+ }
|
||||
+}
|
||||
diff --git a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaItem.java b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaItem.java
|
||||
index e43a24989..5bff99edd 100644
|
||||
index e43a24989..df4bbba57 100644
|
||||
--- a/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaItem.java
|
||||
+++ b/src/main/java/org/bukkit/craftbukkit/inventory/CraftMetaItem.java
|
||||
@@ -134,6 +134,7 @@ class CraftMetaItem implements ItemMeta, Damageable, Repairable {
|
||||
|
@ -361,11 +361,13 @@ index e43a24989..5bff99edd 100644
|
|||
.put(CraftMetaItem.class, "UNSPECIFIC")
|
||||
.build();
|
||||
|
||||
@@ -1084,6 +1085,14 @@ class CraftMetaItem implements ItemMeta, Damageable, Repairable {
|
||||
@@ -1083,7 +1084,15 @@ class CraftMetaItem implements ItemMeta, Damageable, Repairable {
|
||||
CraftMetaCharge.EXPLOSION.NBT,
|
||||
CraftMetaBlockState.BLOCK_ENTITY_TAG.NBT,
|
||||
CraftMetaKnowledgeBook.BOOK_RECIPES.NBT,
|
||||
CraftMetaTropicalFishBucket.VARIANT.NBT
|
||||
- CraftMetaTropicalFishBucket.VARIANT.NBT
|
||||
+ // Paper start
|
||||
+ CraftMetaTropicalFishBucket.VARIANT.NBT,
|
||||
+ CraftMetaArmorStand.ENTITY_TAG.NBT,
|
||||
+ CraftMetaArmorStand.INVISIBLE.NBT,
|
||||
+ CraftMetaArmorStand.NO_BASE_PLATE.NBT,
|
||||
|
|
|
@ -1,4 +1,4 @@
|
|||
From 3699a4c4a5985731a052980b1daf296832225ba7 Mon Sep 17 00:00:00 2001
|
||||
From b78f84d7b123adda716195bf9f2374f78ff92dcd Mon Sep 17 00:00:00 2001
|
||||
From: Aikar <aikar@aikar.co>
|
||||
Date: Sat, 16 Jun 2018 16:23:38 -0400
|
||||
Subject: [PATCH] Ignore Missing Recipes in RecipeBook to avoid data errors
|
||||
|
@ -6,7 +6,7 @@ Subject: [PATCH] Ignore Missing Recipes in RecipeBook to avoid data errors
|
|||
This code was causing NPE's in saving player data, potentially related to reloads.
|
||||
|
||||
diff --git a/src/main/java/net/minecraft/server/RecipeBookServer.java b/src/main/java/net/minecraft/server/RecipeBookServer.java
|
||||
index 71d6c4552..893f67094 100644
|
||||
index 71d6c4552..799f2be70 100644
|
||||
--- a/src/main/java/net/minecraft/server/RecipeBookServer.java
|
||||
+++ b/src/main/java/net/minecraft/server/RecipeBookServer.java
|
||||
@@ -77,7 +77,11 @@ public class RecipeBookServer extends RecipeBook {
|
||||
|
@ -17,7 +17,7 @@ index 71d6c4552..893f67094 100644
|
|||
+ // Paper start - ignore missing recipes
|
||||
+ IRecipe recipe = this.h.a(minecraftkey);
|
||||
+ if (recipe == null) continue;
|
||||
+ nbttaglist.add(new NBTTagString(minecraftkey.toString()))
|
||||
+ nbttaglist.add(new NBTTagString(minecraftkey.toString()));
|
||||
+ // Paper end
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue