From b355e1b4ee3a054d7847b8484b72e71c4f6032d4 Mon Sep 17 00:00:00 2001 From: tanishisherewithhh <120117618+tanishisherewithhh@users.noreply.github.com> Date: Sun, 28 Apr 2024 15:00:25 +0530 Subject: [PATCH] bad dependency --- .github/workflows/gradle.yml | 4 +-- .../dynamichud/helpers/ColorHelper.java | 27 +++++++++++++++++++ .../dynamichud/helpers/TextureHelper.java | 3 +++ .../dynamichud/mixins/ScreenMixin.java | 2 +- .../dynamichud/widgets/ItemWidget.java | 3 +++ 5 files changed, 36 insertions(+), 3 deletions(-) diff --git a/.github/workflows/gradle.yml b/.github/workflows/gradle.yml index ddb689e..d1a6ef1 100644 --- a/.github/workflows/gradle.yml +++ b/.github/workflows/gradle.yml @@ -47,14 +47,14 @@ jobs: name: Dynamichud path: build/libs/ - - name: pre-release tag + - name: pre-release action uses: softprops/action-gh-release@v2 with: tag_name: "latest" name: "DynamicHUD Pre-release" prerelease: true body: - "Pre-release generated from github actions. Maybe unstable to use." + "Pre-release generated from github actions on push commit. Maybe unstable to use." fail_on_unmatched_files: true generate_release_notes: true files: | diff --git a/src/main/java/com/tanishisherewith/dynamichud/helpers/ColorHelper.java b/src/main/java/com/tanishisherewith/dynamichud/helpers/ColorHelper.java index b119142..04c9c19 100644 --- a/src/main/java/com/tanishisherewith/dynamichud/helpers/ColorHelper.java +++ b/src/main/java/com/tanishisherewith/dynamichud/helpers/ColorHelper.java @@ -8,6 +8,33 @@ * This class provides helper methods for working with colors. */ public class ColorHelper { + + //Aliases for chat formatting from heliosclient + public static String colorChar = "\247"; + public static String black = "\2470"; + public static String darkBlue = "\2471"; + public static String darkGreen = "\2472"; + public static String darkAqua = "\2473"; + public static String darkRed = "\2474"; + public static String darkMagenta = "\2475"; + public static String gold = "\2476"; + public static String gray = "\2477"; + public static String darkGray = "\2478"; + public static String blue = "\2479"; + public static String green = "\247a"; + public static String aqua = "\247b"; + public static String red = "\247c"; + public static String magenta = "\247d"; + public static String yellow = "\247e"; + public static String white = "\247f"; + + public static String underline = "\247n"; + public static String bold = "\247l"; + public static String italic = "\247o"; + public static String strikethrough = "\247m"; + public static String obfuscated = "\247k"; + public static String reset = "\247r"; + public static int r, g, b, a; public ColorHelper(int r, int g, int b) { diff --git a/src/main/java/com/tanishisherewith/dynamichud/helpers/TextureHelper.java b/src/main/java/com/tanishisherewith/dynamichud/helpers/TextureHelper.java index 5301aaa..5895241 100644 --- a/src/main/java/com/tanishisherewith/dynamichud/helpers/TextureHelper.java +++ b/src/main/java/com/tanishisherewith/dynamichud/helpers/TextureHelper.java @@ -7,6 +7,9 @@ import java.io.IOException; import java.io.InputStream; +/** + * This class is entirely untested so some issues may occur which in case should be reported immediately. + */ public class TextureHelper { static MinecraftClient mc = MinecraftClient.getInstance(); diff --git a/src/main/java/com/tanishisherewith/dynamichud/mixins/ScreenMixin.java b/src/main/java/com/tanishisherewith/dynamichud/mixins/ScreenMixin.java index 1ce36e5..49462af 100644 --- a/src/main/java/com/tanishisherewith/dynamichud/mixins/ScreenMixin.java +++ b/src/main/java/com/tanishisherewith/dynamichud/mixins/ScreenMixin.java @@ -20,7 +20,7 @@ public abstract class ScreenMixin { @Shadow public int height; - @Inject(at = @At("TAIL"), method = "render") + @Inject(at = @At("RETURN"), method = "render") private void render(DrawContext context, int mouseX, int mouseY, float delta, CallbackInfo ci) { for (WidgetRenderer widgetRenderer : DynamicHUD.getWidgetRenderers()) { widgetRenderer.renderWidgets(context, mouseX, mouseY); diff --git a/src/main/java/com/tanishisherewith/dynamichud/widgets/ItemWidget.java b/src/main/java/com/tanishisherewith/dynamichud/widgets/ItemWidget.java index 002e9c8..deb1571 100644 --- a/src/main/java/com/tanishisherewith/dynamichud/widgets/ItemWidget.java +++ b/src/main/java/com/tanishisherewith/dynamichud/widgets/ItemWidget.java @@ -8,6 +8,9 @@ import net.minecraft.item.ItemStack; import net.minecraft.nbt.NbtCompound; +/** + * This is just an example widget, not supposed to be used. + */ public class ItemWidget extends Widget { public static WidgetData DATA = new WidgetData<>("ItemWidget","Displays item texture", ItemWidget::new); public ItemStack item;