We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
1.21
OhMyMinecraftClient-mc1.21.1-fabric-0.6.362-pull_request.jar
从聊天中解析路径点无法点击高亮,使用O+P发送的坐标,无法点击高亮。开启强制解析也不能点击
使用O+P发送的坐标,发送的坐标无法高亮,手动在聊天框打出的坐标也无法高亮点击
No response
The text was updated successfully, but these errors were encountered:
Sorry, something went wrong.
我尝试clone代码并测试后 修复了解析路径点功能,代码如下: public void parseMessage(@NotNull Component chat) { chat.getSiblings().forEach(this::parseMessage);
//#if MC > 11802 ComponentContents //#else MC > 11502 //$$ BaseComponent //#endif contents = ComponentUtil.getTextContent((MutableComponent) chat); if ( //#if MC > 11802 !(contents instanceof TranslatableContents) //#else //$$ !(contents instanceof TranslatableComponent) //#endif ) { this.updateMessage(chat); return; } //#if MC > 11802 Object[] args = ((TranslatableContents) contents).getArgs(); //#else //$$ Object[] args = ((TranslatableComponent) contents).getArgs(); //#endif boolean updateTranslatableText = false; for (int i = 0; i < args.length; i++) { if (args[i] instanceof Component) { String string = ((Component) args[i]).getString(); if (string.startsWith("[")) { Component text = ComponentUtil.simple(string); if (this.updateMessage(text)) { args[i] = text; updateTranslatableText = true; } } else { this.parseMessage(ComponentUtil.simple(((Component) args[i]).getString())); } } else if (args[i] instanceof String) { Component text = ComponentUtil.simple(args[i]); if (this.updateMessage(text)) { args[i] = text; updateTranslatableText = true; } } } if (updateTranslatableText) { //#if MC > 11502 ((AccessorTranslatableComponent) contents).setDecomposedWith(null); //#else //$$ ((AccessorTranslatableComponent) contents).setDecomposedLanguageTime(-1); //#endif } this.updateMessage(chat); } 兼容代码写的针对性很强,希望对您有价值。
No branches or pull requests
Minecraft Version
1.21
OMMC Version
OhMyMinecraftClient-mc1.21.1-fabric-0.6.362-pull_request.jar
Description
从聊天中解析路径点无法点击高亮,使用O+P发送的坐标,无法点击高亮。开启强制解析也不能点击
To Reproduce
使用O+P发送的坐标,发送的坐标无法高亮,手动在聊天框打出的坐标也无法高亮点击
Expected behavior
No response
Log
No response
Latest CI build tested
The text was updated successfully, but these errors were encountered: