byzantium_post_islam_mmetr_missions_1 = {
	slot = 1
	generic = no
	ai = yes
	potential = {
		OR = {
			tag = BYZ
		}
		started_in = 641.1.1
		NOT = { started_in = 1204.1.1 }
		NOT = { map_setup = map_setup_random }
	}
	has_country_shield = yes
	
	byz2_byzantine_churches_mission = {
		icon = protectors_of_christendom
		required_missions = {  }
		position = 1
		trigger = {
			num_of_owned_provinces_with = {
				value = 20
				OR = {
					has_building = glorious_monument
					has_building = temple
					has_building = cathedral
				}
			}
		}
		effect = {
			country_event = {
				id = mmetr_BYZ_mission_events.1
			}
			custom_tooltip = byz2_byzantine_churches_mission.tt
		}
	}
	byz2_one_empire_one_church_mission = {
		icon = mission_pf_cross
		required_missions = { byz2_byzantine_churches_mission }
		position = 2
		provinces_to_highlight = {
			owned_by = ROOT
			has_owner_religion = no
		}
		trigger = {
			religious_unity = 0.90
			num_of_owned_provinces_with = {
				value = 60
				has_owner_religion = yes
			}
		}
		effect = {
			add_country_modifier = {
				name = "me_byz2_messenger_of_christ"
				duration = 5475
			}
		}
	}
	byz2_shield_of_christendom_mission = {
		icon = mission_crown_of_jesus_roger_ii
		required_missions = { byz2_one_empire_one_church_mission }
		position = 3
		trigger = {
			is_defender_of_faith_of_tier = 3
		}
		effect = {
			add_country_modifier = {
				name = "me_byz2_religious_authority"
				duration = 7300
			}
		}
	}
	byz2_declare_the_crusade_mission = {
		icon = crusader_fleet
		required_missions = { byz2_shield_of_christendom_mission byz2_question_of_iconoclasm_mission }
		position = 4
		trigger = {
			num_of_owned_provinces_with = {
				value = 20
				has_owner_religion = no
				NOT = {
					religion_group = christian
				}
			}
		}
		effect = {
			add_prestige = 10
			add_dip_power = 50
			add_country_modifier = {
				name = "me_byz2_aftermath_of_the_crusade"
				duration = 7300
			}
		}
	}
	byz2_roman_fire_mission = {
		icon = byz_greek_fire
		required_missions = {  }
		position = 5
		trigger = {
			num_of_admirals = 1
			OR = {
				natural_scientist = 1
				navy_size_percentage = 0.90
				navy_tradition = 30
			}
		}
		effect = {
			add_country_modifier = {
				name = "me_byz2_roman_fire"
				duration = 7300
			}
		}
	}
	byz2_megale_hellas_mission = {
		icon = renaissance_city
		required_missions = { byz2_roman_fire_mission }
		position = 7
		provinces_to_highlight = {
			OR = {
				area = calabria_area
				area = apulia_area
				area = naples_area		#Campania
			}
			NOT = {
				country_or_non_sovereign_subject_holds = ROOT
			}
			has_discovered = ROOT
		}
		trigger = {
			calabria_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			apulia_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			naples_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
		}
		effect = {
			add_navy_tradition = 5
			118 = {		#Roma
				add_permanent_claim = ROOT
			}
		}
	}
	byz2_triumph_in_rome_mission = {
		icon = a_real_roman_empire
		required_missions = { byz2_megale_hellas_mission }
		position = 9
		provinces_to_highlight = {
			province_id = 118
			NOT = {
				owned_by = ROOT
				is_core = ROOT
			}
		}
		trigger = {
			owns_core_province = 118
		}
		effect = {
			add_country_modifier = {
				name = "me_byz2_twin_cities_reunited"
				duration = 5475
			}
		}
	}
	byz2_justinians_legacy_mission = {
		icon = byz_justinians_ambition
		required_missions = { byz2_triumph_in_rome_mission }
		position = 11
		provinces_to_highlight = {
			region = italy_region
			NOT = {
				country_or_non_sovereign_subject_holds = ROOT
			}
			has_discovered = ROOT
		}
		trigger = {
			italy_region = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
		}
		effect = {
			add_prestige = 10
			add_legitimacy_equivalent = 50
			add_country_modifier = {
				name = "me_byz2_roman_italy"
				duration = 5475
			}
		}
	}
	byz2_restore_order_from_ravenna_mission = {
		icon = mission_west_roman_soldier
		required_missions = { byz2_justinians_legacy_mission }
		position = 12
		provinces_to_highlight = {
			province_id = 114		#Ravenna
			NOT = {
				num_of_times_improved_by_owner = 3
				fort_level = 2
				owned_by = ROOT
				is_core = ROOT
			}
			has_discovered = ROOT
		}
		trigger = {
			owns_core_province = 114
			114 = {
				fort_level = 2
			}
			114 = {
				num_of_times_improved_by_owner = 3
			}
			num_of_owned_provinces_with = {
				value = 2
				region = italy_region
				fort_level = 2
			}
		}
		effect = {
			add_adm_power = 50
			118 = {
				add_province_modifier = {
					name = "me_byz2_exarchate_of_ravenna"
					duration = 5475
				}
			}
		}
	}
	byz2_cross_the_rubicon_mission = {
		icon = mission_dice_roll_roman
		required_missions = { byz2_restore_order_from_ravenna_mission byz2_reinstate_the_pentarchy_mission }
		position = 13
		trigger = {
			stability = 3
			italy_region = {
				type = all
				owned_by = ROOT
				is_core = ROOT
			}
		}
		effect = {
			country_event = {
				id = mmetr_BYZ_mission_events.13
			}
			custom_tooltip = byz2_cross_the_rubicon_mission.tt
			tooltip = {
				183 = {		#Paris Lutetia
					add_claim = ROOT
				}
				200 = {		#Nimes / Languedoc
					add_claim = ROOT
				}
				203 = {		#Lugdunum / Lyon
					add_claim = ROOT
				}
			}
		}
	}
	byz2_crush_the_franks_mission = {
		icon = carolingian_empire
		required_missions = { byz2_cross_the_rubicon_mission }
		position = 14
		provinces_to_highlight = {
			region = france_region
			NOT = {
				country_or_non_sovereign_subject_holds = ROOT
			}
			has_discovered = ROOT
		}
		trigger = {
			num_of_owned_provinces_with = {
				value = 25
				country_or_non_sovereign_subject_holds = ROOT
			}
		}
		effect = {
			add_country_modifier = {
				name = "me_byz2_basileus_of_gallia"
				duration = 9125
			}
		}
	}
	byz2_dethrone_the_germans_mission = {
		icon = encroach_on_the_germans
		required_missions = { byz2_crush_the_franks_mission }
		position = 16
		provinces_to_highlight = {
			OR = {
				province_id = 1878		#Aachen
				province_id = 1876		#Frankfurt
				region = south_german_region
			}
			NOT = {
				country_or_non_sovereign_subject_holds = ROOT
			}
			has_discovered = ROOT
		}
		trigger = {
			owns_or_non_sovereign_subject_of = 1878
			owns_or_non_sovereign_subject_of = 1876
			num_of_provinces_owned_or_owned_by_non_sovereign_subjects_with = {
				value = 20
				region = south_german_region
			}
		}
		effect = {
			add_army_tradition = 20
			add_ruler_modifier = {
				name = "me_byz2_germanicus"
				duration = -1
			}
		}
	}
	
}

byzantium_post_islam_mmetr_missions_2 = {
	slot = 2
	generic = no
	ai = yes
	potential = {
		OR = {
			tag = BYZ
		}
		started_in = 641.1.1
		NOT = { started_in = 1204.1.1 }
		NOT = { map_setup = map_setup_random }
	}
	has_country_shield = yes
	
	byz2_patriarch_of_constantinople_mission = {
		icon = promote_the_patriarchate
		required_missions = {  }
		position = 1
		trigger = {
			if = {
				limit = {
					has_estate = estate_church
				}
				OR = {
					estate_loyalty = {
						estate = estate_church
						loyalty = 80
					}
					num_of_estate_agendas_completed = {
						estate = estate_church
						value = 4
					}
				}
			}
			else = {
				religious_unity = 0.90
				stability = 2
			}
		}
		effect = {
			country_event = {
				id = mmetr_BYZ_mission_events.2
			}
			tooltip = {
				add_country_modifier = {
					name = "me_byz2_successor_of_saint_andreas"
					duration = 9125
				}
			}
		}
	}
	byz2_endemousa_synodos_mission = {
		icon = reissue_the_mining_code
		required_missions = { byz2_patriarch_of_constantinople_mission byz2_byzantine_churches_mission }
		position = 2
		trigger = {
			OR = {
				theologian = 3
				inquisitor = 3
			}
		}
		effect = {
			add_country_modifier = {
				name = "me_byz2_endemousa_synodos"
				duration = 7300
			}
		}
	}
	byz2_question_of_iconoclasm_mission = {
		icon = mission_abolish_mestnichestvo
		required_missions = { byz2_endemousa_synodos_mission }
		position = 3
		trigger = {
			religious_unity = 1.00
		}
		effect = {
			country_event = {
				id = mmetr_BYZ_mission_events.18
			}
		}
	}
	byz2_renovate_the_hagia_sophia_mission = {
		icon = take_constantinople
		required_missions = { byz2_nine_gates_of_theodosius_mission byz2_question_of_iconoclasm_mission }
		position = 4
		provinces_to_highlight = {
			province_id = 151	#Constantinople
			has_discovered = ROOT
		}
		trigger = {
			owns_core_province = 151
			if = {
				limit = {
					has_dlc = "Leviathan"
				}
				151 = {
					has_great_project = {
						type = hagia_sophia
						tier = 3
					}
				}
			}
			else = {
				151 = {
					development = 35
				}
				prestige = 90
			}
		}
		effect = {
			add_country_modifier = {
				name = "me_byz2_grand_architect"
				duration = 10950
			}
		}
	}
	byz2_foederati_of_dalmatia_mission = {
		icon = dalmatian_conquest
		required_missions = { byz2_recruit_the_tagmata_mission }
		position = 6
		provinces_to_highlight = {
			OR = {
				area = serbia_area
				area = rascia_area
				area = croatia_area
				area = bosnia_area
				area = east_adriatic_coast_area		#Dalmatia
			}
			NOT = {
				country_or_non_sovereign_subject_holds = ROOT
			}
			has_discovered = ROOT
		}
		trigger = {
			serbia_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			rascia_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			croatia_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			bosnia_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			east_adriatic_coast_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			OR = {
				NOT = { exists = DAL }
				overlord_of = DAL
			}
		}
		effect = {
			custom_tooltip = byz2_foederati_of_dalmatia_mission.tt
			country_event = {
				id = mmetr_BYZ_mission_events.11
			}
		}
	}
	byz2_baptize_the_slavic_peoples_mission = {
		icon = mission_mass_baptism
		required_missions = { byz2_foederati_of_dalmatia_mission byz2_vanquish_the_bulgarians_mission }
		position = 7
		provinces_to_highlight = {
			OR = {
				area = serbia_area
				area = rascia_area
				area = croatia_area
				area = bosnia_area
				area = east_adriatic_coast_area		#Dalmatia
			}
			NOT = {
				has_owner_religion = yes
				OR = {
					owned_by = ROOT
					owner = {
						has_matching_religion = ROOT
					}
				}
			}
			has_discovered = ROOT
		}
		trigger = {
			serbia_area = {
				type = all
				has_owner_religion = yes
				OR = {
					owned_by = ROOT
					owner = {
						has_matching_religion = ROOT
					}
				}
			}
			rascia_area = {
				type = all
				has_owner_religion = yes
				OR = {
					owned_by = ROOT
					owner = {
						has_matching_religion = ROOT
					}
				}
			}
			croatia_area = {
				type = all
				has_owner_religion = yes
				OR = {
					owned_by = ROOT
					owner = {
						has_matching_religion = ROOT
					}
				}
			}
			bosnia_area = {
				type = all
				has_owner_religion = yes
				OR = {
					owned_by = ROOT
					owner = {
						has_matching_religion = ROOT
					}
				}
			}
			east_adriatic_coast_area = {
				type = all
				has_owner_religion = yes
				OR = {
					owned_by = ROOT
					owner = {
						has_matching_religion = ROOT
					}
				}
			}
		}
		effect = {
			add_adm_power = 100
			add_prestige = 10
		}
	}
	byz2_adriatic_trading_mission = {
		icon = danubian_power
		required_missions = { byz2_baptize_the_slavic_peoples_mission byz2_megale_hellas_mission }
		position = 8
		provinces_to_highlight = {
			OR = {
				province_id = 1308		#Venice trade node
				province_id = 137		#Ragusa trade node
			}
			NOT = {
				trade_share = {
					country = ROOT
					share = 50
				}
			}
			has_discovered = ROOT
		}
		trigger = {
			1308 = {
				trade_share = {
					country = ROOT
					share = 50
				}
			}
			137 = {
				trade_share = {
					country = ROOT
					share = 50
				}
			}
		}
		effect = {
			add_country_modifier = {
				name = "me_byz2_adriatic_emporia"
				duration = 9125
			}
		}
	}
	byz2_the_bishop_of_rome_mission = {
		icon = answer_the_roman_question
		required_missions = { byz2_triumph_in_rome_mission }
		position = 10
		provinces_to_highlight = {
			OR = {
				AND = {
					OR = {
						area = central_italy_area
						area = lazio_area
					}
					NOT = {
						country_or_non_sovereign_subject_holds = ROOT
					}
				}
				AND = {
					province_id = 118
					NOT = {
						owned_by = ROOT
						is_core = ROOT
						has_owner_religion = yes
						num_of_times_improved_by_owner = 2
						num_of_buildings_in_province = 3
					}
				}
			}
			has_discovered = ROOT
		}
		trigger = {
			owns_core_province = 118
			118 = {
				has_owner_religion = yes
			}
			118 = {
				num_of_times_improved_by_owner = 2
			}
			118 = {
				num_of_buildings_in_province = 3
			}
			central_italy_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			lazio_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
		}
		effect = {
			if = {
				limit = {
					uses_patriarch_authority = yes
				}
				add_patriarch_authority = 0.05
			}
			country_event = {
				id = mmetr_BYZ_mission_events.12
			}
		}
	}
	byz2_reinstate_the_pentarchy_mission = {
		icon = mission_autocephalous_archbishopric
		required_missions = { byz2_the_bishop_of_rome_mission byz2_annexation_of_aegyptos_mission }
		position = 12
		provinces_to_highlight = {
			OR = {
				province_id = 151	#Constantinople
				province_id = 118	#Rome
				province_id = 358	#Alexandria
				province_id = 2313	#Antioch
				province_id = 379	#Jerusalem
			}
			NOT = {
				OR = {
					owned_by = ROOT
					is_core = ROOT
					has_owner_religion = yes
				}
			}
			OR = {
				NOT = {
					has_building = temple
				}
				NOT = {
					has_building = cathedral
				}
			}
			has_discovered = ROOT
		}
		trigger = {
			owns_core_province = 151
			owns_core_province = 118
			owns_core_province = 358
			owns_core_province = 2313
			owns_core_province = 379
			151 = {
				has_owner_religion = yes
			}
			118 = {
				has_owner_religion = yes
			}
			358 = {
				has_owner_religion = yes
			}
			2313 = {
				has_owner_religion = yes
			}
			379 = {
				has_owner_religion = yes
			}
			151 = {
				OR = {
					has_building = temple
					has_building = cathedral
				}
			}
			118 = {
				OR = {
					has_building = temple
					has_building = cathedral
				}
			}
			358 = {
				OR = {
					has_building = temple
					has_building = cathedral
				}
			}
			2313 = {
				OR = {
					has_building = temple
					has_building = cathedral
				}
			}
			379 = {
				OR = {
					has_building = temple
					has_building = cathedral
				}
			}
		}
		effect = {
			add_country_modifier = {
				name = "me_byz2_limited_pentarchy"
				duration = 7300
			}
			if = {
				limit = {
					uses_patriarch_authority = yes
				}
				add_patriarch_authority = 0.05
			}
		}
	}
	byz2_mediterranean_hegemony_mission = {
		icon = mission_mediterranean_islands
		required_missions = { byz2_reinstate_the_pentarchy_mission }
		position = 14
		provinces_to_highlight = {
			OR = {
				area = sicily_area
				area = western_sicily_area
				area = corsica_sardinia_area
				area = baleares_area
				area = aegean_archipelago_area
			}
			NOT = {
				country_or_non_sovereign_subject_holds = ROOT
			}
			has_discovered = ROOT
		}
		trigger = {
			sicily_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			western_sicily_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			corsica_sardinia_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			baleares_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			aegean_archipelago_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
		}
		effect = {
			add_dip_power = 50
			add_country_modifier = {
				name = "me_byz2_thalassocratic_empire"
				duration = 7300
			}
		}
	}
	
}

byzantium_post_islam_mmetr_missions_3 = {
	slot = 3
	generic = no
	ai = yes
	potential = {
		OR = {
			tag = BYZ
		}
		started_in = 641.1.1
		NOT = { started_in = 1204.1.1 }
		NOT = { map_setup = map_setup_random }
	}
	has_country_shield = yes
	
	byz2_city_of_the_worlds_desire_mission = {
		icon = mission_hagia_sophia
		required_missions = {  }
		position = 1
		provinces_to_highlight = {
			province_id = 151		#Constantinople
			NOT = {
				is_capital_of = ROOT
				num_of_times_improved_by_owner = 5
				num_of_buildings_in_province = 3
			}
		}
		trigger = {
			capital = 151
			151 = {
				num_of_times_improved_by_owner = 5
			}
			151 = {
				num_of_buildings_in_province = 3
			}
			anatolia_region = {		#Constantinople is higher development than Anatolia region
				type = all
				151 = {
					higher_development_than = PREV
				}
			}
		}
		effect = {
			country_event = {
				id = mmetr_BYZ_mission_events.3
			}
			tooltip = {
				151 = {
					add_province_modifier = {
						name = "me_byz2_university_of_constantinople"
						duration = 9125
					}
				}
			}
		}
	}
	byz2_nine_gates_of_theodosius_mission = {
		icon = byz_reinforce_constantinople
		required_missions = { byz2_city_of_the_worlds_desire_mission }
		position = 3
		provinces_to_highlight = {
			province_id = 151
			NOT = {
				owned_by = ROOT
				is_core = ROOT
				fort_level = 2
				base_manpower = 10
			}
			has_discovered = ROOT
		}
		trigger = {
			owns_core_province = 151
			151 = {
				fort_level = 2
			}
			151  ={
				base_manpower = 10
			}
		}
		effect = {
			country_event = {
				id = mmetr_BYZ_mission_events.5
			}
			tooltip = {
				151 = {
					add_province_modifier = {
						name = "me_byz2_theodosian_walls_bolstered"
						duration = 7300
					}
				}
			}
		}
	}
	byz2_recruit_the_tagmata_mission = {
		icon = mission_pf_soldier
		required_missions = {  }
		position = 5
		trigger = {
			num_of_generals = 2
			army_size_percentage = 0.9
		}
		effect = {
			add_country_modifier = {
				name = "me_byz2_tagmata"
				duration = 7300
			}
		}
	}
	byz2_vanquish_the_bulgarians_mission = {
		icon = mission_krums_nikephoros_skull_cup
		required_missions = { byz2_recruit_the_tagmata_mission }
		position = 6
		provinces_to_highlight = {
			OR = {
				area = bulgaria_area
				area = silistria_area
				area = wallachia_area
				area = southern_transylvania_area
				area = transylvania_area
			}
			NOT = {
				country_or_non_sovereign_subject_holds = ROOT
			}
			has_discovered = ROOT
		}
		trigger = {
			bulgaria_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			silistria_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			wallachia_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			southern_transylvania_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			transylvania_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			OR = {
				NOT = { exists = BUL }
				overlord_of = BUL
			}
		}
		effect = {
			country_event = {
				id = mmetr_BYZ_mission_events.14
			}
			tooltip = {
				add_country_modifier = {
					name = "me_byz2_the_victorious"
					duration = 5475
				}
			}
		}
	}
	byz2_foothold_in_crimea_mission = {
		icon = secure_the_republic
		required_missions = { byz2_vanquish_the_bulgarians_mission }
		position = 7
		provinces_to_highlight = {
			OR = {
				AND = {
					province_id = 1322		#Crimea trade node
					NOT = {
						is_strongest_trade_power = ROOT
					}
				}
				AND = {
					area = crimea_area
					owned_by = ROOT
					NOT = {
						development = 10
					}
				}
			}
			has_discovered = ROOT
		}
		trigger = {
			1322 = {	#Crimea trade node
				is_strongest_trade_power = ROOT
			}
			any_owned_province = {
				area = crimea_area
				development = 10
			}
		}
		effect = {
			add_mercantilism = 2
			add_dip_power = 100
		}
	}
	byz2_replicate_nineveh_mission = {
		icon = mission_into_persia_2
		required_missions = { byz2_retribution_for_yarmuk_mission }
		position = 9
		provinces_to_highlight = {
			OR = {
				area = al_jazira_area
				area = iraq_arabi_area
				area = basra_area
			}
			NOT = {
				country_or_non_sovereign_subject_holds = ROOT
			}
			has_discovered = ROOT
		}
		trigger = {
			al_jazira_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			iraq_arabi_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			basra_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
		}
		effect = {
			tooltip = {
				add_country_modifier = {
					name = "me_byz2_the_second_trajan"
					duration = 7300
				}
			}
			country_event = {
				id = mmetr_BYZ_mission_events.9
			}
		}
	}
	byz2_the_church_of_the_east_mission = {
		icon = chivalry_is_not_dead
		required_missions = { byz2_replicate_nineveh_mission }
		position = 10
		provinces_to_highlight = {
			OR = {
				area = al_jazira_area
				area = iraq_arabi_area
				area = basra_area
			}
			NOT = {
				religion_group = christian
			}
			has_discovered = ROOT
		}
		trigger = {
			al_jazira_area = {
				type = all
				religion_group = christian
			}
			iraq_arabi_area = {
				type = all
				religion_group = christian
			}
			basra_area = {
				type = all
				religion_group = christian
			}
		}
		effect = {
			country_event = {
				id = mmetr_BYZ_mission_events.16
			}
		}
	}
	byz2_birthplace_of_islam_mission = {
		icon = mission_into_arabia
		required_missions = { byz2_annexation_of_aegyptos_mission }
		position = 12
		provinces_to_highlight = {
			OR = {
				area = mecca_area
				area = medina_area
			}
			NOT = {
				country_or_non_sovereign_subject_holds = ROOT
			}
			has_discovered = ROOT
		}
		trigger = {
			mecca_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			medina_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
		}
		effect = {
			add_prestige = 15
			country_event = {
				id = mmetr_BYZ_mission_events.17
			}
		}
	}
	byz2_mare_nostrum_once_more_mission = {
		icon = mission_mare_nostrum
		required_missions = { byz2_crush_the_franks_mission byz2_mediterranean_hegemony_mission byz2_avenge_the_altavans_mission }
		position = 15
		provinces_to_highlight = {
			OR = {
				area = catalonia_area
				area = valencia_area
				area = toledo_area
				area = lower_andalucia_area
				area = upper_andalucia_area
			}
			NOT = {
				owned_by = ROOT
			}
			has_discovered = ROOT
		}
		trigger = {
			catalonia_area = {
				type = all
				owned_by = ROOT
			}
			valencia_area = {
				type = all
				owned_by = ROOT
			}
			toledo_area = {
				type = all
				owned_by = ROOT
			}
			lower_andalucia_area = {
				type = all
				owned_by = ROOT
			}
			upper_andalucia_area = {
				type = all
				owned_by = ROOT
			}
		}
		effect = {
			add_country_modifier = {
				name = "me_byz2_mare_nostrum"
				duration = 10950
			}
		}
	}
	byz2_basileia_rhomaion_mission = {
		icon = a_roman_empire
		required_missions = { byz2_mare_nostrum_once_more_mission }
		position = 16
		provinces_to_highlight = {
			OR = {
				region = italy_region
				region = iberia_region
				region = france_region
			}
			NOT = {
				owned_by = ROOT
			}
			has_discovered = ROOT
		}
		trigger = {
			stability = 3
			prestige = 75
			italy_region = {
				type = all
				owned_by = ROOT
			}
			iberia_region = {
				type = all
				owned_by = ROOT
			}
			france_region = {
				type = all
				owned_by = ROOT
			}
		}
		effect = {
			add_country_modifier = {
				name = "me_byz2_eternal_empire"
				duration = -1
			}
		}
	}
	
}

byzantium_post_islam_mmetr_missions_4 = {
	slot = 4
	generic = no
	ai = yes
	potential = {
		OR = {
			tag = BYZ
		}
		started_in = 641.1.1
		NOT = { started_in = 1204.1.1 }
		NOT = { map_setup = map_setup_random }
	}
	has_country_shield = yes
	
	byz2_develop_the_themata_mission = {
		icon = mission_consolidate_the_state
		required_missions = {  }
		position = 1
		trigger = {
			num_of_states = 10
			crown_land_share = 50
			num_of_owned_provinces_with = {
				value = 10
				development = 12
			}
		}
		effect = {
			add_country_modifier = {
				name = "me_byz2_themata_system"
				duration = 9125
			}
		}
	}
	byz2_grain_of_the_empire_mission = {
		icon = mission_pol_breadbasket_europe
		required_missions = { byz2_develop_the_themata_mission byz2_city_of_the_worlds_desire_mission }
		position = 2
		trigger = {
			num_of_owned_provinces_with = {
				value = 15
				OR = {
					has_building = storehouse
					has_building = windmill
					has_building = workshop
				}
			}
		}
		effect = {
			country_event = {
				id = mmetr_BYZ_mission_events.4
			}
			tooltip = {
				add_country_modifier = {
					name = "me_byz2_abundant_supply"
					duration = 7300
				}
			}
		}
	}
	byz2_compile_the_basilika_mission = {
		icon = law_of_the_pious
		required_missions = { byz2_grain_of_the_empire_mission }
		position = 3
		trigger = {
			stability = 3
			monthly_adm = 11
			NOT = {
				average_unrest = 5
			}
		}
		effect = {
			add_country_modifier = {
				name = "me_byz2_basilika"
				duration = 7300
			}
		}
	}
	byz2_a_new_good_caesar_mission = {
		icon = mission_imperator_rome
		required_missions = { byz2_compile_the_basilika_mission byz2_nine_gates_of_theodosius_mission byz2_the_bearded_ones_mission }
		position = 4
		trigger = {
			prestige = 80
			monthly_adm = 10
			monthly_dip = 10
			monthly_mil = 10
		}
		effect = {
			add_country_modifier = {
				name = "me_byz2_good_basileus"
				duration = 7300
			}
		}
	}
	byz2_varangians_of_the_rus_mission = {
		icon = mission_the_varangians
		required_missions = { byz2_war_through_diplomacy_mission }
		position = 5
		provinces_to_highlight = {
			OR = {
				owned_by = KRU
				region = ruthenia_region
				region = russia_region
			}
			has_discovered = ROOT
		}
		trigger = {
			OR = {
				KRU = {		#Kievan Rus
					has_opinion = {
						who = ROOT
						value = 120
					}
				}
				any_known_country = {
					culture_group = east_slavic
					has_opinion = {
						who = ROOT
						value = 120
					}
				}
				num_of_provinces_owned_or_owned_by_non_sovereign_subjects_with = {
					value = 10
					OR = {
						region = ruthenia_region
						region = russia_region
					}
				}
			}
		}
		effect = {
			add_country_modifier = {
				name = "me_byz2_varangian_guard"
				duration = 10950
			}
			if = {
				limit = {
					OR = {
						KRU = {		#Kievan Rus
							has_opinion = {
								who = ROOT
								value = 120
							}
						}
						any_known_country = {
							culture_group = east_slavic
							has_opinion = {
								who = ROOT
								value = 120
							}
						}
					}
				}
				every_known_country = {
					limit = {
						OR = {
							tag = KRU
							culture_group = east_slavic
						}
						has_opinion = {
							who = ROOT
							value = 120
						}
					}
					add_trust = {
						who = ROOT
						value = 20
						mutual = yes
					}
				}
			}
		}
	}
	byz2_anatolic_consolidation_mission = {
		icon = mission_pf_map_table
		required_missions = {  }
		position = 6
		provinces_to_highlight = {
			OR = {
				area = hudavendigar_area
				area = aydin_area
				area = ankara_area
				area = germiyan_area
				area = rum_area
				area = karaman_area
				area = kastamonu_area		#Karadeniz
				area = dulkadir_area
				province_id = 327
				province_id = 2302
			}
			NOT = {
				country_or_non_sovereign_subject_holds = ROOT
			}
			has_discovered = ROOT
		}
		trigger = {
			hudavendigar_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			aydin_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			ankara_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			germiyan_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			rum_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			karaman_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			kastamonu_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			dulkadir_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			
			#Cukurova Area besides Cyprus
			owns_or_non_sovereign_subject_of = 327
			owns_or_non_sovereign_subject_of = 2302
			
			num_of_owned_provinces_with = {
				value = 20
				region = anatolia_region
				has_owner_religion = yes
			}
		}
		effect = {
			country_event = {
				id = mmetr_BYZ_mission_events.6
			}
			tooltip = {
				dulkadir_area = {
					add_province_modifier = {
						name = "me_byz2_kleisoura"
						duration = 7300
					}
				}
				327 = {
					add_province_modifier = {
						name = "me_byz2_kleisoura"
						duration = 7300
					}
				}
				2302 = {
					add_province_modifier = {
						name = "me_byz2_kleisoura"
						duration = 7300
					}
				}
				2313 = {		#Antioch
					add_permanent_claim = ROOT
				}
				if = {
					limit = {
						owns_or_non_sovereign_subject_of = 2313
					}
					aleppo_area = {
						limit = {
							NOT = { is_core = ROOT }
						}
						add_permanent_claim = ROOT
					}
				}
			}
		}
	}
	byz2_retribution_for_yarmuk_mission = {
		icon = mission_camel_cataphracts_prt_sas
		required_missions = { byz2_anatolic_consolidation_mission }
		position = 8
		provinces_to_highlight = {
			OR = {
				AND = {
					province_id = 2313		#Antioch
					NOT = {
						owned_by = ROOT
						is_core = ROOT
					}
				}
				AND = {
					OR = {
						area = aleppo_area
						area = syria_area
					}
					NOT = {
						country_or_non_sovereign_subject_holds = ROOT
					}
				}
			}
			has_discovered = ROOT
		}
		trigger = {
			owns_core_province = 2313
			aleppo_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			syria_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
		}
		effect = {
			country_event = {
				id = mmetr_BYZ_mission_events.7
			}
			tooltip = {
				if = {
					limit = {
						uses_patriarch_authority = yes
					}
					add_patriarch_authority = 0.05
				}
				aleppo_area = {
					limit = {
						country_or_non_sovereign_subject_holds = ROOT
					}
					add_province_modifier = {
						name = "me_byz2_domestic_of_the_schools_of_the_east"
						duration = 7300
					}
				}
				379 = {		#Jerusalem
					limit = {
						NOT = { is_core = ROOT }
					}
					add_permanent_claim = ROOT
				}
			}
		}
	}
	byz2_protect_the_true_cross_mission = {
		icon = jerusalem
		required_missions = { byz2_retribution_for_yarmuk_mission }
		position = 9
		provinces_to_highlight = {
			province_id = 379
			OR = {
				NOT = {
					owned_by = ROOT
					is_core = ROOT
				}
				has_owner_religion = no
			}
			has_discovered = ROOT
		}
		trigger = {
			owns_core_province = 379
			379 = {
				has_owner_religion = yes
			}
			num_of_owned_provinces_with = {
				value = 7
				OR = {
					area = palestine_area
					area = trans_jordan_area
				}
			}
		}
		effect = {
			tooltip = {
				if = {
					limit = {
						uses_patriarch_authority = yes
					}
					add_patriarch_authority = 0.05
				}
				add_country_modifier = {
					name = "me_byz2_patriarch_of_jerusalem"
					duration = 7300
				}
				358 = {		#Alexandria
					add_permanent_claim = ROOT
				}
			}
			country_event = {
				id = mmetr_BYZ_mission_events.8
			}
		}
	}
	byz2_annexation_of_aegyptos_mission = {
		icon = mission_conquer_alexandria
		required_missions = { byz2_protect_the_true_cross_mission }
		position = 11
		provinces_to_highlight = {
			OR = {
				AND = {
					province_id = 358	#Alexandria
					NOT = {
						owned_by = ROOT
						is_core = ROOT
					}
				}
				AND = {
					region = egypt_region
					NOT = {
						country_or_non_sovereign_subject_holds = ROOT
					}
				}
			}
			NOT = {
				country_or_non_sovereign_subject_holds = ROOT
			}
			has_discovered = ROOT
		}
		trigger = {
			owns_core_province = 358
			num_of_provinces_owned_or_owned_by_non_sovereign_subjects_with = {
				value = 15
				region = egypt_region
			}
		}
		effect = {
			add_country_modifier = {
				name = "me_byz2_egyptian_agriculture"
				duration = 7300
			}
		}
	}
	byz2_exarchatus_africae_mission = {
		icon = africa_proconsulare
		required_missions = { byz2_annexation_of_aegyptos_mission }
		position = 13
		provinces_to_highlight = {
			OR = {
				area = tunisia_area
				area = kabylia_area
				province_id = 2453
				province_id = 353
				province_id = 2452
				province_id = 354
				province_id = 2451
			}
			NOT = {
				owned_by = ROOT
			}
			has_discovered = ROOT
		}
		trigger = {
			tunisia_area = {
				type = all
				owned_by = ROOT
			}
			kabylia_area = {
				type = all
				owned_by = ROOT
			}
			owns = 2453
			owns = 353
			owns = 2452
			owns = 354
			owns = 2451
		}
		effect = {
			tunisia_area = {
				limit = {
					owned_by = ROOT
				}
				add_province_modifier = {
					name = "me_byz2_exarchate_of_africa"
					duration = 7300
				}
			}
		}
	}
	byz2_avenge_the_altavans_mission = {
		icon = mission_staking_claim_dagger
		required_missions = { byz2_exarchatus_africae_mission }
		position = 14
		provinces_to_highlight = {
			OR = {
				area = barbary_coast_area
				area = algiers_area
				area = fez_area
				area = northern_morocco_area
			}
			NOT = {
				country_or_non_sovereign_subject_holds = ROOT
			}
			has_discovered = ROOT
		}
		trigger = {
			barbary_coast_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			algiers_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			fez_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			northern_morocco_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
		}
		effect = {
			maghreb_region = {
				limit = {
					country_or_non_sovereign_subject_holds = ROOT
				}
				add_province_modifier = {
					name = "me_byz2_dux_mauretaniae"
					duration = 7300
				}
			}
		}
	}
	
}

