﻿
namespace = assassination_ongoing

#Ongoing Events with Master Assassin #by Ola Jentzsch
##########################
# A Secret Sympathizer
# by Ola Jentzsch
##########################
assassination_ongoing.0001 = {
	type = character_event
	title = assassination_ongoing.0001.t
	desc = assassination_ongoing.0001.desc
	theme = generic_intrigue_scheme
	left_portrait = {
		character = scope:secret_sympathizer
		animation = scheme
	}
	right_portrait = {
		character = scope:assassin
		animation = assassin
	}
	widget = {
		gui = "event_window_widget_scheme"
		container = "custom_widgets_container"
	}

	trigger = {
		any_court_position_holder = {
			type = master_assassin_court_position
		}
		scope:target = {
			any_courtier = {
				is_available_ai_adult = yes
				OR = {
					has_trait = callous
					has_trait = deceitful 
					has_trait = disloyal
					has_trait = murderer
					faith = { has_doctrine_parameter = sanctioned_assassinations } 
				}
				opinion = { 
					target = scope:target
					value < 0
				}
			}
		}
		NOT = { exists = scope:scheme.var:had_dark_blessing_event } 
	}

	immediate = {
		random_court_position_holder = { 
			type = master_assassin_court_position
			save_scope_as = assassin 	
		}
		scope:target = {
			random_courtier = {
				limit = { 
					is_available_ai_adult = yes
					OR = {
						has_trait = callous
						has_trait = deceitful 
						has_trait = disloyal
						has_trait = murderer
						faith = { has_doctrine_parameter = sanctioned_assassinations } 
					}
					opinion = { 
						target = scope:target
						value < 0
					}
				}
				save_scope_as = secret_sympathizer
			}
		}
		hidden_effect = {
			scope:secret_sympathizer = {
				if = {
					limit = {
						NOT = { 
							faith = { has_doctrine_parameter = sanctioned_assassinations } 
						}
					}
					make_character_crypto_religionist_effect = { CRYPTO_RELIGION = scope:owner.faith }		 
				}
			}
		}
		scope:scheme = {
			set_variable = {
				name = had_dark_blessing_event
				value = yes
				days = 3650
			}
		}			
	}

	# Bless them 
	option = {
		name = assassination_ongoing.0001.a
		add_piety = medium_piety_loss 
		scope:scheme = {
			add_scheme_modifier = {
				type = scheme_helpful_sympathizer_modifier
			}
		}
		scope:secret_sympathizer = {
			add_opinion = { 
				target = scope:owner
				opinion = 30
				modifier = fp3_blessed_me_opinion
			}
		}
		stress_impact = {
			arrogant = minor_stress_impact_gain
		}
		ai_chance = {
			base = 50
			modifier = {
				add = 50
				scope:secret_sympathizer = {
					intrigue >= medium_skill_rating
				}
			}
			ai_value_modifier = {
				ai_zeal = 0.5
				ai_sociability = 0.3
			}
		}
	}

	# Refuse
	option = {
		name = assassination_ongoing.0001.b
		flavor = fp3_sympathizer_might_betray_you.flavor 
		scope:scheme = {
			add_scheme_modifier = { type = scheme_untrustworthy_sympathizer_modifier }
		}
		stress_impact = {
			zealous = minor_stress_impact_gain
			generous = minor_stress_impact_gain 
		}
		ai_chance = {
			base = 50
			ai_value_modifier = {
				ai_greed = -0.5
			}
		}
	}
}

##########################
# Courting Fanatics
# by Ola Jentzsch
##########################

assassination_ongoing.0002 = {
	type = character_event
	title = assassination_ongoing.0002.t
	desc = assassination_ongoing.0002.desc
	theme = generic_intrigue_scheme
	left_portrait = {
		character = root
		triggered_animation = {
			trigger = {
				OR = {
					has_trait = zealous
					has_trait = generous
					has_trait = gregarious
				}
			}
			animation = happiness
		}
		animation = dismissal
	}
	right_portrait = {
		character = scope:assassin
		animation = personality_greedy 
	}
	widget = {
		gui = "event_window_widget_scheme"
		container = "custom_widgets_container"
	}

	override_background = { reference = wilderness }

	trigger = {
		any_court_position_holder = {
			type = master_assassin_court_position
		}
		NOT = { exists = scope:scheme.var:had_courting_fanatics_event }
	}

	immediate = {
		random_court_position_holder = { 
			type = master_assassin_court_position
			save_scope_as = assassin 	
		}
		scope:scheme = {
			set_variable = {
				name = had_courting_fanatics_event
				value = yes
				days = 3650
			}
		}
	}

	# Pay them  
	option = {
		name = assassination_ongoing.0002.a
		remove_short_term_gold = medium_gold_value 
		scope:scheme = {
			add_scheme_modifier = {
				type = scheme_assassin_recruits_modifier
			}
		}
		stress_impact = {
			greedy = minor_stress_impact_gain
			paranoid = medium_stress_impact_gain 
		}
		ai_chance = {
			base = 50
			ai_value_modifier = {
				ai_zeal = 0.5
				ai_sociability = 0.5
				ai_greed = -0.9
			}
			modifier = {
				factor = 0
				short_term_gold < medium_gold_value
			}
		}
	}

	# Refuse
	option = {
		name = assassination_ongoing.0002.b

		stress_impact = {
			zealous = minor_stress_impact_gain
			generous = minor_stress_impact_gain 
		}
		ai_chance = {
			base = 50
			ai_value_modifier = {
				ai_greed = 0.5
				ai_boldness = -0.2
			}
		}
	}
}


#######################
# Gold and God
# by Ola Jentzsch 
#######################
# Can pay gold for scheme progress
assassination_ongoing.0003 = {
	type = character_event
	title = {
		first_valid = {
			triggered_desc = {
				trigger = { faith = { trait_is_sin = greedy } } 
				desc = assassination_usury_event_title
			}
			desc = assassination_not_usury_event_title
		}	
	}
	desc = {
		desc = assassination_ongoing.0003_opening 
		random_valid = {
			desc = assassination_usury_event_scullery_maid_desc
			desc = assassination_usury_event_guard_desc
			triggered_desc = {
				trigger = { 
					AND = {
						faith = { religion_tag = islam_religion }
						has_game_rule = default_gender_equality
					} 
				}
				desc = assassination_usury_event_harem_slave_desc
			}
			desc = assassination_usury_event_gardener_desc
			desc = assassination_usury_event_minor_servant_desc
		}
		desc = assassination_ongoing.0003.outro
	}
	theme = generic_intrigue_scheme
	widget = {
		gui = "event_window_widget_scheme"
		container = "custom_widgets_container"
	}
	left_portrait = {
		character = scope:assassin
		animation = hunting_knife_start
	}
	right_portrait = {
		character = scope:target
		animation = paranoia
	}

	trigger = {
		any_court_position_holder = {
			type = master_assassin_court_position
		}
		NOT = { exists = scope:scheme.var:had_usury_assassination_event }
		scope:scheme = {
			is_scheme_exposed = no
			scheme_agent_charges < opportunity_cap_value
		}
	}

	immediate = {
		scope:scheme = {
			set_variable = {
				name = had_usury_assassination_event
				value = yes
				days = 3650
			}
		}
		random_court_position_holder = { 
			type = master_assassin_court_position
			save_scope_as = assassin 	
		}
		scope:assassin = { save_scope_as = agent } #so we can reuse some loc from the murder scheme
	}

	option = { #Pay the gold
		name = {
			trigger = {
				faith = {
					trait_is_sin = greedy
				}
			}
			text = assassination_ongoing.0003.a
		}
		name = {
			trigger = {
				NOT = { 
					faith = {
						trait_is_sin = greedy
					}
				}
			}
			text = assassination_ongoing.0003.b
		}
		remove_short_term_gold = medium_gold_value
		scope:assassin = {
			duel = {
				skill = intrigue
				value = 10
				20 = {		
					desc = intrigue_scheme_ongoing.1008.a.success
					compare_modifier = {
						value = scope:duel_value
						multiplier = 0.75
						min = 0
					}
					scope:owner = {
						send_interface_toast = {
							title = intrigue_scheme_ongoing.1008.a.success
							left_icon = scope:agent
							scope:scheme = {
								add_scheme_modifier = {
									type = scheme_assassin_closing_in_modifier
								}
							}
						}
					}
				}
				10 = {		
					desc = intrigue_scheme_ongoing.1008.a.failure
					compare_modifier = {
						value = scope:duel_value
						multiplier = -0.5
						min = -14
					}
					scope:owner = {
						send_interface_toast = {
							title = intrigue_scheme_ongoing.1008.a.failure
							left_icon = scope:agent
							
							scope:scheme = {
								expose_scheme = yes	
							}
						}
					}
				}
			}
		}
		if = {
			limit = {
				faith = {
					trait_is_sin = greedy 
				}
			}
			stress_impact = {
				base = minor_stress_gain 
				generous = minor_stress_loss 
				zealous = medium_stress_gain 
			}
		}
		stress_impact = {
			greedy = medium_stress_impact_gain
		}
		ai_chance = {
			base = 50
			modifier = {
				add = 100
				has_trait = generous
			}
			modifier = {
				factor = 0
				short_term_gold < medium_gold_value
			}
		}
	}
	option = { #Save it
		name = {
			trigger = {
				faith = {
					trait_is_sin = greedy
				}
			}
			text = assassination_ongoing.0003.c
		}
		name = {
			trigger = {
				NOT = { 
					faith = {
						trait_is_sin = greedy
					}
				}
			}
			text = intrigue_scheme_ongoing.1001.b
		}
		scope:scheme = {
			change_opportunities = 2
		}
		stress_impact = {
			impatient = minor_stress_impact_gain
		}
		ai_chance = {
			base = 50
		}
	}
}


