1
0
mirror of https://github.com/vcmi/vcmi.git synced 2025-11-25 22:42:04 +02:00

* fixed bug in campaigns

* turned off artifacts.json creation
* minor changes
This commit is contained in:
mateuszb
2012-09-29 17:36:48 +00:00
parent 2001aeac92
commit 657ed41088
5 changed files with 43 additions and 34 deletions

View File

@@ -910,22 +910,22 @@ void CArtHandler::addBonuses()
ART_PRIM_SKILL (154, 0, +6); //Hardened Shield
}
JsonNode cfg;
BOOST_FOREACH(auto art, artifacts)
{
JsonNode jn;
jn["id"].Float() = art->id;
BOOST_FOREACH (auto b, art->getBonusList())
{
JsonNode bn;
UnparseBonus(bn, b);
jn["bonuses"].Vector().push_back(bn);
}
cfg.Vector().push_back(jn);
}
std::ofstream artconfigOutput("config/artifacts.json");
JsonWriter(artconfigOutput, cfg);
// JsonNode cfg;
// BOOST_FOREACH(auto art, artifacts)
// {
// JsonNode jn;
// jn["id"].Float() = art->id;
// BOOST_FOREACH (auto b, art->getBonusList())
// {
// JsonNode bn;
// UnparseBonus(bn, b);
// jn["bonuses"].Vector().push_back(bn);
// }
// cfg.Vector().push_back(jn);
// }
//
// std::ofstream artconfigOutput("config/artifacts.json");
// JsonWriter(artconfigOutput, cfg);
}
void CArtHandler::clear()