Move the directory structure around to a more conventional one and start out on the 1.7 update.

3797 errors. We have a long way to go.
This commit is contained in:
Ben Spiers committed 2014-04-20 03:44:06 +01:00
1 parent 3a0de87a09
commit ab47724473
1245 files changed
+1764 -5953

No files matched your search

@@ -0,0 +1,55 @@
package mekanism.common;
import java.util.Random;
import net.minecraft.block.Block;
import net.minecraft.item.ItemStack;
import net.minecraft.world.World;
import net.minecraft.world.chunk.IChunkProvider;
import net.minecraft.world.gen.ChunkProviderEnd;
import net.minecraft.world.gen.ChunkProviderHell;
import net.minecraft.world.gen.feature.WorldGenMinable;
import cpw.mods.fml.common.IWorldGenerator;
public class OreHandler implements IWorldGenerator
{
@Override
public void generate(Random random, int chunkX, int chunkZ, World world, IChunkProvider chunkGenerator, IChunkProvider chunkProvider)
{
if(!(chunkGenerator instanceof ChunkProviderHell) && !(chunkGenerator instanceof ChunkProviderEnd))
{
if(Mekanism.osmiumGenerationEnabled)
{
for(int i = 0; i < Mekanism.osmiumGenerationAmount; i++)
{
int randPosX = (chunkX*16) + random.nextInt(16);
int randPosY = random.nextInt(60);
int randPosZ = (chunkZ*16) + random.nextInt(16);
new WorldGenMinable(Mekanism.oreBlockID, 0, 8, Block.stone.blockID).generate(world, random, randPosX, randPosY, randPosZ);
}
}
if(Mekanism.copperGenerationEnabled)
{
for(int i = 0; i < Mekanism.copperGenerationAmount; i++)
{
int randPosX = (chunkX*16) + random.nextInt(16);
int randPosY = random.nextInt(60);
int randPosZ = (chunkZ*16) + random.nextInt(16);
new WorldGenMinable(Mekanism.oreBlockID, 1, 8, Block.stone.blockID).generate(world, random, randPosX, randPosY, randPosZ);
}
}
if(Mekanism.tinGenerationEnabled)
{
for(int i = 0; i < Mekanism.tinGenerationAmount; i++)
{
int randPosX = (chunkX*16) + random.nextInt(16);
int randPosY = random.nextInt(60);
int randPosZ = (chunkZ*16) + random.nextInt(16);
new WorldGenMinable(Mekanism.oreBlockID, 2, 8, Block.stone.blockID).generate(world, random, randPosX, randPosY, randPosZ);
}
}
}
}
}