diff options
| author | miozune <miozune@gmail.com> | 2023-02-05 01:40:43 +0900 |
|---|---|---|
| committer | GitHub <noreply@github.com> | 2023-02-04 17:40:43 +0100 |
| commit | bb9da48b9975cb27e3b7c538bff2853a34b36fcd (patch) | |
| tree | 9de91abf611bf119935df6322e27805cf835fafc /src/main/java/gtPlusPlus/core/block | |
| parent | 8792eb5d9b70cbb1dc0b444cfd8524dfb4a0aa0c (diff) | |
| download | GT5-Unofficial-bb9da48b9975cb27e3b7c538bff2853a34b36fcd.tar.gz GT5-Unofficial-bb9da48b9975cb27e3b7c538bff2853a34b36fcd.tar.bz2 GT5-Unofficial-bb9da48b9975cb27e3b7c538bff2853a34b36fcd.zip | |
Remove redundant flags (#529)
* Remove CORE.GTNH
* Remove LoadedMods.Gregtech
* Remove LoadedMods.IndustrialCraft2
* Remove LoadedMods.MiscUtils
* Remove CORE.MAIN_GREGTECH_5U_EXPERIMENTAL_FORK
* clean
* Remove mention to GT versions
* Fix assembler mode
Diffstat (limited to 'src/main/java/gtPlusPlus/core/block')
| -rw-r--r-- | src/main/java/gtPlusPlus/core/block/base/BlockBaseOre.java | 49 |
1 files changed, 18 insertions, 31 deletions
diff --git a/src/main/java/gtPlusPlus/core/block/base/BlockBaseOre.java b/src/main/java/gtPlusPlus/core/block/base/BlockBaseOre.java index c8c0f4ca08..140773f4ea 100644 --- a/src/main/java/gtPlusPlus/core/block/base/BlockBaseOre.java +++ b/src/main/java/gtPlusPlus/core/block/base/BlockBaseOre.java @@ -18,7 +18,6 @@ import gregtech.api.util.GT_OreDictUnificator; import gtPlusPlus.api.interfaces.ITexturedBlock; import gtPlusPlus.core.client.renderer.CustomOreBlockRenderer; import gtPlusPlus.core.item.base.itemblock.ItemBlockOre; -import gtPlusPlus.core.lib.CORE; import gtPlusPlus.core.material.Material; import gtPlusPlus.core.util.Utils; import gtPlusPlus.core.util.minecraft.ItemUtils; @@ -106,26 +105,20 @@ public class BlockBaseOre extends BasicBlock implements ITexturedBlock { GTPP_RenderedTexture aIconSet = new GTPP_RenderedTexture( blockMaterial.getTextureSet().mTextures[OrePrefixes.ore.mTextureIndex], this.blockMaterial.getRGBA()); - if (aIconSet != null) { - return new ITexture[] { new GTPP_CopiedBlockTexture(Blocks.stone, 0, 0), aIconSet }; - } + return new ITexture[] { new GTPP_CopiedBlockTexture(Blocks.stone, 0, 0), aIconSet }; } if (hiddenTextureArray == null) { - if (!CORE.MAIN_GREGTECH_5U_EXPERIMENTAL_FORK) { - hiddenTextureArray = Textures.BlockIcons.GRANITES; - } else { - try { - Field o = ReflectionUtils.getField(Textures.BlockIcons.class, "STONES"); - if (o != null) { - hiddenTextureArray = (IIconContainer[]) o.get(Textures.BlockIcons.class); - } - if (hiddenTextureArray == null) { - hiddenTextureArray = new IIconContainer[6]; - } - } catch (IllegalArgumentException | IllegalAccessException e) { + try { + Field o = ReflectionUtils.getField(Textures.BlockIcons.class, "STONES"); + if (o != null) { + hiddenTextureArray = (IIconContainer[]) o.get(Textures.BlockIcons.class); + } + if (hiddenTextureArray == null) { hiddenTextureArray = new IIconContainer[6]; } + } catch (IllegalArgumentException | IllegalAccessException e) { + hiddenTextureArray = new IIconContainer[6]; } } return new ITexture[] { new GTPP_RenderedTexture(hiddenTextureArray[0], new short[] { 240, 240, 240, 0 }) }; @@ -200,26 +193,20 @@ public class BlockBaseOre extends BasicBlock implements ITexturedBlock { GTPP_RenderedTexture aIconSet = new GTPP_RenderedTexture( blockMaterial.getTextureSet().mTextures[OrePrefixes.ore.mTextureIndex], this.blockMaterial.getRGBA()); - if (aIconSet != null) { - return new ITexture[] { new GTPP_CopiedBlockTexture(Blocks.stone, 0, 0), aIconSet }; - } + return new ITexture[] { new GTPP_CopiedBlockTexture(Blocks.stone, 0, 0), aIconSet }; } if (hiddenTextureArray == null) { - if (!CORE.MAIN_GREGTECH_5U_EXPERIMENTAL_FORK) { - hiddenTextureArray = Textures.BlockIcons.GRANITES; - } else { - try { - Field o = ReflectionUtils.getField(Textures.BlockIcons.class, "STONES"); - if (o != null) { - hiddenTextureArray = (IIconContainer[]) o.get(Textures.BlockIcons.class); - } - if (hiddenTextureArray == null) { - hiddenTextureArray = new IIconContainer[6]; - } - } catch (IllegalArgumentException | IllegalAccessException e) { + try { + Field o = ReflectionUtils.getField(Textures.BlockIcons.class, "STONES"); + if (o != null) { + hiddenTextureArray = (IIconContainer[]) o.get(Textures.BlockIcons.class); + } + if (hiddenTextureArray == null) { hiddenTextureArray = new IIconContainer[6]; } + } catch (IllegalArgumentException | IllegalAccessException e) { + hiddenTextureArray = new IIconContainer[6]; } } return new ITexture[] { new GTPP_RenderedTexture(hiddenTextureArray[0], new short[] { 240, 240, 240, 0 }) }; |
