1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-11-23 22:37:55 +02:00

MetaString can be serialized in json

This commit is contained in:
Ivan Savenko
2023-06-18 18:59:04 +03:00
parent d51fe62804
commit a84666edf6
4 changed files with 94 additions and 10 deletions

View File

@@ -11,6 +11,7 @@
VCMI_LIB_NAMESPACE_BEGIN
class JsonNode;
class CreatureID;
class CStackBasicDescriptor;
using TQuantity = si32;
@@ -108,6 +109,9 @@ public:
/// Returns true if current string is empty
bool empty() const;
void jsonSerialize(JsonNode & dest) const;
void jsonDeserialize(const JsonNode & dest);
template <typename Handler> void serialize(Handler & h, const int version)
{
h & exactStrings;