Losa10/PreTrain-HOI4-Modding-Assistant huggingface dataset:
### Entity: Idea
Component: HOL_shared_intelligence_hol_ger
Constructs: removal_cost
Source: game
File: common/ideas/netherlands.txt

Code:
HOL_shared_intelligence_hol_ger = {
	name = HOL_shared_intelligence_hol
	picture = SOV_scientist_defect
	allowed = {
		always = no
	}
	allowed_civil_war = {
		always = yes
	}
	removal_cost = -1
	targeted_modifier = {
		tag = GER
		attack_bonus_against = 0.02
		defense_bonus_against = 0.05
	}
}
### Entity: National Focus
Tree: den_focus
Component: DEN_Cross_the_Skagerrak
Constructs: every_owned_state, prerequisite, limit, completion_reward, has_army_manpower, is_subject, is_in_faction_with, has_non_aggression_pact_with
Source: game
File: common/national_focus/r56_denmark.txt

Code:
focus = {
	id = DEN_Cross_the_Skagerrak
	icon = GFX_goal_generic_attack_norway
	cost = 10
	ai_will_do = {
		factor = 1
	}
	search_filters = {
		FOCUS_FILTER_ANNEXATION
	}
	available = {
		has_army_manpower = {
			size = > 199999
		}
		is_subject = no
		NOR = {
			exists = yes
			NOT = {
				is_in_faction_with = DEN
				has_non_aggression_pact_with = DEN
			}
		}
	}
	prerequisite = {
		focus = DEN_Militarization_of_Society
	}
	x = 1
	y = 5
	relative_position_id = DEN_DNSAP_Takeover
	will_lead_to_war_with = NOR
	completion_reward = {
		create_wargoal = {
			target = NOR
			type = annex_everything
		}
		NOR = {
			every_owned_state = {
				limit = {
					is_core_of = NOR
					NOT = {
						is_core_of = DEN
					}
				}
				DEN = {
					add_state_claim = PREV
				}
			}
		}
	}
}
### Entity: Idea
Component: MEN_assist_in_the_great_patriotic_war
Constructs: has_government, removal_cost, planning_speed
Source: game
File: common/ideas/r56_mengkukuo.txt

Code:
MEN_assist_in_the_great_patriotic_war = {
	allowed = {
		always = no
	}
	allowed_civil_war = {
		has_government = communism
	}
	removal_cost = -1
	picture = FIN_german_threat
	modifier = {
		planning_speed = 0.1
		max_planning = 0.05
	}
	targeted_modifier = {
		tag = GER
		attack_bonus_against = 0.1
		defense_bonus_against = 0.1
	}
}
### Entity: Character
Component: INS_sombaya_of_gowa
Source: game
File: common/country_leader/00_traits.txt

Code:
INS_sombaya_of_gowa = {
	non_core_manpower = 0.02
	army_morale_factor = 0.05
	random = no
	sprite = 2
	ai_will_do = {
		factor = 1
	}
}
### Entity: Country History
Country: FOR
Component: FOR_misc
Constructs: set_technology, set_convoys, complete_national_focus, set_grand_doctrine, complete_special_project
Source: game
File: history/countries/FOR - Formosa.txt

Code:
# Misc for FOR
capital = 524
set_convoys = 0
1939.1.1 = {
	complete_national_focus = army_effort equipment_effort motorization_effort aviation_effort naval_effort large_navy industrial_effort construction_effort production_effort
	set_technology = {
		tech_support = 1
		tech_recon = 1
		support_weapons = 1
		gw_artillery = 1
		electronic_mechanical_engineering = 1
		radio = 1
		mechanical_computing = 1
		computing_machine = 1
		basic_machine_tools = 1
		improved_machine_tools = 1
		advanced_machine_tools = 1
		construction1 = 1
		construction2 = 1
		dispersed_industry = 1
		dispersed_industry2 = 1
	}
	set_grand_doctrine = grand_battleplan new_fleet_in_being new_strategic_destruction
	complete_special_project = {
		project = sp:sp_air_radar
	}
}
### Entity: Idea
Component: GRE_reviving_the_double_headed_eagle_2
Constructs: war_support_factor, removal_cost
Source: game
File: common/ideas/greece.txt

