country_event = {

	id = 31507 #see 35400 for LOM parallel event

	trigger = {
		tag = AUS
		year = 1842
		NOT = {
			year = 1845
			exists = LOM
			has_global_flag = Nabucco
		}
	}
	
	fire_only_once = yes
 
	mean_time_to_happen =  {
		months = 5 

		modifier = {
			factor = 0.75 #increase likelihood to happen
			year = 1843
		}


		modifier = {
			factor = 0.95 #increase likelihood to happen
			year = 1844
		}
	}

	title = "EVTNAME35400"
	desc = "EVTDESC35400"
	picture = "Verdi"

	option = {
		name = "EVTOPTA35400" 
		prestige = 3
		any_pop = { 
			limit = { 
				has_pop_culture = lombard
			} 
			consciousness = 1 
		}
		set_global_flag = Nabucco
	}
}

country_event = {

	id = 31508 #see PRU34610 and RUS32501 for parallel events

	trigger = {
		OR = {
			owns = 699 # Posen - PRU
			owns = 706 # Warsaw - RUS
			owns = 714 # Tarnow - AUS
		}
		year = 1846
		war = no
		NOT = {
			year = 1849
			exists = POL
		}	
	}
	
	fire_only_once = yes
 
	mean_time_to_happen =  {
		months = 5

		modifier = {
			factor = 0.75 #increase likelihood to happen
			year = 1847
		}


		modifier = {
			factor = 0.95 #increase likelihood to happen
			year = 1848
		}
	}

	title = "EVTNAME32501"
	desc = "EVTDESC32501"
	picture = "PopeLeo"

	option = {
		name = "EVTOPTA32501" 
		any_pop = {
			limit = { has_pop_culture = polish }
			militancy = 5
		}	
	}
}
#Hungarian revolution
country_event = {

	id = 102800
	title = "EVTNAME102800"
	desc = "EVTDESC102800"
	picture = "hungarian_revolution"
	
	trigger = {
		tag = AUS
		has_country_modifier = springtime_of_nations
		NOT = { year = 1850 
			has_country_flag = hungarian_revolution_has_happened
		}
		owns = 641
	}

	mean_time_to_happen =  {
		days = 25
	}

	
	option = {
		name = "EVTOPTA102800"
		create_vassal = HUN
		any_pop = {
			consciousness = 1
			militancy = -1
		}
		any_owned = {
			limit = {
				is_core = HUN
				NOT = {
					province_id = 774
					province_id = 773
					province_id = 772
					province_id = 775
					province_id = 771
					province_id = 775
					province_id = 776
					province_id = 777
					province_id = 791
					province_id = 793
					province_id = 778
				}
			}
			secede_province = HUN
		}
		HUN = {
			capital = 641
			leadership = 80
		}
		set_country_flag = hungarian_revolution_has_happened
		create_vassal = HUN
	}
	
	option = {
		name = "EVTOPTB102800"
		set_country_flag = hungarian_revolution_has_happened
		any_pop = {
			consciousness = 2
			militancy = 2
		}
		any_owned = {
			limit = {
				is_core = HUN
				NOT = {
					province_id = 774
					province_id = 773
					province_id = 772
					province_id = 775
					province_id = 771
					province_id = 775
					province_id = 776
					province_id = 777
					province_id = 791
					province_id = 793
					province_id = 778
				}
			}
			secede_province = HUN
		}
		HUN = {
			capital = 641
			leadership = 80
		}
		AUS = {
			capital = 619
		}
		create_vassal = HUN
		change_tag_no_core_switch = HUN
	}
}
#Venetian revolution
country_event = {

	id = 102900
	title = "EVTNAME102900"
	desc = "EVTDESC102900"
	picture = "revolutionnn"
	major = yes
	
	trigger = {
		tag = AUS
		has_country_modifier = springtime_of_nations
		NOT = { year = 1850 
			has_country_flag = venetian_revolution_has_happened
		}
		owns = 729
	}

	
	option = {
		name = "EVTOPTA102900"
		any_pop = {
			consciousness = 2
			militancy = 2
		}
		any_owned = {
			limit = {
				is_core = VEN
				NOT = {
					province_id = 737
				}
			}
			secede_province = VEN
		}
		VEN = {
			capital = 729
			leadership = 80
		}
        VEN = { add_country_modifier = {
                name = small_country_draft_aus
                duration = 30 }
            }
            add_country_modifier = {
                name = small_country_draft_aus
                duration = 30
            }
		capital = 729
		AUS = {
			capital = 619
		}
		war = {
			target = VEN
			attacker_goal = {
				casus_belli = civil_war
			}
			
			defender_goal = {
				casus_belli = status_quo
			}
		}
		set_country_flag = venetian_revolution_has_happened
	}
	
	option = {
		name = "EVTOPTB102900"
		any_pop = {
			consciousness = 2
			militancy = 2
		}
		any_owned = {
			limit = {
				is_core = VEN
				NOT = {
					province_id = 737
				}
			}
			secede_province = VEN
		}
		VEN = {
			capital = 729
			leadership = 80
		}
        VEN = { add_country_modifier = {
                name = small_country_draft_aus
                duration = 30 }
            }
		capital = 729
		AUS = {
			capital = 619
		}
		change_tag_no_core_switch = VEN
		AUS = {
			war = {
				target = VEN
				attacker_goal = {
					casus_belli = civil_war
				}
				defender_goal = {
					casus_belli = status_quo
				}
			}
			
		set_country_flag = venetian_revolution_has_happened
		}
	}
}
#Lombard revolution
country_event = {

	id = 103000
	title = "EVTNAME103000"
	desc = "EVTDESC103000"
	picture = "revolutionnn"
	major = yes
	
	trigger = {
		tag = AUS
		has_country_modifier = springtime_of_nations
		NOT = { year = 1850 
			has_country_flag = lombard_revolution_has_happened
		}
		owns = 726
	}

	
	option = {
		name = "EVTOPTA103000"
		any_pop = {
			consciousness = 2
			militancy = 2
		}
		726 = {
			secede_province = LOM
		}
		LOM = {
			capital = 726
			leadership = 80
		}
		capital = 726
		AUS = {
			capital = 619
		}
		war = {
			target = LOM
			attacker_goal = {
				casus_belli = civil_war
			}
			
			defender_goal = {
				casus_belli = status_quo
			}
		}
		set_country_flag = lombard_revolution_has_happened
	}
}
#The Krakowian question
country_event = {
	id = 109000
	title = "EVTNAME109000" #Krakow
	desc = "EVTDESC109000"
	picture = "expansion"

	fire_only_once = yes

	is_triggered_only = yes 
	
	option = {
		name = "EVT109000OPTA"
		PRU = { country_event = 109001 }
		RUS = { country_event = 109002 }
		ai_chance = {
			factor = 100
		}
	}
	option = {
		name = "EVT109000OPTB"
		war = {
			target = KRA
			attacker_goal = {
				casus_belli = conquest
			}
			
			defender_goal = {
				casus_belli = status_quo
			}
		ai_chance = {
			factor = 0 }
		}
	}
country_event = {
	id = 109001
	title = "EVTNAME109001"
	desc = "EVTDESC109001"
	picture = "expansion"
	
	is_triggered_only = yes
	
	option = {
		name = "EVTOPTA109001"
		set_country_flag = i_accept
		PRU = {
		diplomatic_influence = {
			who = KRA
			value = -400
			}
		}
		ai_chance = {
			factor = 100
		}
	}
	
	option = {
		name = "EVTOPTB109001"
		set_country_flag = i_refuse
		PRU = {
		diplomatic_influence = {
			who = KRA
			value = 300
			}
		}		
		ai_chance = {
			factor = 0
		}
	}
}
country_event = {
	id = 109002
	title = "EVTNAME109002"
	desc = "EVTDESC109002"
	picture = "expansion"
	
	is_triggered_only = yes
	
	option = {
		name = "EVTOPTA109002"
		set_country_flag = i_accept
		RUS = {
		diplomatic_influence = {
			who = KRA
			value = -400
			}
		}
		ai_chance = {
			factor = 100
		}
	}
	
	option = {
		name = "EVTOPTB109002"
		set_country_flag = i_refuse
		RUS = {
		diplomatic_influence = {
			who = KRA
			value = 300
			}
		}		
		ai_chance = {
			factor = 0
		}
	}
}
country_event = {
	id = 109003
	title = "EVTNAME109003"
	desc = "EVTDESC109003"
	picture = "expansion"
	
fire_only_once = yes
	
	trigger = {	
			tag = AUS

			PRU = {
				has_country_flag = i_accept
				}
			RUS = {
				has_country_flag = i_accept
				}
			}

	mean_time_to_happen = { months = 2 }
	
	option = {
		name = "EVTOPTA109003"
		KRA = {
		add_casus_belli = {
				target = AUS
				type = conquest
				months = 15 }
		}
		war = {
			target = KRA
			attacker_goal = {
				casus_belli = conquest
			}
			
			defender_goal = {
				casus_belli = status_quo
			}
		}
	}
}
#Hungarian war of independence
country_event = {

	id = 102801
	title = "EVTNAME102801"
	desc = "EVTDESC102801"
	picture = "revolutionnn"
	major = yes 
	
	fire_only_once = yes

	trigger = {
		tag = AUS
		has_country_flag = hungarian_revolution_has_happened
		NOT = {
			has_country_flag = hungary_wants_independence
			has_country_flag = hungarian_language_is_respected
		}
	}
 
	mean_time_to_happen =  {
		months = 1
	}

	option = {
		name = "EVTOPTA102801"
				release_vassal = HUN
		HUN = { government = democracy
		political_reform = wealth_voting
		political_reform = state_equal_weight
		political_reform = yes_meeting }
		AUS = {
			capital = 619
		}
		set_country_flag = hungary_wants_independence
		war = {
			target = HUN
			attacker_goal = {
				casus_belli = civil_war
			}
			
			defender_goal = {
				casus_belli = status_quo
			}	
		}
	}
}
#Hungarian war of independence
country_event = {

	id = 502801
	title = "Hungarian victory!"
	desc = "Having defeated the Hagsburg Monarchy, we can now choose our own path and enjoy our independence."
	major = yes 
	
	fire_only_once = yes

	trigger = {
		tag = HUN
		AUS = { has_country_flag = hungary_wants_independence }
		war = no
		HUN = { exists = yes }
		year = 1850
		NOT = { year = 1855 }
		NOT = { vassal_of = AUS }
	}
 
	mean_time_to_happen =  {
	}

	option = {
		name = "And now our liberal presence will make other Empires unstable."
		prestige = 40
		set_country_flag = empires_fear
		RUS = { add_country_modifier = {
				name = political_instability
				duration = 2000
			} }
	}
}
country_event = {

    id = 32512
    title = "EVTNAME32512" #Intervention in Hungary?
    desc = "EVTDESC32512"
    picture = "deliberation"

    fire_only_once = yes

    trigger = {
        tag = RUS
        war = no
        AUS = { has_country_flag = hungary_wants_independence }
        exists = HUN
        NOT = { truce_with = HUN }
        AUS = {
            NOT = { truce_with = RUS }
            war_with = HUN
        }
    }

    mean_time_to_happen = {
        months = 1
        modifier = {
            factor = 3
            num_of_revolts = 1
        }
        modifier = {
            factor = 0.5
            AUS = {
                any_owned_province = { controlled_by = HUN }
            }
        }
    }

    option = {
        name = "EVT32512OPTA"
        prestige = 5
        casus_belli = {
            target = HUN
            type = cut_down_to_size
            months = 12
        }
        war = {
            target = HUN
            attacker_goal = {
                casus_belli = cut_down_to_size
            }
        }
        military_access = AUS
        random_owned = {
            limit = {
                owner = { ai = yes }
                AUS = { ai = yes }
            }
            owner = {
                relation = {
                    who = AUS
                    value = 300
                }
            }
        }
        random_owned = {
            limit = {
                OR = {
                    owner = { ai = no }
                    AUS = { ai = no }
                }
            }
            owner = {
                relation = {
                    who = AUS
                    value = 100
                }
            }
        }
        ai_chance = {
            factor = 80
            modifier = {
                factor = 0.5
                HUN = { national_provinces_occupied = .25 }
            }
            modifier = {
                factor = 0.5
                NOT = {
                    relation = { who = AUS value = 0 }
                }
            }
        }
    }
	    option = {
        name = "EVT32512OPTB"
    }
}
country_event = {

    id = 116010
    title = "Ukrainian or Polish?" #Intervention in Hungary?
    desc = "With more openess, we must accept other minorities for them to have rights in us."
    picture = "deliberation"

    fire_only_once = yes

    is_triggered_only = yes

    option = {
        name = "Ukrainian"
        prestige = 5
		add_accepted_culture = ukrainian }
		
		ai_chance = {
            factor = 50
        }
		
	option = {
        name = "Polish"
        prestige = 5
		add_accepted_culture = polish }
		
        ai_chance = {
            factor = 50
    }
}
# The Südtirol Compromise
country_event = {
    id = 110089
    title = "EVTNAME110089"
    desc = "EVTDESC110089"
    picture = "map_trentin"

    is_triggered_only = yes

    option = {
        name = "EVT110089OPTA" #There will be no compromise
        badboy = 1
        FROM = { country_event = 110090 }
        ai_chance = {
            factor = 35
        }
    }

    option = {
        name = "EVT110089OPTB" #We should split it equally
        FROM = { country_event = 110091 }

        ai_chance = { factor = 50 }
    }

    option = {
        name = "EVT110089OPTC" #Let's exchange populations
        FROM = { country_event = 110092 }

        ai_chance = { factor = 15 }
    }
}

# The South Tirol Compromise - FROMCOUTNRY Refuses
country_event = {
    id = 110090
    title = "EVTNAME110090"
    desc = "EVTDESC110090"
    picture = "map_trentin"

    is_triggered_only = yes

    option = {
        name = "EVT110090OPTA" #How dare they!
        relation = { who = FROM value = -50 }
    }
}

# The South Tirol Compromise - splitting states
country_event = {
    id = 110091
    title = "EVTNAME110091"
    desc = "EVTDESC110091"
    picture = "map_trentin"

    is_triggered_only = yes

    option = {
        name = "EVT110091OPTA" #We accept
        random_owned = {
            limit = {
                province_id = 735
                owner = { is_culture_group = italian }
            }
            secede_province = FROM
            remove_core = THIS
            remove_core = VEN
        }
        random_owned = {
            limit = {
                province_id = 734
                owner = { is_culture_group = italian }
            }
            remove_core = GER
            remove_core = AUS
            remove_core = KUK
            remove_core = VEN
            change_province_name = "Trentino"
        }
        random_owned = {
            limit = {
                province_id = 734
                owner = { is_culture_group = germanic }
            }
            secede_province = FROM
            remove_core = THIS
            remove_core = GER
            remove_core = AUS
            remove_core = KUK
            change_province_name = "Trentino"
        }
        random_owned = {
            limit = {
                province_id = 735
                owner = { is_culture_group = germanic }
            }
            remove_core = ITA
            remove_core = VEN
        }
        relation = { who = FROM value = 100 }
        ai_chance = {
            factor = 30
        }
    }

    option = {
        name = "EVT110091OPTB" #We refuse
        badboy = 1
        relation = { who = FROM value = -50 }
        FROM = { country_event = 110090 }
        ai_chance = {
            factor = 70
        }
    }
}

# The South Tirol Compromise - Population and province exchanges
country_event = {
    id = 110092
    title = "EVTNAME110092"
    desc = "EVTDESC110092"
    picture = "map_trentin"

    is_triggered_only = yes

    option = {
        name = "EVT110091OPTA" #We accept
        735 = {
            any_pop = {
                limit = { is_culture_group = italian }
                move_pop = 734
            }
        }
        734 = {
            any_pop = {
                limit = { is_culture_group = germanic }
                move_pop = 735
            }
        }
        random_owned = {
            limit = {
                province_id = 735
                owner = { is_culture_group = italian }
            }
            secede_province = FROM
            remove_core = THIS
            remove_core = VEN
        }
        random_owned = {
            limit = {
                province_id = 734
                owner = { is_culture_group = italian }
            }
            remove_core = GER
            remove_core = AUS
            remove_core = KUK
            remove_core = VEN
            change_province_name = "Trentino"
        }
        random_owned = {
            limit = {
                province_id = 734
                owner = { is_culture_group = germanic }
            }
            secede_province = FROM
            remove_core = THIS
            remove_core = GER
            remove_core = AUS
            remove_core = KUK
            change_province_name = "Trentino"
        }
        random_owned = {
            limit = {
                province_id = 735
                owner = { is_culture_group = germanic }
            }
            remove_core = ITA
            remove_core = VEN
        }
        relation = { who = FROM value = 100 }
        ai_chance = {
            factor = 20
        }
    }

    option = {
        name = "EVT110091OPTB" #We refuse
        badboy = 1
        relation = { who = FROM value = -50 }
        FROM = { country_event = 110090 }
        ai_chance = {
            factor = 80
        }
    }
}

country_event = {
    id = 112931000
    title = "Slovak revolt" #Haitian genocide -- to HAI
    desc = "Slovaks are requesting that their language is respected within the glorious Hungarian Republic. Should we accept their demands?"

		fire_only_once = yes
		
	trigger = {
		tag = HUN
		war_with = AUS
		owns = 633 
		}
		
	mean_time_to_happen = { days = 10 }

    option = {
        name = "Let them speak whatever they want."
        war_exhaustion = -10
        prestige = -10
        militancy = 7
    }
	option = {
        name = "Slovakia must remain Hungarian."
        war_exhaustion = -10
        prestige = 5
        militancy = -2
			633 = { secede_province = SLV  }
			634 = { secede_province = SLV  }
			636 = { secede_province = SLV  }
			637 = { secede_province = SLV  }		
		war = {
			target = SLV
			attacker_goal = {
				casus_belli = civil_war
			}
			
			defender_goal = {
				casus_belli = status_quo
			}	
		}
		AUS = { war = {
			target = SLV
			attacker_goal = {
				casus_belli = civil_war
			}
			
			defender_goal = {
				casus_belli = status_quo
			}	
		} }
    }
}

country_event = {
    id = 322931
    title = "Serbian revolt" #Haitian genocide -- to HAI
    desc = "Serbs are requesting that their language is respected within the glorious Hungarian Republic. Should we accept their demands?"

		fire_only_once = yes
		
	trigger = {
		tag = HUN
		war_with = AUS
		owns = 792 
		}
		
	mean_time_to_happen = { days = 10 }

    option = {
        name = "Let them speak whatever they want."
        war_exhaustion = -10
        prestige = -10
        militancy = 7
    }
	option = {
        name = "Vojvodina must remain Hungarian."
        war_exhaustion = -10
        prestige = 5
        militancy = -2
			779 = { secede_province = VJV  }
			793 = { secede_province = VJV  }
			791 = { secede_province = VJV  }
			792 = { secede_province = VJV  }		
		war = {
			target = VJV
			attacker_goal = {
				casus_belli = civil_war
			}
			
			defender_goal = {
				casus_belli = status_quo
			}	
		}
		AUS = { war = {
			target = VJV
			attacker_goal = {
				casus_belli = civil_war
			}
			
			defender_goal = {
				casus_belli = status_quo
			}	
		} }
    }
}
#Hungarian revolution for HRE
country_event = {

	id = 10280001
	title = "Hungarian diplomats"
	desc = "The Hungarian people, a minority within our glorious empire, are asking for a special status for their land"
	picture = "hungarian_revolution"
	
	trigger = {
		tag = HRE
		owns = 641
		year = 1870
	}

	fire_only_once = yes 
	
	mean_time_to_happen =  {
		days = 25
	}

	
	option = {
		name = "Let's give them the autonomy they ask for."
		create_vassal = HUN
		any_pop = {
			consciousness = 1
			militancy = -1
		}
		any_owned = {
			limit = {
				is_core = HUN
				NOT = {
					province_id = 774
					province_id = 773
					province_id = 772
					province_id = 775
					province_id = 771
					province_id = 775
					province_id = 776
					province_id = 777
					province_id = 791
					province_id = 793
				}
			}
			secede_province = HUN
		}
		HUN = {
			capital = 641
			leadership = 80
		}
		create_vassal = HUN
	}
	
	option = {
		name = "Why not to be Hungary now?"
		any_pop = {
			consciousness = 2
			militancy = 2
		}
		any_owned = {
			limit = {
				is_core = HUN
				NOT = {
					province_id = 774
					province_id = 773
					province_id = 772
					province_id = 775
					province_id = 771
					province_id = 775
					province_id = 776
					province_id = 777
					province_id = 791
					province_id = 793
				}
			}
			secede_province = HUN
		}
		HUN = {
			capital = 641
			leadership = 80
		}
		create_vassal = HUN
		change_tag_no_core_switch = HUN
	}
	option = {
		name = "We answer a sounding no."
		set_country_flag = perfect_storm
	}
}
#Hungarian revolution for HRE
country_event = {

	id = 10280002
	title = "Hungarian revolt"
	desc = "Being not satisfied with their status within the empire, Hungarian diet decided to secede from our country"
	picture = ""
	
	trigger = {
		tag = HRE
		owns = 641
		has_country_flag = perfect_storm
	}

	fire_only_once = yes 
	
	mean_time_to_happen =  {
		days = 25
	}

	
	option = {
		name = "Let's give them the iron fist they ask for."
		any_pop = {
			consciousness = 1
			militancy = -1
		}
		any_owned = {
			limit = {
				is_core = HUN
			}
			secede_province = HUN
		}
		HUN = {
			capital = 641
			leadership = 80
		}	
		war = {
			target = HUN
			attacker_goal = {
				casus_belli = civil_war
			}
			
			defender_goal = {
				casus_belli = status_quo
			}	
		}
	}
	
	option = {
		name = "Why not to be Hungary now?"
		any_pop = {
			consciousness = 2
			militancy = 2
		}
		any_owned = {
			limit = {
				is_core = HUN
			}
			secede_province = HUN
		}
		HUN = {
			capital = 641
			leadership = 80
		}
		war = {
			target = HUN
			attacker_goal = {
				casus_belli = civil_war
			}
			
			defender_goal = {
				casus_belli = status_quo
			}	
		}
		change_tag_no_core_switch = HUN
	}
}
#Polish revolution for HRE
country_event = {

	id = 10280002
	title = "Galitzian revolt"
	desc = "Being not satisfied with their status within the empire, Galitzian intellectuals decided to secede from our country"
	picture = ""
	
	trigger = {
		tag = HRE
		owns = 714
		has_country_flag = perfect_storm
	}

	fire_only_once = yes 
	
	mean_time_to_happen =  {
		days = 25
	}

	
	option = {
		name = "Let's give them the iron fist they ask for."
		any_pop = {
			consciousness = 1
			militancy = -1
		}
		any_owned = {
			limit = {
				is_core = GLO
			}
			secede_province = GLO
		}
		GLO = {
			capital = 702
			leadership = 80
		}	
		war = {
			target = GLO
			attacker_goal = {
				casus_belli = civil_war
			}
			
			defender_goal = {
				casus_belli = status_quo
			}	
		}
	}
	
	option = {
		name = "Why not to be Hungary now?"
		any_pop = {
			consciousness = 2
			militancy = 2
		}
		any_owned = {
			limit = {
				is_core = GLO
			}
			secede_province = GLO
		}
		any_owned = {
			limit = {
				is_core = BKN
			}
			secede_province = BKN
		}
		BKN = {
			capital = 702
			leadership = 80
		}
		war = {
			target = GLO
			attacker_goal = {
				casus_belli = civil_war
			}
			
			defender_goal = {
				casus_belli = status_quo
			}	
		}
		war = {
			target = BKN
			attacker_goal = {
				casus_belli = civil_war
			}
			
			defender_goal = {
				casus_belli = status_quo
			}	
		}
		change_tag_no_core_switch = GLO
	}
}

#Autria is no more
country_event = {

	id = 10280003
	title = "Austria is no more"
	desc = "The so callled Austrian Empire does not exist anymore."
	picture = ""
	
	trigger = {
		OR = { tag = AUS
		tag = KUK }
		NOT = { owns = 619
		owns = 613
		owns = 616}
	}

	
	mean_time_to_happen =  {
		days = 25
	}
	
	option = {
		name = "Why not to be Hungary now?"
		any_owned = {
			limit = {
				is_core = GLO
			}
			secede_province = GLO
			remove_core = KUK
		}
		any_owned = {
			limit = {
				is_core = POL
			}
			secede_province = POL
			remove_core = KUK
		}
		any_owned = {
			limit = {
				is_core = CPL
			}
			secede_province = CPL
			remove_core = KUK
		}
		any_owned = {
			limit = {
				is_core = BKN
			}
			secede_province = BKN
			remove_core = KUK
		}
		any_owned = {
			limit = {
				is_core = SLO
			}
			secede_province = SLO
			remove_core = KUK
		}
		any_owned = {
			limit = {
				is_core = BOH
			}
			secede_province = BOH
			remove_core = KUK
		}
		any_owned = {
			limit = {
				is_core = RSM
			}
			secede_province = RSM
		}
		any_owned = {
			limit = {
				is_core = FIU
			}
			secede_province = FIU
			remove_core = KUK
		}
		any_owned = {
			limit = {
				is_core = TRE
			}
			secede_province = TRE
			remove_core = KUK
		}
		change_tag = HUN
		AUS = { all_core = { remove_core = HUN 
			remove_core = KUK} }
		HUN = { all_core = { remove_core = AUS 
			remove_core = KUK} }
		KUK = { all_core = { remove_core = KUK } }
		remove_accepted_culture = south_german
		primary_culture = hungarian 
	}
}
#kuk is no more
country_event = {

	id = 10280004
	title = "Austria-Hungary is no more"
	desc = "The so callled Austrian-Hungarian Empire does not exist anymore."
	picture = ""
	
	trigger = {
		tag = KUK
		NOT = { owns = 641 }
		HUN = { exists = yes }
	}

	
	mean_time_to_happen =  {
		days = 25
	}
	
	option = {
		name = "Why not to be Austria now?"
		change_tag = AUS
		KUK = { all_core = { remove_core = KUK } }
	}
}

#Purcharse of Río De Oro
country_event = {
	
	id = 814020
	title = "Proposal to buy Río de Oro" #The Treaty of Guadalupe Hidalgo
	desc = "The Austrian-Hungarian diplomats have arrived proposing to buy a useless piece of land. WHat is our answer?"
	picture = "treaty"

	is_triggered_only = yes

	option = {
		name = "We agree to their proposal."
		set_country_flag = treaty_of_palau
		prestige = 5
		treasury = 20000
		1774 = { secede_province = KUK }
		KUK = { country_event = 114021 }
		ai_chance = {
			factor = 0
		}
	}

	option = {
		name = "We refuse!"
		ai_chance = {
			factor = 100
		}
	}
}
country_event = {

	id = 814021
	title = "EVTNAME114021" #Spain Agrees
	desc = "The Spanish Empire has agreed to secede the territory we asked for."
	news = yes
	news_title = "EVTNAME44825"
	news_desc_long = "EVTDESC44826_NEWS_LONG"
	news_desc_medium = "EVTDESC44826_NEWS_MEDIUM"
	news_desc_short = "EVTDESC44826_NEWS_SHORT"
	picture = "treaty"

	is_triggered_only = yes

	option = {
		name = "A wise move."
		prestige = 20
		treasury = -20000
		relation = {
			who = FROM
			value = 200
		}
		set_country_flag = treaty_of_palau
	}
}
#Galitzian revolution
country_event = {

	id = 142900
	title = "Galicia-Lodomeria"
	desc = "With Hungarian support, Galicia-Lodomeria has now started an open rebellion against us."
	picture = "revolutionnn"
	
	is_triggered_only = yes

	
	option = {
		name = "Fight them!"
		any_pop = {
			consciousness = 2
			militancy = 2
		}
		any_owned = {
			limit = {
			OR = { 
				is_core = GLO
				is_core = BKN }
				NOT = {
					province_id = 2584
				}
			}
			secede_province = GLO
		}
		GLO = {
			capital = 702
			leadership = 80
		}
		AUS = {
			capital = 619
		}
		war = {
			target = GLO
			attacker_goal = {
				casus_belli = civil_war
			}
			
			defender_goal = {
				casus_belli = status_quo
			}
		}
		set_country_flag = glo_revolution_has_happened
		money = 10000
	}
	
	option = {
		name = "Fight WITH them!"
		any_pop = {
			consciousness = 2
			militancy = 2
		}
		any_owned = {
			limit = {
			OR = { 
				is_core = GLO
				is_core = BKN }
				NOT = {
					province_id = 2584
				}
			}
			secede_province = GLO
		}
		GLO = {
			capital = 702
			leadership = 80
		}
		AUS = {
			capital = 619
		}
		change_tag_no_core_switch = GLO
		AUS = {
			war = {
				target = GLO
				attacker_goal = {
					casus_belli = civil_war
				}
				defender_goal = {
					casus_belli = status_quo
				}
			}
			
		set_country_flag = glo_revolution_has_happened
		money = 10000
		}
	}
}
#Galitzian revolution
country_event = {

	id = 152900
	title = "Ukraine"
	desc = "Ukraine, with the support of Hungary, has decided to be bold enough to try and defeat us."
	picture = "revolutionnn"
	
	is_triggered_only = yes

	
	option = {
		name = "Fight them!"
		any_pop = {
			consciousness = 2
			militancy = 2
		}
		any_owned = {
			950 = { secede_province = UKR }
			953 = { secede_province = UKR }
			951 = { secede_province = UKR }
			702 = { secede_province = UKR }
			952 = { secede_province = UKR }
			957 = { secede_province = UKR }
			956 = { secede_province = UKR }
			955 = { secede_province = UKR }
			959 = { secede_province = UKR }
			960 = { secede_province = UKR }
			954 = { secede_province = UKR }
			969 = { secede_province = UKR }
			968 = { secede_province = UKR }
			958 = { secede_province = UKR }
			961 = { secede_province = UKR }
			971 = { secede_province = UKR }
			970 = { secede_province = UKR }
			972 = { secede_province = UKR }
			676 = { secede_province = UKR }
			677 = { secede_province = UKR }
			678 = { secede_province = UKR }
			2971 = { secede_province = UKR }
			2657 = { secede_province = UKR }
		}
		UKR = {
			capital = 958
			leadership = 80
		}
		war = {
			target = UKR
			attacker_goal = {
				casus_belli = civil_war
			}
			
			defender_goal = {
				casus_belli = status_quo
			}
		}
		set_country_flag = ukr_revolution_has_happened
		money = 10000
	}
	
	option = {
		name = "Fight WITH them!"
		any_pop = {
			consciousness = 2
			militancy = 2
		}
		any_owned = {
			950 = { secede_province = UKR }
			953 = { secede_province = UKR }
			951 = { secede_province = UKR }
			702 = { secede_province = UKR }
			952 = { secede_province = UKR }
			957 = { secede_province = UKR }
			956 = { secede_province = UKR }
			955 = { secede_province = UKR }
			959 = { secede_province = UKR }
			960 = { secede_province = UKR }
			954 = { secede_province = UKR }
			969 = { secede_province = UKR }
			968 = { secede_province = UKR }
			958 = { secede_province = UKR }
			961 = { secede_province = UKR }
			971 = { secede_province = UKR }
			970 = { secede_province = UKR }
			972 = { secede_province = UKR }
			676 = { secede_province = UKR }
			677 = { secede_province = UKR }
			678 = { secede_province = UKR }
			2971 = { secede_province = UKR }
			2657 = { secede_province = UKR }
		}
		UKR = {
			capital = 958
			leadership = 80
		}
		change_tag_no_core_switch = UKR
		RUS = {
			war = {
				target = UKR
				attacker_goal = {
					casus_belli = civil_war
				}
				defender_goal = {
					casus_belli = status_quo
				}
			}
			
		set_country_flag = ukr_revolution_has_happened
		money = 10000
		}
	}
}