Fix tick timeout
This commit is contained in:
parent
c5feae6512
commit
dbdd6c9ac4
|
@ -49,13 +49,8 @@ public class ChatEventHandler {
|
|||
if (profanityScore > threshold && !PlayerConfigManager.hasAdultContentEnabled(receiver)) {
|
||||
continue;
|
||||
}
|
||||
|
||||
try (var senderLevel = sender.level(); var receiverLevel = receiver.level()) {
|
||||
if (isGlobal || (receiverLevel == senderLevel && receiver.position().distanceTo(sender.position()) <= 50)) {
|
||||
receiver.sendSystemMessage(chatComponent);
|
||||
}
|
||||
} catch (Exception e) {
|
||||
e.printStackTrace();
|
||||
if (isGlobal || (receiver.getCommandSenderWorld() == sender.getCommandSenderWorld() && receiver.position().distanceTo(sender.position()) <= 50)) {
|
||||
receiver.sendSystemMessage(chatComponent);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue