#ifndef GAME #define GAME #include "qwixx.h" #include "dice.h" #include "ScoreSheet.h" #include struct Move { int index; int color; }; struct CollectionOfMoves { Move white; Move color; // this can be zero, one or two int numberOfMoves = 0; bool penalty; }; class Game { public: std::vector players; std::vector lockOut; int lastColumnIndex; int state; Dice dice; int activePlayer; Game(); void turn(ScoreSheet activePlayer); void score(); std::string send(); void receive(std::string userInput); // rules as methods of game bool addPlayer(std::string name); // rule for lockout to populate a locked out row so score function can check for locked rows void addX(int player, int color, int index); // rule for being able to lockout a row, check for last box marked off and set condition where the next box has to be higher than that previous box check void lockOutRule(int player, int color, int index); void leftToRightRule(int player, int color, int index); bool Game::isMoveRepresentedInDie(int player, CollectionOfMoves collectionOfMoves); /* TODO: generate a set of all possible moves a player can take given a: ScoreSheet & diceRoll * 1. one good reason to do this would be to check if a player can make a given move * 2. if you give this set of moves to an AI, it could pick a move * 3. could give hints to an end user about what move they can take */ }; #endif