add_namespace = dom

country_event = {
	id = dom.17
	title = dom.17.t
	desc = dom.17.d
	
	is_triggered_only = yes

	option = {
		name = dom.17.a
		ai_chance = {
			base = 80
		}
		complete_national_focus = DOM_stimulate_the_tobacco_economy
		hidden_effect = { country_event = { id = dom.18 days = 20 } }
	}
	
	option = {
		name = dom.17.b
		ai_chance = {
			base = 20
			modifier = {
				factor = 0 
				is_historical_focus_on = yes
			}
		}
		complete_national_focus = DOM_baezs_wild_ride
	}
}

country_event = {
	id = dom.18
	title = dom.18.t
	desc = dom.18.d
	
	is_triggered_only = yes

	option = {
		name = dom.18.a
		set_temp_variable = { money_to_gain = -0.5 }
		add_money_with_tooltip_effect = yes
		add_political_power = -750
		hidden_effect = { country_event = { id = dom.19 days = 7 } }
	}
	
}

country_event = {
	id = dom.19
	hidden = yes
	
	is_triggered_only = yes
	
	immediate = {
		hidden_effect = {
			DOM = {
				if = {
					limit = { 
						DOM = { 
							owns_state = 319
							owns_state = 1318
						}
					}
					set_global_flag = DOM_1857_tobacco_coup_flag
					DOM = { 
						set_politics = { ruling_party = radical_democracy }
						hidden_effect = { country_event = { id = dom.20 hours = 1 } }
					}
				}
			}
		}
	}
}

country_event = {
	id = dom.20
	hidden = yes
	
	is_triggered_only = yes
	
	immediate = {
		hidden_effect = {
			DOM = {
				remove_country_leader_role = {
					character = DOM_Buenaventura_Baez
					Ideology = conserv
				}
				set_capital = { state = 319 }
				start_civil_war = {
					ruling_party = radical_democracy
					ideology = traditional_conservatism
					size = 0
					capital = 1318
					states = { 
						1318
					}
					#keep_unit_leaders = {
					#	
					#}
					keep_political_leader = yes
					keep_political_party_members = yes
				}
				319 = { OWNER = { hidden_effect = { country_event = { id = dom.21 hours = 1 } } } }
			}
			DOM = { 
				add_ai_strategy = {
					type = area_priority
					id = caribbean
					value = 200
				}
				add_ai_strategy = {
					type = garrison
					value = -100
				}
				#add_ai_strategy = {
				#	type = garrison
				#	id = caribbean
				#	value = -100
				#}
			}
		}
	}
}

country_event = {
	id = dom.21
	hidden = yes
	
	is_triggered_only = yes
	
	immediate = {
		hidden_effect = {
			319 = {
				OWNER = {
					#set_politics = { ruling_party = traditional_conservatism }
					set_popularities = {
						anarchism = 0
						ideology_social_liberalism = 5
						ideology_radical_socialism = 0
						social_egalitarianism = 0
						centrism = 15 
						traditional_conservatism = 25
						radical_democracy = 40
						chauvinist_populism = 0
						autocracy = 15
						fundamentalism = 0
					}
					set_stability = 0.6
					set_war_support = 0
					#set_political_power = 0
					#add_ideas = no_constitution
					#swap_ideas = {
					#	remove_idea = presidential_republic
					#	add_idea = military_junta
					#}
					hidden_effect = { country_event = { id = dom.22 hours = 1 } }
				}
			}
		}
	}
}

country_event = {
	id = dom.22
	title = dom.22.t
	desc = dom.22.d
	
	is_triggered_only = yes
	
	immediate = {
		hidden_effect = {
			319 = { 
				OWNER = { 
					division_template = {
						name = "Valverde's Militia"
						priority = 1
						regiments = {
							line_infantry = { x = 0 y = 0 }
							line_infantry = { x = 1 y = 0 }
						}
						is_locked = yes
					}
					319 = {
						create_unit = {
							division = "name = \"Valverde's Militia\" division_template = \"Valverde's Militia\" start_experience_factor = 0.6 start_equipment_factor = 1" 
							owner = PREV
						}
						create_unit = {
							division = "name = \"Valverde's Militia\" division_template = \"Valverde's Militia\" start_experience_factor = 0.6 start_equipment_factor = 1" 
							owner = PREV
						}
					}
				}
			}
			1318 = { 
				OWNER = { 
					 ROOT = { 
						#add_ai_strategy = {    THIS HAS BEEN COMMENTED OUT DUE TO ERROS AND BECAUSE I DONT LIKE IT
						#	 type = front_control
						#
						#	 #you can define a target in following ways. you can define more than one
						#
						#	 tag = PREV 							# target against a specific country
						#	 state = 1318 						# target on a state
						#	 strategic_region = 53				# target on a strategic region
						#	 area = caribbean					# target on a specific ai area
						#	 #country_trigger = { always = no } 	# a trigger to check agaisnt a specific country. scope is enemy country from scope is our country
						#	 #state_trigger = { always = no } 	# a trigger to check agaisnt a state. scope is state. from scope is enemy country from.from scope is our country
						#
						#	 ratio = 0.0 						# the strategy is enabled only if ratio of the front covered by this strat's targets greater than this ratio
						#
						#	 priority = 200 						# default 0, higher prio strats will override lower
						#	 ordertype = front 					# front or invasion. if set this strategy will only apply to that specific order type
						#	 execution_type = rush 				# one of careful balanced rush rush_weak. if set will override the execution type of front (only for front orders)
						#	 execute_order = yes 				# yes or no. if set will override execute or not decision of front
						#	 manual_attack = yes 				# default yes. if no ai will not do manual pokes at enemy (only for front orders)
						#}
					 }
					#add_ideas = limited_constitution
					generate_character = {
						token_base = DOM_Buenaventura_Baez_temp
						name = DOM_Buenaventura_Baez_temp
						portraits={
							civilian={
								large = "GFX_Portrait_DOM_Buenaventura_Baez"
							}
						}
					}
					add_country_leader_role = {
						Character = DOM_Buenaventura_Baez_temp
						Promote_leader = yes
						Country_leader = {
							ideology = conserv
							expire = "1903.12.22"
						}
					}
					promote_character = DOM_Buenaventura_Baez_temp
					promote_character = {
						character = DOM_Buenaventura_Baez_temp
						Ideology = conserv
					}
					set_country_leader_portrait = {
						portrait = GFX_Portrait_DOM_Buenaventura_Baez
					}
					#add_ideas = presidential_republic
					division_template = {
						name = "Buenaventura's Guards"
						priority = 1
						regiments = {
							line_infantry = { x = 0 y = 0 }
						}
						is_locked = yes
					}
					1318 = {
						create_unit = {
							division = "name = \"Buenaventura's Guards\" division_template = \"Buenaventura's Guards\" start_experience_factor = 0.04 start_equipment_factor = 1" 
							owner = PREV
							prioritize_location = 7660
						}
					}
				}
			}
		}
	}

	option = {
		name = dom.22.a
		add_country_leader_role = {
			Character = DOM_Jose_Desiderio_Valverde
			Promote_leader = yes
			Country_leader = {
				ideology = military_junta
				expire = "1903.12.22"
			}
		}
		promote_character = {
			character = DOM_Jose_Desiderio_Valverde
			Ideology = military_junta
		}
		complete_national_focus = DOM_depose_el_presidente
		add_war_support = 0.55
		add_command_power = 150
		custom_effect_tooltip = DOM_1857_tobacco_coup_cibao_tobacco_planters
		319 = { 
			add_extra_state_shared_building_slots = 1
			add_building_construction = {
				type = farm
				level = 1
				instant_build = yes
			}
		}
		add_ideas = DOM_valverdes_plan
	}
}

