Losa10/PreTrain-HOI4-Modding-Assistant huggingface dataset:
### Entity: National Focus
Tree: cze_focus
Component: CZE_contact_the_czech_and_slovak_legion
Constructs: division_template, prerequisite, limit, completion_reward, has_capitulated, is_ally_with, has_war_together_with, has_character
Source: game
File: common/national_focus/czechoslovakia_mu.txt

Code:
focus = {
	id = CZE_contact_the_czech_and_slovak_legion
	icon = GFX_focus_generic_manpower
	prerequisite = {
		focus = CZE_enter_exile
	}
	cost = 2
	relative_position_id = CZE_enter_exile
	x = 0
	y = 1
	available_if_capitulated = yes
	available = {
		has_capitulated = yes
		OR = {
			AND = {
				is_ally_with = FRA
				has_war_together_with = FRA
				FRA = {
					has_capitulated = no
				}
			} {
				is_ally_with = POL
				has_war_together_with = POL
				POL = {
					has_capitulated = no
				}
			}
		}
	}
	completion_reward = {
		if = {
			limit = {
				has_character = CZE_josef_shnejdarek
			}
			show_unit_leaders_tooltip = CZE_josef_shnejdarek
		} {
			limit = {
				is_ally_with = POL
				has_war_together_with = POL
				POL = {
					has_capitulated = no
				}
			}
			POL = {
				random_owned_controlled_state = {
					prioritize = {
						10
					}
					create_unit = {
						division = name = "Czech and Slovak Legion" division_template = "Czech and Slovak Legion" start_experience_factor = 1.0
						owner = ROOT
					}
				}
			}
		} {
			limit = {
				is_ally_with = FRA
				has_war_together_with = FRA
				FRA = {
					has_capitulated = no
				}
			}
			FRA = {
				random_owned_controlled_state = {
					prioritize = {
						16
					}
					create_unit = {
						division = name = "Czechoslovak Exile Army" division_template = "Czech and Slovak Legion" start_experience_factor = 1.0
						owner = ROOT
					}
				}
			}
		} {
			limit = {
				is_ally_with = FRA
			}
			add_ace = {
				name = František
				surname = Peřina
				callsign = François
				type = fighter_unique
				is_female = no
			}
		}
		division_template = {
			name = Czech and Slovak Legion
			priority = 2
			regiments = {
				infantry = {
					x = 0
					y = 0
				} {
					x = 0
					y = 1
				} {
					x = 0
					y = 2
				} {
					x = 1
					y = 0
				} {
					x = 1
					y = 1
				} {
					x = 1
					y = 2
				} {
					x = 2
					y = 0
				} {
					x = 2
					y = 1
				} {
					x = 2
					y = 2
				}
			}
			support = {
				engineer = {
					x = 0
					y = 0
				}
				artillery = {
					x = 0
					y = 1
				}
			}
		}
		custom_effect_tooltip = generic_skip_one_line_tt
		add_ace = {
			name = Leopold
			surname = Šrom
			callsign = Orel
			type = fighter_unique
			is_female = no
		} {
			name = Václav
			surname = Jícha
			callsign = Lev
			type = fighter_unique
			is_female = no
		}
		else = {
			a
# ... (truncated)
### Entity: Modding Documentation
Construct: reloadweather
Source: vanilla_docs
File: documentation/console_commands_documentation.md

Doc:
## reloadweather
* Arguments: <randomseed>

Reload and regenerate weather
### Entity: Unit Leader
Component: carrier_officer
Constructs: has_idea, has_dlc
Source: game
File: common/unit_leader/00_traits.txt

Code:
carrier_officer = {
	type = navy
	trait_type = personality_trait
	country_trigger = {
		NOT = {
			OR = {
				has_idea = best_of_the_best_naval_academy_spirit naval_academy_scholarships_spirit SOV_purged_junior_navy_officers_3
			}
		}
	}
	allowed_ship_equipments = {
		ship_hull_carrier
	}
	trait_xp_factor = {
		air_controller = 0.5
		spotter = 0.5
	}
	new_commander_weight = {
		factor = 1
		modifier = {
			FROM = {
				has_idea = best_of_the_best_naval_academy_spirit
			}
			factor = 0
		} {
			FROM = {
				has_idea = naval_academy_scholarships_spirit
			}
			factor = 0
		} {
			FROM = {
				has_idea = SOV_purged_junior_navy_officers_3
			}
			factor = 0
		} {
			FROM = {
				has_dlc = Thunder at Our Gates
			}
			factor = 0
		}
	}
	ai_will_do = {
		factor = 1
	}
}
### Entity: Country History
Country: BRB
Component: BRB_misc
Constructs: set_research_slots, set_convoys, set_country_flag
Source: game
File: history/countries/BRB - Barbados.txt

Code:
# Misc for BRB
capital = 692
set_research_slots = 2
set_convoys = 5
set_country_flag = monroe_doctrine
### Entity: Character
Component: GNA_ncm
Source: game
File: common/characters/GNA.txt

Code:
GNA_ncm = {
	advisor = {
		slot = navy_chief
		idea_token = GNA_ncm
		allowed = {
			original_tag = GNA
		}
		traits = {
			navy_chief_maneuver_2
		}
		ai_will_do = {
			factor = 1.0
		}
	}
	portraits = {
		army = {
			small = GFX_idea_generic_navy_african_3
		}
	}
}
### Entity: Name List
Component: SER
Source: game
File: common/names/00_names.txt

Code:
SER = {
	male = {
		names = {
			Alaksandar Blagoje Bozidar Branko Danilo Dejan Djordje Dragan Dragisa Dragoljub Dragutin Draza Dusan Gavrilo Goran Janko Jovan Koca Kosta Krsto Ljubisa Mihailo Milan Miliutin Milivoje Milojko Milos Miodrag Mirko Miroslav Momcilo Nebojsa Nikola Pavle Peko Petar Radomir Ratko Sava Slobodan Stepa Stojan Veljko Vaselien Vladimir Vojislav Zivojin Zivota Zoran Zvezdan
		}
	}
	female = {
		names = {
			Agata Agatha Barbara Branimira Desislava Dubravka Elena Helen Hicela Jelena Karolina
		}
	}
	surnames = {
		Adzic Arandelovic Belimarkovic Blaznacac Bojovic Bozanovic Bozinovic Brankovic Damjanic Dapcevic Dragutinovic Grujic Hadzilic Horvatovic Isakovic Jankovic Jokic Jovanovic Kadijevic Karadjordjevic Lesjanin Ljubicic Maric Mihailovic Miliutinovic Miloradovic Misic Nad Nedic Novak Obrenovic Ojdanic Panic Paskas Pavkovic Pesic Petrovic Popovic Putnik Radulovic Rasic Sijan Simovic Sokolovic Stepanovic Vasiljevic Veric Vojvodic Vukotic Zivkovic
	}
	callsigns = {

	}
}
### Entity: Trigger Reference
Construct: owns_any_state_of
Source: vanilla_docs
File: documentation/triggers_documentation.md

Doc:
## owns_any_state_of

* Supported Scopes: COUNTRY
* Supported Targets: none

```
Check if the country owns any of the states in the list.
```
### Entity: Country History
Country: DEN
Component: DEN_characters
Constructs: recruit_character
Source: game
File: history/countries/DEN - Denmark.txt

Code:
# Leaders & Characters for DEN
recruit_character = DEN_thorvald_stauning DEN_knud_bach DEN_knud_bach_2 DEN_knud_bach_3 DEN_aksel_larsen DEN_frits_clausen DEN_william_wain_prior DEN_ebbe_gortz DEN_christian_frederik_von_schalburg DEN_hjalmar_rechnitzer DEN_aage_vedel DEN_carl_hammerich DEN_hans_a_rolsted DEN_kaj_birksted DEN_poul_sommer DEN_paul_sommer DEN_hans_lunding DEN_knud_kristensen DEN_ejnar_warum DEN_viggo_kampman
### Entity: Unit Template
Component: KOR_SS_COMMUNIST
Constructs: has_government
Source: game
File: common/units/names_ships/KOR_ship_names.txt

Code:
KOR_SS_COMMUNIST = {
	name = (D)PRK ship names
	for_countries = {
		KOR NKR
	}
	can_use = {
		OR = {
			tag = NKR
			AND = {
				tag = KOR
				has_government = communism
			}
		}
	}
	type = ship
	ship_types = {
		ship_hull_submarine submarine
	}
	prefix = KPNS 
	fallback_name = Submarine %d
	unique = {
		Sinpo Gorae Sang-o Yono Dolgorae 051 Dolgorae 052 Dolgorae 053 Dosan Ahn Changho Ahn Mu Yi Dong-nyeong Lee Bong-chang Son Won Il Jeong Ji An Jung-geun Kim Jwa-jin Yun Bong-gil Yu Gwan-sun Hong Beom-do Lee Beom-seok Shin Dol-seok Jang Bogo Yi Cheon Choe Museon Park Wi Lee Jongmoo Jung Woon Lee Sun-sin Na Dae-yong Yi Eokgi
	}
}
### Entity: National Focus
Tree: spr_focus
Component: SPR_a_red_fleet
Constructs: prerequisite, has_government, completion_reward, is_in_faction_with, add_tech_bonus
Source: game
File: common/national_focus/spain.txt

Code:
focus = {
	id = SPR_a_red_fleet
	available = {
		is_in_faction_with = SOV
		SOV = {
			has_government = communism
		}
	}
	bypass = {

	}
	prerequisite = {
		focus = SPR_slipway_enlargement
	}
	icon = GFX_goal_generic_navy_doctrines_tactics
	x = 0
	y = 1
	relative_position_id = SPR_slipway_enlargement
	cost = 10
	available_if_capitulated = yes
	search_filters = {
		FOCUS_FILTER_RESEARCH
	}
	completion_reward = {
		navy_experience = 50
		add_tech_bonus = {
			name = SPR_a_red_fleet
			bonus = 1
			uses = 1
			category = dd_tech
		} {
			name = SPR_a_red_fleet
			bonus = 1
			uses = 1
			category = ca_tech
		} {
			name = SPR_a_red_fleet
			bonus = 1
			uses = 1
			category = bb_tech
		}
	}
}
### Entity: Scripted Trigger
Component: EAI_SP_sp_nuclear_reactor_focus
Constructs: is_special_project_completed, is_special_project_being_researched
Source: game
File: common/scripted_triggers/EAI_RESEARCH_special_projects_triggers.txt

Code:
EAI_SP_sp_nuclear_reactor_focus = {
	NOT = {
		is_special_project_completed = sp:sp_nuclear_bomb
		is_special_project_being_researched = sp:sp_nuclear_bomb
	}
	EAI_nuclear_tech_focus = yes
}
### Entity: National Focus
Tree: chl_focus
Component: CHL_rockets
Constructs: prerequisite, add_ideas, completion_reward, add_tech_bonus, add_breakthrough_progress
Source: game
File: common/national_focus/r56_chile.txt

Code:
focus = {
	id = CHL_rockets
	icon = GFX_focus_rocketry
	x = -1
	y = 5
	cost = 10
	prerequisite = {
		focus = CHL_jet_focus
	} {
		focus = CHL_universities
	}
	ai_will_do = {
		factor = 1
	}
	completion_reward = {
		add_tech_bonus = {
			name = jet_rocket_bonus
			bonus = 1
			uses = 2
			category = rocketry jet_technology
		}
		custom_effect_tooltip = generic_skip_one_line_tt generic_skip_one_line_tt
		add_breakthrough_progress = {
			specialization = specialization_air
			value = 0.5
		}
		add_ideas = r56_generic_rocket_idea
	}
	search_filters = {
		FOCUS_FILTER_RESEARCH
	}
}
### Entity: Scripted Trigger
Component: EAI_LAW_available_export_focus
Constructs: has_completed_focus, limit, has_idea, has_dlc
Source: game
File: common/scripted_triggers/EAI_COUNTRY_law_triggers.txt

Code:
EAI_LAW_available_export_focus = {
	NOT = {
		has_idea = export_focus
	}
	if = {
		limit = {
			original_tag = CHI
			has_dlc = Waking the Tiger
		}
		NOT = {
			has_idea = CHI_nine_power_treaty
		}
	} {
		limit = {
			original_tag = SPR
			has_dlc = La Resistance
		}
		NOT = {
			has_completed_focus = SPR_all_must_bear_the_torch
		}
	} {
		limit = {
			original_tag = GER
		}
		NOT = {
			has_completed_focus = GER_autarky_efforts
		}
	} {
		limit = {
			original_tag = PRC
			has_dlc = No Compromise, No Surrender
		}
		NOT = {
			has_completed_focus = PRC_promote_paper_bills
		}
	}
}
### Entity: Modding Documentation
Construct: ai_strategy_decrypt_target
Source: vanilla_docs
File: documentation/dynamic_variables_documentation.md

Doc:
### ai_strategy_decrypt_target
* description: ai strategy value decrypt_target against country. Example: GER.ai_strategy_decrypt_target@ENG
### Entity: Event
Component: WW_hungary.6
Constructs: is_triggered_only, ai_chance, add_war_support, add_stability, fire_only_once, declare_war_on, take_state_focus, remove_state_claim
Source: game
File: events/WUW_Hungary.txt

Code:
country_event = {
	id = WW_hungary.6
	title = WW_hungary.6.t
	desc = WW_hungary.6.desc
	picture = GFX_report_event_vienna_award_hungary
	is_triggered_only = yes
	fire_only_once = yes
	option = {
		name = WW_hungary.6.a
		ai_chance = {
			base = 50
		}
		declare_war_on = {
			target = FROM
			type = take_state_focus
			generator = {
				76 83 84
			}
		}
	} {
		name = WW_hungary.6.b
		ai_chance = {
			base = 50
		}
		add_stability = -0.1
		add_war_support = -0.05
		remove_state_claim = 76 83 84
		add_threat = -1
	}
}
### Entity: Idea
Component: ITA_iri_fake_ns
Constructs: removal_cost
Source: game
File: common/ideas/italy.txt

Code:
ITA_iri_fake_ns = {
	name = ITA_ricostruzione_industriale_dynamic_modifier
	removal_cost = -1
	picture = SOV_third_five_year_plan_civilian
	allowed = {
		always = no
	}
	modifier = {
		production_speed_industrial_complex_factor = 0.05
		industrial_concern_cost_factor = -0.35
		tank_manufacturer_cost_factor = -0.15
		materiel_manufacturer_cost_factor = -0.15
		aircraft_manufacturer_cost_factor = -0.15
		naval_manufacturer_cost_factor = -0.15
	}
}
### Entity: National Focus
Tree: pal_focus
Component: PAL_golani_assumes_power
Constructs: prerequisite, completion_reward, add_political_power, has_idea, add_country_leader_role
Source: game
File: common/national_focus/palestine.txt

Code:
focus = {
	id = PAL_golani_assumes_power
	icon = GFX_focus_ITA_comandante_diavolo
	x = -1
	y = 1
	prerequisite = {
		focus = PAL_cooperate_with_the_ccnjp
	} {
		focus = PAL_second_hebron_march
	}
	available = {
		OR = {
			has_idea = PAL_medium_civilian_power_idea PAL_high_civilian_power_idea
		}
	}
	cost = 5
	relative_position_id = PAL_cooperate_with_the_ccnjp
	completion_reward = {
		add_country_leader_role = {
			character = PAL_abdulhalim_algolani
			promote_leader = yes
			country_leader = {
				ideology = fascism_ideology
				expire = 1965.1.1.1
				traits = {
					popular_figurehead
				}
			}
		}
		add_political_power = 100
	}
	ai_will_do = {
		factor = 1000
	}
}
### Entity: AI Strategy
Component: RAJ_communist_agrarian_dont_waste_focus_bonuses
Constructs: has_completed_focus, has_country_flag, has_game_rule, build_army
Source: game
File: common/ai_strategy/RAJ.txt

Code:
RAJ_communist_agrarian_dont_waste_focus_bonuses = {
	allowed = {
		original_tag = RAJ
		OR = {
			has_country_flag = RAJ_AI_RANDOM_INDIA_COMMUNISM
			has_game_rule = {
				rule = RAJ_ai_behavior
				option = GOE_INDIA_COMMUNISM
			}
		}
	}
	enable = {
		has_completed_focus = RAJ_every_man_a_leader
	}
	abort = {
		always = no
	}
	ai_strategy = {
		type = research_weight_factor
		id = tech_mountaineers
		value = 2000000
	} {
		type = build_army
		id = mountaineers
		value = 100
	}
}
### Entity: Country History
Country: GER
Component: GER_characters
Constructs: recruit_character
Source: game
File: history/countries/GER - Germany.txt

Code:
# Leaders & Characters for GER
recruit_character = GER_wilhelm_pieck GER_konrad_adenauer GER_adolf_hitler GER_albert_kesselring GER_alfred_jodl GER_alfred_saalwachter GER_erhard_milch GER_erich_bey GER_erich_raeder GER_erich_von_manstein GER_ernst_udet GER_ernsteberhard_hell GER_erwin_rommel GER_erwin_von_witzleben GER_ewald_von_kleist GER_fedor_von_bock GER_felix_steiner GER_ferdinand_schorner GER_franz_halder GER_friedrich_paulus GER_friedrich_schulz GER_georg_von_kuchler GER_georghans_reinhardt GER_gerd_von_rundstedt GER_hermann_goring GER_gotthard_heinrici GER_gunther_lutjens GER_gunther_von_kluge GER_hasso_von_manteuffel GER_heinz_guderian GER_heisenberg GER_hermann_boehm GER_hermann_hoth GER_hugo_sperrle GER_johannes_blaskowitz GER_karl_donitz GER_kurt_student GER_ludwig_beck GER_maximilian_von_weichs GER_otto_ciliax GER_paul_hausser GER_ritter_von_greim GER_sepp_dietrich GER_viktor_schutze GER_von_braun GER_walter_kruger GER_walter_model GER_walther_von_brauchitsch GER_walther_wever GER_werner_von_fritsch GER_wilhelm_keitel GER_wilhelm_list GER_wilhelm_marschall GER_wilhelm_ritter_von_leeb GER_wolfram_von_richthofen GER_heinrich_himmler GER_walther_funk GER_hjalmar_schacht GER_julius_leber GER_albert_speer GER_hans_oster GER_theodor_heuss GER_fritz_todt GER_joachim_von_ribbentrop GER_ernst_thalmann GER_rudolf_hess GER_martin_bormann GER_wilhelm_canaris GER_joseph_goebbels GER_konstantin_von_neurath GER_alfred_hugenberg GER_kurt_schumacher GER_wilhelm_ii GER_wilhelm_iii GER_victoria GER_august_von_mackensen GER_alexander_von_falkenhausen GER_werner_von_blomberg GER_oswald_lutz GER_walther_nehring GER_hans_krebs GER_rolf_carls GER_helmuth_wilberg GER_josef_kammhuber GER_robert_knauss GER_alfred_becker GER_walter_dornberger GER_alfred_rosenberg GER_reinhard_heydrich GER_leni_riefenstahl GER_franz_seldte GER_hanns_kerrl GER_ludwig_erhard GER_paul_von_lettow_vorbeck GER_carl_friedrich_goerdeler GER_wilhelm_iv GER_eva_braun GER_peter_adolf_thiessen GER_gustav_ludwig_hertz GER_eduard_grote GER_ferdinand_porsche GER_erwin_aders GER_hermann_burkhardt GER_ulrich_gabler GER_hans_von_ohain GER_max_kramer GER_kurt_tank GER_hellmuth_walter GER_manfred_von_ardenne GER_konrad_zuse
### Entity: AI Strategy
Component: EAI_GER_avoid_southern_africa
Constructs: is_historical_focus_on
Source: game
File: common/ai_strategy/GER_EAI.txt

Code:
EAI_GER_avoid_southern_africa = {
	allowed = {
		tag = GER
	}
	enable = {
		is_historical_focus_on = yes
		enemies_naval_strength_ratio = > 1.0
	}
	abort_when_not_enabled = yes
	ai_strategy = {
		type = front_unit_request
		value = -1000
		area = EAI_southern_africa
	}
}
### Entity: Character
Component: small_tank_producer_offense_0
Constructs: equipment_bonus, maximum_speed
Source: game
File: common/country_leader/r56_companies_traits.txt

Code:
small_tank_producer_offense_0 = {
	random = no
	equipment_bonus = {
		light_tank_chassis = {
			breakthrough = 0.05
			maximum_speed = 0.05
		}
		light_tank_artillery_chassis = {
			breakthrough = 0.05
			maximum_speed = 0.05
		}
		light_tank_destroyer_chassis = {
			breakthrough = 0.05
			maximum_speed = 0.05
		}
		light_tank_aa_chassis = {
			breakthrough = 0.05
			maximum_speed = 0.05
		}
	}
	ai_will_do = {
		factor = 1
	}
}
### Entity: Event
Component: axis_minors_slovakia.4
Constructs: is_triggered_only, limit, add_war_support, add_political_power, is_border_conflict, set_border_war, add_manpower
Source: game
File: events/r56_slovakia.txt

Code:
country_event = {
	id = axis_minors_slovakia.4
	title = axis_minors_slovakia.4.t
	desc = axis_minors_slovakia.4.desc
	picture = GFX_report_event_hungarian_soldiers
	is_triggered_only = yes
	trigger = {
		tag = HUN
	}
	immediate = {
		hidden_effect = {
			71 = {
				if = {
					limit = {
						is_border_conflict = yes
					}
					set_border_war = no
				}
			}
			73 = {
				if = {
					limit = {
						is_border_conflict = yes
					}
					set_border_war = no
				}
			}
			664 = {
				if = {
					limit = {
						is_border_conflict = yes
					}
					set_border_war = no
				}
			}
		}
	}
	option = {
		name = axis_minors_slovakia.4.a
		add_political_power = -100
		add_war_support = -0.05
		add_manpower = -328
		army_experience = 10
		air_experience = 1
		SLO = {
			country_event = {
				id = axis_minors_slovakia.5
			}
		}
	}
}
### Entity: Event
Component: CZE.326
Constructs: is_triggered_only, add_opinion_modifier
Source: game
File: events/CZE_Czechoslovakia.txt

Code:
country_event = {
	id = CZE.326
	title = CZE.326.t
	desc = CZE.326.d
	picture = GFX_report_event_finnish_letter
	is_triggered_only = yes
	option = {
		name = CZE.326.a
		add_opinion_modifier = {
			target = POL
			modifier = CZE_soviet_treaties_negative
		}
	}
}
### Entity: AI Strategy
Component: EAI_PROD_NAVY_prioritise_convoys_SOV
Constructs: has_global_flag
Source: game
File: common/ai_strategy/EAI_PRODUCTION_navy_strategies.txt

Code:
EAI_PROD_NAVY_prioritise_convoys_SOV = {
	enable = {
		original_tag = SOV
		num_of_naval_factories = > 1
		stockpile_ratio = {
			archetype = convoy
			ratio = < 500
		}
		EAI_wants_to_build_ships = yes
		NOT = {
			has_global_flag = EAI_free_convoys
		}
	}
	abort = {
		NOT = {
			AND = {
				EAI_major_country = yes
				stockpile_ratio = {
					archetype = convoy
					ratio = < 800
				}
				EAI_wants_to_build_ships = yes
				NOT = {
					has_global_flag = EAI_free_convoys
				}
			}
		}
	}
	ai_strategy = {
		type = equipment_production_min_factories
		id = convoy
		value = 10
	}
}
### Entity: National Focus
Tree: bel_focus
Component: BEL_begin_rearmement
Constructs: has_government, completion_reward, add_doctrine_cost_reduction
Source: game
File: common/national_focus/r56_belgium.txt

Code:
focus = {
	id = BEL_begin_rearmement
	icon = GFX_goal_BEL_coa_army
	mutually_exclusive = {
		focus = BEL_accept_van_den_den_bergen_plan
	}
	relative_position_id = BEL_urban_projects_capital
	x = 9
	y = 0
	cost = 7.2
	ai_will_do = {
		base = 6
		modifier = {
			factor = 2
			has_government = fascism
		} {
			factor = 3
			threat = > 0.2
		}
	}
	completion_reward = {
		army_experience = 5
		add_doctrine_cost_reduction = {
			name = land_doc_bonus
			cost_reduction = 0.5
			uses = 1
			category = land_doctrine
		}
	}
	search_filters = {
		FOCUS_FILTER_RESEARCH FOCUS_FILTER_HISTORICAL
	}
}
### Entity: Character
Component: scientist_trait_jet_expert
Source: game
File: common/scientist_traits/00_traits.txt

Code:
scientist_trait_jet_expert = {
	specialization = {
		specialization_air
	}
	modifier = {
		sp_tag_jet_speed_factor = 0.1
	}
}
### Entity: Scripted Effect
Component: EAI_PC_get_total_building_level
Constructs: limit, has_country_flag, check_variable, set_temp_variable, add_to_temp_variable
Source: game
File: common/scripted_effects/EAI_CONSTRUCTION_PRIORITY_effects.txt

Code:
EAI_PC_get_total_building_level = {
	if = {
		limit = {
			PREV = {
				has_country_flag = EAI_PC_trace_functions
			}
		}
		log = EAI_PC_get_total_building_level > THIS=[this.getname] PREV=[prev.getname] _project_building_type=[?_project_building_type] _project_province_id=[?_project_province_id]
	} {
		limit = {
			check_variable = {
				_project_building_type = global.EAI_PC_INF
			}
		}
		set_temp_variable = {
			building_level_ = building_level@infrastructure
		}
		EAI_PC_get_num_queued_buildings_at_target = yes
		add_to_temp_variable = {
			building_level_ = queued_amount_
		}
	}
	set_temp_variable = {
		building_level_ = 0
	}
	else_if = {
		limit = {
			check_variable = {
				_project_building_type = global.EAI_PC_AIR
			}
		}
		set_temp_variable = {
			building_level_ = building_level@air_base
		}
		EAI_PC_get_num_queued_buildings_at_target = yes
		add_to_temp_variable = {
			building_level_ = queued_amount_
		}
	} {
		limit = {
			check_variable = {
				_project_building_type = global.EAI_PC_AA
			}
		}
		set_temp_variable = {
			building_level_ = building_level@anti_air_building
		}
		EAI_PC_get_num_queued_buildings_at_target = yes
		add_to_temp_variable = {
			building_level_ = queued_amount_
		}
	} {
		limit = {
			check_variable = {
				_project_building_type = global.EAI_PC_RADAR
			}
		}
		set_temp_variable = {
			building_level_ = building_level@radar_station
		}
		EAI_PC_get_num_queued_buildings_at_target = yes
		add_to_temp_variable = {
			building_level_ = queued_amount_
		}
	} {
		limit = {
			check_variable = {
				_project_building_type = global.EAI_PC_MIC
			}
		}
		set_temp_variable = {
			building_level_ = building_level@arms_factory
		}
		EAI_PC_get_num_queued_buildings_at_target = yes
		add_to_temp_variable = {
			building_level_ = queued_amount_
		}
	} {
		limit = {
			check_variable = {
				_project_building_type = global.EAI_PC_CIC
			}
		}
		set_temp_variable = {
			building_level_ = building_level@industrial_complex
		}
		EAI_PC_get_num_queued_buildings_at_target = yes
		add_to_temp_variable = {
			building_level_ = queued_amount_
		}
	} {
		limit = {
			check_variable = {
				_project_building_type = global.EAI_PC_NIC
			}
		}
		set_temp_variable = {
			building_level_ = building_level@dockyard
		}
		EAI_PC_get_num_queued_buildings_at_target = yes
		add_to_temp_variable = {
			building_level_ = queued_amount_
		}
	} {
		limit
# ... (truncated)
### Entity: AI Strategy
Component: EAI_garrison_role
Constructs: has_country_flag, has_army_experience
Source: game
File: common/ai_templates/EAI_garrison_role.txt

Code:
EAI_garrison_role = {
	role = area_defense
	upgrade_prio = {
		base = 0
		modifier = {
			add = 1000
			has_army_experience = > 100
		}
	}
	GARRISON_TEMPLATE_CHEAP = {
		enable = {
			has_country_flag = {
				flag = EAI_GARRISON_TEMPLATE
				value = 1
			}
		}
		upgrade_prio = {
			base = 10
		}
		reinforce_prio = 0
		target_template = {
			regiments = {
				infantry = 5
			}
		}
	}
	GARRISON_TEMPLATE_REGULAR = {
		enable = {
			has_country_flag = {
				flag = EAI_GARRISON_TEMPLATE
				value = 2
			}
		}
		upgrade_prio = {
			base = 10
		}
		reinforce_prio = 0
		target_template = {
			regiments = {
				infantry = 9
			}
			support = {
				artillery = 1
			}
		}
	}
	GARRISON_TEMPLATE_EXPENSIVE = {
		enable = {
			has_country_flag = {
				flag = EAI_GARRISON_TEMPLATE
				value = 3
			}
		}
		upgrade_prio = {
			base = 10
		}
		reinforce_prio = 0
		target_template = {
			regiments = {
				infantry = 9
			}
			support = {
				engineer = 1
				artillery = 1
			}
		}
	}
}
### Entity: Order of Battle
Component: instant_effect
Constructs: add_equipment_production
Source: game
File: history/units/IRQ_1939.txt

Code:
instant_effect = {
	add_equipment_production = {
		equipment = {
			type = infantry_equipment_1
			creator = IRQ
		}
		requested_factories = 1
		progress = 0.38
		efficiency = 100
	}
}