Block class rename
This commit is contained in:
parent
4b55bf30a8
commit
5f3547de8e
157 changed files with 748 additions and 756 deletions
|
@ -9,9 +9,9 @@ import net.minecraft.block.MaterialColor;
|
||||||
import net.minecraft.sound.BlockSoundGroup;
|
import net.minecraft.sound.BlockSoundGroup;
|
||||||
import net.minecraft.util.math.BlockPos;
|
import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.world.BlockView;
|
import net.minecraft.world.BlockView;
|
||||||
import ru.betterend.blocks.basis.BlockBase;
|
import ru.betterend.blocks.basis.BaseBlock;
|
||||||
|
|
||||||
public class AeterniumBlock extends BlockBase {
|
public class AeterniumBlock extends BaseBlock {
|
||||||
|
|
||||||
public AeterniumBlock() {
|
public AeterniumBlock() {
|
||||||
super(FabricBlockSettings.of(Material.METAL, MaterialColor.GRAY)
|
super(FabricBlockSettings.of(Material.METAL, MaterialColor.GRAY)
|
||||||
|
|
|
@ -3,10 +3,10 @@ package ru.betterend.blocks;
|
||||||
import net.fabricmc.fabric.api.object.builder.v1.block.FabricBlockSettings;
|
import net.fabricmc.fabric.api.object.builder.v1.block.FabricBlockSettings;
|
||||||
import net.minecraft.block.Blocks;
|
import net.minecraft.block.Blocks;
|
||||||
import net.minecraft.block.MaterialColor;
|
import net.minecraft.block.MaterialColor;
|
||||||
import ru.betterend.blocks.basis.BlockBase;
|
import ru.betterend.blocks.basis.BaseBlock;
|
||||||
|
|
||||||
public class BlockAmber extends BlockBase {
|
public class AmberBlock extends BaseBlock {
|
||||||
public BlockAmber() {
|
public AmberBlock() {
|
||||||
super(FabricBlockSettings.copyOf(Blocks.DIAMOND_BLOCK).materialColor(MaterialColor.YELLOW));
|
super(FabricBlockSettings.copyOf(Blocks.DIAMOND_BLOCK).materialColor(MaterialColor.YELLOW));
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -8,14 +8,14 @@ import net.minecraft.block.Blocks;
|
||||||
import net.minecraft.server.world.ServerWorld;
|
import net.minecraft.server.world.ServerWorld;
|
||||||
import net.minecraft.util.math.BlockPos;
|
import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.util.math.Direction;
|
import net.minecraft.util.math.Direction;
|
||||||
import ru.betterend.blocks.basis.BlockBase;
|
import ru.betterend.blocks.basis.BaseBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.registry.EndParticles;
|
import ru.betterend.registry.EndParticles;
|
||||||
import ru.betterend.util.BlocksHelper;
|
import ru.betterend.util.BlocksHelper;
|
||||||
import ru.betterend.util.MHelper;
|
import ru.betterend.util.MHelper;
|
||||||
|
|
||||||
public class BlockAncientEmeraldIce extends BlockBase {
|
public class AncientEmeraldIceBlock extends BaseBlock {
|
||||||
public BlockAncientEmeraldIce() {
|
public AncientEmeraldIceBlock() {
|
||||||
super(FabricBlockSettings.copyOf(Blocks.BLUE_ICE).ticksRandomly());
|
super(FabricBlockSettings.copyOf(Blocks.BLUE_ICE).ticksRandomly());
|
||||||
}
|
}
|
||||||
|
|
|
@ -5,10 +5,10 @@ import net.minecraft.block.BlockState;
|
||||||
import net.minecraft.state.StateManager;
|
import net.minecraft.state.StateManager;
|
||||||
import net.minecraft.state.property.EnumProperty;
|
import net.minecraft.state.property.EnumProperty;
|
||||||
import ru.betterend.blocks.BlockProperties.TripleShape;
|
import ru.betterend.blocks.BlockProperties.TripleShape;
|
||||||
import ru.betterend.blocks.basis.BlockUpDownPlant;
|
import ru.betterend.blocks.basis.UpDownPlantBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
|
|
||||||
public class BlockBlueVine extends BlockUpDownPlant {
|
public class BlueVineBlock extends UpDownPlantBlock {
|
||||||
public static final EnumProperty<TripleShape> SHAPE = BlockProperties.TRIPLE_SHAPE;
|
public static final EnumProperty<TripleShape> SHAPE = BlockProperties.TRIPLE_SHAPE;
|
||||||
|
|
||||||
@Override
|
@Override
|
|
@ -13,13 +13,13 @@ import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.util.math.Direction;
|
import net.minecraft.util.math.Direction;
|
||||||
import net.minecraft.world.WorldAccess;
|
import net.minecraft.world.WorldAccess;
|
||||||
import net.minecraft.world.WorldView;
|
import net.minecraft.world.WorldView;
|
||||||
import ru.betterend.blocks.basis.BlockBase;
|
import ru.betterend.blocks.basis.BaseBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
|
|
||||||
public class BlockBlueVineLantern extends BlockBase {
|
public class BlueVineLanternBlock extends BaseBlock {
|
||||||
public static final BooleanProperty NATURAL = BlockProperties.NATURAL;
|
public static final BooleanProperty NATURAL = BlockProperties.NATURAL;
|
||||||
|
|
||||||
public BlockBlueVineLantern() {
|
public BlueVineLanternBlock() {
|
||||||
super(FabricBlockSettings.of(Material.WOOD).breakByTool(FabricToolTags.AXES).sounds(BlockSoundGroup.WART_BLOCK).luminance(15));
|
super(FabricBlockSettings.of(Material.WOOD).breakByTool(FabricToolTags.AXES).sounds(BlockSoundGroup.WART_BLOCK).luminance(15));
|
||||||
this.setDefaultState(this.stateManager.getDefaultState().with(NATURAL, false));
|
this.setDefaultState(this.stateManager.getDefaultState().with(NATURAL, false));
|
||||||
}
|
}
|
|
@ -7,13 +7,13 @@ import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.util.math.Direction;
|
import net.minecraft.util.math.Direction;
|
||||||
import net.minecraft.world.StructureWorldAccess;
|
import net.minecraft.world.StructureWorldAccess;
|
||||||
import ru.betterend.blocks.BlockProperties.TripleShape;
|
import ru.betterend.blocks.BlockProperties.TripleShape;
|
||||||
import ru.betterend.blocks.basis.BlockFur;
|
import ru.betterend.blocks.basis.FurBlock;
|
||||||
import ru.betterend.blocks.basis.BlockPlantWithAge;
|
import ru.betterend.blocks.basis.PlantWithAgeBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.util.BlocksHelper;
|
import ru.betterend.util.BlocksHelper;
|
||||||
import ru.betterend.util.MHelper;
|
import ru.betterend.util.MHelper;
|
||||||
|
|
||||||
public class BlockBlueVineSeed extends BlockPlantWithAge {
|
public class BlueVineSeedBlock extends PlantWithAgeBlock {
|
||||||
@Override
|
@Override
|
||||||
public void growAdult(StructureWorldAccess world, Random random, BlockPos pos) {
|
public void growAdult(StructureWorldAccess world, Random random, BlockPos pos) {
|
||||||
int height = MHelper.randRange(2, 5, random);
|
int height = MHelper.randRange(2, 5, random);
|
||||||
|
@ -30,15 +30,15 @@ public class BlockBlueVineSeed extends BlockPlantWithAge {
|
||||||
}
|
}
|
||||||
|
|
||||||
private void placeLantern(StructureWorldAccess world, BlockPos pos) {
|
private void placeLantern(StructureWorldAccess world, BlockPos pos) {
|
||||||
BlocksHelper.setWithoutUpdate(world, pos, EndBlocks.BLUE_VINE_LANTERN.getDefaultState().with(BlockBlueVineLantern.NATURAL, true));
|
BlocksHelper.setWithoutUpdate(world, pos, EndBlocks.BLUE_VINE_LANTERN.getDefaultState().with(BlueVineLanternBlock.NATURAL, true));
|
||||||
for (Direction dir: BlocksHelper.HORIZONTAL) {
|
for (Direction dir: BlocksHelper.HORIZONTAL) {
|
||||||
BlockPos p = pos.offset(dir);
|
BlockPos p = pos.offset(dir);
|
||||||
if (world.isAir(p)) {
|
if (world.isAir(p)) {
|
||||||
BlocksHelper.setWithoutUpdate(world, p, EndBlocks.BLUE_VINE_FUR.getDefaultState().with(BlockFur.FACING, dir));
|
BlocksHelper.setWithoutUpdate(world, p, EndBlocks.BLUE_VINE_FUR.getDefaultState().with(FurBlock.FACING, dir));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
if (world.isAir(pos.up())) {
|
if (world.isAir(pos.up())) {
|
||||||
BlocksHelper.setWithoutUpdate(world, pos.up(), EndBlocks.BLUE_VINE_FUR.getDefaultState().with(BlockFur.FACING, Direction.UP));
|
BlocksHelper.setWithoutUpdate(world, pos.up(), EndBlocks.BLUE_VINE_FUR.getDefaultState().with(FurBlock.FACING, Direction.UP));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -13,14 +13,14 @@ import net.minecraft.state.StateManager;
|
||||||
import net.minecraft.state.property.BooleanProperty;
|
import net.minecraft.state.property.BooleanProperty;
|
||||||
import net.minecraft.util.math.BlockPos;
|
import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.util.math.Direction;
|
import net.minecraft.util.math.Direction;
|
||||||
import ru.betterend.blocks.basis.BlockBase;
|
import ru.betterend.blocks.basis.BaseBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.util.BlocksHelper;
|
import ru.betterend.util.BlocksHelper;
|
||||||
|
|
||||||
public class BlockBrimstone extends BlockBase {
|
public class BrimstoneBlock extends BaseBlock {
|
||||||
public static final BooleanProperty ACTIVATED = BlockProperties.ACTIVE;
|
public static final BooleanProperty ACTIVATED = BlockProperties.ACTIVE;
|
||||||
|
|
||||||
public BlockBrimstone() {
|
public BrimstoneBlock() {
|
||||||
super(FabricBlockSettings.copyOf(Blocks.END_STONE).materialColor(MaterialColor.BROWN).ticksRandomly());
|
super(FabricBlockSettings.copyOf(Blocks.END_STONE).materialColor(MaterialColor.BROWN).ticksRandomly());
|
||||||
setDefaultState(stateManager.getDefaultState().with(ACTIVATED, false));
|
setDefaultState(stateManager.getDefaultState().with(ACTIVATED, false));
|
||||||
}
|
}
|
||||||
|
@ -47,17 +47,17 @@ public class BlockBrimstone extends BlockBase {
|
||||||
Direction dir = BlocksHelper.randomDirection(random);
|
Direction dir = BlocksHelper.randomDirection(random);
|
||||||
BlockPos side = pos.offset(dir);
|
BlockPos side = pos.offset(dir);
|
||||||
BlockState sideState = world.getBlockState(side);
|
BlockState sideState = world.getBlockState(side);
|
||||||
if (sideState.getBlock() instanceof BlockSulphurCrystal) {
|
if (sideState.getBlock() instanceof SulphurCrystalBlock) {
|
||||||
if (sideState.get(BlockSulphurCrystal.AGE) < 2 && sideState.get(BlockSulphurCrystal.WATERLOGGED)) {
|
if (sideState.get(SulphurCrystalBlock.AGE) < 2 && sideState.get(SulphurCrystalBlock.WATERLOGGED)) {
|
||||||
int age = sideState.get(BlockSulphurCrystal.AGE) + 1;
|
int age = sideState.get(SulphurCrystalBlock.AGE) + 1;
|
||||||
world.setBlockState(side, sideState.with(BlockSulphurCrystal.AGE, age));
|
world.setBlockState(side, sideState.with(SulphurCrystalBlock.AGE, age));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if (sideState.getFluidState().getFluid() == Fluids.WATER) {
|
else if (sideState.getFluidState().getFluid() == Fluids.WATER) {
|
||||||
BlockState crystal = EndBlocks.SULPHUR_CRYSTAL.getDefaultState()
|
BlockState crystal = EndBlocks.SULPHUR_CRYSTAL.getDefaultState()
|
||||||
.with(BlockSulphurCrystal.FACING, dir)
|
.with(SulphurCrystalBlock.FACING, dir)
|
||||||
.with(BlockSulphurCrystal.WATERLOGGED, true)
|
.with(SulphurCrystalBlock.WATERLOGGED, true)
|
||||||
.with(BlockSulphurCrystal.AGE, 0);
|
.with(SulphurCrystalBlock.AGE, 0);
|
||||||
world.setBlockState(side, crystal);
|
world.setBlockState(side, crystal);
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -17,12 +17,12 @@ import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.util.shape.VoxelShape;
|
import net.minecraft.util.shape.VoxelShape;
|
||||||
import net.minecraft.world.BlockView;
|
import net.minecraft.world.BlockView;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import ru.betterend.blocks.basis.BlockUnderwaterPlant;
|
import ru.betterend.blocks.basis.UnderwaterPlantBlock;
|
||||||
|
|
||||||
public class BlockBubbleCoral extends BlockUnderwaterPlant {
|
public class BubbleCoralBlock extends UnderwaterPlantBlock {
|
||||||
private static final VoxelShape SHAPE = Block.createCuboidShape(0, 0, 0, 16, 14, 16);
|
private static final VoxelShape SHAPE = Block.createCuboidShape(0, 0, 0, 16, 14, 16);
|
||||||
|
|
||||||
public BlockBubbleCoral() {
|
public BubbleCoralBlock() {
|
||||||
super(FabricBlockSettings.of(Material.UNDERWATER_PLANT)
|
super(FabricBlockSettings.of(Material.UNDERWATER_PLANT)
|
||||||
.breakByTool(FabricToolTags.SHEARS)
|
.breakByTool(FabricToolTags.SHEARS)
|
||||||
.sounds(BlockSoundGroup.CORAL)
|
.sounds(BlockSoundGroup.CORAL)
|
|
@ -11,13 +11,13 @@ import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.world.BlockView;
|
import net.minecraft.world.BlockView;
|
||||||
import net.minecraft.world.WorldView;
|
import net.minecraft.world.WorldView;
|
||||||
import ru.betterend.blocks.BlockProperties.TripleShape;
|
import ru.betterend.blocks.BlockProperties.TripleShape;
|
||||||
import ru.betterend.blocks.basis.BlockVine;
|
import ru.betterend.blocks.basis.VineBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.registry.EndItems;
|
import ru.betterend.registry.EndItems;
|
||||||
import ru.betterend.util.MHelper;
|
import ru.betterend.util.MHelper;
|
||||||
|
|
||||||
public class BlockBulbVine extends BlockVine {
|
public class BulbVineBlock extends VineBlock {
|
||||||
public BlockBulbVine() {
|
public BulbVineBlock() {
|
||||||
super(15, true);
|
super(15, true);
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
package ru.betterend.blocks.basis;
|
package ru.betterend.blocks;
|
||||||
|
|
||||||
import net.fabricmc.fabric.api.object.builder.v1.block.FabricBlockSettings;
|
import net.fabricmc.fabric.api.object.builder.v1.block.FabricBlockSettings;
|
||||||
import net.fabricmc.fabric.api.tool.attribute.v1.FabricToolTags;
|
import net.fabricmc.fabric.api.tool.attribute.v1.FabricToolTags;
|
||||||
|
@ -11,14 +11,15 @@ import net.minecraft.sound.BlockSoundGroup;
|
||||||
import net.minecraft.util.math.BlockPos;
|
import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.util.shape.VoxelShape;
|
import net.minecraft.util.shape.VoxelShape;
|
||||||
import net.minecraft.world.BlockView;
|
import net.minecraft.world.BlockView;
|
||||||
|
import ru.betterend.blocks.basis.EndLanternBlock;
|
||||||
import ru.betterend.client.render.ERenderLayer;
|
import ru.betterend.client.render.ERenderLayer;
|
||||||
import ru.betterend.interfaces.IRenderTypeable;
|
import ru.betterend.interfaces.IRenderTypeable;
|
||||||
|
|
||||||
public class BlockBulbVineLantern extends BlockLantern implements IRenderTypeable {
|
public class BulbVineLanternBlock extends EndLanternBlock implements IRenderTypeable {
|
||||||
private static final VoxelShape SHAPE_CEIL = Block.createCuboidShape(4, 4, 4, 12, 16, 12);
|
private static final VoxelShape SHAPE_CEIL = Block.createCuboidShape(4, 4, 4, 12, 16, 12);
|
||||||
private static final VoxelShape SHAPE_FLOOR = Block.createCuboidShape(4, 0, 4, 12, 12, 12);
|
private static final VoxelShape SHAPE_FLOOR = Block.createCuboidShape(4, 0, 4, 12, 12, 12);
|
||||||
|
|
||||||
public BlockBulbVineLantern() {
|
public BulbVineLanternBlock() {
|
||||||
this(FabricBlockSettings.of(Material.METAL)
|
this(FabricBlockSettings.of(Material.METAL)
|
||||||
.sounds(BlockSoundGroup.LANTERN)
|
.sounds(BlockSoundGroup.LANTERN)
|
||||||
.hardness(1)
|
.hardness(1)
|
||||||
|
@ -29,7 +30,7 @@ public class BlockBulbVineLantern extends BlockLantern implements IRenderTypeabl
|
||||||
.luminance(15));
|
.luminance(15));
|
||||||
}
|
}
|
||||||
|
|
||||||
public BlockBulbVineLantern(FabricBlockSettings settings) {
|
public BulbVineLanternBlock(FabricBlockSettings settings) {
|
||||||
super(settings);
|
super(settings);
|
||||||
}
|
}
|
||||||
|
|
|
@ -1,4 +1,4 @@
|
||||||
package ru.betterend.blocks.basis;
|
package ru.betterend.blocks;
|
||||||
|
|
||||||
import java.io.Reader;
|
import java.io.Reader;
|
||||||
|
|
||||||
|
@ -10,8 +10,8 @@ import ru.betterend.interfaces.IColorProvider;
|
||||||
import ru.betterend.patterns.BlockPatterned;
|
import ru.betterend.patterns.BlockPatterned;
|
||||||
import ru.betterend.patterns.Patterns;
|
import ru.betterend.patterns.Patterns;
|
||||||
|
|
||||||
public class BlockBulbVineLanternColored extends BlockBulbVineLantern implements IColorProvider, BlockPatterned {
|
public class BulbVineLanternColoredBlock extends BulbVineLanternBlock implements IColorProvider, BlockPatterned {
|
||||||
public BlockBulbVineLanternColored(FabricBlockSettings settings) {
|
public BulbVineLanternColoredBlock(FabricBlockSettings settings) {
|
||||||
super(settings);
|
super(settings);
|
||||||
}
|
}
|
||||||
|
|
|
@ -8,12 +8,12 @@ import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.world.StructureWorldAccess;
|
import net.minecraft.world.StructureWorldAccess;
|
||||||
import net.minecraft.world.WorldView;
|
import net.minecraft.world.WorldView;
|
||||||
import ru.betterend.blocks.BlockProperties.TripleShape;
|
import ru.betterend.blocks.BlockProperties.TripleShape;
|
||||||
import ru.betterend.blocks.basis.BlockPlantWithAge;
|
import ru.betterend.blocks.basis.PlantWithAgeBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.registry.EndTags;
|
import ru.betterend.registry.EndTags;
|
||||||
import ru.betterend.util.BlocksHelper;
|
import ru.betterend.util.BlocksHelper;
|
||||||
|
|
||||||
public class BlockBulbVineSeed extends BlockPlantWithAge {
|
public class BulbVineSeedBlock extends PlantWithAgeBlock {
|
||||||
@Override
|
@Override
|
||||||
public boolean canPlaceAt(BlockState state, WorldView world, BlockPos pos) {
|
public boolean canPlaceAt(BlockState state, WorldView world, BlockPos pos) {
|
||||||
BlockState up = world.getBlockState(pos.up());
|
BlockState up = world.getBlockState(pos.up());
|
|
@ -5,9 +5,9 @@ import net.minecraft.fluid.Fluids;
|
||||||
import net.minecraft.util.math.BlockPos;
|
import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.util.math.Direction;
|
import net.minecraft.util.math.Direction;
|
||||||
import net.minecraft.world.WorldView;
|
import net.minecraft.world.WorldView;
|
||||||
import ru.betterend.blocks.basis.BlockUnderwaterPlant;
|
import ru.betterend.blocks.basis.UnderwaterPlantBlock;
|
||||||
|
|
||||||
public class BlockCharnia extends BlockUnderwaterPlant {
|
public class CharniaBlock extends UnderwaterPlantBlock {
|
||||||
@Override
|
@Override
|
||||||
public boolean canPlaceAt(BlockState state, WorldView world, BlockPos pos) {
|
public boolean canPlaceAt(BlockState state, WorldView world, BlockPos pos) {
|
||||||
return sideCoversSmallSquare(world, pos.down(), Direction.UP) && world.getFluidState(pos).getFluid() == Fluids.WATER;
|
return sideCoversSmallSquare(world, pos.down(), Direction.UP) && world.getFluidState(pos).getFluid() == Fluids.WATER;
|
|
@ -1,11 +1,11 @@
|
||||||
package ru.betterend.blocks;
|
package ru.betterend.blocks;
|
||||||
|
|
||||||
import net.minecraft.block.BlockState;
|
import net.minecraft.block.BlockState;
|
||||||
import ru.betterend.blocks.basis.BlockPlant;
|
import ru.betterend.blocks.basis.EndPlantBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
|
|
||||||
public class BlockChorusGrass extends BlockPlant {
|
public class ChorusGrassBlock extends EndPlantBlock {
|
||||||
public BlockChorusGrass() {
|
public ChorusGrassBlock() {
|
||||||
super(true);
|
super(true);
|
||||||
}
|
}
|
||||||
|
|
|
@ -2,12 +2,12 @@ package ru.betterend.blocks;
|
||||||
|
|
||||||
import net.fabricmc.fabric.api.object.builder.v1.block.FabricBlockSettings;
|
import net.fabricmc.fabric.api.object.builder.v1.block.FabricBlockSettings;
|
||||||
import net.minecraft.block.Blocks;
|
import net.minecraft.block.Blocks;
|
||||||
import ru.betterend.blocks.basis.BlockBase;
|
import ru.betterend.blocks.basis.BaseBlock;
|
||||||
import ru.betterend.client.render.ERenderLayer;
|
import ru.betterend.client.render.ERenderLayer;
|
||||||
import ru.betterend.interfaces.IRenderTypeable;
|
import ru.betterend.interfaces.IRenderTypeable;
|
||||||
|
|
||||||
public class BlockDenseEmeraldIce extends BlockBase implements IRenderTypeable {
|
public class DenseEmeraldIceBlock extends BaseBlock implements IRenderTypeable {
|
||||||
public BlockDenseEmeraldIce() {
|
public DenseEmeraldIceBlock() {
|
||||||
super(FabricBlockSettings.copyOf(Blocks.PACKED_ICE));
|
super(FabricBlockSettings.copyOf(Blocks.PACKED_ICE));
|
||||||
}
|
}
|
||||||
|
|
|
@ -3,10 +3,10 @@ package ru.betterend.blocks;
|
||||||
import net.fabricmc.fabric.api.object.builder.v1.block.FabricBlockSettings;
|
import net.fabricmc.fabric.api.object.builder.v1.block.FabricBlockSettings;
|
||||||
import net.minecraft.block.Material;
|
import net.minecraft.block.Material;
|
||||||
import net.minecraft.sound.BlockSoundGroup;
|
import net.minecraft.sound.BlockSoundGroup;
|
||||||
import ru.betterend.blocks.basis.BlockBase;
|
import ru.betterend.blocks.basis.BaseBlock;
|
||||||
|
|
||||||
public class BlockDenseSnow extends BlockBase {
|
public class DenseSnowBlock extends BaseBlock {
|
||||||
public BlockDenseSnow() {
|
public DenseSnowBlock() {
|
||||||
super(FabricBlockSettings.of(Material.SNOW_BLOCK).strength(0.2F).sounds(BlockSoundGroup.SNOW));
|
super(FabricBlockSettings.of(Material.SNOW_BLOCK).strength(0.2F).sounds(BlockSoundGroup.SNOW));
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -4,12 +4,12 @@ import net.minecraft.block.BlockState;
|
||||||
import net.minecraft.util.math.BlockPos;
|
import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.world.WorldView;
|
import net.minecraft.world.WorldView;
|
||||||
import net.minecraft.world.gen.feature.Feature;
|
import net.minecraft.world.gen.feature.Feature;
|
||||||
import ru.betterend.blocks.basis.BlockFeatureSapling;
|
import ru.betterend.blocks.basis.FeatureSaplingBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.registry.EndFeatures;
|
import ru.betterend.registry.EndFeatures;
|
||||||
|
|
||||||
public class BlockDragonTreeSapling extends BlockFeatureSapling {
|
public class DragonTreeSaplingBlock extends FeatureSaplingBlock {
|
||||||
public BlockDragonTreeSapling() {
|
public DragonTreeSaplingBlock() {
|
||||||
super();
|
super();
|
||||||
}
|
}
|
||||||
|
|
|
@ -29,8 +29,8 @@ import ru.betterend.interfaces.IRenderTypeable;
|
||||||
import ru.betterend.patterns.BlockPatterned;
|
import ru.betterend.patterns.BlockPatterned;
|
||||||
import ru.betterend.patterns.Patterns;
|
import ru.betterend.patterns.Patterns;
|
||||||
|
|
||||||
public class BlockEmeraldIce extends TransparentBlock implements IRenderTypeable, BlockPatterned {
|
public class EmeraldIceBlock extends TransparentBlock implements IRenderTypeable, BlockPatterned {
|
||||||
public BlockEmeraldIce() {
|
public EmeraldIceBlock() {
|
||||||
super(FabricBlockSettings.copyOf(Blocks.ICE));
|
super(FabricBlockSettings.copyOf(Blocks.ICE));
|
||||||
}
|
}
|
||||||
|
|
|
@ -31,17 +31,17 @@ import net.minecraft.world.World;
|
||||||
import net.minecraft.world.WorldAccess;
|
import net.minecraft.world.WorldAccess;
|
||||||
import net.minecraft.world.WorldView;
|
import net.minecraft.world.WorldView;
|
||||||
import ru.betterend.blocks.BlockProperties.TripleShape;
|
import ru.betterend.blocks.BlockProperties.TripleShape;
|
||||||
import ru.betterend.blocks.basis.BlockUnderwaterPlant;
|
import ru.betterend.blocks.basis.UnderwaterPlantBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.registry.EndItems;
|
import ru.betterend.registry.EndItems;
|
||||||
import ru.betterend.util.MHelper;
|
import ru.betterend.util.MHelper;
|
||||||
|
|
||||||
public class BlockEndLily extends BlockUnderwaterPlant {
|
public class EndLilyBlock extends UnderwaterPlantBlock {
|
||||||
public static final EnumProperty<TripleShape> SHAPE = BlockProperties.TRIPLE_SHAPE;
|
public static final EnumProperty<TripleShape> SHAPE = BlockProperties.TRIPLE_SHAPE;
|
||||||
private static final VoxelShape SHAPE_BOTTOM = Block.createCuboidShape(4, 0, 4, 12, 16, 12);
|
private static final VoxelShape SHAPE_BOTTOM = Block.createCuboidShape(4, 0, 4, 12, 16, 12);
|
||||||
private static final VoxelShape SHAPE_TOP = Block.createCuboidShape(2, 0, 2, 14, 6, 14);
|
private static final VoxelShape SHAPE_TOP = Block.createCuboidShape(2, 0, 2, 14, 6, 14);
|
||||||
|
|
||||||
public BlockEndLily() {
|
public EndLilyBlock() {
|
||||||
super(FabricBlockSettings.of(Material.UNDERWATER_PLANT)
|
super(FabricBlockSettings.of(Material.UNDERWATER_PLANT)
|
||||||
.breakByTool(FabricToolTags.SHEARS)
|
.breakByTool(FabricToolTags.SHEARS)
|
||||||
.sounds(BlockSoundGroup.WET_GRASS)
|
.sounds(BlockSoundGroup.WET_GRASS)
|
|
@ -6,21 +6,21 @@ import net.minecraft.fluid.Fluids;
|
||||||
import net.minecraft.util.math.BlockPos;
|
import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.world.StructureWorldAccess;
|
import net.minecraft.world.StructureWorldAccess;
|
||||||
import ru.betterend.blocks.BlockProperties.TripleShape;
|
import ru.betterend.blocks.BlockProperties.TripleShape;
|
||||||
import ru.betterend.blocks.basis.BlockUnderwaterPlantWithAge;
|
import ru.betterend.blocks.basis.UnderwaterPlantWithAgeBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.util.BlocksHelper;
|
import ru.betterend.util.BlocksHelper;
|
||||||
|
|
||||||
public class BlockEndLilySeed extends BlockUnderwaterPlantWithAge {
|
public class EndLilySeedBlock extends UnderwaterPlantWithAgeBlock {
|
||||||
@Override
|
@Override
|
||||||
public void grow(StructureWorldAccess world, Random random, BlockPos pos) {
|
public void grow(StructureWorldAccess world, Random random, BlockPos pos) {
|
||||||
if (canGrow(world, pos)) {
|
if (canGrow(world, pos)) {
|
||||||
BlocksHelper.setWithoutUpdate(world, pos, EndBlocks.END_LILY.getDefaultState().with(BlockEndLily.SHAPE, TripleShape.BOTTOM));
|
BlocksHelper.setWithoutUpdate(world, pos, EndBlocks.END_LILY.getDefaultState().with(EndLilyBlock.SHAPE, TripleShape.BOTTOM));
|
||||||
BlockPos up = pos.up();
|
BlockPos up = pos.up();
|
||||||
while (world.getFluidState(up).isStill()) {
|
while (world.getFluidState(up).isStill()) {
|
||||||
BlocksHelper.setWithoutUpdate(world, up, EndBlocks.END_LILY.getDefaultState().with(BlockEndLily.SHAPE, TripleShape.MIDDLE));
|
BlocksHelper.setWithoutUpdate(world, up, EndBlocks.END_LILY.getDefaultState().with(EndLilyBlock.SHAPE, TripleShape.MIDDLE));
|
||||||
up = up.up();
|
up = up.up();
|
||||||
}
|
}
|
||||||
BlocksHelper.setWithoutUpdate(world, up, EndBlocks.END_LILY.getDefaultState().with(BlockEndLily.SHAPE, TripleShape.TOP));
|
BlocksHelper.setWithoutUpdate(world, up, EndBlocks.END_LILY.getDefaultState().with(EndLilyBlock.SHAPE, TripleShape.TOP));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -17,15 +17,15 @@ import net.minecraft.loot.context.LootContext;
|
||||||
import net.minecraft.util.math.BlockPos;
|
import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.util.shape.VoxelShape;
|
import net.minecraft.util.shape.VoxelShape;
|
||||||
import net.minecraft.world.BlockView;
|
import net.minecraft.world.BlockView;
|
||||||
import ru.betterend.blocks.basis.BlockPlant;
|
import ru.betterend.blocks.basis.EndPlantBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.util.MHelper;
|
import ru.betterend.util.MHelper;
|
||||||
|
|
||||||
public class BlockEndLotusFlower extends BlockPlant {
|
public class EndLotusFlowerBlock extends EndPlantBlock {
|
||||||
private static final VoxelShape SHAPE_OUTLINE = Block.createCuboidShape(2, 0, 2, 14, 14, 14);
|
private static final VoxelShape SHAPE_OUTLINE = Block.createCuboidShape(2, 0, 2, 14, 14, 14);
|
||||||
private static final VoxelShape SHAPE_COLLISION = Block.createCuboidShape(0, 0, 0, 16, 2, 16);
|
private static final VoxelShape SHAPE_COLLISION = Block.createCuboidShape(0, 0, 0, 16, 2, 16);
|
||||||
|
|
||||||
public BlockEndLotusFlower() {
|
public EndLotusFlowerBlock() {
|
||||||
super(FabricBlockSettings.of(Material.PLANT).nonOpaque().luminance(15));
|
super(FabricBlockSettings.of(Material.PLANT).nonOpaque().luminance(15));
|
||||||
}
|
}
|
||||||
|
|
|
@ -21,18 +21,18 @@ import net.minecraft.util.shape.VoxelShape;
|
||||||
import net.minecraft.world.BlockView;
|
import net.minecraft.world.BlockView;
|
||||||
import net.minecraft.world.WorldView;
|
import net.minecraft.world.WorldView;
|
||||||
import ru.betterend.blocks.BlockProperties.TripleShape;
|
import ru.betterend.blocks.BlockProperties.TripleShape;
|
||||||
import ru.betterend.blocks.basis.BlockBaseNotFull;
|
import ru.betterend.blocks.basis.BaseBlockNotFull;
|
||||||
import ru.betterend.client.render.ERenderLayer;
|
import ru.betterend.client.render.ERenderLayer;
|
||||||
import ru.betterend.interfaces.IRenderTypeable;
|
import ru.betterend.interfaces.IRenderTypeable;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.util.BlocksHelper;
|
import ru.betterend.util.BlocksHelper;
|
||||||
|
|
||||||
public class BlockEndLotusLeaf extends BlockBaseNotFull implements IRenderTypeable {
|
public class EndLotusLeafBlock extends BaseBlockNotFull implements IRenderTypeable {
|
||||||
public static final EnumProperty<Direction> HORIZONTAL_FACING = Properties.HORIZONTAL_FACING;
|
public static final EnumProperty<Direction> HORIZONTAL_FACING = Properties.HORIZONTAL_FACING;
|
||||||
public static final EnumProperty<TripleShape> SHAPE = BlockProperties.TRIPLE_SHAPE;
|
public static final EnumProperty<TripleShape> SHAPE = BlockProperties.TRIPLE_SHAPE;
|
||||||
private static final VoxelShape VSHAPE = Block.createCuboidShape(0, 0, 0, 16, 1, 16);
|
private static final VoxelShape VSHAPE = Block.createCuboidShape(0, 0, 0, 16, 1, 16);
|
||||||
|
|
||||||
public BlockEndLotusLeaf() {
|
public EndLotusLeafBlock() {
|
||||||
super(FabricBlockSettings.of(Material.PLANT).nonOpaque().sounds(BlockSoundGroup.WET_GRASS));
|
super(FabricBlockSettings.of(Material.PLANT).nonOpaque().sounds(BlockSoundGroup.WET_GRASS));
|
||||||
}
|
}
|
||||||
|
|
|
@ -9,16 +9,16 @@ import net.minecraft.util.math.BlockPos.Mutable;
|
||||||
import net.minecraft.util.math.Direction;
|
import net.minecraft.util.math.Direction;
|
||||||
import net.minecraft.world.StructureWorldAccess;
|
import net.minecraft.world.StructureWorldAccess;
|
||||||
import ru.betterend.blocks.BlockProperties.TripleShape;
|
import ru.betterend.blocks.BlockProperties.TripleShape;
|
||||||
import ru.betterend.blocks.basis.BlockUnderwaterPlantWithAge;
|
import ru.betterend.blocks.basis.UnderwaterPlantWithAgeBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.util.BlocksHelper;
|
import ru.betterend.util.BlocksHelper;
|
||||||
|
|
||||||
public class BlockEndLotusSeed extends BlockUnderwaterPlantWithAge {
|
public class EndLotusSeedBlock extends UnderwaterPlantWithAgeBlock {
|
||||||
@Override
|
@Override
|
||||||
public void grow(StructureWorldAccess world, Random random, BlockPos pos) {
|
public void grow(StructureWorldAccess world, Random random, BlockPos pos) {
|
||||||
if (canGrow(world, pos)) {
|
if (canGrow(world, pos)) {
|
||||||
BlockState startLeaf = EndBlocks.END_LOTUS_STEM.getDefaultState().with(BlockEndLotusStem.LEAF, true);
|
BlockState startLeaf = EndBlocks.END_LOTUS_STEM.getDefaultState().with(EndLotusStemBlock.LEAF, true);
|
||||||
BlockState roots = EndBlocks.END_LOTUS_STEM.getDefaultState().with(BlockEndLotusStem.SHAPE, TripleShape.BOTTOM).with(BlockEndLotusStem.WATERLOGGED, true);
|
BlockState roots = EndBlocks.END_LOTUS_STEM.getDefaultState().with(EndLotusStemBlock.SHAPE, TripleShape.BOTTOM).with(EndLotusStemBlock.WATERLOGGED, true);
|
||||||
BlockState stem = EndBlocks.END_LOTUS_STEM.getDefaultState();
|
BlockState stem = EndBlocks.END_LOTUS_STEM.getDefaultState();
|
||||||
BlockState flower = EndBlocks.END_LOTUS_FLOWER.getDefaultState();
|
BlockState flower = EndBlocks.END_LOTUS_FLOWER.getDefaultState();
|
||||||
|
|
||||||
|
@ -26,7 +26,7 @@ public class BlockEndLotusSeed extends BlockUnderwaterPlantWithAge {
|
||||||
Mutable bpos = new Mutable().set(pos);
|
Mutable bpos = new Mutable().set(pos);
|
||||||
bpos.setY(bpos.getY() + 1);
|
bpos.setY(bpos.getY() + 1);
|
||||||
while (world.getFluidState(bpos).isStill()) {
|
while (world.getFluidState(bpos).isStill()) {
|
||||||
BlocksHelper.setWithoutUpdate(world, bpos, stem.with(BlockEndLotusStem.WATERLOGGED, true));
|
BlocksHelper.setWithoutUpdate(world, bpos, stem.with(EndLotusStemBlock.WATERLOGGED, true));
|
||||||
bpos.setY(bpos.getY() + 1);
|
bpos.setY(bpos.getY() + 1);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -36,10 +36,10 @@ public class BlockEndLotusSeed extends BlockUnderwaterPlantWithAge {
|
||||||
BlockPos leafCenter = bpos.toImmutable().offset(dir);
|
BlockPos leafCenter = bpos.toImmutable().offset(dir);
|
||||||
if (hasLeaf(world, leafCenter)) {
|
if (hasLeaf(world, leafCenter)) {
|
||||||
generateLeaf(world, leafCenter);
|
generateLeaf(world, leafCenter);
|
||||||
BlocksHelper.setWithoutUpdate(world, bpos, startLeaf.with(BlockEndLotusStem.SHAPE, shape).with(BlockEndLotusStem.FACING, dir));
|
BlocksHelper.setWithoutUpdate(world, bpos, startLeaf.with(EndLotusStemBlock.SHAPE, shape).with(EndLotusStemBlock.FACING, dir));
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
BlocksHelper.setWithoutUpdate(world, bpos, stem.with(BlockEndLotusStem.SHAPE, shape));
|
BlocksHelper.setWithoutUpdate(world, bpos, stem.with(EndLotusStemBlock.SHAPE, shape));
|
||||||
}
|
}
|
||||||
|
|
||||||
bpos.setY(bpos.getY() + 1);
|
bpos.setY(bpos.getY() + 1);
|
||||||
|
@ -49,7 +49,7 @@ public class BlockEndLotusSeed extends BlockUnderwaterPlantWithAge {
|
||||||
BlocksHelper.setWithoutUpdate(world, bpos, flower);
|
BlocksHelper.setWithoutUpdate(world, bpos, flower);
|
||||||
bpos.setY(bpos.getY() - 1);
|
bpos.setY(bpos.getY() - 1);
|
||||||
stem = world.getBlockState(bpos);
|
stem = world.getBlockState(bpos);
|
||||||
BlocksHelper.setWithoutUpdate(world, bpos, stem.with(BlockEndLotusStem.SHAPE, TripleShape.TOP));
|
BlocksHelper.setWithoutUpdate(world, bpos, stem.with(EndLotusStemBlock.SHAPE, TripleShape.TOP));
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
BlocksHelper.setWithoutUpdate(world, bpos, stem);
|
BlocksHelper.setWithoutUpdate(world, bpos, stem);
|
||||||
|
@ -66,15 +66,15 @@ public class BlockEndLotusSeed extends BlockUnderwaterPlantWithAge {
|
||||||
if (!stem.isOf(EndBlocks.END_LOTUS_STEM)) {
|
if (!stem.isOf(EndBlocks.END_LOTUS_STEM)) {
|
||||||
stem = EndBlocks.END_LOTUS_STEM.getDefaultState();
|
stem = EndBlocks.END_LOTUS_STEM.getDefaultState();
|
||||||
if (!world.getBlockState(bpos.north()).getFluidState().isEmpty()) {
|
if (!world.getBlockState(bpos.north()).getFluidState().isEmpty()) {
|
||||||
stem = stem.with(BlockEndLotusStem.WATERLOGGED, true);
|
stem = stem.with(EndLotusStemBlock.WATERLOGGED, true);
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (world.getBlockState(bpos.offset(dir)).isOf(EndBlocks.END_LOTUS_LEAF)) {
|
if (world.getBlockState(bpos.offset(dir)).isOf(EndBlocks.END_LOTUS_LEAF)) {
|
||||||
stem = stem.with(BlockEndLotusStem.LEAF, true).with(BlockEndLotusStem.FACING, dir);
|
stem = stem.with(EndLotusStemBlock.LEAF, true).with(EndLotusStemBlock.FACING, dir);
|
||||||
}
|
}
|
||||||
|
|
||||||
BlocksHelper.setWithoutUpdate(world, bpos, stem.with(BlockEndLotusStem.SHAPE, TripleShape.TOP));
|
BlocksHelper.setWithoutUpdate(world, bpos, stem.with(EndLotusStemBlock.SHAPE, TripleShape.TOP));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -90,14 +90,14 @@ public class BlockEndLotusSeed extends BlockUnderwaterPlantWithAge {
|
||||||
private void generateLeaf(StructureWorldAccess world, BlockPos pos) {
|
private void generateLeaf(StructureWorldAccess world, BlockPos pos) {
|
||||||
Mutable p = new Mutable();
|
Mutable p = new Mutable();
|
||||||
BlockState leaf = EndBlocks.END_LOTUS_LEAF.getDefaultState();
|
BlockState leaf = EndBlocks.END_LOTUS_LEAF.getDefaultState();
|
||||||
BlocksHelper.setWithoutUpdate(world, pos, leaf.with(BlockEndLotusLeaf.SHAPE, TripleShape.BOTTOM));
|
BlocksHelper.setWithoutUpdate(world, pos, leaf.with(EndLotusLeafBlock.SHAPE, TripleShape.BOTTOM));
|
||||||
for (Direction move: BlocksHelper.HORIZONTAL) {
|
for (Direction move: BlocksHelper.HORIZONTAL) {
|
||||||
BlocksHelper.setWithoutUpdate(world, p.set(pos).move(move), leaf.with(BlockEndLotusLeaf.HORIZONTAL_FACING, move).with(BlockEndLotusLeaf.SHAPE, TripleShape.MIDDLE));
|
BlocksHelper.setWithoutUpdate(world, p.set(pos).move(move), leaf.with(EndLotusLeafBlock.HORIZONTAL_FACING, move).with(EndLotusLeafBlock.SHAPE, TripleShape.MIDDLE));
|
||||||
}
|
}
|
||||||
for (int i = 0; i < 4; i ++) {
|
for (int i = 0; i < 4; i ++) {
|
||||||
Direction d1 = BlocksHelper.HORIZONTAL[i];
|
Direction d1 = BlocksHelper.HORIZONTAL[i];
|
||||||
Direction d2 = BlocksHelper.HORIZONTAL[(i + 1) & 3];
|
Direction d2 = BlocksHelper.HORIZONTAL[(i + 1) & 3];
|
||||||
BlocksHelper.setWithoutUpdate(world, p.set(pos).move(d1).move(d2), leaf.with(BlockEndLotusLeaf.HORIZONTAL_FACING, d1).with(BlockEndLotusLeaf.SHAPE, TripleShape.TOP));
|
BlocksHelper.setWithoutUpdate(world, p.set(pos).move(d1).move(d2), leaf.with(EndLotusLeafBlock.HORIZONTAL_FACING, d1).with(EndLotusLeafBlock.SHAPE, TripleShape.TOP));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
|
@ -26,19 +26,19 @@ import net.minecraft.util.shape.VoxelShape;
|
||||||
import net.minecraft.world.BlockView;
|
import net.minecraft.world.BlockView;
|
||||||
import net.minecraft.world.WorldAccess;
|
import net.minecraft.world.WorldAccess;
|
||||||
import ru.betterend.blocks.BlockProperties.TripleShape;
|
import ru.betterend.blocks.BlockProperties.TripleShape;
|
||||||
import ru.betterend.blocks.basis.BlockBase;
|
import ru.betterend.blocks.basis.BaseBlock;
|
||||||
import ru.betterend.client.render.ERenderLayer;
|
import ru.betterend.client.render.ERenderLayer;
|
||||||
import ru.betterend.interfaces.IRenderTypeable;
|
import ru.betterend.interfaces.IRenderTypeable;
|
||||||
import ru.betterend.util.BlocksHelper;
|
import ru.betterend.util.BlocksHelper;
|
||||||
|
|
||||||
public class BlockEndLotusStem extends BlockBase implements Waterloggable, IRenderTypeable {
|
public class EndLotusStemBlock extends BaseBlock implements Waterloggable, IRenderTypeable {
|
||||||
public static final EnumProperty<Direction> FACING = Properties.FACING;
|
public static final EnumProperty<Direction> FACING = Properties.FACING;
|
||||||
public static final BooleanProperty WATERLOGGED = Properties.WATERLOGGED;
|
public static final BooleanProperty WATERLOGGED = Properties.WATERLOGGED;
|
||||||
public static final BooleanProperty LEAF = BooleanProperty.of("leaf");
|
public static final BooleanProperty LEAF = BooleanProperty.of("leaf");
|
||||||
public static final EnumProperty<TripleShape> SHAPE = BlockProperties.TRIPLE_SHAPE;
|
public static final EnumProperty<TripleShape> SHAPE = BlockProperties.TRIPLE_SHAPE;
|
||||||
private static final Map<Axis, VoxelShape> SHAPES = Maps.newEnumMap(Axis.class);
|
private static final Map<Axis, VoxelShape> SHAPES = Maps.newEnumMap(Axis.class);
|
||||||
|
|
||||||
public BlockEndLotusStem() {
|
public EndLotusStemBlock() {
|
||||||
super(FabricBlockSettings.copyOf(Blocks.OAK_PLANKS));
|
super(FabricBlockSettings.copyOf(Blocks.OAK_PLANKS));
|
||||||
this.setDefaultState(getDefaultState().with(WATERLOGGED, false).with(SHAPE, TripleShape.MIDDLE).with(LEAF, false).with(FACING, Direction.UP));
|
this.setDefaultState(getDefaultState().with(WATERLOGGED, false).with(SHAPE, TripleShape.MIDDLE).with(LEAF, false).with(FACING, Direction.UP));
|
||||||
}
|
}
|
|
@ -16,15 +16,15 @@ import net.minecraft.loot.context.LootContextParameters;
|
||||||
import net.minecraft.util.math.BlockPos;
|
import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.util.shape.VoxelShape;
|
import net.minecraft.util.shape.VoxelShape;
|
||||||
import net.minecraft.world.BlockView;
|
import net.minecraft.world.BlockView;
|
||||||
import ru.betterend.blocks.basis.BlockBaseNotFull;
|
import ru.betterend.blocks.basis.BaseBlockNotFull;
|
||||||
|
|
||||||
public class BlockPath extends BlockBaseNotFull {
|
public class EndPathBlock extends BaseBlockNotFull {
|
||||||
private static final VoxelShape SHAPE = Block.createCuboidShape(0, 0, 0, 16, 15, 16);
|
private static final VoxelShape SHAPE = Block.createCuboidShape(0, 0, 0, 16, 15, 16);
|
||||||
|
|
||||||
public BlockPath(Block source) {
|
public EndPathBlock(Block source) {
|
||||||
super(FabricBlockSettings.copyOf(source).allowsSpawning((state, world, pos, type) -> { return false; }));
|
super(FabricBlockSettings.copyOf(source).allowsSpawning((state, world, pos, type) -> { return false; }));
|
||||||
if (source instanceof BlockTerrain) {
|
if (source instanceof EndTerrainBlock) {
|
||||||
BlockTerrain terrain = (BlockTerrain) source;
|
EndTerrainBlock terrain = (EndTerrainBlock) source;
|
||||||
terrain.setPathBlock(this);
|
terrain.setPathBlock(this);
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -7,10 +7,10 @@ import net.minecraft.block.Block;
|
||||||
import net.minecraft.util.Identifier;
|
import net.minecraft.util.Identifier;
|
||||||
import net.minecraft.util.registry.Registry;
|
import net.minecraft.util.registry.Registry;
|
||||||
import ru.betterend.BetterEnd;
|
import ru.betterend.BetterEnd;
|
||||||
import ru.betterend.blocks.basis.BlockPedestal;
|
import ru.betterend.blocks.basis.PedestalBlock;
|
||||||
import ru.betterend.patterns.Patterns;
|
import ru.betterend.patterns.Patterns;
|
||||||
|
|
||||||
public class EndPedestal extends BlockPedestal {
|
public class EndPedestal extends PedestalBlock {
|
||||||
|
|
||||||
public EndPedestal(Block parent) {
|
public EndPedestal(Block parent) {
|
||||||
super(parent);
|
super(parent);
|
||||||
|
|
|
@ -4,11 +4,10 @@ import net.fabricmc.fabric.api.object.builder.v1.block.FabricBlockSettings;
|
||||||
import net.minecraft.block.Blocks;
|
import net.minecraft.block.Blocks;
|
||||||
import net.minecraft.block.MaterialColor;
|
import net.minecraft.block.MaterialColor;
|
||||||
import net.minecraft.sound.BlockSoundGroup;
|
import net.minecraft.sound.BlockSoundGroup;
|
||||||
import ru.betterend.blocks.basis.BlockBase;
|
import ru.betterend.blocks.basis.BaseBlock;
|
||||||
|
|
||||||
public class BlockStone extends BlockBase {
|
public class EndStoneBlock extends BaseBlock {
|
||||||
|
public EndStoneBlock(MaterialColor color) {
|
||||||
public BlockStone(MaterialColor color) {
|
|
||||||
super(FabricBlockSettings.copyOf(Blocks.END_STONE).materialColor(color).sounds(BlockSoundGroup.STONE));
|
super(FabricBlockSettings.copyOf(Blocks.END_STONE).materialColor(color).sounds(BlockSoundGroup.STONE));
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -29,12 +29,12 @@ import net.minecraft.util.math.Direction;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import net.minecraft.world.WorldView;
|
import net.minecraft.world.WorldView;
|
||||||
import net.minecraft.world.chunk.light.ChunkLightProvider;
|
import net.minecraft.world.chunk.light.ChunkLightProvider;
|
||||||
import ru.betterend.blocks.basis.BlockBase;
|
import ru.betterend.blocks.basis.BaseBlock;
|
||||||
|
|
||||||
public class BlockTerrain extends BlockBase {
|
public class EndTerrainBlock extends BaseBlock {
|
||||||
private Block pathBlock;
|
private Block pathBlock;
|
||||||
|
|
||||||
public BlockTerrain(MaterialColor color) {
|
public EndTerrainBlock(MaterialColor color) {
|
||||||
super(FabricBlockSettings.copyOf(Blocks.END_STONE).materialColor(color).sounds(BlockSounds.TERRAIN_SOUND).ticksRandomly());
|
super(FabricBlockSettings.copyOf(Blocks.END_STONE).materialColor(color).sounds(BlockSounds.TERRAIN_SOUND).ticksRandomly());
|
||||||
}
|
}
|
||||||
|
|
|
@ -9,9 +9,9 @@ import net.minecraft.block.MaterialColor;
|
||||||
import net.minecraft.sound.BlockSoundGroup;
|
import net.minecraft.sound.BlockSoundGroup;
|
||||||
import net.minecraft.util.math.BlockPos;
|
import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.world.BlockView;
|
import net.minecraft.world.BlockView;
|
||||||
import ru.betterend.blocks.basis.BlockBase;
|
import ru.betterend.blocks.basis.BaseBlock;
|
||||||
|
|
||||||
public class EnderBlock extends BlockBase {
|
public class EnderBlock extends BaseBlock {
|
||||||
|
|
||||||
public EnderBlock() {
|
public EnderBlock() {
|
||||||
super(FabricBlockSettings.of(Material.STONE, MaterialColor.field_25708)
|
super(FabricBlockSettings.of(Material.STONE, MaterialColor.field_25708)
|
||||||
|
|
|
@ -15,11 +15,11 @@ import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.world.BlockView;
|
import net.minecraft.world.BlockView;
|
||||||
import ru.betterend.util.MHelper;
|
import ru.betterend.util.MHelper;
|
||||||
|
|
||||||
public class BlockEndstoneDust extends FallingBlock {
|
public class EndstoneDustBlock extends FallingBlock {
|
||||||
@Environment(EnvType.CLIENT)
|
@Environment(EnvType.CLIENT)
|
||||||
private static final int COLOR = MHelper.color(226, 239, 168);
|
private static final int COLOR = MHelper.color(226, 239, 168);
|
||||||
|
|
||||||
public BlockEndstoneDust() {
|
public EndstoneDustBlock() {
|
||||||
super(FabricBlockSettings.copyOf(Blocks.SAND).materialColor(Blocks.END_STONE.getDefaultMaterialColor()));
|
super(FabricBlockSettings.copyOf(Blocks.SAND).materialColor(Blocks.END_STONE.getDefaultMaterialColor()));
|
||||||
}
|
}
|
||||||
|
|
|
@ -23,13 +23,13 @@ import net.minecraft.world.BlockView;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import net.minecraft.world.WorldAccess;
|
import net.minecraft.world.WorldAccess;
|
||||||
import net.minecraft.world.explosion.Explosion;
|
import net.minecraft.world.explosion.Explosion;
|
||||||
import ru.betterend.blocks.basis.BlockPedestal;
|
import ru.betterend.blocks.basis.PedestalBlock;
|
||||||
import ru.betterend.blocks.entities.EternalPedestalEntity;
|
import ru.betterend.blocks.entities.EternalPedestalEntity;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.registry.EndItems;
|
import ru.betterend.registry.EndItems;
|
||||||
import ru.betterend.rituals.EternalRitual;
|
import ru.betterend.rituals.EternalRitual;
|
||||||
|
|
||||||
public class EternalPedestal extends BlockPedestal {
|
public class EternalPedestal extends PedestalBlock {
|
||||||
public static final BooleanProperty ACTIVATED = BlockProperties.ACTIVE;
|
public static final BooleanProperty ACTIVATED = BlockProperties.ACTIVE;
|
||||||
|
|
||||||
public EternalPedestal() {
|
public EternalPedestal() {
|
||||||
|
|
|
@ -5,11 +5,11 @@ import net.fabricmc.api.Environment;
|
||||||
import net.minecraft.block.BlockState;
|
import net.minecraft.block.BlockState;
|
||||||
import net.minecraft.util.math.BlockPos;
|
import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.world.BlockView;
|
import net.minecraft.world.BlockView;
|
||||||
import ru.betterend.blocks.basis.BlockPlant;
|
import ru.betterend.blocks.basis.EndPlantBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
|
|
||||||
public class BlockGlowingMoss extends BlockPlant {
|
public class GlowingMossBlock extends EndPlantBlock {
|
||||||
public BlockGlowingMoss(int light) {
|
public GlowingMossBlock(int light) {
|
||||||
super(light);
|
super(light);
|
||||||
}
|
}
|
||||||
|
|
|
@ -14,13 +14,13 @@ import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.util.math.Direction;
|
import net.minecraft.util.math.Direction;
|
||||||
import net.minecraft.world.WorldAccess;
|
import net.minecraft.world.WorldAccess;
|
||||||
import net.minecraft.world.WorldView;
|
import net.minecraft.world.WorldView;
|
||||||
import ru.betterend.blocks.basis.BlockBase;
|
import ru.betterend.blocks.basis.BaseBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
|
|
||||||
public class BlockGlowingPillarLuminophor extends BlockBase {
|
public class GlowingPillarLuminophorBlock extends BaseBlock {
|
||||||
public static final BooleanProperty NATURAL = BooleanProperty.of("natural");
|
public static final BooleanProperty NATURAL = BooleanProperty.of("natural");
|
||||||
|
|
||||||
public BlockGlowingPillarLuminophor() {
|
public GlowingPillarLuminophorBlock() {
|
||||||
super(FabricBlockSettings.of(Material.LEAVES)
|
super(FabricBlockSettings.of(Material.LEAVES)
|
||||||
.materialColor(MaterialColor.ORANGE)
|
.materialColor(MaterialColor.ORANGE)
|
||||||
.breakByTool(FabricToolTags.SHEARS)
|
.breakByTool(FabricToolTags.SHEARS)
|
|
@ -5,10 +5,10 @@ import net.minecraft.block.BlockState;
|
||||||
import net.minecraft.state.StateManager;
|
import net.minecraft.state.StateManager;
|
||||||
import net.minecraft.state.property.EnumProperty;
|
import net.minecraft.state.property.EnumProperty;
|
||||||
import ru.betterend.blocks.BlockProperties.TripleShape;
|
import ru.betterend.blocks.BlockProperties.TripleShape;
|
||||||
import ru.betterend.blocks.basis.BlockUpDownPlant;
|
import ru.betterend.blocks.basis.UpDownPlantBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
|
|
||||||
public class BlockGlowingPillarRoots extends BlockUpDownPlant {
|
public class GlowingPillarRootsBlock extends UpDownPlantBlock {
|
||||||
public static final EnumProperty<TripleShape> SHAPE = BlockProperties.TRIPLE_SHAPE;
|
public static final EnumProperty<TripleShape> SHAPE = BlockProperties.TRIPLE_SHAPE;
|
||||||
|
|
||||||
@Override
|
@Override
|
|
@ -13,13 +13,13 @@ import net.minecraft.util.math.BlockPos.Mutable;
|
||||||
import net.minecraft.util.math.Direction;
|
import net.minecraft.util.math.Direction;
|
||||||
import net.minecraft.world.StructureWorldAccess;
|
import net.minecraft.world.StructureWorldAccess;
|
||||||
import ru.betterend.blocks.BlockProperties.TripleShape;
|
import ru.betterend.blocks.BlockProperties.TripleShape;
|
||||||
import ru.betterend.blocks.basis.BlockPlantWithAge;
|
import ru.betterend.blocks.basis.PlantWithAgeBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.util.BlocksHelper;
|
import ru.betterend.util.BlocksHelper;
|
||||||
import ru.betterend.util.MHelper;
|
import ru.betterend.util.MHelper;
|
||||||
|
|
||||||
public class BlockGlowingPillarSeed extends BlockPlantWithAge {
|
public class GlowingPillarSeedBlock extends PlantWithAgeBlock {
|
||||||
public BlockGlowingPillarSeed() {
|
public GlowingPillarSeedBlock() {
|
||||||
super(FabricBlockSettings.of(Material.PLANT)
|
super(FabricBlockSettings.of(Material.PLANT)
|
||||||
.luminance((state) -> { return state.get(AGE) * 3 + 3; })
|
.luminance((state) -> { return state.get(AGE) * 3 + 3; })
|
||||||
.breakByTool(FabricToolTags.SHEARS)
|
.breakByTool(FabricToolTags.SHEARS)
|
||||||
|
@ -49,7 +49,7 @@ public class BlockGlowingPillarSeed extends BlockPlantWithAge {
|
||||||
BlocksHelper.setWithUpdate(world, mut, roots.with(BlockProperties.TRIPLE_SHAPE, TripleShape.TOP));
|
BlocksHelper.setWithUpdate(world, mut, roots.with(BlockProperties.TRIPLE_SHAPE, TripleShape.TOP));
|
||||||
mut.move(Direction.UP);
|
mut.move(Direction.UP);
|
||||||
}
|
}
|
||||||
BlocksHelper.setWithUpdate(world, mut, EndBlocks.GLOWING_PILLAR_LUMINOPHOR.getDefaultState().with(BlockBlueVineLantern.NATURAL, true));
|
BlocksHelper.setWithUpdate(world, mut, EndBlocks.GLOWING_PILLAR_LUMINOPHOR.getDefaultState().with(BlueVineLanternBlock.NATURAL, true));
|
||||||
for (Direction dir: BlocksHelper.DIRECTIONS) {
|
for (Direction dir: BlocksHelper.DIRECTIONS) {
|
||||||
pos = mut.offset(dir);
|
pos = mut.offset(dir);
|
||||||
if (world.isAir(pos)) {
|
if (world.isAir(pos)) {
|
|
@ -23,17 +23,17 @@ import net.minecraft.sound.BlockSoundGroup;
|
||||||
import net.minecraft.state.StateManager;
|
import net.minecraft.state.StateManager;
|
||||||
import net.minecraft.state.property.IntProperty;
|
import net.minecraft.state.property.IntProperty;
|
||||||
import net.minecraft.util.math.MathHelper;
|
import net.minecraft.util.math.MathHelper;
|
||||||
import ru.betterend.blocks.basis.BlockBase;
|
import ru.betterend.blocks.basis.BaseBlock;
|
||||||
import ru.betterend.interfaces.IColorProvider;
|
import ru.betterend.interfaces.IColorProvider;
|
||||||
import ru.betterend.noise.OpenSimplexNoise;
|
import ru.betterend.noise.OpenSimplexNoise;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.util.MHelper;
|
import ru.betterend.util.MHelper;
|
||||||
|
|
||||||
public class BlockHelixTreeLeaves extends BlockBase implements IColorProvider {
|
public class HelixTreeLeavesBlock extends BaseBlock implements IColorProvider {
|
||||||
public static final IntProperty COLOR = IntProperty.of("color", 0, 7);
|
public static final IntProperty COLOR = IntProperty.of("color", 0, 7);
|
||||||
private static final OpenSimplexNoise NOISE = new OpenSimplexNoise(0);
|
private static final OpenSimplexNoise NOISE = new OpenSimplexNoise(0);
|
||||||
|
|
||||||
public BlockHelixTreeLeaves() {
|
public HelixTreeLeavesBlock() {
|
||||||
super(FabricBlockSettings.of(Material.LEAVES)
|
super(FabricBlockSettings.of(Material.LEAVES)
|
||||||
.materialColor(MaterialColor.ORANGE)
|
.materialColor(MaterialColor.ORANGE)
|
||||||
.breakByTool(FabricToolTags.SHEARS)
|
.breakByTool(FabricToolTags.SHEARS)
|
|
@ -1,10 +1,10 @@
|
||||||
package ru.betterend.blocks;
|
package ru.betterend.blocks;
|
||||||
|
|
||||||
import net.minecraft.world.gen.feature.Feature;
|
import net.minecraft.world.gen.feature.Feature;
|
||||||
import ru.betterend.blocks.basis.BlockFeatureSapling;
|
import ru.betterend.blocks.basis.FeatureSaplingBlock;
|
||||||
import ru.betterend.registry.EndFeatures;
|
import ru.betterend.registry.EndFeatures;
|
||||||
|
|
||||||
public class BlockHelixTreeSapling extends BlockFeatureSapling {
|
public class HelixTreeSaplingBlock extends FeatureSaplingBlock {
|
||||||
@Override
|
@Override
|
||||||
protected Feature<?> getFeature() {
|
protected Feature<?> getFeature() {
|
||||||
return EndFeatures.HELIX_TREE.getFeature();
|
return EndFeatures.HELIX_TREE.getFeature();
|
|
@ -23,15 +23,15 @@ import net.minecraft.world.BlockView;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import net.minecraft.world.WorldView;
|
import net.minecraft.world.WorldView;
|
||||||
import ru.betterend.blocks.BlockProperties.HydraluxShape;
|
import ru.betterend.blocks.BlockProperties.HydraluxShape;
|
||||||
import ru.betterend.blocks.basis.BlockUnderwaterPlant;
|
import ru.betterend.blocks.basis.UnderwaterPlantBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.registry.EndItems;
|
import ru.betterend.registry.EndItems;
|
||||||
import ru.betterend.util.MHelper;
|
import ru.betterend.util.MHelper;
|
||||||
|
|
||||||
public class BlockHydralux extends BlockUnderwaterPlant {
|
public class HydraluxBlock extends UnderwaterPlantBlock {
|
||||||
public static final EnumProperty<HydraluxShape> SHAPE = BlockProperties.HYDRALUX_SHAPE;
|
public static final EnumProperty<HydraluxShape> SHAPE = BlockProperties.HYDRALUX_SHAPE;
|
||||||
|
|
||||||
public BlockHydralux() {
|
public HydraluxBlock() {
|
||||||
super(FabricBlockSettings.of(Material.UNDERWATER_PLANT)
|
super(FabricBlockSettings.of(Material.UNDERWATER_PLANT)
|
||||||
.breakByTool(FabricToolTags.SHEARS)
|
.breakByTool(FabricToolTags.SHEARS)
|
||||||
.sounds(BlockSoundGroup.WET_GRASS)
|
.sounds(BlockSoundGroup.WET_GRASS)
|
|
@ -8,10 +8,10 @@ import net.minecraft.entity.Entity;
|
||||||
import net.minecraft.sound.BlockSoundGroup;
|
import net.minecraft.sound.BlockSoundGroup;
|
||||||
import net.minecraft.util.math.BlockPos;
|
import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import ru.betterend.blocks.basis.BlockBase;
|
import ru.betterend.blocks.basis.BaseBlock;
|
||||||
|
|
||||||
public class BlockHydraluxPetal extends BlockBase {
|
public class HydraluxPetalBlock extends BaseBlock {
|
||||||
public BlockHydraluxPetal() {
|
public HydraluxPetalBlock() {
|
||||||
this(FabricBlockSettings.of(Material.PLANT)
|
this(FabricBlockSettings.of(Material.PLANT)
|
||||||
.materialColor(MaterialColor.SPRUCE)
|
.materialColor(MaterialColor.SPRUCE)
|
||||||
.sounds(BlockSoundGroup.WART_BLOCK)
|
.sounds(BlockSoundGroup.WART_BLOCK)
|
||||||
|
@ -21,7 +21,7 @@ public class BlockHydraluxPetal extends BlockBase {
|
||||||
.breakByHand(true));
|
.breakByHand(true));
|
||||||
}
|
}
|
||||||
|
|
||||||
public BlockHydraluxPetal(FabricBlockSettings settings) {
|
public HydraluxPetalBlock(FabricBlockSettings settings) {
|
||||||
super(settings);
|
super(settings);
|
||||||
}
|
}
|
||||||
|
|
|
@ -9,8 +9,8 @@ import net.minecraft.util.Identifier;
|
||||||
import ru.betterend.interfaces.IColorProvider;
|
import ru.betterend.interfaces.IColorProvider;
|
||||||
import ru.betterend.patterns.Patterns;
|
import ru.betterend.patterns.Patterns;
|
||||||
|
|
||||||
public class BlockHydraluxPetalColored extends BlockHydraluxPetal implements IColorProvider {
|
public class HydraluxPetalColoredBlock extends HydraluxPetalBlock implements IColorProvider {
|
||||||
public BlockHydraluxPetalColored(FabricBlockSettings settings) {
|
public HydraluxPetalColoredBlock(FabricBlockSettings settings) {
|
||||||
super(settings);
|
super(settings);
|
||||||
}
|
}
|
||||||
|
|
|
@ -8,12 +8,12 @@ import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.util.math.BlockPos.Mutable;
|
import net.minecraft.util.math.BlockPos.Mutable;
|
||||||
import net.minecraft.world.StructureWorldAccess;
|
import net.minecraft.world.StructureWorldAccess;
|
||||||
import ru.betterend.blocks.BlockProperties.HydraluxShape;
|
import ru.betterend.blocks.BlockProperties.HydraluxShape;
|
||||||
import ru.betterend.blocks.basis.BlockUnderwaterPlantWithAge;
|
import ru.betterend.blocks.basis.UnderwaterPlantWithAgeBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.util.BlocksHelper;
|
import ru.betterend.util.BlocksHelper;
|
||||||
import ru.betterend.util.MHelper;
|
import ru.betterend.util.MHelper;
|
||||||
|
|
||||||
public class BlockHydraluxSapling extends BlockUnderwaterPlantWithAge {
|
public class HydraluxSaplingBlock extends UnderwaterPlantWithAgeBlock {
|
||||||
@Override
|
@Override
|
||||||
public void grow(StructureWorldAccess world, Random random, BlockPos pos) {
|
public void grow(StructureWorldAccess world, Random random, BlockPos pos) {
|
||||||
int h = MHelper.randRange(4, 8, random);
|
int h = MHelper.randRange(4, 8, random);
|
|
@ -36,18 +36,18 @@ import net.minecraft.world.BlockView;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import net.minecraft.world.WorldAccess;
|
import net.minecraft.world.WorldAccess;
|
||||||
import net.minecraft.world.WorldView;
|
import net.minecraft.world.WorldView;
|
||||||
import ru.betterend.blocks.basis.BlockBaseNotFull;
|
import ru.betterend.blocks.basis.BaseBlockNotFull;
|
||||||
import ru.betterend.blocks.entities.BlockEntityHydrothermalVent;
|
import ru.betterend.blocks.entities.BlockEntityHydrothermalVent;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.registry.EndParticles;
|
import ru.betterend.registry.EndParticles;
|
||||||
import ru.betterend.util.BlocksHelper;
|
import ru.betterend.util.BlocksHelper;
|
||||||
|
|
||||||
public class BlockHydrothermalVent extends BlockBaseNotFull implements BlockEntityProvider, FluidFillable, Waterloggable {
|
public class HydrothermalVentBlock extends BaseBlockNotFull implements BlockEntityProvider, FluidFillable, Waterloggable {
|
||||||
public static final BooleanProperty WATERLOGGED = Properties.WATERLOGGED;
|
public static final BooleanProperty WATERLOGGED = Properties.WATERLOGGED;
|
||||||
public static final BooleanProperty ACTIVATED = BlockProperties.ACTIVE;
|
public static final BooleanProperty ACTIVATED = BlockProperties.ACTIVE;
|
||||||
private static final VoxelShape SHAPE = Block.createCuboidShape(1, 1, 1, 15, 16, 15);
|
private static final VoxelShape SHAPE = Block.createCuboidShape(1, 1, 1, 15, 16, 15);
|
||||||
|
|
||||||
public BlockHydrothermalVent() {
|
public HydrothermalVentBlock() {
|
||||||
super(FabricBlockSettings.of(Material.STONE)
|
super(FabricBlockSettings.of(Material.STONE)
|
||||||
.breakByTool(FabricToolTags.PICKAXES)
|
.breakByTool(FabricToolTags.PICKAXES)
|
||||||
.sounds(BlockSoundGroup.STONE)
|
.sounds(BlockSoundGroup.STONE)
|
|
@ -14,11 +14,11 @@ import net.minecraft.util.shape.VoxelShape;
|
||||||
import net.minecraft.util.shape.VoxelShapes;
|
import net.minecraft.util.shape.VoxelShapes;
|
||||||
import net.minecraft.world.BlockView;
|
import net.minecraft.world.BlockView;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import ru.betterend.blocks.basis.BlockPedestal;
|
import ru.betterend.blocks.basis.PedestalBlock;
|
||||||
import ru.betterend.blocks.entities.InfusionPedestalEntity;
|
import ru.betterend.blocks.entities.InfusionPedestalEntity;
|
||||||
import ru.betterend.rituals.InfusionRitual;
|
import ru.betterend.rituals.InfusionRitual;
|
||||||
|
|
||||||
public class InfusionPedestal extends BlockPedestal {
|
public class InfusionPedestal extends PedestalBlock {
|
||||||
private static final VoxelShape SHAPE_DEFAULT;
|
private static final VoxelShape SHAPE_DEFAULT;
|
||||||
private static final VoxelShape SHAPE_PEDESTAL_TOP;
|
private static final VoxelShape SHAPE_PEDESTAL_TOP;
|
||||||
|
|
||||||
|
|
|
@ -29,14 +29,14 @@ import ru.betterend.patterns.BlockPatterned;
|
||||||
import ru.betterend.patterns.Patterns;
|
import ru.betterend.patterns.Patterns;
|
||||||
import ru.betterend.util.MHelper;
|
import ru.betterend.util.MHelper;
|
||||||
|
|
||||||
public class BlockJellyshroomCap extends SlimeBlock implements IRenderTypeable, BlockPatterned, IColorProvider {
|
public class JellyshroomCapBlock extends SlimeBlock implements IRenderTypeable, BlockPatterned, IColorProvider {
|
||||||
public static final IntProperty COLOR = IntProperty.of("color", 0, 7);
|
public static final IntProperty COLOR = IntProperty.of("color", 0, 7);
|
||||||
private static final OpenSimplexNoise NOISE = new OpenSimplexNoise(0);
|
private static final OpenSimplexNoise NOISE = new OpenSimplexNoise(0);
|
||||||
private final Vec3i colorStart;
|
private final Vec3i colorStart;
|
||||||
private final Vec3i colorEnd;
|
private final Vec3i colorEnd;
|
||||||
private final int coloritem;
|
private final int coloritem;
|
||||||
|
|
||||||
public BlockJellyshroomCap(int r1, int g1, int b1, int r2, int g2, int b2) {
|
public JellyshroomCapBlock(int r1, int g1, int b1, int r2, int g2, int b2) {
|
||||||
super(FabricBlockSettings.copyOf(Blocks.SLIME_BLOCK));
|
super(FabricBlockSettings.copyOf(Blocks.SLIME_BLOCK));
|
||||||
colorStart = new Vec3i(r1, g1, b1);
|
colorStart = new Vec3i(r1, g1, b1);
|
||||||
colorEnd = new Vec3i(r2, g2, b2);
|
colorEnd = new Vec3i(r2, g2, b2);
|
|
@ -4,12 +4,12 @@ import net.minecraft.block.BlockState;
|
||||||
import net.minecraft.util.math.BlockPos;
|
import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.world.WorldView;
|
import net.minecraft.world.WorldView;
|
||||||
import net.minecraft.world.gen.feature.Feature;
|
import net.minecraft.world.gen.feature.Feature;
|
||||||
import ru.betterend.blocks.basis.BlockFeatureSapling;
|
import ru.betterend.blocks.basis.FeatureSaplingBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.registry.EndFeatures;
|
import ru.betterend.registry.EndFeatures;
|
||||||
|
|
||||||
public class BlockLacugroveSapling extends BlockFeatureSapling {
|
public class LacugroveSaplingBlock extends FeatureSaplingBlock {
|
||||||
public BlockLacugroveSapling() {
|
public LacugroveSaplingBlock() {
|
||||||
super();
|
super();
|
||||||
}
|
}
|
||||||
|
|
|
@ -11,14 +11,14 @@ import net.minecraft.util.math.Direction;
|
||||||
import net.minecraft.world.WorldAccess;
|
import net.minecraft.world.WorldAccess;
|
||||||
import net.minecraft.world.WorldView;
|
import net.minecraft.world.WorldView;
|
||||||
import ru.betterend.blocks.BlockProperties.PentaShape;
|
import ru.betterend.blocks.BlockProperties.PentaShape;
|
||||||
import ru.betterend.blocks.basis.BlockPlant;
|
import ru.betterend.blocks.basis.EndPlantBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
|
|
||||||
public class BlockLanceleaf extends BlockPlant {
|
public class LanceleafBlock extends EndPlantBlock {
|
||||||
public static final EnumProperty<PentaShape> SHAPE = BlockProperties.PENTA_SHAPE;
|
public static final EnumProperty<PentaShape> SHAPE = BlockProperties.PENTA_SHAPE;
|
||||||
public static final IntProperty ROTATION = BlockProperties.ROTATION;
|
public static final IntProperty ROTATION = BlockProperties.ROTATION;
|
||||||
|
|
||||||
public BlockLanceleaf() {
|
public LanceleafBlock() {
|
||||||
super();
|
super();
|
||||||
}
|
}
|
||||||
|
|
|
@ -8,12 +8,12 @@ import net.minecraft.util.math.BlockPos.Mutable;
|
||||||
import net.minecraft.util.math.Direction;
|
import net.minecraft.util.math.Direction;
|
||||||
import net.minecraft.world.StructureWorldAccess;
|
import net.minecraft.world.StructureWorldAccess;
|
||||||
import ru.betterend.blocks.BlockProperties.PentaShape;
|
import ru.betterend.blocks.BlockProperties.PentaShape;
|
||||||
import ru.betterend.blocks.basis.BlockPlantWithAge;
|
import ru.betterend.blocks.basis.PlantWithAgeBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.util.BlocksHelper;
|
import ru.betterend.util.BlocksHelper;
|
||||||
import ru.betterend.util.MHelper;
|
import ru.betterend.util.MHelper;
|
||||||
|
|
||||||
public class BlockLanceleafSeed extends BlockPlantWithAge {
|
public class LanceleafSeedBlock extends PlantWithAgeBlock {
|
||||||
@Override
|
@Override
|
||||||
public void growAdult(StructureWorldAccess world, Random random, BlockPos pos) {
|
public void growAdult(StructureWorldAccess world, Random random, BlockPos pos) {
|
||||||
int height = MHelper.randRange(4, 6, random);
|
int height = MHelper.randRange(4, 6, random);
|
|
@ -19,13 +19,13 @@ import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.util.math.Direction;
|
import net.minecraft.util.math.Direction;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import net.minecraft.world.WorldAccess;
|
import net.minecraft.world.WorldAccess;
|
||||||
import ru.betterend.blocks.basis.BlockBaseNotFull;
|
import ru.betterend.blocks.basis.BaseBlockNotFull;
|
||||||
import ru.betterend.client.render.ERenderLayer;
|
import ru.betterend.client.render.ERenderLayer;
|
||||||
import ru.betterend.interfaces.IRenderTypeable;
|
import ru.betterend.interfaces.IRenderTypeable;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
|
|
||||||
public class BlockMengerSponge extends BlockBaseNotFull implements IRenderTypeable {
|
public class MengerSpongeBlock extends BaseBlockNotFull implements IRenderTypeable {
|
||||||
public BlockMengerSponge() {
|
public MengerSpongeBlock() {
|
||||||
super(FabricBlockSettings.copyOf(Blocks.SPONGE).nonOpaque());
|
super(FabricBlockSettings.copyOf(Blocks.SPONGE).nonOpaque());
|
||||||
}
|
}
|
||||||
|
|
|
@ -16,14 +16,14 @@ import net.minecraft.sound.SoundEvents;
|
||||||
import net.minecraft.util.math.BlockPos;
|
import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.util.math.Direction;
|
import net.minecraft.util.math.Direction;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import ru.betterend.blocks.basis.BlockBaseNotFull;
|
import ru.betterend.blocks.basis.BaseBlockNotFull;
|
||||||
import ru.betterend.client.render.ERenderLayer;
|
import ru.betterend.client.render.ERenderLayer;
|
||||||
import ru.betterend.interfaces.IRenderTypeable;
|
import ru.betterend.interfaces.IRenderTypeable;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.util.BlocksHelper;
|
import ru.betterend.util.BlocksHelper;
|
||||||
|
|
||||||
public class BlockMengerSpongeWet extends BlockBaseNotFull implements IRenderTypeable {
|
public class MengerSpongeWetBlock extends BaseBlockNotFull implements IRenderTypeable {
|
||||||
public BlockMengerSpongeWet() {
|
public MengerSpongeWetBlock() {
|
||||||
super(FabricBlockSettings.copyOf(Blocks.WET_SPONGE).nonOpaque());
|
super(FabricBlockSettings.copyOf(Blocks.WET_SPONGE).nonOpaque());
|
||||||
}
|
}
|
||||||
|
|
|
@ -9,13 +9,13 @@ import net.minecraft.item.ItemPlacementContext;
|
||||||
import net.minecraft.sound.BlockSoundGroup;
|
import net.minecraft.sound.BlockSoundGroup;
|
||||||
import net.minecraft.state.StateManager;
|
import net.minecraft.state.StateManager;
|
||||||
import net.minecraft.state.property.BooleanProperty;
|
import net.minecraft.state.property.BooleanProperty;
|
||||||
import ru.betterend.blocks.basis.BlockBase;
|
import ru.betterend.blocks.basis.BaseBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
|
|
||||||
public class BlockMossyGlowshroomCap extends BlockBase {
|
public class MossyGlowshroomCapBlock extends BaseBlock {
|
||||||
public static final BooleanProperty TRANSITION = BooleanProperty.of("transition");
|
public static final BooleanProperty TRANSITION = BooleanProperty.of("transition");
|
||||||
|
|
||||||
public BlockMossyGlowshroomCap() {
|
public MossyGlowshroomCapBlock() {
|
||||||
super(FabricBlockSettings.of(Material.WOOD).breakByTool(FabricToolTags.AXES).sounds(BlockSoundGroup.WOOD));
|
super(FabricBlockSettings.of(Material.WOOD).breakByTool(FabricToolTags.AXES).sounds(BlockSoundGroup.WOOD));
|
||||||
this.setDefaultState(this.stateManager.getDefaultState().with(TRANSITION, false));
|
this.setDefaultState(this.stateManager.getDefaultState().with(TRANSITION, false));
|
||||||
}
|
}
|
|
@ -4,10 +4,10 @@ import net.fabricmc.fabric.api.object.builder.v1.block.FabricBlockSettings;
|
||||||
import net.fabricmc.fabric.api.tool.attribute.v1.FabricToolTags;
|
import net.fabricmc.fabric.api.tool.attribute.v1.FabricToolTags;
|
||||||
import net.minecraft.block.Material;
|
import net.minecraft.block.Material;
|
||||||
import net.minecraft.sound.BlockSoundGroup;
|
import net.minecraft.sound.BlockSoundGroup;
|
||||||
import ru.betterend.blocks.basis.BlockBase;
|
import ru.betterend.blocks.basis.BaseBlock;
|
||||||
|
|
||||||
public class BlockMossyGlowshroomHymenophore extends BlockBase {
|
public class MossyGlowshroomHymenophoreBlock extends BaseBlock {
|
||||||
public BlockMossyGlowshroomHymenophore() {
|
public MossyGlowshroomHymenophoreBlock() {
|
||||||
super(FabricBlockSettings.of(Material.WOOD).breakByTool(FabricToolTags.AXES).sounds(BlockSoundGroup.WART_BLOCK).luminance(15));
|
super(FabricBlockSettings.of(Material.WOOD).breakByTool(FabricToolTags.AXES).sounds(BlockSoundGroup.WART_BLOCK).luminance(15));
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -4,12 +4,12 @@ import net.minecraft.block.BlockState;
|
||||||
import net.minecraft.util.math.BlockPos;
|
import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.world.WorldView;
|
import net.minecraft.world.WorldView;
|
||||||
import net.minecraft.world.gen.feature.Feature;
|
import net.minecraft.world.gen.feature.Feature;
|
||||||
import ru.betterend.blocks.basis.BlockFeatureSapling;
|
import ru.betterend.blocks.basis.FeatureSaplingBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.registry.EndFeatures;
|
import ru.betterend.registry.EndFeatures;
|
||||||
|
|
||||||
public class BlockMossyGlowshroomSapling extends BlockFeatureSapling {
|
public class MossyGlowshroomSaplingBlock extends FeatureSaplingBlock {
|
||||||
public BlockMossyGlowshroomSapling() {
|
public MossyGlowshroomSaplingBlock() {
|
||||||
super(7);
|
super(7);
|
||||||
}
|
}
|
||||||
|
|
|
@ -12,10 +12,10 @@ import net.minecraft.entity.effect.StatusEffects;
|
||||||
import net.minecraft.particle.ParticleTypes;
|
import net.minecraft.particle.ParticleTypes;
|
||||||
import net.minecraft.util.math.BlockPos;
|
import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import ru.betterend.blocks.basis.BlockPlant;
|
import ru.betterend.blocks.basis.EndPlantBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
|
|
||||||
public class BlockMurkweed extends BlockPlant {
|
public class MurkweedBlock extends EndPlantBlock {
|
||||||
@Override
|
@Override
|
||||||
@Environment(EnvType.CLIENT)
|
@Environment(EnvType.CLIENT)
|
||||||
public void randomDisplayTick(BlockState state, World world, BlockPos pos, Random random) {
|
public void randomDisplayTick(BlockState state, World world, BlockPos pos, Random random) {
|
|
@ -17,11 +17,11 @@ import net.minecraft.loot.context.LootContext;
|
||||||
import net.minecraft.loot.context.LootContextParameters;
|
import net.minecraft.loot.context.LootContextParameters;
|
||||||
import net.minecraft.util.math.BlockPos;
|
import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import ru.betterend.blocks.basis.BlockPlant;
|
import ru.betterend.blocks.basis.EndPlantBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.util.MHelper;
|
import ru.betterend.util.MHelper;
|
||||||
|
|
||||||
public class BlockNeedlegrass extends BlockPlant {
|
public class NeedlegrassBlock extends EndPlantBlock {
|
||||||
@Override
|
@Override
|
||||||
public void onEntityCollision(BlockState state, World world, BlockPos pos, Entity entity) {
|
public void onEntityCollision(BlockState state, World world, BlockPos pos, Entity entity) {
|
||||||
if (entity instanceof LivingEntity) {
|
if (entity instanceof LivingEntity) {
|
|
@ -6,10 +6,10 @@ import java.util.Map;
|
||||||
import net.minecraft.block.Block;
|
import net.minecraft.block.Block;
|
||||||
import net.minecraft.util.Identifier;
|
import net.minecraft.util.Identifier;
|
||||||
import net.minecraft.util.registry.Registry;
|
import net.minecraft.util.registry.Registry;
|
||||||
import ru.betterend.blocks.basis.BlockPedestal;
|
import ru.betterend.blocks.basis.PedestalBlock;
|
||||||
import ru.betterend.patterns.Patterns;
|
import ru.betterend.patterns.Patterns;
|
||||||
|
|
||||||
public class PedestalVanilla extends BlockPedestal {
|
public class PedestalVanilla extends PedestalBlock {
|
||||||
|
|
||||||
public PedestalVanilla(Block parent) {
|
public PedestalVanilla(Block parent) {
|
||||||
super(parent);
|
super(parent);
|
||||||
|
|
|
@ -4,12 +4,12 @@ import net.minecraft.block.BlockState;
|
||||||
import net.minecraft.util.math.BlockPos;
|
import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.world.WorldView;
|
import net.minecraft.world.WorldView;
|
||||||
import net.minecraft.world.gen.feature.Feature;
|
import net.minecraft.world.gen.feature.Feature;
|
||||||
import ru.betterend.blocks.basis.BlockFeatureSapling;
|
import ru.betterend.blocks.basis.FeatureSaplingBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.registry.EndFeatures;
|
import ru.betterend.registry.EndFeatures;
|
||||||
|
|
||||||
public class BlockPythadendronSapling extends BlockFeatureSapling {
|
public class PythadendronSaplingBlock extends FeatureSaplingBlock {
|
||||||
public BlockPythadendronSapling() {
|
public PythadendronSaplingBlock() {
|
||||||
super();
|
super();
|
||||||
}
|
}
|
||||||
|
|
|
@ -36,7 +36,7 @@ import net.minecraft.world.World;
|
||||||
import net.minecraft.world.WorldAccess;
|
import net.minecraft.world.WorldAccess;
|
||||||
import net.minecraft.world.WorldView;
|
import net.minecraft.world.WorldView;
|
||||||
import ru.betterend.blocks.BlockProperties.TripleShape;
|
import ru.betterend.blocks.BlockProperties.TripleShape;
|
||||||
import ru.betterend.blocks.basis.BlockBase;
|
import ru.betterend.blocks.basis.BaseBlock;
|
||||||
import ru.betterend.client.render.ERenderLayer;
|
import ru.betterend.client.render.ERenderLayer;
|
||||||
import ru.betterend.interfaces.IColorProvider;
|
import ru.betterend.interfaces.IColorProvider;
|
||||||
import ru.betterend.interfaces.IRenderTypeable;
|
import ru.betterend.interfaces.IRenderTypeable;
|
||||||
|
@ -46,13 +46,13 @@ import ru.betterend.registry.EndItems;
|
||||||
import ru.betterend.util.BlocksHelper;
|
import ru.betterend.util.BlocksHelper;
|
||||||
import ru.betterend.util.MHelper;
|
import ru.betterend.util.MHelper;
|
||||||
|
|
||||||
public class BlockRespawnObelisk extends BlockBase implements IColorProvider, IRenderTypeable {
|
public class RespawnObeliskBlock extends BaseBlock implements IColorProvider, IRenderTypeable {
|
||||||
private static final VoxelShape VOXEL_SHAPE_BOTTOM = Block.createCuboidShape(1, 0, 1, 15, 16, 15);
|
private static final VoxelShape VOXEL_SHAPE_BOTTOM = Block.createCuboidShape(1, 0, 1, 15, 16, 15);
|
||||||
private static final VoxelShape VOXEL_SHAPE_MIDDLE_TOP = Block.createCuboidShape(2, 0, 2, 14, 16, 14);
|
private static final VoxelShape VOXEL_SHAPE_MIDDLE_TOP = Block.createCuboidShape(2, 0, 2, 14, 16, 14);
|
||||||
|
|
||||||
public static final EnumProperty<TripleShape> SHAPE = BlockProperties.TRIPLE_SHAPE;
|
public static final EnumProperty<TripleShape> SHAPE = BlockProperties.TRIPLE_SHAPE;
|
||||||
|
|
||||||
public BlockRespawnObelisk() {
|
public RespawnObeliskBlock() {
|
||||||
super(FabricBlockSettings.copyOf(Blocks.END_STONE).luminance((state) -> {
|
super(FabricBlockSettings.copyOf(Blocks.END_STONE).luminance((state) -> {
|
||||||
return (state.get(SHAPE) == TripleShape.BOTTOM) ? 0 : 15;
|
return (state.get(SHAPE) == TripleShape.BOTTOM) ? 0 : 15;
|
||||||
}));
|
}));
|
|
@ -6,10 +6,10 @@ import net.minecraft.block.BlockState;
|
||||||
import net.minecraft.block.Blocks;
|
import net.minecraft.block.Blocks;
|
||||||
import net.minecraft.state.StateManager;
|
import net.minecraft.state.StateManager;
|
||||||
import net.minecraft.state.property.BooleanProperty;
|
import net.minecraft.state.property.BooleanProperty;
|
||||||
import ru.betterend.blocks.basis.BlockBase;
|
import ru.betterend.blocks.basis.BaseBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
|
|
||||||
public class RunedFlavolite extends BlockBase {
|
public class RunedFlavolite extends BaseBlock {
|
||||||
public static final BooleanProperty ACTIVATED = BlockProperties.ACTIVE;
|
public static final BooleanProperty ACTIVATED = BlockProperties.ACTIVE;
|
||||||
|
|
||||||
public RunedFlavolite() {
|
public RunedFlavolite() {
|
||||||
|
|
|
@ -16,12 +16,12 @@ import net.minecraft.util.shape.VoxelShape;
|
||||||
import net.minecraft.world.BlockView;
|
import net.minecraft.world.BlockView;
|
||||||
import net.minecraft.world.StructureWorldAccess;
|
import net.minecraft.world.StructureWorldAccess;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import ru.betterend.blocks.basis.BlockPlantWithAge;
|
import ru.betterend.blocks.basis.PlantWithAgeBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.registry.EndItems;
|
import ru.betterend.registry.EndItems;
|
||||||
import ru.betterend.util.MHelper;
|
import ru.betterend.util.MHelper;
|
||||||
|
|
||||||
public class BlockShadowBerry extends BlockPlantWithAge {
|
public class ShadowBerryBlock extends PlantWithAgeBlock {
|
||||||
private static final VoxelShape SHAPE = Block.createCuboidShape(1, 0, 1, 15, 8, 15);
|
private static final VoxelShape SHAPE = Block.createCuboidShape(1, 0, 1, 15, 8, 15);
|
||||||
|
|
||||||
@Override
|
@Override
|
|
@ -10,8 +10,8 @@ import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import ru.betterend.registry.EndParticles;
|
import ru.betterend.registry.EndParticles;
|
||||||
|
|
||||||
public class BlockShadowGrass extends BlockTerrain {
|
public class ShadowGrassBlock extends EndTerrainBlock {
|
||||||
public BlockShadowGrass() {
|
public ShadowGrassBlock() {
|
||||||
super(MaterialColor.BLACK);
|
super(MaterialColor.BLACK);
|
||||||
}
|
}
|
||||||
|
|
|
@ -27,18 +27,18 @@ import net.minecraft.util.shape.VoxelShape;
|
||||||
import net.minecraft.world.BlockView;
|
import net.minecraft.world.BlockView;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import net.minecraft.world.WorldAccess;
|
import net.minecraft.world.WorldAccess;
|
||||||
import ru.betterend.blocks.basis.BlockBase;
|
import ru.betterend.blocks.basis.BaseBlock;
|
||||||
import ru.betterend.client.render.ERenderLayer;
|
import ru.betterend.client.render.ERenderLayer;
|
||||||
import ru.betterend.interfaces.IRenderTypeable;
|
import ru.betterend.interfaces.IRenderTypeable;
|
||||||
import ru.betterend.util.BlocksHelper;
|
import ru.betterend.util.BlocksHelper;
|
||||||
|
|
||||||
public class BlockSilkMothNest extends BlockBase implements IRenderTypeable {
|
public class SilkMothNestBlock extends BaseBlock implements IRenderTypeable {
|
||||||
public static final BooleanProperty ACTIVE = BlockProperties.ACTIVE;
|
public static final BooleanProperty ACTIVE = BlockProperties.ACTIVE;
|
||||||
public static final DirectionProperty FACING = Properties.HORIZONTAL_FACING;
|
public static final DirectionProperty FACING = Properties.HORIZONTAL_FACING;
|
||||||
private static final VoxelShape TOP = createCuboidShape(6, 0, 6, 10, 16, 10);
|
private static final VoxelShape TOP = createCuboidShape(6, 0, 6, 10, 16, 10);
|
||||||
private static final VoxelShape BOTTOM = createCuboidShape(0, 0, 0, 16, 16, 16);
|
private static final VoxelShape BOTTOM = createCuboidShape(0, 0, 0, 16, 16, 16);
|
||||||
|
|
||||||
public BlockSilkMothNest() {
|
public SilkMothNestBlock() {
|
||||||
super(FabricBlockSettings.of(Material.WOOL).hardness(0.5F).resistance(0.1F).sounds(BlockSoundGroup.WOOL).nonOpaque());
|
super(FabricBlockSettings.of(Material.WOOL).hardness(0.5F).resistance(0.1F).sounds(BlockSoundGroup.WOOL).nonOpaque());
|
||||||
this.setDefaultState(getDefaultState().with(ACTIVE, true));
|
this.setDefaultState(getDefaultState().with(ACTIVE, true));
|
||||||
}
|
}
|
|
@ -29,17 +29,17 @@ import net.minecraft.util.shape.VoxelShapes;
|
||||||
import net.minecraft.world.BlockView;
|
import net.minecraft.world.BlockView;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import net.minecraft.world.WorldView;
|
import net.minecraft.world.WorldView;
|
||||||
import ru.betterend.blocks.basis.BlockAttached;
|
import ru.betterend.blocks.basis.AttachedBlock;
|
||||||
import ru.betterend.client.render.ERenderLayer;
|
import ru.betterend.client.render.ERenderLayer;
|
||||||
import ru.betterend.interfaces.IRenderTypeable;
|
import ru.betterend.interfaces.IRenderTypeable;
|
||||||
import ru.betterend.registry.EndFeatures;
|
import ru.betterend.registry.EndFeatures;
|
||||||
import ru.betterend.registry.EndTags;
|
import ru.betterend.registry.EndTags;
|
||||||
import ru.betterend.util.BlocksHelper;
|
import ru.betterend.util.BlocksHelper;
|
||||||
|
|
||||||
public class BlockSmallJellyshroom extends BlockAttached implements IRenderTypeable, Fertilizable {
|
public class SmallJellyshroomBlock extends AttachedBlock implements IRenderTypeable, Fertilizable {
|
||||||
private static final EnumMap<Direction, VoxelShape> BOUNDING_SHAPES = Maps.newEnumMap(Direction.class);
|
private static final EnumMap<Direction, VoxelShape> BOUNDING_SHAPES = Maps.newEnumMap(Direction.class);
|
||||||
|
|
||||||
public BlockSmallJellyshroom() {
|
public SmallJellyshroomBlock() {
|
||||||
super(FabricBlockSettings.of(Material.PLANT)
|
super(FabricBlockSettings.of(Material.PLANT)
|
||||||
.breakByTool(FabricToolTags.SHEARS)
|
.breakByTool(FabricToolTags.SHEARS)
|
||||||
.sounds(BlockSoundGroup.NETHER_WART)
|
.sounds(BlockSoundGroup.NETHER_WART)
|
|
@ -34,19 +34,19 @@ import net.minecraft.util.shape.VoxelShapes;
|
||||||
import net.minecraft.world.BlockView;
|
import net.minecraft.world.BlockView;
|
||||||
import net.minecraft.world.WorldAccess;
|
import net.minecraft.world.WorldAccess;
|
||||||
import net.minecraft.world.WorldView;
|
import net.minecraft.world.WorldView;
|
||||||
import ru.betterend.blocks.basis.BlockAttached;
|
import ru.betterend.blocks.basis.AttachedBlock;
|
||||||
import ru.betterend.client.render.ERenderLayer;
|
import ru.betterend.client.render.ERenderLayer;
|
||||||
import ru.betterend.interfaces.IRenderTypeable;
|
import ru.betterend.interfaces.IRenderTypeable;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.registry.EndItems;
|
import ru.betterend.registry.EndItems;
|
||||||
import ru.betterend.util.MHelper;
|
import ru.betterend.util.MHelper;
|
||||||
|
|
||||||
public class BlockSulphurCrystal extends BlockAttached implements IRenderTypeable, Waterloggable, FluidFillable {
|
public class SulphurCrystalBlock extends AttachedBlock implements IRenderTypeable, Waterloggable, FluidFillable {
|
||||||
private static final EnumMap<Direction, VoxelShape> BOUNDING_SHAPES = Maps.newEnumMap(Direction.class);
|
private static final EnumMap<Direction, VoxelShape> BOUNDING_SHAPES = Maps.newEnumMap(Direction.class);
|
||||||
public static final IntProperty AGE = IntProperty.of("age", 0, 2);
|
public static final IntProperty AGE = IntProperty.of("age", 0, 2);
|
||||||
public static final BooleanProperty WATERLOGGED = Properties.WATERLOGGED;
|
public static final BooleanProperty WATERLOGGED = Properties.WATERLOGGED;
|
||||||
|
|
||||||
public BlockSulphurCrystal() {
|
public SulphurCrystalBlock() {
|
||||||
super(FabricBlockSettings.of(Material.STONE)
|
super(FabricBlockSettings.of(Material.STONE)
|
||||||
.materialColor(MaterialColor.YELLOW)
|
.materialColor(MaterialColor.YELLOW)
|
||||||
.breakByTool(FabricToolTags.PICKAXES)
|
.breakByTool(FabricToolTags.PICKAXES)
|
|
@ -12,15 +12,15 @@ import net.minecraft.util.math.MathHelper;
|
||||||
import net.minecraft.util.math.Vec3i;
|
import net.minecraft.util.math.Vec3i;
|
||||||
import net.minecraft.world.BlockView;
|
import net.minecraft.world.BlockView;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import ru.betterend.blocks.basis.BlockVine;
|
import ru.betterend.blocks.basis.VineBlock;
|
||||||
import ru.betterend.interfaces.IColorProvider;
|
import ru.betterend.interfaces.IColorProvider;
|
||||||
import ru.betterend.registry.EndParticles;
|
import ru.betterend.registry.EndParticles;
|
||||||
import ru.betterend.util.MHelper;
|
import ru.betterend.util.MHelper;
|
||||||
|
|
||||||
public class BlockTenaneaFlowers extends BlockVine implements IColorProvider {
|
public class TenaneaFlowersBlock extends VineBlock implements IColorProvider {
|
||||||
public static final Vec3i[] COLORS;
|
public static final Vec3i[] COLORS;
|
||||||
|
|
||||||
public BlockTenaneaFlowers() {
|
public TenaneaFlowersBlock() {
|
||||||
super(15);
|
super(15);
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,12 +4,12 @@ import net.minecraft.block.BlockState;
|
||||||
import net.minecraft.util.math.BlockPos;
|
import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.world.WorldView;
|
import net.minecraft.world.WorldView;
|
||||||
import net.minecraft.world.gen.feature.Feature;
|
import net.minecraft.world.gen.feature.Feature;
|
||||||
import ru.betterend.blocks.basis.BlockFeatureSapling;
|
import ru.betterend.blocks.basis.FeatureSaplingBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.registry.EndFeatures;
|
import ru.betterend.registry.EndFeatures;
|
||||||
|
|
||||||
public class BlockTenaneaSapling extends BlockFeatureSapling {
|
public class TenaneaSaplingBlock extends FeatureSaplingBlock {
|
||||||
public BlockTenaneaSapling() {
|
public TenaneaSaplingBlock() {
|
||||||
super();
|
super();
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,9 +4,9 @@ import net.fabricmc.fabric.api.object.builder.v1.block.FabricBlockSettings;
|
||||||
import net.minecraft.block.Material;
|
import net.minecraft.block.Material;
|
||||||
import net.minecraft.block.MaterialColor;
|
import net.minecraft.block.MaterialColor;
|
||||||
import net.minecraft.sound.BlockSoundGroup;
|
import net.minecraft.sound.BlockSoundGroup;
|
||||||
import ru.betterend.blocks.basis.BlockBase;
|
import ru.betterend.blocks.basis.BaseBlock;
|
||||||
|
|
||||||
public class TerminiteBlock extends BlockBase {
|
public class TerminiteBlock extends BaseBlock {
|
||||||
public TerminiteBlock() {
|
public TerminiteBlock() {
|
||||||
super(FabricBlockSettings.of(Material.METAL, MaterialColor.field_25708)
|
super(FabricBlockSettings.of(Material.METAL, MaterialColor.field_25708)
|
||||||
.hardness(7F)
|
.hardness(7F)
|
||||||
|
|
|
@ -2,12 +2,12 @@ package ru.betterend.blocks;
|
||||||
|
|
||||||
import net.minecraft.block.Block;
|
import net.minecraft.block.Block;
|
||||||
import net.minecraft.block.BlockState;
|
import net.minecraft.block.BlockState;
|
||||||
import ru.betterend.blocks.basis.BlockPlant;
|
import ru.betterend.blocks.basis.EndPlantBlock;
|
||||||
|
|
||||||
public class BlockTerrainPlant extends BlockPlant {
|
public class TerrainPlantBlock extends EndPlantBlock {
|
||||||
private final Block ground;
|
private final Block ground;
|
||||||
|
|
||||||
public BlockTerrainPlant(Block ground) {
|
public TerrainPlantBlock(Block ground) {
|
||||||
super(true);
|
super(true);
|
||||||
this.ground = ground;
|
this.ground = ground;
|
||||||
}
|
}
|
|
@ -9,13 +9,13 @@ import net.minecraft.server.world.ServerWorld;
|
||||||
import net.minecraft.util.math.BlockPos;
|
import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.world.BlockView;
|
import net.minecraft.world.BlockView;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import ru.betterend.blocks.basis.BlockDoublePlant;
|
import ru.betterend.blocks.basis.DoublePlantBlock;
|
||||||
import ru.betterend.blocks.basis.BlockPlant;
|
import ru.betterend.blocks.basis.EndPlantBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.util.BlocksHelper;
|
import ru.betterend.util.BlocksHelper;
|
||||||
|
|
||||||
public class BlockTwistedUmbrellaMoss extends BlockPlant {
|
public class TwistedUmbrellaMossBlock extends EndPlantBlock {
|
||||||
public BlockTwistedUmbrellaMoss() {
|
public TwistedUmbrellaMossBlock() {
|
||||||
super(11);
|
super(11);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -42,8 +42,8 @@ public class BlockTwistedUmbrellaMoss extends BlockPlant {
|
||||||
@Override
|
@Override
|
||||||
public void grow(ServerWorld world, Random random, BlockPos pos, BlockState state) {
|
public void grow(ServerWorld world, Random random, BlockPos pos, BlockState state) {
|
||||||
int rot = world.random.nextInt(4);
|
int rot = world.random.nextInt(4);
|
||||||
BlockState bs = EndBlocks.TWISTED_UMBRELLA_MOSS_TALL.getDefaultState().with(BlockDoublePlant.ROTATION, rot);
|
BlockState bs = EndBlocks.TWISTED_UMBRELLA_MOSS_TALL.getDefaultState().with(DoublePlantBlock.ROTATION, rot);
|
||||||
BlocksHelper.setWithoutUpdate(world, pos, bs);
|
BlocksHelper.setWithoutUpdate(world, pos, bs);
|
||||||
BlocksHelper.setWithoutUpdate(world, pos.up(), bs.with(BlockDoublePlant.TOP, true));
|
BlocksHelper.setWithoutUpdate(world, pos.up(), bs.with(DoublePlantBlock.TOP, true));
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -7,11 +7,11 @@ import net.minecraft.entity.ItemEntity;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.server.world.ServerWorld;
|
import net.minecraft.server.world.ServerWorld;
|
||||||
import net.minecraft.util.math.BlockPos;
|
import net.minecraft.util.math.BlockPos;
|
||||||
import ru.betterend.blocks.basis.BlockDoublePlant;
|
import ru.betterend.blocks.basis.DoublePlantBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
|
|
||||||
public class BlockTwistedUmbrellaMossTall extends BlockDoublePlant {
|
public class TwistedUmbrellaMossTallBlock extends DoublePlantBlock {
|
||||||
public BlockTwistedUmbrellaMossTall() {
|
public TwistedUmbrellaMossTallBlock() {
|
||||||
super(12);
|
super(12);
|
||||||
}
|
}
|
||||||
|
|
|
@ -9,13 +9,13 @@ import net.minecraft.server.world.ServerWorld;
|
||||||
import net.minecraft.util.math.BlockPos;
|
import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.world.BlockView;
|
import net.minecraft.world.BlockView;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import ru.betterend.blocks.basis.BlockDoublePlant;
|
import ru.betterend.blocks.basis.DoublePlantBlock;
|
||||||
import ru.betterend.blocks.basis.BlockPlant;
|
import ru.betterend.blocks.basis.EndPlantBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.util.BlocksHelper;
|
import ru.betterend.util.BlocksHelper;
|
||||||
|
|
||||||
public class BlockUmbrellaMoss extends BlockPlant {
|
public class UmbrellaMossBlock extends EndPlantBlock {
|
||||||
public BlockUmbrellaMoss() {
|
public UmbrellaMossBlock() {
|
||||||
super(11);
|
super(11);
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -42,8 +42,8 @@ public class BlockUmbrellaMoss extends BlockPlant {
|
||||||
@Override
|
@Override
|
||||||
public void grow(ServerWorld world, Random random, BlockPos pos, BlockState state) {
|
public void grow(ServerWorld world, Random random, BlockPos pos, BlockState state) {
|
||||||
int rot = world.random.nextInt(4);
|
int rot = world.random.nextInt(4);
|
||||||
BlockState bs = EndBlocks.UMBRELLA_MOSS_TALL.getDefaultState().with(BlockDoublePlant.ROTATION, rot);
|
BlockState bs = EndBlocks.UMBRELLA_MOSS_TALL.getDefaultState().with(DoublePlantBlock.ROTATION, rot);
|
||||||
BlocksHelper.setWithoutUpdate(world, pos, bs);
|
BlocksHelper.setWithoutUpdate(world, pos, bs);
|
||||||
BlocksHelper.setWithoutUpdate(world, pos.up(), bs.with(BlockDoublePlant.TOP, true));
|
BlocksHelper.setWithoutUpdate(world, pos.up(), bs.with(DoublePlantBlock.TOP, true));
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -7,11 +7,11 @@ import net.minecraft.entity.ItemEntity;
|
||||||
import net.minecraft.item.ItemStack;
|
import net.minecraft.item.ItemStack;
|
||||||
import net.minecraft.server.world.ServerWorld;
|
import net.minecraft.server.world.ServerWorld;
|
||||||
import net.minecraft.util.math.BlockPos;
|
import net.minecraft.util.math.BlockPos;
|
||||||
import ru.betterend.blocks.basis.BlockDoublePlant;
|
import ru.betterend.blocks.basis.DoublePlantBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
|
|
||||||
public class BlockUmbrellaMossTall extends BlockDoublePlant {
|
public class UmbrellaMossTallBlock extends DoublePlantBlock {
|
||||||
public BlockUmbrellaMossTall() {
|
public UmbrellaMossTallBlock() {
|
||||||
super(12);
|
super(12);
|
||||||
}
|
}
|
||||||
|
|
|
@ -17,15 +17,15 @@ import net.minecraft.util.Hand;
|
||||||
import net.minecraft.util.hit.BlockHitResult;
|
import net.minecraft.util.hit.BlockHitResult;
|
||||||
import net.minecraft.util.math.BlockPos;
|
import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
import ru.betterend.blocks.basis.BlockBase;
|
import ru.betterend.blocks.basis.BaseBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.registry.EndItems;
|
import ru.betterend.registry.EndItems;
|
||||||
import ru.betterend.util.BlocksHelper;
|
import ru.betterend.util.BlocksHelper;
|
||||||
|
|
||||||
public class BlockUmbrellaTreeCluster extends BlockBase {
|
public class UmbrellaTreeClusterBlock extends BaseBlock {
|
||||||
public static final BooleanProperty NATURAL = BlockProperties.NATURAL;
|
public static final BooleanProperty NATURAL = BlockProperties.NATURAL;
|
||||||
|
|
||||||
public BlockUmbrellaTreeCluster() {
|
public UmbrellaTreeClusterBlock() {
|
||||||
super(FabricBlockSettings.copyOf(Blocks.NETHER_WART_BLOCK)
|
super(FabricBlockSettings.copyOf(Blocks.NETHER_WART_BLOCK)
|
||||||
.materialColor(MaterialColor.PURPLE)
|
.materialColor(MaterialColor.PURPLE)
|
||||||
.luminance(15));
|
.luminance(15));
|
|
@ -11,14 +11,14 @@ import net.minecraft.server.world.ServerWorld;
|
||||||
import net.minecraft.state.StateManager;
|
import net.minecraft.state.StateManager;
|
||||||
import net.minecraft.state.property.BooleanProperty;
|
import net.minecraft.state.property.BooleanProperty;
|
||||||
import net.minecraft.util.math.BlockPos;
|
import net.minecraft.util.math.BlockPos;
|
||||||
import ru.betterend.blocks.basis.BlockBase;
|
import ru.betterend.blocks.basis.BaseBlock;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.util.BlocksHelper;
|
import ru.betterend.util.BlocksHelper;
|
||||||
|
|
||||||
public class BlockUmbrellaTreeClusterEmpty extends BlockBase {
|
public class UmbrellaTreeClusterEmptyBlock extends BaseBlock {
|
||||||
public static final BooleanProperty NATURAL = BlockProperties.NATURAL;
|
public static final BooleanProperty NATURAL = BlockProperties.NATURAL;
|
||||||
|
|
||||||
public BlockUmbrellaTreeClusterEmpty() {
|
public UmbrellaTreeClusterEmptyBlock() {
|
||||||
super(FabricBlockSettings.copyOf(Blocks.NETHER_WART_BLOCK)
|
super(FabricBlockSettings.copyOf(Blocks.NETHER_WART_BLOCK)
|
||||||
.materialColor(MaterialColor.PURPLE)
|
.materialColor(MaterialColor.PURPLE)
|
||||||
.ticksRandomly());
|
.ticksRandomly());
|
||||||
|
@ -33,7 +33,7 @@ public class BlockUmbrellaTreeClusterEmpty extends BlockBase {
|
||||||
@Override
|
@Override
|
||||||
public void scheduledTick(BlockState state, ServerWorld world, BlockPos pos, Random random) {
|
public void scheduledTick(BlockState state, ServerWorld world, BlockPos pos, Random random) {
|
||||||
if (state.get(NATURAL) && random.nextInt(16) == 0) {
|
if (state.get(NATURAL) && random.nextInt(16) == 0) {
|
||||||
BlocksHelper.setWithUpdate(world, pos, EndBlocks.UMBRELLA_TREE_CLUSTER.getDefaultState().with(BlockUmbrellaTreeCluster.NATURAL, true));
|
BlocksHelper.setWithUpdate(world, pos, EndBlocks.UMBRELLA_TREE_CLUSTER.getDefaultState().with(UmbrellaTreeClusterBlock.NATURAL, true));
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
|
@ -31,11 +31,11 @@ import ru.betterend.patterns.Patterns;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.util.MHelper;
|
import ru.betterend.util.MHelper;
|
||||||
|
|
||||||
public class BlockUmbrellaTreeMembrane extends SlimeBlock implements IRenderTypeable, BlockPatterned {
|
public class UmbrellaTreeMembraneBlock extends SlimeBlock implements IRenderTypeable, BlockPatterned {
|
||||||
public static final IntProperty COLOR = IntProperty.of("color", 0, 7);
|
public static final IntProperty COLOR = IntProperty.of("color", 0, 7);
|
||||||
private static final OpenSimplexNoise NOISE = new OpenSimplexNoise(0);
|
private static final OpenSimplexNoise NOISE = new OpenSimplexNoise(0);
|
||||||
|
|
||||||
public BlockUmbrellaTreeMembrane() {
|
public UmbrellaTreeMembraneBlock() {
|
||||||
super(FabricBlockSettings.copyOf(Blocks.SLIME_BLOCK));
|
super(FabricBlockSettings.copyOf(Blocks.SLIME_BLOCK));
|
||||||
}
|
}
|
||||||
|
|
|
@ -4,13 +4,13 @@ import net.minecraft.block.BlockState;
|
||||||
import net.minecraft.util.math.BlockPos;
|
import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.world.WorldView;
|
import net.minecraft.world.WorldView;
|
||||||
import net.minecraft.world.gen.feature.Feature;
|
import net.minecraft.world.gen.feature.Feature;
|
||||||
import ru.betterend.blocks.basis.BlockFeatureSapling;
|
import ru.betterend.blocks.basis.FeatureSaplingBlock;
|
||||||
import ru.betterend.client.render.ERenderLayer;
|
import ru.betterend.client.render.ERenderLayer;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.registry.EndFeatures;
|
import ru.betterend.registry.EndFeatures;
|
||||||
|
|
||||||
public class BlockUmbrellaTreeSapling extends BlockFeatureSapling {
|
public class UmbrellaTreeSaplingBlock extends FeatureSaplingBlock {
|
||||||
public BlockUmbrellaTreeSapling() {
|
public UmbrellaTreeSaplingBlock() {
|
||||||
super();
|
super();
|
||||||
}
|
}
|
||||||
|
|
|
@ -32,8 +32,8 @@ import net.minecraft.world.WorldView;
|
||||||
import ru.betterend.registry.EndBlocks;
|
import ru.betterend.registry.EndBlocks;
|
||||||
import ru.betterend.util.BlocksHelper;
|
import ru.betterend.util.BlocksHelper;
|
||||||
|
|
||||||
public class BlockVentBubbleColumn extends Block implements FluidDrainable, FluidFillable {
|
public class VentBubbleColumnBlock extends Block implements FluidDrainable, FluidFillable {
|
||||||
public BlockVentBubbleColumn() {
|
public VentBubbleColumnBlock() {
|
||||||
super(FabricBlockSettings.of(Material.BUBBLE_COLUMN).nonOpaque().noCollision().dropsNothing());
|
super(FabricBlockSettings.of(Material.BUBBLE_COLUMN).nonOpaque().noCollision().dropsNothing());
|
||||||
}
|
}
|
||||||
|
|
|
@ -16,10 +16,10 @@ import net.minecraft.world.WorldAccess;
|
||||||
import net.minecraft.world.WorldView;
|
import net.minecraft.world.WorldView;
|
||||||
import ru.betterend.util.BlocksHelper;
|
import ru.betterend.util.BlocksHelper;
|
||||||
|
|
||||||
public abstract class BlockAttached extends BlockBaseNotFull {
|
public abstract class AttachedBlock extends BaseBlockNotFull {
|
||||||
public static final DirectionProperty FACING = Properties.FACING;
|
public static final DirectionProperty FACING = Properties.FACING;
|
||||||
|
|
||||||
public BlockAttached(Settings settings) {
|
public AttachedBlock(Settings settings) {
|
||||||
super(settings);
|
super(settings);
|
||||||
this.setDefaultState(this.getDefaultState().with(FACING, Direction.UP));
|
this.setDefaultState(this.getDefaultState().with(FACING, Direction.UP));
|
||||||
}
|
}
|
|
@ -6,8 +6,8 @@ import net.minecraft.util.Identifier;
|
||||||
import net.minecraft.util.registry.Registry;
|
import net.minecraft.util.registry.Registry;
|
||||||
import ru.betterend.patterns.Patterns;
|
import ru.betterend.patterns.Patterns;
|
||||||
|
|
||||||
public class BlockBark extends BlockPillar {
|
public class BarkBlock extends EndPillarBlock {
|
||||||
public BlockBark(Settings settings) {
|
public BarkBlock(Settings settings) {
|
||||||
super(settings);
|
super(settings);
|
||||||
}
|
}
|
||||||
|
|
|
@ -13,8 +13,8 @@ import net.minecraft.util.registry.Registry;
|
||||||
import ru.betterend.patterns.BlockPatterned;
|
import ru.betterend.patterns.BlockPatterned;
|
||||||
import ru.betterend.patterns.Patterns;
|
import ru.betterend.patterns.Patterns;
|
||||||
|
|
||||||
public class BlockBase extends Block implements BlockPatterned {
|
public class BaseBlock extends Block implements BlockPatterned {
|
||||||
public BlockBase(Settings settings) {
|
public BaseBlock(Settings settings) {
|
||||||
super(settings);
|
super(settings);
|
||||||
}
|
}
|
||||||
|
|
|
@ -5,9 +5,9 @@ import net.minecraft.entity.EntityType;
|
||||||
import net.minecraft.util.math.BlockPos;
|
import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.world.BlockView;
|
import net.minecraft.world.BlockView;
|
||||||
|
|
||||||
public class BlockBaseNotFull extends BlockBase {
|
public class BaseBlockNotFull extends BaseBlock {
|
||||||
|
|
||||||
public BlockBaseNotFull(Settings settings) {
|
public BaseBlockNotFull(Settings settings) {
|
||||||
super(settings);
|
super(settings);
|
||||||
}
|
}
|
||||||
|
|
|
@ -11,7 +11,6 @@ import net.minecraft.loot.context.LootContext;
|
||||||
import net.minecraft.world.BlockView;
|
import net.minecraft.world.BlockView;
|
||||||
|
|
||||||
public class BaseBlockWithEntity extends BlockWithEntity {
|
public class BaseBlockWithEntity extends BlockWithEntity {
|
||||||
|
|
||||||
public BaseBlockWithEntity(Settings settings) {
|
public BaseBlockWithEntity(Settings settings) {
|
||||||
super(settings);
|
super(settings);
|
||||||
}
|
}
|
||||||
|
|
|
@ -40,12 +40,12 @@ import ru.betterend.interfaces.IRenderTypeable;
|
||||||
import ru.betterend.registry.EndTags;
|
import ru.betterend.registry.EndTags;
|
||||||
import ru.betterend.util.BlocksHelper;
|
import ru.betterend.util.BlocksHelper;
|
||||||
|
|
||||||
public class BlockDoublePlant extends BlockBaseNotFull implements IRenderTypeable, Fertilizable {
|
public class DoublePlantBlock extends BaseBlockNotFull implements IRenderTypeable, Fertilizable {
|
||||||
private static final VoxelShape SHAPE = Block.createCuboidShape(4, 2, 4, 12, 16, 12);
|
private static final VoxelShape SHAPE = Block.createCuboidShape(4, 2, 4, 12, 16, 12);
|
||||||
public static final IntProperty ROTATION = BlockProperties.ROTATION;
|
public static final IntProperty ROTATION = BlockProperties.ROTATION;
|
||||||
public static final BooleanProperty TOP = BooleanProperty.of("top");
|
public static final BooleanProperty TOP = BooleanProperty.of("top");
|
||||||
|
|
||||||
public BlockDoublePlant() {
|
public DoublePlantBlock() {
|
||||||
super(FabricBlockSettings.of(Material.PLANT)
|
super(FabricBlockSettings.of(Material.PLANT)
|
||||||
.breakByTool(FabricToolTags.SHEARS)
|
.breakByTool(FabricToolTags.SHEARS)
|
||||||
.sounds(BlockSoundGroup.WET_GRASS)
|
.sounds(BlockSoundGroup.WET_GRASS)
|
||||||
|
@ -54,7 +54,7 @@ public class BlockDoublePlant extends BlockBaseNotFull implements IRenderTypeabl
|
||||||
this.setDefaultState(this.stateManager.getDefaultState().with(TOP, false));
|
this.setDefaultState(this.stateManager.getDefaultState().with(TOP, false));
|
||||||
}
|
}
|
||||||
|
|
||||||
public BlockDoublePlant(int light) {
|
public DoublePlantBlock(int light) {
|
||||||
super(FabricBlockSettings.of(Material.PLANT)
|
super(FabricBlockSettings.of(Material.PLANT)
|
||||||
.breakByTool(FabricToolTags.SHEARS)
|
.breakByTool(FabricToolTags.SHEARS)
|
||||||
.sounds(BlockSoundGroup.WET_GRASS)
|
.sounds(BlockSoundGroup.WET_GRASS)
|
|
@ -30,8 +30,8 @@ import ru.betterend.patterns.BlockPatterned;
|
||||||
import ru.betterend.patterns.Patterns;
|
import ru.betterend.patterns.Patterns;
|
||||||
import ru.betterend.registry.EndBlockEntities;
|
import ru.betterend.registry.EndBlockEntities;
|
||||||
|
|
||||||
public class BlockBarrel extends BarrelBlock implements BlockPatterned {
|
public class EndBarrelBlock extends BarrelBlock implements BlockPatterned {
|
||||||
public BlockBarrel(Block source) {
|
public EndBarrelBlock(Block source) {
|
||||||
super(FabricBlockSettings.copyOf(source).nonOpaque());
|
super(FabricBlockSettings.copyOf(source).nonOpaque());
|
||||||
}
|
}
|
||||||
|
|
|
@ -16,10 +16,10 @@ import net.minecraft.util.hit.BlockHitResult;
|
||||||
import net.minecraft.util.math.BlockPos;
|
import net.minecraft.util.math.BlockPos;
|
||||||
import net.minecraft.world.World;
|
import net.minecraft.world.World;
|
||||||
|
|
||||||
public class BlockBarkStripable extends BlockBark {
|
public class EndBlockStripableLogLog extends EndPillarBlock {
|
||||||
private final Block striped;
|
private final Block striped;
|
||||||
|
|
||||||
public BlockBarkStripable(MaterialColor color, Block striped) {
|
public EndBlockStripableLogLog(MaterialColor color, Block striped) {
|
||||||
super(FabricBlockSettings.copyOf(striped).materialColor(color));
|
super(FabricBlockSettings.copyOf(striped).materialColor(color));
|
||||||
this.striped = striped;
|
this.striped = striped;
|
||||||
}
|
}
|
|
@ -17,8 +17,8 @@ import net.minecraft.util.Identifier;
|
||||||
import net.minecraft.util.registry.Registry;
|
import net.minecraft.util.registry.Registry;
|
||||||
import ru.betterend.patterns.Patterns;
|
import ru.betterend.patterns.Patterns;
|
||||||
|
|
||||||
public class BlockBookshelf extends BlockBase {
|
public class EndBookshelfBlock extends BaseBlock {
|
||||||
public BlockBookshelf(Block source) {
|
public EndBookshelfBlock(Block source) {
|
||||||
super(FabricBlockSettings.copyOf(source));
|
super(FabricBlockSettings.copyOf(source));
|
||||||
}
|
}
|
||||||
|
|
|
@ -17,11 +17,10 @@ import ru.betterend.patterns.BlockPatterned;
|
||||||
import ru.betterend.patterns.Patterns;
|
import ru.betterend.patterns.Patterns;
|
||||||
import ru.betterend.registry.EndBlockEntities;
|
import ru.betterend.registry.EndBlockEntities;
|
||||||
|
|
||||||
public class BlockChest extends ChestBlock implements BlockPatterned {
|
public class EndChestBlock extends ChestBlock implements BlockPatterned {
|
||||||
|
|
||||||
private final Block parent;
|
private final Block parent;
|
||||||
|
|
||||||
public BlockChest(Block source) {
|
public EndChestBlock(Block source) {
|
||||||
super(FabricBlockSettings.copyOf(source).nonOpaque(), () -> {
|
super(FabricBlockSettings.copyOf(source).nonOpaque(), () -> {
|
||||||
return EndBlockEntities.CHEST;
|
return EndBlockEntities.CHEST;
|
||||||
});
|
});
|
|
@ -15,8 +15,8 @@ import net.minecraft.util.registry.Registry;
|
||||||
import ru.betterend.patterns.BlockPatterned;
|
import ru.betterend.patterns.BlockPatterned;
|
||||||
import ru.betterend.patterns.Patterns;
|
import ru.betterend.patterns.Patterns;
|
||||||
|
|
||||||
public class BlockComposter extends ComposterBlock implements BlockPatterned {
|
public class EndComposterBlock extends ComposterBlock implements BlockPatterned {
|
||||||
public BlockComposter(Block source) {
|
public EndComposterBlock(Block source) {
|
||||||
super(FabricBlockSettings.copyOf(source));
|
super(FabricBlockSettings.copyOf(source));
|
||||||
}
|
}
|
||||||
|
|
|
@ -16,8 +16,8 @@ import net.minecraft.util.registry.Registry;
|
||||||
import ru.betterend.patterns.BlockPatterned;
|
import ru.betterend.patterns.BlockPatterned;
|
||||||
import ru.betterend.patterns.Patterns;
|
import ru.betterend.patterns.Patterns;
|
||||||
|
|
||||||
public class BlockCraftingTable extends CraftingTableBlock implements BlockPatterned {
|
public class EndCraftingTableBlock extends CraftingTableBlock implements BlockPatterned {
|
||||||
public BlockCraftingTable(Block source) {
|
public EndCraftingTableBlock(Block source) {
|
||||||
super(FabricBlockSettings.copyOf(source));
|
super(FabricBlockSettings.copyOf(source));
|
||||||
}
|
}
|
||||||
|
|
|
@ -18,8 +18,8 @@ import ru.betterend.interfaces.IRenderTypeable;
|
||||||
import ru.betterend.patterns.BlockPatterned;
|
import ru.betterend.patterns.BlockPatterned;
|
||||||
import ru.betterend.patterns.Patterns;
|
import ru.betterend.patterns.Patterns;
|
||||||
|
|
||||||
public class BlockDoor extends DoorBlock implements IRenderTypeable, BlockPatterned {
|
public class EndDoorBlock extends DoorBlock implements IRenderTypeable, BlockPatterned {
|
||||||
public BlockDoor(Block block) {
|
public EndDoorBlock(Block block) {
|
||||||
super(FabricBlockSettings.copy(block).nonOpaque());
|
super(FabricBlockSettings.copy(block).nonOpaque());
|
||||||
}
|
}
|
||||||
|
|
|
@ -15,11 +15,10 @@ import net.minecraft.util.registry.Registry;
|
||||||
import ru.betterend.patterns.BlockPatterned;
|
import ru.betterend.patterns.BlockPatterned;
|
||||||
import ru.betterend.patterns.Patterns;
|
import ru.betterend.patterns.Patterns;
|
||||||
|
|
||||||
public class BlockFence extends FenceBlock implements BlockPatterned {
|
public class EndFenceBlock extends FenceBlock implements BlockPatterned {
|
||||||
|
|
||||||
private final Block parent;
|
private final Block parent;
|
||||||
|
|
||||||
public BlockFence(Block source) {
|
public EndFenceBlock(Block source) {
|
||||||
super(FabricBlockSettings.copyOf(source).nonOpaque());
|
super(FabricBlockSettings.copyOf(source).nonOpaque());
|
||||||
this.parent = source;
|
this.parent = source;
|
||||||
}
|
}
|
|
@ -15,11 +15,10 @@ import net.minecraft.util.registry.Registry;
|
||||||
import ru.betterend.patterns.BlockPatterned;
|
import ru.betterend.patterns.BlockPatterned;
|
||||||
import ru.betterend.patterns.Patterns;
|
import ru.betterend.patterns.Patterns;
|
||||||
|
|
||||||
public class BlockGate extends FenceGateBlock implements BlockPatterned {
|
public class EndGateBlock extends FenceGateBlock implements BlockPatterned {
|
||||||
|
|
||||||
private final Block parent;
|
private final Block parent;
|
||||||
|
|
||||||
public BlockGate(Block source) {
|
public EndGateBlock(Block source) {
|
||||||
super(FabricBlockSettings.copyOf(source).nonOpaque());
|
super(FabricBlockSettings.copyOf(source).nonOpaque());
|
||||||
this.parent = source;
|
this.parent = source;
|
||||||
}
|
}
|
|
@ -31,7 +31,7 @@ import ru.betterend.patterns.BlockPatterned;
|
||||||
import ru.betterend.patterns.Patterns;
|
import ru.betterend.patterns.Patterns;
|
||||||
import ru.betterend.util.BlocksHelper;
|
import ru.betterend.util.BlocksHelper;
|
||||||
|
|
||||||
public class BlockLadder extends BlockBaseNotFull implements IRenderTypeable, BlockPatterned {
|
public class EndLadderBlock extends BaseBlockNotFull implements IRenderTypeable, BlockPatterned {
|
||||||
public static final DirectionProperty FACING = HorizontalFacingBlock.FACING;
|
public static final DirectionProperty FACING = HorizontalFacingBlock.FACING;
|
||||||
public static final BooleanProperty WATERLOGGED = Properties.WATERLOGGED;
|
public static final BooleanProperty WATERLOGGED = Properties.WATERLOGGED;
|
||||||
protected static final VoxelShape EAST_SHAPE = Block.createCuboidShape(0.0D, 0.0D, 0.0D, 3.0D, 16.0D, 16.0D);
|
protected static final VoxelShape EAST_SHAPE = Block.createCuboidShape(0.0D, 0.0D, 0.0D, 3.0D, 16.0D, 16.0D);
|
||||||
|
@ -39,7 +39,7 @@ public class BlockLadder extends BlockBaseNotFull implements IRenderTypeable, Bl
|
||||||
protected static final VoxelShape SOUTH_SHAPE = Block.createCuboidShape(0.0D, 0.0D, 0.0D, 16.0D, 16.0D, 3.0D);
|
protected static final VoxelShape SOUTH_SHAPE = Block.createCuboidShape(0.0D, 0.0D, 0.0D, 16.0D, 16.0D, 3.0D);
|
||||||
protected static final VoxelShape NORTH_SHAPE = Block.createCuboidShape(0.0D, 0.0D, 13.0D, 16.0D, 16.0D, 16.0D);
|
protected static final VoxelShape NORTH_SHAPE = Block.createCuboidShape(0.0D, 0.0D, 13.0D, 16.0D, 16.0D, 16.0D);
|
||||||
|
|
||||||
public BlockLadder(Block block) {
|
public EndLadderBlock(Block block) {
|
||||||
super(FabricBlockSettings.copyOf(block).nonOpaque());
|
super(FabricBlockSettings.copyOf(block).nonOpaque());
|
||||||
}
|
}
|
||||||
|
|
|
@ -19,15 +19,15 @@ import net.minecraft.world.BlockView;
|
||||||
import net.minecraft.world.WorldAccess;
|
import net.minecraft.world.WorldAccess;
|
||||||
import net.minecraft.world.WorldView;
|
import net.minecraft.world.WorldView;
|
||||||
|
|
||||||
public class BlockLantern extends BlockBaseNotFull implements Waterloggable, FluidFillable {
|
public class EndLanternBlock extends BaseBlockNotFull implements Waterloggable, FluidFillable {
|
||||||
public static final BooleanProperty IS_FLOOR = BooleanProperty.of("is_floor");
|
public static final BooleanProperty IS_FLOOR = BooleanProperty.of("is_floor");
|
||||||
public static final BooleanProperty WATERLOGGED = Properties.WATERLOGGED;
|
public static final BooleanProperty WATERLOGGED = Properties.WATERLOGGED;
|
||||||
|
|
||||||
public BlockLantern(Block source) {
|
public EndLanternBlock(Block source) {
|
||||||
this(FabricBlockSettings.copyOf(source).luminance(15).nonOpaque());
|
this(FabricBlockSettings.copyOf(source).luminance(15).nonOpaque());
|
||||||
}
|
}
|
||||||
|
|
||||||
public BlockLantern(FabricBlockSettings settings) {
|
public EndLanternBlock(FabricBlockSettings settings) {
|
||||||
super(settings.nonOpaque());
|
super(settings.nonOpaque());
|
||||||
}
|
}
|
||||||
|
|
|
@ -26,10 +26,10 @@ import ru.betterend.patterns.BlockPatterned;
|
||||||
import ru.betterend.patterns.Patterns;
|
import ru.betterend.patterns.Patterns;
|
||||||
import ru.betterend.util.MHelper;
|
import ru.betterend.util.MHelper;
|
||||||
|
|
||||||
public class BlockLeaves extends LeavesBlock implements BlockPatterned, IRenderTypeable {
|
public class EndLeavesBlock extends LeavesBlock implements BlockPatterned, IRenderTypeable {
|
||||||
private final Block sapling;
|
private final Block sapling;
|
||||||
|
|
||||||
public BlockLeaves(Block sapling, MaterialColor color) {
|
public EndLeavesBlock(Block sapling, MaterialColor color) {
|
||||||
super(FabricBlockSettings.copyOf(Blocks.OAK_LEAVES)
|
super(FabricBlockSettings.copyOf(Blocks.OAK_LEAVES)
|
||||||
.allowsSpawning((state, world, pos, type) -> { return false; })
|
.allowsSpawning((state, world, pos, type) -> { return false; })
|
||||||
.suffocates((state, world, pos) -> { return false; })
|
.suffocates((state, world, pos) -> { return false; })
|
||||||
|
@ -39,7 +39,7 @@ public class BlockLeaves extends LeavesBlock implements BlockPatterned, IRenderT
|
||||||
this.sapling = sapling;
|
this.sapling = sapling;
|
||||||
}
|
}
|
||||||
|
|
||||||
public BlockLeaves(Block sapling, MaterialColor color, int light) {
|
public EndLeavesBlock(Block sapling, MaterialColor color, int light) {
|
||||||
super(FabricBlockSettings.copyOf(Blocks.OAK_LEAVES)
|
super(FabricBlockSettings.copyOf(Blocks.OAK_LEAVES)
|
||||||
.allowsSpawning((state, world, pos, type) -> { return false; })
|
.allowsSpawning((state, world, pos, type) -> { return false; })
|
||||||
.suffocates((state, world, pos) -> { return false; })
|
.suffocates((state, world, pos) -> { return false; })
|
|
@ -24,13 +24,13 @@ import ru.betterend.patterns.BlockPatterned;
|
||||||
import ru.betterend.patterns.Patterns;
|
import ru.betterend.patterns.Patterns;
|
||||||
import ru.betterend.util.MHelper;
|
import ru.betterend.util.MHelper;
|
||||||
|
|
||||||
public class BlockOre extends OreBlock implements BlockPatterned {
|
public class EndOreBlock extends OreBlock implements BlockPatterned {
|
||||||
private final Item dropItem;
|
private final Item dropItem;
|
||||||
private final int minCount;
|
private final int minCount;
|
||||||
private final int maxCount;
|
private final int maxCount;
|
||||||
private final int expirience;
|
private final int expirience;
|
||||||
|
|
||||||
public BlockOre(Item drop, int minCount, int maxCount, int expirience) {
|
public EndOreBlock(Item drop, int minCount, int maxCount, int expirience) {
|
||||||
super(FabricBlockSettings.of(Material.STONE, MaterialColor.SAND)
|
super(FabricBlockSettings.of(Material.STONE, MaterialColor.SAND)
|
||||||
.hardness(3F)
|
.hardness(3F)
|
||||||
.resistance(9F)
|
.resistance(9F)
|
|
@ -13,8 +13,8 @@ import net.minecraft.util.registry.Registry;
|
||||||
import ru.betterend.patterns.BlockPatterned;
|
import ru.betterend.patterns.BlockPatterned;
|
||||||
import ru.betterend.patterns.Patterns;
|
import ru.betterend.patterns.Patterns;
|
||||||
|
|
||||||
public class BlockPillar extends PillarBlock implements BlockPatterned {
|
public class EndPillarBlock extends PillarBlock implements BlockPatterned {
|
||||||
public BlockPillar(Settings settings) {
|
public EndPillarBlock(Settings settings) {
|
||||||
super(settings);
|
super(settings);
|
||||||
}
|
}
|
||||||
|
|
|
@ -34,18 +34,18 @@ import ru.betterend.client.render.ERenderLayer;
|
||||||
import ru.betterend.interfaces.IRenderTypeable;
|
import ru.betterend.interfaces.IRenderTypeable;
|
||||||
import ru.betterend.registry.EndTags;
|
import ru.betterend.registry.EndTags;
|
||||||
|
|
||||||
public class BlockPlant extends BlockBaseNotFull implements IRenderTypeable, Fertilizable {
|
public class EndPlantBlock extends BaseBlockNotFull implements IRenderTypeable, Fertilizable {
|
||||||
private static final VoxelShape SHAPE = Block.createCuboidShape(4, 0, 4, 12, 14, 12);
|
private static final VoxelShape SHAPE = Block.createCuboidShape(4, 0, 4, 12, 14, 12);
|
||||||
|
|
||||||
public BlockPlant() {
|
public EndPlantBlock() {
|
||||||
this(false);
|
this(false);
|
||||||
}
|
}
|
||||||
|
|
||||||
public BlockPlant(int light) {
|
public EndPlantBlock(int light) {
|
||||||
this(false, light);
|
this(false, light);
|
||||||
}
|
}
|
||||||
|
|
||||||
public BlockPlant(boolean replaceable) {
|
public EndPlantBlock(boolean replaceable) {
|
||||||
super(FabricBlockSettings.of(replaceable ? Material.REPLACEABLE_PLANT : Material.PLANT)
|
super(FabricBlockSettings.of(replaceable ? Material.REPLACEABLE_PLANT : Material.PLANT)
|
||||||
.breakByTool(FabricToolTags.SHEARS)
|
.breakByTool(FabricToolTags.SHEARS)
|
||||||
.sounds(BlockSoundGroup.GRASS)
|
.sounds(BlockSoundGroup.GRASS)
|
||||||
|
@ -53,7 +53,7 @@ public class BlockPlant extends BlockBaseNotFull implements IRenderTypeable, Fer
|
||||||
.noCollision());
|
.noCollision());
|
||||||
}
|
}
|
||||||
|
|
||||||
public BlockPlant(boolean replaceable, int light) {
|
public EndPlantBlock(boolean replaceable, int light) {
|
||||||
super(FabricBlockSettings.of(replaceable ? Material.REPLACEABLE_PLANT : Material.PLANT)
|
super(FabricBlockSettings.of(replaceable ? Material.REPLACEABLE_PLANT : Material.PLANT)
|
||||||
.breakByTool(FabricToolTags.SHEARS)
|
.breakByTool(FabricToolTags.SHEARS)
|
||||||
.sounds(BlockSoundGroup.GRASS)
|
.sounds(BlockSoundGroup.GRASS)
|
||||||
|
@ -62,7 +62,7 @@ public class BlockPlant extends BlockBaseNotFull implements IRenderTypeable, Fer
|
||||||
.noCollision());
|
.noCollision());
|
||||||
}
|
}
|
||||||
|
|
||||||
public BlockPlant(Settings settings) {
|
public EndPlantBlock(Settings settings) {
|
||||||
super(settings);
|
super(settings);
|
||||||
}
|
}
|
||||||
|
|
|
@ -15,11 +15,10 @@ import net.minecraft.util.registry.Registry;
|
||||||
import ru.betterend.patterns.BlockPatterned;
|
import ru.betterend.patterns.BlockPatterned;
|
||||||
import ru.betterend.patterns.Patterns;
|
import ru.betterend.patterns.Patterns;
|
||||||
|
|
||||||
public class BlockPressurePlate extends PressurePlateBlock implements BlockPatterned {
|
public class EndPlateBlock extends PressurePlateBlock implements BlockPatterned {
|
||||||
|
|
||||||
private final Block parent;
|
private final Block parent;
|
||||||
|
|
||||||
public BlockPressurePlate(Block source) {
|
public EndPlateBlock(Block source) {
|
||||||
super(ActivationRule.EVERYTHING, FabricBlockSettings.copyOf(source).nonOpaque());
|
super(ActivationRule.EVERYTHING, FabricBlockSettings.copyOf(source).nonOpaque());
|
||||||
this.parent = source;
|
this.parent = source;
|
||||||
}
|
}
|
|
@ -41,7 +41,7 @@ import ru.betterend.blocks.entities.ESignBlockEntity;
|
||||||
import ru.betterend.patterns.BlockPatterned;
|
import ru.betterend.patterns.BlockPatterned;
|
||||||
import ru.betterend.patterns.Patterns;
|
import ru.betterend.patterns.Patterns;
|
||||||
|
|
||||||
public class BlockSign extends AbstractSignBlock implements BlockPatterned {
|
public class EndSignBlock extends AbstractSignBlock implements BlockPatterned {
|
||||||
public static final IntProperty ROTATION = Properties.ROTATION;
|
public static final IntProperty ROTATION = Properties.ROTATION;
|
||||||
public static final BooleanProperty FLOOR = BooleanProperty.of("floor");
|
public static final BooleanProperty FLOOR = BooleanProperty.of("floor");
|
||||||
private static final VoxelShape[] WALL_SHAPES = new VoxelShape[] {
|
private static final VoxelShape[] WALL_SHAPES = new VoxelShape[] {
|
||||||
|
@ -52,7 +52,7 @@ public class BlockSign extends AbstractSignBlock implements BlockPatterned {
|
||||||
|
|
||||||
private final Block parent;
|
private final Block parent;
|
||||||
|
|
||||||
public BlockSign(Block source) {
|
public EndSignBlock(Block source) {
|
||||||
super(FabricBlockSettings.copyOf(source).noCollision().nonOpaque(), SignType.OAK);
|
super(FabricBlockSettings.copyOf(source).noCollision().nonOpaque(), SignType.OAK);
|
||||||
this.setDefaultState(this.stateManager.getDefaultState().with(ROTATION, 0).with(FLOOR, true).with(WATERLOGGED, false));
|
this.setDefaultState(this.stateManager.getDefaultState().with(ROTATION, 0).with(FLOOR, true).with(WATERLOGGED, false));
|
||||||
this.parent = source;
|
this.parent = source;
|
|
@ -15,11 +15,10 @@ import net.minecraft.util.registry.Registry;
|
||||||
import ru.betterend.patterns.BlockPatterned;
|
import ru.betterend.patterns.BlockPatterned;
|
||||||
import ru.betterend.patterns.Patterns;
|
import ru.betterend.patterns.Patterns;
|
||||||
|
|
||||||
public class BlockSlab extends SlabBlock implements BlockPatterned {
|
public class EndSlabBlock extends SlabBlock implements BlockPatterned {
|
||||||
|
|
||||||
private final Block parent;
|
private final Block parent;
|
||||||
|
|
||||||
public BlockSlab(Block source) {
|
public EndSlabBlock(Block source) {
|
||||||
super(FabricBlockSettings.copyOf(source));
|
super(FabricBlockSettings.copyOf(source));
|
||||||
this.parent = source;
|
this.parent = source;
|
||||||
}
|
}
|
Some files were not shown because too many files have changed in this diff Show more
Loading…
Add table
Add a link
Reference in a new issue