\r
public void ResetGame(Object[] playerIdentifiers, Object thisPlayer)\r
{\r
- if (playerIdentifiers.Length != 4)\r
- throw new Exception("This game requires four players.");\r
+ //if (playerIdentifiers.Length != 4)\r
+ // throw new Exception("This game requires four players.");\r
\r
// Copy the player identifiers - do not rely on the array parameter not changing.\r
\r
- for (int i = 0; i < 4; i++)\r
+ // Now the test harness will at least run with less than 4 players...\r
+ int numPlayers = playerIdentifiers.Count();\r
+ for (int i = 0; i < numPlayers; i++)\r
this.playerIdentifiers[i] = playerIdentifiers[i];\r
\r
// Create new game state and inputs objects.\r
nameHexPair(spriteBatch, Color.White, "Checksum:", state.Checksum, 215, 515, 100);\r
nameDecPair(spriteBatch, Color.White, "Elapsed Time:", state.elapsedTime / 1000.0f, 570, 790, 100);\r
\r
+ Console.WriteLine("Frame: " + state.frameNumber + " Checksum: " + state.Checksum);\r
+\r
printPlayer(spriteBatch, Color.Turquoise, 0, 10, 190, 170);\r
printPlayer(spriteBatch, Color.Wheat, 1, 210, 390, 170);\r
printPlayer(spriteBatch, Color.Tomato, 2, 410, 590, 170);\r