diff options
author | miozune <miozune@gmail.com> | 2023-10-17 14:07:27 +0900 |
---|---|---|
committer | miozune <miozune@gmail.com> | 2023-10-17 17:39:55 +0900 |
commit | f5fd50a92b3ca258122ba85735883399374db678 (patch) | |
tree | a8b9eb508b9a4b5f1cf96f9215785959fbeb2ed9 /src/main/java/gtPlusPlus/core/item | |
parent | 144b09fe97a89fc9033fd5ec6be899adcefc2046 (diff) | |
download | GT5-Unofficial-f5fd50a92b3ca258122ba85735883399374db678.tar.gz GT5-Unofficial-f5fd50a92b3ca258122ba85735883399374db678.tar.bz2 GT5-Unofficial-f5fd50a92b3ca258122ba85735883399374db678.zip |
Remove BaseItemDustEx which is never updated
Diffstat (limited to 'src/main/java/gtPlusPlus/core/item')
-rw-r--r-- | src/main/java/gtPlusPlus/core/item/base/dusts/BaseItemDustEx.java | 127 |
1 files changed, 0 insertions, 127 deletions
diff --git a/src/main/java/gtPlusPlus/core/item/base/dusts/BaseItemDustEx.java b/src/main/java/gtPlusPlus/core/item/base/dusts/BaseItemDustEx.java deleted file mode 100644 index 13dacd065d..0000000000 --- a/src/main/java/gtPlusPlus/core/item/base/dusts/BaseItemDustEx.java +++ /dev/null @@ -1,127 +0,0 @@ -package gtPlusPlus.core.item.base.dusts; - -import static gregtech.api.enums.Mods.GTPlusPlus; -import static gregtech.api.enums.Mods.GregTech; - -import java.util.HashMap; -import java.util.List; -import java.util.Map; - -import net.minecraft.client.renderer.texture.IIconRegister; -import net.minecraft.creativetab.CreativeTabs; -import net.minecraft.item.Item; -import net.minecraft.item.ItemStack; -import net.minecraft.util.IIcon; - -import org.apache.commons.lang3.StringUtils; - -import gregtech.api.enums.TextureSet; -import gregtech.api.util.GT_OreDictUnificator; -import gtPlusPlus.core.item.base.BaseItemComponent; -import gtPlusPlus.core.lib.CORE; -import gtPlusPlus.core.material.Material; -import gtPlusPlus.core.util.minecraft.ItemUtils; - -public class BaseItemDustEx extends BaseItemComponent { - - public static Map<String, String> mCachedPileLinkages = new HashMap<String, String>(); - - protected IIcon[] baseAr = new IIcon[3]; - protected IIcon[] overlayAr = new IIcon[3]; - public static final ComponentTypes[] componentTypeAr = new ComponentTypes[] { ComponentTypes.DUST, - ComponentTypes.DUSTSMALL, ComponentTypes.DUSTTINY }; - - public BaseItemDustEx(final Material material) { - super(material, componentTypeAr[0]); - // OreDict this beauty - GT_OreDictUnificator.registerOre( - componentTypeAr[0].getOreDictName() + material.getUnlocalizedName(), - ItemUtils.simpleMetaStack(this, 0, 1)); - GT_OreDictUnificator.registerOre( - componentTypeAr[1].getOreDictName() + material.getUnlocalizedName(), - ItemUtils.simpleMetaStack(this, 0, 1)); - GT_OreDictUnificator.registerOre( - componentTypeAr[2].getOreDictName() + material.getUnlocalizedName(), - ItemUtils.simpleMetaStack(this, 0, 1)); - bakeRegistry(); - } - - private void bakeRegistry() { - String unlocalName = getUnlocalizedName(); - if (unlocalName.contains("item.")) { - unlocalName = StringUtils.remove(unlocalName, "item."); - } - if (unlocalName.contains("itemDust")) { - unlocalName = StringUtils.remove(unlocalName, "itemDust"); - } - mCachedPileLinkages.put(this.getUnlocalizedName(), "itemDust" + unlocalName); - mCachedPileLinkages.put(this.getUnlocalizedName(), "itemDustSmall" + unlocalName); - mCachedPileLinkages.put(this.getUnlocalizedName(), "itemDustTiny" + unlocalName); - } - - @Override - public void getSubItems(Item item, CreativeTabs tab, List list) { - for (int i = 0; i < 3; i++) { - list.add(new ItemStack(item, 1, i)); - } - } - - @Override - public IIcon getIconFromDamageForRenderPass(int meta, int pass) { - if (CORE.ConfigSwitches.useGregtechTextures) { - if (meta == 0) { - if (pass == 0) { - return this.baseAr[0]; - } else { - return this.overlayAr[0]; - } - } else if (meta == 1) { - if (pass == 0) { - return this.baseAr[1]; - } else { - return this.overlayAr[1]; - } - } else { - if (pass == 0) { - return this.baseAr[2]; - } else { - return this.overlayAr[2]; - } - } - } else { - return this.baseAr[meta]; - } - } - - @Override - public void registerIcons(final IIconRegister i) { - if (CORE.ConfigSwitches.useGregtechTextures) { - this.baseAr[0] = i.registerIcon(getCorrectTextures()); - this.overlayAr[0] = i.registerIcon(getCorrectTextures() + "_OVERLAY"); - this.baseAr[1] = i.registerIcon(getCorrectTextures() + "Small"); - this.overlayAr[1] = i.registerIcon(getCorrectTextures() + "Small_OVERLAY"); - this.baseAr[2] = i.registerIcon(getCorrectTextures() + "Tiny"); - this.overlayAr[2] = i.registerIcon(getCorrectTextures() + "Tiny_OVERLAY"); - } else { - this.baseAr[0] = i.registerIcon(getCorrectTextures()); - this.baseAr[1] = i.registerIcon(getCorrectTextures() + "Small"); - this.baseAr[2] = i.registerIcon(getCorrectTextures() + "Tiny"); - } - } - - @Override - public String getCorrectTextures() { - if (!CORE.ConfigSwitches.useGregtechTextures) { - return GTPlusPlus.ID + ":" + "item" + this.componentType.getComponent(); - } - String metType = "9j4852jyo3rjmh3owlhw9oe"; - if (this.componentMaterial != null) { - TextureSet u = this.componentMaterial.getTextureSet(); - if (u != null) { - metType = u.mSetName; - } - } - metType = (metType.equals("9j4852jyo3rjmh3owlhw9oe") ? "METALLIC" : metType); - return GregTech.ID + ":" + "materialicons/" + metType + "/" + this.componentType.getOreDictName(); - } -} |