###########################
# Magagaskar Events
###########################

add_namespace = mag
add_namespace = magfla

country_event = { #  Heydrich Departs Madagaskar
	id = mag.1
	immediate = {log = "[GetDateText]: [Root.GetName]: event mag.1"}
	title = mag.1.t
	desc = {
		text = mag.1.d
	trigger = { has_global_flag = MAF_collapse }
	}
	desc = {
		text = mag.1.d.heydrich_maf
	trigger = {
			MAF = {
				has_country_leader = {
					name = "Reinhard Heydrich"
					ruling_only = yes
				}
			}
		}
	}
	desc = {
		text = mag.1.d.heydrich_fired
	trigger = {
			OR = {
				MAF = { has_completed_focus = MAF_theendofheydrich }
				has_country_flag = MAG_heydrich_fired
			}
		}
	}
	picture = GFX_report_event_MAG_Emil_Maurice_eventpic

	fire_only_once = yes

trigger = {
		NOT = {
			has_completed_focus = MAG_the_coup
		}
	}
	
	is_triggered_only = yes

	option = {
		name = mag.1.a
		ai_chance = { factor = 100 }
		retire_country_leader = yes
		set_politics = {
			ruling_party = authoritarian_democrat
			elections_allowed = no
		}
		create_country_leader = {
			name = "Emil Maurice"
			desc = "POLITICS_MAURICE_DESC"
			picture = "gfx/leaders/MAG/MAG_Emil_Maurice.png"
			expire = "1.1.1"
			ideology = colonial_govt_subtype

		}
		random_unit_leader = {
			limit = { has_id = 69420 }			
			remove_unit_leader = yes
		}
		effect_tooltip = { remove_ideas = MAG_Mittelafrikan_Fleet }
		TZN = {
			create_navy_leader = {
				name = "Reinhard Heydrich"
				portrait_path = "gfx/leaders/MAF/Portrait_Mittelafrika_Reinhard_Heydrich.png"
	
				skill = 2
				attack_skill = 1
				defense_skill = 2
				maneuvering_skill = 2
				coordination_skill = 2
				id = 36863
			}
			create_country_leader = {
				name = "Reinhard Heydrich"
				desc = "POLITICS_HEYDRICH_DESC"
				picture = "gfx/leaders/MAF/Portrait_Mittelafrika_Reinhard_Heydrich.png"
				expire = "1.1.1"
				ideology = autocratic_colonial_govt_subtype
	
			}
		}
		if = {
			limit = { MAF = { exists = yes } }
			every_unit_leader = {
				limit = {
					has_id = 69421
					has_id = 69422
				}
				set_nationality = MAF
			}
		}
		else_if = {
			limit = { has_global_flag = MAF_collapse }
			every_unit_leader = {
				limit = {
					has_id = 69421
					has_id = 69422
				}
				set_nationality = TZN
			}
		}
		hidden_effect = {
			remove_ideas = MAG_Heydrich_Projects
			remove_ideas = MAG_Heydrich_Projects2
			remove_ideas = MAG_Heydrich_Projects3
		}
	}
}

country_event = { #  Madagaskar in 1936 Intro
	id = mag.2
	immediate = {log = "[GetDateText]: [Root.GetName]: event mag.2"}
	title = mag.2.t
	desc = mag.2.d
	picture = GFX_report_event_Madagascar

	# trigger = {
		# tag = MAG
		# MAF = {
			# has_completed_focus = MAF_theendofheydrich
		# }
	# }
	trigger = {
		is_ai = no
		NOT = { has_global_flag = player_dislikes_colonial_flavour_flag }
	}
	#minor_flavor = yes
	
	is_triggered_only = yes

	option = {
		name = mag.2.a
		ai_chance = {
			factor = 100
		}
	}
}

country_event = { #The Collapse of German Rule in Dar
	id = mag.3
	immediate = {log = "[GetDateText]: [Root.GetName]: event mag.3"}
	title = mag.3.t
	desc = mag.3.d
	picture = GFX_report_event_boma

	fire_only_once = yes

trigger = {
		NOT = {
			has_completed_focus = MAG_the_coup
		}
	}
	
	is_triggered_only = yes

	option = { #Maurice will Save us!
		name = mag.3.a
		ai_chance = {
			factor = 60
			modifier = {
				factor = 0
				OR = {
					has_game_rule = {
						rule = MAG_heydrich_fucks_up
						option = MAG_HEYDRICH_FUCKS_UP_HAVA_NAGILA
					}
					has_game_rule = {
						rule = MAG_heydrich_fucks_up
						option = MAG_HEYDRICH_FUCKS_UP_HAVA_NAGILA_TWO_STATES
					}
					has_game_rule = {
						rule = MAG_heydrich_fucks_up
						option = MAG_HEYDRICH_FUCKS_UP_KINGDOM
					}
					has_game_rule = {
						rule = MAG_heydrich_fucks_up
						option = MAG_HEYDRICH_FUCKS_UP_CROIX
					}
				}
			}
		}
		hidden_effect = {
			country_event = {
				id = east_africa_war.1
				days = 23
			}
		}
		complete_national_focus = MAG_thepanicofmaurice
		add_ideas = MAG_Massive_Disunity
		hidden_effect = {
			remove_all_ministers = yes
			add_ideas = {
				MAG_Abraham_Schrameck_hog_sco
				MAG_Bernhard_Rogge_for_ade
				MAG_Otto_Selz_eco_sco
				MAG_Erhard_Milch_sec_ade
			}
			remove_ideas = MAG_Colonial_Nation
		}
	}
	
	option = { #The Settlers Take over
		name = mag.3.b
		ai_chance = {
			factor = 30
			modifier = {
				factor = 0
				OR = {
					has_game_rule = {
						rule = MAG_heydrich_fucks_up
						option = MAG_HEYDRICH_FUCKS_UP_MAURICE
					}
					has_game_rule = {
						rule = MAG_heydrich_fucks_up
						option = MAG_HEYDRICH_FUCKS_UP_KINGDOM
					}
					has_game_rule = {
						rule = MAG_heydrich_fucks_up
						option = MAG_HEYDRICH_FUCKS_UP_CROIX
					}
				}
			}
		}
		set_party_name = {
			name = MAG_israel_social_conservative_party
			long_name = MAG_israel_social_conservative_party_long
			ideology = social_conservative
		}
		set_politics = {
			ruling_party = social_conservative
			elections_allowed = no
		}
		complete_national_focus = MAG_thesolutionofaron
		hidden_effect = {
			remove_all_ministers = yes
			add_ideas = {
				MAG_Abraham_Schrameck_hog_sco
				MAG_Felix_Hausdorff_for_sco
				MAG_Otto_Selz_eco_sco
				MAG_Fritz_Elsas_sec_sco
			}
			remove_ideas = MAG_Colonial_Nation
		}
	}
	option = { #Do Nothing
		name = mag.3.c
		ai_chance = {
			factor = 20
			modifier = {
				factor = 0
				OR = {
					has_game_rule = {
						rule = MAG_heydrich_fucks_up
						option = MAG_HEYDRICH_FUCKS_UP_MAURICE
					}
					has_game_rule = {
						rule = MAG_heydrich_fucks_up
						option = MAG_HEYDRICH_FUCKS_UP_HAVA_NAGILA
					}
					has_game_rule = {
						rule = MAG_heydrich_fucks_up
						option = MAG_HEYDRICH_FUCKS_UP_HAVA_NAGILA_TWO_STATES
					}
				}
			}
		}
		country_event = {
			id = mag.4
			days = 3
		}
		hidden_effect = { remove_ideas = MAG_Colonial_Nation }
	}
}

country_event = { #Everything is Fucked thanks to Maurice
	id = mag.4
	immediate = {
		log = "[GetDateText]: [Root.GetName]: event mag.4"
		hidden_effect = {
			MAF = { end_puppet = MAG }
			if = {
			limit = {
			MAG = {
			is_ai = yes
				}
			}
			NFA = { puppet = MAG }
			}
			else = {
			ENT = {
			add_to_faction = MAG
				}
			}
			MAG = {
				set_popularities = {
					totalist = 0
					radical_socialist = 0
					syndicalist = 0
					social_democrat = 10
					social_liberal = 0
					market_liberal = 10
					social_conservative = 20
					authoritarian_democrat = 40
					paternal_autocrat = 10
					national_populist = 10
				}
				set_politics = {
					ruling_party = authoritarian_democrat
					last_election = "1888.6.15"
					election_frequency = 48
					elections_allowed = no
				}
			}
		}
	}
	title = mag.4.t
	desc = mag.4.d
	picture = GFX_report_event_Madagascar

	fire_only_once = yes

	# trigger = {
		# tag = MAG
		# MAF = {
			# has_completed_focus = MAF_theendofheydrich
		# }
	# }
	
	is_triggered_only = yes
	
	option = { #The French Take over
		name = mag.4.a
		ai_chance = {
			factor = 50
			modifier = {
				factor = 0
				FRA = { has_country_flag = NFA_kingdom_revived }
				has_game_rule = {
					rule = MAG_heydrich_fucks_up
					option = DEFAULT
				}
			}
			modifier = {
				factor = 0
				has_game_rule = {
					rule = MAG_heydrich_fucks_up
					option = MAG_HEYDRICH_FUCKS_UP_KINGDOM
				}
			}
		}
		set_politics = {
			ruling_party = paternal_autocrat
			elections_allowed = no
		}
		complete_national_focus = MAG_thestrengthofdelarocque
		add_popularity = {
			ideology = paternal_autocrat
			popularity = 0.2
		}
		hidden_effect = {
			remove_all_ministers = yes
			add_ideas = {
				MAG_Leon_Cayla_hog_pau
				MAG_Armand_Annet_for_pau
				MAG_Maurice_Antoine_Francois_Monguillot_eco_pau
				MAG_Charles_Platon_sec_pau
			}
			set_cosmetic_tag = MAG_RN
		}
	}
	option = { #The Natives Take over
		name = mag.4.b
		ai_chance = {
			factor = 50
			modifier = {
				factor = 0
				FRA = {
					OR = {
						has_country_flag = NFA_de_la_rocque_in_charge
						has_country_flag = NFA_darnand_in_charge
					}
				}
				has_game_rule = {
					rule = MAG_heydrich_fucks_up
					option = DEFAULT
				}
			}
			modifier = {
				factor = 0
				has_game_rule = {
					rule = MAG_heydrich_fucks_up
					option = MAG_HEYDRICH_FUCKS_UP_CROIX
				}
			}
		}
		set_politics = {
			ruling_party = national_populist
			elections_allowed = no
		}
		add_popularity = {
			ideology = national_populist
			popularity = 0.2
		}
		complete_national_focus = MAG_theauspiceofrabearivelo
		hidden_effect = {
			remove_all_ministers = yes
			add_ideas = {
				MAG_Jean-Joseph_Rabearivelo_hog_npo
				MAG_Ny_Avana_Ramanantoanina_for_npo
				MAG_Jacques_Rabemananjara_eco_npo
				MAG_Gabriel_Ramanantsoa_sec_npo
			}
			set_cosmetic_tag = MAG_AF
		}
	}
}


country_event = { #Jews Intro Revent
	id = mag.5
	immediate = {log = "[GetDateText]: [Root.GetName]: event mag.5"}
	title = mag.5.t
	desc = mag.5.d
	picture = GFX_report_event_MAG_Jewish_Settlers
	trigger = {
		is_ai = no
		NOT = { has_global_flag = player_dislikes_colonial_flavour_flag }
	}
	#minor_flavor = yes
	is_triggered_only = yes
	
	option = { 
		name = mag.5.a
		ai_chance = {
			factor = 100
		}
		if = {
			limit = {
				tag = MAG
				}
			add_popularity = {
				ideology = social_conservative
				popularity = 0.02
			}
		}
	}
}

country_event = { #Maurice Intro Revent
	id = mag.6
	immediate = {log = "[GetDateText]: [Root.GetName]: event mag.6"}
	title = mag.6.t
	desc = mag.6.d
	picture = GFX_report_event_MAG_Emil_Maurice_eventpic
	trigger = {
		is_ai = no
		NOT = { has_global_flag = player_dislikes_colonial_flavour_flag }
	}
	#minor_flavor = yes
	is_triggered_only = yes
	
	option = { 
		name = mag.6.a
		ai_chance = {
			factor = 100
		}
		if = {
			limit = {
				tag = MAG
				}
			add_popularity = {
				ideology = social_conservative
				popularity = 0.02
			}
		}
	}
}

country_event = { #Heydrich Intro Revent
	id = mag.7
	immediate = {log = "[GetDateText]: [Root.GetName]: event mag.7"}
	title = mag.7.t
	desc = mag.7.d
	picture = GFX_report_event_MAG_heydrich
	trigger = {
		is_ai = no
		NOT = { has_global_flag = player_dislikes_colonial_flavour_flag }
	}
	#minor_flavor = yes
	is_triggered_only = yes
	
	option = { 
		name = mag.7.a
		ai_chance = {
			factor = 100
		}
		add_political_power = 10
		if = {
			limit = {
				tag = MAG
				}
			add_popularity = {
				ideology = authoritarian_democrat
				popularity = 0.02
			}
		}
	}
}

