establish_the_atri_special_brigade = { #招募亚托莉特种旅团
	组建亚托莉特种旅 = {		
		visible = {
			has_country_flag = have_ATRI
		}
		fire_only_once = yes
		cost = 0
		days_remove = 30

		remove_effect = {
			custom_effect_tooltip = 获得亚托莉特种步兵旅编制
			custom_effect_tooltip = 获得亚托莉装甲合成旅编制
			hidden_effect = {
				division_template = {
						name = "独立亚托莉步兵旅"
						is_locked = yes
						force_allow_recruiting = yes
						division_cap = 12
						regiments = {
							atri_infantry = { x = 0 y = 0 }
							atri_infantry = { x = 0 y = 1 }
							atri_infantry = { x = 0 y = 2 }
							atri_infantry = { x = 0 y = 3 }
							atri_infantry = { x = 0 y = 4 }
						}	
						support = {
							atri_recon = { x = 0 y = 1 }
						}
					}
					random_owned_controlled_state = {
						limit = { is_in_home_area = yes }
						create_unit = {
							division =  "gfx/counters/atri_infantry_icon.dds"
							owner = ROOT
						}
					}
				division_template = {
					name = "独立亚托莉装甲合成旅"
					is_locked = yes
					force_allow_recruiting = yes
					division_cap = 3
					regiments = {
						atri_infantry = { x = 0 y = 0 }
						atri_infantry = { x = 0 y = 1 }
						atri_infantry = { x = 0 y = 2 }
						atri_infantry = { x = 0 y = 3 }
						atri_heavy_armor = { x = 1 y = 0 }
						atri_heavy_armor = { x = 1 y = 1 }
						atri_medium_armor = { x = 2 y = 0 }
						atri_medium_armor = { x = 2 y = 1 }
						atri_medium_armor = { x = 2 y = 2 }
					}
					support = {
						atri_engineer = { x = 0 y = 0 }
						atri_recon = { x = 0 y = 1 }
					}
				}
				random_owned_controlled_state = {
					limit = { is_in_home_area = yes }
					create_unit = {
						division =  "gfx/counters/atri_heavy_armor_icon.dds"
						owner = ROOT
					}
				}
				division_template = {
					name = "独立亚托莉装甲合成旅"
					is_locked = yes
					force_allow_recruiting = yes
					division_cap = 3
					regiments = {
						atri_mechanized = { x = 0 y = 0 }
						atri_mechanized = { x = 0 y = 1 }
						atri_mechanized = { x = 0 y = 2 }
						atri_mechanized = { x = 1 y = 0 }
						atri_mechanized = { x = 1 y = 1 }
						atri_modern_armor = { x = 2 y = 0 }
						atri_modern_armor = { x = 2 y = 1 }
						atri_modern_armor = { x = 3 y = 0 }
						atri_modern_armor = { x = 3 y = 1 }
						atri_modern_armor = { x = 3 y = 2 }
					}
					support = {
						atri_engineer = { x = 0 y = 0 }
						atri_recon = { x = 0 y = 1 }
						field_hospital = { x = 0 y = 2 }
						signal_company = { x = 0 y = 3 }
						logistics_company = { x = 0 y = 4 }
					}
				}
				random_owned_controlled_state = {
					limit = { is_in_home_area = yes }
					create_unit = {
						division =  "gfx/counters/atri_modern_armor_icon.dds"
						owner = ROOT
					}
				}
			}

		}
	}
}

atri_heading_utopia = {
	yz_ATRI_start_utopia_plan = {
		#name = YUZ_integrate_fans
		icon = generic_nationalism
		available = {
			always = yes
		}
		fire_only_once = yes
		complete_effect = {
			set_country_flag = atri_start_plan
			custom_effect_tooltip = atri_start_plan_tt
		}
	}

	yz_ATRI_expand_buildings = {
		#name = YUZ_integrate_fans
		icon = generic_nationalism
		allowed = {
			always = yes
		}

		available = {
			check_variable = {
				yz_money > 100
				tooltip = yz_money_tooltip_compare
			}
			has_country_flag = have_ATRI
			has_country_flag = atri_start_plan
			has_country_flag = finished_yoshino_industry
			has_country_flag = finished_megulu_industry
			has_equipment = { atri_equipment_1 > 4 }
			num_of_civilian_factories_available_for_projects > 9
		}

		state_target = yes

		on_map_mode = map_only

		#targets = {  }

		target_array = controlled_states

		target_trigger = {
			check_variable = {
				yz_money > 100
				tooltip = yz_money_tooltip_compare
			}
			has_country_flag = have_ATRI
			has_country_flag = atri_start_plan
			has_country_flag = finished_yoshino_industry
			has_country_flag = finished_megulu_industry
			has_equipment = { atri_equipment_1 > 4 }
			num_of_civilian_factories_available_for_projects > 9
			FROM = {
				OR = {
					is_island_state = yes
					is_core_of = ROOT
					compliance > 30
				}
			}
		}

		cost = 10

		#fire_only_once = yes

		days_remove = 30


		visible = {
			has_country_flag = have_ATRI
			has_country_flag = atri_start_plan
			has_country_flag = finished_yoshino_industry
			has_country_flag = finished_megulu_industry
		}

		complete_effect = {
			add_to_variable = { yz_money = -100 }
				add_equipment_to_stockpile = {
					type = atri_equipment_1
					amount = -5                  #是在当地融入生活了，不是死了
					producer = ROOT
				}
		}
		modifier = {
			civilian_factory_use = 10
		}

		remove_effect = {
			FROM = {
				add_extra_state_shared_building_slots = 2
			}
		}
	}

	yz_ATRI_improve_living_condition = {

		#name = YUZ_integrate_fans

		icon = generic_nationalism

		allowed = {
			always = yes
		}

		available = {
			check_variable = {
				yz_money > 100
				tooltip = yz_money_tooltip_compare
			}
			has_country_flag = have_ATRI
			has_country_flag = atri_start_plan
			has_country_flag = finished_yoshino_industry
			has_country_flag = finished_megulu_industry
			has_equipment = { atri_equipment_1 > 4 }
			num_of_civilian_factories_available_for_projects > 9
		}

		state_target = yes

		on_map_mode = map_only

		#targets = {  }

		target_array = controlled_states

		target_trigger = {
			check_variable = {
				yz_money > 100
				tooltip = yz_money_tooltip_compare
			}
			has_country_flag = have_ATRI
			has_country_flag = atri_start_plan
			has_country_flag = finished_yoshino_industry
			has_country_flag = finished_megulu_industry
			has_equipment = { atri_equipment_1 > 4 }
			num_of_civilian_factories_available_for_projects > 9
			FROM = {
				OR = {
					is_island_state = yes
					is_core_of = ROOT
					compliance > 30
				}
			}
		}

		cost = 10

		#fire_only_once = yes

		days_remove = 30


		visible = {
			has_country_flag = have_ATRI
			has_country_flag = atri_start_plan
			has_country_flag = finished_yoshino_industry
			has_country_flag = finished_megulu_industry
		}

		complete_effect = {
			add_to_variable = { yz_money = -100 }
				add_equipment_to_stockpile = {
					type = atri_equipment_1
					amount = -5                  #是在当地融入生活了，不是死了
					producer = ROOT
				}
		}
		modifier = {
			civilian_factory_use = 10
		}

		remove_effect = {
			FROM = {
				add_manpower = 50000
			}
		}
	}

}