That's one heck of a commit you've got there...
I may have got a bit behind with version control. A lot behind, in fact. Maybe I'll go back and split this sometime - then again, I probably won't. But hey, at least it's here!
This commit is contained in:
@@ -1,22 +1,28 @@
|
||||
package electroblob.wizardry.spell;
|
||||
|
||||
import electroblob.wizardry.constants.Element;
|
||||
import electroblob.wizardry.constants.SpellType;
|
||||
import electroblob.wizardry.constants.Tier;
|
||||
import com.google.common.collect.ImmutableMap;
|
||||
import electroblob.wizardry.item.IConjuredItem;
|
||||
import electroblob.wizardry.registry.WizardryItems;
|
||||
import electroblob.wizardry.registry.WizardrySounds;
|
||||
import electroblob.wizardry.util.SpellModifiers;
|
||||
import electroblob.wizardry.util.WizardryUtilities;
|
||||
import net.minecraft.entity.player.EntityPlayer;
|
||||
import net.minecraft.inventory.EntityEquipmentSlot;
|
||||
import net.minecraft.item.Item;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.NBTTagList;
|
||||
|
||||
import java.util.Map;
|
||||
|
||||
public class ConjureArmour extends SpellConjuration {
|
||||
|
||||
private static final Map<EntityEquipmentSlot, Item> SPECTRAL_ARMOUR_MAP = ImmutableMap.of(
|
||||
EntityEquipmentSlot.HEAD, WizardryItems.spectral_helmet,
|
||||
EntityEquipmentSlot.CHEST, WizardryItems.spectral_chestplate,
|
||||
EntityEquipmentSlot.LEGS, WizardryItems.spectral_leggings,
|
||||
EntityEquipmentSlot.FEET, WizardryItems.spectral_boots);
|
||||
|
||||
public ConjureArmour(){
|
||||
super("conjure_armour", Tier.ADVANCED, Element.HEALING, SpellType.DEFENCE, 45, 50, null, WizardrySounds.SPELL_CONJURATION);
|
||||
super("conjure_armour", null);
|
||||
}
|
||||
|
||||
@Override
|
||||
@@ -29,9 +35,9 @@ public class ConjureArmour extends SpellConjuration {
|
||||
for(EntityEquipmentSlot slot : WizardryUtilities.ARMOUR_SLOTS){
|
||||
|
||||
if(caster.getItemStackFromSlot(slot).isEmpty() &&
|
||||
!WizardryUtilities.doesPlayerHaveItem(caster, WizardryItems.SPECTRAL_ARMOUR_MAP.get(slot))){
|
||||
!WizardryUtilities.doesPlayerHaveItem(caster, SPECTRAL_ARMOUR_MAP.get(slot))){
|
||||
|
||||
armour = new ItemStack(WizardryItems.SPECTRAL_ARMOUR_MAP.get(slot));
|
||||
armour = new ItemStack(SPECTRAL_ARMOUR_MAP.get(slot));
|
||||
IConjuredItem.setDurationMultiplier(armour, modifiers.get(WizardryItems.duration_upgrade));
|
||||
// Sets a blank "ench" tag to trick the renderer into showing the enchantment effect on the armour model
|
||||
armour.getTagCompound().setTag("ench", new NBTTagList());
|
||||
|
||||
Reference in New Issue
Block a user