﻿focus_tree = {
	id = plankton_phase2
	
	country = {
		factor = 0
		
		modifier = {
			add = 1111210
			OR = {
				tag = PLA
			}
 		}
	}
	
	default = no

	continuous_focus_position = { x = 2250 y = 5350 }

 

 
 	focus = {
		id =  patrick_mad
		icon = GFX_patrick_mad
		cost = 7

		mutually_exclusive = { }
		x = 12
		y = 0

  
		relative_position_id = 2

		available = { always = no

		}
		
		bypass = {

		}

		cancel_if_invalid = yes
		continue_if_invalid = no
		available_if_capitulated = no

		complete_tooltip = {

		}

		completion_reward = {	
		
PAT = {	
	add_timed_idea = {
    idea = patmad
    days = 260
}  
		}

		ai_will_do = {
			factor = 1
		}
		}

	}
 	focus = {
		id =  cb_destroyed
		icon = GFX_cb_destroyed
		cost = 7

		mutually_exclusive = { }
		x = 12
		y = 2

 		prerequisite = { focus = patrick_bazooka}
		relative_position_id = 2

		available = { always = no

		}
		
		bypass = {

		}

		cancel_if_invalid = yes
		continue_if_invalid = no
		available_if_capitulated = no

		complete_tooltip = {

		}

		completion_reward = {	
		
	add_ideas = cb_destroyed
 

		ai_will_do = {
			factor = 1
		}
		}

	}
 	focus = {
		id =  patrick_bazooka
		icon = GFX_patrick_bazooka
		cost = 7

		mutually_exclusive = { }
		x = 14
		y = 1

		prerequisite = { focus = patrick_mad }
 		relative_position_id = 2

		available = { always = no

		}
		
		bypass = {

		}

		cancel_if_invalid = yes
		continue_if_invalid = no
		available_if_capitulated = no

		complete_tooltip = {

		}

		completion_reward = {
PAT = {
add_equipment_to_stockpile = {
    type = motorized_equipment_1
    amount = 5000
    variant_name = "Boats I"
}
	if = {
		limit = {
			NOT = { has_dlc = "No Step Back" }
		}
		set_technology = {
 			basic_heavy_tank = 1    
	 tech_trucks = 1
	motorised_infantry = 1
 			improved_heavy_tank = 1    

 		}
add_equipment_to_stockpile = {
    type = heavy_tank_equipment_1
    amount = 25400
    variant_name = "PatTank"
}
 	}
	if = {
		limit = {
			has_dlc = "No Step Back"
		}
		set_technology = {
 			basic_heavy_tank_chassis = 1
				tech_trucks = 1
	motorised_infantry = 1
 			improved_heavy_tank_chassis = 1

 		}
add_equipment_to_stockpile = {
    type = heavy_tank_chassis_1
    amount = 25400
    variant_name = "PatTank"
}
 	}
			division_template = {
				name = "Patriktank" 	
				division_names_group = RIR_INF_01

				regiments = {
					heavy_armor = { x = 0 y = 0 }		
					heavy_armor = { x = 0 y = 1 }		
					heavy_armor = { x = 1 y = 0 }		
					heavy_armor = { x = 1 y = 1 }		
					heavy_armor = { x = 2 y = 0 }			
					heavy_armor = { x = 2 y = 1 }
					heavy_armor = { x = 2 y = 2 }
					heavy_armor = { x = 3 y = 0 }			
					heavy_armor = { x = 3 y = 1 }
					heavy_armor = { x = 3 y = 2 }
 					heavy_armor = { x = 0 y = 3 }		
					heavy_armor = { x = 1 y = 3 }		
 					heavy_armor = { x = 2 y = 3 }			
 					heavy_armor = { x = 3 y = 3 }			
 
				}
				support = {
					recon = { x = 0 y = 0 }      		
					artillery = { x = 0 y = 1 }
					engineer = { x = 0 y = 2 }
				}
			}
			if = {
				limit = {
					has_dlc = "No Step Back"
				}
				capital_scope = {
					create_unit = {
						division = "name = \"Patriktank\" division_template = \"Patriktank\" start_experience_factor = 1 force_equipment_variants = { heavy_tank_chassis_1 = { creator = \"PAT\" version_name = \"Char B1\"} }"  
						owner = ROOT
					}
					create_unit = {
						division = "name = \"Patriktank\" division_template = \"Patriktank\" start_experience_factor = 1 force_equipment_variants = { heavy_tank_chassis_1 = { creator = \"PAT\" version_name = \"Char B1\"} }"  
						owner = ROOT
					}
					create_unit = {
						division = "name = \"Patriktank\" division_template = \"Patriktank\" start_experience_factor = 1 force_equipment_variants = { heavy_tank_chassis_1 = { creator = \"PAT\" version_name = \"Char B1\"} }"  
						owner = ROOT
					}
					create_unit = {
						division = "name = \"Patriktank\" division_template = \"Patriktank\" start_experience_factor = 1 force_equipment_variants = { heavy_tank_chassis_1 = { creator = \"PAT\" version_name = \"Char B1\"} }"  
						owner = ROOT
					}
					create_unit = {
						division = "name = \"Patriktank\" division_template = \"Patriktank\" start_experience_factor = 1 force_equipment_variants = { heavy_tank_chassis_1 = { creator = \"PAT\" version_name = \"Char B1\"} }"  
						owner = ROOT
					}
					create_unit = {
						division = "name = \"Patriktank\" division_template = \"Patriktank\" start_experience_factor = 1 force_equipment_variants = { heavy_tank_chassis_1 = { creator = \"PAT\" version_name = \"Char B1\"} }"  
						owner = ROOT
					}
					create_unit = {
						division = "name = \"Patriktank\" division_template = \"Patriktank\" start_experience_factor = 1 force_equipment_variants = { heavy_tank_chassis_1 = { creator = \"PAT\" version_name = \"Char B1\"} }"  
						owner = ROOT
					}
					create_unit = {
						division = "name = \"Patriktank\" division_template = \"Patriktank\" start_experience_factor = 1 force_equipment_variants = { heavy_tank_chassis_1 = { creator = \"PAT\" version_name = \"Char B1\"} }"  
						owner = ROOT
					}
					create_unit = {
						division = "name = \"Patriktank\" division_template = \"Patriktank\" start_experience_factor = 1 force_equipment_variants = { heavy_tank_chassis_1 = { creator = \"PAT\" version_name = \"Char B1\"} }"  
						owner = ROOT
					}
					create_unit = {
						division = "name = \"Patriktank\" division_template = \"Patriktank\" start_experience_factor = 1 force_equipment_variants = { heavy_tank_chassis_1 = { creator = \"PAT\" version_name = \"Char B1\"} }"  
						owner = ROOT
					}
				}
			}
			else = {
				capital_scope = {
					create_unit = {
						division = "name = \"Patriktank\" division_template = \"Patriktank\" start_experience_factor = 1"  
						owner = ROOT
					}
					create_unit = {
						division = "name = \"Patriktank\" division_template = \"Patriktank\" start_experience_factor = 1"  
						owner = ROOT
					}
					create_unit = {
						division = "name = \"Patriktank\" division_template = \"Patriktank\" start_experience_factor = 1"  
						owner = ROOT
					}
					create_unit = {
						division = "name = \"Patriktank\" division_template = \"Patriktank\" start_experience_factor = 1"  
						owner = ROOT
					}
					create_unit = {
						division = "name = \"Patriktank\" division_template = \"Patriktank\" start_experience_factor = 1"  
						owner = ROOT
					}
					create_unit = {
						division = "name = \"Patriktank\" division_template = \"Patriktank\" start_experience_factor = 1"  
						owner = ROOT
					}
					create_unit = {
						division = "name = \"Patriktank\" division_template = \"Patriktank\" start_experience_factor = 1"  
						owner = ROOT
					}
					create_unit = {
						division = "name = \"Patriktank\" division_template = \"Patriktank\" start_experience_factor = 1"  
						owner = ROOT
					}
					create_unit = {
						division = "name = \"Patriktank\" division_template = \"Patriktank\" start_experience_factor = 1"  
						owner = ROOT
					}
					create_unit = {
						division = "name = \"Patriktank\" division_template = \"Patriktank\" start_experience_factor = 1"  
						owner = ROOT
					}
				}
			}
		}
		}

	}
	
	
 	focus = {
		id =  plankton_running
		icon = GFX_plankton_running
		cost = 7

		mutually_exclusive = { }
		x = 10
		y = 3

 		prerequisite = { focus = cb_destroyed}
 
		relative_position_id = 2

		available = { always = no

		}
		
		bypass = {

		}

		cancel_if_invalid = yes
		continue_if_invalid = no
		available_if_capitulated = no

		complete_tooltip = {

		}

		completion_reward = {	
		
 swap_ideas = {
    remove_idea = cb_destroyed
    add_idea = cb_destroyed1
}

		ai_will_do = {
			factor = 1
		}
		}

	}	

 	focus = {
		id =  plankton_mad
		icon = GFX_plankton_mad
		cost = 7

		mutually_exclusive = { }
		x = 9
		y = 4

		prerequisite = { focus = plankton_running }
   
		relative_position_id = 2

		available = { always = no

		}
		
		bypass = {

		}

		cancel_if_invalid = yes
		continue_if_invalid = no
		available_if_capitulated = no

		complete_tooltip = {

		}

		completion_reward = {	
		
remove_ideas = cb_destroyed1
add_timed_idea = {
    idea = cb_destroyed2
    days = 280
}
		ai_will_do = {
			factor = 1
		}
		}

	}	
 
 	focus = {
		id =  jellyfish
		icon = GFX_jellyfish
		cost = 7

		mutually_exclusive = { }
		x = 12
		y = 7

		prerequisite = { focus = patrick_research }
  
		relative_position_id = 2

		available = { always = no

		}
		
		bypass = {

		}

		cancel_if_invalid = yes
		continue_if_invalid = no
		available_if_capitulated = no

		complete_tooltip = {

		}

		completion_reward = {	
		 			custom_effect_tooltip = phase_2_tt

			damage_units = {
			   region = 14
				limit = { original_tag = RIR }
				damage = 0.5
				 str_damage = 0.5
				ratio = yes
				 army = yes
				navy = yes
			}	
			damage_units = {
			   region = 8
				limit = { original_tag = RIR }
				damage = 0.5
				 str_damage = 0.5
				ratio = yes
				 army = yes
				navy = yes
			}	
			damage_units = {
			   region = 11
				limit = { original_tag = RIR }
				damage = 0.5
				 str_damage = 0.5
				ratio = yes
				 army = yes
				navy = yes
			}	
			damage_units = {
			   region = 15
				limit = { original_tag = RIR }
				damage = 0.5
				 str_damage = 0.5
				ratio = yes
				 army = yes
				navy = yes
			}


 
			damage_units = {
			   region = 59
				limit = { original_tag = RIR }
				damage = 0.5
				 str_damage = 0.5
				ratio = yes
				 army = yes
				navy = yes
			}	
			damage_units = {
			   region = 10
				limit = { original_tag = RIR }
				damage = 0.5
				 str_damage = 0.5
				ratio = yes
				 army = yes
				navy = yes
			}	
			damage_units = {
			   region = 8
				limit = { original_tag = RIR }
				damage = 0.5
				 str_damage = 0.5
				ratio = yes
				 army = yes
				navy = yes
			}	
			damage_units = {
			   region = 3
				limit = { original_tag = RIR }
				damage = 0.5
				 str_damage = 0.5
				ratio = yes
				 army = yes
				navy = yes
			}



		ai_will_do = {
			factor = 1
		}
		}

	}		
 	focus = {
		id =  patrick_time
		icon = GFX_patrick_time
		cost = 7

		mutually_exclusive = { }
		x = 14
		y = 8

		prerequisite = { focus = jellyfish }
  
		relative_position_id = 2

		available = { always = no

		}
		
		bypass = {

		}

		cancel_if_invalid = yes
		continue_if_invalid = no
		available_if_capitulated = no

		complete_tooltip = {

		}

		completion_reward = {	
		PAT = {
add_timed_idea = {
    idea = clock
    days = 160
} } 

add_timed_idea = {
    idea = clock
    days = 160
} 

		ai_will_do = {
			factor = 1
		}
		}

	}
 	focus = {
		id =  patrick_research
		icon = GFX_patrick_research
		cost = 7

		mutually_exclusive = { }
		x = 10
		y = 6

		prerequisite = { focus = patrick_ears }
  
		relative_position_id = 2

		available = { always = no

		}
		
		bypass = {

		}

		cancel_if_invalid = yes
		continue_if_invalid = no
		available_if_capitulated = no

		complete_tooltip = {

		}

		completion_reward = {	
		add_manpower = -1900000
		
set_stability = 0.1
 set_war_support = 0.01


		ai_will_do = {
			factor = 1
		}
		}

	}	 
 	focus = {
		id =  patrick_ears
		icon = GFX_patrick_ears
		cost = 7

		mutually_exclusive = { }
		x = 8
		y = 5

		prerequisite = { focus = plankton_mad }
  
		relative_position_id = 2

		available = { always = no

		}
		
		bypass = {

		}

		cancel_if_invalid = yes
		continue_if_invalid = no
		available_if_capitulated = no

		complete_tooltip = {

		}

		completion_reward = {	
 		add_equipment_to_stockpile = {
    type = infantry_equipment_1
    amount = -300000
	  producer = RIR

}
add_equipment_to_stockpile = {
    type = support_equipment_1
    amount = -5000
  producer = RIR

}


		ai_will_do = {
			factor = 1
		}
		}

	}	
	
 	focus = {
		id =  patrick_bus
		icon = GFX_patrick_bus
		cost = 7

		mutually_exclusive = { }
		x = 12
		y = 10

		prerequisite = { focus = patrick_time }
 
		relative_position_id = 2

		available = { always = no

		}
		
		bypass = {

		}

		cancel_if_invalid = yes
		continue_if_invalid = no
		available_if_capitulated = no

		complete_tooltip = {

		}

		completion_reward = {	
		clr_country_flag = plankton_phase2
		set_country_flag = plankton_phase2_end

		PAT = {
add_timed_idea = {
    idea = bus
    days = 360
} } 

 
		ai_will_do = {
			factor = 1
		}
		}

	}

 
}
