summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--server/game.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/server/game.cpp b/server/game.cpp
index 4816490..819336a 100644
--- a/server/game.cpp
+++ b/server/game.cpp
@@ -333,6 +333,7 @@ void Game::round_end(Endcondition end) {
msg[count_player]->total_han = msg[count_player]->total_fu = msg[count_player]->won = msg[count_player]->score[count_player].won = 0;
for(int i = 0; i < 4; i++) {
msg[count_player]->score[count_player + i].score = players[count_player + i].get_state().score;
+ msg[count_player]->score[count_player + i].won = 0;
}
switch(end) {
@@ -388,8 +389,13 @@ void Game::round_end(Endcondition end) {
if(current_player + i == round_num) {
msg[count_player]->won = player.won_value.ron_east();
+ msg[count_player]->score[current_player + i].won = player.won_value.ron_east();
+ msg[count_player]->score[current_player].won = -(player.won_value.ron_east());
+
} else {
msg[count_player]->won = player.won_value.ron();
+ msg[count_player]->score[current_player + i].won = player.won_value.ron();
+ msg[count_player]->score[current_player].won = -(player.won_value.ron());
}
// TODO: Support multiple wins.