68 "Invalid culture " + std::string(value) +
" (" + err.
file_name +
" line " + std::to_string(line) +
")\n";
77 "Invalid religion " + std::string(value) +
" (" + err.
file_name +
" line " + std::to_string(line) +
")\n";
86 "Invalid ideology " + std::string(value) +
" (" + err.
file_name +
" line " + std::to_string(line) +
")\n";
92 type_ = it->second.id;
95 "Invalid rebel type " + std::string(value) +
" (" + err.
file_name +
" line " + std::to_string(line) +
")\n";
120 "Invalid modifier " + std::string(value) +
" (" + err.
file_name +
" line " + std::to_string(line) +
")\n";
134 "Invalid modifier " + std::string(value) +
" (" + err.
file_name +
" line " + std::to_string(line) +
")\n";
146 type_ = it->second.id;
149 "Invalid cb type " + std::string(value) +
" (" + err.
file_name +
" line " + std::to_string(line) +
")\n";
161 type_ = it->second.id;
164 "Invalid cb type " + std::string(value) +
" (" + err.
file_name +
" line " + std::to_string(line) +
")\n";
175 type_ = it->second.id;
178 "Invalid cb type " + std::string(value) +
" (" + err.
file_name +
" line " + std::to_string(line) +
")\n";
189 type_ = it->second.id;
192 "Invalid cb type " + std::string(value) +
" (" + err.
file_name +
" line " + std::to_string(line) +
")\n";
211 }
else if(value.length() == 3) {
225 if(
is_fixed_token_ci(value.data(), value.data() + value.length(),
"test_end_war")) {
227 }
else if(
is_fixed_token_ci(value.data(), value.data() + value.length(),
"call_allies_cb")) {
234 "Invalid cb type " + std::string(value) +
" (" + err.
file_name +
" line " + std::to_string(line) +
")\n";
242 "wargoal given an invalid province id (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
256 dcon::national_event_id
id_;
262 dcon::provincial_event_id
id_;
275 "Invalid unit type " + std::string(v) +
" (" + err.
file_name +
" line " + std::to_string(line) +
")\n";
305 "Invalid ideology " + std::string(v) +
" (" + err.
file_name +
" line " + std::to_string(line) +
")\n";
318 "Invalid issue option " + std::string(v) +
" (" + err.
file_name +
" line " + std::to_string(line) +
")\n";
332 "Invalid ideology " + std::string(v) +
" (" + err.
file_name +
" line " + std::to_string(line) +
")\n";
348 "Invalid ideology " + std::string(v) +
" (" + err.
file_name +
" line " + std::to_string(line) +
")\n";
356 "Invalid issue option " + std::string(v) +
" (" + err.
file_name +
" line " + std::to_string(line) +
")\n";
372 "Invalid ideology " + std::string(v) +
" (" + err.
file_name +
" line " + std::to_string(line) +
")\n";
380 "Invalid issue option " + std::string(v) +
" (" + err.
file_name +
" line " + std::to_string(line) +
")\n";
395 "Invalid leader trait " + std::string(v) +
" (" + err.
file_name +
" line " + std::to_string(line) +
")\n";
404 "Invalid leader trait " + std::string(v) +
" (" + err.
file_name +
" line " + std::to_string(line) +
")\n";
419 "Invalid leader trait " + std::string(v) +
" (" + err.
file_name +
" line " + std::to_string(line) +
")\n";
428 "Invalid leader trait " + std::string(v) +
" (" + err.
file_name +
" line " + std::to_string(line) +
")\n";
440 "Invalid cb type " + std::string(v) +
" (" + err.
file_name +
" line " + std::to_string(line) +
")\n";
448 dcon::issue_option_id
to_;
451 from_ = it->second.id;
454 "Invalid issue option " + std::string(v) +
" (" + err.
file_name +
" line " + std::to_string(line) +
")\n";
462 "Invalid issue option " + std::string(v) +
" (" + err.
file_name +
" line " + std::to_string(line) +
")\n";
477 "Invalid ideology " + std::string(v) +
" (" + err.
file_name +
" line " + std::to_string(line) +
")\n";
485 "party_loyalty given an invalid province id (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
534 "capital effect given an invalid province id (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
539 if(
is_integer(value.data(), value.data() + value.length())) {
542 auto ivalue =
parse_int(value, line, err);
547 "add_core = int effect given an invalid province id (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
562 std::to_string(line) +
")\n";
572 std::to_string(line) +
")\n";
586 std::to_string(line) +
")\n";
589 }
else if(value.length() == 3) {
596 "add_core effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
601 "add_core effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
610 std::to_string(line) +
")\n";
620 std::to_string(line) +
")\n";
634 std::to_string(line) +
")\n";
637 }
else if(value.length() == 3) {
640 context.
compiled_effect.push_back(uint16_t(effect::add_core_tag_state));
644 "add_core effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
649 "add_core effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
661 if(
is_integer(value.data(), value.data() + value.length())) {
664 auto ivalue =
parse_int(value, line, err);
669 std::to_string(line) +
")\n";
674 std::to_string(line) +
")\n";
684 std::to_string(line) +
")\n";
694 std::to_string(line) +
")\n";
708 std::to_string(line) +
")\n";
711 }
else if(value.length() == 3) {
718 "remove_core effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
723 "remove_core effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
732 std::to_string(line) +
")\n";
742 std::to_string(line) +
")\n";
756 std::to_string(line) +
")\n";
759 }
else if(value.length() == 3) {
762 context.
compiled_effect.push_back(uint16_t(effect::remove_core_tag_state));
766 "remove_core effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
771 "remove_core effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
780 std::to_string(line) +
")\n";
790 std::to_string(line) +
")\n";
804 std::to_string(line) +
")\n";
807 }
else if(value.length() == 3) {
810 context.
compiled_effect.push_back(uint16_t(effect::remove_core_tag_nation));
814 "remove_core effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
819 "remove_core effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
843 err.
accumulated_errors +=
"trade_goods effect supplied with invalid commodity name " + std::string(value) +
" (" +
844 err.
file_name +
", line " + std::to_string(line) +
")\n";
853 }
else if(
is_fixed_token_ci(value.data(), value.data() + value.length(),
"this_union")) {
855 }
else if(
is_fixed_token_ci(value.data(), value.data() + value.length(),
"from_union")) {
863 context.
compiled_effect.push_back(uint16_t(effect::add_accepted_culture));
866 err.
accumulated_errors +=
"add_accepted_culture effect supplied with invalid culture name " + std::string(value) +
" (" +
867 err.
file_name +
", line " + std::to_string(line) +
")\n";
872 std::to_string(line) +
")\n";
884 ", line " + std::to_string(line) +
")\n";
898 ", line " + std::to_string(line) +
")\n";
907 err.
accumulated_errors +=
"primary_culture effect supplied with invalid culture name " + std::string(value) +
" (" +
908 err.
file_name +
", line " + std::to_string(line) +
")\n";
922 context.
compiled_effect.push_back(uint16_t(effect::remove_accepted_culture));
925 err.
accumulated_errors +=
"remove_accepted_culture effect supplied with invalid culture name " + std::string(value) +
926 " (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
931 std::to_string(line) +
")\n";
942 err.
accumulated_errors +=
"remove_accepted_culture effect supplied with invalid culture name " + std::string(value) +
943 " (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
957 context.
compiled_effect.push_back(uint16_t(effect::life_rating_state));
972 err.
accumulated_errors +=
"religion effect supplied with invalid religion name " + std::string(value) +
" (" +
973 err.
file_name +
", line " + std::to_string(line) +
")\n";
980 context.
compiled_effect.push_back(uint16_t(effect::religion_province));
983 err.
accumulated_errors +=
"religion effect supplied with invalid religion name " + std::string(value) +
" (" +
984 err.
file_name +
", line " + std::to_string(line) +
")\n";
994 err.
accumulated_errors +=
"religion effect supplied with invalid religion name " + std::string(value) +
" (" +
995 err.
file_name +
", line " + std::to_string(line) +
")\n";
1045 err.
accumulated_errors +=
"tech_school effect supplied with invalid modifier name " + std::string(value) +
" (" +
1046 err.
file_name +
", line " + std::to_string(line) +
")\n";
1063 std::to_string(line) +
")\n";
1071 err.
accumulated_errors +=
"government effect supplied with invalid government name " + std::string(value) +
" (" +
1072 err.
file_name +
", line " + std::to_string(line) +
")\n";
1086 context.
compiled_effect.push_back(uint16_t(effect::treasury_province));
1119 }
else if(value.length() == 3) {
1126 "change_tag effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1131 "change_tag effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1146 }
else if(value.length() == 3) {
1149 context.
compiled_effect.push_back(uint16_t(effect::change_tag_no_core_switch));
1153 std::to_string(line) +
")\n";
1158 "change_tag_no_core_switch effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1164 std::to_string(line) +
")\n";
1171 context.
compiled_effect.push_back(uint16_t(effect::set_country_flag));
1174 context.
compiled_effect.push_back(uint16_t(effect::set_country_flag_province));
1177 context.
compiled_effect.push_back(uint16_t(effect::set_country_flag_pop));
1188 context.
compiled_effect.push_back(uint16_t(effect::clr_country_flag));
1208 ", line " + std::to_string(line) +
")\n";
1218 ", line " + std::to_string(line) +
")\n";
1221 }
else if(value.length() == 3) {
1228 "military_access effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1233 "military_access effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1278 }
else if(
is_reb(value)) {
1285 }
else if(
is_fixed_token_ci(value.data(), value.data() + value.length(),
"---")) {
1288 }
else if(value.length() == 3) {
1295 err.
accumulated_warnings +=
"secede_province effect given an invalid tag '" + std::string(value) +
"' will assume null (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1298 }
else if(
is_fixed_token_ci(value.data(), value.data() + value.length(),
"null")) {
1302 err.
accumulated_errors +=
"secede_province effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1328 }
else if(
is_reb(value)) {
1335 }
else if(value.length() == 3) {
1338 context.
compiled_effect.push_back(uint16_t(effect::secede_province_state));
1341 err.
accumulated_errors +=
"secede_province effect given an invalid tag '" + std::string(value) +
"' (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1345 err.
accumulated_errors +=
"secede_province effect given an invalid value '" + std::string(value) +
"' (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1366 std::to_string(line) +
")\n";
1376 std::to_string(line) +
")\n";
1379 }
else if(value.length() == 3) {
1386 "inherit effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1391 "inherit effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1414 std::to_string(line) +
")\n";
1424 std::to_string(line) +
")\n";
1427 }
else if(value.length() == 3) {
1434 "annex_to effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1437 }
else if(
is_fixed_token_ci(value.data(), value.data() + value.length(),
"null")) {
1442 "annex_to effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1451 std::to_string(line) +
")\n";
1473 std::to_string(line) +
")\n";
1483 std::to_string(line) +
")\n";
1486 }
else if(value.length() == 3) {
1493 "release effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1498 "release effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1518 ", line " + std::to_string(line) +
")\n";
1528 ", line " + std::to_string(line) +
")\n";
1531 }
else if(value.length() == 3) {
1534 context.
compiled_effect.push_back(uint16_t(effect::change_controller));
1538 "change_controller effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1543 "change_controller effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1554 ", line " + std::to_string(line) +
")\n";
1564 ", line " + std::to_string(line) +
")\n";
1567 }
else if(value.length() == 3) {
1570 context.
compiled_effect.push_back(uint16_t(effect::change_controller_state));
1574 "change_controller effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1579 "change_controller effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1593 context.
compiled_effect.push_back(uint16_t(effect::infrastructure_state));
1619 context.
compiled_effect.push_back(uint16_t(effect::naval_base_state));
1645 context.
compiled_effect.push_back(uint16_t(effect::university_state));
1656 context.
compiled_effect.push_back(uint16_t(effect::add_province_modifier_no_duration));
1658 }
else if(value == -1) {
1659 context.
compiled_effect.push_back(uint16_t(effect::remove_province_modifier));
1663 "province_selector effect with invalid value " + std::to_string(value) +
" (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1674 context.
compiled_effect.push_back(uint16_t(effect::add_province_modifier_no_duration));
1676 }
else if(value == -1) {
1677 context.
compiled_effect.push_back(uint16_t(effect::remove_province_modifier));
1681 "province_immigrator effect with invalid value " + std::to_string(value) +
" (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1694 context.
compiled_effect.push_back(uint16_t(effect::treasury_province));
1725 std::to_string(line) +
")\n";
1735 std::to_string(line) +
")\n";
1738 }
else if(value.length() == 3) {
1745 "create_vassal effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1750 "create_vassal effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1770 ", line " + std::to_string(line) +
")\n";
1780 ", line " + std::to_string(line) +
")\n";
1783 }
else if(value.length() == 3) {
1786 context.
compiled_effect.push_back(uint16_t(effect::end_military_access));
1790 "end_military_access effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1795 "end_military_access effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1801 std::to_string(line) +
")\n";
1815 std::to_string(line) +
")\n";
1825 std::to_string(line) +
")\n";
1828 }
else if(value.length() == 3) {
1835 "leave_alliance effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1840 "leave_alliance effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1846 std::to_string(line) +
")\n";
1859 std::to_string(line) +
")\n";
1869 std::to_string(line) +
")\n";
1872 }
else if(value.length() == 3) {
1879 "end_war effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1884 "end_war effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1901 err.
accumulated_errors +=
"enable_ideology effect supplied with invalid ideology name " + std::string(value) +
" (" +
1902 err.
file_name +
", line " + std::to_string(line) +
")\n";
1910 context.
compiled_effect.push_back(uint16_t(effect::ruling_party_this));
1912 context.
compiled_effect.push_back(uint16_t(effect::ruling_party_from));
1915 context.
compiled_effect.push_back(uint16_t(effect::ruling_party_ideology));
1918 err.
accumulated_errors +=
"ruling_party_ideology effect supplied with invalid ideology name " + std::string(value) +
1919 " (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1924 std::to_string(line) +
")\n";
1943 context.
compiled_effect.push_back(uint16_t(effect::remove_province_modifier));
1946 err.
accumulated_errors +=
"remove_province_modifier effect supplied with invalid modifier name " + std::string(value) +
1947 " (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1953 context.
compiled_effect.push_back(uint16_t(effect::remove_province_modifier_state));
1956 err.
accumulated_errors +=
"remove_province_modifier effect supplied with invalid modifier name " + std::string(value) +
1957 " (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1962 std::to_string(line) +
")\n";
1971 context.
compiled_effect.push_back(uint16_t(effect::remove_country_modifier));
1974 err.
accumulated_errors +=
"remove_country_modifier effect supplied with invalid modifier name " + std::string(value) +
1975 " (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
1980 std::to_string(line) +
")\n";
1994 ", line " + std::to_string(line) +
")\n";
2004 ", line " + std::to_string(line) +
")\n";
2007 }
else if(value.length() == 3) {
2014 "create_alliance effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
2019 "create_alliance effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
2038 std::to_string(line) +
")\n";
2048 std::to_string(line) +
")\n";
2051 }
else if(
is_reb(value)) {
2056 std::to_string(line) +
")\n";
2059 }
else if(
is_fixed_token_ci(value.data(), value.data() + value.length(),
"random")) {
2061 }
else if(value.length() == 3) {
2067 err.
accumulated_errors +=
"release_vassal effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
2071 err.
accumulated_errors +=
"release_vassal effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
2082 std::to_string(line) +
")\n";
2092 std::to_string(line) +
")\n";
2095 }
else if(
is_reb(value)) {
2100 std::to_string(line) +
")\n";
2103 }
else if(
is_fixed_token_ci(value.data(), value.data() + value.length(),
"random")) {
2105 }
else if(value.length() == 3) {
2108 context.
compiled_effect.push_back(uint16_t(effect::release_vassal_province));
2111 err.
accumulated_errors +=
"release_vassal effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
2115 err.
accumulated_errors +=
"release_vassal effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
2140 context.
compiled_effect.push_back(uint16_t(effect::nationalvalue_nation));
2143 context.
compiled_effect.push_back(uint16_t(effect::nationalvalue_province));
2151 err.
accumulated_errors +=
"nationalvalue effect supplied with invalid modifier name " + std::string(value) +
" (" +
2152 err.
file_name +
", line " + std::to_string(line) +
")\n";
2185 context.
compiled_effect.push_back(uint16_t(effect::social_reform_province));
2193 err.
accumulated_errors +=
"social_reform effect supplied with invalid issue option name " + std::string(value) +
" (" +
2194 err.
file_name +
", line " + std::to_string(line) +
")\n";
2203 context.
compiled_effect.push_back(uint16_t(effect::political_reform));
2206 context.
compiled_effect.push_back(uint16_t(effect::political_reform_province));
2210 std::to_string(line) +
")\n";
2214 err.
accumulated_errors +=
"political_reform effect supplied with invalid issue option name " + std::string(value) +
" (" +
2215 err.
file_name +
", line " + std::to_string(line) +
")\n";
2222 context.
compiled_effect.push_back(uint16_t(effect::add_tax_relative_income));
2226 std::to_string(line) +
")\n";
2243 "reduce_pop effect with a negative value (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
2245 value = std::max(0.0f, value);
2250 context.
compiled_effect.push_back(uint16_t(effect::reduce_pop_nation));
2253 context.
compiled_effect.push_back(uint16_t(effect::reduce_pop_province));
2256 context.
compiled_effect.push_back(uint16_t(effect::reduce_pop_state));
2281 "move_pop effect given an invalid province id (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
2303 ", line " + std::to_string(line) +
")\n";
2309 context.
compiled_effect.push_back(uint16_t(effect::years_of_research));
2320 context.
compiled_effect.push_back(uint16_t(effect::prestige_factor_positive));
2322 context.
compiled_effect.push_back(uint16_t(effect::prestige_factor_negative));
2343 err.
accumulated_errors +=
"military_reform effect supplied with invalid issue option name " + std::string(value) +
" (" +
2344 err.
file_name +
", line " + std::to_string(line) +
")\n";
2361 err.
accumulated_errors +=
"economic_reform effect supplied with invalid issue option name " + std::string(value) +
" (" +
2362 err.
file_name +
", line " + std::to_string(line) +
")\n";
2369 context.
compiled_effect.push_back(uint16_t(effect::remove_random_military_reforms));
2373 ", line " + std::to_string(line) +
")\n";
2380 context.
compiled_effect.push_back(uint16_t(effect::remove_random_economic_reforms));
2384 ", line " + std::to_string(line) +
")\n";
2398 }
else if(
is_fixed_token_ci(value.data(), value.data() + value.length(),
"none")) {
2401 err.
accumulated_errors +=
"add_crime effect supplied with invalid modifier name " + std::string(value) +
" (" +
2402 err.
file_name +
", line " + std::to_string(line) +
")\n";
2421 context.
compiled_effect.push_back(uint16_t(effect::build_factory_in_capital_state));
2425 ", line " + std::to_string(line) +
")\n";
2429 err.
accumulated_errors +=
"build_factory_in_capital_state effect supplied with invalid factory name " + std::string(value) +
2430 " (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
2439 context.
compiled_effect.push_back(uint16_t(effect::activate_technology));
2443 std::to_string(line) +
")\n";
2449 context.
compiled_effect.push_back(uint16_t(effect::activate_invention));
2453 std::to_string(line) +
")\n";
2457 err.
accumulated_errors +=
"activate_technology effect supplied with invalid technology/invention name " +
2458 std::string(value) +
" (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
2504 std::to_string(line) +
")\n";
2510 context.
compiled_effect.push_back(uint16_t(effect::flashpoint_tension));
2513 context.
compiled_effect.push_back(uint16_t(effect::flashpoint_tension_province));
2517 std::to_string(line) +
")\n";
2523 context.
compiled_effect.push_back(uint16_t(effect::add_crisis_temperature));
2531 context.
compiled_effect.push_back(uint16_t(effect::consciousness_province));
2534 context.
compiled_effect.push_back(uint16_t(effect::consciousness_state));
2537 context.
compiled_effect.push_back(uint16_t(effect::consciousness_nation));
2550 context.
compiled_effect.push_back(uint16_t(effect::militancy_province));
2556 context.
compiled_effect.push_back(uint16_t(effect::militancy_nation));
2579 context.
compiled_effect.push_back(uint16_t(effect::add_province_modifier_no_duration));
2582 err.
accumulated_errors +=
"add_province_modifier effect supplied with invalid modifier name " + std::string(value) +
2583 " (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
2589 context.
compiled_effect.push_back(uint16_t(effect::add_province_modifier_state_no_duration));
2592 err.
accumulated_errors +=
"add_province_modifier effect supplied with invalid modifier name " + std::string(value) +
2593 " (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
2598 std::to_string(line) +
")\n";
2607 context.
compiled_effect.push_back(uint16_t(effect::add_country_modifier_no_duration));
2610 err.
accumulated_errors +=
"add_country_modifier effect supplied with invalid modifier name " + std::string(value) +
" (" +
2611 err.
file_name +
", line " + std::to_string(line) +
")\n";
2616 std::to_string(line) +
")\n";
2623 "trigger_revolt must have a valid rebel type (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
2646 std::to_string(line) +
")\n";
2657 context.
compiled_effect.push_back(effect::diplomatic_influence_from_nation);
2665 context.
compiled_effect.push_back(effect::diplomatic_influence_from_province);
2668 ", line " + std::to_string(line) +
")\n";
2672 }
else if(
is_this(value.who)) {
2680 context.
compiled_effect.push_back(effect::diplomatic_influence_this_nation);
2688 context.
compiled_effect.push_back(effect::diplomatic_influence_this_province);
2691 ", line " + std::to_string(line) +
")\n";
2695 }
else if(value.who.length() == 3) {
2707 context.
compiled_effect.push_back(uint16_t(effect::diplomatic_influence));
2712 "diplomatic_influence effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
2717 "diplomatic_influence effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
2730 std::to_string(line) +
")\n";
2734 }
else if(
is_this(value.who)) {
2741 std::to_string(line) +
")\n";
2745 }
else if(
is_reb(value.who)) {
2750 std::to_string(line) +
")\n";
2754 }
else if(value.who.length() == 3) {
2762 "relation effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
2767 "relation effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
2773 context.
compiled_effect.push_back(effect::relation_province_from_nation);
2775 context.
compiled_effect.push_back(effect::relation_province_from_province);
2778 std::to_string(line) +
")\n";
2782 }
else if(
is_this(value.who)) {
2784 context.
compiled_effect.push_back(effect::relation_province_this_nation);
2786 context.
compiled_effect.push_back(effect::relation_province_this_province);
2789 std::to_string(line) +
")\n";
2793 }
else if(
is_reb(value.who)) {
2798 std::to_string(line) +
")\n";
2802 }
else if(value.who.length() == 3) {
2805 context.
compiled_effect.push_back(uint16_t(effect::relation_province));
2810 "relation effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
2815 "relation effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
2827 if(value.duration <= 0) {
2828 context.
compiled_effect.push_back(effect::add_province_modifier_no_duration);
2836 if(value.duration <= 0) {
2837 context.
compiled_effect.push_back(effect::add_province_modifier_state_no_duration);
2840 context.
compiled_effect.push_back(effect::add_province_modifier_state);
2852 if(value.duration <= 0) {
2853 context.
compiled_effect.push_back(effect::add_country_modifier_province_no_duration);
2856 context.
compiled_effect.push_back(effect::add_country_modifier_province);
2861 if(value.duration <= 0) {
2862 context.
compiled_effect.push_back(effect::add_country_modifier_no_duration);
2871 std::to_string(line) +
")\n";
2888 std::to_string(line) +
")\n";
2893 }
else if(
is_this(value.target)) {
2904 std::to_string(line) +
")\n";
2909 }
else if(
is_integer(value.target.data(), value.target.data() + value.target.length())) {
2910 auto ivalue =
parse_int(value.target, line, err);
2918 "casus_belli effect given an invalid province id (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
2921 }
else if(value.target.length() == 3) {
2931 "casus_belli effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
2936 "casus_belli effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
2948 context.
compiled_effect.push_back(effect::add_casus_belli_from_nation);
2950 context.
compiled_effect.push_back(effect::add_casus_belli_from_province);
2953 std::to_string(line) +
")\n";
2958 }
else if(
is_this(value.target)) {
2960 context.
compiled_effect.push_back(effect::add_casus_belli_this_nation);
2962 context.
compiled_effect.push_back(effect::add_casus_belli_this_province);
2964 context.
compiled_effect.push_back(effect::add_casus_belli_this_state);
2969 std::to_string(line) +
")\n";
2974 }
else if(
is_integer(value.target.data(), value.target.data() + value.target.length())) {
2975 auto ivalue =
parse_int(value.target, line, err);
2983 "add_casus_belli effect given an invalid province id (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
2986 }
else if(value.target.length() == 3) {
2990 context.
compiled_effect.push_back(uint16_t(effect::add_casus_belli_tag));
2996 "add_casus_belli effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
3001 "add_casus_belli effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
3009 std::to_string(line) +
")\n";
3014 context.
compiled_effect.push_back(effect::remove_casus_belli_from_nation);
3016 context.
compiled_effect.push_back(effect::remove_casus_belli_from_province);
3019 ", line " + std::to_string(line) +
")\n";
3023 }
else if(
is_this(value.target)) {
3025 context.
compiled_effect.push_back(effect::remove_casus_belli_this_nation);
3027 context.
compiled_effect.push_back(effect::remove_casus_belli_this_province);
3029 context.
compiled_effect.push_back(effect::remove_casus_belli_this_state);
3031 context.
compiled_effect.push_back(effect::remove_casus_belli_this_pop);
3034 ", line " + std::to_string(line) +
")\n";
3038 }
else if(
is_integer(value.target.data(), value.target.data() + value.target.length())) {
3039 auto ivalue =
parse_int(value.target, line, err);
3046 "remove_casus_belli effect given an invalid province id (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
3049 }
else if(value.target.length() == 3) {
3053 context.
compiled_effect.push_back(uint16_t(effect::remove_casus_belli_tag));
3058 "remove_casus_belli effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
3063 "remove_casus_belli effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
3071 std::to_string(line) +
")\n";
3076 context.
compiled_effect.push_back(effect::this_remove_casus_belli_from_nation);
3078 context.
compiled_effect.push_back(effect::this_remove_casus_belli_from_province);
3081 ", line " + std::to_string(line) +
")\n";
3085 }
else if(
is_this(value.target)) {
3087 context.
compiled_effect.push_back(effect::this_remove_casus_belli_this_nation);
3089 context.
compiled_effect.push_back(effect::this_remove_casus_belli_this_province);
3091 context.
compiled_effect.push_back(effect::this_remove_casus_belli_this_state);
3093 context.
compiled_effect.push_back(effect::this_remove_casus_belli_this_pop);
3096 ", line " + std::to_string(line) +
")\n";
3100 }
else if(
is_integer(value.target.data(), value.target.data() + value.target.length())) {
3101 auto ivalue =
parse_int(value.target, line, err);
3103 context.
compiled_effect.push_back(effect::this_remove_casus_belli_int);
3108 std::to_string(line) +
")\n";
3111 }
else if(value.target.length() == 3) {
3115 context.
compiled_effect.push_back(uint16_t(effect::this_remove_casus_belli_tag));
3120 "this_remove_casus_belli effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
3125 "this_remove_casus_belli effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
3135 if(value.attacker_goal.special_end_wargoal) {
3146 }
else if(
is_this(value.target)) {
3160 }
else if(value.target.length() == 3) {
3168 "war = effect (used to create a truce) given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
3173 "war = effect (used to create a truce) given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
3178 }
else if(value.attacker_goal.special_call_ally_wargoal) {
3184 context.
compiled_effect.push_back(value.call_ally ? effect::war_from_nation : effect::war_no_ally_from_nation);
3186 context.
compiled_effect.push_back(value.call_ally ? effect::war_from_province : effect::war_no_ally_from_province);
3192 }
else if(
is_this(value.target)) {
3194 context.
compiled_effect.push_back(value.call_ally ? effect::war_this_nation : effect::war_no_ally_this_nation);
3196 context.
compiled_effect.push_back(value.call_ally ? effect::war_this_province : effect::war_no_ally_this_province);
3198 context.
compiled_effect.push_back(value.call_ally ? effect::war_this_state : effect::war_no_ally_this_state);
3200 context.
compiled_effect.push_back(value.call_ally ? effect::war_this_pop : effect::war_no_ally_this_pop);
3206 }
else if(value.target.length() == 3) {
3210 context.
compiled_effect.push_back(uint16_t(value.call_ally ? effect::war_tag : effect::war_no_ally_tag));
3214 "war = effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
3217 }
else if(value.target.length() == 0) {
3221 "war = effect given an invalid tag (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
3233 if(value.days <= 0) {
3235 context.
compiled_effect.push_back(uint16_t(effect::country_event_immediate_this_nation));
3237 context.
compiled_effect.push_back(uint16_t(effect::country_event_immediate_this_province));
3239 context.
compiled_effect.push_back(uint16_t(effect::country_event_immediate_this_state));
3241 context.
compiled_effect.push_back(uint16_t(effect::country_event_immediate_this_pop));
3250 context.
compiled_effect.push_back(uint16_t(effect::country_event_this_nation));
3252 context.
compiled_effect.push_back(uint16_t(effect::country_event_this_province));
3254 context.
compiled_effect.push_back(uint16_t(effect::country_event_this_state));
3256 context.
compiled_effect.push_back(uint16_t(effect::country_event_this_pop));
3266 if(value.days <= 0) {
3268 context.
compiled_effect.push_back(uint16_t(effect::country_event_immediate_province_this_nation));
3270 context.
compiled_effect.push_back(uint16_t(effect::country_event_immediate_province_this_province));
3272 context.
compiled_effect.push_back(uint16_t(effect::country_event_immediate_province_this_state));
3274 context.
compiled_effect.push_back(uint16_t(effect::country_event_immediate_province_this_pop));
3283 context.
compiled_effect.push_back(uint16_t(effect::country_event_province_this_nation));
3285 context.
compiled_effect.push_back(uint16_t(effect::country_event_province_this_province));
3287 context.
compiled_effect.push_back(uint16_t(effect::country_event_province_this_state));
3289 context.
compiled_effect.push_back(uint16_t(effect::country_event_province_this_pop));
3306 if(value.days <= 0) {
3308 context.
compiled_effect.push_back(uint16_t(effect::province_event_immediate_this_nation));
3310 context.
compiled_effect.push_back(uint16_t(effect::province_event_immediate_this_province));
3312 context.
compiled_effect.push_back(uint16_t(effect::province_event_immediate_this_state));
3314 context.
compiled_effect.push_back(uint16_t(effect::province_event_immediate_this_pop));
3317 std::to_string(line) +
")\n";
3323 context.
compiled_effect.push_back(uint16_t(effect::province_event_this_nation));
3325 context.
compiled_effect.push_back(uint16_t(effect::province_event_this_province));
3327 context.
compiled_effect.push_back(uint16_t(effect::province_event_this_state));
3329 context.
compiled_effect.push_back(uint16_t(effect::province_event_this_pop));
3332 std::to_string(line) +
")\n";
3354 }
else if(
is_from(value.value)) {
3362 }
else if(
is_fixed_token_ci(value.value.data(), value.value.data() + value.value.length(),
"current")) {
3371 auto ivalue =
parse_int(value.value, line, err);
3379 "sub_unit effect given an invalid province id (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
3441 context.
compiled_effect.push_back(uint16_t(effect::change_terrain_pop));
3443 context.
compiled_effect.push_back(uint16_t(effect::change_terrain_province));
3450 err.
accumulated_errors +=
"chenge_terrain effect supplied with an invalid terrain \"" + std::string(value) +
"\" (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
3456 context.
compiled_effect.push_back(uint16_t(effect::masquerade_as_nation_this));
3458 context.
compiled_effect.push_back(uint16_t(effect::masquerade_as_nation_from));
3464 err.
accumulated_errors +=
"masquerade_as_nation effect not used in a nation scope (" + err.
file_name +
", line " + std::to_string(line) +
")\n";
3504 if(
bool(value.ideology_)) {
3508 }
else if(
bool(value.issue_)) {
3513 context.
compiled_effect.push_back(effect::scaled_militancy_unemployment);
3517 if(
bool(value.ideology_)) {
3518 context.
compiled_effect.push_back(effect::scaled_militancy_nation_ideology);
3521 }
else if(
bool(value.issue_)) {
3522 context.
compiled_effect.push_back(effect::scaled_militancy_nation_issue);
3526 context.
compiled_effect.push_back(effect::scaled_militancy_nation_unemployment);
3530 if(
bool(value.ideology_)) {
3531 context.
compiled_effect.push_back(effect::scaled_militancy_state_ideology);
3534 }
else if(
bool(value.issue_)) {
3535 context.
compiled_effect.push_back(effect::scaled_militancy_state_issue);
3539 context.
compiled_effect.push_back(effect::scaled_militancy_state_unemployment);
3543 if(
bool(value.ideology_)) {
3544 context.
compiled_effect.push_back(effect::scaled_militancy_province_ideology);
3547 }
else if(
bool(value.issue_)) {
3548 context.
compiled_effect.push_back(effect::scaled_militancy_province_issue);
3552 context.
compiled_effect.push_back(effect::scaled_militancy_province_unemployment);
3563 if(
bool(value.ideology_)) {
3564 context.
compiled_effect.push_back(effect::scaled_consciousness_ideology);
3567 }
else if(
bool(value.issue_)) {
3568 context.
compiled_effect.push_back(effect::scaled_consciousness_issue);
3572 context.
compiled_effect.push_back(effect::scaled_consciousness_unemployment);
3576 if(
bool(value.ideology_)) {
3577 context.
compiled_effect.push_back(effect::scaled_consciousness_nation_ideology);
3580 }
else if(
bool(value.issue_)) {
3581 context.
compiled_effect.push_back(effect::scaled_consciousness_nation_issue);
3585 context.
compiled_effect.push_back(effect::scaled_consciousness_nation_unemployment);
3589 if(
bool(value.ideology_)) {
3590 context.
compiled_effect.push_back(effect::scaled_consciousness_state_ideology);
3593 }
else if(
bool(value.issue_)) {
3594 context.
compiled_effect.push_back(effect::scaled_consciousness_state_issue);
3598 context.
compiled_effect.push_back(effect::scaled_consciousness_state_unemployment);
3602 if(
bool(value.ideology_)) {
3603 context.
compiled_effect.push_back(effect::scaled_consciousness_province_ideology);
3606 }
else if(
bool(value.issue_)) {
3607 context.
compiled_effect.push_back(effect::scaled_consciousness_province_issue);
3611 context.
compiled_effect.push_back(effect::scaled_consciousness_province_unemployment);
3616 std::to_string(line) +
")\n";
3635 context.
compiled_effect.push_back(effect::move_issue_percentage_nation);
3637 context.
compiled_effect.push_back(effect::move_issue_percentage_state);
3639 context.
compiled_effect.push_back(effect::move_issue_percentage_province);
3644 std::to_string(line) +
")\n";
3652 if(
bool(value.province_id_)) {
3671 std::to_string(line) +
")\n";
3674 if(value.in_whole_capital_state && value.limit_to_world_greatest_level)
3676 uint16_t(effect::build_railway_in_capital_yes_whole_state_yes_limit |
effect::no_payload));
3677 else if(value.in_whole_capital_state && !value.limit_to_world_greatest_level)
3679 else if(!value.in_whole_capital_state && value.limit_to_world_greatest_level)
3688 std::to_string(line) +
")\n";
3691 if(value.in_whole_capital_state && value.limit_to_world_greatest_level)
3693 uint16_t(effect::build_bank_in_capital_yes_whole_state_yes_limit |
effect::no_payload));
3694 else if(value.in_whole_capital_state && !value.limit_to_world_greatest_level)
3696 else if(!value.in_whole_capital_state && value.limit_to_world_greatest_level)
3705 std::to_string(line) +
")\n";
3708 if(value.in_whole_capital_state && value.limit_to_world_greatest_level)
3710 uint16_t(effect::build_university_in_capital_yes_whole_state_yes_limit |
effect::no_payload));
3711 else if(value.in_whole_capital_state && !value.limit_to_world_greatest_level)
3713 else if(!value.in_whole_capital_state && value.limit_to_world_greatest_level)
3722 std::to_string(line) +
")\n";
3725 if(value.in_whole_capital_state && value.limit_to_world_greatest_level)
3727 else if(value.in_whole_capital_state && !value.limit_to_world_greatest_level)
3729 else if(!value.in_whole_capital_state && value.limit_to_world_greatest_level)
3744void ef_random_by_modifier(token_generator& gen, error_handler& err, effect_building_context& context);
3755dcon::value_modifier_key
make_option_ai_chance(token_generator& gen, error_handler& err, effect_building_context& context);
3757dcon::trigger_key
ef_limit(token_generator& gen, error_handler& err, effect_building_context& context);
3759void ef_scope_if(token_generator& gen, error_handler& err, effect_building_context& context);
3760void ef_scope_else_if(token_generator& gen, error_handler& err, effect_building_context& context);
std::string accumulated_errors
std::string accumulated_warnings
dcon::modifier_id get_province_immigrator_modifier(sys::state &state)
dcon::modifier_id get_province_selector_modifier(sys::state &state)
constexpr uint16_t owner_scope_province
constexpr uint16_t no_payload
constexpr uint16_t scope_has_limit
uint32_t tag_to_int(char first, char second, char third)
void ef_scope_random_owned(token_generator &gen, error_handler &err, effect_building_context &context)
bool is_integer(char const *start, char const *end)
void ef_scope_any_defined_country(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_location(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_all_core(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_hidden_tooltip(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_sphere_owner(token_generator &gen, error_handler &err, effect_building_context &context)
bool is_this(std::string_view value)
bool is_reb(std::string_view value)
void ef_scope_random_state(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_owner(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_cultural_union(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_any_greater_power(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_random_list(token_generator &gen, error_handler &err, effect_building_context &context)
int32_t simplify_effect(uint16_t *source)
void ef_scope_else_if(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_middle_strata(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_any_state(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_random_empty_neighbor_province(token_generator &gen, error_handler &err, effect_building_context &context)
bool is_from(std::string_view value)
void ef_crisis_state_scope(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_controller(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_else(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_random_country(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_overlord(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_any_neighbor_province(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_capital_scope(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_state_scope(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_rich_strata(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_any_owned(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_any_substate(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_random_by_modifier(token_generator &gen, error_handler &err, effect_building_context &context)
bool is_fixed_token_ci(char const *start, char const *end, char const (&t)[N])
void ef_scope_any_existing_country_except_scoped(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_independence(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_from(token_generator &gen, error_handler &err, effect_building_context &context)
int32_t parse_int(std::string_view content, int32_t line, error_handler &err)
dcon::trigger_key ef_limit(token_generator &gen, error_handler &err, effect_building_context &context)
dcon::effect_key make_effect(token_generator &gen, error_handler &err, effect_building_context &context)
int32_t add_to_random_list(std::string_view label, token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_random_neighbor_province(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_poor_strata(token_generator &gen, error_handler &err, effect_building_context &context)
dcon::value_modifier_key read_chance_modifier(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_any_country(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_flashpoint_tag_scope(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_variable(std::string_view label, token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_random(token_generator &gen, error_handler &err, effect_building_context &context)
dcon::value_modifier_key make_option_ai_chance(token_generator &gen, error_handler &err, effect_building_context &context)
std::string slot_contents_to_string(trigger::slot_contents v)
void ef_scope_random_neighbor_country(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_country(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_sea_zone(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_any_neighbor_country(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_if(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_random_pop(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_this(token_generator &gen, error_handler &err, effect_building_context &context)
void ef_scope_any_pop(token_generator &gen, error_handler &err, effect_building_context &context)
dcon::text_key find_or_add_key(sys::state &state, std::string_view key, bool as_unicode)
void finish(effect_building_context &)
void type(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void name(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void finish(effect_building_context &)
void finish(effect_building_context &)
void name(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void casus_belli(association_type t, std::string_view v, error_handler &err, int32_t line, effect_building_context &context)
void finish(effect_building_context &)
dcon::cb_type_id casus_belli_
void finish(effect_building_context &)
bool limit_to_world_greatest_level
bool in_whole_capital_state
bool limit_to_world_greatest_level
bool in_whole_capital_state
void finish(effect_building_context &)
bool in_whole_capital_state
void finish(effect_building_context &)
bool limit_to_world_greatest_level
bool in_whole_capital_state
void finish(effect_building_context &)
bool limit_to_world_greatest_level
void type(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void finish(effect_building_context &)
void finish(effect_building_context &)
void which(association_type t, std::string_view v, error_handler &err, int32_t line, effect_building_context &context)
dcon::national_variable_id which_
dcon::national_event_id id_
void id(association_type t, int32_t value, error_handler &err, int32_t line, effect_building_context &context)
void finish(effect_building_context &)
dcon::leader_trait_id personality_
void personality(association_type t, std::string_view v, error_handler &err, int32_t line, effect_building_context &context)
dcon::leader_trait_id background_
void finish(effect_building_context &)
void background(association_type t, std::string_view v, error_handler &err, int32_t line, effect_building_context &context)
dcon::leader_trait_id personality_
void personality(association_type t, std::string_view v, error_handler &err, int32_t line, effect_building_context &context)
void background(association_type t, std::string_view v, error_handler &err, int32_t line, effect_building_context &context)
dcon::leader_trait_id background_
void finish(effect_building_context &)
void finish(effect_building_context &)
void finish(effect_building_context &)
void value(association_type t, std::string_view v, error_handler &err, int32_t line, effect_building_context &context)
dcon::issue_option_id value_
void value(association_type t, std::string_view v, error_handler &err, int32_t line, effect_building_context &context)
void finish(effect_building_context &)
void finish(effect_building_context &)
dcon::issue_option_id from_
dcon::issue_option_id to_
void to(association_type t, std::string_view v, error_handler &err, int32_t line, effect_building_context &context)
void from(association_type t, std::string_view v, error_handler &err, int32_t line, effect_building_context &context)
void ideology(association_type t, std::string_view v, error_handler &err, int32_t line, effect_building_context &context)
dcon::ideology_id ideology_
void finish(effect_building_context &)
void province_id(association_type t, int32_t value, error_handler &err, int32_t line, effect_building_context &context)
dcon::province_id province_id_
void id(association_type t, int32_t value, error_handler &err, int32_t line, effect_building_context &context)
dcon::provincial_event_id id_
void finish(effect_building_context &)
void finish(effect_building_context &)
void any_group(std::string_view label, int32_t value, error_handler &err, int32_t line, effect_building_context &context)
void finish(effect_building_context &)
void finish(effect_building_context &)
void type(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void finish(effect_building_context &)
dcon::ideology_id ideology_
void ideology(association_type t, std::string_view v, error_handler &err, int32_t line, effect_building_context &context)
void issue(association_type t, std::string_view v, error_handler &err, int32_t line, effect_building_context &context)
dcon::issue_option_id issue_
void finish(effect_building_context &)
void ideology(association_type t, std::string_view v, error_handler &err, int32_t line, effect_building_context &context)
dcon::ideology_id ideology_
void issue(association_type t, std::string_view v, error_handler &err, int32_t line, effect_building_context &context)
dcon::issue_option_id issue_
dcon::value_modifier_key chance_modifier
void finish(effect_building_context &)
void finish(effect_building_context &)
dcon::national_variable_id which_
void which(association_type t, std::string_view v, error_handler &err, int32_t line, effect_building_context &context)
void finish(effect_building_context &)
void type(association_type t, std::string_view v, error_handler &err, int32_t line, effect_building_context &context)
void type(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void finish(effect_building_context &)
dcon::culture_id culture_
void type(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void ideology(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
dcon::rebel_type_id type_
dcon::religion_id religion_
dcon::ideology_id ideology_
void culture(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void finish(effect_building_context &)
void religion(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void ideology(association_type t, std::string_view v, error_handler &err, int32_t line, effect_building_context &context)
void finish(effect_building_context &)
dcon::ideology_id ideology_
void finish(effect_building_context &)
dcon::national_identity_id country_
void finish(effect_building_context &)
bool target_country_is_this
void state_province_id(association_type t, int32_t value, error_handler &err, int32_t line, effect_building_context &context)
dcon::cb_type_id casus_belli_
void country(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
dcon::province_id state_province_id_
void casus_belli(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
bool target_country_is_from
bool special_call_ally_wargoal
void scaled_consciousness(ef_scaled_consciousness const &value, error_handler &err, int32_t line, effect_building_context &context)
void remove_random_military_reforms(association_type t, int32_t value, error_handler &err, int32_t line, effect_building_context &context)
void province_immigrator(association_type t, int32_t value, error_handler &err, int32_t line, effect_building_context &context)
void activate_technology(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void remove_accepted_culture(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void military_access(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void define_general(ef_define_general const &value, error_handler &err, int32_t line, effect_building_context &context)
void add_country_modifier(ef_add_country_modifier const &value, error_handler &err, int32_t line, effect_building_context &context)
void build_university_in_capital(ef_build_university_in_capital const &value, error_handler &err, int32_t line, effect_building_context &context)
void government(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void annex_to(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void naval_base(association_type t, int32_t value, error_handler &err, int32_t line, effect_building_context &context)
void limit(dcon::trigger_key lim, error_handler &err, int32_t line, effect_building_context &context)
void set_culture(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void pop_type(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void decrement_variable(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void capital(association_type t, int32_t value, error_handler &err, int32_t line, effect_building_context &context)
void clr_global_flag(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void military_reform(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void set_variable(ef_set_variable const &value, error_handler &err, int32_t line, effect_building_context &context)
void build_factory_in_capital_state(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void release_vassal(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void finish(effect_building_context &)
void add_country_modifier(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void end_war(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void party_loyalty(ef_party_loyalty const &value, error_handler &err, int32_t line, effect_building_context &context)
void set_global_flag(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void primary_culture(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void remove_province_modifier(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void create_vassal(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void leave_alliance(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void world_wars_enabled(association_type t, bool value, error_handler &err, int32_t line, effect_building_context &context)
void enable_ideology(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void nationalvalue(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void create_alliance(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void clr_country_flag(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void trigger_revolt(ef_trigger_revolt const &value, error_handler &err, int32_t line, effect_building_context &context)
void nationalize(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void economic_reform(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void relation(ef_relation const &value, error_handler &err, int32_t line, effect_building_context &context)
void consciousness(association_type t, float value, error_handler &err, int32_t line, effect_building_context &context)
void add_casus_belli(ef_add_casus_belli const &value, error_handler &err, int32_t line, effect_building_context &context)
void change_controller(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void set_variable_to_zero(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void add_accepted_culture(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void literacy(association_type t, float value, error_handler &err, int32_t line, effect_building_context &context)
void add_tax_relative_income(association_type t, float value, error_handler &err, int32_t line, effect_building_context &context)
void any_value(std::string_view label, association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void neutrality(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void prestige(association_type t, float value, error_handler &err, int32_t line, effect_building_context &context)
void flashpoint_tension(association_type t, float value, error_handler &err, int32_t line, effect_building_context &context)
void university(association_type t, int32_t value, error_handler &err, int32_t line, effect_building_context &context)
void ruling_party_ideology(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void leadership(association_type t, int32_t value, error_handler &err, int32_t line, effect_building_context &context)
void election(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void province_selector(association_type t, int32_t value, error_handler &err, int32_t line, effect_building_context &context)
void sub_unit(ef_sub_unit const &value, error_handler &err, int32_t line, effect_building_context &context)
void remove_random_economic_reforms(association_type t, int32_t value, error_handler &err, int32_t line, effect_building_context &context)
void religion(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void badboy(association_type t, float value, error_handler &err, int32_t line, effect_building_context &context)
void change_tag(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void war_exhaustion(association_type t, float value, error_handler &err, int32_t line, effect_building_context &context)
void add_crime(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void change_tag_no_core_switch(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void add_crisis_temperature(association_type t, float value, error_handler &err, int32_t line, effect_building_context &context)
void ideology(ef_ideology const &value, error_handler &err, int32_t line, effect_building_context &context)
void province_event(ef_province_event const &value, error_handler &err, int32_t line, effect_building_context &context)
void masquerade_as_nation(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void political_reform(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void dominant_issue(ef_dominant_issue const &value, error_handler &err, int32_t line, effect_building_context &context)
void remove_casus_belli(ef_remove_casus_belli const &value, error_handler &err, int32_t line, effect_building_context &context)
void upper_house(ef_upper_house const &value, error_handler &err, int32_t line, effect_building_context &context)
void remove_core(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void bank(association_type t, int32_t value, error_handler &err, int32_t line, effect_building_context &context)
void move_issue_percentage(ef_move_issue_percentage const &value, error_handler &err, int32_t line, effect_building_context &context)
void prestige_factor(association_type t, float value, error_handler &err, int32_t line, effect_building_context &context)
void change_province_name(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void money(association_type t, float value, error_handler &err, int32_t line, effect_building_context &context)
void country_event(association_type t, int32_t value, error_handler &err, int32_t line, effect_building_context &context)
void plurality(association_type t, float value, error_handler &err, int32_t line, effect_building_context &context)
void trade_goods(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void social_reform(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void assimilate(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void infrastructure(association_type t, int32_t value, error_handler &err, int32_t line, effect_building_context &context)
void casus_belli(ef_casus_belli const &value, error_handler &err, int32_t line, effect_building_context &context)
void add_war_goal(ef_add_war_goal const &value, error_handler &err, int32_t line, effect_building_context &context)
void change_variable(ef_change_variable const &value, error_handler &err, int32_t line, effect_building_context &context)
void release(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void reduce_pop(association_type t, float value, error_handler &err, int32_t line, effect_building_context &context)
void define_admiral(ef_define_admiral const &value, error_handler &err, int32_t line, effect_building_context &context)
void end_military_access(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void add_province_modifier(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void rgo_size(association_type t, int32_t value, error_handler &err, int32_t line, effect_building_context &context)
void years_of_research(association_type t, float value, error_handler &err, int32_t line, effect_building_context &context)
void remove_country_modifier(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void set_country_flag(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void enable_canal(association_type t, int32_t value, error_handler &err, int32_t line, effect_building_context &context)
void war(ef_war const &value, error_handler &err, int32_t line, effect_building_context &context)
void research_points(association_type t, int32_t value, error_handler &err, int32_t line, effect_building_context &context)
void add_province_modifier(ef_add_province_modifier const &value, error_handler &err, int32_t line, effect_building_context &context)
void inherit(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void reduce_pop_abs(association_type t, int32_t value, error_handler &err, int32_t line, effect_building_context &context)
void fort(association_type t, int32_t value, error_handler &err, int32_t line, effect_building_context &context)
void province_event(association_type t, int32_t value, error_handler &err, int32_t line, effect_building_context &context)
void kill_leader(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void country_event(ef_country_event const &value, error_handler &err, int32_t line, effect_building_context &context)
void great_wars_enabled(association_type t, bool value, error_handler &err, int32_t line, effect_building_context &context)
void scaled_militancy(ef_scaled_militancy const &value, error_handler &err, int32_t line, effect_building_context &context)
void move_pop(association_type t, int32_t value, error_handler &err, int32_t line, effect_building_context &context)
void tech_school(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void diplomatic_influence(ef_diplomatic_influence const &value, error_handler &err, int32_t line, effect_building_context &context)
void life_rating(association_type t, int32_t value, error_handler &err, int32_t line, effect_building_context &context)
void treasury(association_type t, float value, error_handler &err, int32_t line, effect_building_context &context)
void secede_province(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void civilized(association_type t, bool value, error_handler &err, int32_t line, effect_building_context &context)
void increment_variable(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void build_railway_in_capital(ef_build_railway_in_capital const &value, error_handler &err, int32_t line, effect_building_context &context)
void change_region_name(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void this_remove_casus_belli(ef_this_remove_casus_belli const &value, error_handler &err, int32_t line, effect_building_context &context)
void add_crisis_interest(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void build_fort_in_capital(ef_build_fort_in_capital const &value, error_handler &err, int32_t line, effect_building_context &context)
void change_terrain(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void build_bank_in_capital(ef_build_bank_in_capital const &value, error_handler &err, int32_t line, effect_building_context &context)
void add_core(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
void is_slave(association_type t, bool value, error_handler &err, int32_t line, effect_building_context &context)
void militancy(association_type t, float value, error_handler &err, int32_t line, effect_building_context &context)
trigger::slot_contents this_slot
scenario_building_context & outer_context
void add_int32_t_to_payload(int32_t i)
std::vector< uint16_t > compiled_effect
trigger::slot_contents from_slot
effect_building_context(scenario_building_context &outer_context, trigger::slot_contents main_slot, trigger::slot_contents this_slot, trigger::slot_contents from_slot)
trigger::slot_contents main_slot
void add_float_to_payload(float f)
dcon::value_modifier_key ai_chance
void name(association_type t, std::string_view value, error_handler &err, int32_t line, effect_building_context &context)
ankerl::unordered_dense::map< std::string, dcon::unit_type_id > map_of_unit_types
ankerl::unordered_dense::map< std::string, dcon::modifier_id > map_of_modifiers
ankerl::unordered_dense::map< std::string, dcon::religion_id > map_of_religion_names
ankerl::unordered_dense::map< std::string, pending_invention_content > map_of_inventions
ankerl::unordered_dense::map< std::string, pending_roption_content > map_of_roptions
ankerl::unordered_dense::map< std::string, pending_tech_content > map_of_technologies
ankerl::unordered_dense::map< std::string, dcon::pop_type_id > map_of_poptypes
ankerl::unordered_dense::map< std::string, pending_ideology_content > map_of_ideologies
std::vector< dcon::province_id > original_id_to_prov_id_map
ankerl::unordered_dense::map< std::string, pending_crime_content > map_of_crimes
ankerl::unordered_dense::map< std::string, dcon::leader_trait_id > map_of_leader_traits
dcon::global_flag_id get_global_flag(std::string const &name)
ankerl::unordered_dense::map< std::string, pending_option_content > map_of_ioptions
ankerl::unordered_dense::map< std::string, pending_cb_content > map_of_cb_types
ankerl::unordered_dense::map< std::string, terrain_type > map_of_terrain_types
dcon::national_flag_id get_national_flag(std::string const &name)
ankerl::unordered_dense::map< std::string, pending_rebel_type_content > map_of_rebeltypes
ankerl::unordered_dense::map< uint32_t, dcon::national_identity_id > map_of_ident_names
ankerl::unordered_dense::map< std::string, dcon::culture_id > map_of_culture_names
ankerl::unordered_dense::map< std::string, dcon::commodity_id > map_of_commodity_names
ankerl::unordered_dense::map< std::string, dcon::government_type_id > map_of_governments
dcon::national_variable_id get_national_variable(std::string const &name)
ankerl::unordered_dense::map< std::string, dcon::factory_type_id > map_of_factory_names