Merge pull request #3027 from TheVitya2127/zoyus

New Soyuz GUI
This commit is contained in:
HbmMods 2026-07-23 13:10:50 +02:00 committed by GitHub
commit cd4bf86618
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194
23 changed files with 127 additions and 115 deletions

View File

@ -17,21 +17,21 @@ public class ContainerMachineKeyForge extends Container {
diFurnace = tedf; diFurnace = tedf;
this.addSlotToContainer(new Slot(tedf, 0, 44, 35)); this.addSlotToContainer(new Slot(tedf, 0, 44, 36));
this.addSlotToContainer(new Slot(tedf, 1, 80, 35)); this.addSlotToContainer(new Slot(tedf, 1, 80, 36));
this.addSlotToContainer(new Slot(tedf, 2, 116, 35)); this.addSlotToContainer(new Slot(tedf, 2, 116, 36));
for(int i = 0; i < 3; i++) for(int i = 0; i < 3; i++)
{ {
for(int j = 0; j < 9; j++) for(int j = 0; j < 9; j++)
{ {
this.addSlotToContainer(new Slot(invPlayer, j + i * 9 + 9, 8 + j * 18, 84 + i * 18)); this.addSlotToContainer(new Slot(invPlayer, j + i * 9 + 9, 8 + j * 18, 104 + i * 18));
} }
} }
for(int i = 0; i < 9; i++) for(int i = 0; i < 9; i++)
{ {
this.addSlotToContainer(new Slot(invPlayer, i, 8 + i * 18, 142)); this.addSlotToContainer(new Slot(invPlayer, i, 8 + i * 18, 162));
} }
} }

View File

@ -17,21 +17,21 @@ public class ContainerMachineSatLinker extends Container {
diFurnace = tedf; diFurnace = tedf;
this.addSlotToContainer(new Slot(tedf, 0, 44, 35)); this.addSlotToContainer(new Slot(tedf, 0, 44, 36));
this.addSlotToContainer(new Slot(tedf, 1, 80, 35)); this.addSlotToContainer(new Slot(tedf, 1, 80, 36));
this.addSlotToContainer(new Slot(tedf, 2, 116, 35)); this.addSlotToContainer(new Slot(tedf, 2, 116, 36));
for(int i = 0; i < 3; i++) for(int i = 0; i < 3; i++)
{ {
for(int j = 0; j < 9; j++) for(int j = 0; j < 9; j++)
{ {
this.addSlotToContainer(new Slot(invPlayer, j + i * 9 + 9, 8 + j * 18, 84 + i * 18)); this.addSlotToContainer(new Slot(invPlayer, j + i * 9 + 9, 8 + j * 18, 104 + i * 18));
} }
} }
for(int i = 0; i < 9; i++) for(int i = 0; i < 9; i++)
{ {
this.addSlotToContainer(new Slot(invPlayer, i, 8 + i * 18, 142)); this.addSlotToContainer(new Slot(invPlayer, i, 8 + i * 18, 162));
} }
} }

View File

@ -18,23 +18,23 @@ public class ContainerSatDock extends Container {
tileSatelliteDock = tesd; tileSatelliteDock = tesd;
//Storage //Storage
this.addSlotToContainer(new SlotTakeOnly(tesd, 0, 62, 17)); this.addSlotToContainer(new SlotTakeOnly(tesd, 0, 71, 18));
this.addSlotToContainer(new SlotTakeOnly(tesd, 1, 80, 17)); this.addSlotToContainer(new SlotTakeOnly(tesd, 1, 71 + 18, 18));
this.addSlotToContainer(new SlotTakeOnly(tesd, 2, 98, 17)); this.addSlotToContainer(new SlotTakeOnly(tesd, 2, 71 + 18 * 2, 18));
this.addSlotToContainer(new SlotTakeOnly(tesd, 3, 116, 17)); this.addSlotToContainer(new SlotTakeOnly(tesd, 3, 71 + 18 * 3, 18));
this.addSlotToContainer(new SlotTakeOnly(tesd, 4, 134, 17)); this.addSlotToContainer(new SlotTakeOnly(tesd, 4, 71 + 18 * 4, 18));
this.addSlotToContainer(new SlotTakeOnly(tesd, 5, 62, 35)); this.addSlotToContainer(new SlotTakeOnly(tesd, 5, 71, 36));
this.addSlotToContainer(new SlotTakeOnly(tesd, 6, 80, 35)); this.addSlotToContainer(new SlotTakeOnly(tesd, 6, 71 + 18, 36));
this.addSlotToContainer(new SlotTakeOnly(tesd, 7, 98, 35)); this.addSlotToContainer(new SlotTakeOnly(tesd, 7, 71 + 18 * 2, 36));
this.addSlotToContainer(new SlotTakeOnly(tesd, 8, 116, 35)); this.addSlotToContainer(new SlotTakeOnly(tesd, 8, 71 + 18 * 3, 36));
this.addSlotToContainer(new SlotTakeOnly(tesd, 9, 134, 35)); this.addSlotToContainer(new SlotTakeOnly(tesd, 9, 71 + 18 * 4, 36));
this.addSlotToContainer(new SlotTakeOnly(tesd, 10, 62, 53)); this.addSlotToContainer(new SlotTakeOnly(tesd, 10, 71, 54));
this.addSlotToContainer(new SlotTakeOnly(tesd, 11, 80, 53)); this.addSlotToContainer(new SlotTakeOnly(tesd, 11, 71 + 18, 54));
this.addSlotToContainer(new SlotTakeOnly(tesd, 12, 98, 53)); this.addSlotToContainer(new SlotTakeOnly(tesd, 12, 71 + 18 * 2, 54));
this.addSlotToContainer(new SlotTakeOnly(tesd, 13, 116, 53)); this.addSlotToContainer(new SlotTakeOnly(tesd, 13, 71 + 18 * 3, 54));
this.addSlotToContainer(new SlotTakeOnly(tesd, 14, 134, 53)); this.addSlotToContainer(new SlotTakeOnly(tesd, 14, 71 + 18 * 4, 54));
//Chip //Chip
this.addSlotToContainer(new Slot(tesd, 15, 26, 35) { this.addSlotToContainer(new Slot(tesd, 15, 26, 36) {
@Override @Override
public boolean isItemValid(ItemStack stack) { public boolean isItemValid(ItemStack stack) {
return stack.getItem() instanceof ItemSatChip; return stack.getItem() instanceof ItemSatChip;
@ -43,12 +43,12 @@ public class ContainerSatDock extends Container {
for(int i = 0; i < 3; i++) { for(int i = 0; i < 3; i++) {
for(int j = 0; j < 9; j++) { for(int j = 0; j < 9; j++) {
this.addSlotToContainer(new Slot(invPlayer, j + i * 9 + 9, 8 + j * 18, 84 + i * 18)); this.addSlotToContainer(new Slot(invPlayer, j + i * 9 + 9, 8 + j * 18, 104 + i * 18));
} }
} }
for(int i = 0; i < 9; i++) { for(int i = 0; i < 9; i++) {
this.addSlotToContainer(new Slot(invPlayer, i, 8 + i * 18, 142)); this.addSlotToContainer(new Slot(invPlayer, i, 8 + i * 18, 162));
} }
} }

View File

@ -19,23 +19,23 @@ public class ContainerSoyuzCapsule extends Container {
{ {
for(int j = 0; j < 6; j++) for(int j = 0; j < 6; j++)
{ {
this.addSlotToContainer(new Slot(tedf, j + i * 6, 8 + j * 18 + 18 * 2, 17 + i * 18)); this.addSlotToContainer(new Slot(tedf, j + i * 6, 26 + j * 18 + 18 * 2, 18 + i * 18));
} }
} }
this.addSlotToContainer(new Slot(tedf, 18, 8, 35)); this.addSlotToContainer(new Slot(tedf, 18, 17, 36));
for(int i = 0; i < 3; i++) for(int i = 0; i < 3; i++)
{ {
for(int j = 0; j < 9; j++) for(int j = 0; j < 9; j++)
{ {
this.addSlotToContainer(new Slot(invPlayer, j + i * 9 + 9, 8 + j * 18, 84 + i * 18)); this.addSlotToContainer(new Slot(invPlayer, j + i * 9 + 9, 8 + j * 18, 104 + i * 18));
} }
} }
for(int i = 0; i < 9; i++) for(int i = 0; i < 9; i++)
{ {
this.addSlotToContainer(new Slot(invPlayer, i, 8 + i * 18, 142)); this.addSlotToContainer(new Slot(invPlayer, i, 8 + i * 18, 162));
} }
} }

View File

@ -17,29 +17,29 @@ public class ContainerSoyuzLauncher extends Container {
nukeBoy = tedf; nukeBoy = tedf;
//Soyuz //Soyuz
this.addSlotToContainer(new Slot(tedf, 0, 62, 18)); this.addSlotToContainer(new Slot(tedf, 0, 98, 80));
//Designator //Designator
this.addSlotToContainer(new Slot(tedf, 1, 62, 36)); this.addSlotToContainer(new Slot(tedf, 1, 80, 80));
//Satellite //Satellite
this.addSlotToContainer(new Slot(tedf, 2, 116, 18)); this.addSlotToContainer(new Slot(tedf, 2, 98, 26));
//Landing module //Landing module
this.addSlotToContainer(new Slot(tedf, 3, 116, 36)); this.addSlotToContainer(new Slot(tedf, 3, 80, 26));
//Kerosene IN //Kerosene IN
this.addSlotToContainer(new Slot(tedf, 4, 8, 90)); this.addSlotToContainer(new Slot(tedf, 4, 152, 98));
//Kerosene OUT //Kerosene OUT
this.addSlotToContainer(new Slot(tedf, 5, 8, 108)); this.addSlotToContainer(new Slot(tedf, 5, 152, 116));
//Peroxide IN //Oxyden IN
this.addSlotToContainer(new Slot(tedf, 6, 26, 90)); this.addSlotToContainer(new Slot(tedf, 6, 170, 98));
//Peroxide OUT //Oxyden OUT
this.addSlotToContainer(new Slot(tedf, 7, 26, 108)); this.addSlotToContainer(new Slot(tedf, 7, 170, 116));
//Battery //Battery
this.addSlotToContainer(new Slot(tedf, 8, 44, 108)); this.addSlotToContainer(new Slot(tedf, 8, 134, 98));
for(int i = 0; i < 3; i++) for(int i = 0; i < 3; i++)
{ {
for(int j = 0; j < 6; j++) for(int j = 0; j < 6; j++)
{ {
this.addSlotToContainer(new Slot(tedf, j + i * 6 + 9, 62 + j * 18, 72 + i * 18)); this.addSlotToContainer(new Slot(tedf, j + i * 6 + 9, 44 - i * 18, 26 + j * 18));
} }
} }
@ -47,13 +47,13 @@ public class ContainerSoyuzLauncher extends Container {
{ {
for(int j = 0; j < 9; j++) for(int j = 0; j < 9; j++)
{ {
this.addSlotToContainer(new Slot(invPlayer, j + i * 9 + 9, 8 + j * 18, 84 + i * 18 + 56)); this.addSlotToContainer(new Slot(invPlayer, j + i * 9 + 9, 17 + j * 18, 162 + i * 18));
} }
} }
for(int i = 0; i < 9; i++) for(int i = 0; i < 9; i++)
{ {
this.addSlotToContainer(new Slot(invPlayer, i, 8 + i * 18, 142 + 56)); this.addSlotToContainer(new Slot(invPlayer, i, 17 + i * 18, 220));
} }
} }
@ -68,8 +68,8 @@ public class ContainerSoyuzLauncher extends Container {
ItemStack var5 = var4.getStack(); ItemStack var5 = var4.getStack();
var3 = var5.copy(); var3 = var5.copy();
if (par2 <= 27) { if (par2 < 27) {
if (!this.mergeItemStack(var5, 9, this.inventorySlots.size(), true)) if (!this.mergeItemStack(var5, 27, this.inventorySlots.size(), true))
{ {
return null; return null;
} }

View File

@ -5,6 +5,7 @@ import org.lwjgl.opengl.GL11;
import com.hbm.inventory.container.ContainerMachineKeyForge; import com.hbm.inventory.container.ContainerMachineKeyForge;
import com.hbm.lib.RefStrings; import com.hbm.lib.RefStrings;
import com.hbm.tileentity.machine.TileEntityMachineKeyForge; import com.hbm.tileentity.machine.TileEntityMachineKeyForge;
import com.hbm.util.i18n.I18nUtil;
import net.minecraft.client.Minecraft; import net.minecraft.client.Minecraft;
import net.minecraft.client.resources.I18n; import net.minecraft.client.resources.I18n;
@ -13,7 +14,7 @@ import net.minecraft.util.ResourceLocation;
public class GUIMachineKeyForge extends GuiInfoContainer { public class GUIMachineKeyForge extends GuiInfoContainer {
private static ResourceLocation texture = new ResourceLocation(RefStrings.MODID + ":textures/gui/gui_keyforge.png"); private static ResourceLocation texture = new ResourceLocation(RefStrings.MODID + ":textures/gui/machine/gui_keyforge.png");
private TileEntityMachineKeyForge siren; private TileEntityMachineKeyForge siren;
public GUIMachineKeyForge(InventoryPlayer invPlayer, TileEntityMachineKeyForge tedf) { public GUIMachineKeyForge(InventoryPlayer invPlayer, TileEntityMachineKeyForge tedf) {
@ -21,26 +22,25 @@ public class GUIMachineKeyForge extends GuiInfoContainer {
siren = tedf; siren = tedf;
this.xSize = 176; this.xSize = 176;
this.ySize = 166; this.ySize = 186;
} }
@Override @Override
public void drawScreen(int mouseX, int mouseY, float f) { public void drawScreen(int mouseX, int mouseY, float f) {
super.drawScreen(mouseX, mouseY, f); super.drawScreen(mouseX, mouseY, f);
String[] text = new String[] { "The first slot will copy the key/lock's", String[] keyText = I18nUtil.resolveKeyArray("desc.gui.keyforge.key");
"pin configuration and paste it to the second slot." }; this.drawCustomInfoStat(mouseX, mouseY, guiLeft + 12, guiTop + 28, 16, 16, guiLeft - 8, guiTop + 36 + 16, keyText);
this.drawCustomInfoStat(mouseX, mouseY, guiLeft - 16, guiTop + 36, 16, 16, guiLeft - 8, guiTop + 36 + 16, text);
String[] text1 = new String[] { "The third slot will randomize the", String[] randomText = I18nUtil.resolveKeyArray("desc.gui.keyforge.random");
"key/lock's pin configuration."}; this.drawCustomInfoStat(mouseX, mouseY, guiLeft + 12, guiTop + 28 + 16, 16, 16, guiLeft - 8, guiTop + 36 + 16, randomText);
this.drawCustomInfoStat(mouseX, mouseY, guiLeft - 16, guiTop + 36 + 16, 16, 16, guiLeft - 8, guiTop + 36 + 16, text1);
} }
@Override @Override
protected void drawGuiContainerForegroundLayer(int i, int j) { protected void drawGuiContainerForegroundLayer(int i, int j) {
String name = this.siren.hasCustomInventoryName() ? this.siren.getInventoryName() : I18n.format(this.siren.getInventoryName()); String name = this.siren.hasCustomInventoryName() ? this.siren.getInventoryName() : I18n.format(this.siren.getInventoryName());
this.fontRendererObj.drawString(name, this.xSize / 2 - this.fontRendererObj.getStringWidth(name) / 2, 6, 4210752);
this.fontRendererObj.drawString(name, this.xSize / 2 - this.fontRendererObj.getStringWidth(name) / 2, 6, 0xffffff);
this.fontRendererObj.drawString(I18n.format("container.inventory"), 8, this.ySize - 96 + 2, 4210752); this.fontRendererObj.drawString(I18n.format("container.inventory"), 8, this.ySize - 96 + 2, 4210752);
} }
@ -50,7 +50,7 @@ public class GUIMachineKeyForge extends GuiInfoContainer {
Minecraft.getMinecraft().getTextureManager().bindTexture(texture); Minecraft.getMinecraft().getTextureManager().bindTexture(texture);
drawTexturedModalRect(guiLeft, guiTop, 0, 0, xSize, ySize); drawTexturedModalRect(guiLeft, guiTop, 0, 0, xSize, ySize);
this.drawInfoPanel(guiLeft - 16, guiTop + 36, 16, 16, 2); this.drawInfoPanel(guiLeft + 12, guiTop + 28, 16, 16, 2);
this.drawInfoPanel(guiLeft - 16, guiTop + 36 + 16, 16, 16, 3); this.drawInfoPanel(guiLeft + 12, guiTop + 28 + 16, 16, 16, 3);
} }
} }

View File

@ -5,6 +5,7 @@ import org.lwjgl.opengl.GL11;
import com.hbm.inventory.container.ContainerMachineSatLinker; import com.hbm.inventory.container.ContainerMachineSatLinker;
import com.hbm.lib.RefStrings; import com.hbm.lib.RefStrings;
import com.hbm.tileentity.machine.TileEntityMachineSatLinker; import com.hbm.tileentity.machine.TileEntityMachineSatLinker;
import com.hbm.util.i18n.I18nUtil;
import net.minecraft.client.Minecraft; import net.minecraft.client.Minecraft;
import net.minecraft.client.resources.I18n; import net.minecraft.client.resources.I18n;
@ -13,7 +14,7 @@ import net.minecraft.util.ResourceLocation;
public class GUIMachineSatLinker extends GuiInfoContainer { public class GUIMachineSatLinker extends GuiInfoContainer {
private static ResourceLocation texture = new ResourceLocation(RefStrings.MODID + ":textures/gui/gui_linker.png"); private static ResourceLocation texture = new ResourceLocation(RefStrings.MODID + ":textures/gui/machine/gui_sat_linker.png");
private TileEntityMachineSatLinker siren; private TileEntityMachineSatLinker siren;
public GUIMachineSatLinker(InventoryPlayer invPlayer, TileEntityMachineSatLinker tedf) { public GUIMachineSatLinker(InventoryPlayer invPlayer, TileEntityMachineSatLinker tedf) {
@ -21,25 +22,24 @@ public class GUIMachineSatLinker extends GuiInfoContainer {
siren = tedf; siren = tedf;
this.xSize = 176; this.xSize = 176;
this.ySize = 166; this.ySize = 186;
} }
@Override @Override
public void drawScreen(int mouseX, int mouseY, float f) { public void drawScreen(int mouseX, int mouseY, float f) {
super.drawScreen(mouseX, mouseY, f); super.drawScreen(mouseX, mouseY, f);
String[] text = new String[] { "The first slot will copy the satellite/chip's", String[] chipText = I18nUtil.resolveKeyArray("desc.gui.satlinker.chip");
"frequency and paste it to the second slot." }; this.drawCustomInfoStat(mouseX, mouseY, guiLeft + 12, guiTop + 28, 16, 16, guiLeft - 8, guiTop + 36 + 16, chipText);
this.drawCustomInfoStat(mouseX, mouseY, guiLeft - 16, guiTop + 36, 16, 16, guiLeft - 8, guiTop + 36 + 16, text);
String[] text1 = new String[] { "The third slot will randomize the", String[] randomText = I18nUtil.resolveKeyArray("desc.gui.satlinker.random");
"satellite/chip's frequency."}; this.drawCustomInfoStat(mouseX, mouseY, guiLeft + 12, guiTop + 28 + 16, 16, 16, guiLeft - 8, guiTop + 36 + 16, randomText);
this.drawCustomInfoStat(mouseX, mouseY, guiLeft - 16, guiTop + 36 + 16, 16, 16, guiLeft - 8, guiTop + 36 + 16, text1);
} }
@Override @Override
protected void drawGuiContainerForegroundLayer(int i, int j) { protected void drawGuiContainerForegroundLayer(int i, int j) {
String name = this.siren.hasCustomInventoryName() ? this.siren.getInventoryName() : I18n.format(this.siren.getInventoryName()); String name = this.siren.hasCustomInventoryName() ? this.siren.getInventoryName() : I18n.format(this.siren.getInventoryName());
this.fontRendererObj.drawString(name, this.xSize / 2 - this.fontRendererObj.getStringWidth(name) / 2, 6, 4210752); this.fontRendererObj.drawString(name, this.xSize / 2 - this.fontRendererObj.getStringWidth(name) / 2, 6, 4210752);
this.fontRendererObj.drawString(I18n.format("container.inventory"), 8, this.ySize - 96 + 2, 4210752); this.fontRendererObj.drawString(I18n.format("container.inventory"), 8, this.ySize - 96 + 2, 4210752);
} }
@ -50,7 +50,7 @@ public class GUIMachineSatLinker extends GuiInfoContainer {
Minecraft.getMinecraft().getTextureManager().bindTexture(texture); Minecraft.getMinecraft().getTextureManager().bindTexture(texture);
drawTexturedModalRect(guiLeft, guiTop, 0, 0, xSize, ySize); drawTexturedModalRect(guiLeft, guiTop, 0, 0, xSize, ySize);
this.drawInfoPanel(guiLeft - 16, guiTop + 36, 16, 16, 2); this.drawInfoPanel(guiLeft + 12, guiTop + 28, 16, 16, 2);
this.drawInfoPanel(guiLeft - 16, guiTop + 36 + 16, 16, 16, 3); this.drawInfoPanel(guiLeft + 12, guiTop + 28 + 16, 16, 16, 3);
} }
} }

View File

@ -3,6 +3,8 @@ package com.hbm.inventory.gui;
import com.hbm.inventory.container.ContainerSatDock; import com.hbm.inventory.container.ContainerSatDock;
import com.hbm.lib.RefStrings; import com.hbm.lib.RefStrings;
import com.hbm.tileentity.machine.TileEntityMachineSatDock; import com.hbm.tileentity.machine.TileEntityMachineSatDock;
import com.hbm.util.i18n.I18nUtil;
import net.minecraft.client.Minecraft; import net.minecraft.client.Minecraft;
import net.minecraft.client.resources.I18n; import net.minecraft.client.resources.I18n;
import net.minecraft.entity.player.InventoryPlayer; import net.minecraft.entity.player.InventoryPlayer;
@ -11,7 +13,7 @@ import org.lwjgl.opengl.GL11;
public class GUISatDock extends GuiInfoContainer { public class GUISatDock extends GuiInfoContainer {
public static final ResourceLocation texture = new ResourceLocation(RefStrings.MODID + ":textures/gui/gui_dock.png"); public static final ResourceLocation texture = new ResourceLocation(RefStrings.MODID + ":textures/gui/storage/gui_sat_dock.png");
private final TileEntityMachineSatDock tileSatelliteDock; private final TileEntityMachineSatDock tileSatelliteDock;
public GUISatDock(InventoryPlayer invPlayer, TileEntityMachineSatDock tesd) { public GUISatDock(InventoryPlayer invPlayer, TileEntityMachineSatDock tesd) {
@ -19,24 +21,22 @@ public class GUISatDock extends GuiInfoContainer {
tileSatelliteDock = tesd; tileSatelliteDock = tesd;
this.xSize = 176; this.xSize = 176;
this.ySize = 168; this.ySize = 186;
} }
@Override @Override
public void drawScreen(int mouseX, int mouseY, float f) { public void drawScreen(int mouseX, int mouseY, float f) {
super.drawScreen(mouseX, mouseY, f); super.drawScreen(mouseX, mouseY, f);
String[] text = new String[] { "Requires linked miner sat chip.", String[] text = I18nUtil.resolveKeyArray("desc.gui.satdock.desc");
"Cargo ship will land periodically to", this.drawCustomInfoStat(mouseX, mouseY, guiLeft - 7, guiTop + 36, 16, 16, guiLeft - 7, guiTop + 36 + 16, text);
"deliver resources." };
this.drawCustomInfoStat(mouseX, mouseY, guiLeft - 16, guiTop + 36, 16, 16, guiLeft - 8, guiTop + 36 + 16, text);
} }
@Override @Override
protected void drawGuiContainerForegroundLayer(int i, int j) { protected void drawGuiContainerForegroundLayer(int i, int j) {
String name = this.tileSatelliteDock.hasCustomInventoryName() ? this.tileSatelliteDock.getInventoryName() : I18n.format(this.tileSatelliteDock.getInventoryName()); String name = this.tileSatelliteDock.hasCustomInventoryName() ? this.tileSatelliteDock.getInventoryName() : I18n.format(this.tileSatelliteDock.getInventoryName());
this.fontRendererObj.drawString(name, this.xSize / 2 - this.fontRendererObj.getStringWidth(name) / 2, 6, 0x404040); this.fontRendererObj.drawString(name, 115 - this.fontRendererObj.getStringWidth(name) / 2, 6, 0x404040);
this.fontRendererObj.drawString(I18n.format("container.inventory"), 8, this.ySize - 96 + 2, 0x404040); this.fontRendererObj.drawString(I18n.format("container.inventory"), 8, this.ySize - 96 + 2, 0x404040);
} }
@ -46,6 +46,6 @@ public class GUISatDock extends GuiInfoContainer {
Minecraft.getMinecraft().getTextureManager().bindTexture(texture); Minecraft.getMinecraft().getTextureManager().bindTexture(texture);
drawTexturedModalRect(guiLeft, guiTop, 0, 0, xSize, ySize); drawTexturedModalRect(guiLeft, guiTop, 0, 0, xSize, ySize);
this.drawInfoPanel(guiLeft - 16, guiTop + 36, 16, 16, 2); this.drawInfoPanel(guiLeft - 7, guiTop + 36, 16, 16, 2);
} }
} }

View File

@ -14,7 +14,7 @@ import net.minecraft.util.ResourceLocation;
public class GUISoyuzCapsule extends GuiContainer { public class GUISoyuzCapsule extends GuiContainer {
private static ResourceLocation texture = new ResourceLocation(RefStrings.MODID + ":textures/gui/gui_soyuz_capsule.png"); private static ResourceLocation texture = new ResourceLocation(RefStrings.MODID + ":textures/gui/storage/gui_soyuz_capsule.png");
private TileEntitySoyuzCapsule diFurnace; private TileEntitySoyuzCapsule diFurnace;
public GUISoyuzCapsule(InventoryPlayer invPlayer, TileEntitySoyuzCapsule tedf) { public GUISoyuzCapsule(InventoryPlayer invPlayer, TileEntitySoyuzCapsule tedf) {
@ -22,14 +22,14 @@ public class GUISoyuzCapsule extends GuiContainer {
diFurnace = tedf; diFurnace = tedf;
this.xSize = 176; this.xSize = 176;
this.ySize = 168; this.ySize = 186;
} }
@Override @Override
protected void drawGuiContainerForegroundLayer(int i, int j) { protected void drawGuiContainerForegroundLayer(int i, int j) {
String name = this.diFurnace.hasCustomInventoryName() ? this.diFurnace.getInventoryName() : I18n.format(this.diFurnace.getInventoryName()); String name = this.diFurnace.hasCustomInventoryName() ? this.diFurnace.getInventoryName() : I18n.format(this.diFurnace.getInventoryName());
this.fontRendererObj.drawString(name, this.xSize / 2 - this.fontRendererObj.getStringWidth(name) / 2, 6, 4210752); this.fontRendererObj.drawString(name, 115 - this.fontRendererObj.getStringWidth(name) / 2, 6, 0x7daf71);
this.fontRendererObj.drawString(I18n.format("container.inventory"), 8, this.ySize - 96 + 2, 4210752); this.fontRendererObj.drawString(I18n.format("container.inventory"), 8, this.ySize - 96 + 2, 4210752);
} }

View File

@ -7,6 +7,7 @@ import com.hbm.lib.RefStrings;
import com.hbm.packet.PacketDispatcher; import com.hbm.packet.PacketDispatcher;
import com.hbm.packet.toserver.AuxButtonPacket; import com.hbm.packet.toserver.AuxButtonPacket;
import com.hbm.tileentity.machine.TileEntitySoyuzLauncher; import com.hbm.tileentity.machine.TileEntitySoyuzLauncher;
import com.hbm.util.i18n.I18nUtil;
import net.minecraft.client.Minecraft; import net.minecraft.client.Minecraft;
import net.minecraft.client.audio.PositionedSoundRecord; import net.minecraft.client.audio.PositionedSoundRecord;
@ -16,49 +17,50 @@ import net.minecraft.util.ResourceLocation;
public class GUISoyuzLauncher extends GuiInfoContainer { public class GUISoyuzLauncher extends GuiInfoContainer {
private static ResourceLocation texture = new ResourceLocation(RefStrings.MODID + ":textures/gui/gui_soyuz.png"); private static ResourceLocation texture = new ResourceLocation(RefStrings.MODID + ":textures/gui/machine/gui_soyuz.png");
private TileEntitySoyuzLauncher launcher; private TileEntitySoyuzLauncher launcher;
public GUISoyuzLauncher(InventoryPlayer invPlayer, TileEntitySoyuzLauncher tedf) { public GUISoyuzLauncher(InventoryPlayer invPlayer, TileEntitySoyuzLauncher tedf) {
super(new ContainerSoyuzLauncher(invPlayer, tedf)); super(new ContainerSoyuzLauncher(invPlayer, tedf));
launcher = tedf; launcher = tedf;
this.xSize = 176; this.xSize = 194;
this.ySize = 222; this.ySize = 244;
} }
@Override @Override
public void drawScreen(int mouseX, int mouseY, float f) { public void drawScreen(int mouseX, int mouseY, float f) {
super.drawScreen(mouseX, mouseY, f); super.drawScreen(mouseX, mouseY, f);
launcher.tanks[0].renderTankInfo(this, mouseX, mouseY, guiLeft + 8, guiTop + 36, 16, 52); launcher.tanks[0].renderTankInfo(this, mouseX, mouseY, guiLeft + 152, guiTop + 44, 16, 52);
launcher.tanks[1].renderTankInfo(this, mouseX, mouseY, guiLeft + 26, guiTop + 36, 16, 52); launcher.tanks[1].renderTankInfo(this, mouseX, mouseY, guiLeft + 170, guiTop + 44, 16, 52);
this.drawElectricityInfo(this, mouseX, mouseY, guiLeft + 49, guiTop + 72, 6, 34, launcher.power, launcher.maxPower); this.drawElectricityInfo(this, mouseX, mouseY, guiLeft + 134, guiTop + 44, 16, 52, launcher.power, launcher.maxPower);
this.drawCustomInfoStat(mouseX, mouseY, guiLeft + 43, guiTop + 17, 18, 18, mouseX, mouseY, new String[]{"The Soyuz goes here"} ); String[] descText = I18nUtil.resolveKeyArray("desc.gui.soyuz.desc");
this.drawCustomInfoStat(mouseX, mouseY, guiLeft + 43, guiTop + 35, 18, 18, mouseX, mouseY, new String[]{"Designator only for CARGO MODE"} ); this.drawCustomInfoStat(mouseX, mouseY, guiLeft - 16, guiTop + 53, 16, 16, guiLeft - 8, guiTop + 53 + 16, descText);
this.drawCustomInfoStat(mouseX, mouseY, guiLeft + 133, guiTop + 17, 18, 18, mouseX, mouseY, new String[]{"The payload for SATELLITE MODE"} );
this.drawCustomInfoStat(mouseX, mouseY, guiLeft + 133, guiTop + 35, 18, 18, mouseX, mouseY, new String[]{"The orbital module for special payloads"} ); String[] cargoText = I18nUtil.resolveKeyArray("desc.gui.soyuz.cargo");
this.drawCustomInfoStat(mouseX, mouseY, guiLeft + 88, guiTop + 17, 18, 18, mouseX, mouseY, new String[]{"SATELLITE MODE"} ); this.drawCustomInfoStat(mouseX, mouseY, guiLeft + 79, guiTop + 52, 18, 18, mouseX, mouseY, cargoText );
this.drawCustomInfoStat(mouseX, mouseY, guiLeft + 88, guiTop + 35, 18, 18, mouseX, mouseY, new String[]{"CARGO MODE"} ); String[] satelliteText = I18nUtil.resolveKeyArray("desc.gui.soyuz.satellite");
this.drawCustomInfoStat(mouseX, mouseY, guiLeft + 97, guiTop + 52, 18, 18, mouseX, mouseY, satelliteText );
} }
protected void mouseClicked(int x, int y, int i) { protected void mouseClicked(int x, int y, int i) {
super.mouseClicked(x, y, i); super.mouseClicked(x, y, i);
if(guiLeft + 88 <= x && guiLeft + 88 + 18 > x && guiTop + 17 < y && guiTop + 17 + 18 >= y) { if(guiLeft + 97 <= x && guiLeft + 97 + 18 > x && guiTop + 52 < y && guiTop + 52 + 18 >= y) {
mc.getSoundHandler().playSound(PositionedSoundRecord.func_147674_a(new ResourceLocation("gui.button.press"), 1.0F)); mc.getSoundHandler().playSound(PositionedSoundRecord.func_147674_a(new ResourceLocation("gui.button.press"), 1.0F));
PacketDispatcher.wrapper.sendToServer(new AuxButtonPacket(launcher.xCoord, launcher.yCoord, launcher.zCoord, 0, 0)); PacketDispatcher.wrapper.sendToServer(new AuxButtonPacket(launcher.xCoord, launcher.yCoord, launcher.zCoord, 0, 0));
} }
if(guiLeft + 88 <= x && guiLeft + 88 + 18 > x && guiTop + 35 < y && guiTop + 35 + 18 >= y) { if(guiLeft + 79 <= x && guiLeft + 79 + 18 > x && guiTop + 52 < y && guiTop + 52 + 18 >= y) {
mc.getSoundHandler().playSound(PositionedSoundRecord.func_147674_a(new ResourceLocation("gui.button.press"), 1.0F)); mc.getSoundHandler().playSound(PositionedSoundRecord.func_147674_a(new ResourceLocation("gui.button.press"), 1.0F));
PacketDispatcher.wrapper.sendToServer(new AuxButtonPacket(launcher.xCoord, launcher.yCoord, launcher.zCoord, 1, 0)); PacketDispatcher.wrapper.sendToServer(new AuxButtonPacket(launcher.xCoord, launcher.yCoord, launcher.zCoord, 1, 0));
} }
if(guiLeft + 151 <= x && guiLeft + 151 + 18 > x && guiTop + 17 < y && guiTop + 17 + 18 >= y) { if(guiLeft + 88 <= x && guiLeft + 88 + 18 > x && guiTop + 97 < y && guiTop + 97 + 18 >= y) {
mc.getSoundHandler().playSound(PositionedSoundRecord.func_147674_a(new ResourceLocation("gui.button.press"), 1.0F)); mc.getSoundHandler().playSound(PositionedSoundRecord.func_147674_a(new ResourceLocation("gui.button.press"), 1.0F));
PacketDispatcher.wrapper.sendToServer(new AuxButtonPacket(launcher.xCoord, launcher.yCoord, launcher.zCoord, 0, 1)); PacketDispatcher.wrapper.sendToServer(new AuxButtonPacket(launcher.xCoord, launcher.yCoord, launcher.zCoord, 0, 1));
@ -69,8 +71,8 @@ public class GUISoyuzLauncher extends GuiInfoContainer {
protected void drawGuiContainerForegroundLayer( int i, int j) { protected void drawGuiContainerForegroundLayer( int i, int j) {
String name = this.launcher.hasCustomInventoryName() ? this.launcher.getInventoryName() : I18n.format(this.launcher.getInventoryName()); String name = this.launcher.hasCustomInventoryName() ? this.launcher.getInventoryName() : I18n.format(this.launcher.getInventoryName());
this.fontRendererObj.drawString(name, this.xSize / 2 - this.fontRendererObj.getStringWidth(name) / 2, 6, 4210752); this.fontRendererObj.drawString(name, this.xSize / 2 - this.fontRendererObj.getStringWidth(name) / 2, 4, 0xffffff);
this.fontRendererObj.drawString(I18n.format("container.inventory"), 8, this.ySize - 96 + 2, 4210752); this.fontRendererObj.drawString(I18n.format("container.inventory"), 17, this.ySize - 96 + 2, 4210752);
String secs = "" + launcher.countdown / 20; String secs = "" + launcher.countdown / 20;
String cents = "" + (launcher.countdown % 20) * 5; String cents = "" + (launcher.countdown % 20) * 5;
@ -79,9 +81,9 @@ public class GUISoyuzLauncher extends GuiInfoContainer {
if(cents.length() == 1) if(cents.length() == 1)
cents += "0"; cents += "0";
float scale = 0.5F; float scale = 1;
GL11.glScalef(scale, scale, 1); GL11.glScalef(scale, scale, 1);
this.fontRendererObj.drawString(secs + ":" + cents, (int)(153.5F / scale), (int)(37.5F / scale), 0xff0000); this.fontRendererObj.drawString(secs + ":" + cents, (int)(85 / scale), (int)(121 / scale), 0xff0000);
GL11.glScalef(1/scale, 1/scale, 1); GL11.glScalef(1/scale, 1/scale, 1);
} }
@ -91,47 +93,49 @@ public class GUISoyuzLauncher extends GuiInfoContainer {
Minecraft.getMinecraft().getTextureManager().bindTexture(texture); Minecraft.getMinecraft().getTextureManager().bindTexture(texture);
drawTexturedModalRect(guiLeft, guiTop, 0, 0, xSize, ySize); drawTexturedModalRect(guiLeft, guiTop, 0, 0, xSize, ySize);
int i = (int)launcher.getPowerScaled(34); int i = (int)launcher.getPowerScaled(52);
drawTexturedModalRect(guiLeft + 49, guiTop + 106 - i, 194, 52 - i, 6, i); drawTexturedModalRect(guiLeft + 134, guiTop + 96 - i, 194, 52 - i, 16, i);
drawTexturedModalRect(guiLeft + 61, guiTop + 17, 176 + (launcher.hasRocket() ? 18 : 0), 0, 18, 18); drawTexturedModalRect(guiLeft + 97, guiTop + 79, 210 + (launcher.hasRocket() ? 18 : 0), 8, 18, 18);
int j = launcher.designator(); int j = launcher.designator();
if(j > 0) if(j > 0)
drawTexturedModalRect(guiLeft + 61, guiTop + 35, 176 + (j - 1) * 18, 0, 18, 18); drawTexturedModalRect(guiLeft + 79, guiTop + 79, 210 + (j - 1) * 18, 8, 18, 18);
int k = launcher.mode; int k = launcher.mode;
drawTexturedModalRect(guiLeft + 88, guiTop + 17 + k * 18, 176, 18 + k * 18, 18, 18); drawTexturedModalRect(guiLeft + 97 - k * 18, guiTop + 52, 228 - k * 18, 26, 18, 18);
int l = launcher.orbital(); int l = launcher.orbital();
if(l > 0) if(l > 0)
drawTexturedModalRect(guiLeft + 115, guiTop + 35, 176 + (l - 1) * 18, 0, 18, 18); drawTexturedModalRect(guiLeft + 79, guiTop + 25, 210 + (l - 1) * 18, 8, 18, 18);
int m = launcher.satellite(); int m = launcher.satellite();
if(m > 0) if(m > 0)
drawTexturedModalRect(guiLeft + 115, guiTop + 17, 176 + (m - 1) * 18, 0, 18, 18); drawTexturedModalRect(guiLeft + 97, guiTop + 25, 210 + (m - 1) * 18, 8, 18, 18);
if(launcher.starting) if(launcher.starting)
drawTexturedModalRect(guiLeft + 151, guiTop + 17, 176, 54, 18, 18); drawTexturedModalRect(guiLeft + 88, guiTop + 97, 210, 44, 18, 18);
if(launcher.hasFuel()) if(launcher.hasFuel())
drawTexturedModalRect(guiLeft + 13, guiTop + 23, 212, 0, 6, 8); drawTexturedModalRect(guiLeft + 157, guiTop + 31, 210, 0, 6, 8);
else else
drawTexturedModalRect(guiLeft + 13, guiTop + 23, 218, 0, 6, 8); drawTexturedModalRect(guiLeft + 157, guiTop + 31, 216, 0, 6, 8);
if(launcher.hasOxy()) if(launcher.hasOxy())
drawTexturedModalRect(guiLeft + 31, guiTop + 23, 212, 0, 6, 8); drawTexturedModalRect(guiLeft + 175, guiTop + 31, 210, 0, 6, 8);
else else
drawTexturedModalRect(guiLeft + 31, guiTop + 23, 218, 0, 6, 8); drawTexturedModalRect(guiLeft + 175, guiTop + 31, 216, 0, 6, 8);
if(launcher.hasPower()) if(launcher.hasPower())
drawTexturedModalRect(guiLeft + 49, guiTop + 59, 212, 0, 6, 8); drawTexturedModalRect(guiLeft + 139, guiTop + 31, 210, 0, 6, 8);
else else
drawTexturedModalRect(guiLeft + 49, guiTop + 59, 218, 0, 6, 8); drawTexturedModalRect(guiLeft + 139, guiTop + 31, 216, 0, 6, 8);
launcher.tanks[0].renderTank(guiLeft + 8, guiTop + 88, this.zLevel, 16, 52); launcher.tanks[0].renderTank(guiLeft + 152, guiTop + 96, this.zLevel, 16, 52);
launcher.tanks[1].renderTank(guiLeft + 26, guiTop + 88, this.zLevel, 16, 52); launcher.tanks[1].renderTank(guiLeft + 170, guiTop + 96, this.zLevel, 16, 52);
this.drawInfoPanel(guiLeft - 16, guiTop + 53, 16, 16, 2);
} }
} }

View File

@ -953,6 +953,8 @@ desc.gui.assembler.warning=§cError:§r This machine requires an assembly templa
desc.gui.chemplant.warning=§cError:§r This machine requires an chemistry template! desc.gui.chemplant.warning=§cError:§r This machine requires an chemistry template!
desc.gui.gasCent.enrichment=§2Enrichment§r$Uranium enrichment requires cascades.$Two-centrifuge cascades will give$uranium fuel, four-centrifuge cascades$will give total separation. desc.gui.gasCent.enrichment=§2Enrichment§r$Uranium enrichment requires cascades.$Two-centrifuge cascades will give$uranium fuel, four-centrifuge cascades$will give total separation.
desc.gui.gasCent.output=§6Fluid Transfer§r$Fluid can be transferred to another centrifuge$via the output port for further processing. desc.gui.gasCent.output=§6Fluid Transfer§r$Fluid can be transferred to another centrifuge$via the output port for further processing.
desc.gui.keyforge.key=The first slot will copy the key/lock's$pin configuration and paste it to the second slot.
desc.gui.keyforge.random=The third slot will randomize the$key/lock's pin configuration.
desc.gui.nukeBoy.desc=§1Requires:§r$ * Neutron Shielding$ * U235 Projectile$ * Subcritical U235 Target$ * Propellant$ * Bomb Igniter desc.gui.nukeBoy.desc=§1Requires:§r$ * Neutron Shielding$ * U235 Projectile$ * Subcritical U235 Target$ * Propellant$ * Bomb Igniter
desc.gui.nukeGadget.desc=§1Requires:§r$ * 4 Arrays of First-Generation$ High-Explosive Lenses$ * Heavy Plutonium Core$ * Wiring desc.gui.nukeGadget.desc=§1Requires:§r$ * 4 Arrays of First-Generation$ High-Explosive Lenses$ * Heavy Plutonium Core$ * Wiring
desc.gui.nukeMan.desc=§1Requires:§r$ * 4 Arrays of First-Generation$ High-Explosive Lenses$ * Plutonium Core$ * Bomb Firing Unit desc.gui.nukeMan.desc=§1Requires:§r$ * 4 Arrays of First-Generation$ High-Explosive Lenses$ * Plutonium Core$ * Bomb Firing Unit
@ -974,6 +976,12 @@ desc.gui.rtg.heat=§eCurrent heat level: %s
desc.gui.rtg.pellets=Accepted Pellets: desc.gui.rtg.pellets=Accepted Pellets:
desc.gui.rtg.pelletHeat=%s (%s heat) desc.gui.rtg.pelletHeat=%s (%s heat)
desc.gui.rtg.pelletPower=%s (%s HE/tick) desc.gui.rtg.pelletPower=%s (%s HE/tick)
desc.gui.satdock.desc=Requires linked miner sat chip.$Cargo ship will land periodically to$deliver resources.
desc.gui.satlinker.chip=The first slot will copy the satellite/chip's$frequency and paste it to the second slot.
desc.gui.satlinker.random=The third slot will randomize the$satellite/chip's frequency.
desc.gui.soyuz.cargo=CARGO MODE
desc.gui.soyuz.desc=Designator only for CARGO MODE$The payload for SATELLITE MODE
desc.gui.soyuz.satellite=SATELLITE MODE
desc.gui.template=§9Templates§r$Templates can be made by$using the Machine Template Folder. desc.gui.template=§9Templates§r$Templates can be made by$using the Machine Template Folder.
desc.gui.turbinegas.automode=§2Automatic turbine throttling mode§r$By clicking the "AUTO" button, the turbine$will automatically adjust the throttle position$based on the power required from the network$and the fuel level in the internal tank desc.gui.turbinegas.automode=§2Automatic turbine throttling mode§r$By clicking the "AUTO" button, the turbine$will automatically adjust the throttle position$based on the power required from the network$and the fuel level in the internal tank
desc.gui.turbinegas.fuels=§6Accepted fuels:§r desc.gui.turbinegas.fuels=§6Accepted fuels:§r

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.1 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.3 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.9 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 1.0 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.6 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 4.7 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 1.5 KiB

Binary file not shown.

After

Width:  |  Height:  |  Size: 2.5 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 283 B

After

Width:  |  Height:  |  Size: 342 B

Binary file not shown.

Before

Width:  |  Height:  |  Size: 3.1 KiB

After

Width:  |  Height:  |  Size: 3.2 KiB