// Default probabilities // Equal chance of tree and rock, no enemies |-----|-----|-----|-----|-----| |T=50 |T=50 |T=50 |T=50 |T=50 | |R=50 |R=50 |R=50 |R=50 |R=50 | |E=0 |E=0 |E=0 |E=0 |E=0 | |-----|-----|-----|-----|-----| |T=50 |T=50 |T=50 |T=50 |T=50 | |R=50 |R=50 |R=50 |R=50 |R=50 | |E=0 |E=0 |E=0 |E=0 |E=0 | |-----|-----|-----|-----|-----| |T=50 |T=50 |T=50 |T=50 |T=50 | |R=50 |R=50 |R=50 |R=50 |R=50 | |E=0 |E=0 |E=0 |E=0 |E=0 | |-----|-----|-----|-----|-----| You'd pick one cell at random and change the values of that cell to Tree = 10%20%, Rock = 0%, Enemy = 90%80%. Then do the same for rocks. You can also use a radius of cells if you like to make the transitions smoother. You'll end up with something like:
// Added two random clusters: // One enemy cluster on the bottom right // One rock cluster on the top left |-----|-----|-----|-----|-----| |T=0 |T=30 |T=50 |T=50 |T=50 | |R=100|R=70 |R=50 |R=50 |R=50 | |E=0 |E=0 |E=0 |E=0 |E=0 | |-----|-----|-----|-----|-----| |T=30 |T=40 |T=50 |T=80 |T=70 | |R=70 |R=60 |R=50 |R=10 |R=0 | |E=0 |E=0 |E=0 |E=10 |E=30 | |-----|-----|-----|-----|-----| |T=50 |T=50 |T=50 |T=70 |T=20 | |R=50 |R=50 |R=50 |R=0 |R=0 | |E=0 |E=0 |E=0 |E=30 |E=80 | |-----|-----|-----|-----|-----|