
[Enhancement] Minimize placement of world gen structures in water
markaskey opened this issue ยท 2 comments
Great job on this, especially the Village Generation. I am liking what I am seeing so far and have a question on how the mob loads structures to world. I am finding many instance where structures are being place in water, sometimes with only a two or three block base of dirt. Would you control this through blacklisting biomes in the cfg? Also: Does your village generation mechanic place a few outbuildings around villages or is this just random chance? In a flat world,villages seem to be accompanied by a small hut (bed, chest, crafting table) 30 blocks or so from village. Just curious.
For random world structures the mod does a quick biome survey of the chunk to determine the predominant biome type. Based on that biome it will make selections from the schematic inventory. At the moment it is possible to have structures in water. If you take a close look at those structures you will find that the biomes are something like Forest or Swamp even though its a large area of standing water - Swamps can be bad for this. I need to work out a way to filter out these locations without incurring too much processing overhead. It's on my todo list.
As for the out buildings that is random chance. Generation occurs on a chunk by chunk basis. It is possible to populate a world gen structure in one chunk, and then have a village trigger when the next chunk gens. Sometimes you can wind up with world gen structures in villages because of this.
As for flat world the "density" of structures is higher by nature of the terrain. There is logic in the mod that looks at the height variance of the prospective area where a structure would go. If the block heights vary too much generation is ignored. Since superflat is, well, flat, there is no variance. The reason the mod checks for variance is to avoid things like structures generating on the side of a steep mountain. Note that villages don't follow this variance rule - the Village generator wants what it wants.
EDIT: While reading this post I came up with a way to minimize the chance of placing world structures over bodies of water. Will be in the next release when I post it.
Update available on CurseForge: http://minecraft.curseforge.com/projects/restructured/files