Code:
GRE_reviving_the_double_headed_eagle_2 = {
	allowed = {
		original_tag = GRE
	}
	allowed_civil_war = {
		always = yes
	}
	picture = air_support_focus
	removal_cost = -1
	modifier = {
		war_support_factor = 0.15
		political_power_factor = 0.15
		non_core_manpower = 0.1
	}
}
### Entity: AI Strategy
Component: EAI_SOV_defense_in_depth_241
Constructs: has_war_with
Source: game
File: common/ai_strategy/SOV_EAI.txt

Code:
EAI_SOV_defense_in_depth_241 = {
	allowed = {
		tag = SOV
	}
	enable = {
		any_of_scopes = {
			array = global.EAI_MAP_SOV_garrison_strategy_241
			CONTROLLER = {
				has_war_with = ROOT
			}
		}
	}
	abort_when_not_enabled = yes
	ai_strategy = {
		type = put_unit_buffers
		ratio = 0.02
		order_id = 241
		states = {
			241
		}
		subtract_invasions_from_need = no
		subtract_fronts_from_need = no
	}
}
### Entity: Event
Component: tfv_australia.70
Constructs: is_triggered_only, ai_chance
Source: game
File: events/TFV_Australia.txt

Code:
country_event = {
	id = tfv_australia.70
	title = tfv_australia.70.t
	desc = tfv_australia.70.d
	picture = GFX_report_event_ast_troops_landing
	is_triggered_only = yes
	option = {
		name = tfv_australia.70.a
		ai_chance = {
			base = 100
		}
		effect_tooltip = {
			AST = {
				puppet = MAL
			}
		}
		hidden_effect = {
			AST = {
				country_event = {
					id = tfv_australia.71
				}
			}
		}
	} {
		name = tfv_australia.70.b
		ai_chance = {
			base = 0
		}
		hidden_effect = {
			AST = {
				country_event = {
					id = tfv_australia.72
				}
			}
		}
	}
}
### Entity: National Focus
Tree: sov_focus
Component: SOV_civil_war_russian_women_fascist_movement
Constructs: prerequisite, add_ideas, completion_reward
Source: game
File: common/national_focus/r56_soviet_civil_war.txt

Code:
focus = {
	id = SOV_civil_war_russian_women_fascist_movement
	icon = GFX_goal_womens_rights
	prerequisite = {
		focus = SOV_civil_war_reject_cosmopolitanism
	}
	x = 1
	y = 1
	relative_position_id = SOV_civil_war_reject_cosmopolitanism
	mutually_exclusive = {
		focus = SOV_civil_war_union_of_fascist_little_ones
	}
	cost = 10
	ai_will_do = {
		factor = 0
	}
	completion_reward = {
		add_ideas = SOV_russian_women_fascist_movement
	}
	search_filters = {
		FOCUS_FILTER_MANPOWER
	}
}
### Entity: Event
Component: WW_hungary.78
Constructs: is_triggered_only, add_country_leader_role
Source: game
File: events/WUW_Hungary.txt

Code:
country_event = {
	id = WW_hungary.78
	title = WW_hungary.78.t
	desc = WW_hungary.78.desc
	picture = GFX_report_event_military_planning
	is_triggered_only = yes
	option = {
		name = WW_hungary.78.a
		add_country_leader_role = {
			character = ITA_papa_pio_xii
			promote_leader = yes
			country_leader = {
				ideology = oligarchism
				expire = 1958.12.16
				traits = {
					supreme_pontiff grand_master_of_the_equestrian_order_of_the_holy_sepulcher_of_jerusalem
				}
			}
		}
	}
}
### Entity: Decision
Component: GER_austro_hungarian_empire
Constructs: has_completed_focus
Source: game
File: common/decisions/categories/GER_decision_categories.txt

