• 设为首页
  • 点击收藏
  • 手机版
    手机扫一扫访问
    迪恩网络手机版
  • 关注官方公众号
    微信扫一扫关注
    公众号

Java StructureVillagePieceWeight类代码示例

原作者: [db:作者] 来自: [db:来源] 收藏 邀请

本文整理汇总了Java中net.minecraft.world.gen.structure.StructureVillagePieceWeight的典型用法代码示例。如果您正苦于以下问题:Java StructureVillagePieceWeight类的具体用法?Java StructureVillagePieceWeight怎么用?Java StructureVillagePieceWeight使用的例子?那么恭喜您, 这里精选的类代码示例或许可以为您提供帮助。



StructureVillagePieceWeight类属于net.minecraft.world.gen.structure包,在下文中一共展示了StructureVillagePieceWeight类的14个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于我们的系统推荐出更棒的Java代码示例。

示例1: func_75084_a

import net.minecraft.world.gen.structure.StructureVillagePieceWeight; //导入依赖的package包/类
public static List func_75084_a(Random p_75084_0_, int p_75084_1_) {
   ArrayList var2 = new ArrayList();
   var2.add(new StructureVillagePieceWeight(ComponentVillageHouse4_Garden.class, 4, MathHelper.func_76136_a(p_75084_0_, 2 + p_75084_1_, 4 + p_75084_1_ * 2)));
   var2.add(new StructureVillagePieceWeight(ComponentVillageChurch.class, 20, MathHelper.func_76136_a(p_75084_0_, 0 + p_75084_1_, 1 + p_75084_1_)));
   var2.add(new StructureVillagePieceWeight(ComponentVillageHouse1.class, 20, MathHelper.func_76136_a(p_75084_0_, 0 + p_75084_1_, 2 + p_75084_1_)));
   var2.add(new StructureVillagePieceWeight(ComponentVillageWoodHut.class, 3, MathHelper.func_76136_a(p_75084_0_, 2 + p_75084_1_, 5 + p_75084_1_ * 3)));
   var2.add(new StructureVillagePieceWeight(ComponentVillageHall.class, 15, MathHelper.func_76136_a(p_75084_0_, 0 + p_75084_1_, 2 + p_75084_1_)));
   var2.add(new StructureVillagePieceWeight(ComponentVillageField.class, 3, MathHelper.func_76136_a(p_75084_0_, 1 + p_75084_1_, 4 + p_75084_1_)));
   var2.add(new StructureVillagePieceWeight(ComponentVillageField2.class, 3, MathHelper.func_76136_a(p_75084_0_, 2 + p_75084_1_, 4 + p_75084_1_ * 2)));
   var2.add(new StructureVillagePieceWeight(ComponentVillageHouse2.class, 15, MathHelper.func_76136_a(p_75084_0_, 0, 1 + p_75084_1_)));
   var2.add(new StructureVillagePieceWeight(ComponentVillageHouse3.class, 8, MathHelper.func_76136_a(p_75084_0_, 0 + p_75084_1_, 3 + p_75084_1_ * 2)));
   Iterator var3 = var2.iterator();

   while(var3.hasNext()) {
      if(((StructureVillagePieceWeight)var3.next()).field_75087_d == 0) {
         var3.remove();
      }
   }

   return var2;
}
 
开发者ID:HATB0T,项目名称:RuneCraftery,代码行数:22,代码来源:StructureVillagePieces.java


示例2: func_75083_a

