###########################
# Hungarian Events
###########################

add_namespace = DOD_romania

#Jakob: 80-90
#Gabriel: 100-110

# Romania wants to strengthen the Romanian-polish Alliance - event for Poland
country_event = {
	id = DOD_romania.1
	title = DOD_romania.1.t
	desc = DOD_romania.1.desc
	picture = GFX_report_event_romania_poland_visit
	
	is_triggered_only = yes
	
	option = { #sure
		name = DOD_romania.1.a
		ai_chance = {
			factor = 70
			modifier = {
				threat > 0.2
				factor = 2
			}
			modifier = {
				threat > 0.4
				factor = 2
			}
		}
		ROM = { country_event = DOD_romania.2 }
		give_guarantee = ROM
	}

	option = { #no
		name = DOD_romania.1.b
		ai_chance = {
			factor = 30
		}
		ROM = { country_event = DOD_romania.3 }	
	}

}
#Romania wants to strengthen the Romanian-polish alliance - Poland agrees
country_event = {
	id = DOD_romania.2 
	title = DOD_romania.2.t
	desc = DOD_romania.2.desc
	picture = GFX_report_event_romania_poland_visit
	
	is_triggered_only = yes

	option = { #cool
		name = DOD_romania.2.a
		give_guarantee = POL
		hidden_effect = {
			news_event = { id = news.316 days = 1 }
		}
	}

}

#Romania wants to strengthen the Romanian-polish alliance - Poland refuses
country_event = {
	id = DOD_romania.3 
	title = DOD_romania.3.t
	desc = DOD_romania.3.desc
	picture = GFX_report_event_poland_rejects
	
	is_triggered_only = yes

	option = { #cool
		name = DOD_romania.3.a
		add_opinion_modifier = { target = FROM modifier = refused_alliance }
	}

}

# Romania creates the Cordon Sanitaire - event for POL/CZE to join
country_event = {
	id = DOD_romania.10
	title = DOD_romania.10.t
	desc = DOD_romania.10.desc
	picture = GFX_report_event_generic_conference
	
	is_triggered_only = yes
	
	option = { #sure
		name = DOD_romania.10.a
		ai_chance = {
			factor = 70
			modifier = {
				threat > 0.3
				add = 30
			}
		}
		ROM = { country_event = DOD_romania.11 }
		add_ai_strategy = {
			type = alliance
			id = ROM
			value = 200
		}
	}

	option = { #no
		name = DOD_romania.10.b
		ai_chance = {
			factor = 30
			modifier = {
				threat > 0.5
				factor = 0
			}
		}
		ROM = { country_event = DOD_romania.12 }	
	}

}
#Cordon Sanitaire - country agrees
country_event = {
	id = DOD_romania.11 
	title = DOD_romania.11.t
	desc = DOD_romania.11.desc
	picture = GFX_report_event_generic_sign_treaty3
	
	is_triggered_only = yes

	option = { #cool
		name = DOD_romania.11.a
		add_to_faction = FROM
	}

}

#Cordon sanitaire - country refuses
country_event = {
	id = DOD_romania.12 
	title = DOD_romania.12.t
	desc = DOD_romania.12.desc
	picture = GFX_report_event_poland_rejects
	
	is_triggered_only = yes

	option = { #cool
		name = DOD_romania.12.a
		add_opinion_modifier = { target = FROM modifier = refused_alliance }
	}

}

# Romania demands western guarantee
country_event = {
	id = DOD_romania.20
	title = DOD_romania.20.t
	desc = DOD_romania.20.desc
	picture = GFX_report_event_generic_rally
	
	is_triggered_only = yes
	
	option = { #sure
		name = DOD_romania.20.a
		ai_chance = {
			factor = 80
			modifier = {
				threat > 0.25
				factor = 2
			}
		}
		give_guarantee = ROM
		ROM = { country_event = DOD_romania.21 }
	}

	option = { #no
		name = DOD_romania.20.b
		ai_chance = {
			factor = 20
			modifier = {
				ROM = {
					has_added_tension_amount > 0.01
				}
				factor = 1.5 #Romania was naughty
			}
		}
		ROM = { country_event = DOD_romania.22 }	
	}

}
#western guarantee - country agrees
country_event = {
	id = DOD_romania.21 
	title = DOD_romania.21.t
	desc = DOD_romania.21.desc
	picture = GFX_report_event_generic_sign_treaty1
	
	is_triggered_only = yes

	option = { #cool
		name = DOD_romania.21.a
	}

}

#western guarantee - country refuses
country_event = {
	id = DOD_romania.22 
	title = DOD_romania.22.t
	desc = DOD_romania.22.desc
	picture = GFX_report_event_generic_read_write
	
	is_triggered_only = yes

	option = { #cool
		name = DOD_romania.22.a
		add_opinion_modifier = { target = FROM modifier = refused_alliance }
	}

}

# Romania wants to make a deal with SOV - event for SOV
country_event = {
	id = DOD_romania.30
	title = DOD_romania.30.t
	desc = {
		text = DOD_romania.30.desc
		trigger = {
			SOV = { has_government = communism }
		}
	}
	desc = {
		text = DOD_romania.30.desc_alt
		trigger = {
			NOT = { SOV = { has_government = communism } }
		}
	}
	picture = GFX_report_event_aid_pact
	
	is_triggered_only = yes
	
	option = { #sure
		name = DOD_romania.30.a
		give_guarantee = ROM
		ai_chance = {
			factor = 70
			modifier = {
				ROM = { has_government = communism }
				factor = 3
			}
			modifier = {
				ROM = { has_completed_focus = ROM_appoint_soviet_friendly_government }
				factor = 3
			}
		}
		ROM = { country_event = DOD_romania.31 }
	}

	option = { #no
		name = DOD_romania.30.b
		ai_chance = {
			factor = 0
		}
		ROM = { country_event = DOD_romania.32 }	
	}

}
#SOV agrees, gets military access in return
country_event = {
	id = DOD_romania.31 
	title = DOD_romania.31.t
	desc = DOD_romania.31.desc
	picture = GFX_report_event_soviet_soldiers
	
	is_triggered_only = yes

	option = { #cool
		name = DOD_romania.31.a
		give_military_access = SOV
	}

}

#SOV refuses
country_event = {
	id = DOD_romania.32 
	title = DOD_romania.32.t
	desc = DOD_romania.32.desc
	picture = GFX_report_event_stalin_meeting
	
	is_triggered_only = yes

	option = { #cool
		name = DOD_romania.32.a
		add_opinion_modifier = { target = FROM modifier = refused_alliance }
	}

}

# Romania puppets Bulgaria - event for Bulgaria to accept
country_event = {
	id = DOD_romania.40
	title = DOD_romania.40.t
	desc = DOD_romania.40.desc
	picture = GFX_report_event_romanian_soldiers
	
	is_triggered_only = yes
	
	option = { #sure
		name = DOD_romania.40.a
		ai_chance = {
			factor = 30
			modifier = {
				strength_ratio = { tag = ROM ratio < 0.8 }
				factor = 2
			}
			modifier = {
				strength_ratio = { tag = ROM ratio < 0.5 }
				factor = 10
			}
			modifier = {
				is_in_faction = yes
				factor = 0.5
			}
		}
		ROM = { country_event = DOD_romania.41 }
	}

	option = { #no
		name = DOD_romania.40.b
		ai_chance = {
			factor = 70
			modifier = {
				is_in_faction = no
				factor = 0.5
			}
		}
		ROM = { country_event = DOD_romania.42 }	
	}
	
	option = { #request to Ukraine
		name = DOD_romania.40.c
		trigger = {
			is_in_faction = no
			NOT = { has_war_with = UKR }
			UKR = {
				OR = {
					is_faction_leader = yes
					is_in_faction = no
				}
				NOT = { has_war_with = ROM }
				NOT = { is_in_faction_with = ROM }
			}
		}
		ai_chance = {
			factor = 100
		}
		UKR = { country_event = ukraine.305 }	
	}

}
#Bulgaria agrees
country_event = {
	id = DOD_romania.41 
	title = DOD_romania.41.t
	desc = DOD_romania.41.desc
	picture = GFX_report_event_generic_sign_treaty2
	
	is_triggered_only = yes

	option = { #cool
		name = DOD_romania.41.a
		puppet = BUL
		hidden_effect = {
			news_event = { id = news.318 days = 1 }
		}
	}

}

#BUL refuses
country_event = {
	id = DOD_romania.42 
	title = DOD_romania.42.t
	desc = DOD_romania.42.desc
	picture = GFX_report_event_bulgarian_soldiers
	
	is_triggered_only = yes

	option = { #cool
		name = DOD_romania.42.a
		ai_chance = {
			factor = 10
			modifier = {
				strength_ratio = { tag = BUL ratio < 1 }
				factor = 10
			}
			modifier = {
				BUL = {
					is_in_faction = yes
				}
				factor = 10
			}
		}
		
	}

	option = { #war
		name = DOD_romania.42.b
		ai_chance = {
			factor = 90
		}
		create_wargoal = {
			type = puppet_wargoal_focus
			target = BUL
		}
		news_event = { id = news.319 days = 1 }
	}

}

# Romania aligns Hungary - initial event
country_event = {
	id = DOD_romania.50
	title = DOD_romania.50.t
	desc = DOD_romania.50.desc
	picture = GFX_report_event_journalists_speech
	
	is_triggered_only = yes
	
	option = { #become their puppet
		name = DOD_romania.50.a
		ai_chance = {
			factor = 25
		}
		ROM = { country_event = DOD_romania.51 }
	}

	option = { #change government to Romanian type, enter alliance
		name = DOD_romania.50.b
		ai_chance = {
			factor = 25
		}
		ROM = { country_event = DOD_romania.52 }	
	}

	option = { #no deals
		name = DOD_romania.50.c
		ai_chance = {
			factor = 50
			modifier = {
				factor = 2
				ROM = {
					is_in_faction = no
				}
			}
			modifier = {
				factor = 10
				is_in_faction = yes
			}
		}
		ROM = { country_event = DOD_romania.53 }	
	}

}
#hungary agrees to become puppet
country_event = {
	id = DOD_romania.51 
	title = DOD_romania.51.t
	desc = DOD_romania.51.desc
	picture = GFX_report_event_generic_sign_treaty2
	
	is_triggered_only = yes

	option = { #cool
		name = DOD_romania.51.a
		puppet = HUN
		set_country_flag = ROM_HUN_aligned
	}

}

#HUN offers to align somewhat
country_event = {
	id = DOD_romania.52 
	title = DOD_romania.52.t
	desc = DOD_romania.52.desc
	picture = GFX_report_event_hungary_parliament
	
	is_triggered_only = yes

	option = { #cool
		name = DOD_romania.52.a
		ai_chance = {
			factor = 80
		}
		if = {
			limit = { is_faction_leader = yes }
			add_to_faction = HUN
		}
		if = {
			limit = {
				is_in_faction = no
			}
			set_rule = { can_create_factions = yes }
			create_faction_from_template = {
				template = faction_template_BALKAN_ENTENTE_FACTION
				name = ROM_BALKAN_FACTION
			}
			add_to_faction = HUN
		}
		set_country_flag = ROM_HUN_aligned
	}

	option = { #war
		name = DOD_romania.52.b
		ai_chance = {
			factor = 20
		}
		create_wargoal = {
			type = puppet_wargoal_focus
			target = HUN
		}
		set_country_flag = HUN_ROM_puppet_war
	}

}

#HUN refuses
country_event = {
	id = DOD_romania.53 
	title = DOD_romania.53.t
	desc = DOD_romania.53.desc
	picture = GFX_report_event_hungarian_soldiers
	
	is_triggered_only = yes

	option = { #cool
		name = DOD_romania.53.a
		ai_chance = {
			factor = 10
			modifier = {
				strength_ratio = { tag = HUN ratio < 0.5 }
				factor = 7
			}
		}
	}

	option = { #war
		name = DOD_romania.53.b
		ai_chance = {
			factor = 90
			modifier = {
				has_war = yes
				factor = 0
			}
		}
		create_wargoal = {
			type = puppet_wargoal_focus
			target = HUN
		}
	}

}

# Romania wants to split Yugoslavia - initial event for Yugoslavia
country_event = {
	id = DOD_romania.60
	title = DOD_romania.60.t
	desc = DOD_romania.60.desc
	picture = GFX_report_event_yugoslavian_split
	
	is_triggered_only = yes
	
	option = { #sure
		name = DOD_romania.60.a
		ai_chance = {
			factor = 10
			modifier = {
				factor = 2
				strength_ratio = { tag = ROM ratio < 0.5 } #less than half the strength of Romania
			}
			modifier = {
				factor = 2
				strength_ratio = { tag = ROM ratio < 0.25 } #less than 1/4 the strength of Romania
			}
			modifier = {
				factor = 5
				strength_ratio = { tag = ROM ratio < 0.1 } #less than 10% the strength of Romania
			}
			modifier = {
				factor = 0
				NOT = {
					OR = {
						GER = { has_country_flag = invited_to_split_yugo }
						ITA = { has_country_flag = invited_to_split_yugo }
						HUN = { has_country_flag = invited_to_split_yugo }
					}
				}
			}
			modifier = {
				factor = 5
				GER = { has_country_flag = invited_to_split_yugo } #Scared of Germany
			}
			modifier = {
				factor = 5
				ITA = { has_country_flag = invited_to_split_yugo } #Scared of Italy
			}
			modifier = {
				factor = 2
				HUN = { has_country_flag = invited_to_split_yugo } #Scared of Hungary
			}
			modifier = {
				factor = 2
				has_idea = YUG_idea_croatian_opposition
				has_idea = YUG_idea_macedonian_opposition
			}
		}
		ROM = { country_event = DOD_romania.61 }
	}

	option = { #no
		name = DOD_romania.60.b
		ai_chance = {
			factor = 90
			modifier = {
				is_in_faction = yes
				factor = 5
			}
			modifier = {
				factor = 5
				strength_ratio = { tag = ROM ratio > 1.0 } #stronger than Romania
			}
			modifier = {
				factor = 0.5
				GER = { has_country_flag = invited_to_split_yugo } #Scared of Germany
			}
			modifier = {
				factor = 0.5
				ITA = { has_country_flag = invited_to_split_yugo } #Scared of Italy
			}
		}
		ROM = { country_event = DOD_romania.62 }	
	}

}

# Romania wants to split Yugoslavia - invitation from Romania to come help out
country_event = {
	id = DOD_romania.601
	title = DOD_romania.601.t
	desc = DOD_romania.601.desc
	picture = GFX_report_event_yugoslavian_split
	
	is_triggered_only = yes
	
	option = { #sure
		name = DOD_romania.601.a
		ai_chance = {
			factor = 10
		}
		set_country_flag = invited_to_split_yugo
		unlock_decision_category_tooltip = ROM_dividing_yugo
	}

	option = { #no
		name = DOD_romania.601.b
	}

}

# Romania wants to split Yugoslavia - Yugoslavia agrees
country_event = {
	id = DOD_romania.61
	title = DOD_romania.61.t
	desc = DOD_romania.61.desc
	picture = GFX_report_event_generic_peaceful_annexation
	
	is_triggered_only = yes
	
	option = { #cool
		name = DOD_romania.61.a
		every_country = {
			limit = {
				is_subject_of = YUG
			}
			every_owned_state = {
				limit = {
					OR = {
						has_state_flag = strongest_claimant_ROM
						is_claimed_by = ROM
					}
				}
				ROM = { transfer_state = PREV }
			}
			every_owned_state = {
				limit = {
					OR = {
						has_state_flag = strongest_claimant_GER
						AND = {
							is_claimed_by = GER
							GER = { has_country_flag = invited_to_split_yugo }
						}
					}
				}
				GER = { transfer_state = PREV }
			}
			every_owned_state = {
				limit = {
					OR = {
						has_state_flag = strongest_claimant_ITA
						AND = {
							is_claimed_by = ITA
							ITA = { has_country_flag = invited_to_split_yugo }
						}
					}
				}
				ITA = { transfer_state = PREV }
			}
			every_owned_state = {
				limit = {
					OR = {
						has_state_flag = strongest_claimant_HUN
						AND = {
							is_claimed_by = HUN
							HUN = { has_country_flag = invited_to_split_yugo }
						}
					}
				}
				HUN = { transfer_state = PREV }
			}
		}
		YUG = {
			every_owned_state = {
				limit = {
					OR = {
						has_state_flag = strongest_claimant_ROM
						is_claimed_by = ROM
					}
				}
				ROM = { transfer_state = PREV }
			}
			every_owned_state = {
				limit = {
					OR = {
						has_state_flag = strongest_claimant_GER
						AND = {
							is_claimed_by = GER
							GER = { has_country_flag = invited_to_split_yugo }
						}
					}
				}
				GER = { transfer_state = PREV }
			}
			every_owned_state = {
				limit = {
					OR = {
						has_state_flag = strongest_claimant_ITA
						AND = {
							is_claimed_by = ITA
							ITA = { has_country_flag = invited_to_split_yugo }
						}
					}
				}
				ITA = { transfer_state = PREV }
			}
			every_owned_state = {
				limit = {
					OR = {
						has_state_flag = strongest_claimant_HUN
						AND = {
							is_claimed_by = HUN
							HUN = { has_country_flag = invited_to_split_yugo }
						}
					}
				}
				HUN = { transfer_state = PREV }
			}
			hidden_effect = {
				if = {
					limit = { has_idea = YUG_idea_croatian_opposition }
					remove_ideas = YUG_idea_croatian_opposition
				}
				if = {
					limit = { has_idea = YUG_idea_macedonian_opposition }
					remove_ideas = YUG_idea_macedonian_opposition
				}
				if = {
					limit = { has_idea = YUG_idea_slovene_nationalism }
					remove_ideas = YUG_idea_slovene_nationalism
				}
			}
		}
		hidden_effect = {
			every_country = {
				limit = {
					has_country_flag = invited_to_split_yugo
				}
				clr_country_flag = invited_to_split_yugo
			}
		}
		news_event = { id = news.324 days = 1 }
	}

}

# Romania wants to split Yugoslavia - Yugoslavia refuses
country_event = {
	id = DOD_romania.62
	title = DOD_romania.62.t
	desc = DOD_romania.62.desc
	picture = GFX_report_event_yugoslavian_cavalry
	
	is_triggered_only = yes
	
	option = { #unliateral action
		name = DOD_romania.62.a
		ai_chance = {
			factor = 75
		}
		declare_war_on = {
			target = YUG
			type = annex_everything
		}
		every_country = {
			limit = {
				has_country_flag = invited_to_split_yugo
				NOT = { tag = ROM }
			}
			declare_war_on = {
				target = YUG
				type = annex_everything
			}
		}
		hidden_effect = {
			every_country = {
				limit = {
					has_country_flag = invited_to_split_yugo
				}
				clr_country_flag = invited_to_split_yugo
			}
		}
		news_event = { id = news.320 days = 1 }
	}

#	option = { # approach Germans and Italians for joint action
#		name = DOD_romania.62.b
#		trigger = {
#			OR = {
#				GER = {
#					NOT = { owns_state = 102 }
#				}
#				ITA = {
#					NOT = { owns_state = 103 }
#				}
#			}
#		}
#		ai_chance = {
#			factor = 25
#		}
#		if = {
#			limit = { GER = { NOT = { owns_state = 102 } } }
#			GER = { country_event = DOD_romania.63 }	
#		}
#		if = {
#			limit = { 
#				ITA = { 
#					NOT = { owns_state = 103 } 
#				} 
#				GER = { owns_state = 102 }
#			}
#			ITA = { country_event = DOD_romania.64 }
#			
#		}
#		
#	}

}

# Romania wants to split Yugoslavia - Germany approached
country_event = {
	id = DOD_romania.63
	title = DOD_romania.63.t
	desc = DOD_romania.63.desc
	picture = [GetHitlerHandshakeEventPicture]
	
	is_triggered_only = yes
	
	option = { #certainly
		name = DOD_romania.63.a
		ai_chance = {
			factor = 80
		}
		add_state_claim = 102
		add_state_claim = 853
		ROM = { 
			country_event = DOD_romania.65 
			set_country_flag = ROM_YUG_GER_approves
		}
		ITA = { country_event = DOD_romania.64 }	
	}

	option = { # rather not
		name = DOD_romania.63.b
		ai_chance = {
			factor = 20
		}
		ROM = { country_event = DOD_romania.66 }
		ITA = { country_event = DOD_romania.64 }	
	}

}

# Romania wants to split Yugoslavia - Italy approached
country_event = {
	id = DOD_romania.64
	title = DOD_romania.63.t
	desc = DOD_romania.64.desc
	picture = GFX_report_event_generic_read_write
	
	is_triggered_only = yes
	
	option = { #certainly
		name = DOD_romania.63.a
		ai_chance = {
			factor = 80
				modifier = {
					factor = 10 #that sounds great!	
					has_completed_focus = ITA_balkan_ambition
				}
		}
		if = {
			limit = {
				NOT = { 103 = {is_claimed_by = ITA } }
			}
			add_state_claim = 103
		}
		ROM = { 
			country_event = DOD_romania.65 
			set_country_flag = ROM_YUG_ITA_approves
		}
		ROM = { country_event = { id = DOD_romania.67 hours = 12 } }
	}

	option = { # rather not
		name = DOD_romania.63.b
		ai_chance = {
			factor = 25
		}
		ROM = { country_event = DOD_romania.66 }
		if = {
			limit = {
				102 = { is_claimed_by = GER }
			}
			ROM = { country_event = { id = DOD_romania.67 hours = 12 } }
		}
		if = {
			limit = {
				NOT = { 102 = { is_claimed_by = GER } }
			}
			ROM = { country_event = { id = DOD_romania.68 hours = 12 } }
		}
	}
}

# Romania wants to split Yugoslavia - country approves
country_event = {
	id = DOD_romania.65
	title = DOD_romania.65.t
	desc = DOD_romania.65.desc
	picture = GFX_report_event_military_planning
	
	is_triggered_only = yes
	
	option = { #cool
		name = DOD_romania.65.a

	}

}

# Romania wants to split Yugoslavia - country refuses
country_event = {
	id = DOD_romania.66
	title = DOD_romania.66.t
	desc = DOD_romania.66.desc
	picture = GFX_report_event_generic_read_write
	
	is_triggered_only = yes
	
	option = { #shame
		name = DOD_romania.66.a

	}

}

# Romania wants to split Yugoslavia - Romania got some allies
country_event = {
	id = DOD_romania.67
	title = DOD_romania.67.t
	desc = DOD_romania.67.desc
	picture = GFX_report_event_german_inspect_troops
	
	is_triggered_only = yes
	
	option = { #send an ultimatum
		name = DOD_romania.67.a
		YUG = { country_event = DOD_romania.69 }

	}

}

# Romania wants to split Yugoslavia - Romania did not get some allies
country_event = {
	id = DOD_romania.68
	title = DOD_romania.68.t
	desc = DOD_romania.68.desc
	picture = GFX_report_event_romanian_soldiers
	
	is_triggered_only = yes
	
	option = { #oh well
		name = DOD_romania.68.a
		create_wargoal = {
			type = annex_everything
			target = YUG
		}
		news_event = { id = news.320 days = 1 }
	}

}

# Romania wants to split Yugoslavia - Romania and allies send an ultimatum to Yugoslavia
country_event = {
	id = DOD_romania.69
	title = DOD_romania.69.t
	desc = {
		text = DOD_romania.69.desc_GER
		trigger = {
			 ROM = { 
			 	has_country_flag = ROM_YUG_GER_approves
			 	NOT = { has_country_flag = ROM_YUG_ITA_approves }
			 }
		}
	}
	desc = {
		text = DOD_romania.69.desc_ITA
		trigger = {
			 ROM = { 
			 	has_country_flag = ROM_YUG_ITA_approves
			 	NOT = { has_country_flag = ROM_YUG_GER_approves }
			 }
		}
	}
	desc = {
		text = DOD_romania.69.desc_GERITA
		trigger = {
			ROM = { 
			 	has_country_flag = ROM_YUG_GER_approves
			 	has_country_flag = ROM_YUG_ITA_approves 
			 }
		}
	}
	picture = GFX_report_event_german_troops
	
	is_triggered_only = yes
	
	option = { #agree
		name = DOD_romania.69.a
		ai_chance = {
			factor = 60
			modifier = {
				102 = { is_claimed_by = GER }
				factor = 2
			}
			modifier = {
				103 = { is_claimed_by = ITA }
				factor = 2
			}
		}
		ROM = { country_event = DOD_romania.70 }

	}

	option = { #refuse
		name = DOD_romania.69.b
		ai_chance = {
			factor = 40
			modifier = {
				is_in_faction = yes
				factor = 3
			}
		}
		ROM = { country_event = DOD_romania.71 }
		if = {
			limit = { ROM = { has_country_flag = ROM_YUG_GER_approves } }
			GER = { country_event = DOD_romania.71 }
		}
		if = {
			limit = { ROM = { has_country_flag = ROM_YUG_ITA_approves } }
			ITA = { country_event = DOD_romania.71 }
		}
	}

}

# Romania wants to split Yugoslavia - Yugoslavia agrees
country_event = {
	id = DOD_romania.70
	title = DOD_romania.70.t
	desc = DOD_romania.70.desc
	picture = GFX_report_event_yugoslavian_split
	
	is_triggered_only = yes
	
	option = { #cool
		name = DOD_romania.70.a
		if = {
			limit = {
				45 = { is_owned_by = YUG }
			}
			SER = { transfer_state = 45 }
		}
		if = {
			limit = {
				764 = { is_owned_by = YUG }
			}
			SER = { transfer_state = 764 }
		}
		if = {
			limit = {
				107 = { is_owned_by = YUG }
			}
			SER = { transfer_state = 107 }
		}
		if = {
			limit = {
				108 = { is_owned_by = YUG }
			}
			SER = { transfer_state = 108 }
		}
		if = {
			limit = {
				106 = { is_owned_by = YUG }
			}
			SER = { transfer_state = 106 }
		}
		if = {
			limit = {
				970 = { is_owned_by = YUG }
			}
			SER = { transfer_state = 970 }
		}
		puppet = SER

		if = {
			limit = {
				105 = { is_owned_by = YUG }
				has_country_flag = ROM_YUG_ITA_approves
			}
			ITA = { transfer_state = 105 }
		}
		if = {
			limit = {
				105 = { is_owned_by = YUG }
				NOT = { has_country_flag = ROM_YUG_ITA_approves }
			}
			MNT = { transfer_state = 105 }
			puppet = MNT
		}
		if = {
			limit = {
				103 = { 
					is_owned_by = YUG 
					NOT = { is_claimed_by = ITA }
				}

			}
			CRO = { transfer_state = 103 }
		}
		if = {
			limit = {
				103 = { 
					is_owned_by = YUG 
					is_claimed_by = ITA
				}

			}
			ITA = { transfer_state = 103 }
		}
		if = {
			limit = {
				104 = { is_owned_by = YUG }
			}
			CRO = { transfer_state = 104 }
		}
		if = {
			limit = {
				109 = { is_owned_by = YUG }
			}
			CRO = { transfer_state = 109 }
		}
		if = {
			limit = {
				102 = { 
					is_owned_by = YUG 
					NOT = { is_claimed_by = GER }
				}
			}
			CRO = { transfer_state = 102 }
		}
		if = {
			limit = {
				102 = { 
					is_owned_by = YUG 
					is_claimed_by = GER
				}
			}
			GER = { transfer_state = 102 }
		}
		if = {
			limit = {
				853 = { 
					is_owned_by = YUG 
					NOT = { is_claimed_by = GER }
				}
			}
			CRO = { transfer_state = 853 }
		}
		if = {
			limit = {
				853 = { 
					is_owned_by = YUG 
					is_claimed_by = GER
				}
			}
			GER = { transfer_state = 853 }
		}
		if = {
			limit = { has_country_flag = ROM_YUG_GER_approves }
			GER = { puppet = CRO }
		}
		if = {
			limit = { NOT = { has_country_flag = ROM_YUG_GER_approves } }
			puppet = CRO 
		}
		hidden_effect = {
			annex_country = { target = YUG }
			news_event = { id = news.321 days = 1 }
		}
		
	}

}

# Romania wants to split Yugoslavia - Yugoslavia has refused, allies get wargoals
country_event = {
	id = DOD_romania.71
	title = DOD_romania.71.t
	desc = DOD_romania.71.desc
	picture = GFX_report_event_generic_battle
	
	is_triggered_only = yes
	

	option = { #refuse
		name = DOD_romania.71.a
		ROM = {
			declare_war_on = {
				target = YUG
				type = take_state_focus
				generator = { 45 107 108 } 
			}
		}
		if = {
			limit = { ROM = { has_country_flag = ROM_YUG_GER_approves } }
			GER = { 
				create_wargoal = {
					target = YUG
					type = take_state_focus
					generator = { 104 102 853 109 } 
				}
			}
		}
		if = {
			limit = { ROM = { has_country_flag = ROM_YUG_ITA_approves } }
			ITA = { 
				create_wargoal = {
					target = YUG
					type = take_state_focus
					generator = { 106 103 105 } 
				}	
			}
		}
		news_event = { id = news.320 days = 1 }
	}
}

# King Carol II's lifestyle events
#Hidden dispatch event
country_event = {
	id = DOD_romania.80
	
	is_triggered_only = yes

	hidden = yes

	immediate = {
		random_list = {
			20 = { country_event = { id = DOD_romania.81 days = 160 random_days = 30 } } #villa
			20 = { country_event = { id = DOD_romania.82 days = 160 random_days = 30 } } #book
			20 = { country_event = { id = DOD_romania.83 days = 160 random_days = 30 } } #party
			20 = { country_event = { id = DOD_romania.86 days = 160 random_days = 30 } } #êmbezzlement
			20 = {
				if = {
					limit = {
						FRA = { has_war = no }
					}
					country_event = { id = DOD_romania.84 days = 160 random_days = 30 }
					else = {
						country_event = { id = DOD_romania.80 }
					}
				}
			}
			20 = {
				if = {
					limit = {
						FRA = { NOT = { has_war_with = ITA } }
					}
					country_event = { id = DOD_romania.85 days = 160 random_days = 30 }
					else = {
						country_event = { id = DOD_romania.80 }
					}
				}
			}
		}
	}
}

# King Carol II's lifestyle events - Mistress buys villa
country_event = {
	id = DOD_romania.81
	title = DOD_romania.81.t
	desc = DOD_romania.81.desc
	picture = GFX_report_event_ROM_mistress
	
	is_triggered_only = yes

	trigger = {
		has_idea = ROM_king_carol_ii_hedonist
	}

	immediate = {
		set_country_flag = DOD_romania.81_fired
	}

	option = { #Pay for it
		name = DOD_romania.81.a
		ai_chance = {
			base = 1
			modifier = {
				add = 5
				has_war = no
				amount_taken_ideas = {
					amount < 3
					slots = { political_advisor }
				}
			}
			modifier = {
				add = 5
				has_war = no
				amount_taken_ideas = {
					amount < 2
					slots = { political_advisor }
				}
			}
			modifier = {
				add = 5
				has_war = no
				amount_taken_ideas = {
					amount < 1
					slots = { political_advisor }
				}
			}			
			modifier = {
				add = 5
				amount_taken_ideas = {
					amount < 1
					slots = { army_chief }
				}
			}

		}
		add_timed_idea = { idea = ROM_king_carol_ii_consumer_penalty days = 90 }
		hidden_effect = {
			country_event = { id = DOD_romania.80 }
		}
	}
	option = { #Negotiate a deal
		name = DOD_romania.81.b
		ai_chance = {
			base = 4
			modifier = {
				add = -2
				date < 1937.01.02
				has_war = no
			}
			modifier = {
				add = 20
				OR = {
					has_war = yes
					any_other_country = {
						OR = {
							is_justifying_wargoal_against = ROOT
							has_wargoal_against = ROOT
						}
					}
				}
			}
			modifier = {
				add = 20
				date > 1937.01.02
			}
		}
		add_political_power = -90
		add_timed_idea = { idea = ROM_king_carol_ii_paid_with_pp days = 90 }
		hidden_effect = {
			country_event = { id = DOD_romania.80 }
		}
	}

}
# King Carol's Lifestyle - King bans critical book
country_event = {
	id = DOD_romania.82
	title = DOD_romania.82.t
	desc = DOD_romania.82.desc
	picture = GFX_report_event_ROM_mistress
	
	is_triggered_only = yes

	trigger = {
		has_idea = ROM_king_carol_ii_hedonist
	}

	immediate = {
		set_country_flag = DOD_romania.82_fired
	}

	option = { #keep author imprisoned
		name = DOD_romania.82.a
		ai_chance = {
			base = 1
			modifier = {
				add = 5
				has_war = no
				amount_taken_ideas = {
					amount < 3
					slots = { political_advisor }
				}
			}
			modifier = {
				add = 5
				has_war = no
				amount_taken_ideas = {
					amount < 2
					slots = { political_advisor }
				}
			}
			modifier = {
				add = 5
				has_war = no
				amount_taken_ideas = {
					amount < 1
					slots = { political_advisor }
				}
			}						
			modifier = {
				add = 5
				amount_taken_ideas = {
					amount < 1
					slots = { army_chief }
				}
			}			

			modifier = {
				add = -10
				AND = {
					neutrality < 0.5
					has_war = no
					NOT = { has_idea = ROM_mihail_sturdza }
					NOT = { has_idea = generic_democratic_reformer }
				}
			}
		}
		add_stability = -0.05
		add_popularity = { ideology = fascism popularity = 0.05 } #because she is Jewish
		add_popularity = { ideology = democratic popularity = 0.05 } #because Freedom of the Press
		hidden_effect = {
			country_event = { id = DOD_romania.80 }
		}
	}
	option = { #Release him
		name = DOD_romania.82.b
		ai_chance = {
			base = 3
		}
		add_political_power = -90
		hidden_effect = {
			country_event = { id = DOD_romania.80 }
		}
	}
}

# King Carol II's lifestyle events - King throws big party
country_event = {
	id = DOD_romania.83
	title = DOD_romania.83.t
	desc = DOD_romania.83.desc
	picture = GFX_report_event_carol_party
	
	is_triggered_only = yes
	trigger = {
		has_idea = ROM_king_carol_ii_hedonist
	}

	immediate = {
		set_country_flag = DOD_romania.83_fired
	}

	option = { #Pay for it
		name = DOD_romania.83.a
		ai_chance = {
			base = 1
			modifier = {
				add = 5
				has_war = no
				amount_taken_ideas = {
					amount < 3
					slots = { political_advisor }
				}
			}
			modifier = {
				add = 5
				has_war = no
				amount_taken_ideas = {
					amount < 2
					slots = { political_advisor }
				}
			}
			modifier = {
				add = 5
				has_war = no
				amount_taken_ideas = {
					amount < 1
					slots = { political_advisor }
				}
			}			
			modifier = {
				add = 5
				amount_taken_ideas = {
					amount < 1
					slots = { army_chief }
				}
			}

		}
		add_timed_idea = { idea = ROM_king_carol_ii_consumer_penalty days = 90 }
		hidden_effect = {
			country_event = { id = DOD_romania.80 }
		}
	}
	option = { #Negotiate a deal
		name = DOD_romania.83.b
		ai_chance = {
			base = 4
			modifier = {
				add = -2
				date < 1937.01.02
				has_war = no
			}
			modifier = {
				add = 20
				OR = {
					has_war = yes
					any_other_country = {
						OR = {
							is_justifying_wargoal_against = ROOT
							has_wargoal_against = ROOT
						}
					}
				}
			}
			modifier = {
				add = 20
				date > 1937.01.02
			}
		}
		add_political_power = -90
		add_timed_idea = { idea = ROM_king_carol_ii_paid_with_pp days = 90 }
		hidden_effect = {
			country_event = { id = DOD_romania.80 }
		}
	}
}

# King Carol II's lifestyle events - Mistress on shopping spree in France
country_event = {
	id = DOD_romania.84
	title = DOD_romania.84.t
	desc = DOD_romania.84.desc
	picture = GFX_report_event_ROM_mistress
	
	is_triggered_only = yes

	trigger = {
		has_idea = ROM_king_carol_ii_hedonist
	}

	immediate = {
		set_country_flag = DOD_romania.84_fired
	}

	option = { #Pay for it
		name = DOD_romania.84.a
		ai_chance = {
			base = 1
			modifier = {
				add = 5
				has_war = no
				amount_taken_ideas = {
					amount < 3
					slots = { political_advisor }
				}
			}
			modifier = {
				add = 5
				has_war = no
				amount_taken_ideas = {
					amount < 2
					slots = { political_advisor }
				}
			}
			modifier = {
				add = 5
				has_war = no
				amount_taken_ideas = {
					amount < 1
					slots = { political_advisor }
				}
			}			
			modifier = {
				add = 5
				amount_taken_ideas = {
					amount < 1
					slots = { army_chief }
				}
			}

		}
		add_timed_idea = { idea = ROM_king_carol_ii_consumer_penalty days = 90 }
		hidden_effect = {
			country_event = { id = DOD_romania.80 }
		}
	}
	option = { #Negotiate a deal
		name = DOD_romania.84.b
		ai_chance = {
			base = 4
			modifier = {
				add = -2
				date < 1937.01.02
				has_war = no
			}
			modifier = {
				add = 20
				OR = {
					has_war = yes
					any_other_country = {
						OR = {
							is_justifying_wargoal_against = ROOT
							has_wargoal_against = ROOT
						}
					}
				}
			}
			modifier = {
				add = 20
				date > 1937.01.02
			}
		}
		add_political_power = -90
		add_timed_idea = { idea = ROM_king_carol_ii_paid_with_pp days = 90 }
		hidden_effect = {
			country_event = { id = DOD_romania.80 }
		}
	}
}

# King Carol II's lifestyle events - King takes expensive holiday (somewhere in southern France)
country_event = {
	id = DOD_romania.85
	title = DOD_romania.85.t
	desc = DOD_romania.85.desc
	picture = GFX_report_event_carol_party
	
	is_triggered_only = yes

	trigger = {
		has_idea = ROM_king_carol_ii_hedonist
	}

	immediate = {
		set_country_flag = DOD_romania.85_fired
	}

	option = { #Pay for it
		name = DOD_romania.85.a
		ai_chance = {
			base = 1
			modifier = {
				add = 5
				has_war = no
				amount_taken_ideas = {
					amount < 3
					slots = { political_advisor }
				}
			}
			modifier = {
				add = 5
				has_war = no
				amount_taken_ideas = {
					amount < 2
					slots = { political_advisor }
				}
			}
			modifier = {
				add = 5
				has_war = no
				amount_taken_ideas = {
					amount < 1
					slots = { political_advisor }
				}
			}			
			modifier = {
				add = 5
				amount_taken_ideas = {
					amount < 1
					slots = { army_chief }
				}
			}

		}
		add_timed_idea = { idea = ROM_king_carol_ii_consumer_penalty days = 90 }
		hidden_effect = {
			country_event = { id = DOD_romania.80 }
		}
	}
	option = { #Negotiate a deal
		name = DOD_romania.85.b
		ai_chance = {
			base = 4
			modifier = {
				add = -2
				date < 1937.01.02
				has_war = no
			}
			modifier = {
				add = 20
				OR = {
					has_war = yes
					any_other_country = {
						OR = {
							is_justifying_wargoal_against = ROOT
							has_wargoal_against = ROOT
						}
					}
				}
			}
			modifier = {
				add = 20
				date > 1937.01.02
			}
		}
		add_political_power = -90
		add_timed_idea = { idea = ROM_king_carol_ii_paid_with_pp days = 90 }
		hidden_effect = {
			country_event = { id = DOD_romania.80 }
		}
	}

}

# King Carol II's lifestyle events - King aids embezzlement in the army
country_event = {
	id = DOD_romania.86
	title = DOD_romania.86.t
	desc = DOD_romania.86.desc
	picture = GFX_report_event_iww_demonstration
	
	is_triggered_only = yes

	trigger = {
		has_idea = ROM_king_carol_ii_hedonist
	}

	immediate = {
		set_country_flag = DOD_romania.86_fired
	}

	option = { #Pay for it
		name = DOD_romania.86.a
		ai_chance = {
			base = 1
			modifier = {
				add = 5
				has_war = no
				amount_taken_ideas = {
					amount < 3
					slots = { political_advisor }
				}
			}
			modifier = {
				add = 5
				has_war = no
				amount_taken_ideas = {
					amount < 2
					slots = { political_advisor }
				}
			}
			modifier = {
				add = 5
				has_war = no
				amount_taken_ideas = {
					amount < 1
					slots = { political_advisor }
				}
			}			
			modifier = {
				add = 5
				amount_taken_ideas = {
					amount < 1
					slots = { army_chief }
				}
			}

		}
		add_timed_idea = { idea = ROM_king_carol_ii_factory_penalty days = 120 }
		hidden_effect = {
			country_event = { id = DOD_romania.80 }
		}
	}
	option = { #Negotiate a deal
		name = DOD_romania.86.b
		ai_chance = {
			base = 4
			modifier = {
				add = -2
				date < 1937.01.02
				has_war = no
			}
			modifier = {
				add = 20
				OR = {
					has_war = yes
					any_other_country = {
						OR = {
							is_justifying_wargoal_against = ROOT
							has_wargoal_against = ROOT
						}
					}
				}
			}
			modifier = {
				add = 20
				date > 1937.01.02
			}
		}
		add_political_power = -90
		add_timed_idea = { idea = ROM_king_carol_ii_factory_paid_with_pp days = 90 }
		hidden_effect = {
			country_event = { id = DOD_romania.80 }
		}
	}

}

#Split CZE - GER approached by Romania
country_event = {
	id = DOD_romania.110
	title = DOD_romania.110.t
	desc = DOD_romania.110.desc 
	picture = [GetHitlerHandshakeEventPicture]
	
	is_triggered_only = yes

	option = {# agree
		name = DOD_romania.110.a
		ai_chance = {
			factor = 90
			modifier = {
				is_in_faction_with = CZE
				factor = 0
			}
		}
		ROM = { country_event = DOD_romania.111 }
	}
	option = {# no deals
		name = DOD_romania.110.b
		ai_chance = {
			factor = 10
		}
		ROM = { country_event = DOD_romania.113 }
	}
}

#Split CZE - Germany agrees
country_event = {
	id = DOD_romania.111
	title = DOD_romania.111.t
	desc = DOD_romania.111.desc 
	picture = GFX_report_event_generic_sign_treaty3
	
	is_triggered_only = yes

	option = {# agree
		name = DOD_romania.111.a
		CZE = { country_event = DOD_romania.114 }
	}
}

#Intervene in CZE - GER refuses
country_event = {
	id = DOD_romania.113
	title = DOD_romania.113.t
	desc = DOD_romania.113.desc 
	picture = GFX_report_event_german_politician_speech
	
	is_triggered_only = yes

	option = {# okay
		name = DOD_romania.113.a
		ai_chance = {
			factor = 10
		}
	}
	option = {# we shall consider force
		name = DOD_romania.113.b
		ai_chance = {
			factor = 90
		}
		add_state_claim = 70
		add_state_claim = 71
		add_state_claim = 1049
		add_state_claim = 72
		add_state_claim = 73
	}
}

#Intervene in CZE - CZE gets an ultimatum
country_event = {
	id = DOD_romania.114
	title = DOD_romania.114.t
	desc = DOD_romania.114.desc 
	picture = GFX_report_event_german_troops
	
	is_triggered_only = yes

	option = {# okay 
		name = DOD_romania.114.a
		ai_chance = {
			factor = 80
			modifier = {
				factor = 0
				OR = {
					is_in_faction = yes
					any_other_country = {
						is_major = yes
						has_guaranteed = ROOT
					}
				}
			}
			modifier = {
				GER = {
					is_in_faction_with = ROM
					is_in_faction_with = HUN
				}
				factor = 2
			}
		}
		custom_effect_tooltip = GAME_OVER_TT
		GER = {
			set_country_flag = GER_split_CZE_with_ROM_flag
			transfer_state = 9
			transfer_state = 69
			transfer_state = 972
			transfer_state = 75
			transfer_state = 74
		}
		if = {
			limit = {
				country_exists = HUN
			}
			HUN = {
				transfer_state = 664 #might as well throw them a bone
			}
			else = { #Need to get rid of everything
				SLO = { transfer_state = 664 }
			}
		}
		SLO = {
			transfer_state = 70
			transfer_state = 71
			transfer_state = 1049
			transfer_state = 72
			transfer_state = 73
			add_state_core = 70
			add_state_core = 71
			add_state_core = 1049
			add_state_core = 72
			add_state_core = 73

		}
		CUA = {
			transfer_state = 73
		}
		ROM = {
			puppet = SLO
			puppet = CUA
			CUA = { 
				set_politics = { ruling_party = neutrality elections_allowed = no } 
				inherit_technology = CZE
				set_research_slots = 2
			}
			annex_country = { target = CZE } #cleanup
		}
	}
	option = {# refuse
		name = DOD_romania.114.b
		ai_chance = {
			factor = 20
			modifier = {
				owns_state = 69
				owns_state = 972
				factor = 2
			}
			modifier = {
				strength_ratio = { tag = GER ratio > 0.75 }
				factor = 2
			}
			modifier = {
				GER = { has_war = yes }
				factor = 5
			}
		}
		GER = {
			create_wargoal = {
				type = take_state_focus
				target = CZE
				generator = { 9 69 75 74 }
			}
			country_event = DOD_romania.115
		}
		HUN = { 
			create_wargoal = {
				type = take_state_focus
				target = CZE
				generator = { 664 }
			}
			country_event = DOD_romania.115
		}
		FROM = {
			create_wargoal = {
				type = take_state_focus
				target = CZE
				generator = { 70 71 1049 72 73 }
			}
			country_event = DOD_romania.115
		}
	}
}

#Intervene in CZE - CZE defiant
country_event = {
	id = DOD_romania.115
	title = DOD_romania.115.t
	desc = DOD_romania.115.desc 
	picture = GFX_report_event_czech_soldier_01
	
	is_triggered_only = yes

	option = {# okay
		name = DOD_romania.115.a
	}
}

