Added in #396 and gave the sword blocking

This commit is contained in:
Arcaratus committed 2015-07-27 14:02:32 -04:00
1 parent e2db60475f
commit bc67bb8379
7 files changed
+20 -2

No files matched your search

@@ -427,6 +427,7 @@ public class AlchemicalWizardry
public static boolean lockdownAltar;
public static boolean causeHungerWithRegen;
public static boolean causeHungerChatMessage = true;
public static boolean disableBoundToolsRightClick;
public static List<Class> wellBlacklist;
@@ -106,6 +106,7 @@ public class BloodMagicConfiguration
AlchemicalWizardry.causeHungerChatMessage = config.get("WimpySettings", "causeHungerChatMessage", true).getBoolean();
// AlchemicalWizardry.lockdownAltar = config.get("WimpySettings", "LockdownAltarWithRegen", true).getBoolean();
AlchemicalWizardry.lockdownAltar = false;
AlchemicalWizardry.disableBoundToolsRightClick = config.get("WimpySettings", "disableBoundToolsRightClick", false).getBoolean(false);
AlchemicalWizardry.ritualDisabledWater = config.get("Ritual Blacklist", "Ritual of the Full Spring", false).getBoolean(false);
AlchemicalWizardry.ritualDisabledLava = config.get("Ritual Blacklist", "Serenade of the Nether", false).getBoolean(false);
@@ -61,7 +61,7 @@ public class EntityDemon extends EntityTameable implements IDemon
// TODO Auto-generated method stub
return null;
}
@Override
public void writeToNBT(NBTTagCompound tag)
{
@@ -117,7 +117,7 @@ public class BoundAxe extends ItemAxe implements IBindable
par1ItemStack.getTagCompound().setInteger("worldTimeDelay", (int) (par2World.getWorldTime() - 1) % 200);
return par1ItemStack;
}
if (par2World.isRemote)
{
return par1ItemStack;
@@ -128,6 +128,11 @@ public class BoundAxe extends ItemAxe implements IBindable
return par1ItemStack;
}
if (AlchemicalWizardry.disableBoundToolsRightClick)
{
return par1ItemStack;
}
if (par3EntityPlayer.isPotionActive(AlchemicalWizardry.customPotionInhibit))
{
return par1ItemStack;
@@ -131,6 +131,11 @@ public class BoundPickaxe extends ItemPickaxe implements IBindable
return par1ItemStack;
}
if (AlchemicalWizardry.disableBoundToolsRightClick)
{
return par1ItemStack;
}
if (par3EntityPlayer.isPotionActive(AlchemicalWizardry.customPotionInhibit))
{
return par1ItemStack;
@@ -132,6 +132,11 @@ public class BoundShovel extends ItemSpade implements IBindable
return par1ItemStack;
}
if (AlchemicalWizardry.disableBoundToolsRightClick)
{
return par1ItemStack;
}
if (par3EntityPlayer.isPotionActive(AlchemicalWizardry.customPotionInhibit))
{
return par1ItemStack;
@@ -121,6 +121,7 @@ public class EnergySword extends ItemSword
@Override
public ItemStack onItemRightClick(ItemStack par1ItemStack, World par2World, EntityPlayer par3EntityPlayer)
{
super.onItemRightClick(par1ItemStack, par2World, par3EntityPlayer);
if (!EnergyItems.checkAndSetItemOwner(par1ItemStack, par3EntityPlayer) || par3EntityPlayer.isSneaking())
{
this.setActivated(par1ItemStack, !getActivated(par1ItemStack));