more zone plan changes

This commit is contained in:
asiekierka 2015-04-05 10:39:42 +02:00
parent 24441a1ae5
commit ad4d418f78
3 changed files with 13 additions and 9 deletions

Binary file not shown.

Before

Width:  |  Height:  |  Size: 615 B

After

Width:  |  Height:  |  Size: 1.4 KiB

View file

@ -39,8 +39,8 @@ public class ContainerZonePlan extends BuildCraftContainer implements ICommandRe
map = iZonePlan;
addSlotToContainer(new Slot(iZonePlan, 0, 233, 20));
addSlotToContainer(new SlotOutput(iZonePlan, 1, 233, 68));
addSlotToContainer(new Slot(iZonePlan, 0, 233, 9));
addSlotToContainer(new SlotOutput(iZonePlan, 1, 233, 57));
// Player inventory
for (int l = 0; l < 3; l++) {

View file

@ -39,7 +39,7 @@ public class GuiZonePlan extends GuiAdvancedInterface {
private static final ResourceLocation TMP_TEXTURE = new ResourceLocation("buildcraftrobotics:textures/gui/zone_planner_gui.png");
private int mapWidth = 200;
private int mapWidth = 213;
private int mapHeight = 100;
private TileZonePlan zonePlan;
@ -146,7 +146,7 @@ public class GuiZonePlan extends GuiAdvancedInterface {
savedButtonList = buttonList;
textField = new GuiTextField(this.fontRendererObj, 74, 125, 156, 12);
textField = new GuiTextField(this.fontRendererObj, 28, 129, 156, 12);
textField.setMaxStringLength(DefaultProps.MAX_NAME_SIZE);
textField.setText(zonePlan.mapName);
textField.setFocused(true);
@ -168,10 +168,14 @@ public class GuiZonePlan extends GuiAdvancedInterface {
protected void drawGuiContainerBackgroundLayer(float f, int x, int y) {
super.drawGuiContainerBackgroundLayer(f, x, y);
if (getContainer().mapTexture.width <= 213) {
mapXMin = guiLeft + 8 + ((213 - getContainer().mapTexture.width) / 2);
} else {
mapXMin = (width - getContainer().mapTexture.width) / 2;
}
if (getContainer().mapTexture.height <= 200) {
mapYMin = guiTop + 20;
if (getContainer().mapTexture.height <= 100) {
mapYMin = guiTop + 9 + ((100 - getContainer().mapTexture.height) / 2);
} else {
mapYMin = (height - getContainer().mapTexture.height) / 2;
}
@ -202,7 +206,7 @@ public class GuiZonePlan extends GuiAdvancedInterface {
GL11.glDisable(GL11.GL_BLEND);
}
if (getContainer().mapTexture.height <= 200) {
if (getContainer().mapTexture.height <= 100) {
drawBackgroundSlots();
bindTexture(texture);
@ -338,7 +342,7 @@ public class GuiZonePlan extends GuiAdvancedInterface {
uploadMap();
refreshSelectedArea();
} else if (carac == 'm') {
mapWidth = 200;
mapWidth = 213;
mapHeight = 100;
getContainer().mapTexture = new DynamicTexturePaletted(mapWidth, mapHeight);