#####Spanish Major Events########
#By Joakim 'Greven' Bergqwist   #
#   Henrik 'Doomdark' Fеhraeus  #
#   Thomas 'Besuchov' Johansson #
#   Kristof 'BiB' Haekens       #
#################################


#Tomбs de Torquemada#
event = {
	id = 5251
	random = no
	country = SPA
	name = "EVENTNAME5251"
	desc = "EVENTHIST5251"
	style = 1
	date = { day = 1 month = august year = 1484 }

	action_a ={				#Ok#
		name = "ACTIONNAME5251A"
		command = { type = stability value = 2 }
		command = { type = domestic which = INNOVATIVE value = -1 }
command = { type = domestic which = CENTRALIZATION value = 1 }
command = { type = provincereligion which = 1948 value = catholic }
command = { type = provincereligion which = 1412 value = catholic }
command = { type = provincereligion which = 443 value = catholic }
	}
action_b ={				
		name = "Нам он не нужен"
		command = { type = stability value = -2 }
command = { type = provincereligion which = 991 value = hinduism }
command = { type = provincereligion which = 1948 value = sunni }
command = { type = domestic which = ARISTOCRACY value = 2 }
		command = { type = domestic which = CENTRALIZATION value = -2 }
command = { type = sleepevent which = 3150 }
command = { type = sleepevent which = 285044 }
	}
}

# Expulsion of the Spanish Jews
# By Fodoron
event = {
    id = 285044
    random = no     
    country = SPA
    name = "Изгнание испанских евреев"
    desc = "Евреи появились в Испании во времена мусульманского владычества, Кордовский эмиры были к ним лояльны. Умея хорошо ладить с арабами, сефарды успешно занимались морской торговлей. С течением времени они даже приобрели монопольное положение в этой важнейшей для испанской экономики области. Подобное привилегированное положение позволило иудеям сосредоточить в своих руках большую часть богатств полуострова. В должниках у сефардов числились даже Арагонские короли и Кастильские принцы. Изабелла, объединив под своей властью всю Испанию, вынуждена была принять своеобразное антимонопольное законодательство, запрещающее сефардам занимать определенные должности. Начались массовые крещения иудеев, в большинстве своём притворные. В среде крещёных иудеев было много еретиков. Великий инквизитор Токвемада предложил изгнать из Испании всех непринявших Христа евреев с компенацией оставляемого ими имущества...."
    style = 1 
    date = { day = 30 month = july year = 1492 }
      
    action_a = { # expell them
        name = "Изгнать тех, кто не примет христианство"
        command = { type = population which = 436 value = -500 } # Castilla
        command = { type = population which = 438 value = -500 } # Murcia
        command = { type = population which = 439 value = -500 }# Toledo
        command = { type = population which = 443 value = -3500 }# Andalucia
command = { type = population which = 1412 value = -500 }# Andalucia
        command = { type = treasury value = 100 } # Gold and communal properties seized
        command = { type = stability value = 2 } 
        command = { type = revoltrisk which = 12 value = -3 }
        command = { type = provincetax which = 443 value = -1 } # Andalucia
        command = { type = trade value = -500 }
        command = { type = loansize which = 100 }
        command = { type = ADM which = -1 value = 60 }
                command = { type = domestic which = CENTRALIZATION value = 1 }
                command = { type = domestic which = MERCANTILISM value = -1 }
    }
    action_b = { # 
        name = "Оставить всех евреев в Испании"
                command = { type = domestic which = ARISTOCRACY value = 1 }
                command = { type = domestic which = serfdom value = 1 }
                command = { type = domestic which = CENTRALIZATION value = -1 }
                command = { type = domestic which = MERCANTILISM value = 2 }
command = { type = provincereligion which = 991 value = hinduism }
        command = { type = stability value = -1 } 
        command = { type = revoltrisk which = 12 value = 2 }
        command = { type = ADM which = 1 value = 60 }
        command = { type = treasury value = 700 } # Jews offered gold to revert edict
    }
}

#Torquemada and the Expulsion of the Moors#
event = {

	id = 3150
trigger = {
		owned = { province = 444 data = SPA }
		atwar = no
		provincereligion = { province = 444 data = sunni } 
	}
	random = no
	country = SPA
	name = "EVENTNAME3150"
	desc = "EVENTHIST3150"
	style = 1

 date = { day = 20 month = may year = 1512 }
    offset = 600
    deathdate = { day = 1 month = january year = 1532 } 

	action_a ={		#Let us be rid of those we cannot trust#
		name = "Изгнать всех мавров-нехристиан"
		command = { type = domestic which = INNOVATIVE value = -2 }
		command = { type = population which = 443 value = -5000 }
		command = { type = population which = 439 value = -3000 }
command = { type = population which = 1412 value = -3000 }
		command = { type = population which = 438 value = -3000 }
                command = { type = population which = 1948 value = -3000 }
command = { type = population which = 1413 value = -5000 }
command = { type = population which = 445 value = -3000 }
		command = { type = population which = 444 value = -5000 }
                command = { type = population which = 438 value = -4000 }
                command = { type = provincereligion which = 444 value = catholic }
	command = { type = provincereligion which = 445 value = catholic }
        command = { type = provincereligion which = 1413 value = catholic }
command = { type = provincereligion which = 443 value = catholic }
command = { type = provincereligion which = 1948 value = catholic }
command = { type = provincereligion which = 1412 value = catholic }
command = { type = provincereligion which = 438 value = catholic }
                command = { type = provinceculture which = 443 value = iberian }
	        command = { type = provinceculture which = 1412 value = iberian }
		command = { type = stability value = -1 }
		command = { type = trigger which = 3654 }
		command = { type = trigger which = 3652 }
		command = { type = trigger which = 3657 }
command = { type = revolt which = 445 }
command = { type = revolt which = 444 }
command = { type = revolt which = 444 }
command = { type = revolt which = 438 }
command = { type = revolt which = 1948 }
command = { type = revolt which = 443 }
command = { type = revolt which = 1412 }
command = { type = revolt which = 1413 }
command = { type = treasury value = 500 }
	}

	action_b ={		#Let us make a clean sweep for the Glory of God#
		name = "Изгнать всех мавров"
		command = { type = domestic which = INNOVATIVE value = -4 }
                command = { type = treasury value = 1000 }
                command = { type = stability value = -3 }
                command = { type = remove_countryculture which = berber }
	command = { type = provincereligion which = 444 value = catholic }
	command = { type = provincereligion which = 445 value = catholic }
        command = { type = provincereligion which = 1413 value = catholic }
command = { type = provincereligion which = 443 value = catholic }
command = { type = provincereligion which = 1948 value = catholic }
command = { type = provincereligion which = 1412 value = catholic }
command = { type = provincereligion which = 438 value = catholic }
	command = { type = provinceculture which = 1413 value = iberian }
	command = { type = provinceculture which = 444 value = iberian }
	command = { type = provinceculture which = 445 value = iberian }
        command = { type = provinceculture which = 438 value = iberian }
command = { type = provinceculture which = 1412 value = iberian }
command = { type = provinceculture which = 443 value = iberian }
                command = { type = population which = 443 value = -8000 }
		command = { type = population which = 438 value = -12000 }
		command = { type = population which = 444 value = -18000 }
		command = { type = population which = 445 value = -8000 }
                command = { type = population which = 1948 value = -5000 }
                command = { type = population which = 1412 value = -6000 }
                command = { type = population which = 1413 value = -18000 }
command = { type = provincetax which = 444 value = -6 }
command = { type = provincetax which = 1413 value = -6 }
command = { type = provincetax which = 438 value = -3 }
command = { type = provincetax which = 445 value = -1 }
command = { type = provincetax which = 443 value = -2 }
command = { type = provincemanpower which = 438 value = -1 }
command = { type = provincemanpower which = 443 value = -1 }
command = { type = provincemanpower which = 444 value = -2 }
command = { type = provincemanpower which = 1413 value = -2 }
command = { type = fortress which = 444 value = -2 }
command = { type = fortress which = 1413 value = -2 }
command = { type = revolt which = 445 }
command = { type = revolt which = 444 }
command = { type = revolt which = 444 }
command = { type = revolt which = 438 }
command = { type = revolt which = 1948 }
command = { type = revolt which = 443 }
command = { type = revolt which = 1412 }
command = { type = revolt which = 445 }
command = { type = revolt which = 444 }
command = { type = revolt which = 444 }
command = { type = revolt which = 438 }
command = { type = revolt which = 1948 }
command = { type = revolt which = 443 }
command = { type = revolt which = 1412 }
command = { type = revolt which = 439 }
command = { type = revolt which = 1413 }
command = { type = revolt which = 439 }
command = { type = revolt which = 1413 }
command = { type = revolt which = 445 }
command = { type = revolt which = 444 }
command = { type = revolt which = 444 }
command = { type = revolt which = 438 }
command = { type = revolt which = 1948 }
command = { type = revolt which = 443 }
command = { type = revolt which = 1412 }
command = { type = revolt which = 445 }
command = { type = revolt which = 444 }
command = { type = revolt which = 444 }
command = { type = revolt which = 438 }
command = { type = revolt which = 1948 }
command = { type = revolt which = 443 }
command = { type = revolt which = 1412 }
command = { type = revolt which = 439 }
command = { type = revolt which = 1413 }
command = { type = revolt which = 439 }
command = { type = revolt which = 1413 }
command = { type = revolt which = 1412 }
command = { type = revolt which = 1412 }
command = { type = revolt which = 1412 }
command = { type = fortress which = 443 value = -1 }
command = { type = fortress which = 1413 value = -1 }
command = { type = fortress which = 1413 value = -1 }
command = { type = fortress which = 444 value = -2 }
command = { type = fortress which = 445 value = -1 }
command = { type = fortress which = 438 value = -1 }
		command = { type = trigger which = 3728 }
		command = { type = trigger which = 3729 }
		command = { type = trigger which = 3730 }
command = { type = sleepevent which = 3160 }
command = { type = sleepevent which = 3167 }
	}
}


#The Purge of the Morisques#
event = {

	id = 3160
	trigger = { 
			
	    OR = { owned = { province = 444 data = SPA }
			owned = { province = 445 data = SPA }
                        owned = { province = 1413 data = SPA }
                        }
		} 
	random = no
	country = SPA
	name = "EVENTNAME3160"
	desc = "EVENTHIST3160"
	style = 2

	date = { day = 1 month = may year = 1566 }
	offset = 600
	deathdate = { day = 1 month = january year = 1591 } # extended from 1571

	action_a ={		#Force them to become Good Catholic Spaniards#	
	name = "Изгнать всех мавров"
	command = { type = domestic which = INNOVATIVE value = -2 }
	command = { type = stability value = -2 }
  command = { type = treasury value = 500 }
	command = { type = population which = 438 value = -12000 }
	command = { type = population which = 444 value = -21000 }
	command = { type = population which = 445 value = -6000 }
        command = { type = population which = 1413 value = -21000 }
command = { type = population which = 443 value = -6000 }
command = { type = population which = 1412 value = -6000 }
	command = { type = provincereligion which = 444 value = catholic }
	command = { type = provincereligion which = 445 value = catholic }
        command = { type = provincereligion which = 1413 value = catholic }
command = { type = provincereligion which = 443 value = catholic }
command = { type = provincereligion which = 1948 value = catholic }
command = { type = provincereligion which = 1412 value = catholic }
command = { type = provincereligion which = 438 value = catholic }
	command = { type = provinceculture which = 1413 value = iberian }
	command = { type = provinceculture which = 444 value = iberian }
	command = { type = provinceculture which = 445 value = iberian }
        command = { type = provinceculture which = 438 value = iberian }
command = { type = provinceculture which = 1412 value = iberian }
command = { type = provinceculture which = 443 value = iberian }
command = { type = provincetax which = 444 value = -6 }
command = { type = provincetax which = 1413 value = -6 }
command = { type = provincetax which = 438 value = -3 }
command = { type = provincetax which = 445 value = -1 }
command = { type = provincetax which = 443 value = -2 }
command = { type = provincemanpower which = 438 value = -1 }
command = { type = provincemanpower which = 445 value = -1 }
command = { type = provincemanpower which = 443 value = -1 }
command = { type = provincemanpower which = 444 value = -2 }
command = { type = provincemanpower which = 1413 value = -2 }
command = { type = fortress which = 444 value = -2 }
command = { type = fortress which = 1413 value = -2 }
	command = { type = revolt which = 444 }
	command = { type = revolt which = 445 }
        command = { type = revolt which = 1413 }
        command = { type = revolt which = 444 }
	command = { type = revolt which = 445 }
        command = { type = revolt which = 1413 }
command = { type = revolt which = 438 }
        command = { type = revolt which = 438 }
command = { type = revolt which = 444 }
	command = { type = revolt which = 445 }
        command = { type = revolt which = 1413 }
        command = { type = revolt which = 444 }
	command = { type = revolt which = 445 }
        command = { type = revolt which = 1413 }
command = { type = revolt which = 438 }
        command = { type = revolt which = 438 }
command = { type = revolt which = 1412 }
command = { type = revolt which = 1412 }
command = { type = revolt which = 443 }
command = { type = revolt which = 443 }
command = { type = revolt which = 1948 }
command = { type = revolt which = 1412 }
command = { type = revolt which = 1412 }
command = { type = revolt which = 443 }
command = { type = revolt which = 443 }
command = { type = revolt which = 1948 }
command = { type = fortress which = 443 value = -1 }
command = { type = fortress which = 1413 value = -1 }
command = { type = fortress which = 1413 value = -1 }
command = { type = fortress which = 444 value = -2 }
command = { type = fortress which = 445 value = -1 }
command = { type = fortress which = 438 value = -1 }
	command = { type = trigger which = 3655 }
	command = { type = trigger which = 3658 }
        command = { type = remove_countryculture which = berber }
command = { type = sleepevent which = 3167 }
	}

	action_b ={		#Let them be as they are needed for the economy#
	name = "ACTIONNAME3160B"
	command = { type = domestic which = MERCANTILISM value = -2 }
	command = { type = domestic which = INNOVATIVE value = 2 }
	command = { type = stability value = -3 }
	command = { type = trade value = 1000 }
	command = { type = infra value = 1000 }
	command = { type = inflation value = -5 }
        command = { type = revoltrisk which = 48 value = 5 }
command = { type = revolt which = 1948 }
command = { type = revolt which = 443 }
command = { type = revolt which = 1412 }
command = { type = revolt which = 439 }
command = { type = revolt which = 436 }
command = { type = revolt which = 1948 }
command = { type = revolt which = 443 }
command = { type = revolt which = 1412 }
command = { type = revolt which = 439 }
command = { type = revolt which = 436 }
	}
}

#The Expulsion of the Morisques#
event = {

	id = 3167
	trigger = { 
			
			owned = { province = 444 data = SPA }
			owned = { province = 445 data = SPA }
                        owned = { province = 1413 data = SPA }
		} 
	random = no
	country = SPA
	name = "EVENTNAME3167"
	desc = "EVENTHIST3167"
	style = 3

	date = { day = 1 month = may year = 1600 }
	offset = 900
	deathdate = { day = 1 month = january year = 1612 }

	action_a ={			#Expel the Heretics!#
	name = "Изгнать всех мавров"
	command = { type = domestic which = INNOVATIVE value = -2 }
	command = { type = stability value = -2 }
  command = { type = treasury value = 500 }
	command = { type = population which = 438 value = -12000 }
	command = { type = population which = 444 value = -21000 }
	command = { type = population which = 445 value = -6000 }
        command = { type = population which = 1413 value = -21000 }
command = { type = population which = 443 value = -6000 }
command = { type = population which = 1412 value = -6000 }
	command = { type = provincereligion which = 444 value = catholic }
	command = { type = provincereligion which = 445 value = catholic }
        command = { type = provincereligion which = 1413 value = catholic }
command = { type = provincereligion which = 443 value = catholic }
command = { type = provincereligion which = 1948 value = catholic }
command = { type = provincereligion which = 1412 value = catholic }
command = { type = provincereligion which = 438 value = catholic }
	command = { type = provinceculture which = 1413 value = iberian }
	command = { type = provinceculture which = 444 value = iberian }
	command = { type = provinceculture which = 445 value = iberian }
        command = { type = provinceculture which = 438 value = iberian }
command = { type = provinceculture which = 1412 value = iberian }
command = { type = provinceculture which = 443 value = iberian }
command = { type = provincetax which = 444 value = -6 }
command = { type = provincetax which = 1413 value = -6 }
command = { type = provincetax which = 438 value = -3 }
command = { type = provincetax which = 445 value = -1 }
command = { type = provincetax which = 443 value = -2 }
command = { type = provincemanpower which = 438 value = -1 }
command = { type = provincemanpower which = 445 value = -1 }
command = { type = provincemanpower which = 443 value = -1 }
command = { type = provincemanpower which = 444 value = -2 }
command = { type = provincemanpower which = 1413 value = -2 }
command = { type = fortress which = 444 value = -2 }
command = { type = fortress which = 1413 value = -2 }
	command = { type = revolt which = 444 }
	command = { type = revolt which = 445 }
        command = { type = revolt which = 1413 }
        command = { type = revolt which = 444 }
	command = { type = revolt which = 445 }
        command = { type = revolt which = 1413 }
command = { type = revolt which = 438 }
        command = { type = revolt which = 438 }
command = { type = revolt which = 444 }
	command = { type = revolt which = 445 }
        command = { type = revolt which = 1413 }
        command = { type = revolt which = 444 }
	command = { type = revolt which = 445 }
        command = { type = revolt which = 1413 }
command = { type = revolt which = 438 }
        command = { type = revolt which = 438 }
command = { type = revolt which = 1412 }
command = { type = revolt which = 1412 }
command = { type = revolt which = 443 }
command = { type = revolt which = 443 }
command = { type = revolt which = 1948 }
command = { type = revolt which = 1412 }
command = { type = revolt which = 1412 }
command = { type = revolt which = 443 }
command = { type = revolt which = 443 }
command = { type = revolt which = 1948 }
command = { type = fortress which = 443 value = -1 }
command = { type = fortress which = 1413 value = -1 }
command = { type = fortress which = 1413 value = -1 }
command = { type = fortress which = 444 value = -2 }
command = { type = fortress which = 445 value = -1 }
command = { type = fortress which = 438 value = -1 }
	command = { type = trigger which = 3656 }
	command = { type = trigger which = 3653 }
	command = { type = trigger which = 3659 }
command = { type = remove_countryculture which = berber }
	}

	action_b ={	#Let them be as they are needed for the economy#
	name = "ACTIONNAME3167B"
	command = { type = domestic which = MERCANTILISM value = -2 }
	command = { type = domestic which = INNOVATIVE value = 2 }
	command = { type = stability  value = -4 }
	command = { type = revoltrisk which = 42 value = 8 }
	command = { type = trade value = 1000 }
	command = { type = infra value = 1000 }
	command = { type = inflation value = -5 }
command = { type = revolt which = 1948 }
command = { type = revolt which = 443 }
command = { type = revolt which = 1412 }
command = { type = revolt which = 439 }
command = { type = revolt which = 436 }
command = { type = revolt which = 1948 }
command = { type = revolt which = 443 }
command = { type = revolt which = 1412 }
command = { type = revolt which = 439 }
command = { type = revolt which = 436 }
	}
}

#The Habsburg Wedding#
event = {

	id = 3151		#Triggered by HAB3179#
	random = no
	country = SPA
	name = "EVENTNAME3151"
	desc = "EVENTHIST3151"
	style = 1

	action_a ={		#Humbly Accept Carlos' Wise Decision#
		name = "ACTIONNAME3151A"
		command = { type = stability value = -2 }
		command = { type = domestic which = ARISTOCRACY value = 2 }
		command = { type = domestic which = CENTRALIZATION value = -1 }
		command = { type = diplomats value = -6 }
	}
}

#The Habsburg Wedding#
event = {

	id = 3731		#Triggered by HAB3179#
	random = no
	country = SPA
	name = "EVENTNAME3731"
	desc = "EVENTHIST3731"
	style = 1

	action_a ={		#Humbly Accept Carlos' Wise Decision#
		name = "ACTIONNAME3731A"
		command = { type = dynastic which = HAB }
		command = { type = alliance which = HAB }
#		command = { type = vassal which = HAB }
		command = { type = treasury value = 500 }
		command = { type = domestic which = CENTRALIZATION value = 1 }
	}
}


#The Quest for the New World#
event = {

	id = 3152
	trigger = {
		war = {
			country = SPA
			country = AZT
		}
	}
	random = no
	country = SPA
	name = "EVENTNAME3152"
	desc = "EVENTHIST3152"
	style = 2

	date = { day = 1 month = january year = 1470 }
	offset = 30
	deathdate = { day = 1 month = january year = 1560 }

	action_a ={		#A New Reconquista! A New Beginning!#
		name = "ACTIONNAME3152A"
		command = { type = stability value = 1 }
		command = { type = treasury value = 500 }
		command = { type = colonists value = 6 }
		command = { type = missionaries value = 6 }
		command = { type = conquistador which = -1 }
		command = { type = conquistador which = -1 }
		command = { type = conquistador which = -1 }
		command = { type = explorer which = 902 }
		command = { type = explorer which = 903 }
		command = { type = explorer which = 904 }
		command = { type = addcore which = 29 } 
		command = { type = addcore which = 35 } 
                command = { type = addcore which = 1880 } 
                command = { type = addcore which = 31 } 
	}
}

#The Trade Center of Sevilla#
event = {
	id = 3153
	trigger = {owned = { province = 443 data = SPA } }  #added#
	random = no
	country = SPA
	name = "EVENTNAME3153"
	desc = "EVENTHIST3153"
	style = 2

	date = { day = 1 month = january year = 1501 }
	offset = 30
	deathdate = { day = 1 month = january year = 1526 } #moved from 1506#

	action_a ={		#We now have control of our Oversea Trade#
		name = "ACTIONNAME3153A"
		command = { type = cot which = 443 }
		command = { type = gainbuilding which = 443 value = shipyard }
		command = { type = merchants value = 6 }
		command = { type = treasury value = 300 }
	}
}

#The Fuggers#
event = {

	id = 3154
	random = no
	country = SPA
	name = "EVENTNAME3154"
	desc = "EVENTHIST3154"
	style = 2

	date = { day = 1 month = january year = 1508 }
	offset = 30
	deathdate = { day = 1 month = january year = 1514 }

	action_a ={		#Let the Fuggers run our Finances#
		name = "ACTIONNAME3154A"
		command = { type = loansize which = 500 }
		command = { type = treasury value = -100 }
		command = { type = merchants value = 6 }
		command = { type = inflation value = -5 }
                command = { type = domestic which = ARISTOCRACY value = -1 }
                command = { type = domestic which = centralization value = -1 }
                command = { type = domestic which = MERCANTILISM value = 2 }
	}

	action_b ={		#Turn the Fuggers offer down#
		name = "Нам не нужны монополисты"
		command = { type = treasury value = -100 }
		command = { type = stability value = -2 }
                command = { type = loansize which = 200 }
		command = { type = domestic which = ARISTOCRACY value = 1 }
                command = { type = domestic which = MERCANTILISM value = -1 }
                command = { type = inflation value = -2 }
	}
}

#The Communeros#
event = {

	id = 3155
	random = no
	country = SPA
	name = "EVENTNAME3155"
	desc = "EVENTHIST3155"
	style = 2

	date = { day = 1 month = january year = 1520 }
	offset = 30
	deathdate = { day = 1 month = july year = 1520 }

	action_a ={		#Crush the Rebellion#
	name = "ACTIONNAME3155A"
	command = { type = stability value = -1 }
        command = { type = treasury value = -200 }
	command = { type = domestic which = CENTRALIZATION value = 2 }
        command = { type = domestic which = ARISTOCRACY value = 1 }
	command = { type = domestic which = SERFDOM value = 1 }
command = { type = revolt which = 1412 }
command = { type = revolt which = 1412 }
command = { type = revolt which = 1412 }
        command = { type = revolt which = 431 }
command = { type = revolt which = 436 }
command = { type = revolt which = 1414 }
command = { type = revolt which = 440 }
command = { type = revolt which = 439 }
command = { type = revolt which = 438 }
command = { type = revolt which = 431 }
command = { type = revolt which = 436 }
command = { type = revolt which = 1414 }
command = { type = revolt which = 440 }
command = { type = revolt which = 439 }
command = { type = revolt which = 438 }
command = { type = revolt which = 431 }
command = { type = revolt which = 436 }
command = { type = revolt which = 1414 }
command = { type = revolt which = 440 }
command = { type = revolt which = 439 }
command = { type = revolt which = 438 }
	}

	action_b ={		#Use force, but give concessions to the Peasantry#
	name = "ACTIONNAME3155B"
	command = { type = treasury value = -200 }
	command = { type = domestic which = ARISTOCRACY value = -1 }
	command = { type = domestic which = SERFDOM value = -1 }
	command = { type = INF which = -1 value = 12083 }
	command = { type = INF which = -1 value = 9712 }
command = { type = stability value = -2 }	
command = { type = revolt which = 431 }
command = { type = revolt which = 436 }
command = { type = revolt which = 1414 }
command = { type = revolt which = 440 }
command = { type = revolt which = 439 }
command = { type = revolt which = 438 }
command = { type = revolt which = 431 }
command = { type = revolt which = 436 }
command = { type = revolt which = 1414 }
command = { type = revolt which = 440 }
command = { type = revolt which = 439 }
command = { type = revolt which = 438 }
command = { type = revolt which = 1412 }
command = { type = revolt which = 1412 }
	}

	action_c ={		#Use force, but give concessions to the Nobility#
	name = "ACTIONNAME3155C"
	command = { type = treasury value = -200 }
	command = { type = domestic which = ARISTOCRACY value = 1 }
	command = { type = domestic which = SERFDOM value = 2 }
	command = { type = CAV which = -1 value = 8342 }
	command = { type = CAV which = -1 value = 7665 }
command = { type = revolt which = 431 }
command = { type = revolt which = 436 }
command = { type = revolt which = 1414 }
command = { type = revolt which = 440 }
command = { type = revolt which = 439 }
command = { type = revolt which = 438 }
command = { type = revolt which = 1412 }
	}

}

#The Abdication of Charles V#
event = {

	id = 3157		#Triggered by HAB3190#
	random = no
	country = SPA
	name = "EVENTNAME3157"
	desc = "EVENTHIST3157"
	style = 2

	action_a ={		#Yes Father!#
		name = "ACTIONNAME3157A"
		
		command = { type = relation which = HAB value = 100 }
		command = { type = stability value = 1 }
               
	}
}

#The Abdication of Charles V#
event = {

	id = 3484		#Triggered by HAB3190#
	random = no
	country = POL
	name = "EVENTNAME3484"
	desc = "EVENTHIST3484"
	style = 2

	action_a ={		#Yes Father!#
		name = "ACTIONNAME3484A"
		
		command = { type = addcore which = 389 }
command = { type = addcore which = 1929 }
command = { type = addcore which = 1988 }
                command = { type = addcore which = 1919 }
		command = { type = addcore which = 1921 }
		command = { type = relation which = HAB value = -100 }
		command = { type = stability value = 1 }
                command = { type = remove_countryculture which = dutch }
	}
}


#The Abdication of Charles V#
event = {

	id = 3747		#Triggered by HAB3190#
	random = no
	country = SPA
	name = "EVENTNAME3747"
	desc = "EVENTHIST3747"
	style = 2

	action_a ={		#Yes Father!#
		name = "ACTIONNAME3747A"
	
		command = { type = relation which = HAB value = 50 }
		command = { type = stability value = 1 }
                
	}
}

#The Abdication of Charles V#
event = {

	id = 3748		#Triggered by HAB3749#
	random = no
	country = SPA
	name = "EVENTNAME3748"
	desc = "EVENTHIST3748"
	style = 2

	action_a ={		#Yes Father!#
		name = "ACTIONNAME3748A"
		command = { type = relation which = HAB value = 150 }
		command = { type = stability value = 1 }
                command = { type = remove_countryculture which = dutch }
	}
}

#State Bankruptcy#
event = {

	id = 3158
	trigger = {
		AND = {
			OR ={
				owned = { province = 24 data = -1 }
				owned = { province = 27 data = -1 }
				owned = { province = 159 data = -1 }
				}
			OR ={
				owned = { province = 25 data = -1 }
				owned = { province = 163 data = -1 }
				owned = { province = 167 data = -1 }
				}
			OR ={
				owned = { province = 26 data = -1 }
				owned = { province = 194 data = -1 }
				owned = { province = 169 data = -1 }
				}
			}
         AND = {
			
		domestic = { type = ARISTOCRACY value = 6 }
                domestic = { type = serfdom value = 5 }
                domestic = { type =  MERCANTILISM value = 6 }
			}
         AND = {
			NOT = {
				domestic = {
					type = innovative
					value = 8
					}
				}
			}
		}
	random = no
	country = SPA
	name = "EVENTNAME3158"
	desc = "EVENTHIST3158"
	style = 2

	date = { day = 1 month = january year = 1592 }
	offset = 30
	deathdate = { day = 1 month = january year = 1598 }

	action_a ={		#Declare State Bankruptcy#
		name = "ACTIONNAME3158A"
		command = { type = treasury value = -1000 }
		command = { type = loansize which = 100 }
		command = { type = inflation value = 10 }
		command = { type = stability value = -3 }
		command = { type = desertion which = -1 value = 9892 }
		command = { type = desertion which = -1 value = 5841 }
		command = { type = desertion which = -1 value = 5613 }
                command = { type = trade value = -1000 }
		command = { type = naval value = -1000 }
		command = { type = infra value = -1000 }
	}
}

#The Holy League#
event = {

	id = 3161
	trigger = {
			exists = TUR
			AND = {
				event = 3549 
				} 
		}
	random = no
	country = SPA
	name = "EVENTNAME3161"
	desc = "EVENTHIST3161"
	style = 2

	date = { day = 1 month = january year = 1568 }
	offset = 30
	deathdate = { day = 1 month = january year = 1571 }

	action_a ={		#Support the Holy League#
		name = "ACTIONNAME3161A"
		command = { type = casusbelli which = TUR value = 72 }
		command = { type = relation which = TUR value = 150 }
		command = { type = relation which = PAP value = 150 }
		command = { type = relation which = FRA value = 150 }
		command = { type = relation which = KNI value = 150 }
		command = { type = relation which = TOS value = 150 }
		command = { type = relation which = VEN value = 150 }
		command = { type = relation which = NAP value = 150 }
		command = { type = relation which = SAV value = 150 }
	}

	action_b ={		#Let the matter fall#
		name = "ACTIONNAME3161B"
		command = { type = relation which = TUR value = 50 }
		command = { type = relation which = PAP value = -50 }
		command = { type = relation which = FRA value = -50 }
		command = { type = relation which = KNI value = -50 }
		command = { type = relation which = TOS value = -50 }
		command = { type = relation which = VEN value = -50 }
		command = { type = relation which = NAP value = -50 }
		command = { type = relation which = SAV value = -50 }
	}
}

#The Portuguese Crown#
event = {

	id = 3162
	random = no
	country = SPA
	name = "EVENTNAME3162"
	desc = "EVENTHIST3162"
	style = 2

	date = { day = 1 month = february year = 1580 }
	offset = 0
	deathdate = { day = 2 month = february year = 1580 }

	action_a ={		#One King, One Kingdom#
		name = "ACTIONNAME3162A"
		command = { Type = vassal which = POR }
		command = { Type = dynastic which = POR }
		command = { Type = stability value = 1 }
                command = { type = add_countryculture which = maltese }
                command = { type = badboy value = -12 }
	}

	action_b ={		#One King, Two Kingdoms#
		name = "ACTIONNAME3162B"
		command = { Type = alliance which = POR }
		command = { Type = dynastic which = POR }
		command = { Type = stability value = -1 }
	}
}

#The Portuguese Crown#
event = {

	
id = 3163

trigger = {  

OR = { 
vassal = { country = SPA country = POR }
alliance = { country = SPA country = POR }

     }                         

    }
	random = no
	country =  SPA
	name = "EVENTNAME3163"
	desc = "EVENTHIST3163"
	style = 3

	date = { day = 1 month = april year = 1621 }
	offset = 0
	deathdate = { day = 2 month = april year = 1621 }

	action_a ={		#One King, One Kingdom#
		name = "Настаивать на объеденении"
                command = { type = trigger which = 307235 }
	}

	action_b ={		#One King, Two Kingdoms#
		name = "ACTIONNAME3162B"
		command = { Type = alliance which = POR }
		command = { Type = dynastic which = POR }
 command = { type = badboy value = -6 }

	}
}

event = {
	id = 307235
	random = no
	country = POR
	name = "Требование испанского короля"
	desc = "Наш союзник Испанский король требует объеденить наши страны, чтобы убрать торговые барьеры и объеденить ресурсы для борьбы с еретиками и неверными. Согласиться - значить потерять независимость."
	style = 3
	action_a ={	
		name = "Подчиниться - Конец игры"
		command = { type = trigger which = 307236 } 

	}
	action_b ={
		name = "Нет, мы свободное гос-во"
		command = { type = relation which = SPA value = -100 }
	}
}

 

event = {
        id = 307236
	random = no
	country =  SPA
	name = "EVENTNAME3163"
	desc = "Унификация империи - Португальцы согласились на объеденение"
	style = 3

	date = { day = 1 month = april year = 1621 }
	offset = 0
	deathdate = { day = 2 month = april year = 1621 }

	action_a ={		
		name = "Прекрасно!"
command = { Type = stability value = -1 }
		command = { type = inherit which = POR }
		command = { type = add_countryculture which = mississippian }
		command = { type = addcore which = 434 } # Porto
		command = { type = addcore which = 441 } # Tago
		command = { type = addcore which = 442 } # Algarve
		command = { type = addcore which = 823 } # Azores
		command = { type = addcore which = 1918 }
		command = { type = addcore which = 1409 }
command = { type = addcore which = 1014 }
		command = { type = addcore which = 1728 }
command = { type = addcore which = 1996 }
                command = { type = badboy value = -5 }
	}
}

#State Bankruptcy#
event = {

	id = 3164
	trigger = {
		AND = {
			OR ={
				owned = { province = 24 data = -1 }
				owned = { province = 27 data = -1 }
				owned = { province = 159 data = -1 }
				}
			OR ={
				owned = { province = 25 data = -1 }
				owned = { province = 163 data = -1 }
				owned = { province = 167 data = -1 }
				}
			OR ={
				owned = { province = 26 data = -1 }
				owned = { province = 194 data = -1 }
				owned = { province = 169 data = -1 }
				}
			}
               AND = {
			
		domestic = { type = ARISTOCRACY value = 6 }
                domestic = { type = serfdom value = 5 }
                domestic = { type =  MERCANTILISM value = 6 }
			}
             AND = {
			NOT = {
				domestic = {
					type = innovative
					value = 8
					}
				}
			}
		}

	random = no
	country = SPA
	name = "EVENTNAME3164"
	desc = "EVENTHIST3164"
	style = 3

	date = { day = 1 month = january year = 1621 }
	offset = 30
	deathdate = { day = 1 month = january year = 1641 }

	action_a ={			#Declare State Bankruptcy#
		name = "ACTIONNAME3164A"
		command = { type = treasury value = -1600 }
		command = { type = loansize which = 200 }
		command = { type = inflation value = 10 }
		command = { type = stability value = -3 }
		command = { type = desertion which = -1 value = 11198 }
		command = { type = desertion which = -1 value = 7317 }
		command = { type = desertion which = -1 value = 9467 }
                command = { type = trade value = -1000 }
		command = { type = naval value = -1000 }
		command = { type = infra value = -1000 }

	}
}

#Epidemic Plague#
event = {

	id = 3165
	random = no
	country = SPA
	name = "EVENTNAME3165"
	desc = "EVENTHIST3165"
	style = 3

	date = { day = 1 month = january year = 1596 }
	offset = 30
	deathdate = { day = 1 month = january year = 1603 }

	action_a ={				#Arrgh!#
		name = "ACTIONNAME3165A"
		command = { type = stability value = -1 }
		command = { type = trigger which = 3273 }
		command = { type = population which = -1 value = -3000 }
		command = { type = provincetax which = -3 value = -1 }
		command = { type = population which = -1 value = -5000 }
		command = { type = provincetax which = -3 value = -1 }
		command = { type = population which = -1 value = -3000 }
		command = { type = provincetax which = -3 value = -1 }
		command = { type = population which = -1 value = -3000 }
		command = { type = provincetax which = -3 value = -1 }
		command = { type = population which = -1 value = -3000 }
		command = { type = provincetax which = -3 value = -1 }
		command = { type = population which = -1 value = -3000 }
		command = { type = provincetax which = -3 value = -1 }
	}
}

#The Catholic League#
event = {

	id = 3166
	trigger = {
		 OR = {
			religion = catholic
			religion = counterreform
				}
			}
	random = no
	country = SPA
	name = "EVENTNAME3166"
	desc = "EVENTHIST3166"
	style = 3

	date = { day = 1 month = january year = 1607 }
	offset = 30
	deathdate = { day = 1 month = january year = 1609 }

	action_a ={			#Prepare to Join#
		name = "ACTIONNAME3166A"
		command = { type = relation which = FRA value = -100 }
		command = { type = relation which = BRA value = -150 }
		command = { type = relation which = HAN value = -150 }
		command = { type = relation which = HES value = -150 }
		command = { type = relation which = PFA value = -150 }
		command = { type = relation which = SAC value = -150 }
		command = { type = relation which = THU value = -150 }
		command = { type = relation which = SHL value = -150 }
		command = { type = relation which = KLE value = 100 }
		command = { type = relation which = KOL value = 150 }
		command = { type = relation which = BAY value = 150 }
		command = { type = relation which = PAP value = 150 }
		command = { type = relation which = HAB value = 150 }
	}

	action_b ={			#Stay Neutral#
		name = "ACTIONNAME3166B"
		command = { type = relation which = BRA value = 100 }
		command = { type = relation which = HAN value = 100 }
		command = { type = relation which = HES value = 100 }
		command = { type = relation which = PFA value = 100 }
		command = { type = relation which = SAC value = 100 }
		command = { type = relation which = THU value = 100 }
		command = { type = relation which = BAY value = 50 }
		command = { type = relation which = KLE value = -50 }
		command = { type = relation which = KOL value = -50 }
		command = { type = relation which = HAB value = -100 }
		command = { type = relation which = PAP value = -150 }
	}
}





#The Iberian Revolts#
event = {

	id = 3169
	trigger ={
		atwar = yes
		}
	random = no
	country = SPA
	name = "EVENTNAME3169"
	desc = "EVENTHIST3169"
	style = 3

	date = { day = 1 month = january year = 1630 }
	offset = 41
	deathdate = { day = 1 month = january year = 1649 }


	action_a ={			#Put it down!#
		name = "ACTIONNAME3169A"
		
		command = { type = trigger which = 3170 }
		command = { type = breakvassal which = ARG }
		command = { type = relation which = ARG value = -200 }
		command = { type = breakvassal which = CAS }
		command = { type = relation which = CAS value = -200 }
		command = { type = breakvassal which = CAT }
		command = { type = relation which = CAT value = -200 }
		command = { type = revolt which = 429 }
		command = { type = revolt which = 429 }
		command = { type = revolt which = 427 }
		command = { type = revolt which = 821 }
		command = { type = revolt which = 397 }
command = { type = revolt which = 1410 }
		command = { type = revolt which = 1410 }
		command = { type = revolt which = 1990 }
		command = { type = INF which = 436 value = 10000 }
		command = { type = domestic which = INNOVATIVE value = -1 }
	}

	action_b ={			#Appease them!#
		name = "ACTIONNAME3169B"
		
		command = { type = trigger which = 3170 }
		command = { type = treasury value = -500 }
		command = { type = stability value = 1 }
		command = { type = domestic which = ARISTOCRACY value = 3 }
		command = { type = domestic which = CENTRALIZATION value = -1 }

	}
}

#The Italian Revolts#
event = {

	id = 3170					#Triggered by SPA3169#
	random = no
	country = SPA
	name = "EVENTNAME3170"
	desc = "EVENTHIST3170"
	style = 3

	action_a ={			#Put it down!#
		name = "ACTIONNAME3170A"
                command = { type = INF which = 396 value = 10000 }
		command = { type = INF which = 394 value = 10000 }
		command = { type = domestic which = INNOVATIVE value = -1 }
		command = { type = revolt which = 395 }
		command = { type = revolt which = 393 }
		command = { type = revolt which = 399 }
		command = { type = revolt which = 400 }
		command = { type = revolt which = 402 }
command = { type = revolt which = 1407 }
command = { type = revolt which = 1989 }
command = { type = revolt which = 1988 }
		command = { type = revolt which = 389 }
                command = { type = revolt which = 1919 }
		command = { type = revolt which = 1921 }
		command = { type = revolt which = 934 }
                command = { type = revolt which = 1922 }
		command = { type = revolt which = 1923 }
                command = { type = revolt which = 395 }
		command = { type = revolt which = 393 }
		command = { type = revolt which = 399 }
		command = { type = revolt which = 400 }
		command = { type = revolt which = 402 }
		command = { type = revolt which = 389 }
                command = { type = revolt which = 1919 }
		command = { type = revolt which = 1921 }
		command = { type = revolt which = 934 }
                command = { type = revolt which = 1922 }
		command = { type = revolt which = 1923 }
	command = { type = revolt which = 395 }
		command = { type = revolt which = 393 }
		command = { type = revolt which = 399 }
		command = { type = revolt which = 400 }
		command = { type = revolt which = 402 }
command = { type = revolt which = 1407 }
command = { type = revolt which = 1989 }
command = { type = revolt which = 1988 }
		command = { type = revolt which = 389 }
                command = { type = revolt which = 1919 }
		command = { type = revolt which = 1921 }
		command = { type = revolt which = 934 }
                command = { type = revolt which = 1922 }
		command = { type = revolt which = 1923 }
                command = { type = revolt which = 395 }
		command = { type = revolt which = 393 }
		command = { type = revolt which = 399 }
		command = { type = revolt which = 400 }
		command = { type = revolt which = 402 }
		command = { type = revolt which = 389 }
                command = { type = revolt which = 1919 }
		command = { type = revolt which = 1921 }
		command = { type = revolt which = 934 }
                command = { type = revolt which = 1922 }
		command = { type = revolt which = 1923 }
command = { type = revolt which = 1999 }
command = { type = revolt which = 1999 }	
	}

	action_b ={			#Appease them!#
		name = "ACTIONNAME3170B"
		command = { type = treasury value = -1000 }
		command = { type = stability value = 1 }
		command = { type = domestic which = CENTRALIZATION value = -2 }

	}
}



#France opens Chambers of Reunion#
event = {

	id = 3172			#Triggered by FRA3127#
	random = no
	country = SPA
	name = "EVENTNAME3172"
	desc = "EVENTHIST3172"
	style = 3

	action_a ={				#Defy French claims#
		name = "ACTIONNAME3172A"
		command = { type = casusbelli which = FRA value = 72 }
		command = { type = relation which = FRA value = -150 }
		command = { type = relation which = ENG value = 150 }
		command = { type = relation which = HAB value = 150 }
		command = { type = relation which = PRU value = 150 }
		command = { type = relation which = HOL value = 150 }
		command = { type = relation which = HAN value = 100 }
		command = { type = relation which = BAD value = 100 }
		command = { type = relation which = HES value = 100 }
		command = { type = relation which = KLE value = 100 }
		command = { type = relation which = KOL value = 100 }
		command = { type = relation which = PFA value = 100 }
		command = { type = relation which = THU value = 100 }
	}

	action_b ={				#Give in to France#
		name = "ACTIONNAME3172B"
		command = { type = secedeprovince which = FRA value = 377 }
		command = { type = secedeprovince which = FRA value = 375 }
		command = { type = secedeprovince which = FRA value = 379 }
command = { type = secedeprovince which = FRA value = 1983 }
		command = { type = relation which = ENG value = -100 }
		command = { type = relation which = HAB value = -100 }
		command = { type = relation which = PRU value = -100 }
		command = { type = relation which = HOL value = -100 }
		command = { type = relation which = FRA value = 150 }
	}
}

#The Succession of Carlos II in Spain#
event = {

	id = 3173
	random = no
	country = SPA
trigger = {

NOT = {	vassal = { country = SPA country = FRA } }
}

	name = "EVENTNAME3173"
	desc = "EVENTHIST3173"
	style = 4

	date = { day = 1 month = november year = 1700 }
	offset = 0
	deathdate = { day = 2 month = november year = 1700 }

	action_a ={
		name = "ACTIONNAME3173A"	#Felipe of Bourbon#
		command = { type = trigger which = 3199 }
		command = { type = trigger which = 3130 }
		command = { type = trigger which = 3035 }
		command = { type = trigger which = 3511 }
		command = { type = stability value = 2 }
		command = { type = dynastic which = FRA }
		command = { type = alliance which = FRA }
		command = { type = relation which = FRA value = 150 }
		command = { type = relation which = HAB value = -150 }
	}

	action_b ={
		name = "ACTIONNAME3173B"	#Carlos of Habsburg#
		command = { type = trigger which = 3200 }
		command = { type = trigger which = 3131 }
		command = { type = trigger which = 3036 }
		command = { type = trigger which = 3512 }
		command = { type = stability value = -1 }
		command = { type = dynastic which = HAB }
		command = { type = alliance which = HAB }
		command = { type = relation which = HAB value = 150 }
		command = { type = relation which = FRA value = -150 }

		#Habsburg Dynasty#
		command = { type = wakemonarch which = 04151 }
		command = { type = wakemonarch which = 04152 }
		command = { type = wakemonarch which = 04153 }
		command = { type = wakemonarch which = 04154 }
		command = { type = wakemonarch which = 04155 }
	}


}

#The Effects of the Pragmatic Sanction#
event = {

	id = 3174
	trigger = {
		NOT = { 
			Event = 3200
			}
		}
	random = no
	country = SPA
	name = "EVENTNAME3174"
	desc = "EVENTHIST3174"
	style = 4

	date = { day = 1 month = january year = 1741 }
	offset = 10
	deathdate = { day = 1 month = august year = 1741 }

	action_a ={		#Anti-Habsburg#
		name = "ACTIONNAME3174A"
		command = { type = casusbelli which = HAB value = 36 }
		command = { type = stability value = -1 }
		command = { type = relation which = BAY value = 100 }
		command = { type = relation which = SAC value = 100 }
		command = { type = relation which = GEN value = 100 }
		command = { type = relation which = PRU value = 100 }
		command = { type = relation which = FRA value = 150 }
		command = { type = relation which = ENG value = -150 }
		command = { type = relation which = HOL value = -100 }
		command = { type = relation which = POR value = -100 }
		command = { type = relation which = RUS value = -50 }
		command = { type = relation which = HES value = -50 }
		command = { type = relation which = HAN value = -50 }
		command = { type = relation which = HAB value = -150 }

	}

	action_b ={		#Neutral#
		name = "ACTIONNAME3174B"
		command = { type = stability value = 2 }
		command = { type = relation which = BAY value = -50 }
		command = { type = relation which = SAC value = -50 }
		command = { type = relation which = GEN value = 50 }
		command = { type = relation which = PRU value = -50 }
		command = { type = relation which = FRA value = 50 }
		command = { type = relation which = ENG value = 50 }
		command = { type = relation which = HOL value = 100 }
		command = { type = relation which = POR value = 100 }
		command = { type = relation which = RUS value = 50 }
		command = { type = relation which = HES value = 50 }
		command = { type = relation which = HAN value = 50 }
		command = { type = relation which = HAB value = 100 }

	}

	action_c ={		#Pro-Habsburg#
		name = "ACTIONNAME3174C"
		command = { type = stability value = -2 }
		command = { type = casusbelli which = FRA value = 36 }
		command = { type = relation which = BAY value = -100 }
		command = { type = relation which = SAC value = -100 }
		command = { type = relation which = GEN value = -50 }
		command = { type = relation which = PRU value = -100 }
		command = { type = relation which = FRA value = -150 }
		command = { type = relation which = ENG value = 100 }
		command = { type = relation which = HOL value = -150 }
		command = { type = relation which = POR value = 150 }
		command = { type = relation which = RUS value = 50 }
		command = { type = relation which = HES value = 50 }
		command = { type = relation which = HAN value = 50 }
		command = { type = relation which = HAB value = 150 }	}

}

#The Sale of Corsica#
event = {

	id = 3175		#Triggered by GEN3708 or ENG3046#
	random = no
	country = SPA
	name = "EVENTNAME3175"
	desc = "EVENTHIST3175"
	style = 4

	action_a ={				#Offer to buy Corsica#
		name = "ACTIONNAME3175A"
		command = { type = trigger which = 3709 }
	}

	action_b ={			#Pass the opportunity#
		name = "ACTIONNAME3175B"
		command = { type = trigger which = 3648 }
	}
}

#Genoa accepts offer to buy Corsica#
event = {

	id = 3723			#Triggered by GEN3709#
	random = no
	country = SPA
	name = "EVENTNAME3723"
	desc = "EVENTHIST3723"
	style = 4

	action_a ={				#Good#
		name = "ACTIONNAME3723A"
		command = { type = relation which = GEN value = 150 }
		command = { type = treasury value = -1200 }
	}
}

#Genoa decline offer to buy Corsica#
event = {

	id = 3724			#Triggered by GEN3709#
	random = no
	country = SPA
	name = "EVENTNAME3724"
	desc = "EVENTHIST3724"
	style = 4

	action_a ={				#Darn#
		name = "ACTIONNAME3724A"
		command = { type = relation which = GEN value = -100 }
	}
}

#The American Colonial Policy#
event = {

	id = 3176
	trigger = {
		NOT = {
			domestic = {
				type = innovative
				value = 10
				}
			}
		}
	random = no
	country = SPA
	name = "EVENTNAME3176"
	desc = "EVENTHIST3176"
	style = 4

	date = { day = 1 month = january year = 1790 }
	offset = 10
	deathdate = { day = 1 month = august year = 1820 }


	action_a ={		#Govern through Spanish Governors#
		name = "ACTIONNAME3176A"
		command = { type = province_revoltrisk which = 24  value = 4 }
		command = { type = province_revoltrisk which = 25  value = 4 }
		command = { type = province_revoltrisk which = 26  value = 4 }
		command = { type = province_revoltrisk which = 27  value = 4 }
		command = { type = province_revoltrisk which = 28  value = 4 }
		command = { type = province_revoltrisk which = 29  value = 4 }
		command = { type = province_revoltrisk which = 30  value = 4 }
		command = { type = province_revoltrisk which = 223  value = 4 }
		command = { type = province_revoltrisk which = 222  value = 4 }
		command = { type = province_revoltrisk which = 1485  value = 4 }
		command = { type = province_revoltrisk which = 1486  value = 4 }
		command = { type = province_revoltrisk which = 218  value = 4 }
		command = { type = province_revoltrisk which = 217  value = 4 }
		command = { type = province_revoltrisk which = 224  value = 4 }
		command = { type = province_revoltrisk which = 158  value = 4 }
		command = { type = province_revoltrisk which = 160  value = 4 }
		command = { type = province_revoltrisk which = 161  value = 4 }
		command = { type = province_revoltrisk which = 162  value = 4 }
		command = { type = province_revoltrisk which = 163  value = 4 }
		command = { type = province_revoltrisk which = 164  value = 4 }
		command = { type = province_revoltrisk which = 165  value = 4 }
		command = { type = province_revoltrisk which = 166  value = 4 }
		command = { type = province_revoltrisk which = 167  value = 4 }
		command = { type = province_revoltrisk which = 168  value = 4 }
		command = { type = stability value = 1 }
		command = { type = relation which = USA value = -50 }
	}

	action_b ={		#Govern from Madrid#
		name = "ACTIONNAME3176B"
		command = { type = province_revoltrisk which = 24  value = 8 }
		command = { type = province_revoltrisk which = 25  value = 8 }
		command = { type = province_revoltrisk which = 26  value = 8 }
		command = { type = province_revoltrisk which = 27  value = 8 }
		command = { type = province_revoltrisk which = 28  value = 8 }
		command = { type = province_revoltrisk which = 29  value = 8 }
		command = { type = province_revoltrisk which = 30  value = 8 }
		command = { type = province_revoltrisk which = 223  value = 8 }
		command = { type = province_revoltrisk which = 222  value = 8 }
		command = { type = province_revoltrisk which = 1485  value = 8 }
		command = { type = province_revoltrisk which = 1486  value = 8 }
		command = { type = province_revoltrisk which = 218  value = 8 }
		command = { type = province_revoltrisk which = 217  value = 8 }
		command = { type = province_revoltrisk which = 224  value = 8 }
		command = { type = province_revoltrisk which = 158  value = 8 }
		command = { type = province_revoltrisk which = 160  value = 8 }
		command = { type = province_revoltrisk which = 161  value = 8 }
		command = { type = province_revoltrisk which = 162  value = 8 }
		command = { type = province_revoltrisk which = 163  value = 8 }
		command = { type = province_revoltrisk which = 164  value = 8 }
		command = { type = province_revoltrisk which = 165  value = 8 }
		command = { type = province_revoltrisk which = 166  value = 8 }
		command = { type = province_revoltrisk which = 167  value = 8 }
		command = { type = province_revoltrisk which = 168  value = 8 }
		command = { type = stability value = 3 }
		command = { type = relation which = USA value = -150  }
	}

	action_c ={		#Franchised Citizenship#
		name = "ACTIONNAME3176C"
		command = { type = province_revoltrisk which = 24  value = 1 }
		command = { type = province_revoltrisk which = 25  value = 1 }
		command = { type = province_revoltrisk which = 26  value = 1 }
		command = { type = province_revoltrisk which = 27  value = 1 }
		command = { type = province_revoltrisk which = 28  value = 1 }
		command = { type = province_revoltrisk which = 29  value = 1 }
		command = { type = province_revoltrisk which = 30  value = 1 }
		command = { type = province_revoltrisk which = 223  value = 1 }
		command = { type = province_revoltrisk which = 222  value = 1 }
		command = { type = province_revoltrisk which = 1485  value = 1 }
		command = { type = province_revoltrisk which = 1486  value = 1 }
		command = { type = province_revoltrisk which = 218  value = 1 }
		command = { type = province_revoltrisk which = 217  value = 1 }
		command = { type = province_revoltrisk which = 224  value = 1 }
		command = { type = province_revoltrisk which = 158  value = 1 }
		command = { type = province_revoltrisk which = 160  value = 1 }
		command = { type = province_revoltrisk which = 161  value = 1 }
		command = { type = province_revoltrisk which = 162  value = 1 }
		command = { type = province_revoltrisk which = 163  value = 1 }
		command = { type = province_revoltrisk which = 164  value = 1 }
		command = { type = province_revoltrisk which = 165  value = 1 }
		command = { type = province_revoltrisk which = 166  value = 1 }
		command = { type = province_revoltrisk which = 167  value = 1 }
		command = { type = province_revoltrisk which = 168  value = 1 }
		command = { type = stability value = -2 }
		command = { type = relation which = USA value = 100 }
	}

}

#The Sale of Florida to the United States#
event = {

	id = 3090
	date = { day = 1 month = january year = 1819 }
	offset = 120
	deathdate = { day = 2 month = may year = 1819 }
	trigger = {
		exists = USA
		OR = { 
			owned = { province = 48 data = -1 }
			owned = { province = 49 data = -1 }
			owned = { province = 50 data = -1 }
			}
	}

	random = no
	country = SPA
	name = "EVENTNAME3090"
	desc = "EVENTHIST3090"
	style = 5

	action_a ={		#Offer Florida for 500 ducats#
		name = "ACTIONNAME3090A"
		command = { type = trigger which = 3067 }
	}

	action_b ={		#Offer them nothing#
		name = "ACTIONNAME3090B"
		command = { type = relation which = USA value = -100 }
		command = { type = stability value = -1 } 
	}
}

#Adam-Onнs Treaty#
event = {

	id = 3091			#Triggered by USA3067#
	random = no
	country = SPA
	name = "EVENTNAME3091"
	desc = "EVENTHIST3091"
	style = 5

	action_a ={			#Ok#
		name = "ACTIONNAME3091A"
		command = { type = treasury value = 500 }
		command = { type = stability value = 2 }
		command = { type = relation which = USA value = 100 }
		command = { type = secedeprovince which = USA value = 48 }
		command = { type = secedeprovince which = USA value = 49 }
		command = { type = secedeprovince which = USA value = 50 }
	}
}

#The United States declined the offer of Florida#
event = {

	id = 3092			#Triggered by USA3067#
	random = no
	country = SPA
	name = "EVENTNAME3092"
	desc = "EVENTHIST3092"
	style = 5

	action_a ={			#Ok#
		name = "ACTIONNAME3092A"
		command = { type = relation which = USA value = -100 }
	}

}
#Josй Monino's Reforms#
event = {

	id = 3094
	random = no
	country = SPA
	name = "EVENTNAME3094"
	desc = "EVENTHIST3094"
	style = 5

	date = { day = 1 month = january year = 1769 }
	offset = 10
	deathdate = { day = 1 month = january year = 1770 }

	action_a ={			#Reform#
		name = "ACTIONNAME3094A"
		command = { type = domestic which = MERCANTILISM value = -2 }
		command = { type = domestic which = INNOVATIVE value = 2 }
		command = { type = gainmanufactory which = -1 value = refinery }
		command = { type = gainmanufactory which = -1 value = goods }
		command = { type = stability value = -2 }
	}

	action_b ={			#Do not reform#
		name = "ACTIONNAME3094B"
		command = { type = stability value = 2 }
		command = { type = treasury value = 300 }
	}
}

#The Constitution of 1812#
event = {

	id = 3095
	random = no
	country = SPA
	name = "EVENTNAME3095"
	desc = "EVENTHIST3095"
	style = 5

	date = { day = 1 month = january year = 1812 }
	offset = 10
	deathdate = { day = 30 month = december year = 1812 }

	action_a ={		#The Cortes has enacted it already#
		name = "ACTIONNAME3095A"
		command = { type = domestic which = ARISTOCRACY value = -5 }
		command = { type = domestic which = SERFDOM value = -5 }
		command = { type = domestic which = MERCANTILISM value = -2 }
		command = { type = domestic which = INNOVATIVE value = 2 }
		command = { type = domestic which = CENTRALIZATION value = 1 }
		command = { type = stability value = -1 }
	}
}

#The Reaction of 1813#
event = {

	id = 3096
	random = no
	country = SPA
	name = "EVENTNAME3096"
	desc = "EVENTHIST3096"
	style = 5

	date = { day = 1 month = january year = 1813 }
	offset = 10
	deathdate = { day = 30 month = december year = 1813 }

	action_a ={		#Introduce a regime of reaction#
		name = "ACTIONNAME3096A"
		command = { type = domestic which = ARISTOCRACY value = 7 }
		command = { type = domestic which = SERFDOM value = 6 }
		command = { type = domestic which = MERCANTILISM value = 3 }
		command = { type = domestic which = INNOVATIVE value = -5 }
		command = { type = domestic which = CENTRALIZATION value = -2 }
		command = { type = stability value = -3 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }

	}

	action_b ={		#Let the liberal constitution stay put#
		name = "ACTIONNAME3096B"
		command = { type = stability value = -5 }
		command = { type = treasury value = -1000 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }

command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }
command = { type = revolt which = -1 }

	}
}

#Olivares#
event = {

	id = 3711
	random = no
	country = SPA
	name = "EVENTNAME3711"
	desc = "EVENTHIST3711"
	style = 3

	date = { day = 2 month = april year = 1621 }

	action_a ={			#An Excellent Minister!#
		name = "ACTIONNAME3711A"
		command = { type = DIP which = 3 value = 240 }
		command = { type = ADM which = 3 value = 240 }
		command = { type = MIL which = 3 value = 240 }
		command = { type = stability value = 2 }
	}
}
#Alberoni#
event = {

	id = 3712
	random = no
	country = SPA
	name = "EVENTNAME3712"
	desc = "EVENTHIST3712"
	style = 3

	date = { day = 4 month = april year = 1641 }

	action_a ={			#An Excellent Minister!#
		name = "ACTIONNAME3712A"
		command = { type = DIP which = 3 value = 240 }
		command = { type = ADM which = 2 value = 240 }
		command = { type = MIL which = 2 value = 240 }
		command = { type = stability value = 2 }
	}
}



# Spain is Unified
event = {

	id = 3848
	
	# Triggered by CAS 3849 or ARG 3850
	
	random = no
	country = SPA
	name = "EVENTNAME3848"
	desc = "EVENTHIST3848"
	style = 2

	action_a = { #The Kingdoms are one!#
		name = "ACTIONNAME3848A"
		command = { type = inherit which = ARG }
		command = { type = inherit which = CAS }
                command = { type = inherit which = LEO }
                command = { type = inherit which = CAT }
    } 
}

#The Knights of St:John of Jerusalem#
event = {

	id = 3156
	trigger = {
		owned = { province = 819 data = -1 }
		NOT = { exists = KNI }
		NOT = { event = 24000 }
		NOT = { event = 24002 }
		}
	random = no
	country = SPA
	name = "EVENTNAME3156"
	desc = "EVENTHIST3156"
	style = 2

	date = { day = 1 month = january year = 1419 }
	offset = 30
	deathdate = { day = 1 month = january year = 1820 }

	action_a ={		#Give Malta to the Knights of St:John#
		name = "ACTIONNAME24000A"
		command = { type = independence which = KNI }
		command = { type = stability value = 1 }
		command = { type = relation which = TUR value = -100 }
		command = { type = relation which = ALD value = -100 }
		command = { type = trigger which = 3540 }
command = { type = trigger which = 94002 }
	}

	action_b ={		#Don't give them anything#
		name = "ACTIONNAME24000B"
		command = { type = relation which = PAP value = -150 }
		command = { type = relation which = TUR value = 100 }
		command = { type = warships which = -1 value = 6 }
	}
}

#####################################
#####  Events by Johnny Canuck  #####
#####################################

#English Privateering#
event = {

	id = 21038
	random = no
	country = SPA
	name = "EVENTNAME21038"
	desc = "EVENTHIST21038"
	style = 2

	action_a ={
		name = "ACTIONNAME21038A"
		command = { type = stability value = -1 }
	}
}

#Drake Strikes the Panamanian Silver Train#
event = {

	id = 21040
	random = no
	country = SPA
	name = "EVENTNAME21040"
	desc = "EVENTHIST21040"
	style = 2

	action_a ={
		name = "ACTIONNAME21040A"
		command = { type = relation which = ENG value = -50 }
		command = { type = casusbelli which = ENG value = 60 }
	}
}

#Drake in the Pacific#
event = {

	id = 21042
	random = no
	country = SPA
	name = "EVENTNAME21042"
	desc = "EVENTHIST21041"
	style = 2

	action_a ={
		name = "ACTIONNAME21040A"
		command = { type = relation which = ENG value = -50 }
		command = { type = casusbelli which = ENG value = 60 }
	}
}

#Drake Strikes in Spain and the Americas#
event = {

	id = 21044
	random = no
	country = SPA
	name = "EVENTNAME21044"
	desc = "EVENTHIST21043"
	style = 2

	action_a ={
		name = "ACTIONNAME21040A"
		command = { type = relation which = ENG value = -50 }
		command = { type = casusbelli which = ENG value = 60 }
	}
}

##English Support for the Dutch and Huguenots Events##
## Created by Johnny Canuck                         ##

#English Aid Arrives in the Dutch Provinces#
event = {

	id = 21046
	random = no
	country = SPA
	name = "EVENTNAME21046"
	desc = "EVENTHIST21046"
	style = 2

	action_a ={
		name = "ACTIONNAME21046A"
		command = { type = revolt which = 339 }
		command = { type = revolt which = 340 }
command = { type = revolt which = 1925 }
		command = { type = revolt which = 1927 }
command = { type = revolt which = 337 }
		command = { type = revolt which = 338 }
command = { type = revolt which = 1997 }
	command = { type = revolt which = 339 }
		command = { type = revolt which = 340 }
command = { type = revolt which = 1925 }
		command = { type = revolt which = 1927 }
command = { type = revolt which = 337 }
		command = { type = revolt which = 338 }
command = { type = revolt which = 1997 }
	command = { type = revolt which = 339 }
		command = { type = revolt which = 340 }
command = { type = revolt which = 1925 }
		command = { type = revolt which = 1927 }
command = { type = revolt which = 337 }
		command = { type = revolt which = 338 }
command = { type = revolt which = 1997 }
		command = { type = revolt which = 340 }

command = { type = revolt which = 1947 }
		command = { type = revolt which = 1903 }
command = { type = revolt which = 1997 }
command = { type = revolt which = 1947 }
		command = { type = revolt which = 1903 }
command = { type = revolt which = 1997 }
		command = { type = relation which = ENG value = -50 }
		command = { type = casusbelli which = ENG value = 120 }
	}
}

#England Again Sides with the Enemies of Spain#
event = {

	id = 21049
	random = no
	country = SPA
	name = "EVENTNAME21049"
	desc = "EVENTHIST21049"
	style = 2

	action_a ={
		name = "ACTIONNAME21049A"
		command = { type = relation which = ENG value = -50 }
		command = { type = casusbelli which = ENG value = 120 }
	}
}

#Spain Tires of England's Interference#
event = {

	id = 21053
	trigger = {
		event = 21040
		event = 21042
		event = 21044
		OR = {
			event = 21046
			event = 21049
			}
		NOT = {
			relation = {
				country = ENG value = 0
				}
			}
		}
	random = no
	country = SPA
	name = "EVENTNAME21053"
	desc = "EVENTHIST21053"
	style = 2

	offset = 100
	deathdate = { day = 1 month = january year = 1603 }

	action_a ={
		name = "ACTIONNAME21053A"
		command = { type = war which = ENG }
		command = { type = stability value = 1 }
		command = { type = warships which = 433 value = 9 }
		command = { type = INF which = 433 value = 16000 }
		command = { type = CAV which = 433 value = 5000 }
		command = { type = manpower value = -30 }
		command = { type = treasury value = -200 }
                command = { type = transports which = 433 value = 6 }
	}

	action_b ={
		name = "ACTIONNAME21053B"
		command = { type = stability value = -1 }
	}
}

#SPANISH EVENTS#
#Carlo Duke of Nevers succeeds to the Mantuan throne#	
event = {

	id = 17331		#Triggered by 17327#
	random = no
	country = SPA
	name = "EVENTNAME17337"
	desc = "EVENTHIST17331"
	style = 3

	action_a ={				#No it ours#
		name = "ACTIONNAME17337A"
		command = { type = casusbelli which = FRA value = 36 }
		command = { type = casusbelli which = MAN value = 36 }
		command = { type = relation which = MAN value = -150 }
		command = { type = relation which = FRA value = -150 }
		command = { type = relation which = HAB value = 50 }
		command = { type = relation which = SAV value = 100 }
		command = { type = alliance which = SAV }
		command = { type = stability value = 1 }
	}

	action_b ={				#We have more pressing matters#
		name = "ACTIONNAME17337B"
		command = { type = relation which = MAN value = 150 }
		command = { type = relation which = FRA value = 150 }
		command = { type = relation which = HAB value = 100 }
		command = { type = relation which = SAV value = -50 }
		command = { type = stability value = -2 }
	}
}

#Duke of Guastalla succedes to the Mantuan throne#
event = {

	id = 17332		#Triggered by 17327#
	random = no
	country = SPA
	name = "EVENTNAME17338"
	desc = "EVENTHIST17332"
	style = 3

	action_a ={				#Splendid#
		name = "ACTIONNAME17338A"
		command = { type = vassal which = MAN }
		command = { type = alliance which = MAN }
		command = { type = relation which = MAN value = 200 }
		command = { type = relation which = FRA value = -150 }
		command = { type = relation which = HAB value = 50 }
		command = { type = relation which = SAV value = -75 }
		command = { type = stability value = 1 }
	}
}

#Columbus#
event = {
	id = 24005
	random = no
	country = SPA
	name = "EVENTNAME24005"
	desc = "EVENTHIST24005"
	style = 1

	date = { day = 1 month = november year = 1486 }
	offset = 50
	deathdate = { day = 1 month = april year = 1487 }

	action_a ={	
		name = "ACTIONNAME24005A"
		command = { type = land  value = 100 }
		command = { type = domestic which = land value = 1 }
		command = { type = domestic which = offensive value = 1 }
	}
	action_b ={	
		name = "ACTIONNAME24005B"
		command = { type = naval  value = 100 }
		command = { type = domestic which = land value = -1 }
		command = { type = leader which = 09740 } 
		command = { type = warships which = -1 value = 3 }
                command = { type = galleys which = -1 value = 6 }
		command = { type = treasury value = -200 }
		command = { type = sleepevent which = 24006 }
	}
}
#Columbus#
event = {
	id = 24006
	random = no
	country = SPA
	name = "EVENTNAME24006"
	desc = "EVENTHIST24006"
	style = 1

	date = { day = 1 month = november year = 1491 }
	offset = 50
	deathdate = { day = 1 month = april year = 1493 }

	action_a ={	
		name = "ACTIONNAME24006A"
		command = { type = domestic which = land value = -1 }
		command = { type = leader which = 09740 } 
		command = { type = warships which = -1 value = 3 }
               command = { type = transports which = -1 value = 2 }
		command = { type = treasury value = -200 }
	}
	action_b ={	
		name = "ACTIONNAME24006B"
		command = { type = land  value = 100 }
		command = { type = domestic which = land value = 1 }
		}
}
#Vespucci#
event = {
	id = 24007
	random = no
	country = SPA
	name = "EVENTNAME24007"
	desc = "EVENTHIST24007"
	style = 1

	date = { day = 1 month = april year = 1497 }
	offset = 50
	deathdate = { day = 1 month = april year = 1498 }

	action_a ={	
		name = "ACTIONNAME24007A"
		command = { type = leader which = 09745 } 
		command = { type = warships which = -1 value = 2 }
		command = { type = treasury value = -25 }
	}
	action_b ={	
		name = "ACTIONNAME24007B"
		command = { type = land  value = 100 }
		}
}

### Events by Chanda "Phillip V" Choun ### 
#Cambodia asks for aid# 
event = { 
	id = 65149 
	random = no 
	country = SPA 
	name = "EVENTNAME65149" 
	desc = "EVENTHIST65149"
	style = 2 
	action_a = { 
		name = "ACTIONNAME65149A" 
		command = { type = war which = AYU } 
		command = { type = vassal which = CAM } 
		command = { type = trigger which = 65133 } 
		} 
	action_b = { 
		name = "ACTIONNAME65149B" 
		command = { type = trigger which = 65134 } 
		}
}

#Lovek is captured# 
event = { 
	id = 65150 
	random = no 
	country = SPA 
	name = "EVENTNAME65150" 
	desc = "EVENTHIST65150" 
	style = 3 
	action_a = { 
		name = "ACTIONNAME65150A" 
		command = { type = breakvassal which = CAM } 
		command = { type = trigger which = 65143 } 
		}
}

event = {
	id = 7124
	trigger = { exists = GRA
			NOT = { event = 7120 }
}
	random = no
	country = SPA
	name = "EVENTNAME7120"
	desc = "EVENTHIST7120"
	style = 1
	date = { day = 27 month = december year = 1481 }
	action_a = {
		name = "ACTIONNAME7120A"
		command = { type = inf which = -2 value = 16000 }
		command = { type = relation which = GRA value = -200 }
		command = { type = casusbelli which = GRA value = 24 }
		command = { type = stability value = 1 }  
		command = { type = addcore which = 444 }
		command = { type = addcore which = 1413 }
	}
}

event = {
	id = 7125
	trigger = { 
                	exists = GRA
                  }
	random = no
	country = SPA
	name = "EVENTNAME7125"
	desc = "EVENTHIST7125"
	style = 1
	date = { day = 1 month = july year = 1491 }
	action_a = {
		name = "ACTIONNAME7125A"
		command = { type = inf which = -2 value = 16000 }
		command = { type = relation which = GRA value = -200 }
		command = { type = war which = GRA } 
		command = { type = stability value = 2 }  
	}
}

#IB follow up to Iberian wedding to force ARG back into vassalage
event = {
	id = 7127
	trigger = {
		exists = ARG
		event = 7126 #chose to vassalize Aragon in 1477#
	NOT = { vassal = { country = ARG country = SPA } }
		NOT = { vassal = { country = SPA country = ARG } }
		NOT = { war = { country = ARG country = SPA } }
	}
	random = no
	country = SPA
	name = "EVENTNAME7127"
	desc = "EVENTHIST7127"
	style = 1

	date = { day = 26 month = november year = 1504 }
	offset = 30
	deathdate = { day = 30 month = december year = 1505 }

	action_a ={			
		name = "ACTIONNAME5251A"
		command = { type = dynastic which = ARG }
		command = { type = alliance which = ARG }
		command = { type = vassal which = ARG }
	}
}

#Siena sequence of events#
event = {
	id = 17351 #triggered by 17350 Fall of Petrucci PIS
	random = no
	country = SPA
	name = "EVENTNAME17354"
	desc = "EVENTHIST17351"
	style = 1
	action_a ={
		name = "ACTIONNAME5251A"
		command = { type = vassal  which = PIS }
		command = { type = relation   which = PAP value = -20 }
		command = { type = alliance   which = PIS }
		}
}

event = {
	id = 17356 #triggered by 17355 Burnt Siena PIS
	random = no
	country = SPA
	name = "EVENTNAME17359"
	desc = "EVENTHIST17356"
	style = 1
	action_a ={
		name = "ACTIONNAME17359A"
		command = { type = casusbelli which = PIS value = 12 }
		command = { type = relation which = PIS value = -400 }
		command = { type = relation which = TOS value = 200 }
		command = { type = trigger which = 17357 }  #TOS Revolt in Siena          
          	}
	action_b ={
		name = "ACTIONNAME17359B"
		command = { type = casusbelli which = PIS value = 12 }
		command = { type = relation which = PIS value = -400 }          
          	}
}

# Modified by Isaac Brock
#The League of Cambrai#
event = {

	id = 17020
	trigger = { 
		event = 17017 #VEN seeing a chance
		exists = VEN 
		NOT = { exists = ARG}
	}
	random = no
	country = SPA
	name = "EVENTNAME3107"
	desc = "EVENTHIST17020"
	style = 2

	date = { day = 1 month = october year = 1503 }
	offset = 2070
	deathdate = { day = 1 month = april year = 1509 }

	action_a ={
		name = "ACTIONNAME3107A"	#Express Support#
		command = { type = casusbelli which = VEN value = 72 }
		command = { type = relation which = VEN value = -150 }
		command = { type = relation which = HAB value = 150 }
		command = { type = relation which = PAP value = 150 }
		command = { type = relation which = TOS value = 150 }
		command = { type = relation which = FRA value = 150 }
	}

	action_b ={
		name = "ACTIONNAME3107B"	#Ignore#
		command = { type = relation which = VEN value = 50 }
		command = { type = relation which = HAB value = -50 }
		command = { type = relation which = PAP value = -50 }
		command = { type = relation which = TOS value = -50 }
		command = { type = relation which = FRA value = -50 }
	}

	action_c ={
		name = "ACTIONNAME3107C"	#Express Hostility#
		command = { type = relation which = VEN value = 150 }
		command = { type = relation which = HAB value = -150 }
		command = { type = relation which = PAP value = -150 }
		command = { type = relation which = TOS value = -150 }
		command = { type = relation which = FRA value = -150 }
	}

}

#Holy League of 1510 Spanish Version
event = {

	id = 17027
	trigger = { 
		event = 17024
		NOT = { exists = ARG }
		NOT = { event = 17026 }
	}
	random = no
	country = SPA
	name = "EVENTNAME17024"
	desc = "EVENTHIST17025"
	style = 2

	date = { day = 1 month = july year = 1510 }
	offset = 500
	deathdate = { day = 1 month = april year = 1512 }

	action_a ={
		name = "ACTIONNAME17024A"	#Express Support#
		command = { type = casusbelli which = FRA value = 36 }
		command = { type = relation which = FRA value = -150 }
		command = { type = relation which = VEN value = 150 }
		command = { type = relation which = ENG value = 150 }
		command = { type = relation which = HAB value = 150 }
		command = { type = relation which = PAP value = 150 }
	}

	action_b ={
		name = "ACTIONNAME17024B"	#Ignore#
		command = { type = relation which = FRA value = 50 }
		command = { type = relation which = ENG value = -50 }
		command = { type = relation which = HAB value = -50 }
		command = { type = relation which = VEN value = -50 }
		command = { type = relation which = PAP value = -50 }
	}

	action_c ={
		name = "ACTIONNAME17024C"	#Express Hostility#
		command = { type = relation which = FRA value = 150 }
		command = { type = relation which = ENG value = -150 }
		command = { type = relation which = VEN value = -150 }
		command = { type = relation which = HAB value = -150 }
		command = { type = relation which = PAP value = -150 }
	}
}

### Charles V's Mercenary Army Sacks Rome (Papal States Event) ###  Isaac Brock
event = {  
	id = 17407
	random = no
	country = SPA
	name = "EVENTNAME17406"
	desc = "EVENTHIST17408"
	style = 2
	action_a = {
		name = "ACTIONNAME17382A"
		command = { type = relation which = ENG value = -100}
		command = { type = relation which = FRA value = -100}
		command = { type = DIP   which = -2 value =12 }
		command = { type = ADM   which = -2 value =12 }
		command = { type = treasury   value = 50 }# no need to pay their back pay now!
		}
}

### French Meddling in Italy (Spanish Event) ###

event = {
	id = 12026
	trigger = {
		exists = FRA
		exists = HAB
			OR = { 
				event = 12022
#				event = 12024 #French intervention in Milan
				event = 17386 #France pressed claims in Milan
				}
}
	random = no
	country = SPA
	name = "EVENTNAME12026"
	desc = "EVENTHIST12026"
	style = 2
	date = { day = 1 month = january year = 1521 }
	offset = 90
	action_a = {
		name = "ACTIONNAME12026A"
		command = { type = casusbelli which = FRA value = 24}
		command = { type = alliance which = HAB}
		command = { type = relation which = FRA value = -200}
		}
	action_b = {
		name = "ACTIONNAME12026B"
		command = { type = stability value = 1}
		command = { type = sleepevent which = 12027}
		command = { type = sleepevent which = 12028}
		}
}


### Anti-French Coalition (Spanish Event) ###

event = {
	id = 12143
	trigger = {	
			event = 12022
			NOT = { exists = ARG }
 }
	random = no
	country = SPA
	name = "EVENTNAME12143"
	desc = "EVENTHIST12143"
	style = 1
	date = { day = 1 month = january year = 1496 }
	offset = 30
	action_a = {
		name = "ACTIONNAME12143A"
		command = { type = alliance which = HAB}
		command = { type = alliance which = VEN}
		command = { type = casusbelli which = FRA value = 120}
		}
	action_b = {
		name = "ACTIONNAME12143B"
		command = { type = stability value = -1}
		}
}

### French Encirclement by the Habsburgs ###  #SPA Event#

event = {
	id = 12067
	random = no
	country = SPA
	name = "EVENTNAME12062"
	desc = "EVENTHIST12062"
	style = 3
	action_a = {
		name = "ACTIONNAME12066A"
		command = { type = casusbelli which = FRA value = 48}
		command = { type = relation which = FRA value = -100}
		}
	action_b = {
		name = "ACTIONNAME12066B"
		command = { type = relation which = FRA value = 10}
		}
}

### Sabre Rattling ## SPA Event#

event = {
	id = 12116
	random = no
	country = SPA
	name = "EVENTNAME12114"
	desc = "EVENTHIST12114"
	style = 4
	action_a = {
		name = "ACTIONNAME12114A"
		command = { type = casusbelli which = FRA value = 80 } 
		}
	action_b = {
		name = "ACTIONNAME12114B"
		command = { type = stability value = -1 } 
		}
}


### War Again ## SPA Event#

event = {
	id = 12128
	random = no
	country = SPA
	name = "EVENTNAME12125"
	desc = "EVENTHIST12128"
	style = 5
	action_a = {
		name = "ACTIONNAME12126A"
		command = { type = casusbelli which = FRA value = 216 } 
		}
	action_b = {
		name = "ACTIONNAME12126B"
		command = { type = stability value = -1 } 
		}
}


# The treaty of Barcelona (for SPA)
event = {
	id = 7137
	trigger = {
NOT = {exists = ARG}
   	
          }
	random = no
	country = SPA
	name = "EVENTNAME7136"
	desc = "EVENTHIST7136"
	style = 1
	action_a = {
		name = "ACTIONNAME7136A"
		command = {type = treasury value = -300}
		command = {type = stability value = 1}
		command = {type = trigger which = 12147 }
		}
	action_b = {
		name = "ACTIONNAME7136B"
		command = {type = stability value = -2}
		}
}

# France refuses (for SPA)
event = {
	id = 7139
	random = no
	country = SPA
	name = "EVENTNAME7138"
	desc = "EVENTHIST7138"
	style = 1
	action_a = {
		name = "ACTIONNAME7138A" 
		command = {type = casusbelli which = FRA value = 36} 
		} 
}

# Joanot Martorell and the Tirant lo Blanc (SPA owns Valиncia)
event = {
	id = 7147 
	trigger = {owned = {province = 437 data = -1}
		NOT = { event = 7146 }
		NOT = { event = 7145 }
}
	random = no
	country = SPA
	name = "EVENTNAME7145"
	desc = "EVENTHIST7145"
	style = 1
	date = { day = 1 month = february year = 1490}
	offset = 120
	action_a = {
		name = "ACTIONNAME7145A"
		command = {type = stability value = 1}
		command = {type = infra value = 50}
		}
}

event = {
	id = 7157
	trigger = {
		exists = TUR
		exists = TRI
		atwar = no
		NOT = { event = 7156 }
		countrysize = 8
		NOT = { vassal = { country = SPA country = TRI } }
		NOT = { alliance = { country = SPA country = TRI } }
	}
	random = no
	country = SPA
	name = "EVENTNAME7156"
	desc = "EVENTHIST7157"
	style = 1
	date = { day = 1 month = november year = 1509 }
	offset = 30
	deathdate = { day = 1 month = january year = 1528 }
	action_a = {
		name = "ACTIONNAME7156A"
		command = { type = relation which = TRI value = -200 }
		command = { type = war which = TRI }
		}
	action_b = {
		name = "ACTIONNAME7156B"
		command = { type = relation which = TRI value = -50 }
		}
}

event = {
	id = 7159
	trigger = {
		owned = { province = 740 data = -1 }
		control = { province = 740 data = -1 }
		exists = KNI
	}
	random = no
	country = SPA
	name = "EVENTNAME7158"
	desc = "EVENTHIST7159"
	style = 1
	date = { day = 1 month = january year = 1527 }
	offset = 30
	deathdate = { day = 1 month = january year = 1535 }
	action_a = {
		name = "ACTIONNAME7158A"
		command = { type = secedeprovince which = KNI value = 740 }
		command = { type = relation which = KNI value = -30 }
		command = { type = trigger which = 24053 }
		}
	action_b = {
		name = "ACTIONNAME7158B"
		command = { type = secedeprovince which = KNI value = 740 }
		command = { type = trigger which = 24053 }
		}
	action_c = {
		name = "ACTIONNAME7158C"
        	command = { type = treasury value = -250 }
		}
}


### The Novatores
### By mfigueras
event = {
	id = 5252
	trigger = { stability = 0
		domestic = { type = innovative value = 3 } }
	random = no
	country = SPA
	name = "EVENTNAME5252"
	desc = "EVENTHIST5252"
	style = 3
	date = {day = 1 month = june year = 1680}
	offset = 720
	deathdate = {day = 1 month = august year = 1685}
	action_a = {
		name = "ACTIONNAME5252A"
		command = { type = infra value = 50 }
		command = { type = sleepevent which = 5253 }
		}
	action_b = {
		name = "ACTIONNAME5252B"
		command = { type = cash value = -75 }
		command = { type = infra value = 100 }
		}
}

### Consequences of the royal-funded novatores

event = {
	id = 5253
	trigger = { stability = 0
		domestic = { type = innovative value = 3 } 
		event = 5252 }
	random = no
	country = SPA
	name = "EVENTNAME5253"
	desc = "EVENTHIST5253"
	style = 4
	date = {day = 1 month = june year = 1710}
	offset = 720
	deathdate = {day = 1 month = august year = 1715}
	action_a = {
		name = "ACTIONNAME5253A"
		command = {type = infra value = 150}
		command = {type = ADM which = 2 value = 12}
		command = {type = domestic which = innovative value = 1}
		}
}


### The royal expedition for the smallpox vaccination

event = {
	id = 5254
	trigger = { event = 5060 }  ## Jenner
	random = no
	country = SPA
	name = "EVENTNAME5254"
	desc = "EVENTHIST5254"
	style = 5
	date = {day = 1 month = april year = 1803}
	offset = 60
	deathdate = {day = 30 month = september year = 1807}
	action_a = {
		name = ACTIONNAME5254A
		command = {type = cash value = -100}
		command = {type = infra value = 150}
		command = {type = population which = 27 value = 1000}
		command = {type = population which = 29 value = 800}
		command = {type = population which = 33 value = 1000}
		command = {type = population which = 137 value = 800}
		command = {type = population which = 139 value = 1000}
		command = {type = population which = 158 value = 1000}
		command = {type = population which = 160 value = 500}
		command = {type = population which = 163 value = 1000}
		command = {type = population which = 169 value = 1000}
		}
	action_b = {
		name = "ACTIONNAME5254B"
		command = {type = ADM which = -2 value = 15}
		command = {type = population which = 29 value = -1000}
		command = {type = population which = 33 value = -800}
		command = {type = population which = 139 value = -500}
		command = {type = population which = 158 value = -200}
		command = {type = population which = 169 value = -1000}
		}
}

#National revolt in Portugal by Alexsandr Rau#

event = {
id = 320101	
trigger = { 

          OR = { 
                owned = { province = 441 data = -1 } 
		owned = { province = 1918 data = -1 } 
		owned = { province = 434 data = -1 } 
		owned = { province = 442 data = -1 }
                owned = { province = 1409 data = -1 }
owned = { province = 1996 data = -1 }
owned = { province = 1014 data = -1 }
            }
                 NOT = { exists = POR }

    }				
	random = no
	country = SPA
	name = "Независимость Португалии"
	desc = "Португальцы устали от участия в войнах испанских королей, им надоело быть слугами, они вспомнили о было величии, и требуют независимости!"
	style = 3
        date = { day = 1 month = may year = 1635 }
	offset = 30
	deathdate = { day = 25 month = december year = 1636 }

	action_a ={			#Put it down!#
		name = "ACTIONNAME3168A"
		command = { type = independence which = POR }
                command = { type = breakvassal which = POR }
		command = { type = relation which = POR value = -200 }
		command = { type = INF which = 435 value = 10000 }
                command = { type = stability value = -3 }
                command = { type = treasury value = -400 }
                command = { type = remove_countryculture which = maltese }

	}

	action_b ={			#Appease them!#
		name = "ACTIONNAME3168B"
		command = { type = treasury value = -800 }
		command = { type = stability value = -1 }
		command = { type = province_revoltrisk which = 441 value = 20 }
		command = { type = province_revoltrisk which = 1918 value = 20 }
		command = { type = province_revoltrisk which = 434 value = 20 }
                command = { type = province_revoltrisk which = 442 value = 20 }
command = { type = province_revoltrisk which = 1409 value = 20 }
command = { type = province_revoltrisk which = 1996 value = 20 }
command = { type = province_revoltrisk which = 1014 value = 20 }
                command = { type = revolt which = 441 }
 command = { type = revolt which = 1409 }
command = { type = revolt which = 1409 }
command = { type = revolt which = 1409 }
                command = { type = revolt which = 1918 }
                command = { type = revolt which = 434 }
                command = { type = revolt which = 442 }
                command = { type = revolt which = 441 }
                command = { type = revolt which = 1918 }
                command = { type = revolt which = 434 }
                command = { type = revolt which = 442 }
                command = { type = revolt which = 441 }
                command = { type = revolt which = 1918 }
                command = { type = revolt which = 434 }
                command = { type = revolt which = 442 }
command = { type = revolt which = 1996 }
command = { type = revolt which = 1996 }
command = { type = revolt which = 1996 }
command = { type = revolt which = 1996 }
                                command = { type = remove_countryculture which = maltese }

	}
}

event = {
id = 320102	
trigger = { 

event = 320101

          OR = { 
               owned = { province = 441 data = -1 } 
		owned = { province = 1918 data = -1 } 
		owned = { province = 434 data = -1 } 
		owned = { province = 442 data = -1 }
                owned = { province = 1409 data = -1 }
owned = { province = 1996 data = -1 }
owned = { province = 1014 data = -1 }
            }
                 NOT = { exists = POR }

    }				
	random = no
	country = SPA
	name = "Конец войны за независимость Поругалии"
	desc = "Вот уже больше десяти лет, мы воюем с португальскими инсургентами, котрым помогает Фрнация и Англия, страна устала, армии необходима передышка. Португальцы предлогают нам переговоры. Пришло время решить - нужна ли нам Португалия? "
	style = 3
        date = { day = 1 month = january year = 1646 }
	offset = 30
	deathdate = { day = 25 month = december year = 1647 }

	action_a ={			
		name = "Мы не можем удержать Португалию"
		command = { type = independence which = POR }
                command = { type = breakvassal which = POR }
		command = { type = relation which = POR value = 200 }
                command = { type = stability value = -2 }

	}

	action_b ={			#Appease them!#
		name = "Примириться с Португальской знатью"
		command = { type = treasury value = -800 }
		command = { type = stability value = 2 }
                command = { type = add_countryculture which = maltese }
command = { type = province_revoltrisk which = 1409 value = -20 }
command = { type = province_revoltrisk which = 1014 value = -20 }
		command = { type = province_revoltrisk which = 441 value = -20 }
		command = { type = province_revoltrisk which = 1918 value = -20 }
		command = { type = province_revoltrisk which = 434 value = -20 }
                command = { type = province_revoltrisk which = 442 value = -20 }
command = { type = province_revoltrisk which = 1996 value = -20 }
                command = { type = domestic which = ARISTOCRACY value = 2 }
		command = { type = domestic which = CENTRALIZATION value = -4 }
                command = { type = domestic which = serfdom value = 2 }
                command = { type = domestic which = innovative value = -1 }

	}
}


#National revolt in Portugal#
event = {

	id = 3168
trigger = { 

event = 320102
                exists = POR 

    }					
	random = no
	country = SPA
	name = "EVENTNAME3168"
	desc = "EVENTHIST3168"
	style = 3
        date = { day = 1 month = january year = 1637 }
	offset = 41
	deathdate = { day = 1 month = january year = 1648 }

	action_a ={			
		name = "Мы упустили Португалию...."

command = { type = breakvassal which = POR }
command = { type = breakvassal which = OMA }
command = { type = breakvassal which = U05 }
command = { type = breakvassal which = KON }
command = { type = breakvassal which = MLC }
command = { type = breakvassal which = ZAN }
		command = { type = relation which = POR value = -200 }
command = { type = secedeprovince which = POR value = 441 }
command = { type = secedeprovince which = POR value = 1409 }
command = { type = secedeprovince which = POR value = 1996 }
command = { type = secedeprovince which = POR value = 442 }
command = { type = secedeprovince which = POR value = 434 }
command = { type = secedeprovince which = POR value = 1918 }
command = { type = secedeprovince which = POR value = 1014 }
command = { type = secedeprovince which = POR value = 823 }
command = { type = secedeprovince which = POR value = 1728 }
command = { type = secedeprovince which = POR value = 799 }
command = { type = secedeprovince which = POR value = 800 }
command = { type = secedeprovince which = POR value = 826 }
command = { type = secedeprovince which = POR value = 770 }
command = { type = secedeprovince which = POR value = 818 }
command = { type = secedeprovince which = POR value = 765 }
command = { type = secedeprovince which = POR value = 756 }
command = { type = secedeprovince which = POR value = 677 }
command = { type = secedeprovince which = POR value = 788 }
command = { type = secedeprovince which = POR value = 790 }
command = { type = secedeprovince which = POR value = 785 }
command = { type = secedeprovince which = POR value = 771 }
command = { type = secedeprovince which = POR value = 772 }
command = { type = secedeprovince which = POR value = 549 }
command = { type = secedeprovince which = POR value = 203 }
command = { type = secedeprovince which = POR value = 1781 }
command = { type = secedeprovince which = POR value = 1748 }
command = { type = secedeprovince which = POR value = 712 }
command = { type = secedeprovince which = POR value = 711 }
command = { type = secedeprovince which = POR value = 1747 }
command = { type = secedeprovince which = POR value = 548 }
command = { type = secedeprovince which = POR value = 1965 }
command = { type = secedeprovince which = POR value = 1807 }
command = { type = secedeprovince which = POR value = 202 }
command = { type = secedeprovince which = POR value = 204 }
command = { type = secedeprovince which = POR value = 205 }
command = { type = secedeprovince which = POR value = 207 }
command = { type = secedeprovince which = POR value = 208 }
command = { type = secedeprovince which = POR value = 209 }
command = { type = secedeprovince which = POR value = 210 }
command = { type = secedeprovince which = POR value = 211 }
command = { type = secedeprovince which = POR value = 197 }
command = { type = secedeprovince which = POR value = 576 }
command = { type = secedeprovince which = POR value = 577 }
command = { type = secedeprovince which = POR value = 1967 }
command = { type = secedeprovince which = POR value = 199 }
command = { type = secedeprovince which = POR value = 200 }
command = { type = secedeprovince which = POR value = 201 }
command = { type = secedeprovince which = POR value = 1843 }
command = { type = secedeprovince which = POR value = 1844 }
command = { type = secedeprovince which = POR value = 1845 }
command = { type = secedeprovince which = POR value = 1842 }
command = { type = secedeprovince which = POR value = 1840 }
command = { type = secedeprovince which = POR value = 204 }
command = { type = secedeprovince which = POR value = 198 }
command = { type = secedeprovince which = POR value = 1864 }
command = { type = secedeprovince which = POR value = 1866 }
command = { type = secedeprovince which = POR value = 212 }
command = { type = secedeprovince which = POR value = 213 }
command = { type = secedeprovince which = POR value = 214 }
command = { type = secedeprovince which = POR value = 215 }
command = { type = secedeprovince which = POR value = 216 }
command = { type = secedeprovince which = POR value = 678 }
command = { type = secedeprovince which = POR value = 710 }
command = { type = secedeprovince which = POR value = 1738 }
command = { type = secedeprovince which = POR value = 1735 }
command = { type = secedeprovince which = POR value = 1736 }
command = { type = secedeprovince which = POR value = 796 }
command = { type = secedeprovince which = POR value = 797 }
command = { type = secedeprovince which = POR value = 798 }
command = { type = secedeprovince which = POR value = 1705 }
command = { type = secedeprovince which = POR value = 1706 }
command = { type = secedeprovince which = POR value = 802 }
command = { type = secedeprovince which = POR value = 795 }
command = { type = secedeprovince which = POR value = 1498 }
command = { type = secedeprovince which = POR value = 791 }
command = { type = secedeprovince which = POR value = 732 }
command = { type = secedeprovince which = POR value = 504 }
command = { type = secedeprovince which = POR value = 505 }
command = { type = secedeprovince which = POR value = 506 }
command = { type = secedeprovince which = POR value = 509 }
command = { type = secedeprovince which = POR value = 1802 }
command = { type = secedeprovince which = POR value = 706 }
command = { type = secedeprovince which = POR value = 713 }
command = { type = secedeprovince which = POR value = 714 }
command = { type = secedeprovince which = POR value = 715 }
command = { type = secedeprovince which = POR value = 1762 }
command = { type = secedeprovince which = POR value = 1749 }
command = { type = secedeprovince which = POR value = 1737 }
command = { type = secedeprovince which = POR value = 1754 }
command = { type = secedeprovince which = POR value = 1740 }
command = { type = secedeprovince which = POR value = 1681 }
command = { type = stability value = -1 }
command = { type = trigger which = 370102 }
	}
	
}




#The Restoration of the French Monarchy#
event = {

	id = 3177
	trigger = {
		monarch = 04018#Napoleon#
		control = {
			province = 385
			data = -1
		}
	}
	random = no
	country = SPA
	name = "EVENTNAME3177"
	desc = "EVENTHIST3177"
	style = 4

	date = { day = 1 month = january year = 1809 }
	offset = 10
	deathdate = { day = 1 month = january year = 1821 }

	action_a ={				#The Bourbons are reinstalled#
		name = "ACTIONNAME3177A"
		command = { type = vp value = 500 }
		command = { type = treasury value = 500 }
		command = { type = relation which = FRA value = 200 }
		command = { type = stability value = 3 }
		command = { type = trigger which = 3786 }
	}
}

#########################
####  Aragon Events  ####
####    by Crook     ####
#########################

#The Knights of St:John of Jerusalem#
event = {

	id = 24000
	trigger = {
		owned = { province = 819 data = -1 }
		NOT = { exists = KNI }
		NOT = { event = 3156 }
		NOT = { event = 24002 }
		}
	random = no
	country = ARG
	name = "EVENTNAME3156"
	desc = "EVENTHIST3156"
	style = 2

	date = { day = 1 month = january year = 1419 }
	offset = 30
	deathdate = { day = 1 month = january year = 1821 }

	action_a ={		#Give Malta to the Knights of St:John#
		name = "ACTIONNAME24000A"
		command = { type = independence which = KNI }
		command = { type = stability value = 1 }
		command = { type = relation which = TUR value = -100 }
		command = { type = relation which = ALD value = -100 }
		command = { type = trigger which = 24001 }
command = { type = trigger which = 94002 }
	}

	action_b ={		#Don't give them anything#
		name = "ACTIONNAME24000B"
		command = { type = relation which = PAP value = -150 }
		command = { type = relation which = TUR value = 100 }
		command = { type = galleys which = -1 value = 10 }
	}
}

#The Knights of St:John of Jerusalem#
event = {

	id = 24002
	trigger = {
		owned = { province = 819 data = -1 }
		NOT = { exists = KNI }
		NOT = { event = 3156 }
		NOT = { event = 24000 }
		}
	random = no
	country = CAS
	name = "EVENTNAME3156"
	desc = "EVENTHIST3156"
	style = 2

	date = { day = 1 month = january year = 1419 }
	offset = 30
	deathdate = { day = 1 month = january year = 1821 }

	action_a ={		#Give Malta to the Knights of St:John#
		name = "ACTIONNAME24002A"
		command = { type = independence which = KNI }
		command = { type = stability value = 1 }
		command = { type = relation which = TUR value = -100 }
		command = { type = relation which = ALD value = -100 }
		command = { type = trigger which = 24003 }
command = { type = trigger which = 94002 }
	}

	action_b ={		#Don't give them anything#
		name = "ACTIONNAME24002B"
		command = { type = relation which = PAP value = -150 }
		command = { type = relation which = TUR value = 100 }
		command = { type = galleys which = -1 value = 10 }
	}
}

event = {
	id = 94002
	random = no
	country = KNI
	name = "Мы на Мальте!"
	desc = ""

	action_a = {
		name = "Испания Едина!" 
                command = { type = galleys which = -1 value = 26 }
                command = { type = treasury value = 120 }
	}
}


#####Spain Flavor Events#######
#By Henrik 'Doomdark' Fеhraeus#
###############################

#Cervantes publishes 'Don Quixote'#
event = {
	id = 5250
	random = no
	country = SPA
	name = "EVENTNAME5250"
	desc = "EVENTHIST5250"
	style = 3
	date = { day = 1 month = june year = 1605 }

	action_a ={				#Ok#
		name = "ACTIONNAME5250A"
		command = { type = stability value = 1 }
	}
}


# Ids free to 5279

######Miscellaneous EEP events##################

#The Genoese Alliance
event = { 
    id = 285000
    trigger = { event = 174008 } #GEN 174008 Rise of Andrea Doria
    random = no
    country = SPA
    name = "Генуэзский союз"
    desc = "В 1528 году в результате переворота, власть в Генуе перешла в руки Андреа Дориа. Он просил об испанском покровительстве, которое предоставил ему Карл I. На протяжение более чем 150 лет Генуя была одним из самых верных союзников Испании, предоставляя доступ к гавани, позволявшей испанской армии без труда добираться до северной Италии."
    style = 2

    date = { day = 1 month = january year = 1528 }
    offset = 60
    deathdate = { day = 30 month = december year = 1537 }

    action_a = {
        name = "Отлично!"
        command = { type = alliance which = GEN }
        command = { type = relation which = GEN value = 75 }
        command = { type = vassal which = GEN }
    }
}

event = { 
    id = 285002 
    trigger = { 
        AND = { 
            owned = { province = 393 data = -1 } 
            } 
        } 
    random = no 
    country = SPA 
    name = "Восстание под предводительством Мазаньелло" 
    desc = "Неаполитанский революционер, чье настоящее имя было Томмазо Аньелло. Будучи рыбаком, он возглавил восстание низших классов, обремененных высокими налогами, против испанских правителей Неаполя. Беспорядки начались в 1647 году и вскоре приобрели настолько серьезный характер, что испанский вице-король принял условия Мазаньелло, пообещал провести требуемые реформы, и официально признал его генерал-капитаном. В скором времени, потеряв голову от неожиданного успеха, Мазаньелло был убит либо агентами испанского вице-короля, либо своими собственными разочарованными сторонниками. Восстание вскоре было подавлено." 
    style = 3 

    date = { day = 1 month = may year = 1647 } 
    offset = 60 
    deathdate = { day = 1 month = may year = 1649 } 

    action_a = { 
        name = "Провести реформы и убить этого наглеца!" 
        command = { type = stability value = -1 } 
        command = { type = revolt which = 393 } 
                command = { type = revolt which = 394 } 
 command = { type = revolt which = 934 } 
                command = { type = revolt which = 1990 } 
command = { type = revolt which = 1407 } 
    command = { type = revolt which = 393 } 
                command = { type = revolt which = 394 } 
 command = { type = revolt which = 934 } 
                command = { type = revolt which = 1990 } 
command = { type = revolt which = 1407 } 
        command = { type = domestic which = serfdom value = -1 } 
    } 
    action_b = { 
        name = "Реформировать и сделать его генерал-капитаном!" 
        command = { type = stability value = -1 } 
        command = { type = revolt which = 393 } 
                command = { type = revolt which = 393 } 
        command = { type = treasury value = -25 } 
        command = { type = domestic which = aristocracy value = 1 } 
    } 
    action_c = { 
        name = "Дать Неаполю независимость" 
        command = { type = stability value = -1 } 
        command = { type = independence which = NAP } 
        command = { type = trigger which = 239005 } 
        command = { type = secedeprovince which = NAP value = 393 } 
        command = { type = secedeprovince which = NAP value = 394 } 
command = { type = secedeprovince which = NAP value = 1407 } 
                command = { type = secedeprovince which = NAP value = 934 }
command = { type = secedeprovince which = NAP value = 1990 }
    } 
    action_d = { 
        name = "Ничего не делать" 
          command = { type = revolt which = 393 } 
                command = { type = revolt which = 394 } 
 command = { type = revolt which = 934 } 
                command = { type = revolt which = 1990 } 
command = { type = revolt which = 1407 } 
    command = { type = revolt which = 393 } 
                command = { type = revolt which = 394 } 
 command = { type = revolt which = 934 } 
                command = { type = revolt which = 1990 } 
command = { type = revolt which = 1407 } 
     command = { type = revolt which = 393 } 
                command = { type = revolt which = 394 } 
 command = { type = revolt which = 934 } 
                command = { type = revolt which = 1990 } 
command = { type = revolt which = 1407 } 
    command = { type = revolt which = 393 } 
                command = { type = revolt which = 394 } 
 command = { type = revolt which = 934 } 
                command = { type = revolt which = 1990 } 
command = { type = revolt which = 1407 } 
        command = { type = revoltrisk which = 36 value = 2 } 
        command = { type = domestic which = innovative value = -1 } 
    } 
} 



### Parma's Intervention in France###
## by Count Six ##

event = {
id = 285202
trigger = { event = 172002 }
random = no
country = SPA
name = "Интервенция Пармы во Францию"
desc = "EVENTHIST12049"  
style = 2

action_a = { 
name = "Нанести поражение еретикам!"
command = { type = casusbelli which = FRA value = 60 }
command = { type = relation which = FRA value = -200 }
command = { type = vassal which = FUC }
}
}


#Colonial events by mfigueras
### Comuneros de Paraguay 1718

event = {
id = 285020
trigger = { owned = {province = 216 data = -1}
        domestic = {type = serfdom value = 4}
        domestic = {type = centralization value = 4} 
        NOT = { domestic = {type = serfdom value = 9} } }
random = no
country = SPA

name = "‘Комунеросы’ Парагвая"
desc = "Восстание ‘комунерос’ 1718 года в Парагвае явилось протестом креолов и испанцев против правителя Асунсьона, помогавшего Ордену иезуитов. Креолы и испанцы обвиняли иезуитов во владении лучшими землями и в сокращении рабочей силы, вследствие уменьшения рабочего времени для местного населения. В действительности восстание длилось до 1735 года, когда армия рабов под командованием иезуитов разгромила ‘комунерос’."
style = 4
date = {day = 1 month = march year = 1718}
offset = 60
deathdate =  {day = 1 month = march year = 1720}

action_a = {name = "Проклятье!"
        command = {type = revolt which = 216}
        command = {type = revolt which = 216}
        }
}

### La rebeliуn en Venezuela 1749

event = {
id = 285021
trigger = { owned = {province = 154 data = -1}
        domestic = {type = serfdom value = 3}
        domestic = {type = centralization value = 4} }
random = no
country = SPA

name = "Венесуэльская революция 1749 года"
desc = "Целью восстания 1749 года в Венесуэле была созданная в 1728 году компания 'Compania Guipuzcoana de Caracas', обладающая монопольным правом на ведение торговли венесуэльским какао, кожей и табаком. Лидером восстания стал Хуан Франсиско де Леон, который настроил несколько тысяч фермеров против торговцев компании. Восставшие захватили Каракас, но, в конечном счете, бунт был подавлен."
style = 4
date = {day = 1 month = march year = 1749}
offset = 60
deathdate = {day = 1 month = march year = 1750}

action_a = {name = "Сокрушить революционеров"
        command = {type = revolt which = 154}
        command = {type = revolt which = 154}
        command = {type = provincetax which = 154 value = 1}  ## state monopoly
        }
action_b = {name = "Позволить свободную торговлю в Венесуэле"
        command = {type = domestic which = mercantilism value = -1}  ## free trade
        command = {type = province_revoltrisk which = 154 value = -1}
        }
}

### Tupac Amaru

event = {
id = 285022
trigger = { owned = {province = 169 data = -1}
        OR = { owned = {province = 170 data = -1}
             owned = {province = 193 data = -1}
             owned = {province = 194 data = -1} }
        domestic = {type = serfdom value = 3}
        domestic = {type = centralization value = 4} }
random = no
country = SPA

name = "Восстание Тупак Амура"
desc = "В ноябре 1780 года Хосе Габриель Кондорканки, более известный как Тупак Амару, объединил всех перуанских рабов от рождения в самом крупном восстании против правителей. Причиной к бунту послужили сборы, налагаемые правителем и коррехидорами, а также жестокое обращение и недальновидная политика. Тупак Амару требовал отменить налоги, упразднить коррехидоров, а в провинциях и городах, в которых проживают рабы, назначать мэра из числа местного населения."
style = 4
date = {day = 4 month = november year = 1780}
offset = 10
deathdate = {day = 1 month = march year = 1781}

action_a = {name = "Подавить восстание"
        command = {type = revolt which = 169}
        command = {type = revolt which = 169}
        command = {type = revolt which = 170}
        command = {type = revolt which = 193}
        command = {type = revolt which = 194}
        command = {type = revolt which = 167}
        }
action_b = {name = "Принять требования Тупака Амура"
        command = {type = domestic which = centralization value = -2}
        command = {type = provincetax which = 169 value = -1}  ## customs suppressed
    command = {type = stability value = -1}
        }
}
### American trade

event = {
id = 285023
trigger = { owned = {province = 443 data = -1}
        OR = { owned = {province = 437 data = -1}
             owned = {province = 429 data = -1}
             owned = {province = 433 data = -1}
             owned = {province = 431 data = -1}
            }
        OR = {   owned = {province = 158 data = -1}
             owned = {province = 164 data = -1}
             owned = {province = 168 data = -1}
             owned = {province = 223 data = -1}
             owned = {province = 139 data = -1}
            }
        }
random = no
country = SPA

name = "Американская торговля"
desc = "В 1778 году испанский король Карл III позволил вести торговлю с американскими колониями в любой испанской гавани, а не только в Кадисе, который до этого обладал монопольным правом на ведение данного вида деятельности (которое, в свою очередь, до 1717 года принадлежало Севилье). Это разрешение побудило многих средиземноморских и кантабрийских торговцев к ведению рискованной колониальной торговли. Таким образом, в городах, поддерживающих новый политический курс, стали появляться товары и деньги."

style = 4
date = {day = 1 month = march year = 1778}
offset = 20
deathdate = {day = 20 month = september year = 1780}

action_a = {name = "Позволить всем жителям торговать с иностранцами"
        command = {type = provincetax which = 437 value = 1 }
        command = {type = provincetax which = 429 value = 1 }
        command = {type = provincetax which = 433 value = 1 }
        command = {type = provincetax which = 429 value = 1 }
        command = {type = provincetax which = 1413 value = 1 }
                command = {type = provincetax which = 432 value = 1 }
        command = {type = provincetax which = 444 value = -2 }
                command = { type = domestic which = MERCANTILISM value = -2 }
        command = {type = trade value = 150}
        }
action_b = {name = "Поддерживать монополию"
        command = {type = provincetax which = 444 value = 3 }
                command = { type = domestic which = MERCANTILISM value = 1 }
        }
}

### Sale of offices in the colonies

event = {
id = 285024
trigger = { domestic = { type = centralization value = 3 }
        OR = {  owned = { province = 29 data = -1 }
            owned = { province = 32 data = -1 }
            owned = { province = 26 data = -1 }
            owned = { province = 27 data = -1 }  
            owned = { province = 158 data = -1 }
            owned = { province = 163 data = -1 }
            owned = { province = 160 data = -1 }
            owned = { province = 159 data = -1 }
            owned = { province = 157 data = -1 }
            owned = { province = 168 data = -1 }
            owned = { province = 167 data = -1 }
            owned = { province = 169 data = -1 }
            owned = { province = 223 data = -1 }
            owned = { province = 215 data = -1 } } }
random = no
country = SPA

name = "Продажа должностей"
desc = "Проблему участия креолов в управлении удалось решить путем распродажи государственных должностей, тем более что правительство нуждалось в дополнительных доходах. Начиная с 1630 года, жителям колоний была предоставлена возможность занимать должности с помощью денег. В 1622 году король начал распродажу должностей в казначействе, в 1678 году – в провинциях, находившихся в ведении коррехидора, и в 1687 году - в колониях. Многие креолы воспользовались таким стечением обстоятельств. Покупка государственных должностей дала им некоторое влияние и независимость при управлении. Для короля это означало не только дополнительный доход, но и ограничение власти в колониях."
style = 3
date = {day = 16 month = march year = 1660}
offset = 3600
deathdate = {day = 1 month = december year = 1690}

action_a = {name = "Мы нуждаемся в деньгах"
        command = {type = cash value = 400}
        command = {type = inflation value = 2}  ## corrupciуn local
        command = {type = provincetax which = 168 value = -1}  ## Audiencias: Lima
        command = {type = provincetax which = 171 value = -1}  ## Chuquisaca 
        command = {type = provincetax which = 223 value = -1}  ## La Plata
        command = {type = provincetax which = 163 value = -1}  ## Quito
        command = {type = provincetax which = 160 value = -1}  ## Bogotб
        command = {type = provincetax which = 27 value = -1}   ## Nueva Espaсa
        }
action_b = {name = "Король сам назначит человека на алминистративную должность"
        command = {type = stability value = -2}
        command = {type = domestic which = centralization value = 1}
        command = {type = ADM which = 2 value = 96}
        command = {type = sleepevent which = 285025}
        }
}


### Sale of offices in the colonies (II)

event = {
id = 285025
trigger = { domestic = { type = centralization value = 3 }
        OR = {  owned = { province = 27 data = -1 }  
            owned = { province = 158 data = -1 }
            owned = { province = 163 data = -1 }
            owned = { province = 160 data = -1 }
            owned = { province = 159 data = -1 }
            owned = { province = 157 data = -1 }
            owned = { province = 168 data = -1 }
            owned = { province = 167 data = -1 }
            owned = { province = 169 data = -1 }
            owned = { province = 223 data = -1 }
            owned = { province = 215 data = -1 } } }
random = no
country = SPA

name = "Продажа должностей и увеличение сепаратизма в колониях"
desc = "Когда в 1687 году король начал ослаблять свои позиции в колониях, креолы не упустили шанса этим воспользоваться. Постепенно они начали рассматривать районы округа как свою родину, и в связи с этим утверждать, что, принимая во внимание их способность к управлению, они должны были занять все должности, существующие в районе. Уже к 1750 году во многих округах, а особенно в городах Лима, Чаркас и Кито, практически полностью господствовала местная креольская элита. И хотя они еще даже и не думали об отделении от империи, сложившаяся ситуация способствовала появлению некоего местного своеобразия, и определила центры будущих войн за независимость."
style = 4
date = {day = 16 month = march year = 1705}
offset = 3600
deathdate = {day = 1 month = december year = 1725}

action_a = {    name = "Система работает хорошо, мы её поддерживаем"
        command = {type = cash value = 200}
        command = {type = inflation value = 1}  ## corrupciуn local
        command = {type = province_revoltrisk which = 168 value = 1}  ## Audiencias: Lima
        command = {type = province_revoltrisk which = 171 value = 1}  ## Chuquisaca 
        command = {type = province_revoltrisk which = 223 value = 1}  ## La Plata
        command = {type = province_revoltrisk which = 163 value = 1}  ## Quito
        command = {type = province_revoltrisk which = 160 value = 1}  ## Bogotб
        command = {type = province_revoltrisk which = 27 value = 1}   ## Nueva Espaсa
        }
action_b = {    name = "Это не может больше продолжаться, ввести королевский контроль"
        command = {type = stability value = -2}
        command = {type = inflation value = -1}
        command = {type = ADM which = 2 value = 96}
        }
}

### Migration from the Canaries to Venezuela
event = {
id = 285026
trigger = { owned = { province = 817 data = -1 }  ## Canarias
        OR = { owned = { province = 154 data = -1 } ## prov venezolanas
             owned = { province = 155 data = -1 }
             owned = { province = 156 data = -1 }
             owned = { province = 157 data = -1 }
            }
        }
random = no
country = SPA

name = "Канарские эммигранты в Венесуэле"
desc = "Начиная с 1680 года, многие жители Канарских островов эмигрировали в Венесуэлу. С одной стороны, для Канарских островов наступили не лучшие времена: естественная убыль населения, сложная ситуация в экономике и сельском хозяйстве, неблагоприятные климатические условия, и т.д. С другой стороны, Венесуэла быстро развивала свой огромный потенциал, и поэтому нуждалась в большем количестве сельскохозяйственных работников. Более того, на волну переселенцев повлиял и тот факт, что это была самая близкая к Канарским островам американская колония."
style = 4
date = {day = 23 month = march year = 1700 }
offset = 1200
deathdate = { day = 23 month = march year = 1708 }

action_a = {name = "Ok"
        command = {type = population which = 817 value = -1000}
        command = {type = population which = 155 value = 300}
        command = {type = population which = 154 value = 300}
        command = {type = population which = 156 value = 300}
        }
}


#If Italy is created, by mnorrefeldt
event = {
    id = 285003
    trigger = { 
        exists = ITA
         }
    random = no
    country = SPA
    name = "Королевство Италия угрожает балансу сил"
    desc = "Образовалось королевство Италия как независимая часть Священной Римской Империи, поэтому в Милане был коронован новый король. Они заявляют о своих правах на все земли на севере полуострова, а их появление грозит нарушить сложившееся равновесие."
    style = 1

    date = { day = 1 month = january year = 1419 }
    offset = 5
    deathdate = { day = 1 month = january year = 1820 }

    action_a = {
            name = "Плохие новости"
            command = { type = casusbelli which = ITA value = 120 } 
      }
    action_b = {
            name = "Искать их дружбы"
        command = { type = diplomats value = -1 }
            command = { type = stability value = -1 }
        command = { type = relation which = ITA value = 100 }
      }
}


##Bordic###

#The Commissioning of El Escorial#

event = {
id = 285700
random = no
country = SPA
name = "Эль-Эскориал"
desc = "Когда Филипп II стал королём Испании и наконец то прибыл в своё королевство, он выбрал центральное место для своей администрации, Мадрид. Но новая столица испытывала недостаток во Дворце, центральном здании Правительства и Усыпальницу для испанской династии Габсбургов. Руководимый глубокой религиозностью и острым умом, Фелиппе решил построить монастырь во имя  Святого Лоренсо и победы над французами. 10 августа 1557 года, начали строить монастырь Сан Лоренсо эль-Эскориал, он был сконструирован в необычайном прямолинейном стиле с многочисленными внутренними дворами. Несмотря на свой габсбургский религиозный стиль, Фелиппе содержал лучшую библиотеку старых рукописей, не уступавшей по своей величине ватиканской библиотеке. От королевских палат, окружающих главный алтарь Базилики, стоял монастырь в скором времени должен был стать самым главным символом империя Габсбургов и их могущества."

style = 2

date = { day = 1 month = january year = 1562 }
offset = 10
deathdate = { day = 1 month = january year = 1563 }
action_a = { 
name = "Слава нашему императору!"
command = { type = treasury value = -300 }
command = { type = relation which = PAP value = 50 }
command = { type = relation which = FRA value = -50 }
}

action_b = { 
name = "Бесполезная затея..."
command = { type = stability value = 1 }
command = { type = sleepevent which = 285701}
}
}


#El Escorial stands in Unearthly Glory#
event = {

id = 285701
random = no
country = SPA
name = "Финальная стадия строительства"
desc = "Работа над монастырём была закончена лишь в 1584 году, спустя 21 году, после того как она только начинала строиться. В 1567 году, архитектор Хуан Баптиста де Толедо умер, на его место назначили другого архитектора, Хуана де Херреро, который дал этому архитектурному стилю название Херреро, характерные строгие линии с небольшими украшениями и контрастными гранитными камнями в стене усыпанными небольшими кусочками чёрного сланца. Эль-Эскориал был символом испанских Габсбургов, управлявших огромной империей. эль-Эскориал потерял свою былую важность, когда французская династия Бурбонов в 1705 году отстроила ещё более величественное сооружение, Версальский дворец, который стал королевским пантеоном."

style = 2

date = { day = 1 month = january year = 1585 }
offset = 30
deathdate = { day = 1 month = january year = 1586 }

action_a = { 
name = "Мы это сделали!"
command = { type = vp value = 50 }
command = { type = stability value = 1 }
command = { type = relation which = PAP value = 50 }
command = { type = relation which = HAB value = 50 }
command = { type = relation which = FRA value = -50 }
command = { type = relation which = ENG value = -50 }
command = { type = relation which = HOL value = -50 } 
command = { type = DIP which = 2 value = 60 }
command = { type = domestic which = innovative value = -1 }
command = { type = domestic which = centralization value = 1 }
command = { type = infra value = 500 } 
}
}




# modified by Garbon and further by Fodoron
# This event is mainly for changing the .ai file for Spain from the war of Granada to exploration
event = {
    id = 285500
    trigger = { 
        OR = {
            NOT = { exists = GRA }
            year = 1510
        }
    }
    random = no
    country = SPA
    name = "Новый Свет открыт!"
    desc = "После долгих войн за Гранаду, многие участники походов не хотели больше работать в поле как простые крестьяне и продолжали воевать в бесконечных итальянских компаниях, в войске Фернандо Гонсалеса де Кордоба, позже названного эль-Гран Капитан. При этом многие были наслышаны рассказами о том, что где-то за морем находится Новый Свет. Колумб уже вернулся из своего первого путешествия и привёз с собой несколько аборигенов и много золотых слитков. Некоторые даже рассказывали, что стоит в тех краях подойти к аборигену с небольшим мешочком, как он тут же заполнит его полностью золотом, сделав европейца богачом. Не каждый верил этим сказкам, но участвуя в экспедициях, можно было легко продвинутся по карьерной лестнице."
    style = 1
    date = { day = 28 month = december year = 1492 }
    offset = 100
    deathdate = { day = 1 month = january year = 1511 }
    action_a = {
        name = "Новый Свет ждёт нас!"
        command = { type = stability value = 1 }  
        command = { type = domestic which = land value = -1 }
        command = { type = naval value = 300 }
        command = { type = treasury value = -50 }
        command = { type = warships which = -1 value = 4 } # Andalusia
        command = { type = transports which = -1 value = 10 } # Andalusia
    }
    action_b = {
        name = "Давайте лучше сосредоточимся на итальянской компании"
        command = { type = stability value = 1 }  
        command = { type = land value = 300 }
        command = { type = treasury value = -50 }
        command = { type = INF which = -2 value = 12000 } # Sicily
        command = { type = CAV which = -2 value = 8000 } # Sicily
    }
}




event = {
    id = 285043
trigger = { 
        
domestic = { type = aristocracy value = 6 }
domestic = { type = serfdom value = 5 }
NOT = { domestic = { type = centralization value = 8 } }

}
       
    random = no
    country = SPA
    name = "Потеря Италии"
    desc = "Испанская империя вступила в фазу упадка. Её отдельные части перестали чувствовать себя единой страной. Италия долгое время бывшая верной частью Империи, начала борьбу за независимость."
    style = 1
        date = { day = 1 month = january year = 1660 }
    offset = 900
    deathdate = { day = 1 month = january year = 1820 }
    action_a = { # 
        name = "Это печальный факт"
        command = { type = remove_countryculture which = amazonian }
    }
}


# The encomiendas
# by Fodoron
event = { 
    id = 285145
    trigger = { 
        OR = { 
            owned = { province = 137 data = -1 } # Havana
            owned = { province = 138 data = -1 } # Moron
            owned = { province = 139 data = -1 } # Guantanamo
            owned = { province = 143 data = -1 } # Barahona
            
        }
    }
    random = no     
    country = SPA
    name = "'Encomiendas'"
    desc = "EVENTHIST285145"
    style = 1 
      
    date = { day = 12 month = october year = 1519 }
    offset = 2000
    deathdate = { day = 15 month = march year = 1527 }
      
    action_a = { # continue
        name = "продолжить"
        command = { type = badboy value = 1 } 
        command = { type = population which = 137 value = -200 } # Havana
        command = { type = population which = 138 value = -200 } # Moron
        command = { type = population which = 139 value = -200 } # Guantanamo
        command = { type = population which = 141 value = -200 } # Les Cayes
        command = { type = population which = 143 value = -200 } # Barahona
        
    }
    action_b = { # release the slaves
        name = "Освободить рабов"
        command = { type = badboy value = -1 } 
        command = { type = provincetax which = 138 value = -1 } # Moron
        command = { type = provincetax which = 139 value = -1 } # Guantanamo
        command = { type = provincetax which = 137 value = -1 } # Havana
        command = { type = provincetax which = 141 value = -1 } # Les Cayes
        command = { type = provincetax which = 143 value = -1 } # Barahona
        
        command = { type = revolt which = 139 } # Guantanamo
        command = { type = revolt which = 137 } # Havana

        command = { type = revolt which = 143 } # Barahona
        command = { type = sleepevent which = 285160 } # The New Laws
        command = { type = sleepevent which = 285161 } # The rebellion of the encomenderos
    }
}

# The New Laws
# by Fodoron
event = { 
    id = 285146
    random = no     
    country = SPA
    name = "Новые законы"
    desc = "Бартоломе де лас Касас не был одним борцом за права индейцев, многие другие священники и должностные лица в колониях, осуждали злодеяния и злоупотребления. Император и его суд были напуганы сложившейся ситуации. После завоевания Новой Испании (империя Инков), Чарльз был рассержен тем, каким кровавым способом Писарро захватил эту империю и по этому решил отрегулировать свод законов и прав для индейцев, советуясь у лас Касаса. Новые законы, выпущенный в 1542 году запретил любой вид рабства, право индейца самому искать место работы, теперь Церковь не имела ни какой власти над нехристианскими аборигенами. Предсказывали, что ввод  новых законов принесёт только существенный вред испанским колониям."
    style = 1 
      
    date = { day = 20 month = november year = 1542 }
      
    action_a = { # promulgate the law
        name = "Ввести законы"
        command = { type = stability value = -1 } 
        command = { type = revoltrisk which = 24 value = 2 }
    }
    action_b = { # denie the law
        name = "Они нам только навредят"
        command = { type = population which = 165 value = -500 } # Cajamarca
        command = { type = population which = 166 value = -500 } # Huanuco
        command = { type = population which = 167 value = -500 } # Ayacucho
        command = { type = population which = 168 value = -500 } # Lima
        command = { type = population which = 169 value = -500 } # Cuzco
        command = { type = population which = 170 value = -500 } # Arequipa
        command = { type = population which = 171 value = -500 } # Moquega
        command = { type = population which = 172 value = -500 } # Arica
        command = { type = sleepevent which = 285161 } # The rebellion of the encomenderos
    }
}

# The rebellion of the encomenderos
# by Fodoron
event = { 
    id = 285147
    random = no     
    country = SPA
    name = "Восстание Гонсало Писарро"
    desc = "EVENTHIST285147"
    style = 1 
      
    date = { day = 15 month = may year = 1544 }
      
    action_a = { 
        name = "Восстания конкистодоров"
        command = { type = desertion which = 168 value = 10000 } # Lima
        command = { type = revolt which = 167 } # Ayacucho
        command = { type = revolt which = 168 } # Lima
        command = { type = revolt which = 169 } # Cuzco
        command = { type = revolt which = 170 } # Arequipa
        command = { type = revolt which = 39 }  # Isthmus
    }
}

# expedition to Philippines
# by Fodoron
event = {
    id = 285148
    trigger = { 
            owned = { province = 24 data = -1 } # Jalisco
    }
    random = no     
    country = SPA
    name = "Империя над которой никогда не заходит солнце"
    desc = "EVENTHIST285148"
    style = 1 
      
    date = { day = 21 month = november year = 1564 }
      
    action_a = { # finance it
        name = "Отлично"
        command = { type = treasury value = -25 } 
        command = { type = warships which = 24 value = 1 } # Jalisco
        command = { type = explorer which = 24 }
    }
    action_b = { # renounce to it
        name = "Отказаться от этого"
        command = { type = land  value = 100 }
        command = { type = relation which = POR value = 25 }
    }
}

# Manila Galleon
# by Fodoron
event = { 
    id = 285149
    trigger = { 
        owned = { province = 691 data = -1 } 
    }
    random = no     
    country = SPA
    name = "Галеон из Манилы"
    desc = "EVENTHIST285149"
    style = 1 
      
    date = { day = 15 month = march year = 1565 }
    offset = 5000
    deathdate = { day = 15 month = march year = 1819}
      
    action_a = { 
        name = "Галеон из Манилы прибыл"
        command = { type = provincetax which = 691 value = 3 } 
        command = { type = provincetax which = 24 value = 2 }  # Jalisco
        command = { type = provincetax which = 443 value = 1} # Andalusia
        command = { type = domestic which = mercantilism value = 1 }
        command = { type = treasury value = 500 }
    }
}

# Modern Flag
# By Fodoron
# Many thanks to Kaigon and Jarl Birger for their graphics
event = {
    id = 285150
    trigger = { monarch = 04148 } # Carlos III 
    random = no     
    country = SPA
    name = "Модернизация флага"
    desc = "Испанский военно-морской флот имел флаг белого цвета, доставшийся им от Бурбонов, это создавало проблему отличия национальных судов от судов, принадлежащих другим странам, так же имеющим белый цвет флага Бурбонов (Франция, Парма, Тоскана и Королевство обеих Сицилий). Карлос III решил изменить флаг военно-морским силам, для этого ему было представлено 12 проектов, отобранных министром флота, Антонио Валдесом. Они были двухцветными комбинациями красного, жёлтого, синего и белого. Его выбор пал на флаг с двумя горизонтальными красными полосами, отделёнными друг от друга широкой жёлтой полосой. В 1843 году, во время правления Изабеллы II было решено, что военно-морской флот должен принять национальный флаг Испании."
    style = 1 
    date = { day = 21 month = may year = 1785 }
      
    action_a = { # new flag
        name = "Новый флаг"
        command = { type = treasury value = -500 }
        command = { type = flagname which = Modern }
command = { type = warships which = -1 value = 20 }
command = { type = transports which = -1 value = 4 }
command = { type = treasury value = -600 }
    }
    action_b = { # old flag
        name = "Оставить старый"
        command = { type = vp value = -5 } 
    }
}

# the Statutes of Blood Cleanliness
# by Fodoron
event = { 
    id = 285051
    random = no     
    country = SPA
    name = "Устав о Чистоте Крови"
    desc = "EVENTHIST285051"
    style = 1 
      
    date = { day = 15 month = june year = 1547 }
      
    action_a = { # 
        name = "Ввести его"
        command = { type = stability value = 1 } 
        command = { type = domestic which = innovative value = -1 }
    }
    action_b = { # Reject them
        name = "Он нам только навредит"
        command = { type = stability value = -1 } 
        command = { type = domestic which = innovative value = 1 }
    }
}

# The death of prince Carlos
# by Fodoron
event = { 
    id = 285052
    random = no     
    country = SPA
    name = "Смерть принца Карлоса"
    desc = "EVENTHIST285052"
    style = 1 
      
    date = { day = 19 month = january year = 1568 }
      
    action_a = { 
        name = "Это позор, у нас нет наследника!"
        command = { type = stability value = -1 }
    }
}

# Antonio Perez - part 1 (historical) #
# by Fodoron
event = { 
    id = 285053
    random = no     
    country = SPA
    name = "Антонио Перес, часть 1"
    desc = "Гонсало Перес был лучшим госсекретарём императора Карлоса,  в это же самое время он занимал пост  католического священника, имел жену и сына. Антонио Перес-сын Гонсало, имел самое лучшее образование, которое тогда можно было получить в Европе. Он был необычайно интеллектуален и быстро догнал своего отца по служебной лестнице, но вскоре стал очень эгоистичным и коррумпированным. Антонио имел тайные любовные связи с вдовой своего прежнего защитника, одноглазой принцессой Эболи. Их интриги вынудили Антонио Переса заказать убийство секретаря  и двоюродного брата короля, Хуана де Австрийского в марте 1578 года, так как тот слишком много знал и оказывал на пару давление. Филипп II поначалу защищал Антонио, но протесты противоположной фракции были слишком большими, королю пришлось оставить свою идею, и хотя обвинения в убийстве не были доказаны, в Испании начался длительный процесс о коррупции, который длился несколько лет."
    style = 1 
      
    date = { day = 23 month = march year = 1578 }
      
    action_a = {
        name = "Преследовать его по суду" # 
        command = { type = stability value = 1 } 
    }
    action_b = {
        name = "Позволить ему остаться вашим секретарём" # 
        command = { type = stability value = -1 } 
        command = { type = ADM which = -2 value = 60 }
        command = { type = sleepevent which = 285054 } # Antonio Perez - part 2
        command = { type = sleepevent which = 170034 } # FRA Antonio Perez
        command = { type = sleepevent which = 164012 } # ENG Antonio Perez
    }
}

# Antonio Perez - part 2 #
# by Fodoron
event = { 
    id = 285054
    random = no     
    country = SPA
    name = "Антонио Перес, часть 2"
    desc = "EVENTHIST285054"
    style = 1 
      
    date = { day = 10 month = november year = 1591 }
      
    action_a = {
        name = "Провести расследование в Арагоне" # 
        command = { type = domestic which = centralization value = 1 }
        command = { type = revolt which = 430 } # Aragon
    }
    action_b = {
        name = "Проигнорировать" # 
        command = { type = domestic which = centralization value = -2 }
        command = { type = sleepevent which = 170034 } # FRA Antonio Perez
        command = { type = sleepevent which = 164012 } # ENG Antonio Perez
    }
}

#  #
# by Fodoron
event = {
    id = 285055 #triggered by FRA 170034
    random = no     
    country = SPA
    name = "Антонио Перес, часть 3"
    desc = "Во Франции, Антонио Перес был хорошо принят. Хотя Франция и Испания были уже в мире многие годы, Анри IV нашёл чем возразить Филиппу, к тому же он был протестантом и желал мести. Находясь при дворе короля Анри, Антонио Перес рассказал ему всю информацию, которую знал об Испании. В благодарность Анри не считая подарков,  дал ему даже маленькую армию для вторжения в Испанию. Однако его армия была разбита, а сам он снова бежал."
    style = 1 
      
    action_a = {
        name = "Да, Антонио Перес" # 
        command = { type = casusbelli which = FRA value = 60 }
    }
}

# Antonio Perez - part 4 #
# by Fodoron
event = {
    id = 285056 #triggered by ENG 164012
    random = no     
    country = SPA
    name = "Антонио Перес, часть 4"
    desc = "В Англии, Антонио Перес так же хорошо был принят. В это время Елизавета боролась против Испании, и информация данная Пересом помогла Говарду в 1596 году удачно провести нападение на Кадис. Он продолжал составлять заговоры против испанского монарха. С Анри IV Французским он подготавливал вторжение в Арагон, с Англией, на Неаполь, но все неудавшиеся. Анри был вынужден подписать мирное соглашение с Испанией в Вервинсе, в 1598 году, из-за трудной экономической ситуации. Англичане пережили сокрушительное поражение во время атаки на Азорские острова. Антонио Перес потерял былое доверие у иностранных монархов, но продолжал писать клевету против Филиппа II, внося свой вклад в 'чёрную легенду' о короле Испании. Наконец он умер всеми забытый и нищий  в Париже, в 1611 году."
    style = 1 
      
    action_a = {
        name = "Да, Антонио Перес" # 
        command = { type = population which = 445 value = -500 } # Gibraltar
        command = { type = casusbelli which = ENG value = 60 }
    }
}

# The Spanish Armada
# by Fodoron
event = { 
    id = 285057
    trigger = {
        OR = {
            AND = {
                event = 21040 # Drake Strikes the Panamanian Silver Train
                event = 21042 # Drake in the Pacific
            }
            event = 21044 # Drake Strikes in Spain and the Americas
            event = 21046 # English Aid Arrives in the Dutch Provinces
        }
        NOT = { relation = { country = ENG data = 0 } }
    }
    random = no     
    country = SPA
    name = "Испанская армада"
    desc = "EVENTHIST164013"
    style = 1 
      
    date = { day = 30 month = july year = 1588 }
      
    action_a = { 
        name = "Бог нам не помог"
        command = { type = treasury value = -600 }
        command = { type = desertion which = -1 value = 3000 }
        command = { type = stability value = -1 }
        command = { type = naval value = 3000 } # Fleet improvement afterwards
command = { type = warships which = -1 value = 9 }
command = { type = transports which = -1 value = 4 }
    }
}

# 
# by Fodoron
event = { 
    id = 285058
    trigger = {
        event = 164013 # The English Armada
    }
    random = no     
    country = SPA
    name = "Смерть Дрейка"
    desc = "EVENTHIST285058"
    style = 1 
      
    date = { day = 27 month = january year = 1596 }
      
    action_a = { 
        name = "И слава Богу!"
        command = { type = stability value = 1 }
    }
}

# The Martyrs of Nagasaki
# by Fodoron
event = { 
    id = 285059
    trigger = { 
        owned = { province = 690 data = -1 } # Luzon
        exists = NIP
    }
    random = no     
    country = SPA
    name = "Мученики Нагасаки"
    desc = "EVENTHIST285059"
    style = 1 
      
    date = { day = 6 month = february year = 1597 }
      
    action_a = { 
        name = "Боже прими их души!"
        command = { type = treasury value = -25 } 
        command = { type = relation which = NIP value = -100 }
        command = { type = casusbelli which = NIP value = 120 }
    }
}

# Luis I of Spain #
# by Fodoron
event = { 
    id = 285060
    trigger = { monarch = 04146 } # Felipe V 
    random = no     
    country = SPA
    name = "Луис I Испанский"
    desc = "EVENTHIST285060"
    style = 1 

    date = { day = 30 month = august year = 1724 }
      
    action_a = {
        name = "Король умер. Горе!"  # The king is dead
        command = { type = stability value = -1 }
        command = { type = ADM which = -1 value = 262 }
        command = { type = DIP which = -2 value = 262 }
    }
}

#Godoy#
#by Fodoron with the help of the Spanish Forum
event = {
    id = 285061
    trigger = { monarch = 04149 } # Carlos IV 
    random = no
    country = SPA
    name = "Мануэль Годой, принц Мира"
    desc = "EVENTHIST285061"
    style = 3

    date = { day = 15 month = november year = 1792 }

    action_a = {
        name = "Некомпетентный министр!" ##
        command = { type = DIP which = -2 value = 60 }
        command = { type = MIL which = -2 value = 60 }
        command = { type = stability value = -1 }
    }
}

#The disentailment of Godoy#
#by Fodoron with the help of the Spanish Forum
event = {
    id = 285062
    random = no
    country = SPA
    name = "Последствия политики Годоя"
    desc = "EVENTHIST285062"
    style = 3

    date = { day = 15 month = july year = 1798 }

    action_a = {
        name = "Неудавшаяся реформа" #A failed reform#
        command = { type = treasury value = 200 }
        command = { type = inflation value = -1 } # reduction of debt
        command = { type = domestic which = innovative value = 1 }
        command = { type = domestic which = aristocracy value = -1 }
    }
}

#The second treaty of San Ildefonso
#by Fodoron with the help of the Spanish Forum
event = {
    id = 285063 # triggered by FRA 170035
    random = no     
    country = SPA
    name = "Сан-Ильдефонское соглашение"
    desc = "После первого соглашения прошедшим в Сан-Ильдефонсо, Испания стала надежным союзником Франции в ее войнах с Англией, однако Испании, приходилось тяжелее. Ее флот был серьезно поврежден, и её жизненно-необходимая торговля с американскими колониями была прервана, по этому Испания вынуждена была подписать мир. Эта ситуация оставила флот Наполеона без баз снабжения на полуострове, поскольку британский флот использовал порты Португалии, своего традиционного союзника. Наполеон нуждался в испанском сотрудничестве, не только чтобы выиграть войну на море, но и для включения Испании в континентальную блокаду против островов. Испания не давно заключившая мир с Британией, хотела остаться нейтральной в этом конфликте. У испанского премьер-министра Мануэля Гадеу, оставалось два варианта, или с Францией или против Франции, и он выбрал Наполеона. Британия используя мирное соглашение как оправдание, объявила войну Испании."
    style = 1 
      
    action_a = {
        name = "Принять соглашение"  # Accept the treaty
        command = { type = relation which = ENG value = -25 }
        command = { type = relation which = POR value = -25 }
        command = { type = trigger which = 164014 } # ENG treaty of San Ildefonso ratified
    }
    action_b = {
        name = "Отклонить" # Reject the treaty
        command = { type = relation which = FRA value = -75 }
        command = { type = trigger which = 170036 } # FRA Spain rejects treaty of San Ildefonso
    }
}

# War of the oranges #
# by DBM and Fodoron with the help of the Spanish Forum
event = { 
    id = 285064
    trigger = { event = 164014 } # ENG treaty of San Ildefonso ratified 
    random = no     
    country = SPA
    name = "Быстрая война с Португалией"
    desc = "EVENTHIST285064"
    style = 1 

    date = { day = 8 month = june year = 1801 }
      
    action_a = {
        name = "Сотрудничать, но и обманывать Наполеона" # Collaborate but trick Napoleon
        command = { type = relation which = FRA value = -25 }
        command = { type = relation which = POR value = -25 }
        command = { type = treasury value = 25 }
        command = { type = trigger which = 170037 } # FRA War of the oranges
        command = { type = trigger which = 260063 } # POR War of the oranges
    }
    action_b = {
        name = "Верно служить Наполеону" # Fully collaborate
        command = { type = relation which = FRA value = 25 }
        command = { type = relation which = POR value = -100 }
    }
    action_c = {
        name = "Отказаться в сотрудничестве" # 
        command = { type = relation which = FRA value = -100 }
        command = { type = relation which = POR value = 25 }
    }
}

#Magellan's Expedition by Bordic
event = {
    id = 285065
    random = no
    country = SPA
    name = "Первое кругосветное путешествие"
    desc = "EVENTHIST285065"
    style = 2

    date = { day = 20 month = february year = 1518 }
    offset = 20
    deathdate = { day = 10 month = august year = 1519 }

    action_a ={ 
        name = "Нанять его!"
        command = { type = treasury value = -50 }
    }
    action_b ={ 
        name = "Пустая трата денег!"
        command = { type = vp value = -10 }
        command = { type = land  value = 100 }
        command = { type = sleepleader which = 09752 }#Magallanes
        command = { type = sleepleader which = 09753 }#Elcano 
        command = { type = sleepevent which = 326032 } #VEN Pigafetta's Report
        command = { type = sleepevent which = 285066 } #SPA Pigafetta's Report
        }
}

#Pigafetta's Report by Bordic (SPA version)
event = {
    id = 285066
    random = no
    country = SPA
    name = "Географические труды Пифагетты"
    desc = "EVENTHIST326032"
    style = 2

    date = { day = 20 month = october year = 1525 }
    offset = 120
    deathdate = { day = 10 month = august year = 1534 }

    action_a ={ 
        name = "Ученье свет!"
        command = { type = naval value = 200}
    }
}

# The naval reforms of Ensenada #
# by Invernalia and Fodoron with the help of the Spanish Forum
event = { 
    id = 285067
trigger = {
        owned = { province = 433 data = -1 }
        
    }
    random = no     
    country = SPA
    name = "Военно-морские реформы Энсенады"
    desc = "Маркиз Зенон Сомодевилла Энсенада, министр короля Фернандо VI, начал понимать, что испанский флот отстаёт в развитии от других морских держав. Чтобы хоть как-то обновить морские силы, он проводит военно-морские преобразования, параллельно изучая военно-морские технологии других европейских стран, от Англии до России и даже обращаясь к индустриальному шпионажу.  По реформе были наняты самые лучшие английские судостроители, построившие современные верфи в Ферроле, Картахене и Кадисе. Эти реформы положительно сказались на испанском флоте и позволили ему оставаться конкурентно способным вплоть до Наполеоновских войн. В XVII веке порты постепенно начали строить у реки Гвадаквивира, Севилья же теряет своё былое портовое могущество."
    style = 1 
    date = { day = 15 month = march year = 1748 }
      
    action_a = { # 
        name = "Реформировать их"
        command = { type = treasury value = -300 }
        command = { type = naval value = 1000 }
        command = { type = domestic which = LAND value = -1 }
        command = { type = domestic which = mercantilism value = 1 }
        command = { type = warships which = 433 value = 15 }

                command = { type = transports which = 433 value = 4 }
        command = { type = gainbuilding which = 433 value = shipyard } # Galicia
        command = { type = losebuilding which = 443 value = shipyard } # Andalusia
    }
    action_b = { # 
        name = "Давайте улучшим армию"
        command = { type = treasury value = -100 }
        command = { type = land value = 1000 }
        command = { type = domestic which = LAND value = 1 }
        command = { type = inf which = -1 value = 5000 }
    }
}

# Capture of the Spanish treasure fleet #
# by Malatesta and Fodoron with the help of the Spanish forum #
event = { 
    id = 285068 #triggered by HOL 186027
    random = no     
    country = SPA
    name = "Захват испанких короблей с золотом"
    desc = "После войны с Испанией, наступил долгожданный мир, который длился двенадцать лет. Голландцы использовали это время для наращивания своего военно-морского превосходства, путешествуя по всем уголкам света и расширяя свою колониальную империю за счёт Испании и Португалии. Спустя несколько лет после того, как возобновились военные действия, в 1628 году, Вице-Адмирал Пит Хейн, находясь на службе у голландской Вест-Индской компании, командовал флотом, который захватил несколько испанских кораблей, перевозящих американское золото в Испанию близ Матансаса (Куба). Это было единственное удавшееся нападение за 300 лет ежегодных отгрузок серебра и предметов роскоши. Это означало, солидную потерю существенной части дохода для испанской Короны в трудное время. Питу Хейну было присвоено следующие звание, Лейтенант-Адмирал Голландского Флота, но он умер в следующем году, борясь с испанскими корсарами близ города Дюнкерк."
    style = 1 
      
    action_a = { # OK
        name = "Чёрт!"
        command = { type = treasury value = -500 }
        command = { type = trade value = -400 }
        command = { type = merchants value = -2 }
    }
}

# Royal Academies #
# by Gauna and Fodoron with the help of the Spanish Forum
event = { 
    id = 285069
    random = no     
    country = SPA
    name = "Первые испанские Королевские Академии"
    desc = "Самая первая академия была построена в Италии во время эпохи Возрождения, она была направлена на обучение студентов литературой, искусством и наукам. За XVII век подобные академии строятся уже во Франции, где приобретают характер национальных центров по обучению служебных и власть имущих граждан. Но именно в следующим столетии, когда эпоха Просвещения распространяется и на другие страны Европы, академии создаются повсеместно. В Испании, Королевская Библиотека, которая позже стала национальной библиотекой, была создана в 1712 году королём Филиппом V. В 1714 году была построена первая Королевской Академией обучающая испанскому языку и литературе. В 1735 году строится Королевская Академия по обучению истории, а 1752 году Королевская Академия Искусств, в Сан-Фернандо, обучающая искусством и математике. В этих же городах позже строятся Королевский Ботанический Сад, Астрономическая Обсерватория и Королевский Кабинет естествознания."
    style = 1 

    date = { day = 3 month = october year = 1714 }
    offset = 1000
    deathdate = { day = 12 month = april year = 1752 }

    action_a = {
        name = "Создать их!" # 
        command = { type = treasury value = -150 } # they were cheap
        command = { type = domestic which = innovative value = 1 }
    }
    action_b = {
        name = "Не создавать" # 
        command = { type = vp value = -5 }
    }
}

# Reaction to the French revolution #
# by Gauna and Fodoron with the help of the Spanish Forum
event = { 
    id = 285070
    trigger = {
        OR = {
            event = 3342 # The French Revolution: Radical Republic 
            event = 3779 # The French Revoltution: Republican Monarchy
        }
    }
    random = no     
    country = SPA
    name = "Испанская реакция на Французскую Революцию"
    desc = "Французская Революция совпала со сменой монарха в Испании. Испанская монархия, как и многие другие была напугана происходящими событиями, и обвинила в этом просвещение и либерализм . Французская Революция рассматривалась как инфекционная болезнь, которая должна быть остановлена всеми доступными средствами. Границы с Францией были закрыты, все преобразовательные программы приостановлены. Цензура и репрессии переданы в руки Расследования, которая тут же начинает охоту за самыми главными реформистами. Кабарруса сажают в тюрьму, Ёвелланоса высылают за пределы страны, так же как и Кампоманеса. Премьер-министр Флоридабланка экономически поддерживает Луи XVI Французского, кузена испанского короля. Однако вскоре во Франции свергли монарха, Испания рвёт свой традиционный союзный договор с Францией и начинает сближаться с такими странами, как Великобритания, Голландия, Австрия, Португалия и Пруссия, таким образом формируется Первая антифранцузская коалиция."
    style = 1

    date = { day = 10 month = august year = 1792 }
    offset = 100
    deathdate = { day = 7 month = march year = 1793 }

    action_a = {
        name = "Выступить против республики" # oppose the republic
        command = { type = domestic which = innovative value = -2 }
        command = { type = domestic which = aristocracy value = 1 }
        command = { type = relation which = FRA value = -100 }
        command = { type = relation which = ENG value = 50 }
        command = { type = relation which = HOL value = 50 }
        command = { type = relation which = HAB value = 50 }
        command = { type = relation which = POR value = 50 }
        command = { type = relation which = PRU value = 50 }
    }
    action_b = {
        name = "Ничего не делать" # 
        command = { type = stability value = -2 }
        command = { type = domestic which = aristocracy value = -1 }
        command = { type = relation which = FRA value = 50 }
        command = { type = relation which = ENG value = -25 }
        command = { type = relation which = HOL value = -25 }
        command = { type = relation which = HAB value = -25 }
        command = { type = relation which = POR value = -25 }
        command = { type = relation which = PRU value = -25 }
    }
}

# Enlightenment reforms of Carlos III #
# by Fodoron with the help of the Spanish Forum
event = { 
    id = 285071
    trigger = { monarch = 04148 } # Carlos III 
    random = no     
    country = SPA
    name = "Просвещённые реформы Карлоса III"
    desc = "Карлос III ещё был королём Неаполя, когда короновался на Испанский трон, из-за смерти своего родного брата Фернандо VI. Из Неаполя он приехал в сопровождении сицилийца Лепольдо Григорио и маркиза Эсквиллаче (уроженец Калабрии), ставший впоследствии министром. После 30 летнего отсутствия в Испании, он так и не смог назвать её вторым домом. По своему характеру, он был верным реформистом, яркий пример эпохи Просвещённого Абсолютизма. Правительство Эсквиллаче проводит в Испании очень необходимые экономические реформы. Создаются Королевские Лотереи увеличивающие доход государству, ограничивается власть церкви. Другими важными мерами было запрет на ношение оружия, запрет на освещение ночных улиц и создание организованной системы уборки мусора в столице, недаром же в те времена Мадрид рассматривали как самым грязным городом Европы."
    style = 1 

    date = { day = 23 month = march year = 1766 }

    action_a = {
        name = "Провести реформы" # 
        command = { type = treasury value = 150 } # Lottery
        command = { type = domestic which = innovative value = 2 }
        command = { type = trigger which = 285072 } # The Esquilache riots
    }
    action_b = {
        name = "Отказаться от них" # Reject reforms
        command = { type = domestic which = innovative value = -1 } # triumph of anti-reformists
    }
}

# The Esquilache riots#
# by Fodoron with the help of the Spanish Forum
event = { 
    id = 285072 #triggered by SPA 285071
    random = no     
    country = SPA
    name = "Бунты из-за реформ Эсквиллаче"
    desc = "EVENTHIST285072"
    style = 1 
      
    action_a = { 
        name = "Плохо!"
        command = { type = stability value = -1 }
        command = { type = revolt which = -2 }
        command = { type = ADM which = -1 value = 12 }
    }
}

# Expulsion of the Jesuits #
# by Fodoron with the help of the Spanish Forum
event = { 
    id = 285073
    trigger = { event = 285072 } # The Esquilache riots
    random = no
    country = SPA
    name = "Изгнание иезуитов"
    desc = "EVENTHIST285073"
    style = 1

    date = { day = 2 month = april year = 1767 }

    action_a = {
        name = "Прогнать их" # do not expell them
        command = { type = treasury value = 100 }
        command = { type = domestic which = innovative value = 1 }
        command = { type = relation which = PAP value = -25 }
    }
    action_b = {
        name = "Нет, они нам ещё пригодятся" # 
        command = { type = relation which = PAP value = 25 }
    }
}

# The Honorable Council of the Mesta
# By Malatesta and Fodoron with the help of the Spanish forum #
event = {
    id = 285074
    random = no 
    country = SPA
    name = "Благородный Совет Месты"
    desc = "EVENTHIST285074"
    style = 1

    date = { day = 10 month = january year = 1492 }
    offset = 300
    deathdate = { day = 10 month = january year = 1493 }

    action_a = {
        name = "Поддержать Месту" # 
        command = { type = provincetax which = 435 value = 1 } # Leon
        command = { type = provincetax which = 436 value = 1 } # Castilla
        command = { type = provincetax which = 431 value = 1 } # Toledo
        command = { type = provincetax which = 440 value = 1 } # Extremadura
        command = { type = provincetax which = 1414 value = 1 }
        command = { type = domestic which = quality value = -1 }
        command = { type = domestic which = mercantilism value = 1 }
        command = { type = domestic which = aristocracy value = 1 }
                command = { type = domestic which = serfdom value = 2 }
        command = { type = land value = 500 }
        command = { type = infra value = -1000 }
        command = { type = trade value = 1000 }
        command = { type = merchants value = 3 }
        command = { type = treasury value = 200 }
    }
    action_b = {
        name = "Поддержать фермеров" #
        command = { type = population which = 436 value = 1000 } # Castilla
        command = { type = population which = 435 value = 1000 } # Leon
        command = { type = population which = 431 value = 1000 } # Toledo
        command = { type = population which = 440 value = 1000 } # Extremadura
        command = { type = population which = 1414 value = 1000 }
        command = { type = domestic which = serfdom value = -1 }
        command = { type = provincemanpower which = 435 value = 1 } # Leon
        command = { type = provincemanpower which = 436 value = 1 } # Castilla
        command = { type = provincemanpower which = 431 value = 1 } # Toledo
        command = { type = provincemanpower which = 440 value = 1 } # Extremadura
        command = { type = provincemanpower which = 1414 value = 1 }
        command = { type = trade value = -500 }
                command = { type = infra value = 500 }
        command = { type = merchants value = -3 }
    }
}

# the Treaty of Barcelona
# by Malatesta and Fodoron with the help of the Spanish forum
event = {           
    id = 285075
    trigger = {
        event = 17407 # SPA Sack of Rome
        exists = PAP
    }
    random = no     
    country = SPA
    name = "Барселонское соглашение"
    desc = "EVENTHIST285075"
    style = 1 
      
    date = { day = 29 month = june year = 1529 }
      
    action_a = {
        name = "Подписать соглашение" # sign the treaty
        command = { type = treasury value = 150 } 
        command = { type = dynastic which = PAP }
        command = { type = casusbelli which = TOS value = 60 } # Pope gives it
        command = { type = relation which = PAP value = 100 }
        command = { type = relation which = TOS value = -50 }
    }
    action_b = {
        name = "Отказаться от него" # reject the treaty
        command = { type = relation which = PAP value = -25 }
    }
}

#Philippines

event = {
    id = 285076
      trigger = { ai = no OR = { discovered = 692 discovered = 693 discovered = 691 discovered = 690 } owned = { province = 24 data = -1 } control = { province = 24 data = -1 }}
      random = no
    country = SPA
    name = "Завоевание Филиппин"
    desc = "В 1564 году, Мигель Легаспи отравляется с небольшой флотилией из порта Навидад, что в Мексике с инструкциями завоевать Филиппинские острова."
    date = { day = 20 month = november year = 1564 }
    offset = 60
    deathdate = { day = 1 month = january year = 1820 } 
    action_a ={ 
        name = "Поработить Филиппины"
        command = { type = warships which = 30 value = 5 }
            command = { type = transports which = 30 value = 8 }
            command = { type = INF which = 30 value = 6000 }
            command = { type = CAV which = 30 value = 2000 }
            command = { type = manpower value = -10 }
            command = { type = addcore which = 690 }
            command = { type = addcore which = 691 }
            command = { type = addcore which = 692 }
            command = { type = addcore which = 693 }
            command = { type = addcore which = 694 }
            command = { type = addcore which = 1823 }
            command = { type = addcore which = 1824 }
            command = { type = addcore which = 1741 }
           }
}

event = {
    id = 285077
      trigger = { ai = yes 
OR = { discovered = 1352 discovered = 1152 discovered = 1151 discovered = 1150 discovered = 1348 discovered = 1155 discovered = 1154 discovered = 1153 }
}
      random = no
    country = SPA
    name = "Завоевание Филиппин"
    desc = "В 1564 году, Мигель Легаспи отравляется с небольшой флотилией из порта Навидад, что в Мексике с инструкциями завоевать Филиппинские острова."
    date = { day = 20 month = november year = 1564 }
    offset = 60
    deathdate = { day = 1 month = january year = 1820 } 
    action_a ={ 
        name = "Поработить Филиппины"
            command = { type = manpower value = -10 }
            command = { type = addcore which = 690 }
            command = { type = addcore which = 691 }
            command = { type = addcore which = 692 }
            command = { type = addcore which = 693 }
            command = { type = addcore which = 694 }
            command = { type = addcore which = 1823 }
            command = { type = addcore which = 1824 }
            command = { type = addcore which = 1741 }
            command = { type = trigger which = 285078 }
            }
     }
}
event = {
    id = 285078
      trigger = { ai = yes }
      random = no
     country = U35
    name = "Испанское завоевание Филиппин"
    desc = "В XIV-XVI в.в. на Филиппинских островах существовало несколько феодальных княжеств, которые в 1565-71 годах подпали под власть Испании."
    action_a ={ 
        name = "Чёртовы испанцы"
        command = { type = secedeprovince which = SPA value = 691 }
        command = { type = secedeprovince which = SPA value = 690 }
        command = { type = secedeprovince which = SPA value = 692 }
        command = { type = secedeprovince which = SPA value = 1824 }

}
}


#
######################################################


event = {
      id = 285040
      trigger = { 
		event = 111005 #ARG: Inheritance of Navarra
		owned = { province = 428 data = -1 } #Navarra
		NOT = { exists = ARG }
	}
      random = no     
      country = SPA
      name = "War between Beaumont and Gramont continues"
      desc = "Since 1452 two factions led by hostile families, Beaumont and Gramont, waged a bloody, exhausting civil war in Navarra about the legimate succession to the throne, the one originally supporting John of Aragon, the other his son Carlos de Viana. This struggle continued after the death of Carlos in 1461 and even after the death of John when the Count of Foix inherited Navarra, preventing his coronation."
      style = 1 
      
      date = { day = 13 month = march year = 1479 }
      offset = 0
      
      action_a = {
               name = "Damn them"
               command = { type = removecore which = 428 } #Navarra
               command = { type = province_revoltrisk which = 428 value = 7 } 
               command = { type = revolt which = 428 }
                 }
}


 # The Castilian Protectorate of Navarra.
 # By Fodoron
event = { 								# triggered by NAV 241027
	id = 285041
	random = no
	country = SPA
	name = "The Castilian protectorate of Navarra"
	desc = "EVENTHIST285041"
	style = 2
      
	action_a = {
		name = "Наварра - наш вассал"
		command = { type = vassal which = NAV }
	}
}

 # The War of Navarra.
 # By Fodoron
event = {
	id = 285042
	random = no
	country = SPA
	name = "Покорение Наварры"
	desc = "EVENTHIST285042"
	style = 2
      
	action_a = {
		name = "Наварра - наша"
		command = { type = stability value = 1 }
		command = { type = inherit which = NAV } 
	}
}



event = {
id = 299892
	trigger ={
		atwar = yes
		}
	random = no
	country = SPA
	name = "Терцио"
	desc = "В конце 15-го начале 16 века во многочисленных войнах ведущихся Испанией, были созданы испанские терции - войска новой формации эфективно сочетающие таранный удар пикинеров и огонь стрелков. Полтора столетия слава Терций - как непривзойденных полков испанской пехоты - гремела в Европе.Закатом Терций стало поражений при Рокруа. (Не нереяйте Фландрию после 1640гг иначе эфеект обнулится.)"
	style = 3

	date = { day = 1 month = january year = 1480 }
	offset = 100
	deathdate = { day = 1 month = january year = 1530 }


	action_a ={			#Put it down!#
		name = "ACTIONNAME3169A"
		command = { type = INF which = -2 value = 8000 }
command = { type = INF which = -1 value = 6000 }
command = { type = INF which = -1 value = 6000 }
        command = { type = domestic which = OFFENSIVE value = 2 }
        command = { type = domestic which = QUALITY value = 3 }
        command = { type = domestic which = land value = 1 }
		
	}	
}


#Madrid by mfigueras, edited by barkdreg further modified by Fodoron
event = {
id = 285015
trigger = { 
	owned = { province = 436 data = -1 } 
	NOT = { event = 111024 } # CAS inherited by ARG
	}
random = no
country = SPA
name = "EVENTNAME285015"
desc = "EVENTHIST285015"

style = 2
date = {day = 1 month = april year = 1561}
offset = 300
deathdate = {day = 1 month = april year = 1591}

action_a = {  
name = "Мадрид"
		command = {type = capital which = 436}
		command = {type = cash value = -50}
		command = {type = population which = 436 value = 2500} # Madrid
		command = {type = provincetax which = 436 value = 2}
		command = {type = population which = 439 value = -2000} # Toledo
		command = {type = provincetax which = 439 value = -1}
		}
action_b = {    
name = "Толедо"
		command = {type = provincetax which = 439 value = 1}
		command = {type = population which = 439 value = 500}
		command = {type = vp value = -5}
		}
}

#madrid by barkdreg, based on event by mfigueras, further modified by Fodoron
event = {
id = 285016
trigger = { 
	owned = { province = 436 data = -1 } 
	NOT = {event = 142013} # ARG inherited by CAS
	}
random = no
country = SPA
name = "EVENTNAME285015"
desc = "EVENTHIST285015"
style = 2
date = {day = 1 month = april year = 1561}
offset = 300
deathdate = {day = 1 month = april year = 1591}

action_a = {
name = "Мадрид"
		command = {type = capital which = 436}
		command = {type = cash value = -50}
		command = {type = population which = 436 value = 2500} # Madrid
		command = {type = provincetax which = 436 value = 2}
		command = {type = population which = 429 value = -2000} # Catalonia
		command = {type = provincetax which = 429 value = -1}
		}
action_b = {
name = "Барселона"
		command = {type = provincetax which = 429 value = 1}
		command = {type = population which = 429 value = 500}
		command = {type = vp value = -5}
		}
}