diff options
author | HacktheTime <l4bg0jb7@duck.com> | 2023-07-16 16:03:30 +0200 |
---|---|---|
committer | hackthetime <l4bg0jb7@duck.com> | 2023-09-05 08:22:12 +0200 |
commit | 0e7fbeba43e9c88daecbe59a2f9408073b627faa (patch) | |
tree | 5a68364a7efa292b7e20ff8c8483df771637b660 /src/main/java/de/hype/bbsentials/client | |
parent | 94ef1e319dda7e1be4857297a0a9edbf8953346c (diff) | |
download | BBsentials-0e7fbeba43e9c88daecbe59a2f9408073b627faa.tar.gz BBsentials-0e7fbeba43e9c88daecbe59a2f9408073b627faa.tar.bz2 BBsentials-0e7fbeba43e9c88daecbe59a2f9408073b627faa.zip |
General
Diffstat (limited to 'src/main/java/de/hype/bbsentials/client')
-rw-r--r-- | src/main/java/de/hype/bbsentials/client/BBsentials.java | 1 | ||||
-rw-r--r-- | src/main/java/de/hype/bbsentials/client/RenderOverlay.java | 33 |
2 files changed, 1 insertions, 33 deletions
diff --git a/src/main/java/de/hype/bbsentials/client/BBsentials.java b/src/main/java/de/hype/bbsentials/client/BBsentials.java index 2317a18..e133d04 100644 --- a/src/main/java/de/hype/bbsentials/client/BBsentials.java +++ b/src/main/java/de/hype/bbsentials/client/BBsentials.java @@ -173,6 +173,7 @@ public class BBsentials implements ClientModInitializer { } public static void refreshCommands() { + Chat.sendPrivateMessageToSelf("Setting up commands"); coms = new CommandsOLD(); } diff --git a/src/main/java/de/hype/bbsentials/client/RenderOverlay.java b/src/main/java/de/hype/bbsentials/client/RenderOverlay.java deleted file mode 100644 index 6d6a070..0000000 --- a/src/main/java/de/hype/bbsentials/client/RenderOverlay.java +++ /dev/null @@ -1,33 +0,0 @@ -package de.hype.bbsentials.client; - -import net.fabricmc.fabric.api.client.rendering.v1.HudRenderCallback; -import net.minecraft.client.MinecraftClient; -import net.minecraft.client.gui.DrawContext; -import net.minecraft.client.gui.screen.ingame.GenericContainerScreen; -import net.minecraft.datafixer.fix.ItemNbtFix; -import net.minecraft.item.ItemStack; -import net.minecraft.nbt.NbtCompound; -import net.minecraft.text.Text; -import net.minecraft.util.collection.DefaultedList; - -public class RenderOverlay implements HudRenderCallback { - @Override - public void onHudRender(DrawContext drawContext, float tickDelta) { - // Check if the item is present in the GUI - if (BBsentials.bbserver.highlightItem()) { - MinecraftClient client = MinecraftClient.getInstance(); - if (client.currentScreen != null) { - if (client.currentScreen instanceof GenericContainerScreen && client.currentScreen.getTitle().getString().equals("SkyBlock Hub Selector")) { - GenericContainerScreen containerScreen = (GenericContainerScreen) client.currentScreen; - DefaultedList<ItemStack> items = containerScreen.getScreenHandler().getStacks(); - for (int i = 0; i < items.size(); i++) { - if (items.get(i).getName().getString().contains(BBsentials.bbserver.getItemName())) { - ItemStack found = items.get(i); - found.setCustomName(Text.literal("§r§6Splash Hub")); - } - } - } - } - } - } -}
\ No newline at end of file |