summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--common/message.h38
1 files changed, 37 insertions, 1 deletions
diff --git a/common/message.h b/common/message.h
index 1574838..4390cdd 100644
--- a/common/message.h
+++ b/common/message.h
@@ -202,14 +202,50 @@ namespace Message {
public:
typedef boost::shared_ptr<RoundEnd> p;
+ struct Score {
+ std::string nick;
+ int score;
+ int won;
+
+ template<class Archive>
+ void serialize(Archive & ar, const unsigned int v) {
+ ar & nick;
+ ar & score;
+ ar & won;
+ }
+ };
+
+ struct Yaku {
+ std::string name;
+ int value;
+
+ template<class Archive>
+ void serialize(Archive & ar, const unsigned int v) {
+ ar & name;
+ ar & value;
+ }
+ };
+
RoundEnd() : Base(Types::RoundEnd) {}
+ Tiles hand;
+ std::vector<Yaku> yakus;
+ int total_han;
+ int total_fu;
+ int won;
+ Score score[4];
template<class Archive>
void serialize(Archive & ar, const unsigned int v) {
-
+ ar & hand;
+ ar & yakus;
+ ar & total_han;
+ ar & total_fu;
+ ar & won;
+ ar & score;
}
};
+
typedef boost::shared_ptr<Base> p;
};