Code:
GER_austro_hungarian_empire = {
	allowed = {
		OR = {
			original_tag = AUS HUN CZE
		}
	}
	visible = {
		OR = {
			GER = {
				OR = {
					has_completed_focus = GER_rekindle_imperial_sentiment GER_rekindle_imperial_sentiment_ww
				}
			}
			TUR = {
				has_completed_focus = TUR_press_the_austro_hungarian_claim
			}
		}
	}
}
### Entity: Event
Component: wtt_germany.27
Constructs: has_government, fire_only_once, has_country_leader, set_country_flag, add_country_leader_role
Source: game
File: events/WTT_Germany.txt

Code:
country_event = {
	id = wtt_germany.27
	title = wtt_germany.27.t
	desc = wtt_germany.27.d
	picture = GFX_report_event_generic_funeral
	fire_only_once = yes
	trigger = {
		tag = GER
		has_government = neutrality
		date = > 1940.1.1
		has_country_leader = {
			ruling_only = yes
			character = GER_august_von_mackensen
		}
	}
	mean_time_to_happen = {
		days = 1825
	}
	option = {
		name = wtt_germany.26.a
		kill_country_leader = yes
		set_country_flag = GER_mackensen_dead
		GER_wilhelm_iii = {
			add_country_leader_role = {
				country_leader = {
					expire = 1965.1.1
					ideology = despotism
					traits = {
						popular_figurehead2
					}
				}
				promote_leader = yes
			}
		}
	}
}
### Entity: Character
Component: TAH_mt
Source: game
File: common/characters/TAH.txt

Code:
TAH_mt = {
	advisor = {
		slot = theorist
		idea_token = TAH_mt
		ledger = army
		allowed = {
			original_tag = TAH
		}
		traits = {
			military_theorist
		}
	}
	portraits = {
		army = {
			small = GFX_idea_generic_army_asia_6
		}
	}
}
### Entity: Joint Focus
Component: ABDA_ship_a_day_sinking_quotas
Constructs: has_completed_focus, prerequisite, joint_focus, has_country_flag, add_to_variable
Source: game
File: common/national_focus/abdacom_shared_branch.txt

Code:
joint_focus = {
	id = ABDA_ship_a_day_sinking_quotas
	icon = GFX_goal_generic_navy_submarine
	prerequisite = {
		focus = ABDA_unified_naval_command
	}
	relative_position_id = ABDA_abdacom
	text_icon = ABDACOM_focus_style
	x = -2
	y = 4
	cost = 5
	available = {
		OR = {
			has_country_flag = abdacom_member
			has_completed_focus = ABDA_abdacom
		}
	}
	available_if_capitulated = no
	ai_will_do = {
		base = 1
		modifier = {
			add = 1
			original_tag = INS
		}
	}
	completion_reward_joint_originator = {
		custom_effect_tooltip = ABDA_ship_a_day_modifier_tt
		hidden_effect = {
			add_to_variable = {
				ABDA_submarine_attack_factor = 0.1
			} {
				ABDA_submarine_defence_factor = 0.1
			}
		}
	}
	completion_reward_joint_member = {
		custom_effect_tooltip = ABDA_ship_a_day_modifier_tt
		hidden_effect = {
			add_to_variable = {
				ABDA_submarine_attack_factor = 0.1
			} {
				ABDA_submarine_defence_factor = 0.1
			}
		}
	}
	search_filters = {
		FOCUS_FILTER_POLITICAL
	}
}
### Entity: Unit Template
Component: LUX_ARM_01
Source: game
File: common/units/names_divisions/LUX_names_divisions.txt

