Mirror von
https://github.com/ViaVersion/ViaVersion.git
synchronisiert 2024-12-25 15:50:10 +01:00
Merge pull request #18 from StamBoom/master
Fix MalformedJsonException when opening renamed containers
Dieser Commit ist enthalten in:
Commit
e43968c142
@ -263,6 +263,20 @@ public class OutgoingTransformer {
|
||||
|
||||
return;
|
||||
}
|
||||
if (packet == PacketType.PLAY_OPEN_WINDOW){
|
||||
int windowId = input.readUnsignedByte();
|
||||
String type = readString(input);
|
||||
String windowTitle = readString(input);
|
||||
|
||||
if (windowTitle.startsWith("\""))
|
||||
windowTitle = "{\"text\":" + windowTitle + "}";;
|
||||
|
||||
output.writeByte(windowId);
|
||||
writeString(type,output);
|
||||
writeString(windowTitle,output);
|
||||
output.writeBytes(input);
|
||||
return;
|
||||
}
|
||||
if (packet == PacketType.PLAY_SPAWN_MOB) {
|
||||
int id = PacketUtil.readVarInt(input);
|
||||
PacketUtil.writeVarInt(id, output);
|
||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren