当前位置: 首页>>代码示例>>Java>>正文


Java ChunkProviderHell类代码示例

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


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

示例1: generate

import net.minecraft.world.gen.ChunkProviderHell; //导入依赖的package包/类
@Override
public void generate(Random random, int chunkX, int chunkZ, World world, IChunkProvider chunkGenerator, IChunkProvider chunkProvider)
{
	// chunkX <<= 4;
	// chunkZ <<= 4;
	BlockPos pos = new BlockPos(chunkX, 1, chunkZ);
	if (chunkGenerator instanceof ChunkProviderGenerate
			|| chunkGenerator.getClass().toString().contains("ChunkProviderRTG"))
	{
		this.generateOverworld(world, random, chunkX, chunkZ);
		if (Config.genBiomeStones == true)
		{
			this.genBiomeStone(world, chunkX, chunkZ, random);
		}
	}
	else if (chunkGenerator instanceof ChunkProviderHell)
	{
		this.generateNether(world, random, chunkX, chunkZ);
	}
	else if (chunkGenerator instanceof ChunkProviderEnd)
	{
		this.generateEnd(world, random, chunkX, chunkZ);
	}
}
 
开发者ID:MinestrapTeam,项目名称:Minestrappolation-4,代码行数:25,代码来源:MGenHandler.java

示例2: generate

import net.minecraft.world.gen.ChunkProviderHell; //导入依赖的package包/类
@Override
public void generate(Random random, int chunkX, int chunkZ, World world, IChunkProvider chunkGenerator, IChunkProvider chunkProvider)
{
    if(!(chunkGenerator instanceof ChunkProviderHell) && !(chunkGenerator instanceof ChunkProviderEnd))
    {
        for(int i = 0; i < ConfigurationHandler.leadOrePerChunk; i++)
        {
            int randPosX = (chunkX*16) + random.nextInt(16);
            int randPosY = random.nextInt(60);
            int randPosZ = (chunkZ*16) + random.nextInt(16);
            new WorldGenMinable(ModBlocks.leadOre, 10, Blocks.stone).generate(world, random, randPosX, randPosY, randPosZ);
        }


    }
}
 
开发者ID:JWStrube,项目名称:Aftermath,代码行数:17,代码来源:OreGenHandler.java

示例3: isOreGeneratedInWorld

import net.minecraft.world.gen.ChunkProviderHell; //导入依赖的package包/类
@Override
public boolean isOreGeneratedInWorld(World world, IChunkProvider chunkGenerator)
{
	if (!this.shouldGenerate)
	{
		return false;
	}
	if (this.ignoreSurface && chunkGenerator instanceof ChunkProviderGenerate)
	{
		return false;
	}
	if (this.ignoreNether && chunkGenerator instanceof ChunkProviderHell)
	{
		return false;
	}
	if (this.ignoreEnd && chunkGenerator instanceof ChunkProviderEnd)
	{
		return false;
	}
	return true;
}
 
开发者ID:tterrag1098,项目名称:SimpleTransmutations,代码行数:22,代码来源:OreGenReplace.java

示例4: generate

import net.minecraft.world.gen.ChunkProviderHell; //导入依赖的package包/类
@Override
public void generate(Random random, int chunkX, int chunkZ, World world, IChunkProvider chunkGenerator, IChunkProvider chunkProvider) {
    if (!(chunkGenerator instanceof ChunkProviderHell) && !(chunkGenerator instanceof ChunkProviderEnd)) {
        generateSurface(world, random, chunkX * 16, chunkZ * 16);
    } else if (chunkGenerator instanceof ChunkProviderHell) {
        generateNether(world, random, chunkX * 16, chunkZ * 16);
    } else {
        generateEnd(world, random, chunkX * 16, chunkZ * 16);
    }
}
 
开发者ID:MagiciansArtificeTeam,项目名称:Magicians-Artifice,代码行数:11,代码来源:GenerationHandler.java

示例5: generate

import net.minecraft.world.gen.ChunkProviderHell; //导入依赖的package包/类
@Override
public void generate(Random random, int chunkX, int chunkZ, World world, IChunkProvider chunkGenerator, IChunkProvider chunkProvider)
{
    if (chunkGenerator instanceof ChunkProviderGenerate)
    {
        mod.generateSurface(world, random, chunkX << 4, chunkZ << 4);
    }
    else if (chunkGenerator instanceof ChunkProviderHell)
    {
        mod.generateNether(world, random, chunkX << 4, chunkZ << 4);
    }
}
 
开发者ID:HATB0T,项目名称:RuneCraftery,代码行数:13,代码来源:ModLoaderWorldGenerator.java

示例6: createChunkGenerator

import net.minecraft.world.gen.ChunkProviderHell; //导入依赖的package包/类
/**
 * Returns a new chunk provider which generates chunks for this world
 */
public IChunkProvider createChunkGenerator()
{
    return new ChunkProviderHell(this.worldObj, this.worldObj.getWorldInfo().isMapFeaturesEnabled(), this.worldObj.getSeed());
}
 
开发者ID:Notoh,项目名称:DecompiledMinecraft,代码行数:8,代码来源:WorldProviderHell.java

示例7: createChunkGenerator

import net.minecraft.world.gen.ChunkProviderHell; //导入依赖的package包/类
public IChunkGenerator createChunkGenerator()
{
    return new ChunkProviderHell(this.worldObj, this.worldObj.getWorldInfo().isMapFeaturesEnabled(), this.worldObj.getSeed());
}
 
开发者ID:sudofox,项目名称:Backmemed,代码行数:5,代码来源:WorldProviderHell.java

示例8: createChunkGeneration

import net.minecraft.world.gen.ChunkProviderHell; //导入依赖的package包/类
public IChunkProvider createChunkGeneration() {
	return new ChunkProviderHell(this.worldObj, this.worldObj.getWorldInfo().isMapFeaturesEnabled(), this.worldObj.getSeed());
}
 
开发者ID:AdityaGupta1,项目名称:mobycraft,代码行数:4,代码来源:WorldProviderMagicLand.java

示例9: setTarget

import net.minecraft.world.gen.ChunkProviderHell; //导入依赖的package包/类
public void setTarget(String target, int type) {
   this.timeToLive = TimeUtil.secsToTicks(10);
   this.spiritType = type;

   try {
      if(target.equals("Village")) {
         IChunkProvider ex;
         for(ex = super.worldObj.getChunkProvider(); ex != null && ex instanceof ChunkProviderServer; ex = ((ChunkProviderServer)ex).currentChunkProvider) {
            ;
         }

         if(ex != null) {
            if(ex instanceof ChunkProviderFlat) {
               if(fieldStructureGenerators == null) {
                  fieldStructureGenerators = ReflectionHelper.findField(ChunkProviderFlat.class, new String[]{"structureGenerators", "field_82696_f", "f"});
               }

               Iterator iterator = ((List)fieldStructureGenerators.get((ChunkProviderFlat)ex)).iterator();

               while(iterator.hasNext()) {
                  if(this.setWaypointTo(iterator.next(), MapGenVillage.class)) {
                     return;
                  }
               }
            } else if(ex instanceof ChunkProviderGenerate) {
               if(fieldVillageGenerator == null) {
                  fieldVillageGenerator = ReflectionHelper.findField(ChunkProviderGenerate.class, new String[]{"villageGenerator", "field_73224_v", "v"});
               }

               if(fieldVillageGenerator != null) {
                  this.setWaypointTo(fieldVillageGenerator.get((ChunkProviderGenerate)ex), MapGenVillage.class);
               }
            } else if(ex instanceof ChunkProviderHell) {
               this.setWaypointTo(((ChunkProviderHell)ex).genNetherBridge);
            }
         }
      }
   } catch (IllegalAccessException var5) {
      ;
   }

}
 
开发者ID:lerion13,项目名称:witchery,代码行数:43,代码来源:EntitySpirit.java

示例10: createChunkGenerator

import net.minecraft.world.gen.ChunkProviderHell; //导入依赖的package包/类
/**
 * Returns a new chunk provider which generates chunks for this world
 */
public IChunkProvider createChunkGenerator()
{
    return new ChunkProviderHell(this.worldObj, this.worldObj.getSeed());
}
 
开发者ID:MinecraftModdedClients,项目名称:Resilience-Client-Source,代码行数:8,代码来源:WorldProviderHell.java

示例11: createChunkGenerator

import net.minecraft.world.gen.ChunkProviderHell; //导入依赖的package包/类
public IChunkProvider createChunkGenerator()
{
    return new ChunkProviderHell(this.worldObj, this.worldObj.getSeed());
}
 
开发者ID:xtrafrancyz,项目名称:Cauldron,代码行数:5,代码来源:WorldProviderHell.java

示例12: func_76555_c

import net.minecraft.world.gen.ChunkProviderHell; //导入依赖的package包/类
public IChunkProvider func_76555_c() {
   return new ChunkProviderHell(this.field_76579_a, this.field_76579_a.func_72905_C());
}
 
开发者ID:HATB0T,项目名称:RuneCraftery,代码行数:4,代码来源:WorldProviderHell.java

示例13: populateWorldProperties

import net.minecraft.world.gen.ChunkProviderHell; //导入依赖的package包/类
private static void populateWorldProperties(Map<String,Object> properties, World world, WorldInfo worldInfo)
{
    properties.put("world", worldInfo == null ? "" : worldInfo.getWorldName());
    properties.put("world.seed", worldInfo == null ? 0L : worldInfo.getSeed());
    properties.put("world.version", worldInfo == null ? 0 : worldInfo.getSaveVersion());
    properties.put("world.isHardcore", worldInfo == null ? false : worldInfo.isHardcoreModeEnabled());
    properties.put("world.hasFeatures", worldInfo == null ? false : worldInfo.isMapFeaturesEnabled());
    properties.put("world.hasCheats", worldInfo == null ? false : worldInfo.areCommandsAllowed());
    properties.put("world.gameMode", worldInfo == null ? "" : worldInfo.getGameType().getName());
    properties.put("world.gameMode.id", worldInfo == null ? 0 : worldInfo.getGameType().getID());
    properties.put("world.type", worldInfo == null ? "" : worldInfo.getTerrainType().getName());
    properties.put("world.type.version", worldInfo == null ? 0 : worldInfo.getTerrainType().getGeneratorVersion());
    String genName = "RandomLevelSource";
    String genClass = "ChunkProviderOverworld";

    if (world != null)
    {
        IChunkGenerator chunkGenerator = world.provider.createChunkGenerator();
        genName = chunkGenerator.toString();
        genClass = chunkGenerator.getClass().getSimpleName();

        if (chunkGenerator instanceof ChunkProviderOverworld)
        {
            genClass = "ChunkProviderOverworld";
        }
        else if (chunkGenerator instanceof ChunkProviderFlat)
        {
            genClass = "ChunkProviderFlat";
        }
        else if (chunkGenerator instanceof ChunkProviderHell)
        {
            genClass = "ChunkProviderHell";
        }
        else if (chunkGenerator instanceof ChunkProviderEnd)
        {
            genName = "EndRandomLevelSource";
            genClass = "ChunkProviderEnd";
        }
    }

    properties.put("dimension.generator", genName);
    properties.put("dimension.generator.class", genClass);
    properties.put("dimension", world == null ? "" : world.provider.getDimensionType().getName());
    properties.put("dimension.id", world == null ? 0 : world.provider.getDimension());
    properties.put("dimension.isSurface", world == null ? false : world.provider.isSurfaceWorld());
    properties.put("dimension.hasNoSky", world == null ? false : world.provider.hasNoSky());
    properties.put("dimension.groundLevel", world == null ? 0 : world.provider.getAverageGroundLevel());
    properties.put("dimension.actualHeight", world == null ? 0 : world.getActualHeight());
    properties.put("dimension.height", world == null ? 0 : world.getHeight());
    properties.put("age", false);
}
 
开发者ID:lawremi,项目名称:CustomOreGen,代码行数:52,代码来源:WorldConfig.java


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