Fix texture for Greenhouse. Thanks to LauchInterceptor

This commit is contained in:
Lorenz Voßgätter 2021-12-20 23:40:23 +01:00 committed by GitHub
parent 4e17a341c3
commit bdf906c4fc
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -24,6 +24,7 @@
package techreborn.client.gui; package techreborn.client.gui;
import com.mojang.blaze3d.systems.RenderSystem;
import net.minecraft.client.resource.language.I18n; import net.minecraft.client.resource.language.I18n;
import net.minecraft.client.util.math.MatrixStack; import net.minecraft.client.util.math.MatrixStack;
import net.minecraft.entity.player.PlayerEntity; import net.minecraft.entity.player.PlayerEntity;
@ -64,7 +65,7 @@ public class GuiGreenhouseController extends GuiBase<BuiltScreenHandler> {
drawSlot(matrixStack, 48, gridYPos + 36, layer); drawSlot(matrixStack, 48, gridYPos + 36, layer);
if (!blockEntity.isMultiblockValid()) { if (!blockEntity.isMultiblockValid()) {
getMinecraft().getTextureManager().bindTexture(new Identifier("techreborn", "textures/item/part/digital_display.png")); RenderSystem.setShaderTexture(0, new Identifier("techreborn", "textures/item/part/digital_display.png"));
drawTexture(matrixStack, x + 68, y + 22, 0, 0, 16, 16, 16, 16); drawTexture(matrixStack, x + 68, y + 22, 0, 0, 16, 16, 16, 16);
if (isPointInRect(68, 22, 16, 16, mouseX, mouseY)) { if (isPointInRect(68, 22, 16, 16, mouseX, mouseY)) {
List<Text> list = Arrays.stream(I18n.translate("techreborn.tooltip.greenhouse.upgrade_available") List<Text> list = Arrays.stream(I18n.translate("techreborn.tooltip.greenhouse.upgrade_available")