import net.minecraft.world.gen.structure.StructureVillagePieceWeight; //导入依赖的package包/类
private static ComponentVillage func_75083_a(ComponentVillageStartPiece p_75083_0_, StructureVillagePieceWeight p_75083_1_, List p_75083_2_, Random p_75083_3_, int p_75083_4_, int p_75083_5_, int p_75083_6_, int p_75083_7_, int p_75083_8_) {
   Class var9 = p_75083_1_.field_75090_a;
   Object var10 = null;
   if(var9 == ComponentVillageHouse4_Garden.class) {
      var10 = ComponentVillageHouse4_Garden.func_74912_a(p_75083_0_, p_75083_2_, p_75083_3_, p_75083_4_, p_75083_5_, p_75083_6_, p_75083_7_, p_75083_8_);
   } else if(var9 == ComponentVillageChurch.class) {
      var10 = ComponentVillageChurch.func_74919_a(p_75083_0_, p_75083_2_, p_75083_3_, p_75083_4_, p_75083_5_, p_75083_6_, p_75083_7_, p_75083_8_);
   } else if(var9 == ComponentVillageHouse1.class) {
      var10 = ComponentVillageHouse1.func_74898_a(p_75083_0_, p_75083_2_, p_75083_3_, p_75083_4_, p_75083_5_, p_75083_6_, p_75083_7_, p_75083_8_);
   } else if(var9 == ComponentVillageWoodHut.class) {
      var10 = ComponentVillageWoodHut.func_74908_a(p_75083_0_, p_75083_2_, p_75083_3_, p_75083_4_, p_75083_5_, p_75083_6_, p_75083_7_, p_75083_8_);
   } else if(var9 == ComponentVillageHall.class) {
      var10 = ComponentVillageHall.func_74906_a(p_75083_0_, p_75083_2_, p_75083_3_, p_75083_4_, p_75083_5_, p_75083_6_, p_75083_7_, p_75083_8_);
   } else if(var9 == ComponentVillageField.class) {
      var10 = ComponentVillageField.func_74900_a(p_75083_0_, p_75083_2_, p_75083_3_, p_75083_4_, p_75083_5_, p_75083_6_, p_75083_7_, p_75083_8_);
   } else if(var9 == ComponentVillageField2.class) {
      var10 = ComponentVillageField2.func_74902_a(p_75083_0_, p_75083_2_, p_75083_3_, p_75083_4_, p_75083_5_, p_75083_6_, p_75083_7_, p_75083_8_);
   } else if(var9 == ComponentVillageHouse2.class) {
      var10 = ComponentVillageHouse2.func_74915_a(p_75083_0_, p_75083_2_, p_75083_3_, p_75083_4_, p_75083_5_, p_75083_6_, p_75083_7_, p_75083_8_);
   } else if(var9 == ComponentVillageHouse3.class) {
      var10 = ComponentVillageHouse3.func_74921_a(p_75083_0_, p_75083_2_, p_75083_3_, p_75083_4_, p_75083_5_, p_75083_6_, p_75083_7_, p_75083_8_);
   }

   return (ComponentVillage)var10;
}
 
开发者ID:HATB0T,项目名称:RuneCraftery,代码行数:26,代码来源:StructureVillagePieces.java


示例3: addExtraVillageComponents

import net.minecraft.world.gen.structure.StructureVillagePieceWeight; //导入依赖的package包/类
public static void addExtraVillageComponents(ArrayList components, Random random, int i)
{
    List<StructureVillagePieceWeight> parts = components;
    for (IVillageCreationHandler handler : instance().villageCreationHandlers.values())
    {
        parts.add(handler.getVillagePieceWeight(random, i));
    }
}
 
开发者ID:Stormister,项目名称:Rediscovered-Mod-1.6.4,代码行数:9,代码来源:GreenRegistry.java


示例4: getVillagePieceWeight

import net.minecraft.world.gen.structure.StructureVillagePieceWeight; //导入依赖的package包/类
@Override
public StructureVillagePieceWeight getVillagePieceWeight(Random random, int i)
{
    return new StructureVillagePieceWeight(getComponentClass(), 10000, 1);
}
 
开发者ID:CCM-Modding,项目名称:CcmBurialServicesInc,代码行数:6,代码来源:GraveyardHandler.java


示例5: buildComponent

import net.minecraft.world.gen.structure.StructureVillagePieceWeight; //导入依赖的package包/类
@Override
public Object buildComponent(StructureVillagePieceWeight villagePiece, ComponentVillageStartPiece startPiece, List pieces, Random random, int p1, int p2, int p3, int p4, int p5)
{
    return GraveyardComponent.buildComponent(startPiece, pieces, random, p1, p2, p3, p4, p5);
}
 
开发者ID:CCM-Modding,项目名称:CcmBurialServicesInc,代码行数:6,代码来源:GraveyardHandler.java


示例6: getVillageComponent

import net.minecraft.world.gen.structure.StructureVillagePieceWeight; //导入依赖的package包/类
public static Object getVillageComponent(StructureVillagePieceWeight villagePiece, ComponentVillageStartPiece startPiece, List pieces, Random random,
        int p1, int p2, int p3, int p4, int p5)
{
    return instance().villageCreationHandlers.get(villagePiece.villagePieceClass).buildComponent(villagePiece, startPiece, pieces, random, p1, p2, p3, p4, p5);
}
 
开发者ID:Stormister,项目名称:Rediscovered-Mod-1.6.4,代码行数:6,代码来源:GreenRegistry.java


示例7: getVillageComponent

import net.minecraft.world.gen.structure.StructureVillagePieceWeight; //导入依赖的package包/类
public static Object getVillageComponent(StructureVillagePieceWeight villagePiece, ComponentVillageStartPiece startPiece, List pieces, Random random,
        int p1, int p2, int p3, int p4, int p5)
{
    return instance().villageCreationHandlers.get(villagePiece.field_75090_a).buildComponent(villagePiece, startPiece, pieces, random, p1, p2, p3, p4, p5);
}
 
开发者ID:HATB0T,项目名称:RuneCraftery,代码行数:6,代码来源:VillagerRegistry.java


示例8: func_75081_c

import net.minecraft.world.gen.structure.StructureVillagePieceWeight; //导入依赖的package包/类
private static ComponentVillage func_75081_c(ComponentVillageStartPiece p_75081_0_, List p_75081_1_, Random p_75081_2_, int p_75081_3_, int p_75081_4_, int p_75081_5_, int p_75081_6_, int p_75081_7_) {
   int var8 = func_75079_a(p_75081_0_.field_74931_h);
   if(var8 <= 0) {
      return null;
   } else {
      int var9 = 0;

      while(var9 < 5) {
         ++var9;
         int var10 = p_75081_2_.nextInt(var8);
         Iterator var11 = p_75081_0_.field_74931_h.iterator();

         while(var11.hasNext()) {
            StructureVillagePieceWeight var12 = (StructureVillagePieceWeight)var11.next();
            var10 -= var12.field_75088_b;
            if(var10 < 0) {
               if(!var12.func_75085_a(p_75081_7_) || var12 == p_75081_0_.field_74926_d && p_75081_0_.field_74931_h.size() > 1) {
                  break;
               }

               ComponentVillage var13 = func_75083_a(p_75081_0_, var12, p_75081_1_, p_75081_2_, p_75081_3_, p_75081_4_, p_75081_5_, p_75081_6_, p_75081_7_);
               if(var13 != null) {
                  ++var12.field_75089_c;
                  p_75081_0_.field_74926_d = var12;
                  if(!var12.func_75086_a()) {
                     p_75081_0_.field_74931_h.remove(var12);
                  }

                  return var13;
               }
            }
         }
      }

      StructureBoundingBox var14 = ComponentVillageTorch.func_74904_a(p_75081_0_, p_75081_1_, p_75081_2_, p_75081_3_, p_75081_4_, p_75081_5_, p_75081_6_);
      if(var14 != null) {
         return new ComponentVillageTorch(p_75081_0_, p_75081_7_, p_75081_2_, var14, p_75081_6_);
      } else {
         return null;
      }
   }
}
 
开发者ID:HATB0T,项目名称:RuneCraftery,代码行数:43,代码来源:StructureVillagePieces.java


示例9: getVillagePieceWeight

import net.minecraft.world.gen.structure.StructureVillagePieceWeight; //导入依赖的package包/类
@Override
public StructureVillagePieceWeight getVillagePieceWeight(Random random, int size) {
	return new StructureVillagePieceWeight(ComponentVillageBeeHouse.class, 15, MathHelper.getRandomIntegerInRange(random, 0 + size, 1 + size));
}
 
