mirror of
https://github.com/MCCTeam/Minecraft-Console-Client
synced 2025-10-14 21:22:49 +00:00
Fixed a NBT crash < 1.20.2 and Fixed a crash with parsing 'extra' section in Chat
This commit is contained in:
parent
6d016332fb
commit
35cfd4a7db
2 changed files with 5 additions and 8 deletions
|
|
@ -452,7 +452,10 @@ namespace MinecraftClient.Protocol.Message
|
|||
object[] extras = (object[])value;
|
||||
for (int i = 0; i < extras.Length; i++)
|
||||
{
|
||||
var extraDict = (Dictionary<string, object>)extras[i];
|
||||
var extraDict = extras[i] is string
|
||||
? new Dictionary<string, object>() { { "text", (string)extras[i] } }
|
||||
: (Dictionary<string, object>)extras[i];
|
||||
|
||||
extraBuilder.Append(NbtToString(extraDict) + "§r");
|
||||
}
|
||||
}
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue