Spaces:
Build error
Build error
File size: 2,767 Bytes
d46f4a3 |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 |
package net.minecraft.data.worldgen;
import com.google.common.collect.ImmutableList;
import com.mojang.datafixers.util.Pair;
import net.minecraft.core.Holder;
import net.minecraft.core.HolderGetter;
import net.minecraft.core.registries.Registries;
import net.minecraft.world.level.levelgen.structure.pools.StructurePoolElement;
import net.minecraft.world.level.levelgen.structure.pools.StructureTemplatePool;
public class BastionSharedPools {
public static void bootstrap(BootstrapContext<StructureTemplatePool> p_331441_) {
HolderGetter<StructureTemplatePool> holdergetter = p_331441_.lookup(Registries.TEMPLATE_POOL);
Holder<StructureTemplatePool> holder = holdergetter.getOrThrow(Pools.EMPTY);
Pools.register(
p_331441_,
"bastion/mobs/piglin",
new StructureTemplatePool(
holder,
ImmutableList.of(
Pair.of(StructurePoolElement.single("bastion/mobs/melee_piglin"), 1),
Pair.of(StructurePoolElement.single("bastion/mobs/sword_piglin"), 4),
Pair.of(StructurePoolElement.single("bastion/mobs/crossbow_piglin"), 4),
Pair.of(StructurePoolElement.single("bastion/mobs/empty"), 1)
),
StructureTemplatePool.Projection.RIGID
)
);
Pools.register(
p_331441_,
"bastion/mobs/hoglin",
new StructureTemplatePool(
holder,
ImmutableList.of(
Pair.of(StructurePoolElement.single("bastion/mobs/hoglin"), 2), Pair.of(StructurePoolElement.single("bastion/mobs/empty"), 1)
),
StructureTemplatePool.Projection.RIGID
)
);
Pools.register(
p_331441_,
"bastion/blocks/gold",
new StructureTemplatePool(
holder,
ImmutableList.of(
Pair.of(StructurePoolElement.single("bastion/blocks/air"), 3), Pair.of(StructurePoolElement.single("bastion/blocks/gold"), 1)
),
StructureTemplatePool.Projection.RIGID
)
);
Pools.register(
p_331441_,
"bastion/mobs/piglin_melee",
new StructureTemplatePool(
holder,
ImmutableList.of(
Pair.of(StructurePoolElement.single("bastion/mobs/melee_piglin_always"), 1),
Pair.of(StructurePoolElement.single("bastion/mobs/melee_piglin"), 5),
Pair.of(StructurePoolElement.single("bastion/mobs/sword_piglin"), 1)
),
StructureTemplatePool.Projection.RIGID
)
);
}
} |