
add_namespace = ITA_balkan_event


#allign yug
country_event = {
	id = ITA_balkan_event.1
	title = ITA_balkan_event.1.t
	desc = ITA_balkan_event.1.d
	picture = GFX_report_event_HUN_hungary_occupies_area
	
	is_triggered_only = yes
	
	fire_only_once = yes
	
	option = {
	name = ITA_balkan_event.1.a
	
	ai_chance = {
	base = 0.8
	}
	
	custom_effect_tooltip = YUG_greater_yug_after_ita
	set_global_flag = YUG_agreed_to_ita
	
	FROM = {country_event = {id = ITA_balkan_event.3 days = 1}}
	FROM = {add_to_faction = ROOT}
	
		add_offsite_building = { type = industrial_complex level = 3 }
		give_resource_rights = { receiver = ITA state = 105 }
		
		103 = {
		add_core_of = ITA
		transfer_state_to = ITA
		}
		1037 = {
		add_core_of = ITA
		transfer_state_to = ITA
		}
	}
	
	option = {
	name = ITA_balkan_event.1.b
	add_political_power = 25
	add_war_support = 0.03
	
	ai_chance = {
	base = 0.2
	}
	
	FROM = { country_event = {id = ITA_balkan_event.2 days = 1} }
	
	}
}
#no
country_event = {
	id = ITA_balkan_event.2
	title = ITA_balkan_event.2.t
	desc = ITA_balkan_event.2.d
	picture = GFX_report_event_HUN_hungary_occupies_area
	
	is_triggered_only = yes
	
	fire_only_once = yes
	
	option = {
	name = ITA_balkan_event.2.a
	
	uncomplete_national_focus = ITA_potential_allies_in_the_balkans
	uncomplete_national_focus = ITA_align_yugoslavia
	complete_national_focus = ITA_balkan_ambition
	}
}
#yes
country_event = {
	id = ITA_balkan_event.3
	title = ITA_balkan_event.3.t
	desc = ITA_balkan_event.3.d
	picture = GFX_report_event_HUN_hungary_occupies_area
	
	is_triggered_only = yes
	
	fire_only_once = yes
	
	option = {
	name = ITA_balkan_event.3.a
	add_political_power = 15
	}
}

#yug ultimatum, hun and bul
country_event = {
	id = ITA_balkan_event.4
	title = ITA_balkan_event.4.t
	desc = ITA_balkan_event.4.d
	picture = GFX_report_event_HUN_hungary_occupies_area
	
	is_triggered_only = yes
	
	#fire_only_once = yes
	
	option = { #yes
	name = ITA_balkan_event.4.a
	ai_chance = {
	base = 1
	}
	
	FROM = {add_to_faction = ROOT}
	
	if = {
	limit = {
	ROOT = {original_tag = HUN}
	}

	45 = {add_claim_by = HUN}
	1029 = {add_claim_by = HUN}
	
	}
	
	if = {
	limit = {
	ROOT = {original_tag = BUL}
	}

	803 = {add_claim_by = BUL}
	106 = {add_claim_by = BUL}
	
	}
	
	set_country_flag = agrees_split_yug_flag
	
	FROM = {country_event = {id = ITA_balkan_event.5 days = 1}}
	
	}
	
	option = {
	name = ITA_balkan_event.4.b
	ai_chance = {
	base = 0
	}
	
	add_political_power = 15
	
	FROM = {country_event = {id = ITA_balkan_event.6 days = 1}}
	
	}
}

#yug ultimatum, hun and bul yes
country_event = {
	id = ITA_balkan_event.5
	title = ITA_balkan_event.5.t
	desc = ITA_balkan_event.5.d
	picture = GFX_report_event_HUN_hungary_occupies_area
	
	is_triggered_only = yes
	
	#fire_only_once = yes
	
	option = {
	name = ITA_balkan_event.5.a
	ai_chance = {
	base = 1
	}
	
	add_political_power = 10
	
	}
}
#yug ultimatum, hun and bul no
country_event = {
	id = ITA_balkan_event.6
	title = ITA_balkan_event.6.t
	desc = ITA_balkan_event.6.d
	picture = GFX_report_event_HUN_hungary_occupies_area
	
	is_triggered_only = yes
	
	#fire_only_once = yes
	
	option = {
	name = ITA_balkan_event.6.a
	ai_chance = {
	base = 1
	}
	
	}
}

