This visualization will help brush users figure out which area is going to be affected by the active brush. I had to make sure that the brush would wrap around the both horizontal and vertical edges of the map given that they are spherical world projections. When wrapping around horizontal borders specifically, the tool will reappear on the same side of the map but with a 180° degree shift.

After finishing with the visualization, I lost a couple of hours verifying very old map projection code due to some misunderstanding of basic trigonometry which probably would have made all my math professors from college down to middle school shake their heads in disappointment.

Anyway… I finally started working on the actual functionality of the tools. I’m rewriting part of the terrain generation functions so that they can be called only on the cells highlighted by the brush. My hope is that I can have a working prototype by the end of this week.