Removed the stat trackers for the downgrades and prevented downgrades from combining with each other in an anvil.
This commit is contained in:
parent
ed8427c04e
commit
f74f46ab4a
25 changed files with 122 additions and 742 deletions
|
@ -115,7 +115,7 @@ public class CraftingHandler
|
|||
if (event.getLeft().getItem() == ModItems.UPGRADE_TOME && event.getRight().getItem() == ModItems.UPGRADE_TOME)
|
||||
{
|
||||
LivingArmourUpgrade leftUpgrade = ItemHelper.LivingUpgrades.getUpgrade(event.getLeft());
|
||||
if (leftUpgrade != null && ItemHelper.LivingUpgrades.getKey(event.getLeft()).equals(ItemHelper.LivingUpgrades.getKey(event.getRight())))
|
||||
if (leftUpgrade != null && !leftUpgrade.isDowngrade() && ItemHelper.LivingUpgrades.getKey(event.getLeft()).equals(ItemHelper.LivingUpgrades.getKey(event.getRight())))
|
||||
{
|
||||
int leftLevel = ItemHelper.LivingUpgrades.getLevel(event.getLeft());
|
||||
int rightLevel = ItemHelper.LivingUpgrades.getLevel(event.getRight());
|
||||
|
|
|
@ -15,7 +15,6 @@ import net.minecraft.util.EnumHand;
|
|||
import net.minecraft.world.World;
|
||||
import net.minecraftforge.event.entity.EntityJoinWorldEvent;
|
||||
import net.minecraftforge.event.entity.living.LivingDeathEvent;
|
||||
import net.minecraftforge.event.entity.living.LivingEntityUseItemEvent;
|
||||
import net.minecraftforge.event.entity.living.LivingEvent;
|
||||
import net.minecraftforge.event.entity.player.ArrowLooseEvent;
|
||||
import net.minecraftforge.event.entity.player.PlayerEvent;
|
||||
|
@ -34,7 +33,6 @@ import WayofTime.bloodmagic.livingArmour.downgrade.LivingArmourUpgradeStormTroop
|
|||
import WayofTime.bloodmagic.livingArmour.tracker.StatTrackerArrowShot;
|
||||
import WayofTime.bloodmagic.livingArmour.tracker.StatTrackerGrimReaperSprint;
|
||||
import WayofTime.bloodmagic.livingArmour.tracker.StatTrackerJump;
|
||||
import WayofTime.bloodmagic.livingArmour.tracker.downgrade.StatTrackerQuenched;
|
||||
import WayofTime.bloodmagic.livingArmour.upgrade.LivingArmourUpgradeArrowShot;
|
||||
import WayofTime.bloodmagic.livingArmour.upgrade.LivingArmourUpgradeGrimReaperSprint;
|
||||
import WayofTime.bloodmagic.livingArmour.upgrade.LivingArmourUpgradeJump;
|
||||
|
@ -107,33 +105,6 @@ public class LivingArmourHandler
|
|||
}
|
||||
}
|
||||
|
||||
@SubscribeEvent
|
||||
public void onFinishedItem(LivingEntityUseItemEvent.Finish event)
|
||||
{
|
||||
if (event.getEntityLiving() instanceof EntityPlayer)
|
||||
{
|
||||
EntityPlayer player = (EntityPlayer) event.getEntityLiving();
|
||||
ItemStack heldStack = event.getItem();
|
||||
|
||||
if (heldStack != null && heldStack.getItemUseAction() == EnumAction.DRINK)
|
||||
{
|
||||
if (player.getItemInUseCount() <= 1)
|
||||
{
|
||||
if (LivingArmour.hasFullSet(player))
|
||||
{
|
||||
ItemStack chestStack = player.getItemStackFromSlot(EntityEquipmentSlot.CHEST);
|
||||
LivingArmour armour = ItemLivingArmour.getLivingArmour(chestStack);
|
||||
if (armour != null)
|
||||
{
|
||||
//Stat tracker~
|
||||
StatTrackerQuenched.incrementCounter(armour);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
@SubscribeEvent
|
||||
public void onPlayerClick(PlayerInteractEvent event)
|
||||
{
|
||||
|
|
|
@ -34,9 +34,6 @@ import WayofTime.bloodmagic.livingArmour.tracker.StatTrackerNightSight;
|
|||
import WayofTime.bloodmagic.livingArmour.tracker.StatTrackerPhysicalProtect;
|
||||
import WayofTime.bloodmagic.livingArmour.tracker.StatTrackerSolarPowered;
|
||||
import WayofTime.bloodmagic.livingArmour.tracker.StatTrackerSprintAttack;
|
||||
import WayofTime.bloodmagic.livingArmour.tracker.downgrade.StatTrackerBattleHungry;
|
||||
import WayofTime.bloodmagic.livingArmour.tracker.downgrade.StatTrackerDigSlowdown;
|
||||
import WayofTime.bloodmagic.livingArmour.tracker.downgrade.StatTrackerMeleeDecrease;
|
||||
import WayofTime.bloodmagic.livingArmour.upgrade.LivingArmourUpgradeDigging;
|
||||
import WayofTime.bloodmagic.livingArmour.upgrade.LivingArmourUpgradeExperience;
|
||||
import WayofTime.bloodmagic.util.Utils;
|
||||
|
@ -65,11 +62,6 @@ public class StatTrackerHandler
|
|||
{
|
||||
StatTrackerDigging.incrementCounter(armour);
|
||||
LivingArmourUpgradeDigging.hasDug(armour);
|
||||
|
||||
if (player.isPotionActive(MobEffects.MINING_FATIGUE))
|
||||
{
|
||||
StatTrackerDigSlowdown.incrementCounter(armour);
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
@ -170,12 +162,6 @@ public class StatTrackerHandler
|
|||
{
|
||||
StatTrackerMeleeDamage.incrementCounter(armour, amount);
|
||||
|
||||
if (player.isPotionActive(MobEffects.WEAKNESS))
|
||||
StatTrackerMeleeDecrease.incrementCounter(armour, amount);
|
||||
|
||||
if (player.isPotionActive(MobEffects.HUNGER))
|
||||
StatTrackerBattleHungry.incrementCounter(armour, amount);
|
||||
|
||||
if (player.worldObj.getLight(player.getPosition()) <= 9)
|
||||
StatTrackerNightSight.incrementCounter(armour, amount);
|
||||
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue