Server serialization functions require client

This commit is contained in:
juanjp600
2016-09-07 17:32:20 -03:00
parent a02931054a
commit bfd8bc6b35
18 changed files with 66 additions and 55 deletions

View File

@@ -556,11 +556,11 @@ namespace Barotrauma.Networking
}
GameMain.NetLobbyScreen.UpdateSubList(GameMain.NetLobbyScreen.SubList, submarines);
GameMain.NetLobbyScreen.UpdateSubList(GameMain.NetLobbyScreen.ShuttleList.ListBox, submarines);
}
string selectSubName = inc.ReadString();
string selectSubHash = inc.ReadString();
}
string selectSubName = inc.ReadString();
string selectSubHash = inc.ReadString();
GameMain.NetLobbyScreen.TrySelectSub(selectSubName, selectSubHash, GameMain.NetLobbyScreen.SubList);
string selectShuttleName = inc.ReadString();
string selectShuttleName = inc.ReadString();
string selectShuttleHash = inc.ReadString();
GameMain.NetLobbyScreen.TrySelectSub(selectShuttleName, selectShuttleHash, GameMain.NetLobbyScreen.ShuttleList.ListBox);
}
@@ -590,7 +590,7 @@ namespace Barotrauma.Networking
outmsg.Write(GameMain.NetLobbyScreen.LastUpdateID);
outmsg.Write(lastSentChatMsgID);
ChatMessage removeMsg;
while ((removeMsg=chatMsgQueue.Find(cMsg => cMsg.ID <= lastRecvChatMsgID)) != null)
while ((removeMsg=chatMsgQueue.Find(cMsg => cMsg.NetStateID <= lastRecvChatMsgID)) != null)
{
chatMsgQueue.Remove(removeMsg);
}
@@ -598,7 +598,7 @@ namespace Barotrauma.Networking
foreach (ChatMessage cMsg in chatMsgQueue)
{
outmsg.Write((byte)ClientNetObject.CHAT_MESSAGE);
outmsg.Write(cMsg.ID);
outmsg.Write(cMsg.NetStateID);
outmsg.Write(cMsg.Text);
}
outmsg.Write((byte)ClientNetObject.END_OF_MESSAGE);