#######################
# A Moment of Doubt 
# by Ola Jentzsch 
#######################
# Your master assassin is doubting themselves
assassination_ongoing.0004 = {
	type = character_event
	title = assassination_ongoing.0004.t
	desc = {
		desc = assassination_ongoing.0004_opening 
		first_valid = {
			triggered_desc = {
				trigger = { 
					has_trait = hashishiyah 
				}
				desc = assassination_doubt_event_hashish_desc
			}
			triggered_desc = {
				trigger = { 
					has_trait = drunkard 
				}
				desc = assassination_doubt_event_alcohol_desc
			}
			triggered_desc = {
				trigger = { 
					has_trait = comfort_eater 
				}
				desc = assassination_doubt_event_food_desc
			}
			triggered_desc = {
				trigger = { 
					has_trait = confider 
				}
				desc = assassination_doubt_event_confide_desc
			}
			triggered_desc = {
				trigger = { 
					has_trait = rakish 
				}
				desc = assassination_doubt_event_orgy_desc
			}
			triggered_desc = {
				trigger = {
					OR = {
						faith = { has_doctrine_parameter = meditation_mechanics_active	}
						has_character_modifier = fp3_sufi_initiate_modifier 
						has_trait = calm 
					}
				}
				desc = assassination_doubt_event_meditation_desc
			}
			desc = assassin_doubt_event_nothing_else 
		}
	}
	theme = generic_intrigue_scheme
	widget = {
		gui = "event_window_widget_scheme"
		container = "custom_widgets_container"
	}
	left_portrait = {
		character = scope:owner
		animation = thinking
	}
	right_portrait = {
		character = scope:assassin
		animation = worry
		triggered_animation = {
			trigger = {
				OR = {
					ai_zeal >= high_positive_ai_value
					ai_boldness >= high_positive_ai_value
				}
			}
			animation = paranoia 
		}
	}

	trigger = {
		any_court_position_holder = {
			type = master_assassin_court_position
		}
		NOT = { exists = scope:scheme.var:had_doubt_event } 
	}

	immediate = {
		random_court_position_holder = { 
			type = master_assassin_court_position
			save_scope_as = assassin 	
		}
		scope:scheme = {
			set_variable = {
				name = had_doubt_event
				value = yes
				days = 3650
			}
		}
	}


	option = {
		name = {
			trigger = {
				has_trait = hashishiyah
			}
			text = assassination_ongoing.0003.c_hashish
		}
		name = {
			trigger = {
				has_trait = drunkard
			}
			text = assassination_ongoing.0003.c_alcohol
		}
		name = {
			trigger = {
				has_trait = comfort_eater
			}
			text = assassination_ongoing.0003.c_food
		}
		name = {
			trigger = {
				has_trait = confider
			}
			text = assassination_ongoing.0003.c_confide
		}
		name = {
			trigger = {
				has_trait = rakish 
			}
			text = assassination_ongoing.0003.c_orgy
		}
		name = {
			trigger = {
				OR = {
					faith = { has_doctrine_parameter = meditation_mechanics_active	}
					has_character_modifier = fp3_sufi_initiate_modifier 
					has_trait = calm 
				}
			}
			text = assassination_ongoing.0003.c_meditation
		}
		trigger = {
			OR = {
				has_trait = hashishiyah
				has_trait = drunkard
				has_trait = comfort_eater
				has_trait = confider
				has_trait = rakish
				OR = {
					faith = { has_doctrine_parameter = meditation_mechanics_active	}
					has_character_modifier = fp3_sufi_initiate_modifier 
					has_trait = calm 
				}
			}
		}
		scope:scheme = {
			add_scheme_modifier = {
				type = scheme_strengthened_resolve_modifier
			}
			change_opportunities = 2
		}
		custom_tooltip = high_risk_of_dying.tt
		scope:assassin = {
			if = {
				limit = { 
					NOT = { has_relation_friend = scope:owner }
				}
				scope:owner = {
					progress_towards_friend_effect = {
	 					CHARACTER = scope:assassin
						REASON =  friend_reaffirmed_assassin
	 					OPINION = 25
	 				}
				}
			}
			else = { 
				add_opinion = { 
					target = scope:owner
					opinion = 40
					modifier = respect_opinion
				}
			}
		}
		stress_impact = {
   			compassionate = medium_stress_impact_gain #hey, you should want to die! 
		}
		ai_chance = { #zealous yet social AI will do this
        	base = 100
        	ai_value_modifier = {
            	ai_zeal = 1
            	ai_sociability = 1
            	ai_compassion = -1
        	}
   		}	
	}

	option = {
		name = assassination_ongoing.0004.b #skill challenge 
		duel = {
			skill = diplomacy 
			value = medium_skill_rating

			20 = {
				desc = assassination_console.success
				compare_modifier = {
					value = scope:duel_value
					multiplier = 2
				}
				send_interface_toast = {
					title = assassination_console_toast.success
					left_icon = scope:assassin

					add_piety = medium_piety_gain
					scope:scheme = {
						add_scheme_modifier = {
							type = scheme_strengthened_resolve_modifier
						}
						change_opportunities = 2
					}
					#custom_tooltip = high_risk_of_dying.tt #Unop: Actually no ? Found nothing that would cause him to die more :???
				}	
			}
			20 = {
				desc = assassination_console.failure
				compare_modifier = {
					value = scope:duel_value
					multiplier = -1
				}
				scope:owner = {
					send_interface_toast = {
						title = assassination_console_toast.failure
						left_icon = root						

						scope:scheme = {
							add_scheme_modifier = {
								type = scheme_weakened_resolve_modifier
							}
						}
					}
				}
			}
		}
		stress_impact = {
   			compassionate = medium_stress_impact_gain 
		}
		ai_chance = { #zealous yet energetic AI will do this. Plus, it's mutually exclusive with the first option anyhow. 
        	base = 100
        	ai_value_modifier = {
            	ai_zeal = 1
            	ai_energy = 1
            	ai_compassion = -1
        	}
   		}	
	}

	option = {
		name = assassination_ongoing.0004.c
		scope:scheme = {
			end_scheme = yes
		}
		stress_impact = {
   			compassionate = medium_stress_impact_loss
   			trusting = minor_stress_impact_loss 
   			callous = minor_stress_impact_gain 	
   			zealous = medium_stress_impact_gain 
   			ambitious = minor_stress_impact_gain 
   			sadistic = minor_stress_impact_gain 
   			stubborn = minor_stress_impact_gain
   			vengeful = medium_stress_impact_gain 
		}
		ai_chance = { #loving, non-zealous AI will do this
        	base = 50
        	ai_value_modifier = {
           		ai_compassion = 1
            	ai_zeal = -1
            	ai_boldness = -0.5
        	}
   		}	
	}
}