Code:
LUX_ARM_01 = {
	name = Armored Division
	for_countries = {
		LUX
	}
	can_use = {
		always = yes
	}
	division_types = {
		light_armor medium_armor heavy_armor modern_armor
	}
	fallback_name = %d. Panzerwagen-Division
	ordered = {
		1 = {
			%d. Panzerwagen-Division
		}
		2 = {
			%d. Panzerwagen-Division
		}
		3 = {
			%d. Panzerwagen-Division
		}
		4 = {
			%d. Panzerwagen-Division
		}
		5 = {
			%d. Panzerwagen-Division
		}
		6 = {
			%d. Panzerwagen-Division
		}
		7 = {
			%d. Panzerwagen-Division
		}
		8 = {
			%d. Panzerwagen-Division
		}
		9 = {
			%d. Panzerwagen-Division
		}
		10 = {
			%d. Panzerwagen-Division
		}
	}
}
### Entity: Idea
Component: nav_bomber_pro
Constructs: is_major, removal_cost, cancel_if_invalid, equipment_bonus, build_cost_ic, has_tech, is_coastal
Source: game
File: common/ideas/add_effects_air_doc.txt

Code:
nav_bomber_pro = {
	removal_cost = -1
	cancel_if_invalid = no
	allowed = {

	}
	equipment_bonus = {
		small_plane_naval_bomber_airframe = {
			instant = yes
			build_cost_ic = -0.2
		}
		cv_small_plane_naval_bomber_airframe = {
			instant = yes
			build_cost_ic = -0.2
		}
	}
	ai_will_do = {
		factor = 0
		modifier = {
			factor = 0
			OR = {
				has_tech = base_strike
			}
		} {
			factor = 0
			OR = {
				is_major = no
			}
		} {
			factor = -1
			all_owned_state = {
				OR = {
					is_coastal = no
					dockyard = < 1
				}
			}
		}
	}
}
### Entity: Scripted Effect
Component: EAI_MILITARY_japan_invasions_INVASION_get_data
Constructs: limit, has_country_flag, check_variable, set_temp_variable, clear_temp_array, add_to_temp_array, add_to_temp_variable
Source: game
File: common/scripted_effects/EAI_MILITARY_strategy_INVASION_japan_invasions.txt

Code:
EAI_MILITARY_japan_invasions_INVASION_get_data = {
	if = {
		limit = {
			NOT = {
				check_variable = {
					_started_special_operation_ = -1
				}
			}
		}
		if = {
			limit = {
				has_country_flag = EAI_invasion_operations_logging
			}
			log = [GetYear] [GetMonth] | AI | [This.GetName] | EAI_MILITARY_japan_invasions_INVASION_get_data
		} {
			limit = {
				check_variable = {
					_operation_id = @EAI_MILITARY_operation_australia_INVASION_operation_id
				}
			}
			set_temp_variable = {
				_target_control_pct_ = @EAI_MILITARY_operation_australia_INVASION_target_control_pct
			}
		}
		clear_temp_array = _states_ _staging_areas_ _sea_regions_ _air_regions_ _objectives_
		set_temp_variable = {
			_operation_id = _started_special_operation_
		} {
			index = global.EAI_MAP_japan_invasion_data_start^_operation_id
		}
		while_loop_effect = {
			limit = {
				check_variable = {
					index = < global.EAI_MAP_japan_invasion_data_end^_operation_id
				}
			}
			if = {
				limit = {
					check_variable = {
						index = < global.EAI_MAP_japan_invasion_data_ST_end^_operation_id
					}
				}
				add_to_temp_array = {
					_states_ = global.EAI_MAP_japan_invasion_theatres^index
				}
			}
			else_if = {
				limit = {
					check_variable = {
						index = < global.EAI_MAP_japan_invasion_data_SA_end^_operation_id
					}
				}
				add_to_temp_array = {
					_staging_areas_ = global.EAI_MAP_japan_invasion_theatres^index
				}
			} {
				limit = {
					check_variable = {
						index = < global.EAI_MAP_japan_invasion_data_SR_end^_operation_id
					}
				}
				add_to_temp_array = {
					_sea_regions_ = global.EAI_MAP_japan_invasion_theatres^index
				}
			} {
				limit = {
					check_variable = {
						index = < global.EAI_MAP_japan_invasion_data_AR_end^_operation_id
					}
				}
				add_to_temp_array = {
					_air_regions_ = global.EAI_MAP_japan_invasion_theatres^index
				}
			} {
				limit = {
					check_variable = {
						index = < global.EAI_MAP_japan_invasion_data_OB_end^_operation_id
					}
				}
				add_to_temp_array = {
					_objectives_ = global.EAI_MAP_japan_invasion_theatres^index
				}
			}
			add_to_temp_variable = {
				index = 1
			}
		}
	}
}
### Entity: Unit Leader
Component: media_personality
Constructs: has_idea
Source: game
File: common/unit_leader/00_traits.txt

