Sunday, March 12, 2023

Picking random tiles to flip 'green' for land

8 March 2023- Lazy Flood Fill!

I'm going to make something which this guy calls 'Lazy Flood Fill' although I like to call it 'guided' flood fill. The page needs to create a grid of divs based on the size of some world we want to simulate. A nice grid of longitude and latitude will do to begin, so the page will draw a map div 360 by 180 pixels, a degree per pixel, and we'll go with a cell 3 pixels on a side.

Input a seed, please (the default is tau, or 2 pi), or click the button for a random seed number.

Seed: 6.283185307179586, current pseudo-random # 0.6282746310002949

Tile: 5190, horizontal: 30, vertical: 86

No comments:

Post a Comment