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

Renamed JsonNode::meta to more logical modScope. Member is now private

This commit is contained in:
Ivan Savenko
2024-02-13 14:34:16 +02:00
parent e73516b7d1
commit 922966dcf8
46 changed files with 154 additions and 148 deletions

View File

@@ -98,12 +98,12 @@ bool LuaSpellEffect::applicable(Problem & problem, const Mechanics * m, const Ef
for(const auto & dest : target)
{
JsonNode targetData;
targetData.Vector().push_back(JsonUtils::intNode(dest.hexValue.hex));
targetData.Vector().emplace_back(dest.hexValue.hex);
if(dest.unitValue)
targetData.Vector().push_back(JsonUtils::intNode(dest.unitValue->unitId()));
targetData.Vector().emplace_back(dest.unitValue->unitId());
else
targetData.Vector().push_back(JsonUtils::intNode(-1));
targetData.Vector().emplace_back(-1);
requestP.Vector().push_back(targetData);
}
@@ -141,12 +141,12 @@ void LuaSpellEffect::apply(ServerCallback * server, const Mechanics * m, const E
for(const auto & dest : target)
{
JsonNode targetData;
targetData.Vector().push_back(JsonUtils::intNode(dest.hexValue.hex));
targetData.Vector().emplace_back(dest.hexValue.hex);
if(dest.unitValue)
targetData.Vector().push_back(JsonUtils::intNode(dest.unitValue->unitId()));
targetData.Vector().emplace_back(dest.unitValue->unitId());
else
targetData.Vector().push_back(JsonUtils::intNode(-1));
targetData.Vector().emplace_back(-1);
requestP.Vector().push_back(targetData);
}