#####################

 ## #  # ### ###   ## 
#   #  #  #  #  # #   
 #  ####  #  ###   #  
  # #  #  #  #      # 
##  #  # ### #    ##  
 
#####################

DKR_oceanic_ships_organization = {
	include = generic_battle_line_ship_organization
	icon = GFX_DKR_oceanic_ships_manufacturer
	
	allowed = {	
		tag = DKR 
	}
	
	available = {
		FROM = {
			has_completed_focus = DKR_orgainze_war_syndicates
		}
	}
}

DKR_coastal_ships_organization = {
	include = generic_black_sea_fleet_organization
	icon = GFX_idea_DKR_coastal_ships_manufacturer
	
	allowed = {	
		tag = DKR 
	}
	
	available = {
		FROM = {
			has_completed_focus = DKR_orgainze_war_syndicates
		}
	}

}


###########################

###  #    ##  #  # ###  ## 
#  # #   #  # ## # #   #   
###  #   #### # ## ##   #  
#    #   #  # #  # #     # 
#    ### #  # #  # ### ##  

###########################

DKR_light_avia_organization = {
	include = generic_light_aircraft_organization
	icon = GFX_idea_DKR_light_aviamanufacturer
	
	allowed = {	
		tag = DKR
	}
	
	available = {
		FROM = {
			has_completed_focus = DKR_orgainze_war_syndicates
		}
	}
	
	add_trait = {
		token = GER_mio_trait_maintenance_first_design
		name = GER_mio_trait_maintenance_first_design

		icon = GFX_generic_mio_department_icon_plane_fighter_line_efficiency
		special_trait_background = yes
		
		position = { x=-2 y=1 }
		relative_position_id = generic_mio_trait_expanded_production_facilities

		all_parents = { generic_mio_trait_expanded_production_facilities }

		equipment_bonus = {
			reliability = 0.05
		}

		production_bonus = {
			production_efficiency_gain_factor = 0.05
		}
	}
	
	add_trait = {
		token = generic_mio_trait_hardened_frames
		name = generic_mio_trait_hardened_frames
		
		icon = GFX_generic_mio_trait_icon_defense
		special_trait_background = yes

		position = { x=0 y=1 }
		relative_position_id = GER_mio_trait_maintenance_first_design
	
		all_parents = { GER_mio_trait_maintenance_first_design }

		limit_to_equipment_type = { mio_cat_eq_all_small_plane }

		equipment_bonus = {
			air_defence = 0.05
		}
	}
}

DKR_heavy_avia_organization = {
	include = UKR_Aviant_organization
	icon = GFX_idea_DKR_heavy_aviamanufacturer
	
	allowed = {	
		tag = DKR 
	}

	available = {
		FROM = {
			has_completed_focus = DKR_orgainze_war_syndicates
		}
	}
}

################################### 

#   #  ##  ### ### ###  ### ### #   
## ## #  #  #  #   #  #  #  #   #   
# # # ####  #  ##  ###   #  ##  #   
#   # #  #  #  #   #  #  #  #   #   
#   # #  #  #  ### #  # ### ### ### 


###################################

DKR_ugs_organization = {
	icon = GFX_idea_DKR_ugs
	
	allowed = {	
		tag = DKR 
	}
	
	available = {
		FROM = {
			has_completed_focus = DKR_orgainze_war_syndicates
		}
	}

	equipment_type = {
		infantry_equipment
		support_equipment
		artillery_equipment
		anti_tank_equipment
		anti_air_equipment
	}
	research_categories = { infantry_weapons support_tech mio_cat_all_artillery_equipment }

	

	tree_header_text = {
		text = DKR_mio_header_infantry_weapon
		x = 2
	}

	tree_header_text = {
		text = DKR_mio_header_artillery
		x = 6
	}

	tree_header_text = {
		text = mio_header_support
		x = 8
	}

	initial_trait = {
		name = DKR_mio_initial_trait_ugs

		organization_modifier = {
			military_industrial_organization_research_bonus = 0.05
		}

		production_bonus = {
			production_efficiency_cap_factor = 0.03
		}

		equipment_bonus = {
			soft_attack = 0.03
		}
	}

	trait = {
		token = generic_mio_trait_drum_pattern_sights
		name = generic_mio_trait_drum_pattern_sights
		icon = GFX_generic_mio_trait_icon_defense

		position = { x=0 y=0 }

		limit_to_equipment_type = {
			infantry_equipment
		}

		equipment_bonus = {
			defense = 0.035
		}
	}

	trait = {
		token = generic_mio_trait_reinforced_stocks
		name = generic_mio_trait_reinforced_stocks
		icon = GFX_generic_mio_trait_icon_reliability

		position = { x=2 y=0 }
		relative_position_id = generic_mio_trait_drum_pattern_sights

		limit_to_equipment_type = {
			infantry_equipment
		}

		equipment_bonus = {
			soft_attack = 0.025
			reliability = 0.03
		}
	}

	trait = {
		token = generic_mio_trait_bolt_action
		name = generic_mio_trait_bolt_action
		icon = GFX_generic_mio_department_icon_infantry_line_efficiency

		position = { x=-1 y=2 }
		relative_position_id = generic_mio_trait_reinforced_stocks

		all_parents = { generic_mio_trait_reinforced_stocks }

		mutually_exclusive = { generic_mio_trait_semi_auto }

		limit_to_equipment_type = {
			infantry_equipment
		}

		equipment_bonus = {
			soft_attack = -0.03
		}

		production_bonus = {
			production_efficiency_gain_factor = 0.05
		}
	}

	trait = {
		token = generic_mio_trait_semi_auto
		name = generic_mio_trait_semi_auto
		icon = GFX_generic_mio_trait_icon_soft_attack

		position = { x=1 y=2 }
		relative_position_id = generic_mio_trait_reinforced_stocks

		all_parents = { generic_mio_trait_reinforced_stocks }

		mutually_exclusive = { generic_mio_trait_bolt_action }

		limit_to_equipment_type = {
			infantry_equipment
		}

		equipment_bonus = {
			soft_attack = 0.03
			breakthrough = 0.03
		}

		production_bonus = {
			production_efficiency_gain_factor = -0.05
		}
	}

	trait = {
		token = generic_mio_trait_medium_machineguns
		name = generic_mio_trait_medium_machineguns
		icon = GFX_generic_mio_trait_icon_breakthrough

		position = { x=1 y=2 }
		relative_position_id = generic_mio_trait_bolt_action

		any_parent = { generic_mio_trait_semi_auto generic_mio_trait_bolt_action }

		limit_to_equipment_type = {
			infantry_equipment
		}
		
		equipment_bonus = {
			breakthrough = 0.06
			build_cost_ic = 0.08
		}
	}

	trait = {
		token = generic_mio_trait_advanced_barrel_forging
		name = generic_mio_trait_advanced_barrel_forging
		icon = GFX_generic_mio_trait_icon_efficiency_gain

		position = { x=2 y=2 }
		relative_position_id = generic_mio_trait_reinforced_stocks

		any_parent = { generic_mio_trait_reinforced_stocks generic_mio_trait_drum_pattern_sights generic_mio_trait_mobile_limbers generic_mio_trait_stable_platforms }

		limit_to_equipment_type = {
			infantry_equipment
			artillery_equipment
			anti_air_equipment
			anti_tank_equipment
		}

		production_bonus = {
			production_efficiency_gain_factor = 0.03
		}
	}

	trait = {
		token = generic_mio_trait_mass_rifle_production
		name = DKR_mio_trait_mass_weapons_production
		icon = GFX_generic_mio_department_icon_facilities

		position = { x=0 y=2 }
		relative_position_id = generic_mio_trait_advanced_barrel_forging

		all_parents = { generic_mio_trait_advanced_barrel_forging }

		production_bonus = {
			production_efficiency_cap_factor = 0.03
			production_cost_factor = -0.03
		}

		limit_to_equipment_type = {
			infantry_equipment
			artillery_equipment
			anti_air_equipment
			anti_tank_equipment
		}

		organization_modifier = {
			military_industrial_organization_design_team_assign_cost = -0.25
		}
	}


	trait = {
		token = generic_mio_trait_quality_materials
		name = generic_mio_trait_quality_materials
		icon = GFX_generic_mio_trait_icon_reliability

		position = { x=0 y=2 }
		relative_position_id = generic_mio_trait_drum_pattern_sights

		all_parents = { generic_mio_trait_drum_pattern_sights }

		limit_to_equipment_type = {
			infantry_equipment
		}

		equipment_bonus = {
			reliability = 0.05
		}

	}

	trait = {
		token = generic_mio_trait_armor_piercing_rounds
		name = generic_mio_trait_armor_piercing_rounds
		icon = GFX_generic_mio_trait_icon_ap_attack

		position = { x=0 y=2 }
		relative_position_id = generic_mio_trait_quality_materials

		all_parents = { generic_mio_trait_quality_materials }

		limit_to_equipment_type = {
			infantry_equipment
		}
		
		equipment_bonus = {
			ap_attack = 0.25
			hard_attack = 0.10
		}
	}

	trait = {
		token = generic_mio_trait_mobile_limbers
		name = generic_mio_trait_mobile_limbers
		icon = GFX_generic_mio_trait_icon_breakthrough

		position = { x=5 y=0 }
		relative_position_id = generic_mio_trait_drum_pattern_sights
		mutually_exclusive = { generic_mio_trait_stable_platforms }

		limit_to_equipment_type = {
			artillery_equipment
			anti_air_equipment
			anti_tank_equipment
		}

		equipment_bonus = {
			breakthrough = 0.1
		}
	}

	trait = {
		token = generic_mio_trait_stable_platforms
		name = generic_mio_trait_stable_platforms
		icon = GFX_generic_mio_trait_icon_defense

		position = { x=7 y=0 }
		relative_position_id = generic_mio_trait_drum_pattern_sights

		mutually_exclusive = { generic_mio_trait_mobile_limbers }

		limit_to_equipment_type = {
			artillery_equipment
			anti_air_equipment
			anti_tank_equipment
		}

		equipment_bonus = {
			defense = 0.03
		}
	}

	trait = {
		token = generic_mio_trait_improved_hydraulic_recoil_system
		name = generic_mio_trait_improved_hydraulic_recoil_system
		icon = GFX_generic_mio_trait_icon_reliability

		position = { x=1 y=1 }
		relative_position_id = generic_mio_trait_mobile_limbers

		any_parent = {
			generic_mio_trait_stable_platforms
			generic_mio_trait_mobile_limbers
		}

		limit_to_equipment_type = {
			artillery_equipment
			anti_air_equipment
			anti_tank_equipment
		}

		equipment_bonus = {
			reliability = 0.05
		}
	}

	trait = {
		token = generic_mio_trait_improved_direct_fire_targeting
		name = generic_mio_trait_improved_direct_fire_targeting
		icon = GFX_generic_mio_department_icon_anti_tank

		position = { x=-1 y=3 }
		relative_position_id = generic_mio_trait_improved_hydraulic_recoil_system

		all_parents = {
			 generic_mio_trait_improved_hydraulic_recoil_system
		}

		mutually_exclusive = { generic_mio_trait_advanced_anti_air_targeting generic_mio_trait_advanced_trajectory_calculations }
		
		limit_to_equipment_type = { 
			anti_tank_equipment
		}

		equipment_bonus = {
			ap_attack = 0.05
			hard_attack = 0.05
		}
	}

	trait = {
		token = generic_mio_trait_advanced_anti_air_targeting
		name = generic_mio_trait_advanced_anti_air_targeting
		icon = GFX_generic_mio_department_icon_anti_air

		position = { x=1 y=0 }
		relative_position_id = generic_mio_trait_improved_direct_fire_targeting
		
		all_parents = {
			 generic_mio_trait_improved_hydraulic_recoil_system
		}
		
		mutually_exclusive = {
			generic_mio_trait_improved_direct_fire_targeting
			generic_mio_trait_advanced_trajectory_calculations
		}
		
		limit_to_equipment_type = { 
			anti_air_equipment
		}

		equipment_bonus = {
			air_attack = 0.07
		}
	}

	trait = {
		token = generic_mio_trait_advanced_trajectory_calculations
		name = generic_mio_trait_advanced_trajectory_calculations
		icon = GFX_generic_mio_department_icon_artillery

		position = { x=2 y=0 }
		relative_position_id = generic_mio_trait_improved_direct_fire_targeting

		all_parents = {
			 generic_mio_trait_improved_hydraulic_recoil_system
		}

		mutually_exclusive = { 
			generic_mio_trait_improved_direct_fire_targeting
			generic_mio_trait_advanced_anti_air_targeting
		}

		limit_to_equipment_type = { 
			artillery_equipment
		}

		equipment_bonus = {
			hard_attack = 1
			breakthrough = 0.05
		}
	}

	trait = {
		token = generic_mio_trait_material_recycling
		name = generic_mio_trait_material_recycling
		icon = GFX_generic_mio_department_icon_support_materials
		
		relative_position_id = generic_mio_trait_drum_pattern_sights
		position = { x=8 y=0 }
		
		limit_to_equipment_type = { support_equipment }
		
		production_bonus = {
			production_resource_need_factor = -0.15
		}
	}

	trait = {
		token = generic_mio_trait_high_quality_material_blend
		name = generic_mio_trait_high_quality_material_blend
		icon = GFX_generic_mio_trait_icon_efficiency_cap
		
		position = { x=0 y=1 }
		relative_position_id = generic_mio_trait_material_recycling
		
		all_parents = { generic_mio_trait_material_recycling }
		
		limit_to_equipment_type = { support_equipment }
		
		production_bonus = {
			production_efficiency_cap_factor = 0.05
		}
	}

	trait = {
		token = generic_mio_trait_mass_production
		name = generic_mio_trait_mass_production
		icon = GFX_generic_mio_trait_icon_efficiency_gain
		
		position = { x=0 y=2 }
		relative_position_id = generic_mio_trait_high_quality_material_blend
		
		any_parent = { generic_mio_trait_high_quality_material_blend }
		
		limit_to_equipment_type = { support_equipment }

		production_bonus = {
			production_efficiency_gain_factor = 0.05
		}
	}

	trait = {
		token = generic_mio_trait_research_program
		name = generic_mio_trait_research_program
		icon = GFX_generic_mio_department_icon_facilities
		
		position = { x=0 y=1 }
		relative_position_id = generic_mio_trait_mass_production
		
		all_parents = { generic_mio_trait_mass_production }
		
		organization_modifier = {
			military_industrial_organization_research_bonus = 0.05
		}
	}

}
