/** * Attempts to interact the item with an IFluidHandler. * Interaction will always try and fill the item first, if this fails it will attempt to drain the item. * * @param stack The stack to interact with. * @param handler The Handler to fill / drain. * @param player The player using the item. * @param hand The hand the player is holding the item in. * @return If any interaction with the handler was successful. */ public static boolean interactWithHandler(ItemStack stack, IFluidHandler handler, EntityPlayer player, EnumHand hand) { return fillItemFromHandler(stack, handler, player, hand) || drainItemToHandler(stack, handler, player, hand); }