Skip to content

Commit

Permalink
feat: make flesh veins flammable
Browse files Browse the repository at this point in the history
  • Loading branch information
Elenterius committed Aug 25, 2024
1 parent ef3aa2f commit 90d4b14
Showing 1 changed file with 12 additions and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -63,7 +63,7 @@ public class FleshVeinsBlock extends MultifaceBlock implements SimpleWaterlogged
private final MultifaceSpreader spreader = new MultifaceSpreader(new MalignantFleshSpreaderConfig(this));

public FleshVeinsBlock(Properties properties) {
super(properties.randomTicks());
super(properties.randomTicks().ignitedByLava());
registerDefaultState(defaultBlockState().setValue(WATERLOGGED, false).setValue(CHARGE.get(), CHARGE.getMin()));
}

Expand Down Expand Up @@ -650,4 +650,15 @@ public BlockState getStateForPlacement(BlockState currentState, BlockGetter leve
public MultifaceSpreader getSpreader() {
return spreader;
}

@Override
public int getFlammability(BlockState state, BlockGetter level, BlockPos pos, Direction direction) {
return Boolean.TRUE.equals(state.getValue(WATERLOGGED)) ? 0 : 100;
}

@Override
public int getFireSpreadSpeed(BlockState state, BlockGetter level, BlockPos pos, Direction direction) {
return Boolean.TRUE.equals(state.getValue(WATERLOGGED)) ? 0 : 15;
}

}

0 comments on commit 90d4b14

Please sign in to comment.