1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-06-15 00:05:02 +02:00

Added (mostly) complete schema for validation of rewardable

This commit is contained in:
Ivan Savenko
2024-08-14 13:39:40 +00:00
parent 2151a7fc88
commit 72896d4ed5
5 changed files with 298 additions and 6 deletions

View File

@ -10,6 +10,7 @@
#include "StdInc.h"
#include "CRewardableConstructor.h"
#include "../json/JsonUtils.h"
#include "../mapObjects/CRewardableObject.h"
#include "../texts/CGeneralTextHandler.h"
#include "../IGameCallback.h"
@ -23,6 +24,8 @@ void CRewardableConstructor::initTypeData(const JsonNode & config)
if (!config["name"].isNull())
VLC->generaltexth->registerString( config.getModScope(), getNameTextID(), config["name"].String());
JsonUtils::validate(config, "vcmi:rewardable", getJsonKey());
}