Code:
media_personality = {
	type = land
	trait_type = personality_trait
	non_shared_modifier = {
		reassignment_duration_factor = 1
	}
	attack_skill_factor = 1
	defense_skill_factor = 1
	new_commander_weight = {
		factor = 1
		modifier = {
			FROM = {
				has_idea = best_of_the_best_spirit
			}
			factor = 0
		} {
			FROM = {
				has_idea = academy_scholarships_spirit
			}
			factor = 0
		} {
			FROM = {
				has_idea = SOV_purged_junior_army_officers_3
			}
			factor = 0
		}
	}
}
### Entity: Event
Component: war_justification.215
Constructs: is_triggered_only
Source: game
File: events/WarJustification.txt

Code:
country_event = {
	id = war_justification.215
	title = war_justification.215.t
	desc = war_justification.215.d
	picture = GFX_report_event_tanks_mexico_city
	is_triggered_only = yes
	option = {
		name = war_justification.215.a
	}
}
### Entity: Military Industrial Organization
Component: INS_koolhoven_organization
Constructs: has_completed_focus, limit, has_country_flag, has_dlc, is_subject_of, is_in_faction_with
Source: game
File: common/military_industrial_organization/organizations/INS_r56_organization.txt

Code:
INS_koolhoven_organization = {
	include = generic_medium_aircraft_organization
	icon = GFX_idea_koolhoven
	allowed = {
		tag = INS
		has_dlc = Arms Against Tyranny
	}
	available = {
		owner = {
			controls_state = 335
			has_completed_focus = INS_the_test_flight_service
			OR = {
				is_subject_of = HOL
				is_in_faction_with = HOL
				has_country_flag = INS_nationalize_koolhoven_flag
			}
		}
	}
	visible = {
		owner = {
			if = {
				limit = {
					OR = {
						has_completed_focus = INS_launch_the_revolution INS_the_coup
						AND = {
							has_completed_focus = INS_kebangkitan INS_demand_volksraad_elections
						}
					}
				}
				has_country_flag = INS_nationalize_koolhoven_flag
			}
		}
	}
}
### Entity: Idea
Component: EAI_DD_9/anti_air_equipment_bonus
Constructs: equipment_bonus, build_cost_ic
Source: game
File: common/ideas/EAI_difficulty_ideas.txt

Code:
EAI_DD_9/anti_air_equipment_bonus = {
	allowed = {
		always = no
	}
	equipment_bonus = {
		anti_air_equipment = {
			build_cost_ic = -0.225
			instant = yes
		}
	}
}
### Entity: Character
Component: JUNO_president_of_the_senate_2
Constructs: stability_factor, democratic_drift
Source: game
File: common/country_leader/toa_traits.txt

Code:
JUNO_president_of_the_senate_2 = {
	random = no
	sprite = 13
	political_power_factor = -0.35
	stability_factor = 0.25
	democratic_drift = 0.08
	political_advisor_cost_factor = -0.5
	drift_defence_factor = 0.3
	ai_will_do = {
		factor = 0
	}
}
### Entity: Character
Component: OCC_ncs
Source: game
File: common/characters/OCC.txt

Code:
OCC_ncs = {
	advisor = {
		slot = high_command
		idea_token = OCC_ncs
		ledger = navy
		allowed = {
			original_tag = OCC
		}
		traits = {
			navy_capital_ship_2
		}
		ai_will_do = {
			factor = 1.0
		}
	}
	portraits = {
		army = {
			small = GFX_idea_generic_navy_asia_2
		}
	}
}
### Entity: Idea
Component: german_advisors
Constructs: has_government, removal_cost
Source: game
File: common/ideas/china.txt

