#-------------------------------------------------------------------------------- # Dual-scope Triggers #-------------------------------------------------------------------------------- always = yes / no log = "[Root.GetName] text here" ironman = yes / no has_dlc = # Only for gameplay DLCs is_random_new_world = yes / no is_month = is_year = real_day_of_year = real_month_of_year = start_date = # Returns true only on exact date started_in = has_game_started = yes has_global_flag = had_global_flag = { flag = days = } normal_or_historical_nations = yes / no # Checks if the normal country setup is being used normal_province_values = yes / no # Checks if the normal province setup is being used num_of_custom_nations = check_variable = { which = value = which = # Used to compare } is_variable_equal = { which = value = which = # Used to compare } # Highlights provinces for decisions and missions # Acts as all_province scope provinces_to_highlight = { } #-------------------------------------------------------------------------------- # Country-scope Triggers #-------------------------------------------------------------------------------- # ----- General ----- tag = was_tag = exists = yes / ai = yes luck = yes / no was_player = yes / no has_switched_nation = yes / no has_saved_event_target = has_country_flag = has_country_modifier = had_country_flag = { flag = days = } has_global_modifier_value = { which = value = extra_shortcut = yes # Display tooltip as if the modifier is 100% + value } active_major_mission = last_mission = mission_completed = has_custom_ideas = yes / no is_playing_custom_nation = yes / no nation_designer_points = is_dynamic_tag = yes has_mission = # ----- Cores, Claims and Territories ----- capital = / controls = / is_claim = / is_core = / is_state_core = / is_territorial_core = / owns = / owns_core_province = / owns_or_vassal_of = / owns_or_subject_of = / owns_or_non_sovereign_subject_of = / same_continent = / num_of_provinces_in_states = / num_of_provinces_in_territories = / num_of_states = / num_of_territories = / num_of_continents = num_of_cities = / core_percentage = # Checks if an amount of owned provinces meet the specified triggers num_of_owned_provinces_with = { value = } # ----- Economy ----- adm_power = / dip_power = / mil_power = / national_focus = total_base_tax = / total_development = treasury = / years_of_income = / monthly_income = / tax_income_percentage = gold_income_percentage = production_income_percentage = trade_income_percentage = inflation = / is_bankrupt = yes / no is_in_deficit = yes / no num_of_loans = / is_in_large_debt = yes production_efficiency = / trade_efficiency = / production_leader = { trade_goods = } # Checks if the owned provinces of the current scope have the specified amount (or more) of the specified building = # Used in missions share_of_starting_income = grown_by_development = grown_by_states = # ----- Trade ----- = mercantilism = / num_of_merchants = num_of_strong_trade_companies = num_of_trade_companies = num_of_trading_bonuses = num_of_trade_embargos = is_in_trade_league_with = trade_embargoing = trade_embargo_by = trade_league_embargoed_by = is_in_trade_league = yes is_trade_league_leader = yes num_of_centers_of_trade = has_center_of_trade_of_level = trading_bonus = { trade_goods = value = yes / no } trading_part = { trade_goods = value = } # ----- Government ----- prestige = / absolutism = / corruption = yearly_corruption_increase = / government = # Checks: monarchy, republic, tribal, dictatorship government_rank = legitimacy = / republican_tradition = / horde_unity = / legitimacy_or_horde_unity = / devotion = / meritocracy = legitimacy_equivalent = / is_nomad = yes / no is_tribal = yes / no is_monarchists_in_power = yes is_statists_in_power = yes has_parliament = yes / no has_active_debate = yes / no current_debate = current_size_of_parliament = percentage_backing_issue = uses_devotion = yes militarised_society = tribal_allegiance = / statists_vs_orangists = # 0 to 1 # Types: russian_mechanic, feudal_theocracy_mechanic, tribal_federation_mechanic, mamluk_mechanic, iqta_mechanic has_government_mechanic = # Type: ADM, DIP, MIL has_government_power = { type = value = } # Attributes: # Legitimacy - monarchy, republic, religion, tribal, dictatorship, nomad, papacy, has_meritocracy, has_devotion # Abilities - militarised_society, has_parliament, allow_migration, claim_states, native_mechanic # Ruler - heir, queen, has_term_election, election_on_death, is_elective # Other - republican_name, valid_for_nation_designer, allow_normal_conversion has_government_attribute = has_states_general_mechanic = has_reform = is_reform_available = have_had_reform = government_reform_progress = has_reform_level = # ----- Court ----- has_advisor = yes = advisor = advisor_exists = # Historical advisors only is_advisor_employed = # Historical advisors only # Checks if the current scope has an advisor hired with the specified attributes. employed_advisor = { type = category = # ADM / DIP / MIL religion = / / true_faith / heretic / heathen culture = / is_male = yes is_female = yes } # ----- Culture ----- primary_culture = / accepted_culture = / culture_group = / dominant_culture = / has_unified_culture_group = yes num_accepted_cultures = # ----- Religion ----- religion = / / secondary religion_group = / dominant_religion = / / capital / secondary secondary_religion = / papacy_active = yes / no total_number_of_cardinals = papal_influence = / authority = / # (0 to max) doom = / # (0 to max) church_power = / # (0 to max) fervor = # (0 to max) karma = / # (-100 to 100) harmony = # (0 to 100) harmonization_progress = # (0 to 100) patriarch_authority = # (0 to 1) piety = / # (-1 to 1) reform_desire = invested_papal_influence = / isolationism = religious_unity = / is_religion_enabled = has_matching_religion = has_personal_deity = has_unlocked_cult = has_adopted_cult = has_church_aspect = has_religious_school_of = is_harmonizing_with = has_harmonized_with = is_incident_potential = is_incident_happened = is_incident_possible = is_incident_active = / any / none current_icon = has_friendly_reformation_center = yes / no has_hostile_reformation_center = yes / no has_active_fervor = yes / no has_religious_school = yes / no is_any_heresy_enabled = yes / no # Is an heretic religion available to convert to is_crusade_target = yes / no is_defender_of_faith = yes / no is_excommunicated = yes / no is_force_converted = yes / no is_papal_controller = yes / no is_previous_papal_controller = yes / no is_religion_reformed = yes / no # Religious Reforms at_war_with_religious_enemy = yes has_border_with_religious_enemy = yes has_secondary_religion = yes num_of_active_blessings = num_of_aspects = / num_of_cardinals = / num_of_missionaries = num_of_unlocked_cults = num_of_harmonized = uses_authority = yes / no # Checks if the current scope uses Authority (Religious Reforms). uses_blessings = yes / no # Checks if the current scope uses Blessings. uses_church_aspects = yes / no # Checks if the current scope uses Church Aspects. uses_cults = yes / no # Checks if the current scope uses Cults. uses_doom = yes / no # Checks if the current scope uses Doom (Religious Reforms). uses_fervor = yes / no # Checks if the current scope uses Fervor. uses_karma = yes / no # Checks if the current scope uses Karma. uses_isolationism = yes / no # Checks if the current scope uses Isolationism. uses_papacy = yes / no # Checks if the current scope uses the Papacy. uses_patriarch_authority = yes / no # Checks if the current scope uses Patriarch Authority. uses_personal_deities = yes / no # Checks if the current scope uses Personal Deities. uses_piety = yes / no # Checks if the current scope uses Piety. uses_syncretic_faiths = yes / no # Checks if the current scope uses Syncretic Religions. uses_religious_icons = yes / no # Checks if the current scope uses Patriarch Icons. = religion_years = { = } num_of_religion = { religion = value = # Percentage of specified religion to match for heretic = yes # Optional. Used in place of religion, matches all heretic religions } incident_variable_value = { incident = value = } # Check if country has religious school religious_school = { group = school = } school_opinion = { who = opinion = } # ----- Technology ----- technology_group = neighbors_tech_discount = tech_difference = # Checks if the current scope has the specified tech difference with the previous or root scope. adm_tech = dip_tech = mil_tech = has_idea = = full_idea_group = has_idea_group = has_active_policy = had_active_policy = { policy = days = } is_institution_enabled = has_institution = current_institution_growth = num_of_owned_and_controlled_institutions = / has_unembraced_institution = institution_difference = { who = value = } current_age = has_age_ability = in_golden_age = yes / no splendor = / innovativeness = # ----- Unrest ----- stability = / unrest = average_autonomy = average_autonomy_above_min = average_effective_unrest = average_home_autonomy = # Only counts provinces connected to the capital. average_unrest = num_of_rebel_armies = / num_of_rebel_controlled_provinces = / num_of_revolts = / revolt_percentage = has_spawned_rebels = overextension_percentage = / revanchism = yes / no has_any_disaster = yes / no has_disaster = has_disaster_progress = { disaster = value = } # ----- Military ----- army_size = / army_size_percentage = army_tradition = / army_professionalism = artillery_fraction = cavalry_fraction = infantry_fraction = land_forcelimit = / land_maintenance = land_morale = / war_exhaustion = / manpower = manpower_percentage = max_manpower = / num_of_artillery = / num_of_cavalry = / num_of_infantry = / num_of_conquistadors = / num_of_generals = / num_of_generals_with_traits = / num_of_mercenaries = / num_of_banners = / num_of_cossacks = / num_of_streltsy = / num_of_rajput = / janissary_percentage = war_score = had_recent_war = # years has_leader = has_unit_type = has_truce = yes / no has_commanding_three_star = yes has_wartaxes = yes / no is_at_war = yes / no has_leader_with = { general = yes admiral = yes fire = shock = manuever = siege = total_pips = } has_leaders = { value = type = include_monarch = no include_heir = no } compare_regiments_to_province_of_estate = { regiment = # i.e. rajput_regiment estate = compare = # less, (more?), (equals?) } total_losses_in_won_wars = { winner = loser = casualties = } # ----- Navy ----- sailors = sailors_percentage = naval_forcelimit = naval_maintenance = / naval_morale = / navy_size = / navy_size_percentage = galley_fraction = heavy_ship_fraction = light_ship_fraction = transport_fraction = navy_tradition = / num_of_admirals = / num_of_admirals_with_traits = / num_of_explorers = / num_of_galley = / num_of_heavy_ship = / num_of_light_ship = / num_of_transport = / num_of_ports = / num_of_ports_blockading = / num_of_total_ports = / num_ships_privateering = / blockade = / # Current blockade penalty has_privateers = yes / no has_flagship = # ----- Diplomacy ----- cb_on_government_enemies = yes / no cb_on_overseas = yes / no cb_on_primitives = yes / no cb_on_religious_enemies = yes / no is_great_power = yes / no is_in_important_war = yes / no is_in_coalition = yes / no can_create_subject_of_type = coalition_target = historical_friend_with = historical_rival_with = alliance_with = can_justify_trade_conflict = can_release = claim = core_claim = defensive_war_with = guaranteed_by = has_casus_belli_against = has_guaranteed = has_spawned_supported_rebels = is_enemy = is_neighbor_of = is_possible_march = is_possible_vassal = is_rival = is_threat = junior_union_with = march_of = marriage_with = offensive_war_with = overlord_of = provinces_on_capital_continent_of = succession_claim = senior_union_with = truce_with = vassal_of = war_with = = num_of_allies = / num_of_coalition_members = num_of_colonial_subjects = num_of_diplomats = num_of_diplomatic_relations = num_of_free_diplomatic_relations = num_of_marches = num_of_protectorates = num_of_royal_marriages = / num_of_trusted_allies = num_of_unions = num_of_vassals = num_of_war_reparations = / diplomatic_reputation = / great_power_rank = / development_of_overlord_fraction = subsidised_percent_amount = border_distance = { who = distance = } capital_distance = { who = distance = } has_spy_network_from = { who = value = } has_spy_network_in = { who = value = } has_casus_belli = { type = target = } war_score_against = { who = value = } has_opinion_diff = { first = second = value = } reverse_has_opinion_diff = { first = second = value = } has_opinion = { who = value = } trust = { who = value = } reverse_has_opinion = { who = value = } has_opinion_modifier = { modifier = who = value = # used with aggressive_expansion modifier } reverse_has_opinion_modifier = { modifier = who = value = # used with aggressive_expansion modifier } # Parameters are mix and match is_in_war = { attacker_leader = defender_leader = casus_belli = war_score = duration = start_date = war_goal_province = / # You can add multiple to check for multiple defenders/participants attackers = defenders = participants = } army_strength = { who = value = } military_strength = { who = value = } naval_strength = { who = value = } # ----- Subjects ----- can_create_vassals = yes / no has_divert_trade = yes / no has_embargo_rivals = yes / no has_promote_investments = yes / no has_scutage = yes / no has_send_officers = yes / no has_subsidize_armies = yes / no has_support_loyalists = yes / no has_colonial_parent = yes / no is_client_nation = yes / no is_lesser_in_union = yes / no is_march = yes / no is_overseas_subject = yes / no is_subject = yes / no is_vassal = yes / no is_colonial_nation = yes / no is_subject_of_type = is_client_nation_of = is_colonial_nation_of = is_subject_of = liberty_desire = / years_under_vassalage = { type = duration = all_subject_country = yes # Optional, removes limit by subject type. } years_in_union_under = { who = years = all_subject_country = yes # Optional, removes limit by subject type. } # ----- Colonialism ----- knows_country = has_removed_fow = # Has lifted all FOW over has_discovered = / num_of_colonies = / num_of_colonists = num_of_conquistadors = / num_of_explorers = / tariff_value = overseas_provinces_percentage = federation_size = / is_former_colonial_nation = yes / no primitives = yes / no is_federation_leader = yes / no native_policy = # ----- Ruler ----- ADM = / DIP = / MIL = / ruler_age = ruler_has_personality = ruler_culture = # Excludes specific tag scopes ruler_religion = # Excludes specific tag scopes dynasty = / has_ruler = / yes / no has_ruler_flag = ruler_is_foreigner = yes has_new_dynasty = yes / no has_regency = yes / no is_female = yes / no is_monarch_leader = yes has_ruler_modifier = had_ruler_flag = { flag = days = } exiled_same_dynasty_as_current = # ----- Consort ----- consort_adm = consort_dip = consort_mil = consort_age = consort_has_personality = consort_culture = # Excludes specific tag scopes consort_religion = # Excludes specific tag scopes has_consort = / yes / no has_consort_flag = has_consort_regency = yes / no has_female_consort = yes / no has_foreign_consort = yes / no ruler_consort_marriage_length = months_of_ruling = has_given_consort_to = is_origin_of_consort = had_consort_flag = { flag = days = } # ----- Heir ----- heir_adm = / heir_dip = / heir_mil = / heir_age = heir_has_personality = heir_culture = # Excludes specific tag scopes heir_religion = # Excludes specific tag scopes heir_claim = has_heir = / yes / no has_heir_flag = heir_has_consort_dynasty = yes / no heir_has_ruler_dynasty = yes / no can_heir_be_child_of_consort = yes has_female_heir = yes / no has_foreign_heir = yes is_heir_leader = yes heir_nationality = had_heir_flag = { flag = days = } # ----- Estates ----- has_estate = num_of_powerful_estates = estate_influence = { estate = influence = } estate_loyalty = { estate = loyalty = } estate_territory = { estate = territory = } has_estate_influence_modifier = { estate = modifier = } has_estate_loyalty_modifier = { estate = modifier = } # ----- Factions ----- has_factions = yes / no has_faction = faction_in_power = faction_influence = { faction = influence = } # ----- Holy Roman Empire ----- preferred_emperor = hre_reform_level = hre_size = imperial_influence = num_of_electors = is_elector = yes is_emperor = yes / no is_imperial_ban_allowed = yes / no allows_female_emperor = yes / no is_part_of_hre = yes / no will_back_next_reform = yes / no hre_leagues_enabled = yes hre_religion = / hre_heretic_religion = / hre_religion_locked = yes / no hre_religion_treaty = yes / no is_league_leader = yes / no is_in_league_war = yes / no in_league = is_league_enemy = is_league_friend = num_of_foreign_hre_provinces = # ----- Empire of China ----- is_emperor_of_china = yes / no imperial_mandate = empire_of_china_reform_level = # ----- Revolution ----- is_revolution_target = yes has_first_revolution_started = yes revolution_target_exists = yes # ----- AI ----- personality = ai_attitude = { who = attitude = } #-------------------------------------------------------------------------------- # Province-scope Triggers #-------------------------------------------------------------------------------- # ----- General ----- has_province_flag = has_province_modifier = development = base_manpower = base_production = base_tax = devastation = prosperity = local_autonomy = local_autonomy_above_min = num_of_times_improved = has_climate = has_terrain = has_winter = has_monsoon = island = yes / no is_island = yes / no is_capital = yes / no is_city = yes / no is_wasteland = yes / no is_in_capital_area = yes / no # Means is province connected to capital via other provinces is_part_of_hre = yes is_sea = yes / no is_prosperous = yes / no is_empty = yes / no is_overseas = yes / no has_port = yes / no has_empty_adjacent_province = yes had_province_flag = { flag = days = } has_local_modifier_value = { which = value = } province_distance = { who = distance = } has_active_triggered_province_modifier = # ----- Control, States and Territories ----- owned_by = previous_owner = controlled_by = / is_capital_of = is_claim = is_core = is_state_core = is_permanent_claim = is_territorial_core = is_state = yes is_territory = yes province_id = / area = continent = / / region = / capital / superregion = province_group = province_size = months_since_defection = # Within a region scope: country_or_vassal_holds = # If scope or any vassal subjects hold a province in the region country_or_subject_holds = # If scope or any subjects hold a province in the region country_or_non_sovereign_subject_holds = # If scope or any non-tributary subjects hold a province in the region culture_group_claim = # If cur. primary culture is in the same culture group as any culture group within the provinces owned by # ----- Colonialism ----- colonial_region = has_colonist = yes is_colony = yes / no colony = range = colonysize = native_ferocity = native_hostileness = native_size = colony_claim = colonial_claim_by_anyone_of_religion = / # Treaty of Tortillas is_religion_grant_colonial_claim = yes / no / # Treaty of Tortillas expelling_minorities_from = expelling_minorities = expelled_different_minorities = recent_treasure_ship_passage = # ----- Construction ----- can_build = has_building = construction_progress = has_great_project = has_construction = # Types: core, culture, building, merchant, diplomat, missionary, # army, navy, canal, great_project, siberian, colonist or any num_free_building_slots = # ----- Society ----- = current_institution = is_institution_origin = has_state_edict = has_estate = / yes has_seat_in_parliament = yes / no is_backing_current_issue = yes / no current_bribe = culture = / culture_group = / has_owner_culture = yes has_owner_accepted_culture = yes religion = / / secondary religion_group = / tolerance_to_this = has_cardinal = yes has_missionary = yes has_owner_religion = yes is_reformation_center = yes papacy_active = yes has_state_patriach = yes / no holy_order = provincial_institution_progress = { which = value = } # ----- Military ----- fort_level = garrison = sieged_by = / has_influencing_fort = yes has_siege = yes is_blockaded = no is_looted = yes has_heir_leader_from = has_ruler_leader_from = units_in_province = / unit_in_battle = yes unit_has_leader = yes unit_in_siege = yes infantry_in_province = / cavalry_in_province = / artillery_in_province = / heavy_ships_in_province = / light_ships_in_province = / galleys_in_province = / transports_in_province = / num_of_units_in_province = { who = / enemy type = # optional amount = # optional } # ----- Unrest ----- can_spawn_rebels = has_rebel_faction = REB / likely_rebels = nationalism = pure_unrest = unrest = has_harsh_treatment = yes # ----- Trade ----- trade_goods = has_latent_trade_goods = trade_range = province_trade_power = trade_company_size = trade_company_region = is_owned_by_trade_company = yes province_has_center_of_trade_of_level = # Has specified number of investments in the trade company region the current province belongs to. num_investments_in_trade_company_region = { investment = value = } # Has the specified investment in the area of the current province. has_trade_company_investment_in_area = { investment = investor = } # Within a tradenode scope: has_merchant = has_most_province_trade_power = has_trader = is_strongest_trade_power = is_node_in_trade_company_region = yes / no highest_value_trade_node = yes trader_has_active_policy = #Can use name and key has_trade_modifier = { who = name = } privateer_power = { share = country = # optional, limits to scope's privateers } trade_share = { share = country = } trading_policy_in_node = { node = policy = / any } has_privateer_share_in_trade_node = { who = share = } #-------------------------------------------------------------------------------- # Trigger - Script #-------------------------------------------------------------------------------- # Hides trigger tooltip for a set of triggers hidden_trigger = { } # Adds a custom tooltip for a set of triggers custom_trigger_tooltip = { tooltip = } #Following Trigger has two separate uses calc_true_if = { #triggers amount = 3 } #It can be used with multiple triggers, and it returns true if at least X amount of the triggers return true calc_true_if = { ADM = 4 religion = catholic full_idea_group = religious_ideas religious_unity = 1.0 is_papal_controller = yes amount = 3 } #So this will return true if at least 3 of these 5 triggers are true #This trigger funtions differently if using one of the all_ triggers #Country Scope Example calc_true_if = { all_country = { religion = protestant } amount = 5 } #This will return true if there are at least 5 Protestant countries in the world #Province Scope Example calc_true_if = { all_owned_province = { has_terrain = marsh } amount = 2 } #This will return true if the scope has at least two provinces that have the marsh terrain #Scripted Triggers (defined in common\scripted_triggers) scripted_triggers_name = yes #no doesn't work, must use NOT = { scripted_triggers_name = yes } #-------------------------------------------------------------------------------- # Removed #-------------------------------------------------------------------------------- has_sphere = #EU IV doesn't use spheres in the way that EU III did. in_sphere_of = # EU IV doesn't use spheres in the way that EU III did. leads_coalition = yes #never found in code, coalitions no longer have leaders num_of_free_ideas = #never found in code, tested and wasn't working properly num_of_total_ideas = #never found in code, tested and wasn't working properly num_of_placed_merchants = #never found in code. Not really needed since merchants are no longer a currency, they'll always be placed so can just count number of merchants. num_of_trade_rights = #not found in code. I don't think there are trade rights in EU IV pure_revolt_risk = 3 #Removed as of patch 1.8 revolt_risk = 1 #Removed as of patch 1.8 trade_leader = #Removed by Gars in 1.6 and didn't work before that war_with_nomads = yes is_colonial = yes / no has_discovered_region = { region = years = } has_discovered_capital_region_of = { who = years = } #This trigger is not localized has_any_country_in_region_discovered_capital_region_of = { region = who = years = } has_hre_emperor_modifier = test has_hre_member_modifier = test months_since_last_owner_change = 60 #never found in code and reported that it doesn't work is_protectorate = yes