aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--src/Java/gregtech/api/enums/TAE.java9
-rw-r--r--src/Java/gtPlusPlus/xmod/gregtech/common/blocks/GregtechMetaCasingBlocks4.java12
-rw-r--r--src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/production/GregtechMTE_LargeNaqReactor.java82
-rw-r--r--src/Java/gtPlusPlus/xmod/gregtech/registration/gregtech/GregtechNaqReactor.java2
4 files changed, 63 insertions, 42 deletions
diff --git a/src/Java/gregtech/api/enums/TAE.java b/src/Java/gregtech/api/enums/TAE.java
index 0abc5db38a..3ec018b3a1 100644
--- a/src/Java/gregtech/api/enums/TAE.java
+++ b/src/Java/gregtech/api/enums/TAE.java
@@ -4,7 +4,7 @@ import java.lang.reflect.Field;
import gregtech.api.interfaces.ITexture;
import gregtech.api.objects.GT_CopiedBlockTexture;
-
+import gtPlusPlus.api.objects.Logger;
import gtPlusPlus.core.lib.CORE;
import gtPlusPlus.core.util.Utils;
import gtPlusPlus.core.util.reflect.ReflectionUtils;
@@ -47,9 +47,9 @@ public class TAE {
}*/
public static boolean registerTextures(GT_CopiedBlockTexture gt_CopiedBlockTexture) {
- try {
-
+ try {
//Handle page 2.
+ Logger.INFO("[TAE} Registering Texture, Last used casing ID is "+gtPPLastUsedIndex+".");
if (gtPPLastUsedIndex >= 128) {
if (CORE.MAIN_GREGTECH_5U_EXPERIMENTAL_FORK && Utils.getGregtechSubVersion() > 30) {
Field x = ReflectionUtils.getField(Textures.BlockIcons.class, "casingTexturePages");
@@ -58,6 +58,7 @@ public class TAE {
if (h != null) {
h[64][secondaryIndex++] = gt_CopiedBlockTexture;
x.set(null, h);
+ Logger.INFO("[TAE} Registered Texture with ID "+(secondaryIndex-1)+" in secondary index.");
return true;
}
}
@@ -67,6 +68,7 @@ public class TAE {
//set to page 1.
else {
Textures.BlockIcons.CASING_BLOCKS[gtPPLastUsedIndex] = gt_CopiedBlockTexture;
+ Logger.INFO("[TAE} Registered Texture with ID "+(gtPPLastUsedIndex)+" in main index.");
gtPPLastUsedIndex++;
return true;
}
@@ -74,6 +76,7 @@ public class TAE {
catch (Throwable t) {
t.printStackTrace();
}
+ Logger.INFO("[TAE} Failed to register texture, Last used casing ID is "+gtPPLastUsedIndex+".");
return false;
}
diff --git a/src/Java/gtPlusPlus/xmod/gregtech/common/blocks/GregtechMetaCasingBlocks4.java b/src/Java/gtPlusPlus/xmod/gregtech/common/blocks/GregtechMetaCasingBlocks4.java
index 30bee6a84c..e6a228b854 100644
--- a/src/Java/gtPlusPlus/xmod/gregtech/common/blocks/GregtechMetaCasingBlocks4.java
+++ b/src/Java/gtPlusPlus/xmod/gregtech/common/blocks/GregtechMetaCasingBlocks4.java
@@ -21,9 +21,9 @@ extends GregtechMetaCasingBlocksAbstract {
for (byte i = 0; i < 16; i = (byte) (i + 1)) {
TAE.registerTextures(new GT_CopiedBlockTexture(this, 6, i));
}
- GT_LanguageManager.addStringLocalization(this.getUnlocalizedName() + ".0.name", "Naquadah Reactor Base");
- GT_LanguageManager.addStringLocalization(this.getUnlocalizedName() + ".1.name", "Naquadah Reactor Piping");
- GT_LanguageManager.addStringLocalization(this.getUnlocalizedName() + ".2.name", "Naquadah Reactor Containment");
+ GT_LanguageManager.addStringLocalization(this.getUnlocalizedName() + ".0.name", "Naquadah Reactor Base"); //48
+ GT_LanguageManager.addStringLocalization(this.getUnlocalizedName() + ".1.name", "Reactor Piping");
+ GT_LanguageManager.addStringLocalization(this.getUnlocalizedName() + ".2.name", "Naquadah Containment Chamber");
GT_LanguageManager.addStringLocalization(this.getUnlocalizedName() + ".3.name", "");
GT_LanguageManager.addStringLocalization(this.getUnlocalizedName() + ".4.name", "");
GT_LanguageManager.addStringLocalization(this.getUnlocalizedName() + ".5.name", "");
@@ -61,16 +61,16 @@ extends GregtechMetaCasingBlocksAbstract {
switch (aMeta) {
//Centrifuge
case 0:
- return TexturesGtBlock.TEXTURE_ORGANIC_PANEL_A.getIcon();
+ return TexturesGtBlock.TEXTURE_METAL_PANEL_E.getIcon();
//Coke Oven Frame
case 1:
return TexturesGtBlock.TEXTURE_TECH_C.getIcon();
//Coke Oven Casing Tier 1
case 2:
- return TexturesGtBlock.TEXTURE_METAL_PANEL_E.getIcon();
+ return TexturesGtBlock.TEXTURE_ORGANIC_PANEL_A.getIcon();
//Coke Oven Casing Tier 2
case 3:
- return TexturesGtBlock.Casing_Material_Fluid_IncoloyDS.getIcon();
+ return TexturesGtBlock.Casing_Material_Grisium.getIcon();
//Material Press Casings
case 4:
return TexturesGtBlock.Casing_Material_Grisium.getIcon();
diff --git a/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/production/GregtechMTE_LargeNaqReactor.java b/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/production/GregtechMTE_LargeNaqReactor.java
index a6b4d48333..959bfe5338 100644
--- a/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/production/GregtechMTE_LargeNaqReactor.java
+++ b/src/Java/gtPlusPlus/xmod/gregtech/common/tileentities/machines/multi/production/GregtechMTE_LargeNaqReactor.java
@@ -1,6 +1,7 @@
package gtPlusPlus.xmod.gregtech.common.tileentities.machines.multi.production;
import gregtech.api.GregTech_API;
+import gregtech.api.enums.TAE;
import gregtech.api.enums.Textures.BlockIcons;
import gregtech.api.gui.GT_GUIContainer_MultiMachine;
import gregtech.api.interfaces.ITexture;
@@ -9,11 +10,15 @@ import gregtech.api.interfaces.tileentity.IGregTechTileEntity;
import gregtech.api.metatileentity.implementations.GT_MetaTileEntity_Hatch;
import gregtech.api.objects.GT_RenderedTexture;
import gregtech.api.util.GT_Utility;
+import gtPlusPlus.core.block.ModBlocks;
+import gtPlusPlus.core.lib.CORE;
import gtPlusPlus.xmod.gregtech.api.metatileentity.implementations.GT_MetaTileEntity_Hatch_Naquadah;
import gtPlusPlus.xmod.gregtech.api.metatileentity.implementations.base.GregtechMeta_MultiBlockBase;
import gtPlusPlus.xmod.gregtech.common.blocks.textures.TexturesGtBlock;
import gregtech.api.util.GT_Recipe.GT_Recipe_Map;
import java.util.ArrayList;
+
+import net.minecraft.block.Block;
import net.minecraft.entity.player.InventoryPlayer;
import net.minecraft.item.ItemStack;
import net.minecraftforge.common.util.ForgeDirection;
@@ -46,17 +51,21 @@ public class GregtechMTE_LargeNaqReactor extends GregtechMeta_MultiBlockBase {
" Grate Machine Casing (or Controller or Data Access Hatch)",
"Top: Steel Casing(or Energy Hatch)",
"Up to 16 repeating slices, last is Output Bus",
- "Optional 1x Data Access Hatch next to the Controller"};
+ "Optional 1x Data Access Hatch next to the Controller",
+ getPollutionTooltip(),
+ getMachineTooltip(),
+ CORE.GT_Tooltip
+ };
}
public ITexture[] getTexture(IGregTechTileEntity aBaseMetaTileEntity, byte aSide, byte aFacing, byte aColorIndex,
boolean aActive, boolean aRedstone) {
return aSide == aFacing
- ? new ITexture[]{BlockIcons.CASING_BLOCKS[16],
+ ? new ITexture[]{BlockIcons.CASING_BLOCKS[TAE.getIndexFromPage(3, 0)],
new GT_RenderedTexture(aActive
? TexturesGtBlock.Overlay_Machine_Controller_Default_Active
: TexturesGtBlock.Overlay_Machine_Controller_Default)}
- : new ITexture[]{BlockIcons.CASING_BLOCKS[16]};
+ : new ITexture[]{BlockIcons.CASING_BLOCKS[TAE.getIndexFromPage(3, 0)]};
}
public Object getClientGUI(int aID, InventoryPlayer aPlayerInventory, IGregTechTileEntity aBaseMetaTileEntity) {
@@ -86,8 +95,17 @@ public class GregtechMTE_LargeNaqReactor extends GregtechMeta_MultiBlockBase {
GT_Utility.doSoundAtClient((String) GregTech_API.sSoundList.get(Integer.valueOf(212)), 10, 1.0F, aX, aY,
aZ);
}
-
}
+
+ private Block getCasing(int casingID) {
+ return ModBlocks.blockCasings4Misc;
+ }
+
+ //Casing3, Meta 10 - "Grate Machine Casing");
+ //Casing2, Meta 0 - "Solid Steel Machine Casing"
+ //Casing2, Meta 5 - "Assembling Line Casing"
+ //Casing2, Meta 9 - "Assembler Machine Casing"
+ //Magic Glass - blockAlloyGlass
public boolean checkMachine(IGregTechTileEntity aBaseMetaTileEntity, ItemStack aStack) {
int xDir = ForgeDirection.getOrientation(aBaseMetaTileEntity.getBackFacing()).offsetX;
@@ -102,7 +120,7 @@ public class GregtechMTE_LargeNaqReactor extends GregtechMeta_MultiBlockBase {
if (i != 0
&& (aBaseMetaTileEntity.getBlockOffset(0, 0, i) != GregTech_API.sBlockCasings3
|| aBaseMetaTileEntity.getMetaIDOffset(0, 0, i) != 10)
- && r == 1 && !this.addNaquadahHatchToMachineInput(tTileEntity, 16)) {
+ && r == 1 && !this.addNaquadahHatchToMachineInput(tTileEntity, TAE.getIndexFromPage(3, 0))) {
return false;
}
@@ -111,9 +129,9 @@ public class GregtechMTE_LargeNaqReactor extends GregtechMeta_MultiBlockBase {
}
tTileEntity = aBaseMetaTileEntity.getIGregTechTileEntityOffset(0, -2, i);
- if (!this.addMaintenanceToMachineList(tTileEntity, 16)
- && !this.addInputToMachineList(tTileEntity, 16)) {
- if (aBaseMetaTileEntity.getBlockOffset(0, -2, i) != GregTech_API.sBlockCasings2) {
+ if (!this.addMaintenanceToMachineList(tTileEntity, TAE.getIndexFromPage(3, 0))
+ && !this.addInputToMachineList(tTileEntity, TAE.getIndexFromPage(3, 0))) {
+ if (aBaseMetaTileEntity.getBlockOffset(0, -2, i) != ModBlocks.blockCasings4Misc) {
return false;
}
@@ -123,8 +141,8 @@ public class GregtechMTE_LargeNaqReactor extends GregtechMeta_MultiBlockBase {
}
tTileEntity = aBaseMetaTileEntity.getIGregTechTileEntityOffset(xDir, 1, i);
- if (!this.addEnergyInputToMachineList(tTileEntity, 16)) {
- if (aBaseMetaTileEntity.getBlockOffset(xDir, 1, i) != GregTech_API.sBlockCasings2) {
+ if (!this.addEnergyInputToMachineList(tTileEntity, TAE.getIndexFromPage(3, 0))) {
+ if (aBaseMetaTileEntity.getBlockOffset(xDir, 1, i) != ModBlocks.blockCasings4Misc) {
return false;
}
@@ -133,13 +151,13 @@ public class GregtechMTE_LargeNaqReactor extends GregtechMeta_MultiBlockBase {
}
}
- if (i != 0 && (aBaseMetaTileEntity.getBlockOffset(xDir, 0, i) != GregTech_API.sBlockCasings2
- || aBaseMetaTileEntity.getMetaIDOffset(xDir, 0, i) != 9)) {
+ if (i != 0 && (aBaseMetaTileEntity.getBlockOffset(xDir, 0, i) != ModBlocks.blockCasings4Misc
+ || aBaseMetaTileEntity.getMetaIDOffset(xDir, 0, i) != 1)) {
return false;
}
- if (i != 0 && (aBaseMetaTileEntity.getBlockOffset(xDir, -1, i) != GregTech_API.sBlockCasings2
- || aBaseMetaTileEntity.getMetaIDOffset(xDir, -1, i) != 5)) {
+ if (i != 0 && (aBaseMetaTileEntity.getBlockOffset(xDir, -1, i) != ModBlocks.blockCasings4Misc
+ || aBaseMetaTileEntity.getMetaIDOffset(xDir, -1, i) != 2)) {
return false;
}
@@ -154,9 +172,9 @@ public class GregtechMTE_LargeNaqReactor extends GregtechMeta_MultiBlockBase {
}
tTileEntity = aBaseMetaTileEntity.getIGregTechTileEntityOffset(xDir * 2, -2, i);
- if (!this.addMaintenanceToMachineList(tTileEntity, 16)
- && !this.addInputToMachineList(tTileEntity, 16)) {
- if (aBaseMetaTileEntity.getBlockOffset(xDir * 2, -2, i) != GregTech_API.sBlockCasings2) {
+ if (!this.addMaintenanceToMachineList(tTileEntity, TAE.getIndexFromPage(3, 0))
+ && !this.addInputToMachineList(tTileEntity, TAE.getIndexFromPage(3, 0))) {
+ if (aBaseMetaTileEntity.getBlockOffset(xDir * 2, -2, i) != ModBlocks.blockCasings4Misc) {
return false;
}
@@ -166,7 +184,7 @@ public class GregtechMTE_LargeNaqReactor extends GregtechMeta_MultiBlockBase {
}
tTileEntity = aBaseMetaTileEntity.getIGregTechTileEntityOffset(xDir, -2, i);
- if (!this.addInputToMachineList(tTileEntity, 16) && this.addOutputToMachineList(tTileEntity, 16)) {
+ if (!this.addInputToMachineList(tTileEntity, TAE.getIndexFromPage(3, 0)) && this.addOutputToMachineList(tTileEntity, TAE.getIndexFromPage(3, 0))) {
return r > 0 && this.mEnergyHatches.size() > 0;
}
}
@@ -177,7 +195,7 @@ public class GregtechMTE_LargeNaqReactor extends GregtechMeta_MultiBlockBase {
if (i != 0
&& (aBaseMetaTileEntity.getBlockOffset(i, 0, 0) != GregTech_API.sBlockCasings3
|| aBaseMetaTileEntity.getMetaIDOffset(i, 0, 0) != 10)
- && r == 1 && !this.addNaquadahHatchToMachineInput(tTileEntity, 16)) {
+ && r == 1 && !this.addNaquadahHatchToMachineInput(tTileEntity, TAE.getIndexFromPage(3, 0))) {
return false;
}
@@ -186,9 +204,9 @@ public class GregtechMTE_LargeNaqReactor extends GregtechMeta_MultiBlockBase {
}
tTileEntity = aBaseMetaTileEntity.getIGregTechTileEntityOffset(i, -2, 0);
- if (!this.addMaintenanceToMachineList(tTileEntity, 16)
- && !this.addInputToMachineList(tTileEntity, 16)) {
- if (aBaseMetaTileEntity.getBlockOffset(i, -2, 0) != GregTech_API.sBlockCasings2) {
+ if (!this.addMaintenanceToMachineList(tTileEntity, TAE.getIndexFromPage(3, 0))
+ && !this.addInputToMachineList(tTileEntity, TAE.getIndexFromPage(3, 0))) {
+ if (aBaseMetaTileEntity.getBlockOffset(i, -2, 0) != ModBlocks.blockCasings4Misc) {
return false;
}
@@ -198,8 +216,8 @@ public class GregtechMTE_LargeNaqReactor extends GregtechMeta_MultiBlockBase {
}
tTileEntity = aBaseMetaTileEntity.getIGregTechTileEntityOffset(i, 1, zDir);
- if (!this.addEnergyInputToMachineList(tTileEntity, 16)) {
- if (aBaseMetaTileEntity.getBlockOffset(i, 1, zDir) != GregTech_API.sBlockCasings2) {
+ if (!this.addEnergyInputToMachineList(tTileEntity, TAE.getIndexFromPage(3, 0))) {
+ if (aBaseMetaTileEntity.getBlockOffset(i, 1, zDir) != ModBlocks.blockCasings4Misc) {
return false;
}
@@ -208,13 +226,13 @@ public class GregtechMTE_LargeNaqReactor extends GregtechMeta_MultiBlockBase {
}
}
- if (i != 0 && (aBaseMetaTileEntity.getBlockOffset(i, 0, zDir) != GregTech_API.sBlockCasings2
- || aBaseMetaTileEntity.getMetaIDOffset(i, 0, zDir) != 9)) {
+ if (i != 0 && (aBaseMetaTileEntity.getBlockOffset(i, 0, zDir) != ModBlocks.blockCasings4Misc
+ || aBaseMetaTileEntity.getMetaIDOffset(i, 0, zDir) != 1)) {
return false;
}
- if (i != 0 && (aBaseMetaTileEntity.getBlockOffset(i, -1, zDir) != GregTech_API.sBlockCasings2
- || aBaseMetaTileEntity.getMetaIDOffset(i, -1, zDir) != 5)) {
+ if (i != 0 && (aBaseMetaTileEntity.getBlockOffset(i, -1, zDir) != ModBlocks.blockCasings4Misc
+ || aBaseMetaTileEntity.getMetaIDOffset(i, -1, zDir) != 2)) {
return false;
}
@@ -229,9 +247,9 @@ public class GregtechMTE_LargeNaqReactor extends GregtechMeta_MultiBlockBase {
}
tTileEntity = aBaseMetaTileEntity.getIGregTechTileEntityOffset(i, -2, zDir * 2);
- if (!this.addMaintenanceToMachineList(tTileEntity, 16)
- && !this.addInputToMachineList(tTileEntity, 16)) {
- if (aBaseMetaTileEntity.getBlockOffset(i, -2, zDir * 2) != GregTech_API.sBlockCasings2) {
+ if (!this.addMaintenanceToMachineList(tTileEntity, TAE.getIndexFromPage(3, 0))
+ && !this.addInputToMachineList(tTileEntity, TAE.getIndexFromPage(3, 0))) {
+ if (aBaseMetaTileEntity.getBlockOffset(i, -2, zDir * 2) != ModBlocks.blockCasings4Misc) {
return false;
}
@@ -241,7 +259,7 @@ public class GregtechMTE_LargeNaqReactor extends GregtechMeta_MultiBlockBase {
}
tTileEntity = aBaseMetaTileEntity.getIGregTechTileEntityOffset(i, -2, zDir);
- if (!this.addInputToMachineList(tTileEntity, 16) && this.addOutputToMachineList(tTileEntity, 16)) {
+ if (!this.addInputToMachineList(tTileEntity, TAE.getIndexFromPage(3, 0)) && this.addOutputToMachineList(tTileEntity, TAE.getIndexFromPage(3, 0))) {
return r > 0 && this.mEnergyHatches.size() > 0;
}
}
diff --git a/src/Java/gtPlusPlus/xmod/gregtech/registration/gregtech/GregtechNaqReactor.java b/src/Java/gtPlusPlus/xmod/gregtech/registration/gregtech/GregtechNaqReactor.java
index 484737471e..a28084e1da 100644
--- a/src/Java/gtPlusPlus/xmod/gregtech/registration/gregtech/GregtechNaqReactor.java
+++ b/src/Java/gtPlusPlus/xmod/gregtech/registration/gregtech/GregtechNaqReactor.java
@@ -16,7 +16,7 @@ public class GregtechNaqReactor {
private static void run1() {
// LFTR
- GregtechItemList.Controller_Naq_Reactor.set(new GregtechMTE_LargeNaqReactor(991, "lnr.controller.single", "Large Naquadah Reactor").getStackForm(1L));
+ GregtechItemList.Controller_Naq_Reactor.set(new GregtechMTE_LargeNaqReactor(970, "lnr.controller.single", "Large Naquadah Reactor").getStackForm(1L));
}
}