country_event = {
	id = dom.23
	title = dom.23.t
	desc = dom.23.d
	
	is_triggered_only = yes
	
	immediate = {
		hidden_effect = {
			DOM = { 
				remove_ideas = DOM_valverdes_plan
				#add_ideas = limited_constitution
				delete_unit_template_and_units = { division_template = "Valverde's Militia" disband = no }
				country_event = { id = dom.24 days = 7 }
			}
		}
	}
	
	option = {
		name = dom.23.a
		#hidden_effect = { retire_country_leader = yes }
		complete_national_focus = DOM_the_new_liberal_state
		#swap_ideas = {
		#	remove_idea = military_junta
		#	add_idea = presidential_republic
		#}
		set_politics = { ruling_party = ideology_social_liberalism }
		add_country_leader_role = {
			Character = DOM_Jose_Desiderio_Valverde
			Promote_leader = yes
			Country_leader = {
				ideology = ideology_sub_social_liberal
				expire = "1903.12.22"
			}
		}
		promote_character = DOM_Jose_Desiderio_Valverde
		promote_character = {
			character = DOM_Jose_Desiderio_Valverde
			Ideology = ideology_sub_social_liberal
		}
		set_temp_variable = { money_to_gain = -0.5 }
		add_money_with_tooltip_effect = yes
		hidden_effect = { country_event = { id = dom.25 days = 330 } }
	}
	
}

country_event = {
	id = dom.24
	title = dom.24.t
	desc = dom.24.d
	
	is_triggered_only = yes
	fire_only_once = yes

	option = {
		name = dom.24.a
		add_ideas = DOM_santanas_military
		add_field_marshal_role = {
			Character = DOM_Pedro_Santana
			skill = 4
			attack_skill = 2
			defense_skill = 3
			planning_skill = 3
			logistics_skill = 5
		}
	}
}

country_event = {
	id = dom.25
	title = dom.25.t
	desc = dom.25.d
	
	is_triggered_only = yes
	fire_only_once = yes
	
	immediate = { hidden_effect = { ROOT = { complete_national_focus = DOM_the_question_of_the_military } } }

	option = {
		name = dom.25.a
		ai_chance = { 
			factor = 70 
		
		}
		hidden_effect = { 
			country_event = { id = dom.26 days = 15 } 
			DOM = { set_country_flag = DOM_1858_santana_coup_flag }
		}
		complete_national_focus = DOM_reduce_santanas_control
	}
	
	option = {
		name = dom.25.b
		trigger = { DOM = { NOT = { has_country_flag = DOM_1858_santana_coup_flag } } }
		ai_chance = { 
			factor = 30 
			modifier = {
				factor = 0 
				is_historical_focus_on = yes
			}
		}
		complete_national_focus = DOM_santanas_military_focus
	}
}

country_event = {
	id = dom.26
	title = dom.26.t
	desc = dom.26.d
	
	is_triggered_only = yes
	fire_only_once = yes
	
	trigger = { 
		is_subject = no 
	}
	
	immediate = { DOM = { clr_country_flag = DOM_1858_santana_coup_flag } }

	option = {
		name = dom.26.a
		ai_chance = { 
			factor = 75 
			modifier = {
				factor = 0 
				is_historical_focus_on = yes
			}
		}
		remove_country_leader_role = {
			character = DOM_Jose_Desiderio_Valverde
			ideology = ideology_sub_social_liberal
		}
		complete_national_focus = DOM_follow_el_general
		#retire_country_leader = yes
		set_politics = { ruling_party = traditional_conservatism }
		set_capital = { state = 1318 }
		add_country_leader_role = {
			Character = DOM_Pedro_Santana
			Promote_leader = yes
			Country_leader = {
				ideology = conserv
				expire = "1890.7.2"
			}
		}
		promote_character = DOM_Pedro_Santana
		promote_character = {
			character = DOM_Pedro_Santana
			Ideology = conserv
		}
		hidden_effect = { country_event = { id = dom.32 days = 15 } }
	}
	
	option = {
		name = dom.26.b
		ai_chance = { 
			factor = 25 
		}
		complete_national_focus = DOM_follow_el_presidente
		set_capital = { state = 319 }
		DOM_Pedro_Santana = {
			remove_unit_leader_role = yes
		}
		start_civil_war = {
			ruling_party = centrism
			ideology = radical_democracy
			size = 1
			capital = 1318
			states = { 
				1318
			}
			#keep_unit_leaders = {
			#	
			#}
			keep_political_leader = yes
		}
		hidden_effect = {
			#1318 = { OWNER = { set_variable = { THIS.debt_level = ROOT.debt_level } } }
			set_global_flag = DOM_1858_santana_coup_flag
			USA = { country_event = { id = dom.27 } }
		}
	}
}

country_event = {
	id = dom.27
	title = dom.27.t
	desc = dom.27.d
	
	is_triggered_only = yes
	
	immediate = {
		hidden_effect = {
			319 = {
				OWNER = { 
					#add_ideas = presidential_republic
					division_template = {
						name = "Valverde's Guards"
						priority = 1
						regiments = {
							line_infantry = { x = 0 y = 0 }
							line_infantry = { x = 1 y = 0 }
						}
						is_locked = yes
					}
					319 = {
						create_unit = {
							division = "name = \"Valverde's Guards\" division_template = \"Valverde's Guards\" start_experience_factor = 0.3 start_equipment_factor = 1" 
							owner = PREV
						}
						create_unit = {
							division = "name = \"Valverde's Guards\" division_template = \"Valverde's Guards\" start_experience_factor = 0.3 start_equipment_factor = 1" 
							owner = PREV
						}
					}
				}
			}
			1318 = {
				OWNER = {
					 ROOT = { 
						#add_ai_strategy = {   ### NOT SET UP CORRECT, DONT LIKE IT ANYWAY
						#	 type = front_control
						#
						#	 #you can define a target in following ways. you can define more than one
						#
						#	 tag = PREV 							# target against a specific country
						#	 state = 1318 						# target on a state
						#	 strategic_region = 53				# target on a strategic region
						#	 area = caribbean					# target on a specific ai area
						#	 #country_trigger = { always = no } 	# a trigger to check agaisnt a specific country. scope is enemy country from scope is our country
						#	 #state_trigger = { always = no } 	# a trigger to check agaisnt a state. scope is state. from scope is enemy country from.from scope is our country
						#
						#	 ratio = 0.0 						# the strategy is enabled only if ratio of the front covered by this strat's targets greater than this ratio
						#
						#	 priority = 200 						# default 0, higher prio strats will override lower
						#	 ordertype = front 					# front or invasion. if set this strategy will only apply to that specific order type
						#	 execution_type = balanced 			# one of careful balanced rush rush_weak. if set will override the execution type of front (only for front orders)
						#	 execute_order = yes 				# yes or no. if set will override execute or not decision of front
						#	 manual_attack = yes 				# default yes. if no ai will not do manual pokes at enemy (only for front orders)
						#}
					 }
					#add_ideas = limited_constitution
					set_politics = { ruling_party = radical_democracy }
					generate_character = {
						token_base = DOM_Pedro_Santana_temp
						name = DOM_Pedro_Santana_temp
						portraits={
							civilian={
								large = GFX_Portrait_DOM_Pedro_Santana
							}
						}
					}
					add_country_leader_role = {
						Character = DOM_Pedro_Santana_temp
						Promote_leader = yes
						Country_leader = {
							ideology = military_junta
							expire = "1903.12.22"
						}
					}
					add_field_marshal_role = {
						Character = DOM_Pedro_Santana_temp
						skill = 4
						attack_skill = 2
						defense_skill = 3
						planning_skill = 3
						logistics_skill = 5
					}
					promote_character = DOM_Pedro_Santana_temp
					promote_character = {
						character = DOM_Pedro_Santana_temp
						Ideology = military_junta
					}
					set_country_leader_portrait = {
						portrait = GFX_Portrait_DOM_Pedro_Santana
					}
					#add_ideas = military_junta
					division_template = {
						name = "Santana's Army"
						priority = 1
						regiments = {
							line_infantry = { x = 0 y = 0 }
							line_infantry = { x = 1 y = 0 }
						}
						is_locked = yes
					}
					1318 = {
						create_unit = {
							division = "name = \"Santana's Army\" division_template = \"Santana's Army\" start_experience_factor = 0.6 start_equipment_factor = 1" 
							owner = PREV
						}
						create_unit = {
							division = "name = \"Santana's Army\" division_template = \"Santana's Army\" start_experience_factor = 0.6 start_equipment_factor = 1" 
							owner = PREV
						}
						create_unit = {
							division = "name = \"Santana's Army\" division_template = \"Santana's Army\" start_experience_factor = 0.6 start_equipment_factor = 1" 
							owner = PREV
						}
					}
				}
			}
		}
	}
	
	option = {
		name = dom.27.a
		ai_chance = { factor = 100 }
		319 = { OWNER = { country_event = { id = dom.28 days = 1 } } }
		add_political_power = 100
		
	}
	
	option = {
		name = dom.27.b
		ai_chance = { factor = 0 }
		
	}
}