byzantium_post_islam_mmetr_missions_5 = {
	slot = 5
	generic = no
	ai = yes
	potential = {
		OR = {
			tag = BYZ
		}
		started_in = 641.1.1
		NOT = { started_in = 1204.1.1 }
		NOT = { map_setup = map_setup_random }
	}
	has_country_shield = yes
	
	byz2_merchant_guilds_mission = {
		icon = sources_of_trade
		required_missions = {  }
		position = 1
		provinces_to_highlight = {
			OR = {
				AND = {
					province_id = 1320
					NOT = {
						trade_share = {
							country = ROOT
							share = 60
						}
					}
				}
				AND = {
					province_id = 151
					NOT = {
						owned_by = ROOT
						is_core = ROOT
					}
				}
			}
			has_discovered = ROOT
		}
		trigger = {
			owns_core_province = 151
			1320 = {
				trade_share = {
					country = ROOT
					share = 60
				}
			}
			OR = {
				estate_loyalty = {
					estate = estate_burghers
					loyalty = 80
				}
				num_of_estate_agendas_completed = {
					estate = estate_burghers
					value = 4
				}
			}
		}
		effect = {
			add_dip_power = 25
			add_country_modifier = {
				name = "me_byz2_trade_control"
				duration = 10950
			}
		}
	}
	byz2_byzantine_silk_mission = {
		icon = purely_for_commerce
		required_missions = { byz2_merchant_guilds_mission }
		position = 2
		provinces_to_highlight = {
			OR = {
				trade_goods = cloth
				trade_goods = silk
			}
			OR = {
				NOT = { owned_by = ROOT }
				AND = {
					owned_by = ROOT
					NOT = {
						base_production = 7
					}
				}
			}
			has_discovered = ROOT
		}
		trigger = {
			num_of_owned_provinces_with = {
				value = 10
				OR = {
					trade_goods = cloth
					trade_goods = silk
				}
				base_production = 7
			}
		}
		effect = {
			add_country_modifier = {
				name = "me_byz2_byzantine_silk_road"
				duration = 9125
			}
		}
	}
	byz2_the_bearded_ones_mission = {
		icon = mission_noble_council
		required_missions = { byz2_byzantine_silk_mission byz2_grain_of_the_empire_mission }
		position = 3
		trigger = {
			NOT = { corruption = 1 } 
			has_adm_advisor_3 = yes 
			has_dip_advisor_3 = yes 
			has_mil_advisor_3 = yes
			OR = {
				num_of_different_cultures_in_court = 2
				num_of_different_religions_in_court = 2
				stability = 3
			}
		}
		effect = {
			country_event = {
				id = mmetr_BYZ_mission_events.10
			}
		}
	}
	byz2_war_through_diplomacy_mission = {
		icon = mission_dove_peace_diplomacy
		required_missions = {  }
		position = 4
		trigger = {
			calc_true_if = {
				all_known_country = {
					has_opinion = {
						who = ROOT
						value = 170
					}
					OR = {
						is_subject_of = ROOT
						alliance_with = ROOT
					}
				}
				amount = 2
			}
		}
		effect = {
			add_country_modifier = {
				name = "influential_diplomacy"
				duration = 9125 #25 years
			}
		}
	}
	byz2_strengthen_the_cavalry_mission = {		#Katafraktoi
		icon = mission_sassanid_golden_cataphract_attack
		required_missions = { byz2_war_through_diplomacy_mission }
		position = 5
		trigger = {
			army_tradition = 90
			OR = {
				num_of_cavalry = 10
				cavalry_fraction = 0.1
			}
		}
		effect = {
			add_country_modifier = {
				name = "me_byz2_katafraktoi"
				duration = 7300
			}
		}
	}
	byz2_military_reforms_mission = {
		icon = mission_constantinople
		required_missions = { byz2_strengthen_the_cavalry_mission byz2_recruit_the_tagmata_mission }
		position = 6
		trigger = {
			monthly_mil = 11
		}
		effect = {
			add_country_modifier = {
				name = "me_byz2_reformed_troops"
				duration = 10950
			}
		}
	}
	byz2_armenian_subjects_mission = {
		icon = mission_georgian_warrior
		required_missions = { byz2_anatolic_consolidation_mission }
		position = 7
		provinces_to_highlight = {
			OR = {
				area = armenia_area
				area = kartli_kakheti_area
				area = imereti_area
				area = samtskhe_area
			}
			NOT = {
				country_or_non_sovereign_subject_holds = ROOT
			}
			has_discovered = ROOT
		}
		trigger = {
			armenia_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			kartli_kakheti_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			imereti_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			samtskhe_area = {
				type = all
				country_or_non_sovereign_subject_holds = ROOT
			}
			OR = {
				overlord_of = ARM
				NOT = { exists = ARM }
			}
		}
		effect = {
			custom_tooltip = byz2_armenian_subjects_mission.tt
			country_event = {
				id = mmetr_BYZ_mission_events.15
			}
			armenia_area = {
				add_province_modifier = {
					name = "me_byz2_missionaries_in_armenia"
					duration = 5475
				}
			}
		}
	}
	byz2_heraclius_woes_mission = {
		icon = arm_holy_sites
		required_missions = { byz2_armenian_subjects_mission byz2_protect_the_true_cross_mission }
		position = 10
		provinces_to_highlight = {
			OR = {
				area = armenia_area
				area = kartli_kakheti_area
				area = imereti_area
				area = samtskhe_area
			}
			NOT = {
				has_owner_religion = yes
				OR = {
					owned_by = ROOT
					owner = {
						has_matching_religion = ROOT
					}
				}
			}
			has_discovered = ROOT
		}
		trigger = {
			armenia_area = {
				type = all
				has_owner_religion = yes
				OR = {
					owned_by = ROOT
					owner = {
						has_matching_religion = ROOT
					}
				}
			}
			kartli_kakheti_area = {
				type = all
				has_owner_religion = yes
				OR = {
					owned_by = ROOT
					owner = {
						has_matching_religion = ROOT
					}
				}
			}
			imereti_area = {
				type = all
				has_owner_religion = yes
				OR = {
					owned_by = ROOT
					owner = {
						has_matching_religion = ROOT
					}
				}
			}
			samtskhe_area = {
				type = all
				has_owner_religion = yes
				OR = {
					owned_by = ROOT
					owner = {
						has_matching_religion = ROOT
					}
				}
			}
		}
		effect = {
			if = {
				limit = {
					uses_patriarch_authority = yes
				}
				add_patriarch_authority = 0.05
			}
			add_country_modifier = {
				name = "me_byz2_reunited_eastern_doctrine"
				duration = 5475
			}
		}
	}
	byz2_cultivate_alexandreia_mission = {
		icon = mission_library_ancient
		required_missions = { byz2_annexation_of_aegyptos_mission }
		position = 12
		provinces_to_highlight = {
			province_id = 358
			NOT = {
				owned_by = ROOT
				is_core = ROOT
				num_of_times_improved_by_owner = 5
				num_of_buildings_in_province = 3
			}
			has_discovered = ROOT
		}
		trigger = {
			owns_core_province = 358		#Alexandria
			358 = {
				num_of_times_improved_by_owner = 5
			}
			358 = {
				num_of_buildings_in_province = 3
			}
		}
		effect = {
			if = {
				limit = {
					uses_patriarch_authority = yes
				}
				add_patriarch_authority = 0.05
			}
			add_country_modifier = {
				name = "me_byz2_scholars_of_aegyptos"
				duration = 7300
			}
		}
	}
	byz2_nova_romas_breadbasket_mission = {
		icon = mission_latin_farmer_latifundia
		required_missions = { byz2_exarchatus_africae_mission }
		position = 14
		provinces_to_highlight = {
			province_id = 341
			NOT = {
				num_of_times_improved_by_owner = 5
				owned_by = ROOT
				is_core = ROOT
				base_production = 9
			}
			OR = {
				NOT = {
					has_building = storehouse
				}
				NOT = {
					has_building = windmill
				}
				NOT = {
					has_building = workshop
				}
			}
			has_discovered = ROOT
		}
		trigger = {
			owns_core_province = 341	#Carthage
			341 = {
				base_production = 9
			}
			341 = {
				num_of_times_improved_by_owner = 5
			}
			341 = {
				OR = {
					has_building = storehouse
					has_building = windmill
					has_building = workshop
				}
			}
		}
		effect = {
			341 = {
				add_province_modifier = {
					name = "me_byz2_breadbasket_restored"
					duration = 5475
				}
			}
		}
	}
	byz2_reconcile_african_faith_mission = {
		icon = mission_arius_arianism
		required_missions = { byz2_avenge_the_altavans_mission byz2_nova_romas_breadbasket_mission }
		position = 15
		provinces_to_highlight = {
			OR = {
				area = tunisia_area
				area = kabylia_area
				area = barbary_coast_area
				area = algiers_area
				area = fez_area
				area = northern_morocco_area
			}
			NOT = {
				owned_by = ROOT
				has_owner_religion = yes
			}
			has_discovered = ROOT
		}
		trigger = {
			num_of_owned_provinces_with = {
				value = 10
				OR = {
					has_building = temple
					has_building = cathedral
				}
			}
			tunisia_area = {
				type = all
				owned_by = ROOT
				has_owner_religion = yes
			}
			kabylia_area = {
				type = all
				owned_by = ROOT
				has_owner_religion = yes
			}
			barbary_coast_area = {
				type = all
				owned_by = ROOT
				has_owner_religion = yes
			}
			algiers_area = {
				type = all
				owned_by = ROOT
				has_owner_religion = yes
			}
			fez_area = {
				type = all
				owned_by = ROOT
				has_owner_religion = yes
			}
			northern_morocco_area = {
				type = all
				owned_by = ROOT
				has_owner_religion = yes
			}
		}
		effect = {
			add_country_modifier = {
				name = "me_byz2_heresies_quashed"
				duration = 9125
			}
		}
	}
}
