Getting local minHeights within MapPixel height map

Discuss modding questions and implementation details.
Post Reply
User avatar
Daniel87
Posts: 391
Joined: Thu Nov 28, 2019 6:25 pm

Getting local minHeights within MapPixel height map

Post by Daniel87 »

Hi dear community,

My mod creates Oasis' all over in the desert on a random principle.
The problem is, when using mods that alter or enhance the height map, the slopes become more aparent and water tiles will be placed on steep slopes.

Is there any function, class or method that can find local minHeights in a MapPixels height map?
I would need that utility to randomly pick one in the ITerrainTexturing and make it become water, maybe even smooth out neighbouring tiles to be horizontal as well an water. If not, I might have to spend a few days or a week to investigate how heightmaps can be manipulated without distorting the whole surrounding area and figure a smoothing process for the local minHeight points surrounding as well as writing a method to find me local minima. I'd rather not do that, as I don't know yet if the necessary scripts are modable yet.

Thanks for any help, as always!
In Julianos we Trust.

Post Reply