Using Swift, iOS 15
I am working on building a simple 3D tic-tac-toe game and need a suitable data structure so that I can efficiently check for a winner. The game board looks like this.
Not easy to see here but it makes far more sense if you can move it around. Now in this example the blue player has won, since they have three squares in row diagonally.
In this version I have 9 x 9 nodes. I wanted to use GKOctree, but it seems to be broken and reading about it isn't the right solution.
I think some form of a linked list or simply a multidimensional array might work, but has someone come up with a better plan they could share?