开发者ID:ForestryMC,项目名称:ForestryLegacy,代码行数:5,代码来源:VillageHandlerApiculture.java


示例10: buildComponent

import net.minecraft.world.gen.structure.StructureVillagePieceWeight; //导入依赖的package包/类
@Override
public Object buildComponent(StructureVillagePieceWeight villagePiece, ComponentVillageStartPiece startPiece, List pieces, Random random, int p1, int p2,
		int p3, int p4, int p5) {
	return ComponentVillageBeeHouse.buildComponent(startPiece, pieces, random, p1, p2, p3, p4, p5);
}
 
开发者ID:ForestryMC,项目名称:ForestryLegacy,代码行数:6,代码来源:VillageHandlerApiculture.java


示例11: getVillagePieceWeight

import net.minecraft.world.gen.structure.StructureVillagePieceWeight; //导入依赖的package包/类
@Override
public StructureVillagePieceWeight getVillagePieceWeight(Random random, int i) {
	return new StructureVillagePieceWeight(ComponentVillageCemetery.class, 5, 1);
}
 
开发者ID:sirolf2009,项目名称:Necromancy,代码行数:5,代码来源:PacketHandler.java


示例12: buildComponent

import net.minecraft.world.gen.structure.StructureVillagePieceWeight; //导入依赖的package包/类
@Override
public Object buildComponent(StructureVillagePieceWeight villagePiece, ComponentVillageStartPiece startPiece, @SuppressWarnings("rawtypes") List pieces, Random random, int p1, int p2, int p3, int p4, int p5) {
	ComponentVillageCemetery cemetery = ComponentVillageCemetery.func_74919_a(startPiece, pieces, random, p1, p2, p3, p4, p5);
	return cemetery;
}
 
开发者ID:sirolf2009,项目名称:Necromancy,代码行数:6,代码来源:PacketHandler.java


示例13: getVillagePieceWeight

import net.minecraft.world.gen.structure.StructureVillagePieceWeight; //导入依赖的package包/类
/**
 * Called when {@link net.minecraft.world.gen.structure.MapGenVillage} is creating a new village
 *
 * @param random
 * @param i
 */
StructureVillagePieceWeight getVillagePieceWeight(Random random, int i);
 
开发者ID:Stormister,项目名称:Rediscovered-Mod-1.6.4,代码行数:8,代码来源:GreenRegistry.java


示例14: buildComponent

import net.minecraft.world.gen.structure.StructureVillagePieceWeight; //导入依赖的package包/类
/**
 * Build an instance of the village component {@link net.minecraft.world.gen.structure.StructureVillagePieces}
 * @param villagePiece
 * @param startPiece
 * @param pieces
 * @param random
 * @param p1
 * @param p2
 * @param p3
 * @param p4
 * @param p5
 */
Object buildComponent(StructureVillagePieceWeight villagePiece, ComponentVillageStartPiece startPiece, List pieces, Random random, int p1,
        int p2, int p3, int p4, int p5);
 
开发者ID:Stormister,项目名称:Rediscovered-Mod-1.6.4,代码行数:15,代码来源:GreenRegistry.java



注:本文中的net.minecraft.world.gen.structure.StructureVillagePieceWeight类示例整理自Github/MSDocs等源码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。


鲜花

握手

雷人

路过

鸡蛋
该文章已有0人参与评论

请发表评论

全部评论

专题导读
上一篇:
Java BaseProduct类代码示例发布时间:2022-05-23
下一篇:
Java WGS84Point类代码示例发布时间:2022-05-23
热门推荐
阅读排行榜

扫描微信二维码

查看手机版网站

随时了解更新最新资讯

139-2527-9053

在线客服(服务时间 9:00~18:00)

在线QQ客服
地址:深圳市南山区西丽大学城创智工业园
电邮:jeky_zhao#qq.com
移动电话:139-2527-9053

Powered by 互联科技 X3.4© 2001-2213 极客世界.|Sitemap