# Targetted decisions are possible vs _all_ other characters and shown are in the Diplomacy View, not the Intrigue View. The taker is in the FROM scope.
#
# filter = [self/court/home_court/vassals/sub_realm/realm/dynasty/all] (self MUST be set for decisions targetting only the taker, the other filter types can be set to lessen CPU load)
# #ai_target_filter  = [self/court/home_court/vassals/sub_realm/realm/dynasty/all] (which characters for which the AI evaluates the decision.)
#	court: all characters in the AI's host court, including prisoners, and characters currently away (wards, prisoners, etc)
#	home_court: all characters in the AI's home court, including prisoners, and characters currently away (wards, prisoners, etc)
#	vassals: direct vassal rulers of the AI's employer
#	sub_realm: all characters below the AI's employer
#	realm: all characters in the same top realm as the AI
#	dynasty: all members of the same dynasty (including the dead!)
#	all: all living characters (Avoid if possible. VERY CPU-HEAVY!)
#	

targetted_decisions = {

	trial_character = {
		only_playable = yes
		filter = court
		from_potential = {
			ai = no
			is_playable = yes
			capital_scope = { has_building = ca_high_court }
			any_courtier = { has_minor_title = title_grand_judge }
		}
		
		potential = {
			is_adult = yes				
		}
		
		allow = {
			prisoner = yes
			host = { character = FROM }
			FROM = { 	
				prestige = 50
				NOT = { has_character_modifier = holding_trial }
			}
			ROOT = {
				NOT = {
					has_character_modifier = on_trial
				}
			}
		}
		
		effect = {		
			FROM = { 
				add_character_modifier = { modifier = holding_trial duration = 7 }
				character_event = { id = trial_events.1 } 
			} 
			ROOT = { add_character_modifier = { modifier = on_trial duration = 7 } }
			}		
		ai_will_do = {
			factor = 0
		}
	}
}
