[Change] Use Refactored Plant API (#24)

This commit is contained in:
Frank 2022-06-30 17:52:25 +02:00
parent 372d7ddd13
commit ccd4a6f57d
18 changed files with 37 additions and 110 deletions

View file

@ -7,39 +7,21 @@ import org.betterx.worlds.together.tag.v3.CommonBlockTags;
import net.minecraft.world.level.block.Block;
import net.minecraft.world.level.block.state.BlockState;
import java.util.function.Function;
public class EndPlantBlock extends BasePlantBlock implements PottablePlant {
public EndPlantBlock() {
this(false, p -> p);
protected EndPlantBlock() {
super();
}
public EndPlantBlock(int light) {
this(light, p -> p);
}
public EndPlantBlock(int light, Function<Properties, Properties> propMod) {
this(false, light, propMod);
}
public EndPlantBlock(boolean replaceable) {
protected EndPlantBlock(boolean replaceable) {
super(replaceable);
}
public EndPlantBlock(boolean replaceable, Function<Properties, Properties> propMod) {
super(replaceable, propMod);
protected EndPlantBlock(int light) {
super(light);
}
public EndPlantBlock(boolean replaceable, int light) {
this(replaceable, light, p -> p);
}
public EndPlantBlock(boolean replaceable, int light, Function<Properties, Properties> propMod) {
super(replaceable, light, propMod);
}
public EndPlantBlock(Properties settings) {
super(settings);
protected EndPlantBlock(Properties props) {
super(props);
}
@Override

View file

@ -5,15 +5,9 @@ import org.betterx.worlds.together.tag.v3.CommonBlockTags;
import net.minecraft.world.level.block.state.BlockState;
import java.util.function.Function;
public abstract class EndPlantWithAgeBlock extends BasePlantWithAgeBlock {
public EndPlantWithAgeBlock() {
}
public EndPlantWithAgeBlock(Function<Properties, Properties> propMod) {
super(propMod);
protected EndPlantWithAgeBlock() {
super();
}
public EndPlantWithAgeBlock(Properties settings) {

View file

@ -5,17 +5,11 @@ import org.betterx.worlds.together.tag.v3.CommonBlockTags;
import net.minecraft.world.level.block.state.BlockState;
import java.util.function.Function;
public class EndUnderwaterPlantBlock extends UnderwaterPlantBlock {
public EndUnderwaterPlantBlock() {
}
public EndUnderwaterPlantBlock(int light, Function<Properties, Properties> propMod) {
super(light, propMod);
}
public EndUnderwaterPlantBlock(Properties settings) {
super(settings);
}

View file

@ -10,14 +10,6 @@ public class EndUnderwaterWallPlantBlock extends BaseUnderwaterWallPlantBlock {
public EndUnderwaterWallPlantBlock() {
}
public EndUnderwaterWallPlantBlock(int light) {
super(light);
}
public EndUnderwaterWallPlantBlock(Properties settings) {
super(settings);
}
@Override
protected boolean isTerrain(BlockState state) {
return state.is(CommonBlockTags.END_STONES);

View file

@ -13,10 +13,6 @@ public class EndWallPlantBlock extends BaseWallPlantBlock {
super(light);
}
public EndWallPlantBlock(Properties settings) {
super(settings);
}
@Override
protected boolean isTerrain(BlockState state) {
return state.is(CommonBlockTags.END_STONES);