country_event = { #Accident event
	id = mag.8
	immediate = {log = "[GetDateText]: [Root.GetName]: event mag.8"}
	title = mag.8.t
	desc = mag.8.d
	picture = GFX_report_event_MAG_aron

	is_triggered_only = yes
	
	option = { 
		name = mag.8.a
		ai_chance = {
			factor = 100
		}
	trigger = {
			tag = MAG
		}
		if = {
			limit = {
				tag = MAG
				}
		add_political_power = -10
		set_country_flag = MAG_Heydrich_Fucked_Up_flag
		hidden_effect = {
			country_event = {
				id = mag.9
				days = 10
				}
			}
		}
	}
	option = { 
		name = mag.8.b
		ai_chance = {
			factor = 100
		}
		add_political_power = -5
	trigger = {
			NOT = {
				tag = MAG
			}
		}
	}
} 

country_event = { #Aron event
	id = mag.9
	immediate = {log = "[GetDateText]: [Root.GetName]: event mag.9"}
	title = mag.9.t
	desc = mag.9.d
	picture = GFX_report_event_MAG_aron

	fire_only_once = yes

	is_triggered_only = yes
	
	option = { 
		name = mag.9.a
		ai_chance = {
			factor = 100
		}
		add_stability = -0.02
		hidden_effect = {
			country_event = {
				id = mag.13
				days = 15
			}
		}
	}
}

country_event = { #Mad Frogs event
	id = mag.10
	immediate = {log = "[GetDateText]: [Root.GetName]: event mag.10"}
	title = mag.10.t
	desc = mag.10.d
	picture = GFX_report_event_Madagascar

	fire_only_once = yes

	is_triggered_only = yes
	
	option = { 
		name = mag.10.a
		ai_chance = {
			factor = 100
		}
		add_war_support = -0.02
		add_manpower = -100
		set_country_flag = MAG_French_Purge_flag
	}
}

country_event = { #Mad German Trigger event
	id = mag.11000
	immediate = {
		log = "[GetDateText]: [Root.GetName]: event mag.11"
		hidden_effect = {
		country_event = {
			id = mag.11
			days = 4
			}
			MAF = {
			country_event = {
				id = mag.11
				days = 4
				}			
			}
			GER = {
			country_event = {
				id = mag.11
				days = 4
				}			
			}
		}
	}

	fire_only_once = yes
	
	hidden = yes
	
trigger = {
		has_country_flag = MAG_Heydrich_Fucked_Up_flag
		has_country_flag = MAG_French_Purge_flag
	}

}

country_event = { #Mad German event
	id = mag.11
	immediate = {log = "[GetDateText]: [Root.GetName]: event mag.11"}
	title = mag.11.t
	desc = mag.11.d
	picture = GFX_report_event_MAG_heydrich

	is_triggered_only = yes
	
	option = { 
		name = mag.11.a
		ai_chance = {
			factor = 75
		}
	trigger = {
			tag = MAG
		}
		if = {
			limit = {
				tag = MAG
			}
		custom_effect_tooltip = MAG_we_must_turn_away_berlin
		set_country_flag = MAG_heydrich_timer_start_flag
		add_popularity = {
			ideology = authoritarian_democrat
			popularity = -0.02
			}
		}
	}
	option = { 
		name = mag.11.b
		ai_chance = {
			factor = 100
		}
	trigger = {
			NOT = {
				tag = MAG
			}
		}
		add_political_power = -5
	}
	option = { 
		name = mag.11.c  #Coup path
		ai_chance = {
			factor = 100
		}
	trigger = {
			tag = MAG
		}
		if = {
			limit = {
				tag = MAG
			}
		add_stability = 0.05
		add_political_power = -20
		add_popularity = {
			ideology = national_populist
			popularity = 0.03
			}
		add_popularity = {
			ideology = authoritarian_democrat
			popularity = -0.03
			}
			country_event = {
				id = mag.28
				days = 6
			}
		}
	}
}

country_event = { #A Paradise on the Surface
	id = mag.12
	immediate = {log = "[GetDateText]: [Root.GetName]: event mag.12"}
	title = mag.12.t
	desc = mag.12.d
	picture = GFX_report_event_Madagascar

	is_triggered_only = yes
	
	trigger = {
		is_ai = no
		NOT = { has_global_flag = player_dislikes_colonial_flavour_flag }
	}
	#minor_flavor = yes
	
	option = { 
		name = mag.12.a
		ai_chance = {
			factor = 100
		}
		add_stability = -0.01
	}
}

country_event = { #Heydrich Caves
	id = mag.13
	immediate = {log = "[GetDateText]: [Root.GetName]: event mag.13"}
	title = mag.13.t
	desc = mag.13.d
	picture = GFX_report_event_MAG_heydrich

	fire_only_once = yes

	is_triggered_only = yes
	
	trigger = {
		is_ai = no
		NOT = { has_global_flag = player_dislikes_colonial_flavour_flag }
	}
	#minor_flavor = yes
	
	option = { 
		name = mag.13.a
		ai_chance = {
			factor = 100
		}
		add_stability = 0.02
		add_political_power = 10
	}
}

country_event = { #Jews have a state now
	id = mag.14
	immediate = {log = "[GetDateText]: [Root.GetName]: event mag.14"}
	title = mag.14.t
	desc = mag.14.d
	picture = GFX_report_event_MAG_Jewish_Settlers

	fire_only_once = yes

	is_triggered_only = yes
	
	trigger = {
		is_ai = no
		NOT = { has_global_flag = player_dislikes_colonial_flavour_flag }
	}
	#minor_flavor = yes
	
	option = { 
		name = mag.14.a
		ai_chance = {
			factor = 100
		}
		add_stability = 0.02
		add_political_power = 10
	}
}

country_event = { #Wow turns out not everyone was happy with the Jews taking over
	id = mag.15
	immediate = {log = "[GetDateText]: [Root.GetName]: event mag.15"}
	title = mag.15.t
	desc = mag.15.d
	picture = GFX_report_event_Madagascar

	fire_only_once = yes

	is_triggered_only = yes
	
	option = { 
		name = mag.15.a
	trigger = { NOT = { is_subject_of = NFA } }
		ai_chance = {
			factor = 0
			modifier = {
				factor = 0
				has_game_rule = {
					rule = MAG_heydrich_fucks_up
					option = MAG_HEYDRICH_FUCKS_UP_HAVA_NAGILA
				}
			}
		}
		custom_effect_tooltip = MAG_split_tt
		hidden_effect = {
			create_dynamic_country = {	#Palestine Madagascar Edition
				original_tag = MAG
				copy_tag = MAG

				#State
				transfer_state = 1179
				add_state_core = 1179	
				transfer_state = 1177
				add_state_core = 1177
				
				### Leader
				create_country_leader = {
					name = "Razafinkeriefo I"
					desc = "POLITICS_RAZAFINKERIEFO_DESC"
					picture = "gfx/leaders/MAG/MAG_Marie-Louise_Razafinkeriefo.png"
					expire = "1.1.1"
					ideology = maurrassism_subtype
		
				}

				### Politics
				set_popularities = {
					totalist = 0
					radical_socialist = 0
					syndicalist = 0
					social_democrat = 10
					social_liberal = 0
					market_liberal = 10
					social_conservative = 20
					authoritarian_democrat = 10
					paternal_autocrat = 10
					national_populist = 40
				}
				set_party_name = {
					ideology = national_populist
					long_name = MAG_national_populist_party_long
					name = MAG_national_populist_party
				}
				set_politics = {
					ruling_party = national_populist
					elections_allowed = no
				}
				set_cosmetic_tag = MAG_MON

				#Units
				division_template = {
					name = "Madagaskar Garrison"
					division_names_group = GER_GAR_01

					regiments = {
						infantry = { x = 0 y = 0 }
						infantry = { x = 0 y = 1 }
						infantry = { x = 0 y = 2 }
						infantry = { x = 1 y = 0 }
						infantry = { x = 1 y = 1 }
						infantry = { x = 1 y = 2 }
					}
					priority = 0
				}
				
				1179 = {
					create_unit = {
						division = "division_template = \"Madagaskar Garrison\" start_experience_factor = 0.1"
						owner = ROOT
					}
					create_unit = {
						division = "division_template = \"Madagaskar Garrison\" start_experience_factor = 0.1"
						owner = ROOT
					}
				}
			}
		}
	}
	option = { #Doomed to the same fate as OTL
		name = mag.15.b
		ai_chance = {
			factor = 50
			modifier = {
				factor = 0
				has_game_rule = {
					rule = MAG_heydrich_fucks_up
					option = MAG_HEYDRICH_FUCKS_UP_HAVA_NAGILA_TWO_STATES
				}
			}
		}
	}
}

country_event = { #Maurice Event
	id = mag.16
	immediate = {log = "[GetDateText]: [Root.GetName]: event mag.16"}
	title = mag.16.t
	desc = mag.16.d
	picture = GFX_report_event_MAG_Emil_Maurice_eventpic

	fire_only_once = yes

	is_triggered_only = yes
	
	trigger = {
		is_ai = no
		NOT = { has_global_flag = player_dislikes_colonial_flavour_flag }
	}
	#minor_flavor = yes
	
	option = { 
		name = mag.16.a
		ai_chance = {
			factor = 100
		}
		add_political_power = 20
	}
}

country_event = { #Maurice Event
	id = mag.17
	immediate = {log = "[GetDateText]: [Root.GetName]: event mag.17"}
	title = mag.17.t
	desc = mag.17.d
	picture = GFX_report_event_MAG_Emil_Maurice_eventpic

	fire_only_once = yes

	is_triggered_only = yes
	
	trigger = {
		is_ai = no
		NOT = { has_global_flag = player_dislikes_colonial_flavour_flag }
	}
	#minor_flavor = yes
	
	option = { 
		name = mag.17.a
		ai_chance = {
			factor = 100
		}
	}
}

country_event = { #Revival Event
	id = mag.18
	immediate = {log = "[GetDateText]: [Root.GetName]: event mag.18"}
	title = mag.18.t
	desc = mag.18.d
	picture = GFX_report_event_Madagascar

	trigger = {
		is_ai = no
		NOT = { has_global_flag = player_dislikes_colonial_flavour_flag }
	}
	#minor_flavor = yes
	
	fire_only_once = yes

	is_triggered_only = yes
	
	option = { 
		name = mag.18.a
		ai_chance = {
			factor = 100
		}
		add_war_support = 0.01
	}
}

country_event = { #Revival Event
	id = mag.19
	immediate = {log = "[GetDateText]: [Root.GetName]: event mag.19"}
	title = mag.19.t
	desc = mag.19.d
	picture = GFX_report_event_Madagascar

	fire_only_once = yes

	is_triggered_only = yes
	
	trigger = {
		is_ai = no
		NOT = { has_global_flag = player_dislikes_colonial_flavour_flag }
	}
	#minor_flavor = yes
	
	option = { 
		name = mag.19.a
		ai_chance = {
			factor = 100
		}
		add_stability = 0.01
	}
}

country_event = { #FREE PLANE RIDES
	id = mag.21
	immediate = {log = "[GetDateText]: [Root.GetName]: event mag.21"}
	title = mag.21.t
	desc = mag.21.d
	picture = GFX_report_event_CUB_airforce

	fire_only_once = yes

	is_triggered_only = yes
	
	trigger = {
		is_ai = no
		NOT = { has_global_flag = player_dislikes_colonial_flavour_flag }
	}
	#minor_flavor = yes
	
	option = { 
		name = mag.21.a
		ai_chance = {
			factor = 100
		}
		add_political_power = 20
	}
}

country_event = { #Petain Visits
	id = mag.22
	immediate = {log = "[GetDateText]: [Root.GetName]: event mag.22"}
	title = mag.22.t
	desc = mag.22.d
	picture = GFX_report_event_NFA_event_Petain1

	fire_only_once = yes

	is_triggered_only = yes

	trigger = {
		is_ai = no
		NOT = { has_global_flag = player_dislikes_colonial_flavour_flag }
		NFA = {
			has_idea = NFA_Philippe_Petain_hog_pau
		}
	}
	#minor_flavor = yes
	
	option = { 
		name = mag.22.a
		ai_chance = {
			factor = 100
		}
		add_political_power = 20
	}
}

country_event = { #Piracy
	id = mag.23
	immediate = {log = "[GetDateText]: [Root.GetName]: event mag.23"}
	title = mag.23.t
	desc = mag.23.d
	picture = GFX_event_NEE_ship

	fire_only_once = yes

	is_triggered_only = yes
	
	trigger = {
		is_ai = no
		NOT = { has_global_flag = player_dislikes_colonial_flavour_flag }
	}
	#minor_flavor = yes
	
	option = { 
		name = mag.23.a
		ai_chance = {
			factor = 100
		}
	}
}

