summaryrefslogtreecommitdiff
path: root/src/main/java
diff options
context:
space:
mode:
author alemi <me@alemi.dev>2023-02-15 21:44:29 +0100
committer alemi <me@alemi.dev>2023-02-15 21:44:29 +0100
commita7664f8485ef026e680cc9ae6c4a950a378fee97 (patch)
treeafbbbc09dca56a6b3131f9c98958e7f170ee8ec4 /src/main/java
parentcaf64a44f20a5d7f59b85146c8fdffdc4823724c (diff)
feat: don't bloat chat with toggle events
Diffstat (limited to 'src/main/java')
-rw-r--r--src/main/java/ftbsc/bscv/BoSCoVicino.java5
-rw-r--r--src/main/java/ftbsc/bscv/modules/Module.java2
2 files changed, 4 insertions, 3 deletions
diff --git a/src/main/java/ftbsc/bscv/BoSCoVicino.java b/src/main/java/ftbsc/bscv/BoSCoVicino.java
index c533bf5..4f4c108 100644
--- a/src/main/java/ftbsc/bscv/BoSCoVicino.java
+++ b/src/main/java/ftbsc/bscv/BoSCoVicino.java
@@ -75,7 +75,10 @@ public class BoSCoVicino implements ICommons {
}
public static void log(String message) {
- MC.gui.getChat().addMessage(new StringTextComponent(message));
+ LOGGER.info(message);
+ if (MC.player != null) {
+ MC.player.displayClientMessage(new StringTextComponent(message), true);
+ }
}
private void clientSetup(final FMLClientSetupEvent event) {
diff --git a/src/main/java/ftbsc/bscv/modules/Module.java b/src/main/java/ftbsc/bscv/modules/Module.java
index e0ae606..d2c5598 100644
--- a/src/main/java/ftbsc/bscv/modules/Module.java
+++ b/src/main/java/ftbsc/bscv/modules/Module.java
@@ -145,7 +145,6 @@ public abstract class Module {
// this.enabled.save();
this.onEnabled();
log(String.format("%s enabled", this.name));
- BoSCoVicino.LOGGER.info(String.format("%s enabled", this.name));
}
public final void disable() {
@@ -154,6 +153,5 @@ public abstract class Module {
// this.enabled.save();
this.onDisabled();
log(String.format("%s disabled", this.name));
- BoSCoVicino.LOGGER.info(String.format("%s disabled", this.name));
}
}