MinecraftForge/MinecraftForge — pull request #837 by DarkGuardsman (2013-10-23 13:22:20+00:00)
Title: Add in fill method to IFluidBlock

I've made a pull request for this before but since it been a while i'm remaking the request with fresh code. This way there should be less issues pulling in the code if it ever does.

The idea behind this change to the IFluidBlock is too allow automation to fill a block in the same way it can drain a block. This way the code doesn't have to assume that the block's meta represents the volume of the fluid block. As well it allows blocks to control how they are filled in the case they don't save volume at all using metadata. This will be a very useful method for other things than automation. As item containers can start to use this method to correctly fill a block that can contain more than one bucket worth of fluid. Another use would be blocks that can store fluid but are not fluids themselves.

Also for those that are reading this the doFill and doDrain Boolean are not up for discussion as that seems to be a large issues with fluid methods. I'm am making this pull with the only idea of creating an easy way to let automation understand how fluid blocks are filled. Without running into issues of mod incompatibility due to different methods by which volume is stored in a block.