country_event = {
	id = dom.28
	title = dom.28.t
	desc = dom.28.d
	
	is_triggered_only = yes
	
	immediate = { hidden_effect = { complete_national_focus = DOM_valverdes_last_gambit } }

	option = {
		name = dom.28.a
		ai_chance = { factor = 100 }
		set_temp_variable = { money_to_gain = -0.5 }
		add_money_with_tooltip_effect = yes
		add_equipment_to_stockpile = {
			type = infantry_equipment_rifle_1
			amount = 250
			producer = USA
		}
		add_equipment_to_stockpile = {
			type = uniform_equipment_2
			amount = 250
			producer = USA
		}
	}
	
	option = {
		name = dom.28.b
		ai_chance = { factor = 100 }
		 
		add_equipment_to_stockpile = {
			type = infantry_equipment_rifle_1
			amount = 250
			producer = USA
		}
		add_equipment_to_stockpile = {
			type = uniform_equipment_2
			amount = 250
			producer = USA
		}
		FROM = { country_event = { id = dom.29 } }
	}
	
	option = {
		name = dom.28.c
		ai_chance = { factor = 0 }
		set_temp_variable = { money_to_gain = -0.5 }
		add_money_with_tooltip_effect = yes
	}
}

country_event = {
	id = dom.29
	title = dom.29.t
	desc = dom.29.d
	
	is_triggered_only = yes
	
	option = {
		name = dom.29.a
		ai_chance = { factor = 100 }
		add_political_power = 200
		FROM = { country_event = { id = dom.30 days = 3 } }
	}
}

country_event = {
	id = dom.30
	title = dom.30.t
	desc = dom.30.d
	
	is_triggered_only = yes
	
	option = {
		name = dom.30.a
		ai_chance = { factor = 100 }
		hidden_effect = {
			division_template = {
				name = "US Marines"
				priority = 1
				regiments = {
					early_marine = { x = 0 y = 0 }
					early_marine = { x = 0 y = 1 }
					early_marine = { x = 1 y = 0 }
					early_marine = { x = 1 y = 1 }
				}
				is_locked = yes
			}
		}
		random_owned_state = {
			create_unit = {
				division = "name = \"US Marines\" division_template = \"US Marines\" start_experience_factor = 1 start_equipment_factor = 1" 
				owner = ROOT
			}
		}
	}
}

country_event = {
	id = dom.37
	hidden = yes
	
	is_triggered_only = yes
	
	immediate = {
		ROOT = {
			annex_country = {
				target = FROM
				transfer_troops = yes
			}
			remove_country_leader_role = {
				character = DOM_Jose_Desiderio_Valverde
				ideology = ideology_sub_social_liberal
			}
			#set_political_power = 0
			set_politics = { ruling_party = radical_democracy }
			#add_ideas = military_junta
			#add_ideas = no_constitution
			add_country_leader_role = {
				Character = DOM_Pedro_Santana
				Promote_leader = yes
				Country_leader = {
					ideology = authoritarian_democracy
					expire = "1890.7.2"
				}
			}
			add_field_marshal_role = {
				Character = DOM_Pedro_Santana
				skill = 4
				attack_skill = 2
				defense_skill = 3
				planning_skill = 3
				logistics_skill = 5
			}
			promote_character = DOM_Pedro_Santana
			DOM_Pedro_Santana = {
				promote_character = authoritarian_democracy
			}
			set_capital = { state = 1318 }
			country_event = { id = dom.32 days = 6 }
		}
	}
}

country_event = {
	id = dom.31
	title = dom.31.t
	desc = dom.31.d
	
	is_triggered_only = yes
	
	option = {
		name = dom.31.a
		ai_chance = { factor = 100 }
		delete_unit_template_and_units = { division_template = "US Marines" disband = no }
	}
}

country_event = {
	id = dom.32
	title = dom.32.t
	desc = dom.32.d
	
	is_triggered_only = yes
	
	
	option = {
		name = dom.32.a
		ai_chance = { factor = 100 }
		complete_national_focus = DOM_our_new_presidente
		#swap_ideas = {
		#	add_idea = limited_constitution
		#	remove_idea = no_constitution
		#}
		#swap_ideas = {
		#	add_idea = semi_presidential_republic
		#	remove_idea = military_junta
		#}
		hidden_effect = { country_event = { id = dom.33 days = 9 } }
	}
}

country_event = {
	id = dom.33
	title = dom.33.t
	desc = dom.33.d
	
	is_triggered_only = yes
	
	option = {
		name = dom.33.a
		ai_chance = { factor = 100 }
		if = {
			limit = { NOT = { has_idea = law_spending_level_3 } }
			swap_ideas = {
				add_idea = law_spending_level_3
				remove_idea = law_spending_level_5
			}
		}
		if = {
			limit = { has_idea = kangaroo_court }
			swap_ideas = {
				add_idea = biased_courtroom
				remove_idea = kangaroo_court
			}
			add_political_power = -150
		}
		else_if = {
			limit = { has_idea = high_judge_courtroom }
			swap_ideas = {
				add_idea = biased_courtroom
				remove_idea = high_judge_courtroom
			}
			add_political_power = -150
		}
		else_if = {
			limit = { has_idea = quasi_jury_court }
			swap_ideas = {
				add_idea = biased_courtroom
				remove_idea = quasi_jury_court
			}
			add_political_power = -150
		}
		else_if = {
			limit = { has_idea = jury_court }
			swap_ideas = {
				add_idea = biased_courtroom
				remove_idea = jury_court
			}
			add_political_power = -150
		}
		hidden_effect = { country_event = { id = dom.34 days = 30 } }
	}
}

