From 3d6ed92e7fc475976192e39a6bd45d99c79eee2a Mon Sep 17 00:00:00 2001 From: KryptonCaptain Date: Mon, 10 Jul 2017 21:40:53 +1000 Subject: [PATCH] Armour buffs Ichor armour buffed to 5% discount (Not sure if I did this already). Awakened to 6% discount. Ichor armour given Warping 3 Added IRunicArmor to Ichor gear and Thaumium helm of revealing. Why this took 2 years and a forked build to implement is beyond me --- build.properties | 2 +- .../common/item/ItemRevealingHelm.java | 10 ++++++- .../common/item/kami/armor/ItemGemHelm.java | 27 +++++++------------ .../common/item/kami/armor/ItemGemLegs.java | 3 +-- .../item/kami/armor/ItemIchorclothArmor.java | 14 +++++++++- .../kami/armor/ItemIchorclothArmorAdv.java | 7 +++++ 6 files changed, 40 insertions(+), 23 deletions(-) diff --git a/build.properties b/build.properties index d82b9cd5e..effee2498 100644 --- a/build.properties +++ b/build.properties @@ -1,5 +1,5 @@ #Thu, 30 Jan 2014 18:26:58 +0000 -version=2.5-551-K +version=2.5-552-K build_number=0 mc_version=1.7.10 mod_name=ThaumicTinkerer-[1.7.10] diff --git a/src/main/java/thaumic/tinkerer/common/item/ItemRevealingHelm.java b/src/main/java/thaumic/tinkerer/common/item/ItemRevealingHelm.java index b1bec6f84..9d35ec3e8 100644 --- a/src/main/java/thaumic/tinkerer/common/item/ItemRevealingHelm.java +++ b/src/main/java/thaumic/tinkerer/common/item/ItemRevealingHelm.java @@ -30,6 +30,7 @@ import net.minecraft.world.World; import thaumcraft.api.IGoggles; import thaumcraft.api.IRepairable; +import thaumcraft.api.IRunicArmor; import thaumcraft.api.IVisDiscountGear; import thaumcraft.api.ThaumcraftApi; import thaumcraft.api.aspects.Aspect; @@ -52,7 +53,7 @@ import java.util.ArrayList; import java.util.List; -public class ItemRevealingHelm extends ItemArmor implements IRepairable, IRevealer, IGoggles, IVisDiscountGear, ITTinkererItem { +public class ItemRevealingHelm extends ItemArmor implements IRepairable, IRevealer, IGoggles, IVisDiscountGear, IRunicArmor, ITTinkererItem { public ItemRevealingHelm() { super(ThaumcraftApi.armorMatThaumium, 2, 0); @@ -101,6 +102,11 @@ public boolean getIsRepairable(ItemStack par1ItemStack, ItemStack par2ItemStack) public int getVisDiscount(ItemStack Itemstack, EntityPlayer Player, Aspect Aspect) { return 5; } + + @Override + public int getRunicCharge(ItemStack arg0) { + return 0; + } @Override public ArrayList getSpecialParameters() { @@ -148,4 +154,6 @@ public boolean onItemUse(ItemStack p_77648_1_, EntityPlayer p_77648_2_, World p_ p_77648_2_.addChatComponentMessage(new ChatComponentText("Tile Entity: null")); return super.onItemUse(p_77648_1_, p_77648_2_, p_77648_3_, p_77648_4_, p_77648_5_, p_77648_6_, p_77648_7_, p_77648_8_, p_77648_9_, p_77648_10_); } + + } diff --git a/src/main/java/thaumic/tinkerer/common/item/kami/armor/ItemGemHelm.java b/src/main/java/thaumic/tinkerer/common/item/kami/armor/ItemGemHelm.java index 98152c746..8c0f3bf04 100644 --- a/src/main/java/thaumic/tinkerer/common/item/kami/armor/ItemGemHelm.java +++ b/src/main/java/thaumic/tinkerer/common/item/kami/armor/ItemGemHelm.java @@ -38,22 +38,19 @@ import thaumic.tinkerer.common.research.KamiResearchItem; import thaumic.tinkerer.common.research.ResearchHelper; -public class ItemGemHelm extends ItemIchorclothArmorAdv implements IGoggles, - IRevealer { +public class ItemGemHelm extends ItemIchorclothArmorAdv implements IGoggles, IRevealer { public ItemGemHelm() { super(0); } @Override - public boolean showNodes(ItemStack paramItemStack, - EntityLivingBase paramEntityLivingBase) { + public boolean showNodes(ItemStack paramItemStack, EntityLivingBase paramEntityLivingBase) { return true; } @Override - public boolean showIngamePopups(ItemStack paramItemStack, - EntityLivingBase paramEntityLivingBase) { + public boolean showIngamePopups(ItemStack paramItemStack, EntityLivingBase paramEntityLivingBase) { return true; } @@ -75,21 +72,18 @@ void tickPlayer(EntityPlayer player) { if (effect != null && effect.duration <= 202) effect.duration = 202; else - player.addPotionEffect(new PotionEffect(Potion.nightVision.id, - 202, 0, true)); + player.addPotionEffect(new PotionEffect(Potion.nightVision.id, 202, 0, true)); } if (player.isInsideOfMaterial(Material.lava) && ThaumicTinkerer.proxy.armorStatus(player) && armor.getItemDamage() == 0) { player.setAir(300); - PotionEffect effect = player - .getActivePotionEffect(Potion.blindness); + PotionEffect effect = player.getActivePotionEffect(Potion.blindness); if (effect != null && effect.duration <= 202) effect.duration = 202; else - player.addPotionEffect(new PotionEffect(Potion.blindness.id, - 202, 0, true)); + player.addPotionEffect(new PotionEffect(Potion.blindness.id, 202, 0, true)); } int food = player.getFoodStats().getFoodLevel(); if (food > 0 && food < 18 && player.shouldHeal() @@ -113,8 +107,7 @@ LibResearch.KEY_ICHORCLOTH_HELM_GEM, new AspectList() new ItemStack(this)).setParents( LibResearch.KEY_ICHORCLOTH_ARMOR).setPages( new ResearchPage("0"), - ResearchHelper - .infusionPage(LibResearch.KEY_ICHORCLOTH_HELM_GEM)); + ResearchHelper.infusionPage(LibResearch.KEY_ICHORCLOTH_HELM_GEM)); } @@ -127,10 +120,8 @@ LibResearch.KEY_ICHORCLOTH_HELM_GEM, new ItemStack(this), 13, .add(Aspect.LIGHT, 64).add(Aspect.FLESH, 16) .add(Aspect.MIND, 16), new ItemStack(ThaumicTinkerer.registry.getItemFromClassAndName(ItemIchorclothArmor.class, LibItemNames.ICHOR_HELM)), new ItemStack(Items.diamond, 1), - new ItemStack(ThaumicTinkerer.registry - .getFirstItemFromClass(ItemKamiResource.class)), - new ItemStack(ThaumicTinkerer.registry - .getFirstItemFromClass(ItemKamiResource.class)), + new ItemStack(ThaumicTinkerer.registry.getFirstItemFromClass(ItemKamiResource.class)), + new ItemStack(ThaumicTinkerer.registry.getFirstItemFromClass(ItemKamiResource.class)), new ItemStack(ConfigItems.itemThaumonomicon), new ItemStack( ConfigItems.itemFocusPrimal), new ItemStack( Items.golden_helmet), new ItemStack(Items.potionitem, diff --git a/src/main/java/thaumic/tinkerer/common/item/kami/armor/ItemGemLegs.java b/src/main/java/thaumic/tinkerer/common/item/kami/armor/ItemGemLegs.java index 3004aad21..2250ca225 100644 --- a/src/main/java/thaumic/tinkerer/common/item/kami/armor/ItemGemLegs.java +++ b/src/main/java/thaumic/tinkerer/common/item/kami/armor/ItemGemLegs.java @@ -62,8 +62,7 @@ void tickPlayer(EntityPlayer player) { if (effect != null && effect.duration <= 202) effect.duration = 202; else - player.addPotionEffect(new PotionEffect(Potion.fireResistance.id, - 202, 10, true)); + player.addPotionEffect(new PotionEffect(Potion.fireResistance.id, 202, 10, true)); ItemBrightNitor.meta = 1; ((ItemBrightNitor)ThaumicTinkerer.registry.getFirstItemFromClass(ItemBrightNitor.class)).onUpdate(null, player.worldObj, player, 0, false); ItemBrightNitor.meta = 0; diff --git a/src/main/java/thaumic/tinkerer/common/item/kami/armor/ItemIchorclothArmor.java b/src/main/java/thaumic/tinkerer/common/item/kami/armor/ItemIchorclothArmor.java index 915d636d2..8f77bf0bd 100644 --- a/src/main/java/thaumic/tinkerer/common/item/kami/armor/ItemIchorclothArmor.java +++ b/src/main/java/thaumic/tinkerer/common/item/kami/armor/ItemIchorclothArmor.java @@ -28,7 +28,9 @@ import net.minecraft.util.StatCollector; import net.minecraftforge.common.ISpecialArmor; import net.minecraftforge.common.util.EnumHelper; +import thaumcraft.api.IRunicArmor; import thaumcraft.api.IVisDiscountGear; +import thaumcraft.api.IWarpingGear; import thaumcraft.api.aspects.Aspect; import thaumcraft.api.aspects.AspectList; import thaumcraft.api.research.ResearchPage; @@ -51,7 +53,7 @@ import java.util.ArrayList; import java.util.List; -public class ItemIchorclothArmor extends ItemArmor implements IVisDiscountGear, ISpecialArmor, ITTinkererItem { +public class ItemIchorclothArmor extends ItemArmor implements IVisDiscountGear, ISpecialArmor, ITTinkererItem, IWarpingGear, IRunicArmor { static ItemArmor.ArmorMaterial material = EnumHelper.addArmorMaterial( "ICHOR", 0, new int[]{3, 8, 6, 3}, 20); @@ -213,4 +215,14 @@ LibResearch.KEY_ICHORCLOTH_ARMOR, new ItemStack(this), } return null; } + + @Override + public int getWarp(ItemStack arg0, EntityPlayer arg1) { + return 3; + } + + @Override + public int getRunicCharge(ItemStack arg0) { + return 0; + } } diff --git a/src/main/java/thaumic/tinkerer/common/item/kami/armor/ItemIchorclothArmorAdv.java b/src/main/java/thaumic/tinkerer/common/item/kami/armor/ItemIchorclothArmorAdv.java index eabad47d1..b6b7fc66f 100644 --- a/src/main/java/thaumic/tinkerer/common/item/kami/armor/ItemIchorclothArmorAdv.java +++ b/src/main/java/thaumic/tinkerer/common/item/kami/armor/ItemIchorclothArmorAdv.java @@ -22,6 +22,7 @@ import net.minecraft.world.World; import net.minecraftforge.common.MinecraftForge; import net.minecraftforge.event.entity.living.LivingEvent.LivingUpdateEvent; +import thaumcraft.api.aspects.Aspect; import thaumic.tinkerer.client.core.handler.kami.ToolModeHUDHandler; import thaumic.tinkerer.client.lib.LibResources; import thaumic.tinkerer.common.registry.ThaumicTinkererRecipe; @@ -74,6 +75,12 @@ public void addInformation(ItemStack stack, EntityPlayer par2EntityPlayer, List public String getArmorTexture(ItemStack stack, Entity entity, int slot, String type) { return slot == 2 ? LibResources.MODEL_ARMOR_ICHOR_GEM_2 : LibResources.MODEL_ARMOR_ICHOR_GEM_1; } + + @Override + public int getVisDiscount(ItemStack arg0, EntityPlayer arg1, Aspect arg2) { + return 6; + } + boolean ticks() { return false;