2121
2222#include " DevelopmentCard.h"
2323
24-
2524class GameVisitor ;
2625
2726/* *
@@ -37,7 +36,7 @@ class GameBoard {
3736
3837 Deck deck;
3938
40- std::map<Coordinate, std::vector<std::shared_ptr<Road>>> roads;
39+ std::map<Coordinate, std::vector<std::shared_ptr<Road>>>roads;
4140
4241 std::vector<std::unique_ptr<Player>> players;
4342 Coordinate robber;
@@ -46,12 +45,11 @@ class GameBoard {
4645 int maxVictoryPoints;
4746 int winner;
4847
49- void addResource (int x, int y, resourceType res, int val);
50- bool checkRolls (int * rolls);
48+ void addResource (int x, int y, resourceType res, int val);
49+ bool checkRolls (int * rolls);
5150
5251 bool isValidBoard () const ;
5352
54-
5553 bool outOfBounds (const Coordinate& coord) const ;
5654 bool roadExists (Coordinate start, Coordinate end) const ;
5755 bool isRoadConnectionPoint (Coordinate point, Player& Owner) const ;
@@ -64,11 +62,11 @@ class GameBoard {
6462
6563 void createRing (Coordinate topRight, int sideLength, std::vector<resourceType>& resources, std::vector<int >& rolls);
6664 void insertTile (Coordinate location, std::vector<resourceType>& resources, std::vector<int >& rolls);
67-
68- std::pair<int , int > startTurn ();
69- void enableRobber ();
70- void payoutResources (int roll);
71-
65+
66+ std::pair<int , int > startTurn ();
67+ void enableRobber ();
68+ void payoutResources (int roll);
69+
7270public:
7371 GameBoard (const std::vector<std::string>& playerNames);
7472 GameBoard (const std::vector<std::string>& playerNames, const std::map<Coordinate, std::pair<resourceType, int >>& resourceLocations);
@@ -112,16 +110,16 @@ class GameBoard {
112110 void PlaceSettlement (Coordinate location, Player& Owner);
113111 void UpgradeSettlement (Coordinate location);
114112 void UpgradeToWonder (Coordinate location);
115-
113+
116114 bool verifyRoadPlacement (Coordinate start, Coordinate end, Player& Owner) const ;
117115 bool buyRoad (Coordinate start, Coordinate end, Player& Owner);
118-
116+
119117 bool canPlaceSettlement (const Coordinate& location, const Player& owner);
120118 bool buySettlement (const Coordinate& location, Player& owner);
121-
119+
122120 bool canUpgradeSettlement (Coordinate location, const Player& owner) const ;
123121 bool buyUpgradeOnSettlement (Coordinate location, Player& owner);
124-
122+
125123 bool canUpgradeToWonder (Coordinate location, const Player& owner) const ;
126124 bool buyUpgradeOnWonder (Coordinate location, Player& owner);
127125
@@ -136,15 +134,15 @@ class GameBoard {
136134 bool operator ==(const GameBoard& other) const ;
137135
138136 const std::vector<std::unique_ptr<Player>>& getPlayers () const ;
139-
137+
140138 int getNoOfPlayers ();
141139 Player& getPlayer (int index);
142140
143- bool testRollChecking (int * rolls);
141+ bool testRollChecking (int * rolls);
144142
145- bool moveRobber (Coordinate newRobber);
146- Coordinate getRobber () const ;
147- bool canRobberRob (Player& opponent, Coordinate location);
143+ bool moveRobber (Coordinate newRobber);
144+ Coordinate getRobber () const ;
145+ bool canRobberRob (Player& opponent, Coordinate location);
148146
149147};
150148
0 commit comments