#Invite Foreign Motor Companies 
country_event = {
	id = DOD_romania.120
	title = DOD_romania.120.t
	desc = DOD_romania.120.desc 
	picture = GFX_report_event_generic_truck
	
	is_triggered_only = yes

	option = {# Britain
		name = DOD_romania.120.a
		ai_chance = {
			factor = 35
			modifier = {
				is_historical_focus_on = yes
				factor = 0
			}
		}
		set_country_flag = ENG_mot_chosen
		add_relation_modifier = {
			target = ENG
			modifier = ROM_foreign_motor_company
		}

		if = {
			limit = {
				has_dlc = "Arms Against Tyranny"
			}
			custom_effect_tooltip = available_mio_tt
			show_mio_tooltip = ENG_vauxhall_automotive_organization
		}
		else = {
			custom_effect_tooltip = available_designer
			show_ideas_tooltip = ROM_vauxhall
		}
	}
	option = {# Germany
		name = DOD_romania.120.b
		ai_chance = {
			factor = 35
			modifier = {
				is_historical_focus_on = yes
				factor = 0
			}
		}
		set_country_flag = GER_mot_chosen
		add_relation_modifier = {
			target = GER
			modifier = ROM_foreign_motor_company
		}

		if = {
			limit = {
				has_dlc = "Arms Against Tyranny"
			}
			custom_effect_tooltip = available_mio_tt
			show_mio_tooltip = GER_opel_organization
		}
		else = {
			custom_effect_tooltip = available_designer
			show_ideas_tooltip = ROM_opel
		}
	}
	option = {# USA
		name = DOD_romania.120.c
		ai_chance = {
			factor = 35
		}
		set_country_flag = USA_mot_chosen
		add_relation_modifier = {
			target = USA
			modifier = ROM_foreign_motor_company
		}

		if = {
			limit = {
				has_dlc = "Arms Against Tyranny"
			}
			custom_effect_tooltip = available_mio_tt
			show_mio_tooltip = USA_ford_motor_company_organization
		}
		else = {
			custom_effect_tooltip = available_designer
			show_ideas_tooltip = ROM_ford
		}
	}
}

#fighter competition - initial choice for Romania
country_event = {
	id = DOD_romania.150
	title = DOD_hungary.150.t
	desc = DOD_hungary.150.desc 
	picture = GFX_report_event_fighters
	
	is_triggered_only = yes

	option = {# light fighter
		name = DOD_hungary.150.a
		trigger = {
			OR = {
				GER = {
					is_available_fighter_HUN = yes
				}
				FRA = {
					is_available_fighter_HUN = yes
				}
				ITA = {
					is_available_fighter_HUN = yes
				}
				ENG = {
					is_available_fighter_HUN = yes
				}
				USA = {
					is_available_fighter_HUN = yes
				}
			}
		}
		ai_chance = {
			factor = 50
			modifier = {
				has_tech = fighter1
				add = -10
			}
			modifier = {
				has_tech = fighter2
				add = -10
			}
			modifier = {
				has_tech = fighter3
				factor = 0
			}
			modifier = {
				has_tech = basic_small_airframe
				add = -10
			}
			modifier = {
				has_tech = improved_small_airframe
				add = -10
			}
			modifier = {
				has_tech = advanced_small_airframe
				factor = 0
			}
		}
		if = {
			limit = {
				NOT = {
					has_dlc = "By Blood Alone"
				}
			}
			country_event = DOD_romania.151 
		}
		else = {
			country_event = DOD_romania.1511
		}
		
	}

	option = {# heavy fighter
		name = DOD_hungary.150.b
		trigger = {
			OR = {
				GER = {
					is_available_heavy_fighter_HUN = yes
				}
				FRA = {
					is_available_heavy_fighter_HUN = yes
				}
				ITA = {
					is_available_heavy_fighter_HUN = yes
				}
				ENG = {
					is_available_heavy_fighter_HUN = yes
				}
				USA = {
					is_available_heavy_fighter_HUN = yes
				}
			}
		}
		if = {
			limit = {
				NOT = {
					has_dlc = "By Blood Alone"
				}
			}
			country_event = DOD_romania.152
		}
		else = {
			country_event = DOD_romania.1521	
		}
		ai_chance = {
			factor = 50
			modifier = {
				has_tech = heavy_fighter1
				add = -10
			}
			modifier = {
				has_tech = heavy_fighter2
				add = -10
			}
			modifier = {
				has_tech = heavy_fighter3
				factor = 0
			}
			modifier = {
				has_tech = basic_medium_airframe
				add = -10
			}
			modifier = {
				has_tech = improved_medium_airframe
				add = -10
			}
			modifier = {
				has_tech = advanced_medium_airframe
				factor = 0
			}
		}
	}
}

#Fighter competition - Romania is looking for a light fighter
country_event = {
	id = DOD_romania.151
	title = DOD_hungary.151.t
	desc = {
		text = DOD_hungary.151.desc_light_fighter
		trigger = {
			NOT = { 
				has_country_flag = GER_fighter_refused
				has_country_flag = ENG_fighter_refused
				has_country_flag = USA_fighter_refused
				has_country_flag = FRA_fighter_refused
				has_country_flag = ITA_fighter_refused
			} 
		}
	}
	desc = {
		text = DOD_hungary.151.desc_light_fighter_refused
		trigger = {
			OR = {
		 		has_country_flag = GER_fighter_refused
				has_country_flag = ENG_fighter_refused
				has_country_flag = USA_fighter_refused
				has_country_flag = FRA_fighter_refused
				has_country_flag = ITA_fighter_refused
		 	}
		}
	}
	picture = GFX_report_event_fighters
	
	is_triggered_only = yes

	option = {# Select German Plane
		name = DOD_hungary.151.a
		ai_chance = {
			factor = 30
			modifier = {
				is_in_faction_with = GER
				factor = 10
			}
			modifier = {
				GER = { has_government = ROOT }
				factor = 2
			}
			modifier = {
				GER = {
					has_tech = fighter1
				}
				add = 10
			}
			modifier = {
				GER = {
					has_tech = fighter2
				}
				add = 10
			}
			modifier = {
				GER = {
					has_tech = fighter3
				}
				add = 10
			}
		}
		trigger = {
			OR = {
				AND = {
					GER = { has_tech = fighter1}
					ROM = { NOT = { has_tech = fighter1 } }
				}
				AND = {
					GER = { has_tech = fighter2}
					ROM = { NOT = { has_tech = fighter2 } }
				}
				AND = {
					GER = { has_tech = fighter3}
					ROM = { NOT = { has_tech = fighter3 } }
				}
			}
			NOT = { has_war_with = GER }
			NOT = { has_country_flag = GER_fighter_refused }
		}
		GER = { country_event = DOD_romania.153 }	
	}

	option = {# select italian plane
		name = DOD_hungary.151.b
		ai_chance = {
			factor = 30
			modifier = {
				is_in_faction_with = ITA
				factor = 10
			}
			modifier = {
				ITA = { has_government = ROOT }
				factor = 2
			}
			modifier = {
				ITA = {
					has_tech = fighter1
				}
				add = 10
			}
			modifier = {
				ITA = {
					has_tech = fighter2
				}
				add = 10
			}
			modifier = {
				ITA = {
					has_tech = fighter3
				}
				add = 10
			}
		}
		trigger = {
			OR = {
				AND = {
					ITA = { has_tech = fighter1}
					ROM = { NOT = { has_tech = fighter1 } }
				}
				AND = {
					ITA = { has_tech = fighter2}
					ROM = { NOT = { has_tech = fighter2 } }
				}
				AND = {
					ITA = { has_tech = fighter3}
					ROM = { NOT = { has_tech = fighter3 } }
				}
			}
			NOT = { has_war_with = ITA }
			NOT = { has_country_flag = ITA_fighter_refused }
		}
		ITA = { country_event = DOD_romania.153 }	
	}

	option = {# select french plane
		name = DOD_hungary.151.c
		ai_chance = {
			factor = 30
			modifier = {
				is_in_faction_with = FRA
				factor = 10
			}
			modifier = {
				FRA = { has_government = ROOT }
				factor = 2
			}
			modifier = {
				FRA = {
					has_tech = fighter1
				}
				add = 10
			}
			modifier = {
				FRA = {
					has_tech = fighter2
				}
				add = 10
			}
			modifier = {
				FRA = {
					has_tech = fighter3
				}
				add = 10
			}
		}
		trigger = {
			OR = {
				AND = {
					FRA = { has_tech = fighter1}
					ROM = { NOT = { has_tech = fighter1 } }
				}
				AND = {
					FRA = { has_tech = fighter2}
					ROM = { NOT = { has_tech = fighter2 } }
				}
				AND = {
					FRA = { has_tech = fighter3}
					ROM = { NOT = { has_tech = fighter3 } }
				}
			}
			NOT = { has_war_with = FRA }
			NOT = { has_country_flag = FRA_fighter_refused }
			
		}
		FRA = { country_event = DOD_romania.153 }	
	}
	option = {# select british plane
		name = DOD_hungary.151.d
		ai_chance = {
			factor = 30
			modifier = {
				is_in_faction_with = ENG
				factor = 10
			}
			modifier = {
				ENG = { has_government = ROOT }
				factor = 2
			}
			modifier = {
				ENG = {
					has_tech = fighter1
				}
				add = 10
			}
			modifier = {
				ENG = {
					has_tech = fighter2
				}
				add = 10
			}
			modifier = {
				ENG = {
					has_tech = fighter3
				}
				add = 10
			}
		}
		trigger = {
			OR = {
				AND = {
					ENG = { has_tech = fighter1}
					ROM = { NOT = { has_tech = fighter1 } }
				}
				AND = {
					ENG = { has_tech = fighter2}
					ROM = { NOT = { has_tech = fighter2 } }
				}
				AND = {
					ENG = { has_tech = fighter3}
					ROM = { NOT = { has_tech = fighter3 } }
				}
			}
			NOT = { has_war_with = ENG }
			NOT = { has_country_flag = ENG_fighter_refused }
		}
		ENG = { country_event = DOD_romania.153 }	
	}
	option = {# select american plane
		name = DOD_hungary.151.e
		ai_chance = {
			factor = 30
			modifier = {
				is_in_faction_with = USA
				factor = 10
			}
			modifier = {
				USA = { has_government = ROOT }
				factor = 2
			}
			modifier = {
				USA = {
					has_tech = fighter1
				}
				add = 10
			}
			modifier = {
				USA = {
					has_tech = fighter2
				}
				add = 10
			}
			modifier = {
				USA = {
					has_tech = fighter3
				}
				add = 10
			}
		}
		trigger = {
			OR = {
				AND = {
					USA = { has_tech = fighter1}
					ROM = { NOT = { has_tech = fighter1 } }
				}
				AND = {
					USA = { has_tech = fighter2}
					ROM = { NOT = { has_tech = fighter2 } }
				}
				AND = {
					USA = { has_tech = fighter3}
					ROM = { NOT = { has_tech = fighter3 } }
				}
			}
			NOT = { has_war_with = USA }
			NOT = { has_country_flag = USA_fighter_refused }
			NOT = { #to prevent overflow issues
				AND = {
					GER = {
						is_available_fighter_ROM = yes
					}
					FRA = {
						is_available_fighter_ROM = yes
					}
					ITA = {
						is_available_fighter_ROM = yes
					}
					ENG = {
						is_available_fighter_ROM = yes
					}
				}
			}
		}
		USA = { country_event = DOD_romania.153 }	
	}
	option = {# failsafe
		name = DOD_hungary.151.f	
		trigger = {
			OR = {
				has_country_flag = GER_fighter_refused
				has_country_flag = ITA_fighter_refused
				has_country_flag = ENG_fighter_refused
				has_country_flag = FRA_fighter_refused
				has_country_flag = USA_fighter_refused
			}
		}
		air_experience = 50
	}

}

#Fighter competition - Romania is looking for a light fighter - BBA version
country_event = {
	id = DOD_romania.1511
	title = DOD_hungary.151.t
	desc = {
		text = DOD_hungary.151.desc_light_fighter
		trigger = {
			NOT = { 
				has_country_flag = GER_fighter_refused
				has_country_flag = ENG_fighter_refused
				has_country_flag = USA_fighter_refused
				has_country_flag = FRA_fighter_refused
				has_country_flag = ITA_fighter_refused
			} 
		}
	}
	desc = {
		text = DOD_hungary.151.desc_light_fighter_refused
		trigger = {
			OR = {
		 		has_country_flag = GER_fighter_refused
				has_country_flag = ENG_fighter_refused
				has_country_flag = USA_fighter_refused
				has_country_flag = FRA_fighter_refused
				has_country_flag = ITA_fighter_refused
		 	}
		}
	}
	picture = GFX_report_event_fighters
	
	is_triggered_only = yes

	option = {# Select German Plane
		name = DOD_hungary.151.a
		ai_chance = {
			factor = 30
			modifier = {
				is_in_faction_with = GER
				factor = 10
			}
			modifier = {
				GER = { has_government = ROOT }
				factor = 2
			}
			modifier = {
				GER = {
					has_tech = basic_small_airframe
				}
				add = 10
			}
			modifier = {
				GER = {
					has_tech = improved_small_airframe
				}
				add = 10
			}
			modifier = {
				GER = {
					has_tech = advanced_small_airframe
				}
				add = 10
			}
		}
		trigger = {
			OR = {
				AND = {
					GER = { has_tech = basic_small_airframe}
					ROM = { NOT = { has_tech = basic_small_airframe } }
				}
				AND = {
					GER = { has_tech = improved_small_airframe}
					ROM = { NOT = { has_tech = improved_small_airframe } }
				}
				AND = {
					GER = { has_tech = advanced_small_airframe}
					ROM = { NOT = { has_tech = advanced_small_airframe } }
				}
			}
			NOT = { has_war_with = GER }
			NOT = { has_country_flag = GER_fighter_refused }
		}
		GER = { country_event = DOD_romania.153 }	
	}

	option = {# select italian plane
		name = DOD_hungary.151.b
		ai_chance = {
			factor = 30
			modifier = {
				is_in_faction_with = ITA
				factor = 10
			}
			modifier = {
				ITA = { has_government = ROOT }
				factor = 2
			}
			modifier = {
				ITA = {
					has_tech = basic_small_airframe
				}
				add = 10
			}
			modifier = {
				ITA = {
					has_tech = improved_small_airframe
				}
				add = 10
			}
			modifier = {
				ITA = {
					has_tech = advanced_small_airframe
				}
				add = 10
			}
		}
		trigger = {
			OR = {
				AND = {
					ITA = { has_tech = basic_small_airframe}
					ROM = { NOT = { has_tech = basic_small_airframe } }
				}
				AND = {
					ITA = { has_tech = improved_small_airframe}
					ROM = { NOT = { has_tech = improved_small_airframe } }
				}
				AND = {
					ITA = { has_tech = advanced_small_airframe}
					ROM = { NOT = { has_tech = advanced_small_airframe } }
				}
			}
			NOT = { has_war_with = ITA }
			NOT = { has_country_flag = ITA_fighter_refused }
		}
		ITA = { country_event = DOD_romania.153 }	
	}

	option = {# select french plane
		name = DOD_hungary.151.c
		ai_chance = {
			factor = 30
			modifier = {
				is_in_faction_with = FRA
				factor = 10
			}
			modifier = {
				FRA = { has_government = ROOT }
				factor = 2
			}
			modifier = {
				FRA = {
					has_tech = basic_small_airframe
				}
				add = 10
			}
			modifier = {
				FRA = {
					has_tech = improved_small_airframe
				}
				add = 10
			}
			modifier = {
				FRA = {
					has_tech = advanced_small_airframe
				}
				add = 10
			}
		}
		trigger = {
			OR = {
				AND = {
					FRA = { has_tech = basic_small_airframe}
					ROM = { NOT = { has_tech = basic_small_airframe } }
				}
				AND = {
					FRA = { has_tech = improved_small_airframe}
					ROM = { NOT = { has_tech = improved_small_airframe } }
				}
				AND = {
					FRA = { has_tech = advanced_small_airframe}
					ROM = { NOT = { has_tech = advanced_small_airframe } }
				}
			}
			NOT = { has_war_with = FRA }
			NOT = { has_country_flag = FRA_fighter_refused }
			
		}
		FRA = { country_event = DOD_romania.153 }	
	}
	option = {# select british plane
		name = DOD_hungary.151.d
		ai_chance = {
			factor = 30
			modifier = {
				is_in_faction_with = ENG
				factor = 10
			}
			modifier = {
				ENG = { has_government = ROOT }
				factor = 2
			}
			modifier = {
				ENG = {
					has_tech = basic_small_airframe
				}
				add = 10
			}
			modifier = {
				ENG = {
					has_tech = improved_small_airframe
				}
				add = 10
			}
			modifier = {
				ENG = {
					has_tech = advanced_small_airframe
				}
				add = 10
			}
		}
		trigger = {
			OR = {
				AND = {
					ENG = { has_tech = basic_small_airframe}
					ROM = { NOT = { has_tech = basic_small_airframe } }
				}
				AND = {
					ENG = { has_tech = improved_small_airframe}
					ROM = { NOT = { has_tech = improved_small_airframe } }
				}
				AND = {
					ENG = { has_tech = advanced_small_airframe}
					ROM = { NOT = { has_tech = advanced_small_airframe } }
				}
			}
			NOT = { has_war_with = ENG }
			NOT = { has_country_flag = ENG_fighter_refused }
		}
		ENG = { country_event = DOD_romania.153 }	
	}
	option = {# select american plane
		name = DOD_hungary.151.e
		ai_chance = {
			factor = 30
			modifier = {
				is_in_faction_with = USA
				factor = 10
			}
			modifier = {
				USA = { has_government = ROOT }
				factor = 2
			}
			modifier = {
				USA = {
					has_tech = basic_small_airframe
				}
				add = 10
			}
			modifier = {
				USA = {
					has_tech = improved_small_airframe
				}
				add = 10
			}
			modifier = {
				USA = {
					has_tech = advanced_small_airframe
				}
				add = 10
			}
		}
		trigger = {
			OR = {
				AND = {
					USA = { has_tech = basic_small_airframe}
					ROM = { NOT = { has_tech = basic_small_airframe } }
				}
				AND = {
					USA = { has_tech = improved_small_airframe}
					ROM = { NOT = { has_tech = improved_small_airframe } }
				}
				AND = {
					USA = { has_tech = advanced_small_airframe}
					ROM = { NOT = { has_tech = advanced_small_airframe } }
				}
			}
			NOT = { has_war_with = USA }
			NOT = { has_country_flag = USA_fighter_refused }
			OR = {
				AND = {
					has_country_flag = GER_fighter_refused
					has_country_flag = ITA_fighter_refused
					has_country_flag = ENG_fighter_refused
					has_country_flag = FRA_fighter_refused
				}
				AND = {
					GER = { is_available_fighter_HUN = no }
					ENG = { is_available_fighter_HUN = no }
					FRA = { is_available_fighter_HUN = no }
					ITA = { is_available_fighter_HUN = no }
				}
			}
		}
		USA = { country_event = DOD_romania.153 }	
	}
	option = {# failsafe
		name = DOD_hungary.151.f	
		trigger = {
			OR = {
				has_country_flag = GER_fighter_refused
				has_country_flag = ITA_fighter_refused
				has_country_flag = ENG_fighter_refused
				has_country_flag = FRA_fighter_refused
				has_country_flag = USA_fighter_refused
			}
		}
		air_experience = 50
	}

}
#Fighter competition - Romania is looking for a heavy fighter
country_event = {
	id = DOD_romania.152
	title = DOD_hungary.152.t
	desc = {
		text = DOD_hungary.152.desc_heavy_fighter
		trigger = {
			NOT = { 
				has_country_flag = GER_heavy_fighter_refused
				has_country_flag = ENG_heavy_fighter_refused
				has_country_flag = USA_heavy_fighter_refused
				has_country_flag = FRA_heavy_fighter_refused
				has_country_flag = ITA_heavy_fighter_refused
			} 
		}
	}
	desc = {
		text = DOD_hungary.152.desc_heavy_fighter_refused
		trigger = {
			OR = {
		 		has_country_flag = GER_heavy_fighter_refused
				has_country_flag = ENG_heavy_fighter_refused
				has_country_flag = USA_heavy_fighter_refused
				has_country_flag = FRA_heavy_fighter_refused
				has_country_flag = ITA_heavy_fighter_refused
		 	}
		}
	}
	picture = GFX_report_event_fighters
	
	is_triggered_only = yes

	option = {# Select German Plane
		name = DOD_hungary.151.a
		ai_chance = {
			factor = 30
			modifier = {
				is_in_faction_with = GER
				factor = 10
			}
			modifier = {
				GER = { has_government = ROOT }
				factor = 2
			}
			modifier = {
				GER = {
					has_tech = heavy_fighter1
				}
				add = 10
			}
			modifier = {
				GER = {
					has_tech = heavy_fighter2
				}
				add = 10
			}
			modifier = {
				GER = {
					has_tech = heavy_fighter3
				}
				add = 10
			}
		}
		trigger = {
			OR = {
				AND = {
					GER = { has_tech = heavy_fighter1}
					ROM = { NOT = { has_tech = heavy_fighter1 } }
				}
				AND = {
					GER = { has_tech = heavy_fighter2}
					ROM = { NOT = { has_tech = heavy_fighter2 } }
				}
				AND = {
					GER = { has_tech = heavy_fighter3}
					ROM = { NOT = { has_tech = heavy_fighter3 } }
				}
			}
			NOT = { has_war_with = GER }
			NOT = { has_country_flag = GER_heavy_fighter_refused }
		}
		GER = { country_event = DOD_romania.154 }	
	}

	option = {# select italian plane
		name = DOD_hungary.151.b
		ai_chance = {
			factor = 30
			modifier = {
				is_in_faction_with = ITA
				factor = 10
			}
			modifier = {
				ITA = { has_government = ROOT }
				factor = 2
			}
			modifier = {
				ITA = {
					has_tech = heavy_fighter1
				}
				add = 10
			}
			modifier = {
				ITA = {
					has_tech = heavy_fighter2
				}
				add = 10
			}
			modifier = {
				ITA = {
					has_tech = heavy_fighter3
				}
				add = 10
			}
		}
		trigger = {
			OR = {
				AND = {
					ITA = { has_tech = heavy_fighter1}
					ROM = { NOT = { has_tech = heavy_fighter1 } }
				}
				AND = {
					ITA = { has_tech = heavy_fighter2}
					ROM = { NOT = { has_tech = heavy_fighter2 } }
				}
				AND = {
					ITA = { has_tech = heavy_fighter3}
					ROM = { NOT = { has_tech = heavy_fighter3 } }
				}
			}
			NOT = { has_war_with = ITA }
			NOT = { has_country_flag = ITA_heavy_fighter_refused }
		}
		ITA = { country_event = DOD_romania.154 }	
	}

	option = {# select french plane
		name = DOD_hungary.151.c
		ai_chance = {
			factor = 30
			modifier = {
				is_in_faction_with = FRA
				factor = 10
			}
			modifier = {
				FRA = { has_government = ROOT }
				factor = 2
			}
			modifier = {
				FRA = {
					has_tech = heavy_fighter1
				}
				add = 10
			}
			modifier = {
				FRA = {
					has_tech = heavy_fighter2
				}
				add = 10
			}
			modifier = {
				FRA = {
					has_tech = heavy_fighter3
				}
				add = 10
			}
		}
		trigger = {
			OR = {
				AND = {
					FRA = { has_tech = heavy_fighter1}
					ROM = { NOT = { has_tech = heavy_fighter1 } }
				}
				AND = {
					FRA = { has_tech = heavy_fighter2}
					ROM = { NOT = { has_tech = heavy_fighter2 } }
				}
				AND = {
					FRA = { has_tech = heavy_fighter3}
					ROM = { NOT = { has_tech = heavy_fighter3 } }
				}
			}
			NOT = { has_war_with = FRA }
			NOT = { has_country_flag = FRA_heavy_fighter_refused }
			
		}
		FRA = { country_event = DOD_romania.154 }	
	}
	option = {# select british plane
		name = DOD_hungary.151.d
		ai_chance = {
			factor = 30
			modifier = {
				is_in_faction_with = ENG
				factor = 10
			}
			modifier = {
				ENG = { has_government = ROOT }
				factor = 2
			}
			modifier = {
				ENG = {
					has_tech = heavy_fighter1
				}
				add = 10
			}
			modifier = {
				ENG = {
					has_tech = heavy_fighter2
				}
				add = 10
			}
			modifier = {
				ENG = {
					has_tech = heavy_fighter3
				}
				add = 10
			}
		}
		trigger = {
			OR = {
				AND = {
					ENG = { has_tech = heavy_fighter1}
					ROM = { NOT = { has_tech = heavy_fighter1 } }
				}
				AND = {
					ENG = { has_tech = heavy_fighter2}
					ROM = { NOT = { has_tech = heavy_fighter2 } }
				}
				AND = {
					ENG = { has_tech = heavy_fighter3}
					ROM = { NOT = { has_tech = heavy_fighter3 } }
				}
			}
			NOT = { has_war_with = ENG }
			NOT = { has_country_flag = ENG_heavy_fighter_refused }
		}
		ENG = { country_event = DOD_romania.154 }	
	}
	option = {# select american plane
		name = DOD_hungary.151.e
		ai_chance = {
			factor = 30
			modifier = {
				is_in_faction_with = USA
				factor = 10
			}
			modifier = {
				USA = { has_government = ROOT }
				factor = 2
			}
			modifier = {
				USA = {
					has_tech = heavy_fighter1
				}
				add = 10
			}
			modifier = {
				USA = {
					has_tech = heavy_fighter2
				}
				add = 10
			}
			modifier = {
				USA = {
					has_tech = heavy_fighter3
				}
				add = 10
			}
		}
		trigger = {
			OR = {
				AND = {
					USA = { has_tech = heavy_fighter1}
					ROM = { NOT = { has_tech = heavy_fighter1 } }
				}
				AND = {
					USA = { has_tech = heavy_fighter2}
					ROM = { NOT = { has_tech = heavy_fighter2 } }
				}
				AND = {
					USA = { has_tech = heavy_fighter3}
					ROM = { NOT = { has_tech = heavy_fighter3 } }
				}
			}
			NOT = { has_war_with = USA }
			NOT = { has_country_flag = USA_heavy_fighter_refused }
			NOT = { #to prevent overflow issues
				AND = {
					GER = {
						is_available_heavy_fighter_ROM = yes
					}
					FRA = {
						is_available_heavy_fighter_ROM = yes
					}
					ITA = {
						is_available_heavy_fighter_ROM = yes
					}
					ENG = {
						is_available_heavy_fighter_ROM = yes
					}
				}
			}
		}
		USA = { country_event = DOD_romania.154 }	
	}
	option = {# failsafe
		name = DOD_hungary.151.f	
		trigger = {
			OR = {
				has_country_flag = GER_heavy_fighter_refused
				has_country_flag = ITA_heavy_fighter_refused
				has_country_flag = ENG_heavy_fighter_refused
				has_country_flag = FRA_heavy_fighter_refused
				has_country_flag = USA_heavy_fighter_refused
			}
		}
		air_experience = 50
	}

}

#Fighter competition - Romania is looking for a heavy fighter - BBA
country_event = {
	id = DOD_romania.1521
	title = DOD_hungary.152.t
	desc = {
		text = DOD_hungary.152.desc_heavy_fighter
		trigger = {
			NOT = { 
				has_country_flag = GER_heavy_fighter_refused
				has_country_flag = ENG_heavy_fighter_refused
				has_country_flag = USA_heavy_fighter_refused
				has_country_flag = FRA_heavy_fighter_refused
				has_country_flag = ITA_heavy_fighter_refused
			} 
		}
	}
	desc = {
		text = DOD_hungary.152.desc_heavy_fighter_refused
		trigger = {
			OR = {
		 		has_country_flag = GER_heavy_fighter_refused
				has_country_flag = ENG_heavy_fighter_refused
				has_country_flag = USA_heavy_fighter_refused
				has_country_flag = FRA_heavy_fighter_refused
				has_country_flag = ITA_heavy_fighter_refused
		 	}
		}
	}
	picture = GFX_report_event_fighters
	
	is_triggered_only = yes

	option = {# Select German Plane
		name = DOD_hungary.151.a
		ai_chance = {
			factor = 30
			modifier = {
				is_in_faction_with = GER
				factor = 10
			}
			modifier = {
				GER = { has_government = ROOT }
				factor = 2
			}
			modifier = {
				GER = {
					has_tech = basic_medium_airframe
				}
				add = 10
			}
			modifier = {
				GER = {
					has_tech = improved_medium_airframe
				}
				add = 10
			}
			modifier = {
				GER = {
					has_tech = advanced_medium_airframe
				}
				add = 10
			}
		}
		trigger = {
			OR = {
				AND = {
					GER = { has_tech = basic_medium_airframe}
					ROM = { NOT = { has_tech = basic_medium_airframe } }
				}
				AND = {
					GER = { has_tech = improved_medium_airframe}
					ROM = { NOT = { has_tech = improved_medium_airframe } }
				}
				AND = {
					GER = { has_tech = advanced_medium_airframe}
					ROM = { NOT = { has_tech = advanced_medium_airframe } }
				}
			}
			NOT = { has_war_with = GER }
			NOT = { has_country_flag = GER_heavy_fighter_refused }
		}
		GER = { country_event = DOD_romania.154 }	
	}

	option = {# select italian plane
		name = DOD_hungary.151.b
		ai_chance = {
			factor = 30
			modifier = {
				is_in_faction_with = ITA
				factor = 10
			}
			modifier = {
				ITA = { has_government = ROOT }
				factor = 2
			}
			modifier = {
				ITA = {
					has_tech = basic_medium_airframe
				}
				add = 10
			}
			modifier = {
				ITA = {
					has_tech = improved_medium_airframe
				}
				add = 10
			}
			modifier = {
				ITA = {
					has_tech = advanced_medium_airframe
				}
				add = 10
			}
		}
		trigger = {
			OR = {
				AND = {
					ITA = { has_tech = basic_medium_airframe}
					ROM = { NOT = { has_tech = basic_medium_airframe } }
				}
				AND = {
					ITA = { has_tech = improved_medium_airframe}
					ROM = { NOT = { has_tech = improved_medium_airframe } }
				}
				AND = {
					ITA = { has_tech = advanced_medium_airframe}
					ROM = { NOT = { has_tech = advanced_medium_airframe } }
				}
			}
			NOT = { has_war_with = ITA }
			NOT = { has_country_flag = ITA_heavy_fighter_refused }
		}
		ITA = { country_event = DOD_romania.154 }	
	}

	option = {# select french plane
		name = DOD_hungary.151.c
		ai_chance = {
			factor = 30
			modifier = {
				is_in_faction_with = FRA
				factor = 10
			}
			modifier = {
				FRA = { has_government = ROOT }
				factor = 2
			}
			modifier = {
				FRA = {
					has_tech = basic_medium_airframe
				}
				add = 10
			}
			modifier = {
				FRA = {
					has_tech = improved_medium_airframe
				}
				add = 10
			}
			modifier = {
				FRA = {
					has_tech = advanced_medium_airframe
				}
				add = 10
			}
		}
		trigger = {
			OR = {
				AND = {
					FRA = { has_tech = basic_medium_airframe}
					ROM = { NOT = { has_tech = basic_medium_airframe } }
				}
				AND = {
					FRA = { has_tech = improved_medium_airframe}
					ROM = { NOT = { has_tech = improved_medium_airframe } }
				}
				AND = {
					FRA = { has_tech = advanced_medium_airframe}
					ROM = { NOT = { has_tech = advanced_medium_airframe } }
				}
			}
			NOT = { has_war_with = FRA }
			NOT = { has_country_flag = FRA_heavy_fighter_refused }
			
		}
		FRA = { country_event = DOD_romania.154 }	
	}
	option = {# select british plane
		name = DOD_hungary.151.d
		ai_chance = {
			factor = 30
			modifier = {
				is_in_faction_with = ENG
				factor = 10
			}
			modifier = {
				ENG = { has_government = ROOT }
				factor = 2
			}
			modifier = {
				ENG = {
					has_tech = basic_medium_airframe
				}
				add = 10
			}
			modifier = {
				ENG = {
					has_tech = improved_medium_airframe
				}
				add = 10
			}
			modifier = {
				ENG = {
					has_tech = advanced_medium_airframe
				}
				add = 10
			}
		}
		trigger = {
			OR = {
				AND = {
					ENG = { has_tech = basic_medium_airframe}
					ROM = { NOT = { has_tech = basic_medium_airframe } }
				}
				AND = {
					ENG = { has_tech = improved_medium_airframe}
					ROM = { NOT = { has_tech = improved_medium_airframe } }
				}
				AND = {
					ENG = { has_tech = advanced_medium_airframe}
					ROM = { NOT = { has_tech = advanced_medium_airframe } }
				}
			}
			NOT = { has_war_with = ENG }
			NOT = { has_country_flag = ENG_heavy_fighter_refused }
		}
		ENG = { country_event = DOD_romania.154 }	
	}
	option = {# select american plane
		name = DOD_hungary.151.e
		ai_chance = {
			factor = 30
			modifier = {
				is_in_faction_with = USA
				factor = 10
			}
			modifier = {
				USA = { has_government = ROOT }
				factor = 2
			}
			modifier = {
				USA = {
					has_tech = basic_medium_airframe
				}
				add = 10
			}
			modifier = {
				USA = {
					has_tech = improved_medium_airframe
				}
				add = 10
			}
			modifier = {
				USA = {
					has_tech = advanced_medium_airframe
				}
				add = 10
			}
		}
		trigger = {
			OR = {
				AND = {
					USA = { has_tech = basic_medium_airframe}
					ROM = { NOT = { has_tech = basic_medium_airframe } }
				}
				AND = {
					USA = { has_tech = improved_medium_airframe}
					ROM = { NOT = { has_tech = improved_medium_airframe } }
				}
				AND = {
					USA = { has_tech = advanced_medium_airframe}
					ROM = { NOT = { has_tech = advanced_medium_airframe } }
				}
			}
			NOT = { has_war_with = USA }
			NOT = { has_country_flag = USA_heavy_fighter_refused }
			
			AND = { #to prevent overflow issues
				GER = {
					is_available_heavy_fighter_HUN = no
				}
				FRA = {
					is_available_heavy_fighter_HUN = no
				}
				ITA = {
					is_available_heavy_fighter_HUN = no
				}
				ENG = {
					is_available_heavy_fighter_HUN = no
				}
			}
		}
		USA = { country_event = DOD_romania.154 }	
	}
	option = {# failsafe
		name = DOD_hungary.151.f	
		trigger = {
			OR = {
				has_country_flag = GER_heavy_fighter_refused
				has_country_flag = ITA_heavy_fighter_refused
				has_country_flag = ENG_heavy_fighter_refused
				has_country_flag = FRA_heavy_fighter_refused
				has_country_flag = USA_heavy_fighter_refused
			}
		}
		air_experience = 50
	}
}

#fighter competition - light fighter competition winner gets a choice whether to permit license production
country_event = {
	id = DOD_romania.153
	title = DOD_hungary.153.t
	desc = DOD_hungary.153.desc 
	picture = GFX_report_event_fighters
	
	is_triggered_only = yes

	option = {# certainly
		name = DOD_hungary.153.a
		ai_chance = {
			factor = 90
			modifier = {
				has_war = yes
				factor = 0.5
			}
		}
		ROM = { country_event = DOD_romania.155 }
		air_experience = 20
		if = {
			limit = {
				NOT = {
					has_dlc = "By Blood Alone"
				}
			}
			if = {
				limit = {
					has_tech = fighter1
					NOT = { has_tech = fighter2 }
				}
				create_production_license = {
					target = ROM 
					equipment = {
						type = fighter_equipment_1
						
					}
					cost_factor = 0
				}
			}
			if = {
				limit = {
					has_tech = fighter2
					NOT = { has_tech = fighter3 }
				}
				create_production_license = {
					target = ROM 
					equipment = {
						type = fighter_equipment_2
					}
					cost_factor = 0
				}
			}
			if = {
				limit = {
					has_tech = fighter3
				}
				create_production_license = {
					target = ROM 
					equipment = {
						type = fighter_equipment_3
					}
					cost_factor = 0
				}
			}
		}
		else = {
			ROM = { set_variable = { fighter_buy_amount = 200 } }
			FROM = { save_event_target_as = license_target }
			if = {
				limit = {
					tag = GER
				}
				ROM = { bba_get_fighter_GER_effect = yes }
				
			}
			else_if = {
				limit = {
					tag = ENG
				}
				ROM = { bba_get_fighter_ENG_effect = yes }
			}
			else_if = {
				limit = {
					tag = ITA
				}
				ROM = { bba_get_fighter_ITA_effect = yes }
			}
			else_if = {
				limit = {
					tag = FRA
				}
				ROM = { bba_get_fighter_FRA_effect = yes }
			}
			else_if = {
				limit = {
					tag = USA
				}
				ROM = { bba_get_fighter_USA_effect = yes }
			}
			bba_create_fighter_license_effect = yes
		}
	}

	option = {# no
		name = DOD_hungary.153.b
		ai_chance = {
			factor = 10
			modifier = {
				is_in_faction_with = ROM
				factor = 0
			}
		}
		if = {
			limit = { tag = GER }
			ROM = { set_country_flag = GER_fighter_refused }
		}
		if = {
			limit = { tag = ITA }
			ROM = { set_country_flag = ITA_fighter_refused }
		}
		if = {
			limit = { tag = FRA }
			ROM = { set_country_flag = FRA_fighter_refused }
		}
		if = {
			limit = { tag = ENG }
			ROM = { set_country_flag = ENG_fighter_refused }
		}
		if = {
			limit = { tag = USA }
			ROM = { set_country_flag = USA_fighter_refused }
		}
		if = {
			limit = {
				NOT = {
					has_dlc = "By Blood Alone"
				}
			}
			ROM = { country_event = DOD_romania.151 }
		}
		else = {
			ROM = { country_event = DOD_romania.1511 }
		}
		reverse_add_opinion_modifier = { target = ROM modifier = refused_help }
	}
}

#fighter competition - heavy fighter competition winner gets a choice whether to permit license production
country_event = {
	id = DOD_romania.154
	title = DOD_hungary.153.t
	desc = DOD_hungary.154.desc 
	picture = GFX_report_event_fighters
	
	is_triggered_only = yes

	option = {# certainly
		name = DOD_hungary.153.a
		ai_chance = {
			factor = 90
			modifier = {
				has_war = yes
				factor = 0.5
			}
		}
		ROM = { country_event = DOD_romania.155 }
		air_experience = 20
		if = {
			limit = {
				NOT = {
					has_dlc = "By Blood Alone"
				}
			}
			if = {
				limit = {
					has_tech = heavy_fighter1
					NOT = { has_tech = heavy_fighter2 }
				}
				create_production_license = {
					target = ROM 
					equipment = {
						type = heavy_fighter_equipment_1
					}
					cost_factor = 0
				}
			}
			if = {
				limit = {
					has_tech = heavy_fighter2
					NOT = { has_tech = heavy_fighter3 }
				}
				create_production_license = {
					target = ROM 
					equipment = {
						type = heavy_fighter_equipment_2	
					}
					cost_factor = 0
				}
			}
			if = {
				limit = {
					has_tech = heavy_fighter3
				}
				create_production_license = {
					target = ROM 
					equipment = {
						type = heavy_fighter_equipment_3
					}
					cost_factor = 0
				}
			}
		}
		else = {
			ROM = { set_variable = { heavy_fighter_buy_amount = 200 } }
			FROM = { save_event_target_as = license_target }
			if = {
				limit = {
					tag = GER
				}
				ROM = { bba_get_heavy_fighter_GER_effect = yes }
				
			}
			else_if = {
				limit = {
					tag = ENG
				}
				ROM = { bba_get_heavy_fighter_ENG_effect = yes }
			}
			else_if = {
				limit = {
					tag = ITA
				}
				ROM = { bba_get_heavy_fighter_ITA_effect = yes }
			}
			else_if = {
				limit = {
					tag = FRA
				}
				ROM = { bba_get_heavy_fighter_FRA_effect = yes }
			}
			else_if = {
				limit = {
					tag = USA
				}
				ROM = { bba_get_heavy_fighter_USA_effect = yes }
			}
			bba_create_heavy_fighter_license_effect = yes
		}
		
	}

	option = {# no
		name = DOD_hungary.153.b
		ai_chance = {
			factor = 10
			modifier = {
				is_in_faction_with = ROM
				factor = 0
			}
		}
		if = {
			limit = { tag = GER }
			ROM = { set_country_flag = GER_heavy_fighter_refused }
		}
		if = {
			limit = { tag = ITA }
			ROM = { set_country_flag = ITA_heavy_fighter_refused }
		}
		if = {
			limit = { tag = FRA }
			ROM = { set_country_flag = FRA_heavy_fighter_refused }
		}
		if = {
			limit = { tag = ENG }
			ROM = { set_country_flag = ENG_heavy_fighter_refused }
		}
		if = {
			limit = { tag = USA }
			ROM = { set_country_flag = USA_heavy_fighter_refused }
		}
		if = {
			limit = {
				NOT = {
					has_dlc = "By Blood Alone"
				}
			}
			ROM = { country_event = DOD_romania.152 }
		}
		else = {
			ROM = { country_event = DOD_romania.1521 }	
		}
		reverse_add_opinion_modifier = { target = ROM modifier = refused_help }
	}
}

#fighter competition - license production approved
country_event = {
	id = DOD_romania.155
	title = DOD_hungary.155.t
	desc = DOD_hungary.155.desc 
	picture = GFX_report_event_fighters
	
	is_triggered_only = yes

	option = {# neat
		name = DOD_hungary.155.a
		
	}
}

#rename city
country_event = {
	id = DOD_romania.999
	title = DOD_romania.999.t
	desc = DOD_romania.999.desc
	picture = GFX_report_event_german_reichstag_gathering

	fire_only_once = yes

	trigger = {
		tag = ROM
		ROM = {
			has_country_leader = { id = 550 } #Carol II
			owns_state = 217
			owns_state = 195
		}
	}

	option = { #a great idea!
		name = DOD_romania.a
		ai_chance = {
			base = 100
		}
		set_province_name = { id = 3529 name = "Magdagrad" }
		set_province_name = { id = 3151 name = "Zizigrad" }
		set_global_flag = ROM_king_is_silly
	}

	option = { #rather not
		name = DOD_romania.b
		ai_chance = {
			base = 0
		}
		add_timed_idea = { idea = ROM_king_carol_ii_consumer_penalty days = 90 }
	}

}

#Britain recieves Romania's request to change sides
country_event = {
	id = DOD_romania.16
	title = DOD_romania.16.t
	desc = DOD_romania.16.desc
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes

	immediate = {
		FROM = { set_country_flag = ROM_switched_sides }
		FROM = {
			every_other_country = {
				limit = {
					is_in_faction_with = PREV
					has_capitulated = no
				}
				set_country_flag = ROM_former_ally_still_standing #required for achievement
			}
		}
	}

	option = { #End hostilities with Romania
		name = DOD_romania.16.a
		ai_chance = {
			base = 100
		}
		hidden_effect = {
			#ensure Germany doesn't get randomly encircled
			every_state = {
				limit = {
					controller = { tag = FROM }
					owner = {
						has_war_with = event_target:romania_former_ally_target
						NOT = { has_war_with = event_target:romania_new_ally_target }
					}
				}
				event_target:romania_former_ally_target = {
					set_state_controller = PREV
				}
			}
			FROM = {
				# move our armies to back home
				teleport_armies = {
					to_state_array = owned_controlled_states
				}
			}
		}
		white_peace = FROM
		every_country = {
			limit = {
				is_subject_of = FROM
				has_war_with = ROOT
			}
			white_peace = ROOT
		}
		FROM = {
			leave_faction = yes
		}
		hidden_effect = {
			event_target:romania_former_ally_target = {
				country_event = { id = DOD_romania.161 days = 1 }
			}
			FROM = { #essentially so the Soviets peace out with Romania, preventing England from being dragged into a war with the Soviets.
				every_enemy_country = {
					limit = {
						NOT = { has_war_with = event_target:romania_new_ally_target }
						has_war_with = event_target:romania_former_ally_target
						is_faction_leader = yes
					}
					save_global_event_target_as = romania_third_party_target
					if = { #creates a collab gov out of every Moldovan state they occupy
						limit = {
							any_controlled_state = {
								owner = { tag = FROM }
							}
						}
						if = {
							limit = { MOL = { exists = no } }
							release_puppet = MOL 
							MOL = { save_event_target_as = released_nation_target }
						}
						else = {
							create_dynamic_country = {
								original_tag = MOL
								save_event_target_as = released_nation_target
							}
						}
						event_target:released_nation_target = {
							every_state = {
								limit = {
									is_core_of = MOL
									controller = { tag = event_target:romania_third_party_target }
								}
								PREV = { transfer_state = PREV }
							}
							PREV = {
								puppet = PREV
								if = {
									limit = {
										has_dlc = "La Resistance"
									}
									PREV = { set_variable = { collaboration_formed_by = PREV } }
									set_autonomy = { target = PREV autonomy_state = autonomy_collaboration_government }
								}
								else = {
									set_autonomy = { target = PREV autonomy_state = autonomy_integrated_puppet }
								}
							}
						}
					}
					if = { #creates a collab gov out of every Romanian state they occupy
						limit = {
							any_controlled_state = {
								owner = { tag = FROM }
							}
						}
						create_dynamic_country = {
							original_tag = FROM
							
							save_event_target_as = released_nation_target
							every_state = {
								limit = {
									is_core_of = FROM
									NOT = { is_core_of = MOL }
									controller = { tag = event_target:romania_third_party_target }
								}
								PREV = { transfer_state = PREV }
							}
							PREV = {
								puppet = PREV
								if = {
									limit = {
										has_dlc = "La Resistance"
									}
									PREV = { set_variable = { collaboration_formed_by = PREV } }
									set_autonomy = { target = PREV autonomy_state = autonomy_collaboration_government }
								}
								else = {
									set_autonomy = { target = PREV autonomy_state = autonomy_integrated_puppet }
								}
							}
						}
					}
					white_peace = FROM
					every_country = {
						limit = {
							is_subject_of = FROM
							has_war_with = ROOT
						}
						white_peace = ROOT
					}
				}
			}
		}
	}
}

#change sides
country_event = {
	id = DOD_romania.161
	title = DOD_romania.161.t
	desc = DOD_romania.161.desc
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes

	immediate = {
		hidden_effect = {
			FROM.FROM = {
				leave_faction = yes
				country_event = { id = DOD_romania.162 }
			}
		}
	}

	option = { #time to abandon ship
		name = DOD_romania.161.a
		ai_chance = {
			base = 100
		}
	}
}

#change sides
country_event = {
	id = DOD_romania.162
	title = DOD_romania.162.t
	desc = DOD_romania.162.desc
	picture = GFX_report_event_german_reichstag_gathering

	is_triggered_only = yes

	immediate = {
		
	}

	option = { #time to abandon ship
		name = DOD_romania.162.a
		ai_chance = {
			base = 100
		}
		event_target:romania_new_ally_target = { 
			add_to_faction = ROOT
			ROOT = {
				add_to_war = {
					targeted_alliance = PREV
					enemy = FROM
					hostility_reason = asked_to_join
				}
			}
		}
	}
}

country_event = { #if Codreanu is still in power, kill him and replace with Goga, then change name of party
	id = DOD_romania.163
	title = DOD_romania.163.t
	desc = DOD_romania.163.desc
	picture = GFX_report_event_generic_funeral
	fire_only_once = yes
	is_triggered_only = yes
	option = {
		name = DOD_romania.163.a
		add_stability = -0.05
		add_popularity = {
			ideology = fascism
			popularity = 0.05
		}
		kill_ideology_leader = fascism
		promote_character = ROM_octavian_goga
		set_party_name = { 
		    ideology = fascism
		    long_name = ROM_fascism_party2_long
		    name = ROM_fascism_party2
		}
	}
}
