This commit is contained in:
modmuss50 2019-06-04 12:05:18 +01:00
parent e8396dbc33
commit d18d1b820e
65 changed files with 287 additions and 520 deletions

View file

@ -49,7 +49,7 @@ public class GuiAlloyFurnace extends AbstractContainerScreen {
protected void drawBackground(final float p_146976_1_, final int p_146976_2_, final int p_146976_3_) {
this.drawDefaultBackground();
GlStateManager.color4f(1.0F, 1.0F, 1.0F, 1.0F);
this.mc.getTextureManager().bindTexture(GuiAlloyFurnace.texture);
this.minecraft.getTextureManager().bindTexture(GuiAlloyFurnace.texture);
final int k = (this.width - this.containerWidth) / 2;
final int l = (this.height - this.containerHeight) / 2;
this.blit(k, l, 0, 0, this.containerWidth, this.containerHeight);

View file

@ -24,6 +24,7 @@
package techreborn.client.gui;
import com.mojang.blaze3d.platform.GlStateManager;
import net.minecraft.client.renderer.GlStateManager;
import net.minecraft.entity.player.PlayerEntity;
import reborncore.client.gui.builder.GuiBase;

View file

@ -53,8 +53,8 @@ public class GuiChunkLoader extends AbstractContainerScreen {
}
@Override
public void initGui() {
super.initGui();
public void init() {
super.init();
this.left = this.width / 2 - this.containerWidth / 2;
this.top = this.height / 2 - this.containerHeight / 2;
this.plusOneButton = new GuiButtonSimple(0, this.left + 5, this.top + 37, 40, 20, "+1");
@ -73,7 +73,7 @@ public class GuiChunkLoader extends AbstractContainerScreen {
protected void drawBackground(final float p_146976_1_, final int p_146976_2_, final int p_146976_3_) {
this.drawDefaultBackground();
GlStateManager.color4f(1.0F, 1.0F, 1.0F, 1.0F);
this.mc.getTextureManager().bindTexture(GuiChunkLoader.texture);
minecraft.getTextureManager().bindTexture(GuiChunkLoader.texture);
final int k = (this.width - this.containerWidth) / 2;
final int l = (this.height - this.containerHeight) / 2;
this.blit(k, l, 0, 0, this.containerWidth, this.containerHeight);

View file

@ -24,6 +24,7 @@
package techreborn.client.gui;
import com.mojang.blaze3d.platform.GlStateManager;
import net.minecraft.block.BlockState;
import net.minecraft.client.renderer.GlStateManager;
import net.minecraft.entity.player.PlayerEntity;

View file

@ -57,8 +57,8 @@ public class GuiFluidReplicator extends GuiBase {
// GuiBase
@Override
public void initGui() {
super.initGui();
public void init() {
super.init();
ClientProxy.multiblockRenderEvent.setMultiblock(null);
}

View file

@ -100,8 +100,8 @@ public class GuiFusionReactor extends GuiBase {
}
}
builder.drawUpDownButtons(this, 121, 79, layer);
draw("Size: " + tile.size, 83, 81, 0xFFFFFF, layer);
draw("" + tile.getPowerMultiplier() + "x", 10, 81, 0xFFFFFF, layer);
drawString("Size: " + tile.size, 83, 81, 0xFFFFFF, layer);
drawString("" + tile.getPowerMultiplier() + "x", 10, 81, 0xFFFFFF, layer);
buttons.add(new GuiButtonUpDown(300, 121, 79, this, GuiBase.Layer.FOREGROUND));
buttons.add(new GuiButtonUpDown(301, 121 + 12, 79, this, GuiBase.Layer.FOREGROUND));

View file

@ -24,7 +24,7 @@
package techreborn.client.gui;
import net.minecraft.client.renderer.GlStateManager;
import com.mojang.blaze3d.platform.GlStateManager;
import net.minecraft.entity.player.PlayerEntity;
import reborncore.client.gui.builder.GuiBase;
import reborncore.common.powerSystem.PowerSystem;

View file

@ -49,8 +49,8 @@ public class GuiImplosionCompressor extends GuiBase {
}
@Override
public void initGui() {
super.initGui();
public void init() {
super.init();
ClientProxy.multiblockRenderEvent.setMultiblock(null);
}

View file

@ -49,8 +49,8 @@ public class GuiIndustrialGrinder extends GuiBase {
}
@Override
public void initGui() {
super.initGui();
public void init() {
super.init();
ClientProxy.multiblockRenderEvent.setMultiblock(null);
}

View file

@ -24,6 +24,7 @@
package techreborn.client.gui;
import com.mojang.blaze3d.platform.GlStateManager;
import net.minecraft.client.renderer.GlStateManager;
import net.minecraft.client.resource.language.I18n;
import net.minecraft.entity.player.PlayerEntity;
@ -52,7 +53,7 @@ public class GuiIronFurnace extends GuiBase {
drawDefaultBackground();
GlStateManager.color4f(1.0F, 1.0F, 1.0F, 1.0F);
builder.drawSlotTab(this, left - 24, top + 6, new ItemStack(TRContent.WRENCH));
mc.getTextureManager().bindTexture(GuiIronFurnace.texture);
minecraft.getTextureManager().bindTexture(GuiIronFurnace.texture);
final int k = (this.width - containerWidth) / 2;
final int l = (this.height - containerHeight) / 2;
blit(k, l, 0, 0, containerWidth, containerHeight);

View file

@ -25,7 +25,6 @@
package techreborn.client.gui;
import com.mojang.blaze3d.platform.GlStateManager;
import net.minecraft.client.renderer.GlStateManager;
import net.minecraft.entity.player.PlayerEntity;
import reborncore.client.gui.builder.GuiBase;
import reborncore.common.powerSystem.PowerSystem;

View file

@ -25,7 +25,6 @@
package techreborn.client.gui;
import com.mojang.blaze3d.platform.GlStateManager;
import net.minecraft.client.renderer.GlStateManager;
import net.minecraft.entity.player.PlayerEntity;
import reborncore.client.gui.builder.GuiBase;
import reborncore.common.powerSystem.PowerSystem;

View file

@ -24,19 +24,18 @@
package techreborn.client.gui;
import net.minecraft.client.gui.ingame.ConfirmChatLinkScreen;
import net.minecraft.client.gui.screen.ConfirmChatLinkScreen;
import net.minecraft.client.gui.screen.Screen;
import net.minecraft.client.resource.language.I18n;
import net.minecraft.entity.player.PlayerEntity;
import net.minecraft.util.Identifier;
import reborncore.client.gui.builder.widget.GuiButtonExtended;
import reborncore.common.network.NetworkManager;
import techreborn.items.ItemManual;
import techreborn.packets.ServerboundPackets;
import java.awt.*;
import net.minecraft.client.gui.Screen;
import net.minecraft.client.gui.ingame.ConfirmChatLinkScreen;
import net.minecraft.client.resource.language.I18n;
import net.minecraft.entity.player.PlayerEntity;
import net.minecraft.util.Identifier;
public class GuiManual extends Screen {
@ -61,7 +60,7 @@ public class GuiManual extends Screen {
}
@Override
public void initGui() {
public void init() {
int y = height / 4;
buttons.add(new GuiButtonExtended(1, (width / 2 - 30), y + 10, 60, 20, I18n.translate("techreborn.manual.wikibtn")));
buttons.add(new GuiButtonExtended(2, (width / 2 - 30), y + 60, 60, 20, I18n.translate("techreborn.manual.discordbtn")));
@ -73,7 +72,7 @@ public class GuiManual extends Screen {
@Override
public void render(int mouseX, int mouseY, float partialTicks) {
drawDefaultBackground();
mc.getTextureManager().bindTexture(GuiManual.texture);
minecraft.getTextureManager().bindTexture(GuiManual.texture);
int centerX = (width / 2) - guiWidth / 2;
int centerY = (height / 2) - guiHeight / 2;
blit(centerX, centerY, 0, 0, guiWidth, guiHeight);
@ -89,13 +88,13 @@ public class GuiManual extends Screen {
public void onClick(GuiButtonExtended button, Double mouseX, Double mouseY){
switch (button.id) {
case 1:
mc.displayGuiScreen(new ConfirmChatLinkScreen(this, "http://wiki.techreborn.ovh", 1, false));
minecraft.openScreen(new ConfirmChatLinkScreen(this, "http://wiki.techreborn.ovh", 1, false));
break;
case 2:
this.mc.displayGuiScreen(new ConfirmChatLinkScreen(this, "https://discord.gg/teamreborn", 2, false));
this.minecraft.openScreen(new ConfirmChatLinkScreen(this, "https://discord.gg/teamreborn", 2, false));
break;
case 3:
mc.displayGuiScreen(null);
minecraft.openScreen(null);
NetworkManager.sendToServer(ServerboundPackets.createRefundPacket());
break;
}
@ -112,7 +111,7 @@ public class GuiManual extends Screen {
System.err.print(e);
}
}else {
mc.displayGuiScreen(this);
minecraft.openScreen(this);
}
break;
case 2:
@ -123,7 +122,7 @@ public class GuiManual extends Screen {
System.err.print(e);
}
}else {
mc.displayGuiScreen(this);
minecraft.openScreen(this);
}
break;
}

View file

@ -47,8 +47,8 @@ public class GuiVacuumFreezer extends GuiBase {
}
@Override
public void initGui() {
super.initGui();
public void init() {
super.init();
ClientProxy.multiblockRenderEvent.setMultiblock(null);
}