country_event = {
	id = dom.34
	title = dom.34.t
	desc = dom.34.d
	
	is_triggered_only = yes
	
	option = {
		name = dom.34.a
		ai_chance = { factor = 100 }
		if = {
			limit = { NOT = { has_idea = foa_banned } }
			swap_ideas = {
				add_idea = foa_banned
				remove_idea = foa_free_assembly
			}
		}
		if = {
			limit = { has_idea = free_press }
			swap_ideas = {
				add_idea = state_controlled_press
				remove_idea = free_press
			}
			add_political_power = 50
		}
		else_if = {
			limit = { has_idea = censored_press }
			swap_ideas = {
				add_idea = state_controlled_press
				remove_idea = censored_press
			}
			add_political_power = 50
		}
		if = {
			limit = { NOT = { has_idea = tu_prohibited } }
			swap_ideas = {
				add_idea = tu_prohibited
				remove_idea = tu_non_political
			}
			add_political_power = 50
		}
		hidden_effect = { country_event = { id = dom.35 days = 7 } }
	}
}

country_event = {
	id = dom.35
	title = dom.35.t
	desc = dom.35.d
	
	is_triggered_only = yes
	
	option = {
		name = dom.35.a
		ai_chance = { factor = 100 }
		complete_national_focus = DOM_santanas_military_budget_reforms
		hidden_effect = { country_event = { id = dom.36 days = 5 } }
	}
}

country_event = {
	id = dom.36
	title = dom.36.t
	desc = dom.36.d
	
	is_triggered_only = yes
	
	option = {
		name = dom.36.a
		ai_chance = { factor = 100 }
		complete_national_focus = DOM_santanas_recruitment_reforms
		add_equipment_to_stockpile = {
			type = infantry_equipment_rifle_1
			amount = 4000
			producer = DOM
		}
		add_equipment_to_stockpile = {
			type = uniform_equipment_2
			amount = 4000
			producer = DOM
		}
		set_temp_variable = { money_to_gain = -0.5 }
		add_money_with_tooltip_effect = yes
	}
}


country_event = {
	id = dom.47
	title = dom.47.t
	desc = dom.47.d
	
	is_triggered_only = yes

	option = {
		name = dom.47.a
		ai_chance = { factor = 100 }
	}
}

country_event = {
	id = dom.48
	title = dom.48.t
	desc = {
		text = dom.48.desc_1
		trigger = { 
			NOT = { 
				AND = {
					has_country_flag = SPR_hispaniola_declined
					has_country_flag = USA_hispaniola_declined
					has_country_flag = FRA_hispaniola_declined
				}
			}
		}
	}
	desc = {
		text = dom.48.desc_2
		trigger = { 
			has_country_flag = SPR_hispaniola_declined
			has_country_flag = USA_hispaniola_declined
			has_country_flag = FRA_hispaniola_declined
		}
	}
	
	is_triggered_only = yes

	option = {
		name = dom.48.a
		trigger = { NOT = { has_country_flag = SPR_hispaniola_declined } }
		ai_chance = { factor = 70 }
		SPR = { country_event = { id = dom.39 days = 3 } }
	}
	
	option = {
		name = dom.48.b
		trigger = { NOT = { has_country_flag = USA_hispaniola_declined } }
		ai_chance = { 
			factor = 30 
			modifier = {
				factor = 0 
				is_historical_focus_on = yes
			}
		}
		USA = { country_event = { id = dom.13 days = 3 } }
	}
	
	option = {
		name = dom.48.c
		trigger = { NOT = { has_country_flag = FRA_hispaniola_declined } }
		ai_chance = { 
			factor = 10 
			modifier = {
				factor = 0 
				is_historical_focus_on = yes
			}
		}
		FRA = { country_event = { id = dom.1 days = 3 } }
	}
	
	option = {
		name = dom.48.d
		trigger = { 
			has_country_flag = SPR_hispaniola_declined
			has_country_flag = USA_hispaniola_declined
			has_country_flag = FRA_hispaniola_declined
		}
		ai_chance = { factor = 100 }
	}
}

country_event = {
	id = dom.38
	title = dom.38.t
	desc = dom.38.d

	fire_only_once = yes
	is_triggered_only = yes
	
	#trigger = {
		#TAG = DOM
		#date > 1861.3.18
		#USA = {
		#	has_war_with = CSA
		#}
	#}
	
	option = {
		name = dom.38.a
		trigger = { SPR = { set_temp_variable = { loan_size_to_check = 200}
			has_less_than_specific_loan_size = yes } }
		ai_chance = { 
			base = 0 
			modifier = {
				add = 30
				has_country_leader = { name = "Buenaventura Báez" ruling_only = yes }
			}
			modifier = {
				add = 90
				has_country_leader = { name = "Jose Desiderio Valverde" ruling_only = yes }
			}
			modifier = {
				add = 85
				has_country_leader = { name = "Pedro Santana" ruling_only = yes }
			}
			modifier = {
				add = 100 
				OR = {
					has_country_leader = { name = "Jose Desiderio Valverde" ruling_only = yes }
					has_country_leader = { name = "Pedro Santana" ruling_only = yes }
				}
				is_historical_focus_on = yes
			}
		}
		SPR = { country_event = { id = dom.39 days = 3 } }
	}
	
	option = {
		name = dom.38.b
		trigger = { 
			USA = { NOT = { has_country_flag = USA_American_Civil_War } }
			USA  = { set_temp_variable = { loan_size_to_check = 200}
			has_less_than_specific_loan_size = yes }
		}
		ai_chance = {
			base = 0 
			modifier = {
				add = 60
				has_country_leader = { name = "Buenaventura Báez" ruling_only = yes }
			}
			modifier = {
				add = 5
				has_country_leader = { name = "Jose Desiderio Valverde" ruling_only = yes }
			}
			modifier = {
				add = 10
				has_country_leader = { name = "Pedro Santana" ruling_only = yes }
			}
			modifier = {
				factor = 0 
				is_historical_focus_on = yes
			}
		}
		USA = { country_event = { id = dom.13 days = 3 } }
	}
	
	option = {
		name = dom.38.c
		trigger = { FRA = { set_temp_variable = { loan_size_to_check = 200}
			has_less_than_specific_loan_size = yes } }
		ai_chance = {
			base = 0 
			modifier = {
				add = 10
				has_country_leader = { name = "Buenaventura Báez" ruling_only = yes }
			}
			modifier = {
				add = 5
				has_country_leader = { name = "Jose Desiderio Valverde" ruling_only = yes }
			}
			modifier = {
				add = 5
				has_country_leader = { name = "Pedro Santana" ruling_only = yes }
			}
			modifier = {
				factor = 0 
				is_historical_focus_on = yes
			}
		}
		FRA = { country_event = { id = dom.1 days = 3 } }
	}
}

country_event = {
	id = dom.13
	title = dom.13.t
	desc = dom.13.d

	is_triggered_only = yes
	
	
	option = {
		name = dom.13.a
		ai_chance = {
			base = 100 
			modifier = {
				add = -100 
				USA = {
					OR = {
						has_idea = USA_1857Panic1
						has_idea = USA_1857Panic2
						has_idea = USA_1857Panic3
						has_idea = USA_1857Panic4
					}
				}
			}
			modifier = {
				factor = 0 
				is_historical_focus_on = yes
			}
		}
		hidden_effect = { SPR = { remove_opinion_modifier = { target = DOM modifier = defaulted_on_loan } } }
		#if = {
		#	limit = { 
		#		FROM = { is_ai = yes } 
		#	}
		#	annex_country = {
		#		target = DOM
		#		transfer_troops = yes
		#	}
		#	#hidden_effect = { load_oob = "DOM_SPAIN_1861" }
		#}
		#else = {
			ROOT = {
				hidden_effect = { FROM = { store_current_ideologies = yes } }
				set_autonomy = {
					target = FROM
					autonomy_state = autonomy_organized_unincorporated_territory
					freedom_level = 0.5
				}
				hidden_effect = { FROM = { load_prevous_ideologies = yes } }
			}
			hidden_effect = { FROM = { load_oob = "DOM_SPAIN_1861" } }
			if = {
				limit = { USA = { has_country_flag = USAPanic_Of_1857 } }
				set_temp_variable = { money_to_gain = -0.5 }
				add_money_with_tooltip_effect = yes 
			}
			else = {   
				set_temp_variable = { money_to_gain = -0.5 }
				add_money_with_tooltip_effect = yes
			}
			hidden_effect = { ROOT = { country_event = { id = dom.14 days = 7 } } }
			hidden_effect = { DOM = { add_ideas = taxation_level_3 } }
			hidden_effect = { DOM = { set_variable = { most_favoured_country = USA.id } } }
		#}
		
	}
	
	option = {
		name = dom.13.b
		ai_chance = { 
			base = 100 
			modifier = {
				add = 100 
				USA = {
					OR = {
						has_idea = USA_1857Panic1
						has_idea = USA_1857Panic2
						has_idea = USA_1857Panic3
						has_idea = USA_1857Panic4
					}
				}
			}
		}
		FROM = { country_event = { id = dom.48 days = 3 } }
		hidden_effect = {
			FROM = { set_country_flag = USA_hispaniola_declined }
		}
	}
}

country_event = {
	id = dom.14
	title = dom.14.t
	desc = dom.14.d

	is_triggered_only = yes
	
	trigger = { DOM = { is_subject_of = ROOT } }
	
	immediate = { hidden_effect = { ROOT = { country_event = { id = dom.14 days = 1460 } } } }
	
	option = {
		name = dom.14.a
		ai_chance = {
			base = 75 
			modifier = {
				add = -25 
				DOM = {
					OR = {
						has_country_leader = { name = "Buenaventura Báez" ruling_only = yes }
						has_country_leader = { name = "Jose Desiderio Valverde" ruling_only = yes }
						has_country_leader = { name = "Pedro Santana" ruling_only = yes }
					}
				}
			}
		}
		DOM = {
			if = {
				limit = { ROOT = { has_government = anarchism } }
				retire_country_leader = yes
				hidden_effect = { 
					set_politics = { ruling_party = anarchism }
					retire_country_leader = yes
				}
			}
			else_if = {
				limit = { ROOT = { has_government = ideology_social_liberalism } }
				retire_country_leader = yes
				hidden_effect = { 
					set_politics = { ruling_party = ideology_social_liberalism }
					retire_country_leader = yes
				}
			}
			else_if = {
				limit = { ROOT = { has_government = ideology_radical_socialism } }
				retire_country_leader = yes
				hidden_effect = { 
					set_politics = { ruling_party = ideology_radical_socialism }
					retire_country_leader = yes
				}
			}
			else_if = {
				limit = { ROOT = { has_government = social_egalitarianism } }
				retire_country_leader = yes
				hidden_effect = { 
					set_politics = { ruling_party = social_egalitarianism }
					retire_country_leader = yes
				}
			}
			else_if = {
				limit = { ROOT = { has_government = centrism } }
				retire_country_leader = yes
				hidden_effect = { 
					set_politics = { ruling_party = centrism }
					retire_country_leader = yes
				}
			}
			else_if = {
				limit = { ROOT = { has_government = traditional_conservatism } }
				retire_country_leader = yes
				hidden_effect = { 
					set_politics = { ruling_party = traditional_conservatism }
					retire_country_leader = yes
				}
			}
			else_if = {
				limit = { ROOT = { has_government = radical_democracy } }
				retire_country_leader = yes
				hidden_effect = { 
					set_politics = { ruling_party = radical_democracy }
					retire_country_leader = yes
				}
			}
			else_if = {
				limit = { ROOT = { has_government = chauvinist_populism } }
				retire_country_leader = yes
				hidden_effect = { 
					set_politics = { ruling_party = chauvinist_populism }
					retire_country_leader = yes
				}
			}
			else_if = {
				limit = { ROOT = { has_government = autocracy } }
				retire_country_leader = yes
				hidden_effect = { 
					set_politics = { ruling_party = autocracy }
					retire_country_leader = yes
				}
			}
			else_if = {
				limit = { ROOT = { has_government = fundamentalism } }
				retire_country_leader = yes
				hidden_effect = { 
					set_politics = { ruling_party = fundamentalism }
					retire_country_leader = yes
				}
			}
		}
		hidden_effect = { DOM = { country_event = { id = dom.15 days = 3 } } }
	}
	
	option = {
		name = dom.14.b
		ai_chance = { 
			base = 25 
			modifier = {
				add = 25 
				DOM = {
					OR = {
						has_country_leader = { name = "Buenaventura Báez" ruling_only = yes }
						has_country_leader = { name = "Jose Desiderio Valverde" ruling_only = yes }
						has_country_leader = { name = "Pedro Santana" ruling_only = yes }
					}
				}
			}
		}
		hidden_effect = { DOM = { country_event = { id = dom.16 days = 3 } } }
	}
}

country_event = {
	id = dom.15
	title = dom.15.t
	desc = dom.15.d

	is_triggered_only = yes
	
	
	option = {
		name = dom.15.a
		ai_chance = { base = 100 }
		add_political_power = 25
		ROOT = {
			if = {
				limit = { FROM = { has_government = anarchism } }
				add_popularity = { ideology = anarchism popularity = 0.05 }
			}
			else_if = {
				limit = { FROM = { has_government = ideology_social_liberalism } }
				add_popularity = { ideology = ideology_social_liberalism popularity = 0.05 }
			}
			else_if = {
				limit = { FROM = { has_government = ideology_radical_socialism } }
				add_popularity = { ideology = ideology_radical_socialism popularity = 0.05 }
			}
			else_if = {
				limit = { FROM = { has_government = social_egalitarianism } }
				add_popularity = { ideology = social_egalitarianism popularity = 0.05 }
			}
			else_if = {
				limit = { FROM = { has_government = centrism } }
				add_popularity = { ideology = centrism popularity = 0.05 }
			}
			else_if = {
				limit = { FROM = { has_government = traditional_conservatism } }
				add_popularity = { ideology = traditional_conservatism popularity = 0.05 }
			}
			else_if = {
				limit = { FROM = { has_government = radical_democracy } }
				add_popularity = { ideology = radical_democracy popularity = 0.05 }
			}
			else_if = {
				limit = { FROM = { has_government = chauvinist_populism } }
				add_popularity = { ideology = chauvinist_populism popularity = 0.05 }
			}
			else_if = {
				limit = { FROM = { has_government = autocracy } }
				add_popularity = { ideology = autocracy popularity = 0.05 }
			}
			else_if = {
				limit = { FROM = { has_government = fundamentalism } }
				add_popularity = { ideology = fundamentalism popularity = 0.05 }
			}
		}
	}
}

country_event = {
	id = dom.16
	title = dom.16.t
	desc = dom.16.d

	is_triggered_only = yes
	
	
	option = {
		name = dom.16.a
		ai_chance = { base = 100 }
		add_political_power = 100
	}
}

country_event = {
	id = dom.1
	title = dom.1.t
	desc = dom.1.d

	is_triggered_only = yes
	
	
	option = {
		name = dom.1.a
		ai_chance = { 
			base = 100 
			modifier = {
				factor = 0 
				is_historical_focus_on = yes
			}
		}
		hidden_effect = { SPR = { remove_opinion_modifier = { target = DOM modifier = defaulted_on_loan } } }
		if = {
			limit = { 
				FROM = { 
					is_ai = yes 
				} 
			}
			annex_country = {
				target = DOM
				transfer_troops = yes
			}
			hidden_effect = { load_oob = "DOM_SPAIN_1861" }
		}
		else = {
			ROOT = {
				hidden_effect = { FROM = { store_current_ideologies = yes } }
				hidden_effect = { FROM = { add_ideas = AFR_french_colony } }
				set_autonomy = {
					target = FROM
					autonomy_state = autonomy_afr_colony
					freedom_level = 0.5
				}
				hidden_effect = { FROM = { load_prevous_ideologies = yes } }
			}
			hidden_effect = { FROM = { load_oob = "DOM_SPAIN_1861" } }
			hidden_effect = { DOM = { add_ideas = taxation_level_3 } }
			set_temp_variable = { money_to_gain = -0.5 }
            add_money_with_tooltip_effect = yes
			hidden_effect = { DOM = { set_variable = { most_favoured_country = FRA.id } } }
		}
	}
	
	option = {
		name = dom.1.b
		ai_chance = { base = 0 }
		FROM = { country_event = { id = dom.48 days = 3 } }
		hidden_effect = {
			FROM = { set_country_flag = FRA_hispaniola_declined }
		}
	}
	
}

country_event = {
	id = dom.39
	title = dom.39.t
	desc = dom.39.d

	is_triggered_only = yes
	
	
	option = {
		name = dom.39.a
		trigger = { SPR = { set_temp_variable = { loan_size_to_check = 200}
			has_less_than_specific_loan_size = yes } }
		ai_chance = {
			base = 100
			modifier = {
				add = -100
				set_temp_variable = { loan_size_to_check = 40 }
				has_less_than_specific_loan_size = yes				
			}
			modifier = {
				add = 100 
				is_historical_focus_on = yes
			}
		}
		remove_opinion_modifier = { target = DOM modifier = defaulted_on_loan }
		hidden_effect = { SPR = { set_country_flag = SPR_welcome_back_la_hispaniola_flag } }
		if = {
			limit = { 
				FROM = { 
					is_ai = yes 
					OR = {
						has_country_leader = { name = "Pedro Santana" ruling_only = yes }
						has_country_leader = { name = "Buenaventura Báez" ruling_only = yes }
					}
				} 
			}
			annex_country = {
				target = DOM
				transfer_troops = yes
			}
			hidden_effect = { load_oob = "DOM_SPAIN_1861" }
		}
		else = {
			ROOT = {
				hidden_effect = { FROM = { store_current_ideologies = yes } }
				hidden_effect = { FROM = { add_ideas = AFR_spanish_colony } }
				set_autonomy = {
					target = FROM
					autonomy_state = autonomy_afr_colony
					freedom_level = 0.5
				}
				hidden_effect = { FROM = { load_prevous_ideologies = yes } }
				hidden_effect = { DOM = { set_cosmetic_tag = DOM_SPC_cosmetic } }
			}
			hidden_effect = { ROOT = { country_event = { id = dom.2 days = 7 } } }
			hidden_effect = { DOM = { add_ideas = taxation_level_3 } }
			hidden_effect = { load_oob = "DOM_SPAIN_1861" }
			hidden_effect = {
				SPR = { 
				}
				DOM = { set_variable = { most_favoured_country = SPR.id } }
			}
		}
	    HAI = { country_event = { id = dom.40 days = 3 } }
		set_temp_variable = { money_to_gain = -0.5 }
		add_money_with_tooltip_effect = yes 
	}
	
	option = {
		name = dom.39.b
		ai_chance = {
			base = 0
			modifier = {
				add = 100
				set_temp_variable = { loan_size_to_check = 40 }
				has_less_than_specific_loan_size = yes				
			}
			modifier = {
				factor = 0 
				is_historical_focus_on = yes
			}
		}
		FROM = { country_event = { id = dom.48 days = 3 } }
		hidden_effect = {
			FROM = { set_country_flag = SPR_hispaniola_declined }
		}
	}
	
}

country_event = {
	id = dom.2
	title = dom.2.t
	desc = {
		text = dom.2.d
		trigger = { 
			NOT = { 
				OR = {
					DOM = { has_country_leader = { name = "Jose Desiderio Valverde" ruling_only = yes } }
					DOM = { has_country_leader = { name = "Pedro Santana" ruling_only = yes } }
				}
			}
		}
	}
	desc = {
		text = dom.2.valverde
		trigger = { DOM = { has_country_leader = { name = "Jose Desiderio Valverde" ruling_only = yes } } }
	}
	desc = {
		text = dom.2.santana
		trigger = { DOM = { has_country_leader = { name = "Pedro Santana" ruling_only = yes } } }
	}

	is_triggered_only = yes
	
	trigger = { DOM = { is_subject_of = ROOT } }
	
	immediate = { hidden_effect = { ROOT = { country_event = { id = dom.2 days = 1095 } } } }
	
	option = {
		name = dom.2.a
		ai_chance = {
			base = 75 
			modifier = {
				add = -75 
				DOM = { has_country_leader = { name = "Jose Desiderio Valverde" ruling_only = yes } }
			}
		}
		DOM = {
			if = {
				limit = { ROOT = { has_government = anarchism } }
				retire_country_leader = yes
				hidden_effect = { 
					set_politics = { ruling_party = anarchism }
					retire_country_leader = yes
				}
			}
			else_if = {
				limit = { ROOT = { has_government = ideology_social_liberalism } }
				retire_country_leader = yes
				hidden_effect = { 
					set_politics = { ruling_party = ideology_social_liberalism }
					retire_country_leader = yes
				}
			}
			else_if = {
				limit = { ROOT = { has_government = ideology_radical_socialism } }
				retire_country_leader = yes
				hidden_effect = { 
					set_politics = { ruling_party = ideology_radical_socialism }
					retire_country_leader = yes
				}
			}
			else_if = {
				limit = { ROOT = { has_government = social_egalitarianism } }
				retire_country_leader = yes
				hidden_effect = { 
					set_politics = { ruling_party = social_egalitarianism }
					retire_country_leader = yes
				}
			}
			else_if = {
				limit = { ROOT = { has_government = centrism } }
				retire_country_leader = yes
				hidden_effect = { 
					set_politics = { ruling_party = centrism }
					retire_country_leader = yes
				}
			}
			else_if = {
				limit = { ROOT = { has_government = traditional_conservatism } }
				retire_country_leader = yes
				hidden_effect = { 
					set_politics = { ruling_party = traditional_conservatism }
					retire_country_leader = yes
				}
			}
			else_if = {
				limit = { ROOT = { has_government = radical_democracy } }
				retire_country_leader = yes
				hidden_effect = { 
					set_politics = { ruling_party = radical_democracy }
					retire_country_leader = yes
				}
			}
			else_if = {
				limit = { ROOT = { has_government = chauvinist_populism } }
				retire_country_leader = yes
				hidden_effect = { 
					set_politics = { ruling_party = chauvinist_populism }
					retire_country_leader = yes
				}
			}
			else_if = {
				limit = { ROOT = { has_government = autocracy } }
				retire_country_leader = yes
				hidden_effect = { 
					set_politics = { ruling_party = autocracy }
					retire_country_leader = yes
				}
			}
			else_if = {
				limit = { ROOT = { has_government = fundamentalism } }
				retire_country_leader = yes
				hidden_effect = { 
					set_politics = { ruling_party = fundamentalism }
					retire_country_leader = yes
				}
			}
		}
		hidden_effect = { DOM = { country_event = { id = dom.3 days = 3 } } }
	}
	
	option = {
		name = dom.2.b
		trigger = { DOM = { NOT = { has_country_leader = { name = "Pedro Santana" ruling_only = yes } } } }
		ai_chance = { 
			base = 25 
			modifier = {
				add = 75 
				DOM = { has_country_leader = { name = "Jose Desiderio Valverde" ruling_only = yes } }
			}
		}
		hidden_effect = { DOM = { country_event = { id = dom.4 days = 3 } } }
	}
}

country_event = {
	id = dom.3
	title = dom.3.t
	desc = dom.3.d

	is_triggered_only = yes
	
	
	option = {
		name = dom.3.a
		ai_chance = { base = 100 }
		add_political_power = 25
		ROOT = {
			if = {
				limit = { FROM = { has_government = anarchism } }
				add_popularity = { ideology = anarchism popularity = 0.05 }
			}
			else_if = {
				limit = { FROM = { has_government = ideology_social_liberalism } }
				add_popularity = { ideology = ideology_social_liberalism popularity = 0.05 }
			}
			else_if = {
				limit = { FROM = { has_government = ideology_radical_socialism } }
				add_popularity = { ideology = ideology_radical_socialism popularity = 0.05 }
			}
			else_if = {
				limit = { FROM = { has_government = social_egalitarianism } }
				add_popularity = { ideology = social_egalitarianism popularity = 0.05 }
			}
			else_if = {
				limit = { FROM = { has_government = centrism } }
				add_popularity = { ideology = centrism popularity = 0.05 }
			}
			else_if = {
				limit = { FROM = { has_government = traditional_conservatism } }
				add_popularity = { ideology = traditional_conservatism popularity = 0.05 }
			}
			else_if = {
				limit = { FROM = { has_government = radical_democracy } }
				add_popularity = { ideology = radical_democracy popularity = 0.05 }
			}
			else_if = {
				limit = { FROM = { has_government = chauvinist_populism } }
				add_popularity = { ideology = chauvinist_populism popularity = 0.05 }
			}
			else_if = {
				limit = { FROM = { has_government = autocracy } }
				add_popularity = { ideology = autocracy popularity = 0.05 }
			}
			else_if = {
				limit = { FROM = { has_government = fundamentalism } }
				add_popularity = { ideology = fundamentalism popularity = 0.05 }
			}
		}
	}
}

country_event = {
	id = dom.4
	title = dom.4.t
	desc = dom.4.d

	is_triggered_only = yes
	
	
	option = {
		name = dom.4.a
		ai_chance = { base = 100 }
		add_political_power = 100
	}
}

country_event = {
	id = dom.40
	title = dom.40.t
	desc = dom.40.d

	is_triggered_only = yes
	
	
	option = {
		name = dom.40.a
		ai_chance = { 
			base = 95 
			modifier = {
				add = -10 
				num_divisions > 2
			}
			modifier = {
				add = -25 
				num_divisions > 5
			}
		}
		every_state = {
			limit = {
				is_core_of = DOM
			}
			remove_claim_by = HAI
		}
		add_political_power = 30
		remove_ideas = HAI_idea_humilliation_hispaniola
	}
	
	option = {
		name = dom.40.b
		ai_chance = { 
			base = 5 
			modifier = {
				add = 10 
				num_divisions > 2
			}
			modifier = {
				add = 25 
				num_divisions > 5
			}
			modifier = {
				factor = 0 
				is_historical_focus_on = yes
			}
		}
		add_political_power = -40
		remove_ideas = HAI_idea_humilliation_hispaniola
		add_ideas = HAI_liberation_of_hispaniola
		if = {
			limit = { 
				DOM = {
					OR = {
						is_subject_of = SPR 
						is_subject_of = USA 
						is_subject_of = FRA 
					}
				} 
			}
			declare_war_on = {
				target = DOM
				type = take_claimed_state
			}
			DOM = {
				OVERLORD = {
					add_to_war = { 
						targeted_alliance = DOM 
						enemy = ROOT 
						hostility_reason = asked_to_join
					}
					hidden_effect = { set_country_flag = HAI_spain_war }
				}
				hidden_effect = { set_country_flag = HAI_spain_war }
			}
			hidden_effect = { set_country_flag = HAI_spain_war }
		}
		else = {
			every_country = {
				limit = { 
					OR = {
						owns_state = 1318
						owns_state = 319
					}
				}
				ROOT = { 
					declare_war_on = {
						target = PREV
						type = take_claimed_state
					}
				}
				hidden_effect = { set_country_flag = HAI_spain_war }
			}
		}
		hidden_effect = {
			set_country_flag = HAI_spain_war
		}
	}
	
}

country_event = {
	id = dom.41
	title = dom.41.t
	desc = dom.41.d
	fire_only_once = yes
	is_triggered_only = yes
	
	#trigger = {
	#	AND = {
	#		TAG = HAI
	#		controls_state = 1318
	#		has_country_flag = HAI_spain_war
	#	}
	#}
	
	immediate = {
		hidden_effect = {
			if = {
				limit = { 
					DOM = { is_ai = no }
					HAI = { is_ai = yes }
				}
				HAI = { change_tag_from = DOM }
			}
		}
	}
	
	option = {
		name = dom.41.a
		HAI = {
			add_political_power = 30
			remove_ideas = HAI_liberation_of_hispaniola
			transfer_state = 1318
			transfer_state = 319
		}
		hidden_effect = {
			every_country = {
				limit = { has_country_flag = HAI_spain_war }
				clr_country_flag = HAI_spain_war
			}
			every_country = {
				limit = { 
					has_war_with = HAI 
					NOT = { original_tag = HAI }
				}
				white_peace = HAI
			}
		}
	}
	
	
}

country_event = {
	id = dom.42
	title = dom.42.t
	desc = dom.42.d
	fire_only_once = yes
	is_triggered_only = yes
	
	#trigger = {
	#	AND = {
	#		TAG = SPR
	#		controls_state = 318
	#		HAI = {
	#			has_country_flag = HAI_spain_war
	#		}
	#	}
	#}
	
	immediate = {
		hidden_effect = {
			if = {
				limit = { 
					HAI = { is_ai = no }
					DOM = { is_ai = yes }
					DOM = { is_subject_of = SPR }
				}
				HAI = { change_tag_from = DOM }
			}
		}
	}
	
	option = {
		name = dom.42.a
		add_political_power = 30
		HAI = {
			remove_ideas = HAI_liberation_of_hispaniola
			hidden_effect = { clr_country_flag = HAI_spain_war }
		}
		if = {
			limit = { DOM = { is_subject_of = ROOT } }
			DOM = {
				transfer_state = 318
				transfer_state = 790
			}
		}
		else = {
			SPR = {
				transfer_state = 318
				transfer_state = 790
			}
		}
		hidden_effect = {
			every_country = {
				limit = { has_country_flag = HAI_spain_war }
				clr_country_flag = HAI_spain_war
			}
			if = {
				limit = { HAI = { exists = yes } }
				every_country = {
					limit = { 
						has_war_with = HAI 
						NOT = { original_tag = HAI }
					}
					white_peace = HAI
				}
			}
		}
	}
}

country_event = {
	id = dom.43
	title = dom.43.t
	desc = dom.43.d

	fire_only_once = yes
	is_triggered_only = yes
	
	#trigger = {
	#	AND = {
	#		TAG = HAI
	#		date > 1859.04.15
	#	}
	#}
	
	option = {
		name = dom.43.a
		add_political_power = 30
		set_politics = {
			ruling_party = traditional_conservatism
		}
		add_popularity = {
			ideology = traditional_conservatism
			popularity = 0.5
		}
		add_popularity = {
			ideology = centrism
			popularity = 0.4
		}
		#swap_ideas = {
		#	add_idea = presidential_republic
		#	remove_idea = absolute_monarchy
		#}
		swap_ideas = {
			add_idea = universal_male_suffrage
			remove_idea = absolutism
		}	
	}	
}
#rich man's revolt against spain cuz la hispaniola has not been so welcoming
country_event = {
	id = dom.44
	title = dom.44.t
	desc = dom.44.d
	picture = GFX_report_event_dominican_restoration
	
	fire_only_once = yes 
	is_triggered_only = yes
    
    option = {
		name = dom.44.a
		if = { 
			limit = { DOM = { exists = no } }
			DOM = {
				transfer_state = 319
				hidden_effect = { load_oob = "DOM_1863_REVOLT" }	
				declare_war_on = {
					target = ROOT
					type = annex_everything
				}
				hidden_effect = {
					set_politics = {
						ruling_party = radical_democracy
					}
					add_popularity = {
						ideology = radical_democracy
						popularity = 0.5
					}
					#swap_ideas = {
					#	add_idea = presidential_republic
					#	remove_idea = absolute_monarchy
					#}
					swap_ideas = {
						add_idea = universal_male_suffrage
						remove_idea = absolutism
					}
					add_ideas = {
						DOM_restoration_war
					}				
				}
			}
			add_political_power = -10
			add_war_support = 0.015
		}
		else_if = {
			limit = { DOM = { is_subject_of = SPR } }
			start_civil_war = {
				ruling_party = radical_democracy
				ideology = ROOT
				size = 0
				capital = 319
				states = { 
					319
				}
				#keep_unit_leaders = {
				#	
				#}
				keep_political_leader = yes
				keep_political_party_members = yes
			}
		}
	}
}

country_event = {
	id = dom.45
	fire_only_once = yes 
	is_triggered_only = yes
	hidden = yes
	
	trigger = {
		#AND = {
		#	TAG = DOM
		#	date > 1865.3.1
		#	has_war_with = SPR
		#}
		DOM = { has_war_with = SPR }
	}
    
    immediate = {
		DOM = {
			if = {
				limit = { DOM = { has_idea = DOM_restoration_war } }
				remove_ideas = DOM_restoration_war
				add_ideas = DOM_restoration_war2	
			}
		}
	}    
}

country_event = {
	id = dom.46
	title = dom.46.t
	desc = dom.46.d
	fire_only_once = yes 
	is_triggered_only = yes
	
	trigger = {
		AND = {
			TAG = DOM
			#has_war_with = SPR
			controls_state = 1318
		}
	}
    
    option = {
		name = dom.46.a
		DOM = {
			remove_ideas = DOM_restoration_war2
			remove_ideas = DOM_restoration_war
			transfer_state = 1318
			white_peace = SPR
			hidden_effect = {
				every_country = {
					limit = { 
						has_war_with = DOM 
						NOT = { original_tag = DOM }
					}
					white_peace = DOM
				}
			}
			SPR = { set_country_flag = SPR_lost_restoration }
			USA = { give_guarantee = DOM }
		}
	}    
}



#country_event = {   THIS IS NOT A NAMESPACE?
#	id = hispaniola.12
#	title = hispaniola.12.t
#	desc = hispaniola.12.d
#	fire_only_once = yes 
#	is_triggered_only = yes
#	
#	trigger = {
#		TAG = SPR
#	}
#    
#    option = {
#		name = hispaniola.12.a
#		if = {
#			limit = { SPR = { controls_state = 319 } }
#			SPR = { transfer_state = 319 }
#		}
#		hidden_effect = {
#			SPR = { set_country_flag = SPR_won_restoration }
#		}
#	}    
#}

country_event = {
	id = dom.5
	title = dom.5.t
	desc = dom.5.d

	is_triggered_only = yes
	
	
	option = {
		name = dom.5.a
		ai_chance = { base = 100 }
		FROM = { country_event = { id = dom.6 days = 3 } }
	}
}

country_event = {
	id = dom.6
	title = dom.6.t
	desc = dom.6.d

	is_triggered_only = yes
	
	
	option = {
		name = dom.6.a
		ai_chance = { base = 100 }
		SPR = {
			create_production_license = {
				target = DOM
				equipment = {
					type = ship_hull_corvette_0
					#version = 
				}
				cost_factor = 0
			}
			create_production_license = {
				target = DOM
				equipment = {
					type = ship_hull_frigate_0
				}
				cost_factor = 0
			}
			create_production_license = {
				target = DOM
				equipment = {
					type = ship_hull_frigate_1
				}
				cost_factor = 0
			}
			create_production_license = {
				target = DOM
				equipment = {
					type = ship_hull_lineship_0
				}
				cost_factor = 0
			}
		}
	}
}

country_event = { #Recreation of the Caribbean Capitaincy
	id = dom.7
	title = dom.7.t
	desc = dom.7.d

	is_triggered_only = yes
	
	
	option = {
		name = dom.7.a
		trigger = { NOT = { has_completed_focus = SPR_give_power_to_the_landowners } }
		ai_chance = { 
			base = 100 
			modifier = {
				factor = 0
				is_historical_focus_on = yes
			}
		}
		if = { 
			limit = { NOT = { has_completed_focus = SPR_give_power_to_the_landowners } }
			complete_national_focus = SPR_give_power_to_the_landowners
		}
		if = { 
			limit = { NOT = { has_completed_focus = SPR_recreate_the_capitaincy } }
			complete_national_focus = SPR_recreate_the_capitaincy
		}
		hidden_effect = { FROM = { country_event = { id = dom.8 days = 7 } } }
	}
	
	option = {
		name = dom.7.b
		ai_chance = { 
			base = 100 
			modifier = {
				factor = 0
				FROM = { has_country_leader = { name = "Jose Desiderio Valverde" ruling_only = yes } }
			}
		}
		hidden_effect = { FROM = { country_event = { id = dom.9 days = 7 } } }
	}
}
	
country_event = { #Recreation of the Caribbean Capitaincy Accepted
	id = dom.8
	title = dom.8.t
	desc = dom.8.d

	is_triggered_only = yes
	
	immediate = {
		hidden_effect = {
			if = { 
				limit = { TAG = DOM }
				complete_national_focus = DOM_recreation_of_the_caribbean_captaincy
			}
		}
	}
	option = {
		name = dom.8.a
		ai_chance = { base = 100 }
		set_cosmetic_tag = SPC
	}
}

country_event = { #Recreation of the Caribbean Capitaincy Declined
	id = dom.9
	title = dom.9.t
	desc = dom.9.d

	is_triggered_only = yes
	
	immediate = {
		hidden_effect = {
			set_country_flag = SPR_rejected_as_SPC_flag
		}
	}
	
	option = {
		name = dom.9.a
		ai_chance = { base = 100 }
		add_political_power = -25
	}
}
	
country_event = { 
	id = dom.12
	title = dom.12.t
	desc = dom.12.d

	is_triggered_only = yes
	
	option = { #Dont Promote French
		name = dom.12.a
		ai_chance = { base = 80 }
	}
	
	option = { #Accommodate Both
		name = dom.12.b
		trigger = { has_political_power > 0 }
		ai_chance = { base = 20 }
		add_political_power = -75
	}
}
