Mirror von
https://github.com/PaperMC/Paper.git
synchronisiert 2024-11-15 12:30:06 +01:00
29 Zeilen
2.0 KiB
Diff
29 Zeilen
2.0 KiB
Diff
From 0000000000000000000000000000000000000000 Mon Sep 17 00:00:00 2001
|
|
From: kashike <kashike@vq.lc>
|
|
Date: Tue, 20 Sep 2016 00:58:01 +0000
|
|
Subject: [PATCH] Configurable flying kick messages
|
|
|
|
|
|
diff --git a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
|
index d3d141d18d9e66bc04e4c1af38b44bdd41e8d416..aea8d2376e88a327985f7f5d34e355cd9090941e 100644
|
|
--- a/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
|
+++ b/src/main/java/net/minecraft/server/network/ServerGamePacketListenerImpl.java
|
|
@@ -355,7 +355,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
|
|
if (this.clientIsFloating && !this.player.isSleeping() && !this.player.isPassenger()) {
|
|
if (++this.aboveGroundTickCount > 80) {
|
|
ServerGamePacketListenerImpl.LOGGER.warn("{} was kicked for floating too long!", this.player.getName().getString());
|
|
- this.disconnect(Component.translatable("multiplayer.disconnect.flying"));
|
|
+ this.disconnect(io.papermc.paper.configuration.GlobalConfiguration.get().messages.kick.flyingPlayer); // Paper - use configurable kick message
|
|
return;
|
|
}
|
|
} else {
|
|
@@ -374,7 +374,7 @@ public class ServerGamePacketListenerImpl implements ServerPlayerConnection, Tic
|
|
if (this.clientVehicleIsFloating && this.player.getRootVehicle().getControllingPassenger() == this.player) {
|
|
if (++this.aboveGroundVehicleTickCount > 80) {
|
|
ServerGamePacketListenerImpl.LOGGER.warn("{} was kicked for floating a vehicle too long!", this.player.getName().getString());
|
|
- this.disconnect(Component.translatable("multiplayer.disconnect.flying"));
|
|
+ this.disconnect(io.papermc.paper.configuration.GlobalConfiguration.get().messages.kick.flyingVehicle); // Paper - use configurable kick message
|
|
return;
|
|
}
|
|
} else {
|