#####Hungary Major Events######
#By Joakim 'Greven' Bergqwist #
#   Hvard Moe                #
#   Tom 'Demetrios' Rinschler #
###############################

#Religious Rebellion#
event = {

	id = 3641
	random = no
	country = HUN
	name = "EVENTNAME3641"
	desc = "EVENTHIST3641"
	style = 3

	date = { day = 1 month = january year = 1604 }
	offset = 30
	deathdate = { day = 1 month = january year = 1605 }

	action_a ={				#Fight for the cause of the Reformed Faith#
		name = "ACTIONNAME3641A"
		command = { type = revoltrisk which = 36 value = 6 }
		command = { type = religion which = reformed }
		command = { type = desertion which = -1 value = 5000 }
		command = { type = desertion which = -1 value = 5000 }
		command = { type = relation which = HAB value = -100 }
		command = { type = relation which = PAP value = -100 }
		command = { type = relation which = SPA value = -100 }
		command = { type = relation which = SWE value = 100 }
		command = { type = relation which = LIT value = 100 }
		command = { type = relation which = PRU value = 100 }
		command = { type = relation which = DAN value = 100 }
		command = { type = relation which = HOL value = 100 }
		command = { type = domestic which = INNOVATIVE value = 2 }
		command = { type = stability value = -2 }
	}

	action_b ={				#Fight for the cause of the Catholic Faith#
		name = "ACTIONNAME3641B"
		command = { type = revoltrisk which = 36 value = 6 }
		command = { type = religion which = counterreform }
		command = { type = desertion which = -1 value = 5000 }
		command = { type = desertion which = -1 value = 5000 }
		command = { type = relation which = HAB value = 100 }
		command = { type = relation which = PAP value = 100 }
		command = { type = relation which = SPA value = 100 }
		command = { type = relation which = SWE value = -100 }
		command = { type = relation which = ENG value = -100 }
		command = { type = relation which = PRU value = -100 }
		command = { type = relation which = DAN value = -100 }
		command = { type = relation which = HOL value = -100 }
		command = { type = domestic which = INNOVATIVE value = -2 }
		command = { type = stability value = -2 }
	}
}

# The Council of Florence and the Union of the Churches
event = { 
	id = 3835
	
	# Triggered by BYZ 3833
	
	random = no
	country = HUN
	name = "EVENTNAME3835"
	desc = "EVENTHIST3835"
	style = 1 
	
	action_a ={ #Gain CB on Ottomans#
		name = "ACTIONNAME3835A"
		command = { type = casusbelli which = TUR value = 60 }
	}
}

# The Death of King Vaclav IV
event = {
	id = 3851		# Triggered from BOH3801
	random = no
	country = HUN
	name = "EVENTNAME3851"
	desc = "EVENTHIST3851"
	style = 1

	action_a ={ # They reject!
		name = "ACTIONNAME3851A"
		command = { type = casusbelli which = BOH value = 215 }
	}
}




#The Death of King Lajos of Hungary#
event = {

	id = 3639		#Previous 1526 Hungarian (Siebenburgen exists) event#
	trigger = {
			exists = HAB
			OR = {
		    	   control = { province = 353 data = TUR }#Buda
		    	   control = { province = 1952 data = TUR }#Slavonia
		    	   }
		    	OR = {
		    	   control = { province = 325 data = TUR }#Eger
		    	   control = { province = 324 data = TUR }#Szeged
		    	   }
		    	OR = {
		    	   control = { province = 354 data = TUR }#Temeswar
		    	   control = { province = 1950 data = TUR }#Varad
		    	   }
                        owned = { province = 353 data = -1 }
		    	owned = { province = 1952 data = -1 }
		    	owned = { province = 325 data = -1 }
		    	owned = { province = 324 data = -1 }
		    	owned = { province = 354 data = -1 }
		    	owned = { province = 1950  data = -1 }
		}
	random = no
	country = HUN
	name = "EVENTNAME3639"
	desc = "EVENTHIST3184"	#changed the description, more suitable imo :)#
	style = 2

	date = { day = 13 month = march year = 1516 }	#earlier startdate-they year Lajos took the throne#
	offset = 0
	deathdate = { day = 21 month = july year = 1540 }	#The death of Janos I Zapolya#

	action_a ={				#Elect Ferdinand Habsburg of Austria#
		name = "ACTIONNAME3639B"
		command = { type = sleepmonarch which = 06267 }#no effect, but i will leave it here.
		command = { type = sleepmonarch which = 06284 }
		command = { type = sleepmonarch which = 06285 }
		command = { type = sleepmonarch which = 06286 }
		command = { type = sleepmonarch which = 06287 }
		command = { type = sleepmonarch which = 06288 }
		command = { type = sleepmonarch which = 06289 }
		command = { type = sleepmonarch which = 06290 }
		command = { type = sleepmonarch which = 06291 }
		command = { type = sleepmonarch which = 06292 }
		command = { type = sleepmonarch which = 06293 }
		command = { type = sleepmonarch which = 06294 }
		command = { type = sleepmonarch which = 06295 }
		command = { type = sleepmonarch which = 06296 }
		command = { type = sleepmonarch which = 06297 }
		command = { type = sleepmonarch which = 06298 }
		command = { type = wakemonarch which = 06268 }
		command = { type = wakemonarch which = 06269 }
		command = { type = wakemonarch which = 06270 }
		command = { type = wakemonarch which = 06271 }
		command = { type = wakemonarch which = 06272 }
		command = { type = wakemonarch which = 06273 }
		command = { type = wakemonarch which = 06274 }
		command = { type = wakemonarch which = 06275 }
		command = { type = wakemonarch which = 06276 }
		command = { type = wakemonarch which = 06277 }
		command = { type = wakemonarch which = 06278 }
		command = { type = wakemonarch which = 06279 }
		command = { type = wakemonarch which = 06280 }
		command = { type = trigger which = 3645 }		#TUR#
		command = { type = trigger which = 3185 }		#HAB#
		command = { type = secedeprovince which = HAB value = 316 }	#Karpatok#
		command = { type = secedeprovince which = HAB value = 326 }     #Pozsony#
		command = { type = secedeprovince which = HAB value = 352 }     #Veszprem#
		command = { type = secedeprovince which = HAB value = 366 }     #Zagreb#
		command = { type = secedeprovince which = HAB value = 368 }	#Istria#
		command = { type = secedeprovince which = HAB value = 315 }	#Morava#
		command = { type = secedeprovince which = HAB value = 314 }     #Liegnitz#
		command = { type = secedeprovince which = HAB value = 329 }     #Sudety#
		command = { type = secedeprovince which = HAB value = 330 }     #Tabor#
		command = { type = secedeprovince which = HAB value = 328 }     #Cechy#
		command = { type = secedeprovince which = HAB value = 840 }     #Breslau#
		command = { type = secedeprovince which = HAB value = 881 }     #Oels#
		command = { type = secedeprovince which = HAB value = 1003 }    #Sumava#
		command = { type = secedeprovince which = HAB value = 1940 }    #Lausitz#
		command = { type = secedeprovince which = HAB value = 1943 }    #Oppeln#
		command = { type = secedeprovince which = HAB value = 367 }	#Krain#
		command = { type = secedeprovince which = HAB value = 369 }	#Steiermark#
		command = { type = secedeprovince which = HAB value = 327 }	#Ostmarch#
		command = { type = secedeprovince which = HAB value = 1613 }	#Ober-sterreich#
		command = { type = secedeprovince which = HAB value = 351 }	#Nieder-sterreich# Just for safety
		command = { type = secedeprovince which = HAB value = 350 }	#Salzburg#
		command = { type = secedeprovince which = HAB value = 1932 }	#Krnten#
		command = { type = secedeprovince which = TUR value = 323 }	#Transylvania#
		command = { type = secedeprovince which = TUR value = 317 }     #Karpatalja#
		command = { type = secedeprovince which = TUR value = 365 }     #Dalmatia#
	}

	action_b ={				#Elect Johan Zapolya of Siebenbrgen#
		name = "ACTIONNAME3639A"	#This is Die-Hard independence option.#
		command = { type = stability value = -3 }
		command = { type = relation which = HAB value = -200 }
		command = { type = desertion which = -1 value = 15000 }
		command = { type = desertion which = -1 value = 10000 }
		command = { type = desertion which = -1 value = 10000 }
		command = { type = desertion which = -1 value = 5000 }
		command = { type = desertion which = -1 value = 5000 }
	}
}

#The Habsburg Inheritance of Hungary#	#Habsburg#
event = {

	id = 3185			#Triggered by HUN3639#
	random = no
	country = HAB
	name = "EVENTNAME3185"
	desc = "EVENTHIST3185"
	style = 2

	action_a ={				#I will be crowned King of Hungary#
		name = "ACTIONNAME3185A"
		command = { type = add_countryculture which = magyar }
		command = { type = add_countryculture which = slovak }
		command = { type = add_countryculture which = aleutian }
		#command = { type = add_countryculture which = slavonic }
		command = { type = stability value = 3 }
		command = { type = domestic which = CENTRALIZATION value = -3 }
		command = { type = domestic which = ARISTOCRACY value = 2 }
		command = { type = addcore which = 326 }
		command = { type = addcore which = 352 }
		command = { type = addcore which = 367 }
		command = { type = addcore which = 316 }
		command = { type = addcore which = 353 }
		command = { type = addcore which = 317 }
		command = { type = addcore which = 325 }
		command = { type = addcore which = 354 }
		command = { type = addcore which = 323 }
		command = { type = addcore which = 324 }
		command = { type = addcore which = 366 }
		command = { type = addcore which = 365 }
		command = { type = addcore which = 368 }
		command = { type = addcore which = 1952 }
		command = { type = addcore which = 1950 }
		command = { type = addcore which = 355 }
		command = { type = addcore which = 364 }
		command = { type = addcore which = 1957 }
		command = { type = addcore which = 1000 }
		command = { type = addcore which = 1615 }
		command = { type = addcore which = 363 }
	}
}

#The Habsburg Inheritance of Hungary#		#TUR#
event = {

	id = 3645				#Triggered by HUN3639#
	random = no
	country = TUR
	name = "EVENTNAME3185"
	desc = "EVENTHIST3639"
	style = 2

	action_a ={				#Magnificient!#
		name = "ACTIONNAME3184A"	#gotta love those vague action names ;)#
		command = { type = add_countryculture which = magyar }
		command = { type = inherit which = HUN }
		command = { type = stability value = 3 }	#well, random goodie command#
	        command = { type = independence which = SIE }   #Siebenbrgen#
		command = { type = trigger which = 3644 }
	}
}

#The Death of King Lajos of Hungary#		#TUR#
event = {

	id = 3644			
	random = no
	country = TUR
	name = "EVENTNAME3639"
	desc = "EVENTHIST3639"
	style = 2

	action_a ={				#Ok#
		name = "ACTIONNAME3744A"
		command = { type = secedeprovince which = SIE value = 317 }	#Karpatalja#
		command = { type = trigger which = 3640 }
	}
}

#The Habsburg Inheritance of Hungary#	#Only Heir#
event = {

	id = 3184
	trigger = {
				exists = HUN
		NOT = {
			event  = 3639
			}
		}
	random = no
	country = HAB
	name = "EVENTNAME3098"
	desc = "EVENTHIST3098"
	style = 2

	date = { day = 22 month = july year = 1540 }
	offset = 0
	deathdate = { day = 23 month = july year = 1540 }

	action_a ={				#I will be crowned King of Hungary#
		name = "ACTIONNAME3185A"
		command = { type = add_countryculture which = magyar }
		command = { type = add_countryculture which = slovak }
		command = { type = add_countryculture which = aleutian }
		#command = { type = add_countryculture which = slavonic }
		command = { type = inherit which = HUN }
		command = { type = stability value = 3 }
		command = { type = domestic which = CENTRALIZATION value = -3 }
		command = { type = domestic which = ARISTOCRACY value = 2 }
		command = { type = addcore which = 326 }
		command = { type = addcore which = 352 }
		command = { type = addcore which = 367 }
		command = { type = addcore which = 316 }
		command = { type = addcore which = 353 }
		command = { type = addcore which = 317 }
		command = { type = addcore which = 325 }
		command = { type = addcore which = 354 }
		command = { type = addcore which = 323 }
		command = { type = addcore which = 324 }
		command = { type = addcore which = 366 }
		command = { type = addcore which = 365 }
		command = { type = addcore which = 368 }
		command = { type = addcore which = 1952 }
		command = { type = addcore which = 1950 }
		command = { type = addcore which = 355 }
		command = { type = addcore which = 364 }
		command = { type = addcore which = 1957 }
		command = { type = addcore which = 1000 }
		command = { type = addcore which = 1615 }
		command = { type = addcore which = 363 }
	}
}

#The Death of King Lajos of Hungary#		#SIE#
event = {
	id = 3640
	random = no
	country = SIE
	name = "EVENTNAME3639"
	desc = "EVENTHIST3639"
	style = 2
	action_a = { 			#Ok#
		name = "ACTIONNAME3744A"
		command = { type = addcore which = 317 }	#Karpatalja#
	}
}

event = {

	id = 687000
	trigger = {
		    	   war = { country = TUR country = HAB }
		    	   OR= { 
                               religion = catholic
                               religion = counterreform
                            }
                            relation = { country = HAB data = 50 }
		}
	random = no
	country = PAP
	name = "The Holy Alliance"
	desc = "In 1683 an Ottoman army 140,000 men strong had failed to take Vienna by siege, and had been defeated by a combined Polish-German relief force in the Battle of Kahlenberg (Habsburg-Ottoman War 1683-1699). In December that year, Ottoman commander Kara Mustafa Pasha was strangled, an execution ordered by Sultan Mehmet IV. Pope Innocent XI. then forged the Holy Alliance, joined by the Papal State, the Emperor, Poland and the Republic of Venice, directed against the Ottoman Empire."
	style = 2

	date = { day = 1 month = january year = 1683 }
	offset = 30
	deathdate = { day = 29 month = december year = 1685 }

	action_a ={
		name = "Forge the Holy Alliance"
		command = { type = casusbelli   which = TUR value = 168 }
		command = { type = war  which = TUR }
		command = { type = manpower   value = 20 }
		command = { type = trigger   which = 687008 }

	}
	action_b ={
		name = "I'm a man of peace"
		command = { type = relation   which = HAB value = -200 }
		command = { type = stability   value = 1 }

	}
	action_c ={
		name = "Protestants are our real enemy!"
		command = { type = religiousrevolt   which = -1 }
		command = { type = religiousrevolt   which = -1 }
		command = { type = religiousrevolt   which = -1 }
		command = { type = religiousrevolt   which = -1 }
		command = { type = conversion   which = -3 }
		command = { type = relation   which = SAC value = -200 }
		command = { type = relation   which = DAN value = -200 }
		command = { type = relation   which = HAN value = -200 }
		command = { type = relation   which = SWE value = -200 }
		command = { type = relation   which = HEL value = -200 }

	}
}

event = {

	id = 687001
	trigger = {
			event = 687008
			OR = { event = 687005 event = 687006 event = 687007 }

		  	    OR = {
		    	            control = { province = 353 data = HAB }#Buda
		    	            control = { province = 1952 data = HAB }#Slavonia
		    	            }
                            OR = {
                                    control = { province = 325 data = HAB }#Eger
                                    control = { province = 324 data = HAB }#Szeged
		    	            }
		    	            control = { province = 1950 data = HAB }#Varad
		    	owned = { province = 353 data = -1 }
		    	owned = { province = 1952 data = -1 }
		    	owned = { province = 325 data = -1 }
		    	owned = { province = 324 data = -1 }
		    	owned = { province = 1950  data = -1 }
		    	OR = {
		    	   war = { country = POL country = TUR }
		    	   war = { country = VEN country = TUR }
		    	   war = { country = PAP country = TUR }
		    	}
		}
	random = no
	country = TUR
	name = "Treaty of Karlowitz"
	desc = "The Treaty of Karlowitz was signed on January 26, 1699 concluding the Austro-Ottoman War of 16831697 in which the Ottoman side was defeated."
	style = 2

	date = { day = 1 month = january year = 1683 }
	offset = 30
	deathdate = { day = 29 month = december year = 1699 }

	action_a ={
		name = "Sign it"
		command = { type = secedeprovince which = HAB value = 323 }	#Transylvania#
		command = { type = secedeprovince which = HAB value = 317 }     #Karpatalja#
		command = { type = secedeprovince which = HAB value = 1950 }    #Varad#
		command = { type = secedeprovince which = HAB value = 325 }     #Eger#
		command = { type = secedeprovince which = HAB value = 324 }     #Szeged#
		command = { type = secedeprovince which = HAB value = 353 }     #Buda#
		command = { type = secedeprovince which = HAB value = 1952 }    #Slavonia#
		command = { type = secedeprovince which = VEN value = 365 }     #Dalmatia#
		command = { type = secedeprovince which = VEN value = 360 }     #Morea#
		command = { type = secedeprovince which = VEN value = 1369 }    #Achaea#
		command = { type = secedeprovince which = POL value = 295 }     #Braclav#
		command = { type = secedeprovince which = POL value = 297 }     #Kamieniec#
		command = { type = remove_countryculture which = magyar }
	}
}

event = {
	id = 687002
	trigger = {
			event  = 687008
		}
	random = no
	country = POL
	name = "The Holy Alliance"
	desc = "In 1683 an Ottoman army 140,000 men strong had failed to take Vienna by siege, and had been defeated by a combined Polish-German relief force in the Battle of Kahlenberg (Habsburg-Ottoman War 1683-1699). In December that year, Ottoman commander Kara Mustafa Pasha was strangled, an execution ordered by Sultan Mehmet IV. Pope Innocent XI. then forged the Holy Alliance, joined by the Papal State, the Emperor, Poland and the Republic of Venice, directed against the Ottoman Empire."
	style = 2
	date = { day = 1 month = january year = 1684 }
	offset = 1
	deathdate = { day = 29 month = december year = 1914 }

	action_a ={
		name = "Accept"
		command = { type = casusbelli   which = TUR value = 168 }
		command = { type = war  which = TUR }
		command = { type = manpower   value = 20 }
		command = { type = trigger   which = 687005 }
	}
	action_b ={
		name = "Decline"
		command = { type = relation   which = PAP value = -100 }
		command = { type = relation   which = HAB value = -100 }
		command = { type = stability   value = 1 }

	}
}

event = {
	id = 687003
	trigger = {
			event  = 687008
		}
	random = no
	country = VEN
	name = "The Holy Alliance"
	desc = "In 1683 an Ottoman army 140,000 men strong had failed to take Vienna by siege, and had been defeated by a combined Polish-German relief force in the Battle of Kahlenberg (Habsburg-Ottoman War 1683-1699). In December that year, Ottoman commander Kara Mustafa Pasha was strangled, an execution ordered by Sultan Mehmet IV. Pope Innocent XI. then forged the Holy Alliance, joined by the Papal State, the Emperor, Poland and the Republic of Venice, directed against the Ottoman Empire."
	style = 2
	date = { day = 1 month = january year = 1684 }
	offset = 1
	deathdate = { day = 29 month = december year = 1914 }

	action_a ={
		name = "Accept"
		command = { type = casusbelli   which = TUR value = 168 }
		command = { type = war  which = TUR }
		command = { type = manpower   value = 20 }
		command = { type = trigger   which = 687006 }
	}
	action_b ={
		name = "Decline"
		command = { type = relation   which = PAP value = -100 }
		command = { type = relation   which = HAB value = -100 }
		command = { type = stability   value = 1 }

	}
}

event = {
	id = 687004
	trigger = {
			event  = 687008
			emperor = yes
		}
	random = no
	name = "The Holy Alliance"
	desc = "In 1683 an Ottoman army 140,000 men strong had failed to take Vienna by siege, and had been defeated by a combined Polish-German relief force in the Battle of Kahlenberg (Habsburg-Ottoman War 1683-1699). In December that year, Ottoman commander Kara Mustafa Pasha was strangled, an execution ordered by Sultan Mehmet IV. Pope Innocent XI. then forged the Holy Alliance, joined by the Papal State, the Emperor, Poland and the Republic of Venice, directed against the Ottoman Empire."
	style = 2
	date = { day = 1 month = january year = 1684 }
	offset = 1
	deathdate = { day = 29 month = december year = 1914 }

	action_a ={
		name = "Accept"
		command = { type = casusbelli   which = TUR value = 168 } 
		command = { type = war  which = TUR }
		command = { type = manpower   value = 20 }
		command = { type = trigger   which = 687007 }
	}
	action_b ={
		name = "Decline"
		command = { type = relation   which = PAP value = -100 }
		command = { type = relation   which = HAB value = -100 }
		command = { type = stability   value = 1 }

	}
}

event = {
	id = 687005

	country = PAP
	random = no
	name = "Poland Accepts"
	desc = "Poland accepted to join Pope Innocent XI's Holy Alliance."
	style = 2

	action_a ={
		name = "Amen"
		command = { type = relation   which = POL value = 200 }
		command = { type = alliance   which = POL }
	}
}
event = {
	id = 687006
	country = PAP
	random = no
	name = "Venice Accepts"
	desc = "Venice accepted to join Pope Innocent XI's Holy Alliance."
	style = 2

	action_a ={
		name = "Amen"
		command = { type = relation   which = VEN value = 200 }
		command = { type = alliance   which = VEN }
	}
}
event = {
	id = 687007
	country = PAP
	random = no
	name = "The Emperor Accepts"
	desc = "The Emperor accepted to join Pope Innocent XI's Holy Alliance."
	style = 2

	action_a ={
		name = "Amen"
		command = { type = relation   which = -6 value = 200 }
		command = { type = alliance   which = -6 }
	}
}

event = {
	id = 687008
	country = PAP
	random = no
	name = "Heralds"
	desc = "Holy Pope, our heralds have been sent to the nearest powers now we just have to wait."
	style = 2

	action_a ={
		name = "May god be with them"
		command = { type = cash   value = -25 }
		command = { type = diplomats   value = -4 }
	}
}

event = {
	id = 687009
	trigger = {
			event  = 687008
		}
	random = no
	country = RUS
	name = "The Holy Alliance"
	desc = "In 1683 an Ottoman army 140,000 men strong had failed to take Vienna by siege, and had been defeated by a combined Polish-German relief force in the Battle of Kahlenberg (Habsburg-Ottoman War 1683-1699). In December that year, Ottoman commander Kara Mustafa Pasha was strangled, an execution ordered by Sultan Mehmet IV. Pope Innocent XI. then forged the Holy Alliance, joined by the Papal State, the Emperor, Poland and the Republic of Venice, directed against the Ottoman Empire."
	style = 2
	date = { day = 1 month = january year = 1686 }
	offset = 1
	deathdate = { day = 29 month = december year = 1914 }

	action_a ={
		name = "Accept"
		command = { type = casusbelli   which = TUR value = 168 }
		command = { type = war  which = TUR }
		command = { type = manpower   value = 20 }
		command = { type = trigger   which = 687010 }
	}
	action_b ={
		name = "Decline"
		command = { type = relation   which = PAP value = -100 }
		command = { type = relation   which = HAB value = -100 }
		command = { type = stability   value = 1 }

	}
}

event = {
	id = 687010
	country = PAP
	random = no
	name = "The Russian Empire Accepts"
	desc = "The Russian Empire accepted to join Pope Innocent XI's Holy Alliance."
	style = 2

	action_a ={
		name = "Amen"
		command = { type = relation   which = -6 value = 200 }
		command = { type = alliance   which = -6 }
	}
}

event = {

	id = 687011
	trigger = {
			event = 687001
                            OR = {
                                    control = { province = 1951 data = HAB }#Oltenia
                                    control = { province = 355 data = HAB }#Serbia
		    	            }
		    	            control = { province = 354 data = HAB }#Temeswar
                            OR = {
                                    control = { province = 360 data = TUR }#Morea
                                    control = { province = 1969 data = TUR }#Achaea
		    	            }


		    	owned = { province = 1951 data = -1 }
		    	owned = { province = 354 data = -1 }
		    	owned = { province = 355 data = -1 }
		    	owned = { province = 360 data = VEN }
		    	owned = { province = 1969  data = VEN }

		    	war = { country = VEN country = TUR }
   	                war = { country = HAB country = TUR }
		}
	random = no
	country = TUR
	name = "Treaty of Passarowitz"
	desc = "The Treaty of Passarowitz was signed on July 21, 1718 between the Ottoman Empire on one side and the Habsburg Monarchy of Austria and the Republic of Venice on the other."
	style = 2

	date = { day = 1 month = january year = 1714 }
	offset = 30
	deathdate = { day = 29 month = december year = 1718 }

	action_a ={
		name = "Sign it"
		command = { type = secedeprovince which = HAB value = 1951 }	#Oltenia#
		command = { type = secedeprovince which = HAB value = 355 }     #Serbia#
		command = { type = secedeprovince which = HAB value = 354 }    #Temeswar#
		command = { type = trigger   which = 687012 }
	}
}

event = {

	id = 687012
	random = no
	country = VEN
	name = "Treaty of Passarowitz"
	desc = "The Treaty of Passarowitz was signed on July 21, 1718 between the Ottoman Empire on one side and the Habsburg Monarchy of Austria and the Republic of Venice on the other."
	style = 2

	action_a ={
		name = "Sign it"
		command = { type = secedeprovince which = TUR value = 360 }     #Morea#
		command = { type = secedeprovince which = TUR value = 1369 }    #Achaea#
	}
}

event = {

	id = 687013
	trigger = {
			event = 687011
                            OR = {
                                    control = { province = 1951 data = TUR }#Oltenia
                                    control = { province = 1951 data = WAL }#Oltenia
		    	            }
                            OR = {
                                    control = { province = 355 data = TUR }#Serbia
                                    control = { province = 355 data = WAL }#Serbia
		    	            }


		    	owned = { province = 1951 data = -1 }
		    	owned = { province = 355 data = -1 }
		    	vassal   = { country = TUR country = WAL }

                            OR = {
		    	war = { country = HAB country = WAL }
   	                war = { country = HAB country = TUR }
		    	            }
		}
	random = no
	country = HAB
	name = "Treaty of Belgrade"
	desc = "The Treaty of Belgrade was the peace treaty signed on September 18, 1739 in Belgrade, Serbia, by the Ottoman Empire on one side and the Habsburg Monarchy on the other. This ended the hostilities of the two-year Austro-Turkish War of 1737-39, in which the Habsburgs joined Imperial Russia in its fight against the Ottomans."
	style = 2

	date = { day = 1 month = january year = 1737 }
	offset = 30
	deathdate = { day = 29 month = december year = 1739 }

	action_a ={
		name = "Sign it"
		command = { type = secedeprovince which = WAL value = 1951 }	#Oltenia#
		command = { type = secedeprovince which = TUR value = 355 }     #Serbia#
		command = { type = sleepevent   which = 687014 }
	}
}

event = {

	id = 687014
	trigger = {
			event = 687011

                                    control = { province = 1951 data = TUR }#Oltenia
                                    control = { province = 355 data = TUR }#Serbia


		    	owned = { province = 1951 data = -1 }
		    	owned = { province = 355 data = -1 }
		    	NOT = {
                                  vassal   = { country = TUR country = WAL }
                        }
   	                war = { country = HAB country = TUR }
		}
	random = no
	country = HAB
	name = "Treaty of Belgrade"
	desc = "The Treaty of Belgrade was the peace treaty signed on September 18, 1739 in Belgrade, Serbia, by the Ottoman Empire on one side and the Habsburg Monarchy on the other. This ended the hostilities of the two-year Austro-Turkish War of 1737-39, in which the Habsburgs joined Imperial Russia in its fight against the Ottomans."
	style = 2

	date = { day = 1 month = january year = 1737 }
	offset = 30
	deathdate = { day = 29 month = december year = 1739 }

	action_a ={
		name = "Sign it"
		command = { type = secedeprovince which = TUR value = 1951 }	#Oltenia#
		command = { type = secedeprovince which = TUR value = 355 }     #Serbia#
		command = { type = sleepevent   which = 687013 }
	}
}

##########################
#------Random Events-----#
##########################

event = {
	id = 78793500
	random = yes
	country = HUN
	name = "EVENTNAME1"
	desc = "EVENTHIST1"
	style = 0

	action_a = {
		name = "OK"
		command = { type = revolt which = -1 }
	}

}

event = {
	id = 78793501
	trigger = {
		countrysize = 7
		ai = yes
	}
	random = yes
	country = HUN
	name = "EVENTNAME1"
	desc = "EVENTHIST1"
	style = 0

	action_a = {
		name = "OK"
		command = { type = revolt which = -1 }
		command = { type = revolt which = -1 }
	}

}

event = {
	id = 78793502
	trigger = {
		countrysize = 23
		ai = yes
	}
	random = yes
	country = HUN
	name = "EVENTNAME1"
	desc = "EVENTHIST1"
	style = 0

	action_a = {
		name = "OK"
		command = { type = revolt which = -1 }
		command = { type = revolt which = -1 }
		command = { type = revolt which = -1 }
	}

}

event = {
	id = 78793503
	trigger = {
		countrysize = 30
		ai = no
	}
	random = yes
	country = HUN
	name = "EVENTNAME1"
	desc = "EVENTHIST1"
	style = 0

	action_a = {
		name = "OK"
		command = { type = revolt which = -1 }
		command = { type = revolt which = -1 }
		command = { type = revolt which = -1 }
		command = { type = revolt which = -1 }
	}

}
