Skip to content

Commit

Permalink
players no longer have multiple turns, and ending turns works correctly
Browse files Browse the repository at this point in the history
  • Loading branch information
bsurmanski committed Jul 15, 2011
1 parent 10f2819 commit 359b79c
Show file tree
Hide file tree
Showing 12 changed files with 15 additions and 12 deletions.
3 changes: 3 additions & 0 deletions .hgignore
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,6 @@
\.chg\..*$
\.rej$
\.conflict\~$
^build$
^dist$
^nbproject$
4 changes: 2 additions & 2 deletions GameLibrary.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -118,7 +118,7 @@ void GameLibrary::setPlayers(std::vector<Player*>* plrs) {

void GameLibrary::setCurrentPlayer(Player* player) {
currentPlayer = player;
for (int i = 0; i < localPlayers; i++) {
for (int i = 0; i < getNumberOfPlayers(); i++) {
if (player == players->at(i)) {
currentPlayerIndex = i;
player->beginTurn();
Expand Down Expand Up @@ -160,8 +160,8 @@ void GameLibrary::nextPlayerTurn() {
if (!prev->isRemote()) {
getNetworkManager()->sendPackets("trn", getCurrentLocalPlayer()->serialize());
}
getCurrentLocalPlayer()->beginTurn();
}
getDockWidget()->updatePlayerInfo();
}

bool GameLibrary::checkLargestArmy(Player* player) {
Expand Down
2 changes: 1 addition & 1 deletion moc_GLFrame.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/****************************************************************************
** Meta object code from reading C++ file 'GLFrame.h'
**
** Created: Wed Jul 13 22:57:15 2011
** Created: Thu Jul 14 21:06:48 2011
** by: The Qt Meta Object Compiler version 62 (Qt 4.7.3)
**
** WARNING! All changes made in this file will be lost!
Expand Down
2 changes: 1 addition & 1 deletion moc_GameDockWidget.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/****************************************************************************
** Meta object code from reading C++ file 'GameDockWidget.h'
**
** Created: Wed Jul 13 22:57:09 2011
** Created: Thu Jul 14 21:06:35 2011
** by: The Qt Meta Object Compiler version 62 (Qt 4.7.3)
**
** WARNING! All changes made in this file will be lost!
Expand Down
2 changes: 1 addition & 1 deletion moc_GameWindow.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/****************************************************************************
** Meta object code from reading C++ file 'GameWindow.h'
**
** Created: Wed Jul 13 22:57:12 2011
** Created: Thu Jul 14 21:06:44 2011
** by: The Qt Meta Object Compiler version 62 (Qt 4.7.3)
**
** WARNING! All changes made in this file will be lost!
Expand Down
2 changes: 1 addition & 1 deletion moc_MainGameWindow.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/****************************************************************************
** Meta object code from reading C++ file 'MainGameWindow.h'
**
** Created: Sat Jul 9 23:21:04 2011
** Created: Thu Jul 14 21:06:38 2011
** by: The Qt Meta Object Compiler version 62 (Qt 4.7.3)
**
** WARNING! All changes made in this file will be lost!
Expand Down
2 changes: 1 addition & 1 deletion moc_MainMenu.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/****************************************************************************
** Meta object code from reading C++ file 'MainMenu.h'
**
** Created: Wed Jul 6 16:21:56 2011
** Created: Thu Jul 14 21:06:41 2011
** by: The Qt Meta Object Compiler version 62 (Qt 4.7.3)
**
** WARNING! All changes made in this file will be lost!
Expand Down
2 changes: 1 addition & 1 deletion moc_NetworkManager.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/****************************************************************************
** Meta object code from reading C++ file 'NetworkManager.h'
**
** Created: Thu Jul 14 15:07:01 2011
** Created: Thu Jul 14 21:06:40 2011
** by: The Qt Meta Object Compiler version 62 (Qt 4.7.3)
**
** WARNING! All changes made in this file will be lost!
Expand Down
2 changes: 1 addition & 1 deletion moc_SettingsMenu.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/****************************************************************************
** Meta object code from reading C++ file 'SettingsMenu.h'
**
** Created: Wed Jul 6 16:21:55 2011
** Created: Thu Jul 14 21:06:39 2011
** by: The Qt Meta Object Compiler version 62 (Qt 4.7.3)
**
** WARNING! All changes made in this file will be lost!
Expand Down
2 changes: 1 addition & 1 deletion moc_StatisticsWindow.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/****************************************************************************
** Meta object code from reading C++ file 'StatisticsWindow.h'
**
** Created: Wed Jul 6 16:22:03 2011
** Created: Thu Jul 14 21:06:47 2011
** by: The Qt Meta Object Compiler version 62 (Qt 4.7.3)
**
** WARNING! All changes made in this file will be lost!
Expand Down
2 changes: 1 addition & 1 deletion moc_TradeMenu.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/****************************************************************************
** Meta object code from reading C++ file 'TradeMenu.h'
**
** Created: Wed Jul 13 22:57:19 2011
** Created: Thu Jul 14 21:06:51 2011
** by: The Qt Meta Object Compiler version 62 (Qt 4.7.3)
**
** WARNING! All changes made in this file will be lost!
Expand Down
2 changes: 1 addition & 1 deletion moc_YearOfPlentyDialog.cpp
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
/****************************************************************************
** Meta object code from reading C++ file 'YearOfPlentyDialog.h'
**
** Created: Wed Jul 6 16:21:49 2011
** Created: Thu Jul 14 21:06:34 2011
** by: The Qt Meta Object Compiler version 62 (Qt 4.7.3)
**
** WARNING! All changes made in this file will be lost!
Expand Down

0 comments on commit 359b79c

Please sign in to comment.