本文整理汇总了Java中net.minecraft.world.gen.structure.StructureVillagePieces.Village方法的典型用法代码示例。如果您正苦于以下问题:Java StructureVillagePieces.Village方法的具体用法?Java StructureVillagePieces.Village怎么用?Java StructureVillagePieces.Village使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类net.minecraft.world.gen.structure.StructureVillagePieces
的用法示例。
在下文中一共展示了StructureVillagePieces.Village方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。
示例1: buildComponent
import net.minecraft.world.gen.structure.StructureVillagePieces; //导入方法依赖的package包/类
public static StructureVillagePieces.Village buildComponent(StructureVillagePieces.Start startPiece,
@SuppressWarnings("rawtypes") List pieces, Random random, int x, int y, int z, int direction, int type) {
StructureBoundingBox _boundingBox = StructureBoundingBox.getComponentToAddBoundingBox(x, y, z, 0, 0, 0, 5, 8, 5, direction);
if (canVillageGoDeeper(_boundingBox)) {
if (StructureComponent.findIntersecting(pieces, _boundingBox) == null) {
return new CatapultTower(startPiece, type, random, _boundingBox, direction);
}
}
return null;
}
示例2: buildComponent
import net.minecraft.world.gen.structure.StructureVillagePieces; //导入方法依赖的package包/类
public static StructureVillagePieces.Village buildComponent(StructureVillagePieces.Start startPiece,
@SuppressWarnings("rawtypes") List pieces, Random random, int x, int y, int z, int direction, int type) {
StructureBoundingBox _boundingBox = StructureBoundingBox.getComponentToAddBoundingBox(x, y, z, 0, 0, 0, 5, 8, 5, direction);
if (canVillageGoDeeper(_boundingBox)) {
if (StructureComponent.findIntersecting(pieces, _boundingBox) == null) {
return new BallistaTower(startPiece, type, random, _boundingBox, direction);
}
}
return null;
}
示例3: buildComponent
import net.minecraft.world.gen.structure.StructureVillagePieces; //导入方法依赖的package包/类
public static StructureVillagePieces.Village buildComponent(StructureVillagePieces.Start startPiece,
@SuppressWarnings("rawtypes") List pieces, Random random, int x, int y, int z, int direction, int type) {
StructureBoundingBox _boundingBox = StructureBoundingBox.getComponentToAddBoundingBox(x, y, z, 0, 0, 0, 7, 14, 6, direction);
if (canVillageGoDeeper(_boundingBox)) {
if (StructureComponent.findIntersecting(pieces, _boundingBox) == null) {
return new VillageGuardTower(startPiece, type, _boundingBox, direction);
}
}
return null;
}
示例4: buildComponent
import net.minecraft.world.gen.structure.StructureVillagePieces; //导入方法依赖的package包/类
public static StructureVillagePieces.Village buildComponent(StructureVillagePieces.Start startPiece,
@SuppressWarnings("rawtypes") List pieces, Random random, int x, int y, int z, int direction, int type) {
StructureBoundingBox _boundingBox = StructureBoundingBox.getComponentToAddBoundingBox(x, y, z, 0, 0, 0, 23, 12, 21, direction);
if (canVillageGoDeeper(_boundingBox)) {
if (StructureComponent.findIntersecting(pieces, _boundingBox) == null) {
return new VillageKingCastle(startPiece, type, random, _boundingBox, direction);
}
}
return null;
}
示例5: buildComponent
import net.minecraft.world.gen.structure.StructureVillagePieces; //导入方法依赖的package包/类
public static StructureVillagePieces.Village buildComponent(StructureVillagePieces.Start startPiece,
@SuppressWarnings("rawtypes") List pieces, Random random, int x, int y, int z, int direction, int type) {
StructureBoundingBox _boundingBox = StructureBoundingBox.getComponentToAddBoundingBox(x, y, z, 0, 0, 0, 5, 10, 5, direction);
if (canVillageGoDeeper(_boundingBox)) {
if (StructureComponent.findIntersecting(pieces, _boundingBox) == null) {
return new TestBallistaTower(startPiece, type, random, _boundingBox, direction);
}
}
return null;
}
示例6: buildComponent
import net.minecraft.world.gen.structure.StructureVillagePieces; //导入方法依赖的package包/类
public static StructureVillagePieces.Village buildComponent(StructureVillagePieces.Start startPiece, @SuppressWarnings("rawtypes") List pieces, Random random, int x, int y, int z, int direction, int type) {
StructureBoundingBox _boundingBox = StructureBoundingBox.getComponentToAddBoundingBox(x, y, z, 0, 0, 0, 11, 6, 11, direction);
if(canVillageGoDeeper(_boundingBox)){
if(StructureComponent.findIntersecting(pieces, _boundingBox) == null){
return new ComponentBakery(startPiece, type, random, _boundingBox, direction);
}
}
return null;
}
示例7: buildComponent
import net.minecraft.world.gen.structure.StructureVillagePieces; //导入方法依赖的package包/类
public static StructureVillagePieces.Village buildComponent(Start startPiece, @SuppressWarnings("rawtypes") List pieces, Random random, int x, int y, int z, int direction, int type) {
StructureBoundingBox _boundingBox = StructureBoundingBox.getComponentToAddBoundingBox(x, y, z, 0, 0, 0, 14, 10, 8, direction);
if(canVillageGoDeeper(_boundingBox)){
if(StructureComponent.findIntersecting(pieces, _boundingBox) == null){
return new VillageTavern(startPiece, type, random, _boundingBox, direction);
}
}
return null;
}
示例8: buildComponent
import net.minecraft.world.gen.structure.StructureVillagePieces; //导入方法依赖的package包/类
public static StructureVillagePieces.Village buildComponent(StructureVillagePieces.Start startPiece,
@SuppressWarnings("rawtypes") List pieces, Random random, int x, int y, int z, int direction, int type) {
StructureBoundingBox _boundingBox = StructureBoundingBox.getComponentToAddBoundingBox(x, y, z, 0, 0, 0, 5, 10, 5, direction);
if (canVillageGoDeeper(_boundingBox)) {
if (StructureComponent.findIntersecting(pieces, _boundingBox) == null) {
return new TestCatapultTower(startPiece, type, random, _boundingBox, direction);
}
}
return null;
}
示例9: buildComponent
import net.minecraft.world.gen.structure.StructureVillagePieces; //导入方法依赖的package包/类
public static StructureVillagePieces.Village buildComponent(StructureVillagePieces.Start startPiece, @SuppressWarnings("rawtypes") List pieces, Random random, int x, int y, int z, int direction, int type) {
StructureBoundingBox _boundingBox = StructureBoundingBox.getComponentToAddBoundingBox(x, y, z, 0, 0, 0, 14, 10, 8, direction);
if(canVillageGoDeeper(_boundingBox)){
if(StructureComponent.findIntersecting(pieces, _boundingBox) == null){
return new VillageWall(startPiece, type, random, _boundingBox, direction);
}
}
return null;
}
示例10: buildComponent
import net.minecraft.world.gen.structure.StructureVillagePieces; //导入方法依赖的package包/类
public static StructureVillagePieces.Village buildComponent(StructureVillagePieces.Start startPiece,
@SuppressWarnings("rawtypes") List pieces, Random random, int x, int y, int z, int direction, int type) {
StructureBoundingBox _boundingBox = StructureBoundingBox.getComponentToAddBoundingBox(x, y, z, 0, 0, 0, 14, 14, 12, direction);
if (canVillageGoDeeper(_boundingBox)) {
if (StructureComponent.findIntersecting(pieces, _boundingBox) == null) {
return new VillageBaronCastle(startPiece, type, random, _boundingBox, direction);
}
}
return null;
}
示例11: buildComponent
import net.minecraft.world.gen.structure.StructureVillagePieces; //导入方法依赖的package包/类
@SuppressWarnings("rawtypes")
@Override
public Object buildComponent(PieceWeight villagePiece, Start startPiece, List pieces, Random random, int x, int y, int z, int coordBaseMode, int p5) {
int totalWeight = getTotalWieght(pieceWeights);
if(totalWeight <= 0) {
return null;
}
for (int i = 0; i < 5; ++i) {
int randomWeight = random.nextInt(totalWeight);
Iterator<WeightedCreationHandler> iterator = pieceWeights.iterator();
while (iterator.hasNext()) {
WeightedCreationHandler el = iterator.next();
PieceWeight pieceweight = el.weight;
randomWeight -= pieceweight.villagePieceWeight;
if(randomWeight < 0) {
int notUsed = 0;
if(!pieceweight.canSpawnMoreVillagePiecesOfType(notUsed)
|| pieceweight == startPiece.structVillagePieceWeight && pieceWeights.size() > 1) {
break;
}
StructureVillagePieces.Village village = (Village) el.handler.buildComponent(pieceweight, startPiece, pieces, random, x, y, z, coordBaseMode, p5);
if(village != null) {
++pieceweight.villagePiecesSpawned;
startPiece.structVillagePieceWeight = pieceweight;
if(!pieceweight.canSpawnMoreVillagePieces()) {
pieceWeights.remove(el);
}
return village;
}
}
}
}
return null;
}
示例12: buildComponent
import net.minecraft.world.gen.structure.StructureVillagePieces; //导入方法依赖的package包/类
@Override
public StructureVillagePieces.Village buildComponent(StructureVillagePieces.PieceWeight villagePiece, StructureVillagePieces.Start startPiece, List<StructureComponent> pieces, Random random, int p1, int p2, int p3, EnumFacing facing, int p5)
{
return Cave.createPiece(startPiece, pieces, random, p1, p2, p3, facing, p5);
}
示例13: buildComponent
import net.minecraft.world.gen.structure.StructureVillagePieces; //导入方法依赖的package包/类
@Override
public StructureVillagePieces.Village buildComponent(StructureVillagePieces.PieceWeight villagePiece, StructureVillagePieces.Start startPiece, List pieces, Random random, int p1, int p2, int p3, EnumFacing facing, int p5) {
return ComponentVillageUndertaker.buildComponent(startPiece, pieces, random, p1, p2, p3, facing, p5);
}
示例14: buildComponent
import net.minecraft.world.gen.structure.StructureVillagePieces; //导入方法依赖的package包/类
@Override
public StructureVillagePieces.Village buildComponent(StructureVillagePieces.PieceWeight villagePiece, StructureVillagePieces.Start startPiece, List pieces, Random random, int p1, int p2, int p3, EnumFacing facing, int p5) {
return ComponentVillageMemorial.buildComponent(startPiece, pieces, random, p1, p2, p3, facing, p5);
}
示例15: buildComponent
import net.minecraft.world.gen.structure.StructureVillagePieces; //导入方法依赖的package包/类
@Override
public StructureVillagePieces.Village buildComponent(StructureVillagePieces.PieceWeight villagePiece, StructureVillagePieces.Start startPiece, List<StructureComponent> pieces, Random random, int p1, int p2, int p3, EnumFacing facing, int p5) {
StructureBoundingBox boundingBox = StructureBoundingBox.getComponentToAddBoundingBox(p1, p2, p3, 0, 0, 0, 7, 6, 7, facing);
return new MoogleHouse(startPiece, p5, random, boundingBox, facing);
}