country_event = { #Tourism
	id = mag.24
	immediate = {log = "[GetDateText]: [Root.GetName]: event mag.24"}
	title = mag.24.t
	desc = mag.24.d
	picture = GFX_event_NEE_ship

	fire_only_once = yes

	is_triggered_only = yes

	trigger = {
		is_ai = no
		NOT = { has_global_flag = player_dislikes_colonial_flavour_flag }
	}
	#minor_flavor = yes
	
	option = { 
		name = mag.24.a
		ai_chance = {
			factor = 100
		}
	}
}

country_event = { #Open Ports
	id = mag.25
	immediate = {log = "[GetDateText]: [Root.GetName]: event mag.25"}
	title = mag.25.t
	desc = mag.25.d
	picture = GFX_YUN_landscape

	fire_only_once = yes

	is_triggered_only = yes
	
	trigger = {
		is_ai = no
		NOT = { has_global_flag = player_dislikes_colonial_flavour_flag }
	}
	#minor_flavor = yes
	
	option = { 
		name = mag.25.a
		ai_chance = {
			factor = 100
		}
	}
}

country_event = { #Heydrich Advert
	id = mag.26
	immediate = {log = "[GetDateText]: [Root.GetName]: event mag.26"}
	title = mag.26.t
	desc = mag.26.d
	picture = GFX_report_event_MAG_heydrich

	is_triggered_only = yes

	trigger = {
		is_ai = no
		NOT = { has_global_flag = player_dislikes_colonial_flavour_flag }
	}
	#minor_flavor = yes
	
	option = { 
		name = mag.26.a
		ai_chance = {
			factor = 0
		}
		country_event = magfla.23
		add_political_power = 5
	}
	option = { 
		name = mag.26.b
		ai_chance = {
			factor = 100
		}
	}
}

country_event = { #Return
	id = mag.27
	immediate = {log = "[GetDateText]: [Root.GetName]: event mag.27"}
	title = mag.27.t
	desc = mag.27.d
	picture = GFX_report_event_MAG_abraham_schrameck

	mean_time_to_happen = {
		days = 90
	}
	
	fire_only_once = yes

trigger = {
		tag = MAG
		has_global_flag = MAF_collapse
		OR = {
			is_subject_of = MAF
			is_subject = no
		}
		has_country_leader = { ruling_only = yes name = "Abraham Schrameck" }
		NFA = {
			OR = {
				has_government = social_democrat
				has_government = social_liberal
				has_government = market_liberal
                has_country_leader = { ruling_only = yes name = "François de la Rocque" }
				has_country_leader = { ruling_only = yes name = "Charles Vallin" }
			}
			NOT = { has_completed_focus = NFA_napoleon_restoration }
		}
	}
	
	option = { 
		name = mag.27.a
		ai_chance = {
			factor = 0
			modifier = {
				factor = 100
				NFA = { is_ai = no }
			}
		}
		hidden_effect = {
			if = {
				limit = { is_subject_of =  MAG }
			}
			MAF = { end_puppet = MAG }
		}
		if = {
			limit = {
			MAG = {
			is_ai = yes
			}
		}
		NFA = { 
			set_autonomy = {
				target = MAG
				autonomous_state = kx_colored_puppet
				}
			}
		}
		else = {
			ENT = {
				add_to_faction = MAG
			}
		}		
	}
	option = { 
		name = mag.27.b
		ai_chance = {
			factor = 100
			modifier = {
				factor = 0
				NFA = { is_ai = no }
			}
		}
	}
}

country_event = { #Fury at argument over Toamasina
	id = mag.28
	immediate = {log = "[GetDateText]: [Root.GetName]: event mag.28"}
	title = mag.28.t
	desc = mag.28.d
	picture = GFX_report_event_MAG_heydrich

	is_triggered_only = yes
	
	option = { 
		name = mag.28.a
	trigger = {
			tag = MAG
		}
		ai_chance = {
			factor = 100
		}
		add_stability = -0.02
		add_war_support = -0.03
		hidden_effect = {
			country_event = {
				id = mag.29 # Tana Coup
				days = 4
			}
		}
	}
	option = { 
		name = mag.28.b
		ai_chance = {
			factor = 100
		}
	trigger = {
			NOT = {
				tag = MAG
			}
		}
		hidden_effect = {
			country_event = {
				id = mag.29 # Tana Coup
				days = 4
			}
		}
		add_political_power = -10
	}
}

