Browse Source

Fix serialization

Ivan Savenko 2 years ago
parent
commit
c5225aab70
2 changed files with 3 additions and 1 deletions
  1. 1 1
      lib/serializer/CSerializer.h
  2. 2 0
      lib/spells/CSpellHandler.h

+ 1 - 1
lib/serializer/CSerializer.h

@@ -14,7 +14,7 @@
 
 VCMI_LIB_NAMESPACE_BEGIN
 
-const ui32 SERIALIZATION_VERSION = 820;
+const ui32 SERIALIZATION_VERSION = 821;
 const ui32 MINIMAL_SERIALIZATION_VERSION = 820;
 const std::string SAVEGAME_MAGIC = "VCMISVG";
 

+ 2 - 0
lib/spells/CSpellHandler.h

@@ -272,6 +272,8 @@ public:
 	template <typename Handler> void serialize(Handler & h, const int version)
 	{
 		h & identifier;
+		if (version > 820)
+			h & modScope;
 		h & id;
 		h & level;
 		h & power;