Preparations to go from a 3x3 board to a NxN board

Have added several function required for the game to unfold on a NxN board instead of a 3x3 board. Hopefully the transition will be smooth :)