country_event = { #The Tana Coup
	id = mag.29
	immediate = {log = "[GetDateText]: [Root.GetName]: event mag.29"}
	title = mag.29.t
	desc = mag.29.d
	picture = GFX_report_event_praia

	is_triggered_only = yes
	
	immediate = {
	hidden_effect = {
		if = {
			limit = {
				tag = MAG
			}
			overlord = {
				set_autonomy = {
					target = ROOT
					autonomous_state = autonomy_free
				}
			}
			GER = {
				remove_from_faction = ROOT
			}
			ROOT = {
				separate_peace_all_wars = yes
			}
		}
		delete_units = {
			division_template = "Mittelafrikanische Division"
			disband = yes
		}
		delete_units = {
			division_template = "Marine-Sturmdivision"
			disband = yes
		}
		load_oob = MAG_start_rising
		if = {
			limit = {
				country_exists = MAF
			}
		1179 = {
			transfer_state_to = MAF
		}
		1178 = {
			transfer_state_to = MAF
		}
		MAF = {
			add_state_claim = 1178
			add_state_claim = 1179
			add_state_claim = 1177
			add_state_claim = 543
		}
		MAG = {
			declare_war_on = {
				target = MAF
				type = annex_everything
				}
			}
			MAF = {
				load_oob = GER_MAG
			}			
		}
		}
	}
	
	option = {
		name = mag.29.a
	trigger = {
			tag = MAG
		}
		ai_chance = {
			factor = 10
		}
		set_party_name = {
			name = MAG_israel_social_conservative_party
			long_name = MAG_israel_social_conservative_party_long
			ideology = social_conservative
		}
		set_politics = {
			ruling_party = social_conservative
			elections_allowed = no
		}
		add_popularity = {
			ideology = social_conservative
			popularity = 0.1
		}
		complete_national_focus = MAG_the_coup
		complete_national_focus = MAG_thesolutionofaron
		hidden_effect = {
			remove_all_ministers = yes
			add_ideas = {
				MAG_Abraham_Schrameck_hog_sco
				MAG_Felix_Hausdorff_for_sco
				MAG_Otto_Selz_eco_sco
				MAG_Fritz_Elsas_sec_sco
			}
			remove_ideas = MAG_Colonial_Nation
		}
	}
	option = { 
		name = mag.29.b
	trigger = {
			tag = MAG
		}
		ai_chance = {
			factor = 30
		}
		set_politics = {
			ruling_party = national_populist
			elections_allowed = no
		}
		add_popularity = {
			ideology = national_populist
			popularity = 0.2
		}
		complete_national_focus = MAG_the_coup
		complete_national_focus = MAG_theauspiceofrabearivelo
		hidden_effect = {
			remove_all_ministers = yes
			add_ideas = {
				MAG_Jean-Joseph_Rabearivelo_hog_npo
				MAG_Ny_Avana_Ramanantoanina_for_npo
				MAG_Jacques_Rabemananjara_eco_npo
				MAG_Gabriel_Ramanantsoa_sec_npo
			}
			set_cosmetic_tag = MAG_AF
		}
	}
	option = { 
		name = mag.29.c
	trigger = {
			tag = MAG
		}
		ai_chance = {
			factor = 30
		}
		set_politics = {
			ruling_party = paternal_autocrat
			elections_allowed = no
		}
		complete_national_focus = MAG_the_coup
		complete_national_focus = MAG_thestrengthofdelarocque
		add_popularity = {
			ideology = paternal_autocrat
			popularity = 0.2
		}
		hidden_effect = {
			remove_all_ministers = yes
			add_ideas = {
				MAG_Leon_Cayla_hog_pau
				MAG_Armand_Annet_for_pau
				MAG_Maurice_Antoine_Francois_Monguillot_eco_pau
				MAG_Charles_Platon_sec_pau
			}
			set_cosmetic_tag = MAG_RN
		}
	}
	option = { 
		name = mag.29.e
		ai_chance = {
			factor = 10
		}
	trigger = {
			tag = MAG
		}
		set_politics = {
			ruling_party = social_democrat
			elections_allowed = no
		}
		add_popularity = {
			ideology = social_democrat
			popularity = 0.2
		}
		load_focus_tree = African_Generic_Democracy
		complete_national_focus = MAG_the_coup
		drop_cosmetic_tag = yes
		hidden_effect = {
			remove_all_ministers = yes
		}
	}
	option = { 
		name = mag.29.f
		ai_chance = {
			factor = 100
			modifier = {
				factor = 0
				has_war_with = PAF
			}
			modifier = {
				factor = 20
				has_war = yes
			}
		}
	trigger = {
			tag = MAF
		}
		add_stability = -0.01
	}
	option = { 
		name = mag.29.g
		ai_chance = {
			factor = 100
		}
	trigger = {
			tag = MAF
		}
		1179 = {
			transfer_state_to = MAG
		}
		1178 = {
			transfer_state_to = MAG
		}
			every_country = { #white peace!
				limit = {
					has_war_with = MAG
					OR = {
						is_in_faction_with = MAF
						is_subject_of = MAF
						tag = MAF
					}
				}
				MAG = {
					white_peace = PREV
				}
			}
		add_stability = -0.01
	}
	option = { 
		name = mag.29.h
		ai_chance = {
			factor = 1
			modifier = {
				factor = 10
				has_war = no
			}
		}
	trigger = {
			tag = GER
		}
		GER = {
			declare_war_on = {
				target = MAG
				type = annex_everything
				}
			}
		add_stability = -0.01
	}
	option = { 
		name = mag.29.i
		ai_chance = {
			factor = 99
		}
	trigger = {
			tag = GER
		}
		add_stability = -0.01
	}
}

#New Flavour

country_event = { #  Reforms to SMOTIG on Madagaskar
	id = magfla.1
	immediate = { log = "[GetDateText]: [Root.GetName]: event magfla.1" }
	title = magfla.1.t
	desc = magfla.1.d
	picture = GFX_report_event_railway2
	is_triggered_only = yes

	trigger = {
		is_ai = no
		NOT = { has_global_flag = player_dislikes_colonial_flavour_flag }
	}
	#minor_flavor = yes

	option = {
		name = magfla.1.a
		ai_chance = {
			factor = 100
		}
		if = {
			limit = {
				tag = MAG
			}
			add_stability = 0.01
			add_manpower = 873
		}
		add_political_power = 5

	}
}

country_event = { # Jean Ralaimongo Assassinated
	id = magfla.2
	immediate = { log = "[GetDateText]: [Root.GetName]: event magfla.2" }
	title = magfla.2.t
	desc = magfla.2.d
	picture = GFX_report_event_railway2
	is_triggered_only = yes

trigger = {
		is_ai = no
		543 = { is_controlled_by_ROOT_or_ally = yes } #Madagaskar
	}

	option = {
		name = magfla.2.a
		ai_chance = {
			factor = 100
		}
		if = {
			limit = {
				tag = MAG
			}
			add_stability = 0.02
			add_manpower = -7
		}
		add_political_power = -10

	}
}

country_event = { # Black Monday Hits Madagascar
	id = magfla.3
	immediate = { log = "[GetDateText]: [Root.GetName]: event magfla.3" }
	title = magfla.3.t
	desc = magfla.3.d
	picture = GFX_report_event_port_rail
	is_triggered_only = yes

	trigger = {
		is_ai = no
		NOT = { has_global_flag = player_dislikes_colonial_flavour_flag }
	}
	#minor_flavor = yes

	option = {
		name = magfla.3.a
		ai_chance = {
			factor = 100
		}
		if = {
			limit = {
				tag = MAG
			}
			543 = {
				remove_building = {
					type = dockyard
					level = 1
				}
			}
			add_stability = -0.1
			add_war_support = -0.05
			add_political_power = -100
		}
		if = {
			limit = {
				NOT = { tag = MAG }
			}
		add_political_power = -10
		}

	}
}

country_event = { # Société Sucrière de Madagascar Shuts Down
	id = magfla.4
	immediate = { log = "[GetDateText]: [Root.GetName]: event magfla.4" }
	title = magfla.4.t
	desc = magfla.4.d
	picture = GFX_report_event_factory
	is_triggered_only = yes

	trigger = {
		is_ai = no
		NOT = { has_global_flag = player_dislikes_colonial_flavour_flag }
	}
	#minor_flavor = yes

	option = {
		name = magfla.4.a
		ai_chance = {
			factor = 100
		}
		if = {
			limit = {
				tag = MAG
			}
			add_stability = -0.03
		}
		add_political_power = -5

	}
}

country_event = { # Schuztruppe Desecrate Ambohimanga
	id = magfla.5
	immediate = { log = "[GetDateText]: [Root.GetName]: event magfla.5" }
	title = magfla.5.t
	desc = magfla.5.d
	picture = GFX_report_event_lake
	is_triggered_only = yes

	trigger = {
		is_ai = no
		NOT = { has_global_flag = player_dislikes_colonial_flavour_flag }
	}
	#minor_flavor = yes
	option = {
		name = magfla.5.a
		ai_chance = {
			factor = 100
		}
		if = {
			limit = {
				tag = MAG
			}
			add_political_power = -30
		}
		if = {
			limit = {
				NOT = { tag = MAG }
			}
			add_political_power = -5
		}

	}
}

