#Panamanian war of independence
country_event = {

	id = 110060

	title = "EVTNAME110060"
	desc = "EVTDESC110060"
	major = yes
	
	trigger = {
		tag = CLM
		USA = { is_greater_power = yes
		year = 1903
		NOT = {
			has_global_flag = panamanian_revolution_has_happened }
		}
	}

	
	option = {
		name = "EVTOPTA110060"
		any_pop = {
			consciousness = 2
			militancy = 1
		}
		set_global_flag = panamanian_revolution_has_happened
		CLM = {
		any_owned = {
			limit = {
				is_core = PNM
			}
			secede_province = PNM
		}
		}
		PNM = {
			capital = 2204
			leadership = 80
			USA = { diplomatic_influence = {
				who = PNM
				value = 400 }
			}
		}
		diplomatic_influence = {
				who = USA
				value = -400
		}
	}
	
	option = {
		name = "EVTOPTB110060"
		any_pop = {
			consciousness = 2
			militancy = 2
		}
		set_global_flag = panamanian_revolution_has_happened
		diplomatic_influence = {
				who = USA
				value = -400
		}
		CLM = {
			any_owned = {
				limit = {
					is_core = PNM
				}
				secede_province = PNM
			}
		}
		PNM = {
			capital = 2204
			leadership = 80
			USA = { diplomatic_influence = {
				who = PNM
				value = 400 }
			}
		}		
		change_tag_no_core_switch = PNM
	}
}
country_event = {

    id = 110061

    title = "EVTNAME110061" #The Treaties of Velasco
    desc = "EVTDESC110061"

	trigger= {
	tag = CLM
	exists = PNM
	}
	
	fire_only_once = yes

	mean_time_to_happen = { months = 2 }

    option = {
        name = "EVT110061OPTA"
		CLM = {
			war = {
				target = PNM
				attacker_goal = {
					casus_belli = conquest
					
				}
				defender_goal = {
					casus_belli = status_quo
				}
			}

		}
        prestige = 10
        relation = { who = PNM value = 400 }
	ai_chance = {
		factor = 0
	}
	}

    option = {
        name = "EVT110061OPTB"
		CLM_1723 = { remove_core = CLM }
        prestige = 10
        relation = { who = CLM value = 400 }
		ai_chance = {
			factor = 100
		}
	
    }
}