add subgroups for fishing rods to encounter json

This commit is contained in:
garak authored and huderlem committed 2019-10-14 18:12:03 -05:00
1 parent 74477471a6
commit c73e20b6af
4 files changed
+41 -30

No files matched your search

+5 -15
View File
@@ -65,21 +65,6 @@ int main(int argc, char *argv[])
return get_custom_var(key);
});
env.add_callback("trackVar", 2, [](Arguments& args) {
static int counter = 0;
int addValue = args.at(0)->get<int>();
int checkValue = args.at(1)->get<int>();
bool over = false;
counter = (counter + addValue) % (checkValue + 1);
if (counter <= addValue) over = true;
return over;
});
env.add_callback("concat", 2, [](Arguments& args) {
string first = args.at(0)->get<string>();
string second = args.at(1)->get<string>();
@@ -106,6 +91,11 @@ int main(int argc, char *argv[])
return rawValue.substr(0, i);
});
// single argument is a json object
env.add_callback("isEmpty", 1, [](Arguments& args) {
return args.at(0)->empty();
});
try
{
env.write_with_json_file(templateFilepath, jsonfilepath, outputFilepath);