From 2d713a68e8d25fbe983648b99604d57bb5552a3c Mon Sep 17 00:00:00 2001 From: Jess Date: Sun, 6 Oct 2024 06:52:27 +0100 Subject: [PATCH] add killbind --- .../java/de/com/baseband/client/Setup.java | 1 + .../feature/modules/ingame/KillBind.java | 29 +++++++++++++++++++ 2 files changed, 30 insertions(+) create mode 100644 Client/src/main/java/de/com/baseband/client/feature/modules/ingame/KillBind.java diff --git a/Client/src/main/java/de/com/baseband/client/Setup.java b/Client/src/main/java/de/com/baseband/client/Setup.java index dee182e..8e58ca9 100644 --- a/Client/src/main/java/de/com/baseband/client/Setup.java +++ b/Client/src/main/java/de/com/baseband/client/Setup.java @@ -63,6 +63,7 @@ public class Setup { new InteractionTweaks.FastBreak(), new InteractionTweaks.FastUse(), new Inventory(), + new KillBind(), new MidClick(), new Nametags(), new NoFall(), diff --git a/Client/src/main/java/de/com/baseband/client/feature/modules/ingame/KillBind.java b/Client/src/main/java/de/com/baseband/client/feature/modules/ingame/KillBind.java new file mode 100644 index 0000000..aa59150 --- /dev/null +++ b/Client/src/main/java/de/com/baseband/client/feature/modules/ingame/KillBind.java @@ -0,0 +1,29 @@ +package de.com.baseband.client.feature.modules.ingame; + +import de.com.baseband.client.event.Listen; +import de.com.baseband.client.event.events.PlayerDestroyEvent; +import de.com.baseband.client.feature.Feature; +import de.com.baseband.client.feature.category.Ingame; +import de.com.baseband.client.util.interact.Chat; + +@Ingame +public class KillBind extends Feature { + @Override + public String toString() { + return "KillBind"; + } + + + @Override + public void onEnable() { + if(!notIngame()) { + Chat.simulateSend("/kill", false); + } + this.setEnabledSilent(false); + } + + @Listen + public void onPlayerDestroy(PlayerDestroyEvent event) { + this.setEnabledSilent(false); + } +}