country_event = { # Ranavalona III's Body Returned to Manjakamiadana
	id = magfla.6
	immediate = { log = "[GetDateText]: [Root.GetName]: event magfla.6" }
	title = magfla.6.t
	desc = magfla.6.d
	picture = GFX_report_event_railway
	is_triggered_only = yes

	trigger = {
		is_ai = no
		NOT = { has_global_flag = player_dislikes_colonial_flavour_flag }
	}
	#minor_flavor = yes

	option = {
		name = magfla.6.a
		ai_chance = {
			factor = 100
		}
		if = {
			limit = {
				tag = MAG
			}
			add_stability = 0.02
		}
		if = {
			limit = {
				NOT = { tag = MAG }
				}
			add_political_power = 10
		}
	}
}

country_event = { # League for the Protection of Fomba
	id = magfla.7
	immediate = { log = "[GetDateText]: [Root.GetName]: event magfla.7" }
	title = magfla.7.t
	desc = magfla.7.d
	picture = GFX_report_event_railway
	is_triggered_only = yes

trigger = {
		is_ai = no
		543 = { is_controlled_by_ROOT_or_ally = yes } #Madagaskar
	}

	option = {
		name = magfla.7.a
		ai_chance = {
			factor = 100
		}
		if = {
			limit = {
				tag = MAG
			}
			add_political_power = -20
		}
		if = {
			limit = {
				NOT = { tag = MAG }
			}
			add_political_power = -5
		}
	}
}


country_event = { # Closure of the Befelatanana Medical School
	id = magfla.8
	immediate = { log = "[GetDateText]: [Root.GetName]: event magfla.8" }
	title = magfla.8.t
	desc = magfla.8.d
	picture = GFX_report_event_nurse
	is_triggered_only = yes

	trigger = {
		is_ai = no
		NOT = { has_global_flag = player_dislikes_colonial_flavour_flag }
	}
	#minor_flavor = yes
	option = {
		name = magfla.8.a
		ai_chance = {
			factor = 100
		}
		if = {
			limit = {
				tag = MAG
			}
			add_stability = 0.02
			add_political_power = -20
		}
		if = {
			limit = {
				NOT = { tag = MAG }
			}
			add_political_power = 5
		}
	}
}

country_event = { # The Curious Incident of Count Benyovszky
	id = magfla.9
	immediate = { log = "[GetDateText]: [Root.GetName]: event magfla.9" }
	title = magfla.9.t
	desc = magfla.9.d
	picture = GFX_report_event_coast
	is_triggered_only = yes

	trigger = {
		is_ai = no
		NOT = { has_global_flag = player_dislikes_colonial_flavour_flag }
	}
	#minor_flavor = yes

	option = {
		name = magfla.9.a
		ai_chance = {
			factor = 100
		}
		if = {
			limit = {
				tag = MAG
			}
			add_political_power = 10
		}
		if = {
			limit = {
				NOT = { tag = MAG }
			}
			add_political_power = 5
		}
	}
}


country_event = { # Christian Infighting on Madagaskar
	id = magfla.10
	immediate = { log = "[GetDateText]: [Root.GetName]: event magfla.10" }
	title = magfla.10.t
	desc = magfla.10.d
	picture = GFX_report_event_church
	is_triggered_only = yes

	trigger = {
		is_ai = no
		NOT = { has_global_flag = player_dislikes_colonial_flavour_flag }
	}
	#minor_flavor = yes
	option = {
		name = magfla.10.a
		ai_chance = {
			factor = 100
		}
		if = {
			limit = {
				tag = MAG
			}
			add_political_power = -30
			add_stability = -0.02
		}
		if = {
			limit = {
				NOT = { tag = MAG }
			}
			add_political_power = -5
		}
	}
}

country_event = { # Tribal Clashes in Betsimisarakaland
	id = magfla.11
	immediate = { log = "[GetDateText]: [Root.GetName]: event magfla.11" }
	title = magfla.11.t
	desc = magfla.11.d
	picture = GFX_report_event_chiefs
	is_triggered_only = yes

trigger = {
		is_ai = no
		543 = { is_controlled_by_ROOT_or_ally = yes } #Madagaskar
	}

	option = {
		name = magfla.11.a
		ai_chance = {
			factor = 100
		}
		if = {
			limit = {
				tag = MAG
			}
			add_stability = -0.01
			add_war_support = -0.01
		}
		if = {
			limit = {
				NOT = { tag = MAG }
			}
			add_political_power = -10
		}
	}
}

country_event = { # The Three Crocodiles
	id = magfla.12
	immediate = { log = "[GetDateText]: [Root.GetName]: event magfla.12" }
	title = magfla.12.t
	desc = magfla.12.d
	picture = GFX_report_event_port_goods
	is_triggered_only = yes

	trigger = {
		is_ai = no
		NOT = { has_global_flag = player_dislikes_colonial_flavour_flag }
	}
	#minor_flavor = yes

	option = {
		name = magfla.12.a
		ai_chance = {
			factor = 100
		}
		if = {
			limit = {
				tag = MAG
			}
			add_stability = 0.01
		}
		if = {
			limit = {
				NOT = { tag = MAG }
			}
			add_political_power = 5
		}
	}
}

country_event = { # Madagaskan Concession Companies See Profits
	id = magfla.13
	immediate = { log = "[GetDateText]: [Root.GetName]: event magfla.13" }
	title = magfla.13.t
	desc = magfla.13.d
	picture = GFX_report_event_picking
	is_triggered_only = yes

	trigger = {
		is_ai = no
		NOT = { has_global_flag = player_dislikes_colonial_flavour_flag }
	}
	#minor_flavor = yes

	option = {
		name = magfla.13.a
		ai_chance = {
			factor = 100
		}
		if = {
			limit = {
				tag = MAG
			}
			add_stability = 0.02
		}
		add_political_power = 10
		if = {
			limit = {
				NOT = { tag = MAG }
			}
			add_political_power = 5
		}
	}
}

