|
|
|
|
|
by tfinniga
4352 days ago
|
|
With maze generation, you need some way of deciding which subset of the possible walls you're going to keep. Usually you rely on some random or pseudorandom numbers to feed into the algorithm or use internally. Having the maze verts in the same positions is possible and not too unlikely. Having the same walls is astronomically unlikely. Even if you had exactly the same algorithm (possible, but unlikely) and the implementations used the random values in exactly the same order, you'd also need exactly the same random seed. There are a lot of possibilities for that seed. |
|
I've seen a lot of code that either forgot to srand(), or misused it in some way so the output was pretty determinate. There are also a limited number of PRNGs in use, and they're most definitely not understood well by the majority of programmers; the crypto community knows this quite well. A collision may not be so unlikely after all.
(Try Googling "41, 18467, 6334" for example. "41184676334" also brings up some interesting results.)