Fix plugin cmd list displayed in Action Bar instead of the chat 1.19.3+

The boolean flag determines 'whether the message is an actionbar or chat message'.
We want to have it set to `false` here.

Reference:
https://wiki.vg/index.php?title=Protocol&oldid=18120#System_Chat_Message
This commit is contained in:
Christian Koop 2023-04-29 11:56:04 +02:00
parent 7a7d2e8b97
commit 06761c001c
No known key found for this signature in database
GPG Key ID: 89A8181384E010A3

View File

@ -227,7 +227,7 @@ public class ChatMessage {
Object packet;
if (ServerVersion.isServerVersionAtLeast(ServerVersion.V1_19)) {
packet = mc_PacketPlayOutChat_new.newInstance(mc_IChatBaseComponent_ChatSerializer_a.invoke(null, gson.toJson(textList)), mc_PacketPlayOutChat_new_1_19_0 ? 1 : true);
packet = mc_PacketPlayOutChat_new.newInstance(mc_IChatBaseComponent_ChatSerializer_a.invoke(null, gson.toJson(textList)), mc_PacketPlayOutChat_new_1_19_0 ? 1 : false);
}else if (ServerVersion.isServerVersionAtLeast(ServerVersion.V1_16)) {
packet = mc_PacketPlayOutChat_new.newInstance(
mc_IChatBaseComponent_ChatSerializer_a.invoke(null, gson.toJson(textList)),