Code:
german_advisors = {
	allowed = {
		always = no
	}
	allowed_civil_war = {
		NOT = {
			has_government = communism
		}
	}
	removal_cost = -1
	modifier = {
		land_doctrine_cost_factor = -0.1
	}
}
### Entity: Modifier Reference
Component: LIE_spirit_of_the_liechtenstein_army_modifier
Constructs: army_defence_factor, army_attack_factor, supply_factor, planning_speed
Source: game
File: common/dynamic_modifiers/LIE.txt

Code:
LIE_spirit_of_the_liechtenstein_army_modifier = {
	enable = {
		always = yes
	}
	icon = GFX_idea_LIE_army_hat
	production_speed_arms_factory_factor = LIE_production_speed_arms_factory_factor
	land_doctrine_cost_factor = LIE_land_doctrine_cost_factor
	naval_doctrine_cost_factor = LIE_naval_doctrine_cost_factor
	army_org_factor = LIE_org_factor
	army_attack_factor = LIE_army_attack_factor
	army_defence_factor = LIE_army_defence_factor
	army_core_defence_factor = LIE_army_core_defence_factor
	supply_factor = LIE_supply_factor
	dig_in_speed_factor = LIE_dig_in_speed_factor
	max_dig_in = LIE_max_dig_in
	command_power_gain_mult = LIE_command_power_gain_mult
	production_speed_bunker_factor = LIE_production_speed_bunker_factor
	production_speed_coastal_bunker_factor = LIE_production_speed_coastal_bunker_factor
	cas_damage_reduction = LIE_cas_damage_reduction
	winter_attrition_factor = LIE_winter_attrition_factor
	army_speed_factor = LIE_army_speed_factor
	planning_speed = LIE_planning_speed
}
### Entity: Scripted Effect
Component: SOV_paranoia_high_decrease_effect
Constructs: limit, has_country_flag, add_to_variable
Source: game
File: common/scripted_effects/SOV_scripted_effects.txt

Code:
SOV_paranoia_high_decrease_effect = {
	if = {
		limit = {
			has_country_flag = SOV_paranoia_system_active_flag
		}
		custom_effect_tooltip = SOV_paranoia_high_decrease_effect_tt
		add_to_variable = {
			SOV_paranoia = SOV_paranoia_high_decrease
		}
		SOV_paranoia_clamp_and_update_ui_effect = yes
	}
}
### Entity: AI Strategy
Component: FRA_unit_production
Source: game
File: common/ai_strategy/FRA.txt

Code:
FRA_unit_production = {
	allowed = {
		original_tag = FRA
	}
	enable = {
		always = yes
	}
	abort = {
		always = no
	}
	ai_strategy = {
		type = role_ratio
		id = garrison
		value = 10
	} {
		type = role_ratio
		id = paratroopers
		value = 0
	} {
		type = role_ratio
		id = mountaineers
		value = 30
	} {
		type = role_ratio
		id = marines
		value = 0
	} {
		type = role_ratio
		id = cavalry
		value = 0
	} {
		type = role_ratio
		id = armor
		value = 5
	} {
		type = role_ratio
		id = infantry
		value = 80
	} {
		type = unit_ratio
		id = fighter
		value = 75
	} {
		type = unit_ratio
		id = cas
		value = 10
	} {
		type = unit_ratio
		id = tactical_bomber
		value = 5
	} {
		type = unit_ratio
		id = strategic_bomber
		value = 5
	} {
		type = unit_ratio
		id = naval_bomber
		value = 5
	} {
		type = unit_ratio
		id = capital_ship
		value = 20
	} {
		type = unit_ratio
		id = submarine
		value = 40
	} {
		type = unit_ratio
		id = screen_ship
		value = 25
	} {
		type = unit_ratio
		id = convoy
		value = 20
	} {
		type = equipment_production_factor
		id = fighter
		value = 20
	} {
		type = equipment_production_factor
		id = infantry
		value = 35
	} {
		type = equipment_production_factor
		id = artillery
		value = 25
	} {
		type = equipment_production_factor
		id = armor
		value = 20
	}
}
### Entity: Joint Focus
Component: INSHOL_hybrid_navy
Constructs: prerequisite, limit, joint_focus, completion_reward, is_subject_of, random_owned_controlled_state, add_extra_state_shared_building_slots, add_building_construction
Source: game
File: common/national_focus/indonesia_joint.txt

