Rework stencil table button layout to weaponry and more NEI fix

This commit is contained in:
Bernhard Bonigl committed 2014-10-24 13:30:46 +02:00
1 parent 939bd8a0ae
commit 5bfdb0d769
2 files changed
+12 -6

No files matched your search

@@ -168,7 +168,7 @@ public class StencilTableGui extends GuiContainer implements INEIGuiHandler
public boolean hideItemPanelSlot(GuiContainer guiContainer, int x, int y, int w, int h) {
// is it in the horizontal column of the right buttons?
if(x > this.guiLeft + this.xSize + 4 && x < this.guiLeft + this.xSize + 4 + 22*3 + 16)
if(y > this.guiTop + 2 && y < this.guiTop + 2 + 22*(TConstructClientRegistry.stencilButtons2.size()-1)/4)
if(y > this.guiTop - 10 && y < this.guiTop + 2 + 22*(TConstructClientRegistry.stencilButtons2.size()-1)/4 + 22*(TConstructClientRegistry.stencilButtons2.size()%4 > 0 ? 1 : 0))
return true;
return false;
@@ -98,11 +98,17 @@ public class WeaponryClientProxy extends WeaponryCommonProxy {
private void buttons()
{
int base = StencilBuilder.getIndex(new ItemStack(TinkerWeaponry.woodPattern, 0, 0));
TConstructClientRegistry.addStencilButton2(0, 4, base + 0, Reference.RESOURCE, "textures/gui/icons.png"); // shuriken
TConstructClientRegistry.addStencilButton2(1, 4, base + 1, Reference.RESOURCE, "textures/gui/icons.png"); // crossbow limb
TConstructClientRegistry.addStencilButton2(2, 4, base + 2, Reference.RESOURCE, "textures/gui/icons.png"); // crossbow body
TConstructClientRegistry.addStencilButton2(3, 4, base + 3, Reference.RESOURCE, "textures/gui/icons.png"); // bow limb
TConstructClientRegistry.addStencilButton2(11, 3, 21, Reference.RESOURCE, "textures/gui/icons.png"); // arrow head
TConstructClientRegistry.addStencilButton2(12, 3, 22, Reference.RESOURCE, "textures/gui/icons.png"); // fletchling
TConstructClientRegistry.addStencilButton2(0,0, -1, null, null);
TConstructClientRegistry.addStencilButton2(0,0, -1, null, null);
TConstructClientRegistry.addStencilButton2(3, 4, 27, Reference.RESOURCE, "textures/gui/icons.png"); // bow limb
TConstructClientRegistry.addStencilButton2(10, 3, 23, Reference.RESOURCE, "textures/gui/icons.png"); // bowstring
TConstructClientRegistry.addStencilButton2(1, 4, 25, Reference.RESOURCE, "textures/gui/icons.png"); // crossbow limb
TConstructClientRegistry.addStencilButton2(2, 4, 26, Reference.RESOURCE, "textures/gui/icons.png"); // crossbow body
TConstructClientRegistry.addStencilButton2(0, 4, 24, Reference.RESOURCE, "textures/gui/icons.png"); // shuriken
//TConstructClientRegistry.addStencilButton2(4, 4, index, Reference.RESOURCE, "textures/gui/icons.png"); // bolt
}
}