Merge branch 'experimental' into HEAD

This commit is contained in:
Dream-Master 2016-11-21 18:58:08 +01:00
commit f530d6dc2e
3 changed files with 9 additions and 7 deletions

View file

@ -16,7 +16,7 @@ import java.util.Iterator;
public class GT_Container_Teleporter
extends GT_ContainerMetaTile_Machine {
//public int mEgg = 0;
public int mEgg = 0;
public int mTargetD = 0;
public int mTargetZ = 0;
public int mTargetY = 0;
@ -119,7 +119,7 @@ public class GT_Container_Teleporter
this.mTargetY = ((GT_MetaTileEntity_Teleporter) this.mTileEntity.getMetaTileEntity()).mTargetY;
this.mTargetZ = ((GT_MetaTileEntity_Teleporter) this.mTileEntity.getMetaTileEntity()).mTargetZ;
this.mTargetD = ((GT_MetaTileEntity_Teleporter) this.mTileEntity.getMetaTileEntity()).mTargetD;
//this.mEgg = (((GT_MetaTileEntity_Teleporter) this.mTileEntity.getMetaTileEntity()).hasDimensionalTeleportCapability() ? 1 : 0);
this.mEgg = (((GT_MetaTileEntity_Teleporter) this.mTileEntity.getMetaTileEntity()).hasDimensionalTeleportCapability() ? 1 : 0);
Iterator var2 = this.crafters.iterator();
while (var2.hasNext()) {
@ -132,7 +132,7 @@ public class GT_Container_Teleporter
var1.sendProgressBarUpdate(this, 105, this.mTargetZ >>> 16);
var1.sendProgressBarUpdate(this, 106, this.mTargetD & 0xFFFF);
var1.sendProgressBarUpdate(this, 107, this.mTargetD >>> 16);
//var1.sendProgressBarUpdate(this, 108, 1);
var1.sendProgressBarUpdate(this, 108, this.mEgg);
}
}
@ -164,8 +164,8 @@ public class GT_Container_Teleporter
case 107:
this.mTargetD = (this.mTargetD & 0xFFFF | par2 << 16);
break;
//case 108:
// this.mEgg = par2;
case 108:
this.mEgg = par2;
}
}
}

View file

@ -19,10 +19,10 @@ public class GT_GUIContainer_Teleporter
this.fontRendererObj.drawString("X: " + GT_Utility.parseNumberToString(((GT_Container_Teleporter) this.mContainer).mTargetX), 46, 16, 16448255);
this.fontRendererObj.drawString("Y: " + GT_Utility.parseNumberToString(((GT_Container_Teleporter) this.mContainer).mTargetY), 46, 24, 16448255);
this.fontRendererObj.drawString("Z: " + GT_Utility.parseNumberToString(((GT_Container_Teleporter) this.mContainer).mTargetZ), 46, 32, 16448255);
//if (((GT_Container_Teleporter) this.mContainer).mEgg > 0) {
if (((GT_Container_Teleporter) this.mContainer).mEgg > 0) {
this.fontRendererObj.drawString("Dim: " + GT_Utility.parseNumberToString(((GT_Container_Teleporter) this.mContainer).mTargetD), 46, 40, 16448255);
this.fontRendererObj.drawString("Dim Valid: " + (GT_Utility.isRealDimension(((GT_Container_Teleporter) this.mContainer).mTargetD) ? "Yes":"No"), 46, 48, 16448255);
//}
}
}
}

View file

@ -215,6 +215,8 @@ public class GT_MetaTileEntity_Teleporter extends GT_MetaTileEntity_BasicTank {
}
}
}
public boolean hasDimensionalTeleportCapability() {return true;}
public boolean isDimensionalTeleportAvailable() {
return (this.mDebug) || ((GT_Utility.isRealDimension(this.mTargetD)) && (GT_Utility.isRealDimension(getBaseMetaTileEntity().getWorld().provider.dimensionId)));