Change Revealing upgrade to follow other upgrades
Obtained the same way as before.
This commit is contained in:
parent
be0a93143d
commit
f613c00970
|
@ -132,7 +132,6 @@ public class Constants
|
||||||
public static final String WAILA_CONFIG_RITUAL = Mod.MODID + ".ritualController";
|
public static final String WAILA_CONFIG_RITUAL = Mod.MODID + ".ritualController";
|
||||||
public static final String WAILA_CONFIG_ARRAY = Mod.MODID + ".array";
|
public static final String WAILA_CONFIG_ARRAY = Mod.MODID + ".array";
|
||||||
|
|
||||||
public static final String THAUMCRAFT_HAS_GOGGLES = "hasGoggles";
|
|
||||||
public static final Item THAUMCRAFT_GOGGLES = GameRegistry.findItem("Thaumcraft", "goggles");
|
public static final Item THAUMCRAFT_GOGGLES = GameRegistry.findItem("Thaumcraft", "goggles");
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
@ -188,12 +188,6 @@ public class ItemLivingArmour extends ItemArmor implements ISpecialArmor, IRevea
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (this == ModItems.livingArmourHelmet)
|
|
||||||
{
|
|
||||||
if (stack.getTagCompound().getBoolean(Constants.Compat.THAUMCRAFT_HAS_GOGGLES))
|
|
||||||
tooltip.add(TextHelper.localizeEffect("tooltip.BloodMagic.livingArmour.hasGoggles"));
|
|
||||||
}
|
|
||||||
|
|
||||||
super.addInformation(stack, player, tooltip, advanced);
|
super.addInformation(stack, player, tooltip, advanced);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -326,16 +320,19 @@ public class ItemLivingArmour extends ItemArmor implements ISpecialArmor, IRevea
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean showIngamePopups(ItemStack stack, EntityLivingBase entityLivingBase)
|
public boolean showIngamePopups(ItemStack stack, EntityLivingBase entityLivingBase) {
|
||||||
{
|
|
||||||
stack = NBTHelper.checkNBT(stack);
|
stack = NBTHelper.checkNBT(stack);
|
||||||
return stack != null && stack.getItem() == ModItems.livingArmourHelmet && stack.getTagCompound().getBoolean(Constants.Compat.THAUMCRAFT_HAS_GOGGLES);
|
LivingArmour armor = getLivingArmour(stack);
|
||||||
|
|
||||||
|
return armor.upgradeMap.containsKey(Constants.Mod.MODID + ".upgrade.revealing") && LivingArmour.hasFullSet((EntityPlayer) entityLivingBase);
|
||||||
}
|
}
|
||||||
|
|
||||||
@Override
|
@Override
|
||||||
public boolean showNodes(ItemStack stack, EntityLivingBase entityLivingBase)
|
public boolean showNodes(ItemStack stack, EntityLivingBase entityLivingBase)
|
||||||
{
|
{
|
||||||
stack = NBTHelper.checkNBT(stack);
|
stack = NBTHelper.checkNBT(stack);
|
||||||
return stack != null && stack.getItem() == ModItems.livingArmourHelmet && stack.getTagCompound().getBoolean(Constants.Compat.THAUMCRAFT_HAS_GOGGLES);
|
LivingArmour armor = getLivingArmour(stack);
|
||||||
|
|
||||||
|
return armor.upgradeMap.containsKey(Constants.Mod.MODID + ".upgrade.revealing") && LivingArmour.hasFullSet((EntityPlayer) entityLivingBase);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -0,0 +1,42 @@
|
||||||
|
package WayofTime.bloodmagic.livingArmour.upgrade;
|
||||||
|
|
||||||
|
import WayofTime.bloodmagic.api.Constants;
|
||||||
|
import WayofTime.bloodmagic.api.livingArmour.LivingArmourUpgrade;
|
||||||
|
import net.minecraft.nbt.NBTTagCompound;
|
||||||
|
|
||||||
|
public class LivingArmourUpgradeRevealing extends LivingArmourUpgrade {
|
||||||
|
|
||||||
|
public LivingArmourUpgradeRevealing(int level) {
|
||||||
|
super(level);
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String getUniqueIdentifier() {
|
||||||
|
return Constants.Mod.MODID + ".upgrade.revealing";
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public String getUnlocalizedName() {
|
||||||
|
return tooltipBase + "revealing";
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int getMaxTier() {
|
||||||
|
return 1;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public int getCostOfUpgrade() {
|
||||||
|
return 5;
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void writeToNBT(NBTTagCompound tag) {
|
||||||
|
|
||||||
|
}
|
||||||
|
|
||||||
|
@Override
|
||||||
|
public void readFromNBT(NBTTagCompound tag) {
|
||||||
|
|
||||||
|
}
|
||||||
|
}
|
|
@ -11,17 +11,7 @@ import WayofTime.bloodmagic.livingArmour.tracker.StatTrackerMovement;
|
||||||
import WayofTime.bloodmagic.livingArmour.tracker.StatTrackerPhysicalProtect;
|
import WayofTime.bloodmagic.livingArmour.tracker.StatTrackerPhysicalProtect;
|
||||||
import WayofTime.bloodmagic.livingArmour.tracker.StatTrackerPoison;
|
import WayofTime.bloodmagic.livingArmour.tracker.StatTrackerPoison;
|
||||||
import WayofTime.bloodmagic.livingArmour.tracker.StatTrackerSelfSacrifice;
|
import WayofTime.bloodmagic.livingArmour.tracker.StatTrackerSelfSacrifice;
|
||||||
import WayofTime.bloodmagic.livingArmour.upgrade.LivingArmourUpgradeArrowShot;
|
import WayofTime.bloodmagic.livingArmour.upgrade.*;
|
||||||
import WayofTime.bloodmagic.livingArmour.upgrade.LivingArmourUpgradeDigging;
|
|
||||||
import WayofTime.bloodmagic.livingArmour.upgrade.LivingArmourUpgradeGrimReaperSprint;
|
|
||||||
import WayofTime.bloodmagic.livingArmour.upgrade.LivingArmourUpgradeHealthboost;
|
|
||||||
import WayofTime.bloodmagic.livingArmour.upgrade.LivingArmourUpgradeKnockbackResist;
|
|
||||||
import WayofTime.bloodmagic.livingArmour.upgrade.LivingArmourUpgradeMeleeDamage;
|
|
||||||
import WayofTime.bloodmagic.livingArmour.upgrade.LivingArmourUpgradePhysicalProtect;
|
|
||||||
import WayofTime.bloodmagic.livingArmour.upgrade.LivingArmourUpgradePoisonResist;
|
|
||||||
import WayofTime.bloodmagic.livingArmour.upgrade.LivingArmourUpgradeSelfSacrifice;
|
|
||||||
import WayofTime.bloodmagic.livingArmour.upgrade.LivingArmourUpgradeSpeed;
|
|
||||||
import WayofTime.bloodmagic.livingArmour.upgrade.LivingArmourUpgradeStepAssist;
|
|
||||||
|
|
||||||
public class ModArmourTrackers
|
public class ModArmourTrackers
|
||||||
{
|
{
|
||||||
|
@ -49,5 +39,6 @@ public class ModArmourTrackers
|
||||||
LivingArmourHandler.registerArmourUpgrade(new LivingArmourUpgradeArrowShot(0));
|
LivingArmourHandler.registerArmourUpgrade(new LivingArmourUpgradeArrowShot(0));
|
||||||
LivingArmourHandler.registerArmourUpgrade(new LivingArmourUpgradeStepAssist(0));
|
LivingArmourHandler.registerArmourUpgrade(new LivingArmourUpgradeStepAssist(0));
|
||||||
LivingArmourHandler.registerArmourUpgrade(new LivingArmourUpgradeGrimReaperSprint(0));
|
LivingArmourHandler.registerArmourUpgrade(new LivingArmourUpgradeGrimReaperSprint(0));
|
||||||
|
LivingArmourHandler.registerArmourUpgrade(new LivingArmourUpgradeRevealing(0));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,6 +3,8 @@ package WayofTime.bloodmagic.util.handler;
|
||||||
import java.util.List;
|
import java.util.List;
|
||||||
import java.util.Random;
|
import java.util.Random;
|
||||||
|
|
||||||
|
import WayofTime.bloodmagic.api.livingArmour.LivingArmourHandler;
|
||||||
|
import WayofTime.bloodmagic.item.ItemUpgradeTome;
|
||||||
import net.minecraft.block.Block;
|
import net.minecraft.block.Block;
|
||||||
import net.minecraft.enchantment.Enchantment;
|
import net.minecraft.enchantment.Enchantment;
|
||||||
import net.minecraft.enchantment.EnchantmentHelper;
|
import net.minecraft.enchantment.EnchantmentHelper;
|
||||||
|
@ -181,9 +183,10 @@ public class EventHandler
|
||||||
{
|
{
|
||||||
if (event.left.getItem() == ModItems.livingArmourHelmet && event.right.getItem() == Constants.Compat.THAUMCRAFT_GOGGLES && !event.right.isItemDamaged())
|
if (event.left.getItem() == ModItems.livingArmourHelmet && event.right.getItem() == Constants.Compat.THAUMCRAFT_GOGGLES && !event.right.isItemDamaged())
|
||||||
{
|
{
|
||||||
ItemStack output = event.left.copy();
|
ItemStack output = new ItemStack(ModItems.upgradeTome);
|
||||||
output = NBTHelper.checkNBT(output);
|
output = NBTHelper.checkNBT(output);
|
||||||
output.getTagCompound().setBoolean(Constants.Compat.THAUMCRAFT_HAS_GOGGLES, true);
|
((ItemUpgradeTome) output.getItem()).setKey(output, Constants.Mod.MODID + ".upgrade.revealing");
|
||||||
|
((ItemUpgradeTome) output.getItem()).setLevel(output, 1);
|
||||||
event.cost = 1;
|
event.cost = 1;
|
||||||
|
|
||||||
event.output = output;
|
event.output = output;
|
||||||
|
|
|
@ -282,8 +282,8 @@ tooltip.BloodMagic.livingArmour.upgrade.meleeDamage=Fierce Strike
|
||||||
tooltip.BloodMagic.livingArmour.upgrade.arrowShot=Trick Shot
|
tooltip.BloodMagic.livingArmour.upgrade.arrowShot=Trick Shot
|
||||||
tooltip.BloodMagic.livingArmour.upgrade.stepAssist=Step Assist
|
tooltip.BloodMagic.livingArmour.upgrade.stepAssist=Step Assist
|
||||||
tooltip.BloodMagic.livingArmour.upgrade.grimReaper=Grim Reaper's Sprint
|
tooltip.BloodMagic.livingArmour.upgrade.grimReaper=Grim Reaper's Sprint
|
||||||
|
tooltip.BloodMagic.livingArmour.upgrade.revealing=Revealing
|
||||||
tooltip.BloodMagic.livingArmour.upgrade.level=%s (Level %d)
|
tooltip.BloodMagic.livingArmour.upgrade.level=%s (Level %d)
|
||||||
tooltip.BloodMagic.livingArmour.hasGoggles=&oContains Goggles of Revealing
|
|
||||||
|
|
||||||
tooltip.BloodMagic.will=Will Quality: %1$,.2f
|
tooltip.BloodMagic.will=Will Quality: %1$,.2f
|
||||||
tooltip.BloodMagic.sentientSword.desc=Uses demon will to unleash its full potential.
|
tooltip.BloodMagic.sentientSword.desc=Uses demon will to unleash its full potential.
|
||||||
|
|
Loading…
Reference in a new issue