lighting fix

This commit is contained in:
Bob 2024-05-20 21:58:58 +02:00
parent f39b5a0e2c
commit 39a855afdd
2 changed files with 4 additions and 1 deletions

View File

@ -14,3 +14,4 @@
* Fixed armor mods adding health showing only half as much as they actually do
* Fixed RBMK fuel xenon burn function being described wrong
* When converting ComparableStacks to ItemStacks, there is now a check that replaces null items with the nothing placeholder, fixing crashes caused by incorrect recipe configuration
* Fixed item icon lighting in the anvil's search field

View File

@ -7,6 +7,7 @@ import java.util.Locale;
import org.lwjgl.input.Keyboard;
import org.lwjgl.input.Mouse;
import org.lwjgl.opengl.GL11;
import org.lwjgl.opengl.GL12;
import com.hbm.inventory.RecipesCommon.AStack;
import com.hbm.inventory.RecipesCommon.ComparableStack;
@ -427,6 +428,7 @@ public class GUIAnvil extends GuiContainer {
GL11.glColor4f(1.0F, 1.0F, 1.0F, 1.0F);
RenderHelper.enableGUIStandardItemLighting();
GL11.glDisable(GL11.GL_LIGHTING);
GL11.glEnable(GL12.GL_RESCALE_NORMAL);
AnvilConstructionRecipe recipe = recipes.get(i);
ItemStack display = recipe.getDisplay();
@ -438,7 +440,7 @@ public class GUIAnvil extends GuiContainer {
itemRender.zLevel = 100.0F;
itemRender.renderItemAndEffectIntoGUI(font, this.mc.getTextureManager(), recipe.getDisplay(), guiLeft + 17 + 18 * (ind / 2), guiTop + 72 + 18 * (ind % 2));
itemRender.zLevel = 0.0F;
GL11.glEnable(GL11.GL_ALPHA_TEST);
GL11.glDisable(GL11.GL_LIGHTING);
this.mc.getTextureManager().bindTexture(texture);