summaryrefslogtreecommitdiffstats
path: root/src/main/java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java')
-rw-r--r--src/main/java/com/aizistral/nochatreports/core/NoReportsConfig.java2
-rw-r--r--src/main/java/com/aizistral/nochatreports/mixins/client/MixinChatListener.java20
2 files changed, 7 insertions, 15 deletions
diff --git a/src/main/java/com/aizistral/nochatreports/core/NoReportsConfig.java b/src/main/java/com/aizistral/nochatreports/core/NoReportsConfig.java
index 20491e5..403b3ff 100644
--- a/src/main/java/com/aizistral/nochatreports/core/NoReportsConfig.java
+++ b/src/main/java/com/aizistral/nochatreports/core/NoReportsConfig.java
@@ -135,7 +135,7 @@ public class NoReportsConfig {
* do not feature signatures and look completely identical in the chat, with exception of gray line
* next to them added in pre-release 3. They are also unselectable for chat reporting.<br><br>
*
- * This is true by default.
+ * This is false by default.
*/
public static boolean convertToGameMessage() {
diff --git a/src/main/java/com/aizistral/nochatreports/mixins/client/MixinChatListener.java b/src/main/java/com/aizistral/nochatreports/mixins/client/MixinChatListener.java
index 274e67e..654d44a 100644
--- a/src/main/java/com/aizistral/nochatreports/mixins/client/MixinChatListener.java
+++ b/src/main/java/com/aizistral/nochatreports/mixins/client/MixinChatListener.java
@@ -44,8 +44,12 @@ public class MixinChatListener {
} else {
var evaluate = ChatTrustLevel.evaluate(playerChatMessage, component, playerInfo, instant);
- if ((evaluate == ChatTrustLevel.NOT_SECURE || evaluate == ChatTrustLevel.BROKEN_CHAIN)
- && NoReportsConfig.hideRedChatIndicators()) {
+ if (evaluate == ChatTrustLevel.BROKEN_CHAIN) {
+ info.setReturnValue(evaluate);
+ return;
+ }
+
+ if (evaluate == ChatTrustLevel.NOT_SECURE && NoReportsConfig.hideRedChatIndicators()) {
info.setReturnValue(ChatTrustLevel.SECURE);
} else if ((evaluate == ChatTrustLevel.FILTERED || evaluate == ChatTrustLevel.MODIFIED)
&& NoReportsConfig.hideYellowChatIndicators()) {
@@ -62,16 +66,4 @@ public class MixinChatListener {
}
}
- /**
- * @reason Prevent client from disconnecting when chat chain is broken.
- * Normal average user will not even understand what happened, so this is absolutely
- * useless for them.
- * @author Aizistral
- */
-
- @Inject(method = "onChatChainBroken", at = @At("HEAD"), cancellable = true)
- private void stopUselessDisconnects(CallbackInfo info) {
- info.cancel();
- }
-
}