Assuming moisture/rainfall was one of the factors in determining the biomes. How did you go about determining the rainfall for each hex?
The rainfall isn't really as sophisticated as it could be, it's just random noise. Right now it uses four overlaid Simplex Noise maps, for height, temperature (y-axis biased), rainfall and drainage. The terrain types are basically determined by all those noise values in order. Once I got the simplex noise working, it was pretty simple from there. Those mountain ranges were probably more effort all by themselves, at least getting them to look natural.
I also used simplex noise for elevation, for temperature I just have a simple function that makes it hotter at the equator and colder as you go outwards. I'm not entirely happy with my rainfall. It does two things to determine the rainfall simulation. First, it calculates a rainshadow, so you end up with deserts on the eastern side of large enough mountains. Second, it propagates moisture from all water sources, in all directions. Something that I would eventually like to try is mentioned part way down in
this article about generating different areas of wind speed and direction and then simulating the paths of several weather cells. Though the article is talking about generating using OpenCL, I still found it useful.
Did the use of hexes make it much more difficult to code?
I'd suggest this fantastic guide by Amit Patel to anyone thinking about working with hex maps. Most of my understanding came from there.
Have you read some of his other articles? I found
this to be very useful, it helped me understand what I was doing early on. (Let me know if that link isn't working. I'm on a bad connection and can't load it right now).
Also, are you going to add rivers to it?
I've been thinking about it. There's a lot to think about if I wanted to do it right, like sprites.
Doing the sprites wasn't that bad for me. It would be more time consuming since there are 6 directions for hexes instead of 4 for tiles. But, all I did was, pass each river tile through a function that determines which river sprite it should use. It just looks at all of the tiles adjacent to the river to do so. There would have to be many different sprites though because of the amount of directions and intersections possible.
The other issue that I see is making it so the rivers background color is the same as the surrounding land. Though it isn't perfect if you look at the image I linked, I have a something that could do it. The way I display the sprites is that initially, the background of the sprite is magenta, and the foreground is white. First it determines the background and foreground colors of each tile based on their biome. It's very subtle, but on the forests especially you can see slight variation in the background colors. I had the tiles elevations affect the background color. For rivers, I just took an average of background colors surrounding the river, and made that the river's background color.
It then runs each tile through a shader that replaces the magenta with that tile's background color, and the white with that tile's foreground color. Though my method only allows two colors in the sprite, it could be expanded to have more, and perhaps there is a better method. I think rivers were the most painstaking part for me so far though. They still need some tweaking, just like the rest of the generator.