You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
With the latest Minecraft client, we can send texts in any RGB color, rather than the previous space of only 16.
Full color isn't supported by every viewer of our text -- commonly used console libraries convert to ANSI based on legacy color codes, and we target clients all the way back to MC 1.8.
When unsupported colors are passed to the legacy serializer, it fails locally with an exception.
When unsupported colors are sent to players, the color will be stripped entirely and players will see white text.
Users of the API could only avoid these issues by tracking the capabilities of every individual version they target, or by not using RGB at all.
I've added some API, currently on NamedTextColor, to find the nearest legacy color from any RGB color, but it is not yet used in any of the serializers. I'm also not entirely satisfied with the algorithm used -- it tends to favor the grays, as relatively "average" colors numerically.
How should the different serializers handle it?
The text was updated successfully, but these errors were encountered:
With the latest Minecraft client, we can send texts in any RGB color, rather than the previous space of only 16.
Full color isn't supported by every viewer of our text -- commonly used console libraries convert to ANSI based on legacy color codes, and we target clients all the way back to MC 1.8.
When unsupported colors are passed to the legacy serializer, it fails locally with an exception.
When unsupported colors are sent to players, the color will be stripped entirely and players will see white text.
Users of the API could only avoid these issues by tracking the capabilities of every individual version they target, or by not using RGB at all.
I've added some API, currently on NamedTextColor, to find the nearest legacy color from any RGB color, but it is not yet used in any of the serializers. I'm also not entirely satisfied with the algorithm used -- it tends to favor the grays, as relatively "average" colors numerically.
How should the different serializers handle it?
The text was updated successfully, but these errors were encountered: