net.minecraftforge.fluids

## Interface IFluidBlock

- All Known Implementing Classes:
    BlockFluidBase, BlockFluidClassic, BlockFluidFinite

      public interface IFluidBlock

  Implement this interface on Block classes which represent world-placeable Fluids. NOTE: Using/extending the reference implementations `BlockFluidBase` is encouraged.
  Author:
    King Lemming

- - ### Method Summary

    Methods
    Modifier and Type | Method and Description
    --- | ---
    `boolean` | `canDrain(World world, int x, int y, int z)` Check to see if a block can be drained.
    `FluidStack` | `drain(World world, int x, int y, int z, boolean doDrain)` Attempt to drain the block.
    `float` | `getFilledPercentage(World world, int x, int y, int z)` Returns the amount of a single block is filled.
    `Fluid` | `getFluid()` Returns the Fluid associated with this Block.

- - ### Method Detail

    - #### getFluid

          Fluid getFluid()

      Returns the Fluid associated with this Block.

    - #### drain

          FluidStack drain(World world,
                         int x,
                         int y,
                         int z,
                         boolean doDrain)

      Attempt to drain the block. This method should be called by devices such as pumps. NOTE: The block is intended to handle its own state changes.
      Parameters:
        `doDrain` - If false, the drain will only be simulated.
      Returns:

    - #### canDrain

          boolean canDrain(World world,
                         int x,
                         int y,
                         int z)

      Check to see if a block can be drained. This method should be called by devices such as pumps.
      Parameters:
        `doDrain` - If false, the drain will only be simulated.
      Returns:

    - #### getFilledPercentage

          float getFilledPercentage(World world,
                                  int x,
                                  int y,
                                  int z)

      Returns the amount of a single block is filled. Value between 0 and 1. 1 meaning the entire 1x1x1 cube is full, 0 meaning completely empty. If the return value is negative. It will be treated as filling the block from the top down instead of bottom up.
      Returns: