I was still interested in the generation of random terrain after my Terraria Clone so I decided to continue development of the generation specifically in Python. I re-implemented cosine interpolation and added trees, clouds, water, lighting and cave generation.
The caves use a form of seeding to generate where random ‘seed’ tiles are selected in the ground and then every iteration the seed will have a random chance to transform an adjacent tile into another seed. Interesting patches of caves started to develop after several iterations and the inclusion of water to flood exposed cave entrances lead to an interesting landscape generator.