##########################
# Poison or Pestilence 
# by Ola Jentzsch
##########################
assassination_ongoing.0005 = {
	type = character_event
	title = assassination_ongoing.0005.t
	desc = assassination_ongoing.0005.desc
	theme = medicine

	left_portrait = {
		character = root
		animation = thinking
	}
	right_portrait = {
		character = scope:assassin
		animation = hunting_knife_start
	}
	widget = {
		gui = "event_window_widget_scheme"
		container = "custom_widgets_container"
	}

	trigger = {
		any_court_position_holder = {
			type = master_assassin_court_position
		}
		NOT = { exists = scope:scheme.var:had_poison_event }
		scope:scheme = {
			scheme_agent_charges < opportunity_cap_value
		} 
	}

	immediate = {
		random_court_position_holder = { 
			type = master_assassin_court_position
			save_scope_as = assassin 	
		}
		scope:scheme = {
			set_variable = {
				name = had_poison_event
				value = yes
				days = 3650
			}
		}
	}

	# Herbalism!
	option = {
		name = {
			trigger = {
				has_trait = lifestyle_herbalist 
			}
			text = assassination_ongoing.0005.a_you
		}
		name = {
			trigger = {
				scope:assassin = { has_trait = lifestyle_herbalist }
			}
			text = assassination_ongoing.0005.a_them
		}
		trigger = {
			OR = {
				has_trait = lifestyle_herbalist 
				scope:assassin = { has_trait = lifestyle_herbalist }
			}
		}
		scope:scheme = {
			add_scheme_modifier = {
				type = scheme_poisoned_blade_modifier
			}
		}
		stress_impact = {
   			lazy = minor_stress_impact_gain
		}
		ai_chance = { #AI will do this if they can
        	base = 100
        	ai_value_modifier = {
            	ai_zeal = 1
            	ai_energy = 2
        	}
   		}
	}

	# Gold!
	option = {
		name = assassination_ongoing.0005.b
		trigger = {
			NOR = {
				has_trait = lifestyle_herbalist 
				scope:assassin = { has_trait = lifestyle_herbalist }
			}
		}
		remove_short_term_gold = minor_gold_value 
		scope:scheme = {
			add_scheme_modifier = {
				type = scheme_poisoned_blade_modifier
			}
		}
		stress_impact = {
   			greedy = minor_stress_impact_gain
		}
		ai_chance = { #some AI are hesitant to spend money on this 
        	base = 100
        	ai_value_modifier = {
            	ai_zeal = 1
            	ai_vengefulness = 0.9
            	ai_greed = -0.9
        	}
        	modifier = {
        		factor = 0
        		short_term_gold < minor_gold_value
        	}
   		}
	}

	# Cheap natural poison!
	option = {
		name = assassination_ongoing.0005.c
		scope:scheme = {
			add_scheme_modifier = {
				type = scheme_pestilent_blade_modifier
			}
		}
		scope:assassin = {
			add_opinion = { 
				target = scope:owner
				opinion = -20
				modifier = frustrated_opinion
			}
		}
		stress_impact = {
   			gallant = medium_stress_impact_gain
   			generous = minor_stress_impact_gain
   			arrogant = minor_stress_impact_gain 
		}

		ai_chance = { #this is the cheapskate option
        	base = 100
        	ai_value_modifier = {
            	ai_greed = 0.8
            	ai_rationality = 1
            	ai_zeal = -0.3       	
        	}
   		}
	}

	# Beneath us!
	option = {
		name = assassination_ongoing.0005.d
		scope:scheme = {
			change_opportunities = 2
		}
		scope:assassin = {
			add_opinion = { 
				target = scope:owner
				opinion = 20
				modifier = respect_opinion
			}
		}
		stress_impact = {
   			cynical = minor_stress_impact_gain
   			generous = minor_stress_impact_gain
   			vengeful = minor_stress_impact_gain
		}
		ai_chance = { #this is the "honorable" option
        	base = 100
        	ai_value_modifier = {
            	ai_honor = 0.8
            	ai_rationality = -0.3
            	ai_zeal = -0.5       	
        	}
   		}
	}
}

##########################
# Runaway Assassin
# by Ola Jentzsch
##########################
assassination_ongoing.0006 = {
	type = character_event
	title = assassination_ongoing.0006.t
	desc = assassination_ongoing.0006.desc
	theme = generic_intrigue_scheme
	left_portrait = {
		character = root
		animation = personality_vengeful
	}
	right_portrait = {
		character = scope:target
		animation = paranoia
	}
	lower_right_portrait = {
		character = scope:assassin
	}
	widget = {
		gui = "event_window_widget_scheme"
		container = "custom_widgets_container"
	}

	trigger = {
		any_court_position_holder = {
			type = master_assassin_court_position
		}
		NOT = { exists = scope:scheme.var:had_faltering_assassin_event } 
	}

	immediate = {
		random_court_position_holder = { 
			type = master_assassin_court_position
			save_scope_as = assassin 	
		}
		scope:scheme = {
			set_variable = {
				name = had_faltering_assassin_event
				value = yes
				days = 3650
			}
		}
		scope:scheme = {
			add_scheme_modifier = {
				type = scheme_renegade_assassin_modifier
			}
		}
		random_dummy_gender_assassin_effect = yes #to set a gender in the loc for the unscoped assassin
	}

	option = {
		name = assassination_ongoing.0006.a
		duel = {
			skill = intrigue
			value = medium_skill_rating
			20 = {
				desc = assassination_hunted_down.success
				compare_modifier = {
					value = scope:duel_value
					multiplier = 2
				}
				send_interface_toast = {
					title = assassination_hunted_down_toast.success
					left_icon = scope:assassin
					add_dread = medium_dread_gain 
					scope:scheme = {
						remove_scheme_modifier = scheme_renegade_assassin_modifier
					}
				}	
			}
			20 = {
				desc = assassination_hunted_down.failure
				compare_modifier = {
					value = scope:duel_value
					multiplier = -1
				}
				scope:owner = {
					send_interface_toast = {
						title = assassination_hunted_down_toast.failure
						left_icon = root
						add_prestige = minor_prestige_loss
					}
				}
			}
		}
		stress_impact = {
   			lazy = major_stress_impact_gain
   			compassionate = major_stress_impact_gain
   			trusting = medium_stress_impact_gain
   			forgiving = medium_stress_impact_gain
		}
		ai_chance = { 
        	base = 100
        	ai_value_modifier = {
            	ai_vengefulness = 1
            	ai_rationality = 0.3
            	ai_compassion = -1   	
        	}
   		}
	}

	option = {
		name = assassination_ongoing.0006.b
		stress_impact = {
   			vengeful = major_stress_impact_gain
   			paranoid = major_stress_impact_gain
   			callous = minor_stress_impact_gain
   			sadistic = minor_stress_impact_gain
		}
		ai_chance = { #this is the "honorable" option
        	base = 100
        	ai_value_modifier = {
            	ai_honor = 0.8
            	ai_rationality = -0.7
            	ai_vengefulness = -1   	
        	}
   		}
	}		
}

