More fixes

This commit is contained in:
paulevsGitch 2020-10-26 16:09:14 +03:00
parent a81413caed
commit 29ea99ae11

View file

@ -10,6 +10,7 @@ import org.spongepowered.asm.mixin.injection.callback.CallbackInfoReturnable;
import net.minecraft.block.BlockState;
import net.minecraft.block.Blocks;
import net.minecraft.block.ChorusFlowerBlock;
import net.minecraft.block.ConnectingBlock;
import net.minecraft.util.math.BlockPos;
import net.minecraft.world.StructureWorldAccess;
import net.minecraft.world.gen.chunk.ChunkGenerator;
@ -27,7 +28,7 @@ public class ChorusPlantFeatureMixin {
ChorusFlowerBlock.generate(structureWorldAccess, blockPos, random, MHelper.randRange(8, 16, random));
BlockState bottom = structureWorldAccess.getBlockState(blockPos);
if (bottom.isOf(Blocks.CHORUS_PLANT)) {
BlocksHelper.setWithoutUpdate(structureWorldAccess, blockPos, bottom.with(BlocksHelper.ROOTS, true));
BlocksHelper.setWithoutUpdate(structureWorldAccess, blockPos, bottom.with(BlocksHelper.ROOTS, true).with(ConnectingBlock.DOWN, true));
}
info.setReturnValue(true);
info.cancel();