Normalized code formatting.
This commit is contained in:
parent
b1db7c5152
commit
134b11f177
122 changed files with 944 additions and 697 deletions
|
@ -62,7 +62,8 @@ public class ItemSigilBase extends ItemBindable implements ISigil, IVariantProvi
|
|||
}
|
||||
|
||||
@Override
|
||||
public List<Pair<Integer, String>> getVariants() {
|
||||
public List<Pair<Integer, String>> getVariants()
|
||||
{
|
||||
List<Pair<Integer, String>> ret = new ArrayList<Pair<Integer, String>>();
|
||||
ret.add(new ImmutablePair<Integer, String>(0, "type=normal"));
|
||||
return ret;
|
||||
|
|
|
@ -21,7 +21,8 @@ public class ItemSigilBloodLight extends ItemSigilBase
|
|||
}
|
||||
|
||||
@Override
|
||||
public void onUpdate(ItemStack stack, World worldIn, Entity entityIn, int itemSlot, boolean isSelected) {
|
||||
public void onUpdate(ItemStack stack, World worldIn, Entity entityIn, int itemSlot, boolean isSelected)
|
||||
{
|
||||
if (getCooldownRemainder(stack) > 0)
|
||||
reduceCooldown(stack);
|
||||
}
|
||||
|
@ -49,7 +50,8 @@ public class ItemSigilBloodLight extends ItemSigilBase
|
|||
}
|
||||
} else
|
||||
{
|
||||
if (!world.isRemote) {
|
||||
if (!world.isRemote)
|
||||
{
|
||||
world.spawnEntityInWorld(new EntityBloodLight(world, player));
|
||||
NetworkHelper.syphonAndDamage(NetworkHelper.getSoulNetwork(player), player, getLPUsed());
|
||||
}
|
||||
|
@ -65,15 +67,18 @@ public class ItemSigilBloodLight extends ItemSigilBase
|
|||
return oldStack.getItem() != newStack.getItem();
|
||||
}
|
||||
|
||||
public int getCooldownRemainder(ItemStack stack) {
|
||||
public int getCooldownRemainder(ItemStack stack)
|
||||
{
|
||||
return NBTHelper.checkNBT(stack).getTagCompound().getInteger(Constants.NBT.TICKS_REMAINING);
|
||||
}
|
||||
|
||||
public void reduceCooldown(ItemStack stack) {
|
||||
public void reduceCooldown(ItemStack stack)
|
||||
{
|
||||
NBTHelper.checkNBT(stack).getTagCompound().setInteger(Constants.NBT.TICKS_REMAINING, getCooldownRemainder(stack) - 1);
|
||||
}
|
||||
|
||||
public void resetCooldown(ItemStack stack) {
|
||||
public void resetCooldown(ItemStack stack)
|
||||
{
|
||||
NBTHelper.checkNBT(stack).getTagCompound().setInteger(Constants.NBT.TICKS_REMAINING, 10);
|
||||
}
|
||||
}
|
||||
|
|
|
@ -54,5 +54,4 @@ public class ItemSigilSuppression extends ItemSigilToggleable
|
|||
}
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
|
|
@ -82,4 +82,3 @@ public class ItemSigilTeleposition extends ItemSigilBase
|
|||
return tag.getInteger(key);
|
||||
}
|
||||
}
|
||||
|
||||
|
|
|
@ -83,7 +83,8 @@ public class ItemSigilToggleable extends ItemSigilBase
|
|||
}
|
||||
|
||||
@Override
|
||||
public List<Pair<Integer, String>> getVariants() {
|
||||
public List<Pair<Integer, String>> getVariants()
|
||||
{
|
||||
List<Pair<Integer, String>> ret = new ArrayList<Pair<Integer, String>>();
|
||||
ret.add(new ImmutablePair<Integer, String>(0, "active=false"));
|
||||
ret.add(new ImmutablePair<Integer, String>(1, "active=true"));
|
||||
|
|
|
@ -1,6 +1,5 @@
|
|||
package WayofTime.bloodmagic.item.sigil;
|
||||
|
||||
|
||||
import java.util.List;
|
||||
|
||||
import net.minecraft.block.Block;
|
||||
|
@ -146,5 +145,4 @@ public class ItemSigilTransposition extends ItemSigilBase
|
|||
world.addWeatherEffect(new EntityLightningBolt(world, blockPos.getX(), blockPos.getY(), blockPos.getZ()));
|
||||
}
|
||||
|
||||
|
||||
}
|
||||
|
|
|
@ -83,7 +83,8 @@ public class ItemSigilWater extends ItemSigilBase
|
|||
return false;
|
||||
}
|
||||
|
||||
if (world.getBlockState(blockPos).getBlock() == Blocks.cauldron && syphonNetwork(stack, player, getLPUsed())) {
|
||||
if (world.getBlockState(blockPos).getBlock() == Blocks.cauldron && syphonNetwork(stack, player, getLPUsed()))
|
||||
{
|
||||
world.setBlockState(blockPos, Blocks.cauldron.getDefaultState().withProperty(BlockCauldron.LEVEL, 3));
|
||||
return true;
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue