Mirror von
https://github.com/ViaVersion/ViaVersion.git
synchronisiert 2024-12-27 00:22:51 +01:00
Remove Protocol1_9To1_8#FIX_JSON usage in 1.11->1.12 (#3791)
Dieser Commit ist enthalten in:
Ursprung
98c5d38d0c
Commit
4302dd61aa
@ -100,11 +100,11 @@ public class Protocol1_12To1_11_1 extends AbstractProtocol<ClientboundPackets1_9
|
||||
registerClientbound(ClientboundPackets1_9_3.CHAT_MESSAGE, wrapper -> {
|
||||
if (!Via.getConfig().is1_12NBTArrayFix()) return;
|
||||
try {
|
||||
JsonElement obj = Protocol1_9To1_8.FIX_JSON.transform(null, wrapper.passthrough(Type.COMPONENT).toString());
|
||||
TranslateRewriter.toClient(obj);
|
||||
ChatItemRewriter.toClient(obj);
|
||||
final JsonElement element = wrapper.passthrough(Type.COMPONENT);
|
||||
TranslateRewriter.toClient(element);
|
||||
ChatItemRewriter.toClient(element);
|
||||
|
||||
wrapper.set(Type.COMPONENT, 0, obj);
|
||||
wrapper.set(Type.COMPONENT, 0, element);
|
||||
} catch (Exception e) {
|
||||
Via.getPlatform().getLogger().log(Level.WARNING, "Error converting 1.11.2 -> 1.12 chat item", e);
|
||||
}
|
||||
|
Laden…
In neuem Issue referenzieren
Einen Benutzer sperren