1
0
mirror of https://github.com/vcmi/vcmi.git synced 2024-12-24 22:14:36 +02:00

Comments save format backward compatability code as Ivan suggested

Also we should always handle RumorState::TYPE_NONE in getTavernRumor properly anyway.
This commit is contained in:
ArseniyShestakov 2015-12-06 02:51:54 +03:00
parent 05a34fb417
commit e872b400b7
4 changed files with 4 additions and 4 deletions

View File

@ -577,7 +577,7 @@ EPlayerStatus::EStatus CGameInfoCallback::getPlayerStatus(PlayerColor player, bo
std::string CGameInfoCallback::getTavernRumor(const CGObjectInstance * townOrTavern) const
{
std::string text = "", extraText = "";
if(gs->rumor.type == RumorState::TYPE_NONE) // (version < 755 backward compatability
if(gs->rumor.type == RumorState::TYPE_NONE)
return text;
auto rumor = gs->rumor.last[gs->rumor.type];

View File

@ -249,7 +249,7 @@ public:
template <typename Handler> void serialize(Handler &h, const int version)
{
h & scenarioOps & initialOpts & currentPlayer & day & map & players & teams & hpool & globalEffects & rand;
if(version >= 755)
if(version >= 755) //save format backward compatibility
{
h & rumor;
}

View File

@ -79,7 +79,7 @@ public:
template <typename Handler> void serialize(Handler &h, const int version)
{
h & patrolling;
if(version >= 755)
if(version >= 755) //save format backward compatibility
{
h & initialPos;
}

View File

@ -75,7 +75,7 @@ public:
template <typename Handler> void serialize(Handler & h, const int version)
{
h & resourceName & verticalPosition;
if(version >= 754)
if(version >= 754) //save format backward compatibility
{
h & pause;
}