From b9942d8af0400f943b9b5bd67faf417a932750f5 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Atle=20Hellvik=20Havs=C3=B8?= Date: Sun, 21 Nov 2010 16:31:10 +0100 Subject: Server sends the players id in the game together with the GameStart message. MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Atle Hellvik Havsø --- common/message.cpp | 2 ++ common/message.h | 1 + 2 files changed, 3 insertions(+) (limited to 'common') diff --git a/common/message.cpp b/common/message.cpp index b69ddef..4f7bad3 100644 --- a/common/message.cpp +++ b/common/message.cpp @@ -116,10 +116,12 @@ Message::GameStart::GameStart() : BoostBase(Types::GameStart) { void Message::GameStart::serialize(boost::archive::text_oarchive& ar) { ar & players; + ar & player_id; } void Message::GameStart::deserialize(boost::archive::text_iarchive& ar) { ar & players; + ar & player_id; } Message::Ready::Ready() : NullBase(Types::Ready) { diff --git a/common/message.h b/common/message.h index 447d12d..584a850 100644 --- a/common/message.h +++ b/common/message.h @@ -114,6 +114,7 @@ namespace Message { GameStart(); std::vector players; + int player_id; virtual void serialize(boost::archive::text_oarchive& ar); virtual void deserialize(boost::archive::text_iarchive& ar); -- cgit v1.2.3