Add rubber wood and stripped rubber wood (#2086). Thanks to haykam821
* Make rubber wood block names consistent with vanilla * Add rubber wood * Add stripped rubber wood * Add block and item tags for rubber logs * Allow crafting all types of rubber logs into rubber planks * Allow extracting rubber from rubber wood and stripped rubber wood
This commit is contained in:
parent
7b672244c3
commit
99a2a28d91
22 changed files with 191 additions and 45 deletions
|
@ -131,19 +131,6 @@ public class BlockRubberLog extends LogBlock {
|
|||
return ActionResult.PASS;
|
||||
}
|
||||
|
||||
if (stack.getItem() instanceof AxeItem) {
|
||||
worldIn.playSound(playerIn, pos, SoundEvents.ITEM_AXE_STRIP, SoundCategory.BLOCKS, 1.0F, 1.0F);
|
||||
if (worldIn.isClient) {
|
||||
return ActionResult.SUCCESS;
|
||||
}
|
||||
worldIn.setBlockState(pos, TRContent.RUBBER_LOG_STRIPPED.getDefaultState().with(PillarBlock.AXIS, state.get(PillarBlock.AXIS)), 11);
|
||||
if (playerIn instanceof LivingEntity) {
|
||||
LivingEntity playerEntity = (LivingEntity) playerIn;
|
||||
stack.damage(1, playerEntity, player -> { player.sendToolBreakStatus(hand); });
|
||||
}
|
||||
return ActionResult.SUCCESS;
|
||||
}
|
||||
|
||||
if ((Energy.valid(stack) && Energy.of(stack).getEnergy() > 20 && stack.getItem() instanceof ElectricTreetapItem) || stack.getItem() instanceof TreeTapItem) {
|
||||
if (state.get(HAS_SAP) && state.get(SAP_SIDE) == hitResult.getSide()) {
|
||||
worldIn.setBlockState(pos, state.with(HAS_SAP, false).with(SAP_SIDE, Direction.fromHorizontal(0)));
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue