###########################
# Greek Events
###########################

add_namespace = greece

# Soviet Demands
country_event = {
	id = greece.1
	title = greece.1.t
	desc = greece.1.d
	picture = GFX_report_event_stalin_02
	
	is_triggered_only = yes
	
	option = { # Accept demands
		name = greece.1.a
		ai_chance = {	
			modifier = {
				factor = 0
				OR = {
					any_other_country = {

						has_guaranteed = GRE
					}
					any_other_country = {

						is_in_faction_with = GRE
					}
				}
			}
			factor = 100	
		}

		SOV = { transfer_state = 187 }
		if = {
			limit = {
				BUL = { 
					OR = { 
						is_in_faction_with = SOV 
						is_in_faction = no
					}
				}
			}
			BUL = { 
				transfer_state = 184
				transfer_state = 1181
				add_opinion_modifier = { target = SOV modifier = SOV_ultimatum_to_greece_thrace }
			}
		}
		hidden_effect = {
			news_event = { id = news.197 }
		}
	}
	option = { # Refuse
		name = greece.1.b
		ai_chance = {	
			modifier = {
				factor = 0
				NOT = {
					OR = {
						any_other_country = {

							has_guaranteed = GRE
						}
						any_other_country = {

							is_in_faction_with = GRE
						}
					}
				}
			}
			factor = 5	
		}
		hidden_effect = {
			news_event = { id = news.198 hours = 6 }
		}
	}
}

# German demands to hand over territory to friends or self
country_event = {
	id = greece.2
	title = greece.2.t

	desc = { 
		text = greece.2.d_GER_demand
		trigger = {
			OR = {
				731 = { has_state_flag = GER_second_ljubljana_award_GER_demand }
				185 = { has_state_flag = GER_second_ljubljana_award_GER_demand }
				47 = { has_state_flag = GER_second_ljubljana_award_GER_demand }
			}
		}
	}

	desc = {
		text = greece.2.d_ITA
		trigger = {
			OR = {
				has_global_flag = GER_second_ljubljana_award_ITA_185
				has_global_flag = GER_second_ljubljana_award_ITA_186
				has_global_flag = GER_second_ljubljana_award_ITA_47
				has_global_flag = GER_second_ljubljana_award_ITA_1042
			}
			NOT = { has_global_flag = GER_second_ljubljana_award_BUL_184 }
			NOT = { has_global_flag = GER_second_ljubljana_award_BUL_1181 }
		}
	}
	
	desc = {
		text = greece.2.d_BUL
		trigger = {
			NOT = { has_global_flag = GER_second_ljubljana_award_ITA_185 }
			NOT = { has_global_flag = GER_second_ljubljana_award_ITA_186 }
			NOT = { has_global_flag = GER_second_ljubljana_award_ITA_47 }
			NOT = { has_global_flag = GER_second_ljubljana_award_ITA_1042 }
			has_global_flag = GER_second_ljubljana_award_BUL_184
			has_global_flag = GER_second_ljubljana_award_BUL_1181
		}
	}

	desc = {
		text = greece.2.d_ITA_BUL
		trigger = {
			OR = {
				has_global_flag = GER_second_ljubljana_award_ITA_185
				has_global_flag = GER_second_ljubljana_award_ITA_186
				has_global_flag = GER_second_ljubljana_award_ITA_47
				has_global_flag = GER_second_ljubljana_award_ITA_1042
			}
			has_global_flag = GER_second_ljubljana_award_BUL_184
			has_global_flag = GER_second_ljubljana_award_BUL_1181
		}
	}

	picture = GFX_report_event_generic_sign_treaty2
	
	is_triggered_only = yes
	
	option = { # Accept demands
		name = greece.2.a
		ai_chance = {	
			modifier = {
				factor = 0
				OR = {
					any_other_country = {

						has_guaranteed = GRE
					}
					any_other_country = {

						is_in_faction_with = GRE
					}
				}
			}
			modifier = {
				factor = 0
				is_puppet = yes
			}
			factor = 100	
		}

		hidden_effect = {
			news_event = { id = news.170 hours = 2}
		}
		if = {
			limit = {
				has_global_flag = GER_second_ljubljana_award_BUL_184
			}
			BUL = { transfer_state = 184 }
		}
		if = {
			limit = {
				has_global_flag = GER_second_ljubljana_award_BUL_1181
			}
			BUL = { transfer_state = 1181 }
		}

		if = {
			limit = {
				has_global_flag = GER_second_ljubljana_award_ITA_185
			}
			ITA = { transfer_state = 185 }
		}
		if = {
			limit = {
				has_global_flag = GER_second_ljubljana_award_ITA_186
			}
			ITA = { transfer_state = 186 }
		}
		if = {
			limit = {
				has_global_flag = GER_second_ljubljana_award_ITA_47
			}
			ITA = { transfer_state = 47 }
		}
		if = {
			limit = {
				has_global_flag = GER_second_ljubljana_award_ITA_1042
			}
			ITA = { transfer_state = 1042 }
		}

		if = {
			limit = { 
				has_global_flag = GER_second_ljubljana_award_GER_731
			}
			GER = { transfer_state = 731 }
		}
		if = {
			limit = { 
				has_global_flag = GER_second_ljubljana_award_GER_185
				NOT = { has_global_flag = GER_second_ljubljana_award_GER_731 }
			}
			GER = { transfer_state = 185 }
		}
		if = {
			limit = { 
				has_global_flag = GER_second_ljubljana_award_GER_47
				NOT = { has_global_flag = GER_second_ljubljana_award_GER_731 }
				NOT = { has_global_flag = GER_second_ljubljana_award_GER_185 }
			}
			GER = { transfer_state = 47 }
		}
	}
	
	option = { # Refuse
		name = greece.2.b
		ai_chance = {	
			modifier = {
				factor = 0
				NOT = {
					OR = {
						any_other_country = {

							has_guaranteed = GRE
						}
						any_other_country = {

							is_in_faction_with = GRE
						}
					}
				}
			}
			factor = 5	
		}
		GER = { country_event = { id = germany.102 hours = 6 } }
		news_event = { id = news.171 hours = 2 }
		effect_tooltip = {
			GER = {
				create_wargoal = {
					type = annex_everything
					target = GRE		
				}
			}			
		}
	}
}

# Germany demands Greece become puppet
country_event = {
	id = greece.3
	title = greece.3.t
	desc = greece.3.d
	picture = GFX_report_event_generic_sign_treaty2
	
	is_triggered_only = yes
	
	option = { # Accept demands
		name = greece.3.a
		ai_chance = {	
			modifier = {
				factor = 0
				OR = {
					any_other_country = {
	
						has_guaranteed = GRE
					}
					any_other_country = {

						is_in_faction_with = GRE
					}
				}
			}
			factor = 100	
		}
		GER = { puppet = GRE }
		hidden_effect = {
			news_event = { id = news.172 hours = 2 }
		}
	}

	option = { # Refuse
		name = greece.3.b
		ai_chance = {	
			modifier = {
				factor = 0
				NOT = {
					OR = {
						any_other_country = {

							has_guaranteed = GRE
						}
						any_other_country = {

							is_in_faction_with = GRE
						}
					}
				}
			}
			factor = 5	
		}
		GER = { country_event = { id = germany.102 hours = 6 } }
		effect_tooltip = {
			GER = {
				create_wargoal = {
					type = puppet_wargoal_focus
					target = GRE		
				}
			}			
		}
	}
}

# Greece gets wargoal - From Italian focus tree
country_event = {
	id = greece.4
	title = greece.4.t
	desc = greece.4.d
	picture = GFX_report_event_fascist_militia
	
	is_triggered_only = yes
	
	option = { # Accept demands
		name = greece.4.a
		ai_chance = {	factor = 100	}
		create_wargoal = {
			type = take_state_focus
			target = TUR
			generator = { 339 }
		}
		
	}
}