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:
parent
05a34fb417
commit
e872b400b7
@ -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];
|
||||
|
@ -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;
|
||||
}
|
||||
|
@ -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;
|
||||
}
|
||||
|
@ -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;
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user