mirror of
https://github.com/GTNewHorizons/Botania.git
synced 2026-11-15 17:45:10 +00:00
Run format
This commit is contained in:
1 parent
09be139b0e
commit
7da5552cc1
3 files changed
+13
-4
No files matched your search
@@ -1,3 +1,11 @@
|
||||
/*
|
||||
* This class is distributed as part of the Botania Mod.
|
||||
* Get the Source Code in github:
|
||||
* https://github.com/Vazkii/Botania
|
||||
*
|
||||
* Botania is Open Source and distributed under the
|
||||
* Botania License: http://botaniamod.net/license.php
|
||||
*/
|
||||
package vazkii.botania.common.item;
|
||||
|
||||
import net.minecraft.entity.player.PlayerEntity;
|
||||
@@ -5,6 +13,7 @@ import net.minecraft.inventory.Inventory;
|
||||
import net.minecraft.item.ItemStack;
|
||||
import net.minecraft.nbt.CompoundNBT;
|
||||
import net.minecraft.nbt.ListNBT;
|
||||
|
||||
import vazkii.botania.common.core.helper.ItemNBTHelper;
|
||||
|
||||
/**
|
||||
|
||||
@@ -26,8 +26,8 @@ import net.minecraftforge.common.util.LazyOptional;
|
||||
import net.minecraftforge.fml.network.NetworkHooks;
|
||||
import net.minecraftforge.items.CapabilityItemHandler;
|
||||
import net.minecraftforge.items.IItemHandler;
|
||||
|
||||
import net.minecraftforge.items.wrapper.InvWrapper;
|
||||
|
||||
import vazkii.botania.client.gui.box.ContainerBaubleBox;
|
||||
import vazkii.botania.common.core.handler.EquipmentHandler;
|
||||
|
||||
|
||||
@@ -50,8 +50,8 @@ public class ItemFlowerBag extends Item {
|
||||
public static boolean isValid(int slot, ItemStack stack) {
|
||||
Block blk = Block.getBlockFromItem(stack.getItem());
|
||||
return !stack.isEmpty()
|
||||
&& blk.getClass() == BlockModFlower.class
|
||||
&& slot == ((BlockModFlower) blk).color.getId();
|
||||
&& blk.getClass() == BlockModFlower.class
|
||||
&& slot == ((BlockModFlower) blk).color.getId();
|
||||
}
|
||||
|
||||
public static Inventory getInventory(ItemStack stack) {
|
||||
@@ -98,7 +98,7 @@ public class ItemFlowerBag extends Item {
|
||||
Inventory bagInv = getInventory(bag);
|
||||
ItemStack existing = bagInv.getStackInSlot(color);
|
||||
int newCount = Math.min(existing.getCount() + entityStack.getCount(),
|
||||
Math.min(existing.getMaxStackSize(), bagInv.getInventoryStackLimit()));
|
||||
Math.min(existing.getMaxStackSize(), bagInv.getInventoryStackLimit()));
|
||||
int numPickedUp = newCount - existing.getCount();
|
||||
|
||||
if (numPickedUp > 0) {
|
||||
|
||||
Reference in new issue
Block a user