Structure scatter

This commit is contained in:
paulevsGitch 2020-10-03 00:11:18 +03:00
parent 8dfb71478a
commit 8eb15c8d73
4 changed files with 95 additions and 91 deletions

View file

@ -7,6 +7,7 @@ import java.util.function.Function;
import net.minecraft.block.BlockState;
import net.minecraft.block.Blocks;
import net.minecraft.block.Material;
import net.minecraft.client.util.math.Vector3f;
import net.minecraft.util.math.BlockPos;
import net.minecraft.util.math.Direction;
@ -154,6 +155,9 @@ public class MossyGlowshroomFeature extends DefaultFeature {
if (state.getBlock() != Blocks.END_STONE && state.isIn(BlockTagRegistry.END_GROUND)) {
return true;
}
if (state.getMaterial().equals(Material.PLANT)) {
return true;
}
return state.getMaterial().isReplaceable();
};