aboutsummaryrefslogtreecommitdiff
path: root/src/main/java/me/shedaniel/rei/gui/widget/AutoCraftingButtonWidget.java
diff options
context:
space:
mode:
Diffstat (limited to 'src/main/java/me/shedaniel/rei/gui/widget/AutoCraftingButtonWidget.java')
-rw-r--r--src/main/java/me/shedaniel/rei/gui/widget/AutoCraftingButtonWidget.java10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/main/java/me/shedaniel/rei/gui/widget/AutoCraftingButtonWidget.java b/src/main/java/me/shedaniel/rei/gui/widget/AutoCraftingButtonWidget.java
index 6430708cb..9c080455a 100644
--- a/src/main/java/me/shedaniel/rei/gui/widget/AutoCraftingButtonWidget.java
+++ b/src/main/java/me/shedaniel/rei/gui/widget/AutoCraftingButtonWidget.java
@@ -5,10 +5,10 @@
package me.shedaniel.rei.gui.widget;
-import com.mojang.blaze3d.platform.GlStateManager;
import it.unimi.dsi.fastutil.ints.IntList;
import me.shedaniel.math.api.Point;
import me.shedaniel.math.api.Rectangle;
+import me.shedaniel.math.compat.RenderHelper;
import me.shedaniel.rei.api.*;
import me.shedaniel.rei.impl.ScreenHelper;
import net.minecraft.client.gui.screen.ingame.AbstractContainerScreen;
@@ -94,11 +94,11 @@ public class AutoCraftingButtonWidget extends ButtonWidget {
errorTooltip = error;
int x = getBounds().x, y = getBounds().y, width = getBounds().width, height = getBounds().height;
minecraft.getTextureManager().bindTexture(ScreenHelper.isDarkModeEnabled() ? BUTTON_LOCATION_DARK : BUTTON_LOCATION);
- GlStateManager.color4f(1.0F, 1.0F, 1.0F, 1.0F);
+ RenderHelper.color4f(1.0F, 1.0F, 1.0F, 1.0F);
int textureOffset = this.getTextureId(isHovered(mouseX, mouseY));
- GlStateManager.enableBlend();
- GlStateManager.blendFuncSeparate(GlStateManager.SourceFactor.SRC_ALPHA, GlStateManager.DestFactor.ONE_MINUS_SRC_ALPHA, GlStateManager.SourceFactor.ONE, GlStateManager.DestFactor.ZERO);
- GlStateManager.blendFunc(GlStateManager.SourceFactor.SRC_ALPHA, GlStateManager.DestFactor.ONE_MINUS_SRC_ALPHA);
+ RenderHelper.enableBlend();
+ RenderHelper.blendFuncSeparate(770, 771, 1, 0);
+ RenderHelper.blendFunc(770, 771);
//Four Corners
blit(x, y, 0, textureOffset * 80, 4, 4);
blit(x + width - 4, y, 252, textureOffset * 80, 4, 4);