Original Post
Hi,
I would like to make a game like this: http://www.funnygame...pet-connect.htm, however I can not seem to wrap my head around if I need to prevent deadlocks and if so how.
Often the player has multiple other blocks to which he can connect a block. How can I guarantee there wont be a situation where no options are left no matter which block the player connects and no matter which sequence?
Also on a small 4x4 grid it is possible to generate a deadlocked seed:
1234
2413
3142
4321
I would like to make a game like this: http://www.funnygame...pet-connect.htm, however I can not seem to wrap my head around if I need to prevent deadlocks and if so how.
Often the player has multiple other blocks to which he can connect a block. How can I guarantee there wont be a situation where no options are left no matter which block the player connects and no matter which sequence?
Also on a small 4x4 grid it is possible to generate a deadlocked seed:
1234
2413
3142
4321