This commit is contained in:
ThisIsALegitUsername 2023-04-05 09:47:57 -06:00
parent 080b939548
commit 6552390c0a
2 changed files with 35 additions and 3 deletions

View File

@ -45,6 +45,38 @@ public class RenderUtils {
}
}
public static void drawChromaRect(int zLevel, int x, int y, int width, int height) {
GlStateManager.pushMatrix();
GlStateManager.translate((float)x, (float)(y + height), (float)0.0f);
GlStateManager.rotate((float)-90.0f, (float)0.0f, (float)0.0f, (float)1.0f);
boolean p_drawGradientRect_1_ = false;
boolean p_drawGradientRect_2_ = false;
int p_drawGradientRect_5_ = Color.HSBtoRGB((float)((System.currentTimeMillis() - (long)x * 10L - (long)y * 10L) % 2000L) / 2000.0f, 0.8f, 0.8f);
int p_drawGradientRect_6_ = Color.HSBtoRGB((float)((System.currentTimeMillis() - (long)(x + width / 2) * 10L - (long)y * 10L) % 2000L) / 2000.0f, 0.8f, 0.8f);
float lvt_7_1_ = (float)(p_drawGradientRect_5_ >> 24 & 0xFF) / 255.0f;
float lvt_8_1_ = (float)(p_drawGradientRect_5_ >> 16 & 0xFF) / 255.0f;
float lvt_9_1_ = (float)(p_drawGradientRect_5_ >> 8 & 0xFF) / 255.0f;
float lvt_10_1_ = (float)(p_drawGradientRect_5_ & 0xFF) / 255.0f;
float lvt_11_1_ = (float)(p_drawGradientRect_6_ >> 24 & 0xFF) / 255.0f;
float lvt_12_1_ = (float)(p_drawGradientRect_6_ >> 16 & 0xFF) / 255.0f;
float lvt_13_1_ = (float)(p_drawGradientRect_6_ >> 8 & 0xFF) / 255.0f;
float lvt_14_1_ = (float)(p_drawGradientRect_6_ & 0xFF) / 255.0f;
GlStateManager.disableTexture2D();
GlStateManager.enableBlend();
GlStateManager.enableAlpha();
GlStateManager.tryBlendFuncSeparate((int)770, (int)771, (int)1, (int)0);
GlStateManager.shadeModel((int)7425);
Tessellator lvt_15_1_ = Tessellator.getInstance();
WorldRenderer lvt_16_1_ = lvt_15_1_.getWorldRenderer();
lvt_16_1_.begin(7, DefaultVertexFormats.POSITION_COLOR);
lvt_16_1_.pos((double)height, (double)width, (double)zLevel).color(lvt_12_1_, lvt_13_1_, lvt_14_1_, lvt_11_1_).endVertex();
lvt_15_1_.draw();
GlStateManager.shadeModel((int)7424);
GlStateManager.disableBlend();
GlStateManager.enableTexture2D();
GlStateManager.popMatrix();
}
public static int astolfoColorsDraw(float yOffset, int yTotal, float speed) {
float hue = (float) (System.currentTimeMillis() % (int) speed) + ((yTotal - yOffset) * 9);
while (hue > speed) {

View File

@ -125,7 +125,7 @@ public class ClickGuiRewrite extends GuiScreen {
//RenderUtils.drawRoundedRect(x+width-60, y+140+offset, x+width-40, y+160+offset, 4, -1);
//Toggle
RenderUtils.drawRoundedRect(x + 90, y + 125 + offset + scrollOffset, x + 140, y + 175 + offset + scrollOffset, 8, new Color(66, 66, 66).getRGB());
RenderUtils.drawRoundedRect(x + 90, y + 125 + offset + scrollOffset, x + 140, y + 175 + offset + scrollOffset, 8, m.isEnabled() ? onSurfaceColor : new Color(66, 66, 66).getRGB());
GlUtils.startScale(x + 90, y + 140 + offset + scrollOffset, 2);
fr.drawString(m.getName(), x + 120, y + 140 + offset + scrollOffset, -1, false);