Mirror von
https://github.com/PaperMC/Velocity.git
synchronisiert 2024-11-17 05:20:14 +01:00
GS4 clients generally don't understand MC color codes (or JSON chat).
Dieser Commit ist enthalten in:
Ursprung
b5fcc1b34a
Commit
09eff5a2fb
@ -10,6 +10,7 @@ import io.netty.buffer.ByteBuf;
|
|||||||
import io.netty.channel.ChannelHandlerContext;
|
import io.netty.channel.ChannelHandlerContext;
|
||||||
import io.netty.channel.SimpleChannelInboundHandler;
|
import io.netty.channel.SimpleChannelInboundHandler;
|
||||||
import io.netty.channel.socket.DatagramPacket;
|
import io.netty.channel.socket.DatagramPacket;
|
||||||
|
import net.kyori.text.serializer.ComponentSerializers;
|
||||||
import org.apache.logging.log4j.LogManager;
|
import org.apache.logging.log4j.LogManager;
|
||||||
import org.apache.logging.log4j.Logger;
|
import org.apache.logging.log4j.Logger;
|
||||||
|
|
||||||
@ -100,7 +101,7 @@ public class GS4QueryHandler extends SimpleChannelInboundHandler<DatagramPacket>
|
|||||||
|
|
||||||
// Start writing the response
|
// Start writing the response
|
||||||
ResponseWriter responseWriter = new ResponseWriter(queryResponse, queryMessage.readableBytes() == 0);
|
ResponseWriter responseWriter = new ResponseWriter(queryResponse, queryMessage.readableBytes() == 0);
|
||||||
responseWriter.write("hostname", server.getConfiguration().getMotd());
|
responseWriter.write("hostname", ComponentSerializers.PLAIN.serialize(server.getConfiguration().getMotdComponent()));
|
||||||
responseWriter.write("gametype", "SMP");
|
responseWriter.write("gametype", "SMP");
|
||||||
|
|
||||||
responseWriter.write("game_id", "MINECRAFT");
|
responseWriter.write("game_id", "MINECRAFT");
|
||||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren