mirror of
https://github.com/PaperMC/Paper.git
synced 2024-12-30 16:19:03 +01:00
remove calls to DoNotUse methods
This commit is contained in:
parent
dcbe8f75f2
commit
57a40dbdd3
4 changed files with 26 additions and 5 deletions
|
@ -105,6 +105,8 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
||||||
+
|
+
|
||||||
+ INVALID_PAYLOAD,
|
+ INVALID_PAYLOAD,
|
||||||
+
|
+
|
||||||
|
+ INVALID_COOKIE,
|
||||||
|
+
|
||||||
+ SPAM,
|
+ SPAM,
|
||||||
+
|
+
|
||||||
+ ILLEGAL_ACTION,
|
+ ILLEGAL_ACTION,
|
||||||
|
|
|
@ -144,6 +144,15 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
||||||
// Paper start - adventure pack callbacks
|
// Paper start - adventure pack callbacks
|
||||||
// call the callbacks before the previously-existing event so the event has final say
|
// call the callbacks before the previously-existing event so the event has final say
|
||||||
@@ -0,0 +0,0 @@ public abstract class ServerCommonPacketListenerImpl implements ServerCommonPack
|
@@ -0,0 +0,0 @@ public abstract class ServerCommonPacketListenerImpl implements ServerCommonPack
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
// CraftBukkit end
|
||||||
|
- this.disconnect(ServerCommonPacketListenerImpl.DISCONNECT_UNEXPECTED_QUERY);
|
||||||
|
+ this.disconnect(ServerCommonPacketListenerImpl.DISCONNECT_UNEXPECTED_QUERY, org.bukkit.event.player.PlayerKickEvent.Cause.INVALID_COOKIE); // Paper - kick event cause
|
||||||
|
}
|
||||||
|
|
||||||
|
protected void keepConnectionAlive() {
|
||||||
|
@@ -0,0 +0,0 @@ public abstract class ServerCommonPacketListenerImpl implements ServerCommonPack
|
||||||
|
|
||||||
if (!this.isSingleplayerOwner() && elapsedTime >= KEEPALIVE_LIMIT) { // Paper - check keepalive limit, don't fire if already disconnected
|
if (!this.isSingleplayerOwner() && elapsedTime >= KEEPALIVE_LIMIT) { // Paper - check keepalive limit, don't fire if already disconnected
|
||||||
if (this.keepAlivePending && !this.processedDisconnect) { // Paper
|
if (this.keepAlivePending && !this.processedDisconnect) { // Paper
|
||||||
|
|
|
@ -68,6 +68,21 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
||||||
} else {
|
} else {
|
||||||
if (this.level().isClientSide || this.isSitting() || this.isInWater()) {
|
if (this.level().isClientSide || this.isSitting() || this.isInWater()) {
|
||||||
return InteractionResult.PASS;
|
return InteractionResult.PASS;
|
||||||
|
diff --git a/src/main/java/net/minecraft/world/entity/animal/armadillo/Armadillo.java b/src/main/java/net/minecraft/world/entity/animal/armadillo/Armadillo.java
|
||||||
|
index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644
|
||||||
|
--- a/src/main/java/net/minecraft/world/entity/animal/armadillo/Armadillo.java
|
||||||
|
+++ b/src/main/java/net/minecraft/world/entity/animal/armadillo/Armadillo.java
|
||||||
|
@@ -0,0 +0,0 @@ public class Armadillo extends Animal {
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
- public void setInLove(@Nullable Player player) {
|
||||||
|
- super.setInLove(player);
|
||||||
|
+ public void setInLove(@Nullable Player player, @Nullable ItemStack breedItemCopy) { // Paper
|
||||||
|
+ super.setInLove(player, breedItemCopy); // Paper
|
||||||
|
this.makeSound(SoundEvents.ARMADILLO_EAT);
|
||||||
|
}
|
||||||
|
|
||||||
diff --git a/src/main/java/net/minecraft/world/entity/animal/camel/Camel.java b/src/main/java/net/minecraft/world/entity/animal/camel/Camel.java
|
diff --git a/src/main/java/net/minecraft/world/entity/animal/camel/Camel.java b/src/main/java/net/minecraft/world/entity/animal/camel/Camel.java
|
||||||
index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644
|
index 0000000000000000000000000000000000000000..0000000000000000000000000000000000000000 100644
|
||||||
--- a/src/main/java/net/minecraft/world/entity/animal/camel/Camel.java
|
--- a/src/main/java/net/minecraft/world/entity/animal/camel/Camel.java
|
||||||
|
|
|
@ -471,11 +471,6 @@ index 0000000000000000000000000000000000000000..00000000000000000000000000000000
|
||||||
}
|
}
|
||||||
|
|
||||||
@@ -0,0 +0,0 @@ public class HopperBlockEntity extends RandomizableContainerBlockEntity implemen
|
@@ -0,0 +0,0 @@ public class HopperBlockEntity extends RandomizableContainerBlockEntity implemen
|
||||||
}
|
|
||||||
}
|
|
||||||
|
|
||||||
+ @io.papermc.paper.annotation.DoNotUse // Paper - Optimize hoppers
|
|
||||||
private static boolean tryTakeInItemFromSlot(Hopper ihopper, Container iinventory, int i, Direction enumdirection, Level world) { // Spigot
|
|
||||||
ItemStack itemstack = iinventory.getItem(i);
|
ItemStack itemstack = iinventory.getItem(i);
|
||||||
|
|
||||||
if (!itemstack.isEmpty() && HopperBlockEntity.canTakeItemFromContainer(ihopper, iinventory, itemstack, i, enumdirection)) {
|
if (!itemstack.isEmpty() && HopperBlockEntity.canTakeItemFromContainer(ihopper, iinventory, itemstack, i, enumdirection)) {
|
||||||
|
|
Loading…
Reference in a new issue