diff --git a/paper-server/patches/sources/net/minecraft/world/level/block/state/properties/EnumProperty.java.patch b/paper-server/patches/sources/net/minecraft/world/level/block/state/properties/EnumProperty.java.patch new file mode 100644 index 0000000000..94537a6a1d --- /dev/null +++ b/paper-server/patches/sources/net/minecraft/world/level/block/state/properties/EnumProperty.java.patch @@ -0,0 +1,12 @@ +--- a/net/minecraft/world/level/block/state/properties/EnumProperty.java ++++ b/net/minecraft/world/level/block/state/properties/EnumProperty.java +@@ -59,8 +_,7 @@ + return this.ordinalToIndex[value.ordinal()]; + } + +- @Override +- public boolean equals(Object other) { ++ public boolean equals_unused(Object other) { // Paper - Perf: Optimize hashCode/equals + return this == other || other instanceof EnumProperty enumProperty && super.equals(other) && this.values.equals(enumProperty.values); + } + diff --git a/paper-server/patches/sources/net/minecraft/world/level/block/state/properties/IntegerProperty.java.patch b/paper-server/patches/sources/net/minecraft/world/level/block/state/properties/IntegerProperty.java.patch new file mode 100644 index 0000000000..a3b33fce20 --- /dev/null +++ b/paper-server/patches/sources/net/minecraft/world/level/block/state/properties/IntegerProperty.java.patch @@ -0,0 +1,12 @@ +--- a/net/minecraft/world/level/block/state/properties/IntegerProperty.java ++++ b/net/minecraft/world/level/block/state/properties/IntegerProperty.java +@@ -28,8 +_,7 @@ + return this.values; + } + +- @Override +- public boolean equals(Object other) { ++ public boolean equals_unused(Object other) { // Paper - Perf: Optimize hashCode/equals + return this == other || other instanceof IntegerProperty integerProperty && super.equals(other) && this.values.equals(integerProperty.values); + } + diff --git a/paper-server/patches/sources/net/minecraft/world/level/block/state/properties/Property.java.patch b/paper-server/patches/sources/net/minecraft/world/level/block/state/properties/Property.java.patch new file mode 100644 index 0000000000..78b6de8b7e --- /dev/null +++ b/paper-server/patches/sources/net/minecraft/world/level/block/state/properties/Property.java.patch @@ -0,0 +1,11 @@ +--- a/net/minecraft/world/level/block/state/properties/Property.java ++++ b/net/minecraft/world/level/block/state/properties/Property.java +@@ -72,7 +_,7 @@ + + @Override + public boolean equals(Object other) { +- return this == other || other instanceof Property property && this.clazz.equals(property.clazz) && this.name.equals(property.name); ++ return this == other; // Paper - Perf: Optimize hashCode/equals + } + + @Override diff --git a/paper-server/patches/unapplied/net/minecraft/world/level/block/state/properties/EnumProperty.java.patch b/paper-server/patches/unapplied/net/minecraft/world/level/block/state/properties/EnumProperty.java.patch deleted file mode 100644 index 95194b370f..0000000000 --- a/paper-server/patches/unapplied/net/minecraft/world/level/block/state/properties/EnumProperty.java.patch +++ /dev/null @@ -1,12 +0,0 @@ ---- a/net/minecraft/world/level/block/state/properties/EnumProperty.java -+++ b/net/minecraft/world/level/block/state/properties/EnumProperty.java -@@ -59,8 +59,7 @@ - return this.ordinalToIndex[enum_.ordinal()]; - } - -- @Override -- public boolean equals(Object object) { -+ public boolean equals_unused(Object object) { // Paper - Perf: Optimize hashCode/equals - if (this == object) { - return true; - } else { diff --git a/paper-server/patches/unapplied/net/minecraft/world/level/block/state/properties/IntegerProperty.java.patch b/paper-server/patches/unapplied/net/minecraft/world/level/block/state/properties/IntegerProperty.java.patch deleted file mode 100644 index 6542f0bc6f..0000000000 --- a/paper-server/patches/unapplied/net/minecraft/world/level/block/state/properties/IntegerProperty.java.patch +++ /dev/null @@ -1,12 +0,0 @@ ---- a/net/minecraft/world/level/block/state/properties/IntegerProperty.java -+++ b/net/minecraft/world/level/block/state/properties/IntegerProperty.java -@@ -28,8 +28,7 @@ - return this.values; - } - -- @Override -- public boolean equals(Object object) { -+ public boolean equals_unused(Object object) { // Paper - Perf: Optimize hashCode/equals - if (this == object) { - return true; - } else { diff --git a/paper-server/patches/unapplied/net/minecraft/world/level/block/state/properties/Property.java.patch b/paper-server/patches/unapplied/net/minecraft/world/level/block/state/properties/Property.java.patch deleted file mode 100644 index e0a6a659ba..0000000000 --- a/paper-server/patches/unapplied/net/minecraft/world/level/block/state/properties/Property.java.patch +++ /dev/null @@ -1,11 +0,0 @@ ---- a/net/minecraft/world/level/block/state/properties/Property.java -+++ b/net/minecraft/world/level/block/state/properties/Property.java -@@ -72,7 +72,7 @@ - - @Override - public boolean equals(Object object) { -- return this == object || object instanceof Property property && this.clazz.equals(property.clazz) && this.name.equals(property.name); -+ return this == object; // Paper - Perf: Optimize hashCode/equals - } - - @Override