From 4dad5fc27145593c14425b3e673b924155903585 Mon Sep 17 00:00:00 2001 From: Keuin Date: Mon, 28 Dec 2020 22:53:31 +0800 Subject: Version 1.3.0: add switches for all disable features. Fixed the vanilla bug that the entity trackers sometimes spam in the console. --- .../mixin/DisableEntityTrackerEntrySpamming.java | 19 +++++++++++++++++++ 1 file changed, 19 insertions(+) create mode 100644 src/main/java/com/keuin/ohmyvanillamc/mixin/DisableEntityTrackerEntrySpamming.java (limited to 'src/main/java/com/keuin/ohmyvanillamc/mixin/DisableEntityTrackerEntrySpamming.java') diff --git a/src/main/java/com/keuin/ohmyvanillamc/mixin/DisableEntityTrackerEntrySpamming.java b/src/main/java/com/keuin/ohmyvanillamc/mixin/DisableEntityTrackerEntrySpamming.java new file mode 100644 index 0000000..523aeed --- /dev/null +++ b/src/main/java/com/keuin/ohmyvanillamc/mixin/DisableEntityTrackerEntrySpamming.java @@ -0,0 +1,19 @@ +package com.keuin.ohmyvanillamc.mixin; + +import com.keuin.ohmyvanillamc.DummyLogger; +import net.minecraft.server.network.EntityTrackerEntry; +import org.apache.logging.log4j.Logger; +import org.spongepowered.asm.mixin.Mixin; +import org.spongepowered.asm.mixin.gen.Accessor; + +@Mixin(EntityTrackerEntry.class) +public class DisableEntityTrackerEntrySpamming { + + private static final Logger DUMMY_LOGGER = new DummyLogger(); + + @Accessor("LOGGER") + private static Logger LOGGER() { + return DUMMY_LOGGER; + } + +} -- cgit v1.2.3