From 9a4d1e95ea7784f0f98ea2913701a3a3c28aefaa Mon Sep 17 00:00:00 2001 From: bculkin2442 Date: Thu, 24 May 2018 16:03:42 -0400 Subject: Formatting pass --- .../jewelrycraft/client/JewelryInventory.java | 24 +++++++++++++--------- 1 file changed, 14 insertions(+), 10 deletions(-) (limited to 'src/main/java/darkknight/jewelrycraft/client/JewelryInventory.java') diff --git a/src/main/java/darkknight/jewelrycraft/client/JewelryInventory.java b/src/main/java/darkknight/jewelrycraft/client/JewelryInventory.java index 6baf8ad..6571634 100755 --- a/src/main/java/darkknight/jewelrycraft/client/JewelryInventory.java +++ b/src/main/java/darkknight/jewelrycraft/client/JewelryInventory.java @@ -20,11 +20,11 @@ public class JewelryInventory implements IInventory { */ public JewelryInventory(EntityPlayer player) { this.player = player; - NBTTagCompound nbt = PlayerUtils.getModPlayerPersistTag(player, - Variables.MODID); + NBTTagCompound nbt = PlayerUtils.getModPlayerPersistTag( + player, Variables.MODID); for (int i = 0; i < 18; i++) - inventory[i] = ItemStack - .loadItemStackFromNBT(nbt.getCompoundTag("ext" + i)); + inventory[i] = ItemStack.loadItemStackFromNBT( + nbt.getCompoundTag("ext" + i)); } /** @@ -79,7 +79,8 @@ public class JewelryInventory implements IInventory { @Override public void setInventorySlotContents(int slot, ItemStack stack) { inventory[slot] = stack; - if (stack != null && stack.stackSize > getInventoryStackLimit()) + if (stack != null + && stack.stackSize > getInventoryStackLimit()) stack.stackSize = getInventoryStackLimit(); markDirty(); } @@ -113,12 +114,13 @@ public class JewelryInventory implements IInventory { */ @Override public void markDirty() { - NBTTagCompound nbt = PlayerUtils.getModPlayerPersistTag(player, - Variables.MODID); + NBTTagCompound nbt = PlayerUtils.getModPlayerPersistTag( + player, Variables.MODID); for (int i = 0; i < 18; i++) if (inventory[i] != null) nbt.setTag("ext" + i, inventory[i] - .writeToNBT(nbt.getCompoundTag("ext" + i))); + .writeToNBT(nbt.getCompoundTag( + "ext" + i))); else nbt.removeTag("ext" + i); } @@ -155,7 +157,8 @@ public class JewelryInventory implements IInventory { */ @Override public boolean isItemValidForSlot(int slot, ItemStack stack) { - if (slot >= 0 && slot <= 9 && stack.getItem() instanceof ItemRing) + if (slot >= 0 && slot <= 9 + && stack.getItem() instanceof ItemRing) return true; else if (slot >= 10 && slot <= 13 && stack.getItem() instanceof ItemBracelet) @@ -163,7 +166,8 @@ public class JewelryInventory implements IInventory { else if (slot >= 14 && slot <= 16 && stack.getItem() instanceof ItemNecklace) return true; - else if (slot == 17 && stack.getItem() instanceof ItemEarrings) + else if (slot == 17 + && stack.getItem() instanceof ItemEarrings) return true; return false; } -- cgit v1.2.3