13
0
geforkt von Mirrors/Velocity

Fix compile error caused by adventure changes

Dieser Commit ist enthalten in:
Andrew Steinborn 2020-07-16 11:50:48 -04:00
Ursprung 72ce5c86ba
Commit 2296a9d8dd
3 geänderte Dateien mit 5 neuen und 4 gelöschten Zeilen

Datei anzeigen

@ -108,7 +108,7 @@ public interface ResultedEvent<R extends ResultedEvent.Result> {
return "allowed";
}
if (reason != null) {
return "denied: " + PlainComponentSerializer.INSTANCE.serialize(reason);
return "denied: " + PlainComponentSerializer.plain().serialize(reason);
}
return "denied";
}

Datei anzeigen

@ -72,7 +72,7 @@ public class GS4QueryHandler extends SimpleChannelInboundHandler<DatagramPacket>
private QueryResponse createInitialResponse() {
return QueryResponse.builder()
.hostname(PlainComponentSerializer.INSTANCE.serialize(server.getConfiguration().getMotd()))
.hostname(PlainComponentSerializer.plain().serialize(server.getConfiguration().getMotd()))
.gameVersion(ProtocolVersion.SUPPORTED_VERSION_STRING)
.map(server.getConfiguration().getQueryMap())
.currentPlayers(server.getPlayerCount())

Datei anzeigen

@ -12,7 +12,8 @@ public class LegacyDisconnect {
private static final ServerPing.Players FAKE_PLAYERS = new ServerPing.Players(0, 0,
ImmutableList.of());
private static final String LEGACY_COLOR_CODE = "\u00a7";
private static final String LEGACY_COLOR_CODE = Character
.toString(LegacyComponentSerializer.SECTION_CHAR);
private final String reason;
@ -36,7 +37,7 @@ public class LegacyDisconnect {
// remove all section symbols, along with fetching just the first line of an (unformatted)
// MOTD.
return new LegacyDisconnect(String.join(LEGACY_COLOR_CODE,
cleanSectionSymbol(getFirstLine(PlainComponentSerializer.INSTANCE.serialize(
cleanSectionSymbol(getFirstLine(PlainComponentSerializer.plain().serialize(
response.getDescriptionComponent()))),
Integer.toString(players.getOnline()),
Integer.toString(players.getMax())));