1
0
mirror of https://github.com/vcmi/vcmi.git synced 2024-11-28 08:48:48 +02:00

CClient::loadGame: pass correct save version for BinaryDeserializer

Fix loading crashes that appear after duel mode removal.
This commit is contained in:
Arseniy Shestakov 2017-07-03 05:11:58 +03:00
parent a1c2307f61
commit c059f95e2e

View File

@ -342,7 +342,7 @@ void CClient::loadGame(const std::string & fname, const bool server, const std::
std::cout << x << std::endl;
std::cout << "ENDCLIENTPLAYERS\n";
serialize(loader->serializer,0,clientPlayers);
serialize(loader->serializer, loader->serializer.fileVersion, clientPlayers);
*serv << ui32(clientPlayers.size());
for(auto & elem : clientPlayers)
*serv << ui8(elem.getNum());