This implementation presents a simplified constraint-based terrain generator, inspired by Wave Function Collapse (WFC) but utilizing a greedy approach. While true WFC maintains superposition of all possible states until collapse, this algorithm makes immediate decisions based on local rules.
The resulting maps, while less precise than true WFC, generate quickly and provide satisfactory terrain patterns for many practical applications.