From 4da10fc7fa940ef7b5f2c796c0e4a92df17f133e Mon Sep 17 00:00:00 2001 From: Mark Vejvoda Date: Wed, 5 Jun 2013 20:31:54 +0000 Subject: [PATCH] save player uuid in last game settings --- source/glest_game/global/core_data.cpp | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/source/glest_game/global/core_data.cpp b/source/glest_game/global/core_data.cpp index a7de9c11..4463f194 100644 --- a/source/glest_game/global/core_data.cpp +++ b/source/glest_game/global/core_data.cpp @@ -1012,6 +1012,8 @@ void CoreData::saveGameSettingsToFile(std::string fileName, GameSettings *gameSe saveGameFile << "FactionStartLocationForIndex" << Shared::PlatformByteOrder::toCommonEndian(slotIndex) << "=" << Shared::PlatformByteOrder::toCommonEndian(gameSettings->getStartLocationIndex(i)) << std::endl; saveGameFile << "FactionTypeNameForIndex" << Shared::PlatformByteOrder::toCommonEndian(slotIndex) << "=" << gameSettings->getFactionTypeName(i) << std::endl; saveGameFile << "FactionPlayerNameForIndex" << Shared::PlatformByteOrder::toCommonEndian(slotIndex) << "=" << gameSettings->getNetworkPlayerName(i) << std::endl; + + saveGameFile << "FactionPlayerUUIDForIndex" << Shared::PlatformByteOrder::toCommonEndian(slotIndex) << "=" << gameSettings->getNetworkPlayerUUID(i) << std::endl; } #if defined(WIN32) && !defined(__MINGW32__) @@ -1093,6 +1095,8 @@ bool CoreData::loadGameSettingsFromFile(std::string fileName, GameSettings *game else { gameSettings->setNetworkPlayerName(i,""); } + + gameSettings->setNetworkPlayerUUID(i,properties.getString(string("FactionPlayerUUIDForIndex") + intToStr(i),"") ); } if(SystemFlags::getSystemSettingType(SystemFlags::debugSystem).enabled) SystemFlags::OutputDebug(SystemFlags::debugSystem,"In [%s::%s] Line: %d\n",__FILE__,__FUNCTION__,__LINE__);