scripted_trigger righteous_target_trigger = {
	has_religion = scope:temporary_assassin.religion 
	num_sinful_traits = 0
	OR = {
		piety_level >= 3
		AND = {
			piety_level >= 2
			ai_honor >= medium_positive_ai_value 
		}
	}
	OR = {
		num_virtuous_traits >= 1
		reverse_opinion = { 
			target = scope:temporary_assassin 	
			value > 50
		}
	}
}

##########################
# A Man/Woman of Virtue
# by Ola Jentzsch
##########################
assassination_ongoing.0007 = {
	type = character_event
	title = assassination_ongoing.0007.t
	desc = assassination_ongoing.0007.desc
	theme = generic_intrigue_scheme
	
	left_portrait = {
		character = root
		animation = personality_callous			
	}
	right_portrait = {
		character = scope:assassin
		triggered_animation = {
			trigger = {
				ai_vengefulness >= medium_positive_ai_value
			}
			animation = stress
		}
		animation = worry
	}
	lower_right_portrait = scope:target
	widget = {
		gui = "event_window_widget_scheme"
		container = "custom_widgets_container"
	}

	trigger = {
		NOT = { exists = scope:scheme.var:had_righteous_target_event }
		scope:scheme = {
			scheme_agent_charges < opportunity_cap_value
		}
		any_court_position_holder = { 
			type = master_assassin_court_position
			save_temporary_scope_as = temporary_assassin 	
		}
		scope:temporary_assassin = {
			NOR = {
				ai_zeal < low_positive_ai_value 
				opinion = { 
					target = scope:target
					value < -50
				}
			}
		}
		scope:target = {
			righteous_target_trigger = yes 
		}
	}

	immediate = {
		random_court_position_holder = { 
			type = master_assassin_court_position
			save_scope_as = assassin 	
		}
		scope:scheme = {
			set_variable = {
				name = had_righteous_target_event
				value = yes
				days = 3650
			}
		}
	}

	option = {
		name = assassination_ongoing.0007.a
		scope:scheme = {
			change_opportunities = 2
		}
		add_dread = minor_dread_gain 
		scope:assassin = {
			add_opinion = {
				target = root
				modifier = fp3_dismayed_opinion
			}
		}
		custom_tooltip = high_risk_of_dying.tt
		stress_impact = {
   			brave = minor_stress_impact_loss
   			trusting = medium_stress_impact_gain
   			forgiving = medium_stress_impact_gain 
		}
		ai_chance = { 
        	base = 50
        	ai_value_modifier = {
           		ai_vengefulness = 1
            	ai_boldness = 1
            	ai_compassion = -0.3
        	}
   		}	
	}

	option = {
		name = assassination_ongoing.0007.b
		scope:scheme = {
			end_scheme = yes
		}
		if = { #if target is truly righteous, you'll gain some piety 
			limit = {
				scope:target = { num_virtuous_traits >= 1 }
			}
			add_piety = medium_piety_gain
		}
		stress_impact = {
   			craven = minor_stress_impact_loss
   			trusting = minor_stress_impact_loss 
   			ambitious = minor_stress_impact_gain  
   			stubborn = medium_stress_impact_gain
   			vengeful = medium_stress_impact_gain 
		}
		ai_chance = { #cautious, trusting AI will do this
        	base = 50
        	ai_value_modifier = {
           		ai_sociability = 0.4
            	ai_boldness = -1
            	ai_vengefulness = -1
        	}
   		}	
	}		
}


