Added new packet type as end of game notification. Now displaying dialogs at end of game, to start a new game. Server errors are displayed.

This commit is contained in:
lotodore
2007-06-10 23:28:25 +00:00
parent 8129880461
commit baf2c82864
20 changed files with 418 additions and 169 deletions
+7 -1
View File
@@ -568,6 +568,12 @@ ClientStateWaitHand::InternalProcess(ClientThread &client, boost::shared_ptr<Net
retVal = MSG_NET_GAME_CLIENT_HAND_START;
}
else if (packet->ToNetPacketEndOfGame())
{
client.GetCallback().SignalNetClientWaitDialog();
client.SetState(ClientStateWaitGame::Instance());
retVal = MSG_NET_GAME_CLIENT_END;
}
return MSG_SOCK_INTERNAL_PENDING;
}
@@ -831,7 +837,7 @@ ClientStateRunHand::InternalProcess(ClientThread &client, boost::shared_ptr<NetP
// Wait for next Hand.
client.SetState(ClientStateWaitHand::Instance());
retVal = MSG_NET_GAME_SERVER_HAND_END;
retVal = MSG_NET_GAME_CLIENT_HAND_END;
}
}