This commit is contained in:
2024-01-02 08:36:08 +02:00
parent 921ca9a7a7
commit c8094b050a

View File

@@ -23,7 +23,8 @@ public class PlayerListMixin {
@Inject(method = "broadcastSystemMessage(Lnet/minecraft/network/chat/Component;Ljava/util/function/Function;Z)V", at = @At("HEAD"))
private void injectBroadcastEvent(Component component, Function<ServerPlayer, Component> function, boolean bl, CallbackInfo ci) {
MessageBroadcastEvent event = new MessageBroadcastEvent(component, function, bl, threadName);
String thread = Thread.currentThread().getStackTrace()[3].getClassName();
MessageBroadcastEvent event = new MessageBroadcastEvent(component, function, bl, thread);
CraterEventBus.INSTANCE.postEvent(event);
}