38 lines
1.2 KiB
Java
38 lines
1.2 KiB
Java
package net.minecraft.world.level.block;
|
|
|
|
import net.minecraft.world.level.ItemLike;
|
|
import net.minecraft.world.item.ItemStack;
|
|
import net.minecraft.server.level.ServerLevel;
|
|
import java.util.Random;
|
|
import net.minecraft.world.level.Level;
|
|
import net.minecraft.core.BlockPos;
|
|
import net.minecraft.world.level.BlockGetter;
|
|
import net.minecraft.world.item.BlockPlaceContext;
|
|
import net.minecraft.world.level.block.state.BlockState;
|
|
|
|
public class TallFlowerBlock extends DoublePlantBlock implements BonemealableBlock {
|
|
public TallFlowerBlock(final Properties c) {
|
|
super(c);
|
|
}
|
|
|
|
@Override
|
|
public boolean canBeReplaced(final BlockState byg, final BlockPlaceContext bcn) {
|
|
return false;
|
|
}
|
|
|
|
@Override
|
|
public boolean isValidBonemealTarget(final BlockGetter bjd, final BlockPos fk, final BlockState byg, final boolean boolean4) {
|
|
return true;
|
|
}
|
|
|
|
@Override
|
|
public boolean isBonemealSuccess(final Level bjt, final Random random, final BlockPos fk, final BlockState byg) {
|
|
return true;
|
|
}
|
|
|
|
@Override
|
|
public void performBonemeal(final ServerLevel xd, final Random random, final BlockPos fk, final BlockState byg) {
|
|
Block.popResource(xd, fk, new ItemStack(this));
|
|
}
|
|
}
|