package net.minecraft.world.level.levelgen.feature;

import net.minecraft.nbt.CompoundTag;
import net.minecraft.world.level.levelgen.structure.BoundingBox;
import net.minecraft.world.level.block.Rotation;
import net.minecraft.world.level.levelgen.feature.structures.StructurePoolElement;
import java.util.Random;
import net.minecraft.world.level.levelgen.structure.PoolElementStructurePiece;
import net.minecraft.world.level.levelgen.feature.structures.JigsawPlacement;
import net.minecraft.world.level.levelgen.feature.configurations.JigsawConfiguration;
import net.minecraft.world.level.levelgen.WorldgenRandom;
import net.minecraft.world.level.levelgen.structure.StructurePiece;
import java.util.List;
import net.minecraft.core.BlockPos;
import net.minecraft.world.level.levelgen.structure.templatesystem.StructureManager;
import net.minecraft.world.level.chunk.ChunkGenerator;

public class VillagePieces {
    public static void bootstrap() {
        PlainVillagePools.bootstrap();
        SnowyVillagePools.bootstrap();
        SavannaVillagePools.bootstrap();
        DesertVillagePools.bootstrap();
        TaigaVillagePools.bootstrap();
    }
    
    public static void addPieces(final ChunkGenerator cha, final StructureManager cva, final BlockPos fu, final List<StructurePiece> list, final WorldgenRandom ciy, final JigsawConfiguration cnu) {
        bootstrap();
        JigsawPlacement.addPieces(cnu.startPool, cnu.size, VillagePiece::new, cha, cva, fu, list, ciy, true, true);
    }
    
    public static class VillagePiece extends PoolElementStructurePiece {
        public VillagePiece(final StructureManager cva, final StructurePoolElement cqd, final BlockPos fu, final int integer, final Rotation cap, final BoundingBox ctd) {
            super(StructurePieceType.VILLAGE, cva, cqd, fu, integer, cap, ctd);
        }
        
        public VillagePiece(final StructureManager cva, final CompoundTag le) {
            super(cva, le, StructurePieceType.VILLAGE);
        }
    }
}