#yug ultimatum, YUG
country_event = {
	id = ITA_balkan_event.7
	title = ITA_balkan_event.7.t
	desc = ITA_balkan_event.7.d
	picture = GFX_report_event_HUN_hungary_occupies_area
	
	is_triggered_only = yes
	
	fire_only_once = yes
	
	option = { #yes
	name = ITA_balkan_event.7.a
	ai_chance = {
	base = 0.35
	
	modifier = {
	add = 0.2
	GER = {is_in_faction_with = ITA}
	}	
	modifier = {
	add = 0.05
	is_in_faction = no
	}
	}
	
	FROM = {country_event = {id = ITA_balkan_event.8 days = 1} }
	
	ita_split_yug_focus = yes
	
	}
	
	option = { #no
	name = ITA_balkan_event.7.b
	ai_chance = {
	base = 0.65
	}
	
	FROM = {country_event = {id = ITA_balkan_event.9 days = 1} }
	
	add_timed_idea = {idea = ALL_war_of_independence days = 60}
	
	}
}
#yug ultimatum, YUG yes
country_event = {
	id = ITA_balkan_event.8
	title = ITA_balkan_event.8.t
	desc = ITA_balkan_event.8.d
	picture = GFX_report_event_HUN_hungary_occupies_area
	
	is_triggered_only = yes
	
	fire_only_once = yes
	
	option = { #yes
	name = ITA_balkan_event.8.a
	ai_chance = {
	base = 1
	}
	}
}
#yug ultimatum, YUG no
country_event = {
	id = ITA_balkan_event.9
	title = ITA_balkan_event.9.t
	desc = ITA_balkan_event.9.d
	picture = GFX_report_event_HUN_hungary_occupies_area
	
	is_triggered_only = yes
	
	fire_only_once = yes
	
	option = { #yes
	name = ITA_balkan_event.9.a
	ai_chance = {
	base = 1
	}
	
	every_country = {
	limit = {
	OR = {
	tag = ROOT
	has_country_flag = agrees_split_yug_flag
	}
	}
	
	add_war_support = 0.03
	
		declare_war_on = {
		target = YUG
		type = take_state_focus
		}
	}
	
	}
}

#rom alliance
country_event = {
	id = ITA_balkan_event.10
	title = ITA_balkan_event.10.t
	desc = ITA_balkan_event.10.d
	picture = GFX_report_event_HUN_hungary_occupies_area
	
	is_triggered_only = yes
	
	fire_only_once = yes
	
	option = { #yes
	name = ITA_balkan_event.10.a
	ai_chance = {
	base = 0.75
	}
	
	FROM = {add_to_faction = ROOT}
	
			ROOT = {
				add_ai_strategy = {
					type = befriend
					id = FROM
					value = 100
				}
			}
			
		#if = {
		#limit = {
		#owns_state = 76
		#HUN = {has_country_flag = agrees_split_yug_flag}
		#}
		#HUN = {
		#transfer_state = 76
		#		add_ai_strategy = {
		#			type = alliance
		#			id = ITA
		#			value = 200
		#		}
		#	}
		#}
			
		#if = {
		#limit = {
		#owns_state = 77
		#BUL = {has_country_flag = agrees_split_yug_flag}
		#}
		#BUL = {
		#transfer_state = 76
		#		add_ai_strategy = {
		#			type = alliance
		#			id = ITA
		#			value = 200
		#		}
		#}
		#}
	
		give_resource_rights = { receiver = ITA state = 46 }
		add_offsite_building = {type = industrial_complex level = 3}	
	}
	
	option = { #no
	name = ITA_balkan_event.10.b
	
	FROM = {country_event = {id = ITA_balkan_event.12 days = 1}}
	
	}
}

#костыль
country_event = {
	id = ITA_balkan_event.11
	title = ITA_balkan_event.11.t
	desc = ITA_balkan_event.11.d
	picture = GFX_report_event_HUN_hungary_occupies_area
	
	#hidden = yes
	
	is_triggered_only = yes
	
	fire_only_once = yes
	
	option = { #yes
	name = ITA_balkan_event.11.a
	
	ROM = {
	every_owned_state = {
	transfer_state_to = ROM
	}
	
	give_resource_rights = { receiver = ITA state = 46 }

	}
	
	}
}
#rejects
country_event = {
	id = ITA_balkan_event.12
	title = ITA_balkan_event.12.t
	desc = ITA_balkan_event.12.d
	picture = GFX_report_event_HUN_hungary_occupies_area
	
	#hidden = yes
	
	is_triggered_only = yes
	
	fire_only_once = yes
	
	option = { #yes
	name = ITA_balkan_event.12.a
	
	ai_chance = {
	base = 0.6
	}
	
	FROM = {add_timed_idea = {idea = ALL_war_of_independence days = 60}}
	
		create_wargoal = {
		type = puppet_wargoal_focus
		target = FROM
		}
	
	}
	
	option = { #yes
	name = ITA_balkan_event.12.b
	
	ai_chance = {
	base = 0.2
	}
	
	FROM = {country_event = {id = generic.5 days = 1}}
	
	}
	
	option = { #yes
	name = ITA_balkan_event.12.c
	
	ai_chance = {
	base = 0.2
	}
	
	}
}

#accepts
country_event = {
	id = ITA_balkan_event.13
	title = ITA_balkan_event.13.t
	desc = ITA_balkan_event.13.d
	picture = GFX_report_event_HUN_hungary_occupies_area
	
	#hidden = yes
	
	is_triggered_only = yes
	
	fire_only_once = yes
	
	option = { #yes
	name = ITA_balkan_event.13.a
	
	add_political_power = 15
	
	}
}
