Called by ItemBlocks just before a block is actually set in the world, to allow for adjustments to the IBlockstate
(World worldIn, BlockPos pos, EnumFacing facing, float hitX, float hitY, float hitZ, int meta, EntityLivingBase placer)
| 390 | * IBlockstate |
| 391 | */ |
| 392 | public IBlockState onBlockPlaced(World worldIn, BlockPos pos, EnumFacing facing, float hitX, float hitY, float hitZ, int meta, EntityLivingBase placer) |
| 393 | { |
| 394 | IBlockState iblockstate = this.getDefaultState().withProperty(UP, Boolean.FALSE).withProperty(NORTH, Boolean.FALSE).withProperty(EAST, Boolean.FALSE).withProperty(SOUTH, Boolean.FALSE).withProperty(WEST, Boolean.FALSE); |
| 395 | return facing.getAxis().isHorizontal() ? iblockstate.withProperty(getPropertyFor(facing.getOpposite()), Boolean.TRUE) : iblockstate; |
| 396 | } |
| 397 | |
| 398 | /** |
| 399 | * Get the Item that this Block should drop when harvested. |
nothing calls this directly
no test coverage detected