country_event = { # The Closure of Novy Lava
	id = magfla.14
	immediate = { log = "[GetDateText]: [Root.GetName]: event magfla.14" }
	title = magfla.14.t
	desc = magfla.14.d
	picture = GFX_report_event_march
	is_triggered_only = yes

trigger = {
		is_ai = no
		543 = { is_controlled_by_ROOT_or_ally = yes } #Madagaskar
	}

	option = {
		name = magfla.14.a
		ai_chance = {
			factor = 100
		}
		if = {
			limit = {
				tag = MAG
			}
			add_stability = -0.01
			add_political_power = -10
		}
		if = {
			limit = {
				NOT = { tag = MAG }
			}
			add_political_power = -5
		}
	}
}

country_event = { # Successful oil drilling at Tsimiroro 
	id = magfla.15
	immediate = { log = "[GetDateText]: [Root.GetName]: event magfla.15" }
	title = magfla.15.t
	desc = magfla.15.d
	picture = GFX_report_event_port_military
	is_triggered_only = yes

trigger = {
		is_ai = no
		543 = { is_controlled_by_ROOT_or_ally = yes } #Madagaskar
	}

	option = {
		name = magfla.15.a
		ai_chance = {
			factor = 100
		}
		1177 = {
			add_resource = {
				type = oil
				amount = 1
			}
		}
		if = {
			limit = {
				tag = MAG
			}
			add_stability = 0.01
		}
		if = {
			limit = {
				NOT = { tag = MAG }
			}
			add_political_power = 10
		}
	}
}
country_event = { # Présence Française Protests German Language Requirements
	id = magfla.16
	immediate = { log = "[GetDateText]: [Root.GetName]: event magfla.16" }
	title = magfla.16.t
	desc = magfla.16.d
	picture = GFX_report_event_announcement
	is_triggered_only = yes

trigger = {
		is_ai = no
		543 = { is_controlled_by_ROOT_or_ally = yes } #Madagaskar
	}

	option = {
		name = magfla.16.a
		ai_chance = {
			factor = 100
		}
		if = {
			limit = {
				tag = MAG
			}
			add_stability = -0.01
			add_political_power = -10
		}
		if = {
			limit = {
				NOT = { tag = MAG }
			}
			add_political_power = -5
		}
	}
}

country_event = { # Death of Prince Ramahatra of Merina
	id = magfla.17
	immediate = { log = "[GetDateText]: [Root.GetName]: event magfla.17" }
	title = magfla.17.t
	desc = magfla.17.d
	picture = GFX_report_event_square
	is_triggered_only = yes

trigger = {
		is_ai = no
		543 = { is_controlled_by_ROOT_or_ally = yes } #Madagaskar
	}

	option = {
		name = magfla.17.a
		ai_chance = {
			factor = 100
		}
		if = {
			limit = {
				tag = MAG
			}
			add_war_support = -0.01
		}
		if = {
			limit = {
				NOT = { tag = MAG }
			}
			add_political_power = -5
		}
	}
}

country_event = { # Japan and the Japanese
	id = magfla.18
	immediate = { log = "[GetDateText]: [Root.GetName]: event magfla.18" }
	title = magfla.18.t
	desc = magfla.18.d
	picture = GFX_report_event_lights
	is_triggered_only = yes

trigger = {
		is_ai = no
		OR = {
			543 = { is_controlled_by_ROOT_or_ally = yes } #Madagaskar
			tag = JAP
		}
	}

	option = {
		name = magfla.18.a
		ai_chance = {
			factor = 100
		}
		if = {
			limit = {
				tag = MAG
			}
			add_stability = -0.01
		}
		if = {
			limit = {
				NOT = { tag = MAG }
			}
			add_political_power = -5
		}
	}
}
country_event = { # Réunion-Madagaskar Colonisation Efforts
	id = magfla.19
	immediate = { log = "[GetDateText]: [Root.GetName]: event magfla.19" }
	title = magfla.19.t
	desc = magfla.19.d
	picture = GFX_report_event_boat
	is_triggered_only = yes

trigger = {
		is_ai = no
		543 = { is_controlled_by_ROOT_or_ally = yes } #Madagaskar
	}

	option = {
		name = magfla.19.a
		ai_chance = {
			factor = 100
		}
		if = {
			limit = {
				tag = MAG
				tag = DJI
			}
			add_stability = 0.01
			add_political_power = 10
		}
		if = {
			limit = {
				NOT = { tag = MAG }
			}
			add_political_power = 5
		}
	}
}
country_event = { # Office du Riz Sparks Backlash
	id = magfla.20
	immediate = { log = "[GetDateText]: [Root.GetName]: event magfla.20" }
	title = magfla.20.t
	desc = magfla.20.d
	picture = GFX_report_event_teamaking
	is_triggered_only = yes

trigger = {
		is_ai = no
		543 = { is_controlled_by_ROOT_or_ally = yes } #Madagaskar
	}

	option = {
		name = magfla.20.a
		ai_chance = {
			factor = 100
		}
		if = {
			limit = {
				tag = MAG
			}
			add_stability = -0.01
		}
		if = {
			limit = {
				NOT = { tag = MAG }
			}
			add_political_power = -5
		}
	}
}
country_event = { # Pangalanes Canal Completed in Madagaskar
	id = magfla.21
	immediate = { log = "[GetDateText]: [Root.GetName]: event magfla.21" }
	title = magfla.21.t
	desc = magfla.21.d
	picture = GFX_report_event_coast
	is_triggered_only = yes
	
trigger = {
		is_ai = no
		543 = { is_controlled_by_ROOT_or_ally = yes } #Madagaskar
	}	

	option = {
		name = magfla.21.a
		ai_chance = {
			factor = 100
		}
		add_political_power = 10
	}
}

country_event = { # Excavations at Vohemar
	id = magfla.22
	immediate = { log = "[GetDateText]: [Root.GetName]: event magfla.22" }
	title = magfla.22.t
	desc = magfla.22.d
	picture = GFX_report_event_mosque
	is_triggered_only = yes

	trigger = {
		is_ai = no
		NOT = { has_global_flag = player_dislikes_colonial_flavour_flag }
	}
	#minor_flavor = yes
	
	option = {
		name = magfla.22.a
		ai_chance = {
			factor = 100
		}
		if = {
			limit = {
				tag = MAG
			}
			add_stability = 0.01
		}
		add_political_power = 5
	}
}

country_event = { # Kaiser responds to Heydrich
	id = magfla.23
	immediate = { log = "[GetDateText]: [Root.GetName]: event magfla.23" }
	title = magfla.23.t
	desc = magfla.23.d
	picture = GFX_report_event_praia
	is_triggered_only = yes

	trigger = {
		is_ai = no
		NOT = { has_global_flag = player_dislikes_colonial_flavour_flag }
	}
	#minor_flavor = yes
	option = {
		name = magfla.23.a
		ai_chance = {
			factor = 100
		}
	}
}