Code:
joint_focus = {
	id = INSHOL_hybrid_navy
	icon = GFX_goal_generic_build_navy
	text_icon = INSHOL_INS_focus_style
	available = {
		original_tag = INS
		is_subject_of = HOL
	}
	prerequisite = {
		focus = INSHOL_emergency_naval_purchases
	}
	mutually_exclusive = {
		focus = INSHOL_request_naval_control
	}
	x = -1
	y = 1
	relative_position_id = INSHOL_emergency_naval_purchases
	cost = 5
	search_filters = {
		FOCUS_FILTER_INDUSTRY
	}
	completion_reward = {

	}
	completion_reward_joint_originator = {
		if = {
			limit = {
				original_tag = INS
			}
			random_owned_controlled_state = {
				limit = {
					free_building_slots = {
						building = dockyard
						size = > 0
						include_locked = yes
					}
				}
				prioritize = {
					1058
				}
				add_extra_state_shared_building_slots = 1
				add_building_construction = {
					type = dockyard
					level = 1
					instant_build = yes
				}
			}
		}
		else_if = {
			limit = {
				original_tag = HOL
				INS = {
					is_subject_of = HOL
				}
			}
			random_owned_controlled_state = {
				limit = {
					free_building_slots = {
						building = dockyard
						size = > 0
						include_locked = yes
					}
				}
				prioritize = {
					7
				}
				add_extra_state_shared_building_slots = 1
				add_building_construction = {
					type = dockyard
					level = 1
					instant_build = yes
				}
			}
		}
	}
	completion_reward_joint_member = {
		if = {
			limit = {
				original_tag = INS
			}
			random_owned_controlled_state = {
				limit = {
					free_building_slots = {
						building = dockyard
						size = > 0
						include_locked = yes
					}
				}
				prioritize = {
					1058
				}
				add_extra_state_shared_building_slots = 1
				add_building_construction = {
					type = dockyard
					level = 1
					instant_build = yes
				}
			}
		}
		else_if = {
			limit = {
				original_tag = HOL
				INS = {
					is_subject_of = HOL
				}
			}
			random_owned_controlled_state = {
				limit = {
					free_building_slots = {
						building = dockyard
						size = > 0
						include_locked = yes
					}
				}
				prioritize = {
					7
				}
				add_extra_state_shared_building_slots = 1
				add_building_construction = {
					type = dockyard
					level = 1
					instant_build = yes
				}
			}
		}
	}
}
### Entity: Resistance
Component: sabotage_infrastructure
Constructs: limit, has_variable, check_variable
Source: game
File: common/resistance_activity/resistance_activity.txt

Code:
sabotage_infrastructure = {
	available = {
		non_damaged_building_level = {
			building = infrastructure
			level = > 0
		}
	}
	weight = {
		base = 1
		modifier = {
			has_variable = targeted_sabotage_infrastructure
			check_variable = {
				targeted_sabotage_infrastructure = > 0
			}
			add = 4
		}
	}
	effect = {
		if = {
			limit = {
				has_variable = targeted_sabotage_infrastructure
				check_variable = {
					targeted_sabotage_infrastructure = > 0
				}
			}
			damage_building = {
				type = infrastructure
				damage = 1.0
			}
			subtract_from_variable = {
				var = targeted_sabotage_infrastructure
				value = 1
			}
		}
		else = {
			damage_building = {
				type = infrastructure
				damage = 0.5
			}
		}
	}
	alert_text = building_is_sabotaged
}
### Entity: Modifier Reference
Component: military_appeasement
Source: game
File: common/dynamic_modifiers/0_dynamic_modifiers.txt

Code:
military_appeasement = {
	enable = {
		always = yes
	}
	icon = GFX_modifiers_sabotaged_resource
	resistance_growth = -0.5
}