blob: e0c96d88b40f65d0c062f4d6be0b1d908da74e4b (
plain)
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
|
package gtPlusPlus.everglades.biome;
import net.minecraft.world.biome.BiomeGenBase;
import net.minecraft.world.gen.layer.GenLayer;
import net.minecraft.world.gen.layer.IntCache;
public class GenLayerBiomes extends GenLayer {
protected BiomeGenBase[] allowedBiomes = { BiomeEverglades.biome, };
public GenLayerBiomes(long seed) {
super(seed);
}
@Override
public int[] getInts(int x, int z, int width, int depth) {
int[] dest = IntCache.getIntCache(width * depth);
for (int dz = 0; dz < depth; dz++) {
for (int dx = 0; dx < width; dx++) {
this.initChunkSeed(dx + x, dz + z);
dest[(dx + dz * width)] = this.allowedBiomes[nextInt(this.allowedBiomes.length)].biomeID;
}
}
return dest;
}
}
|