### This file determines how the ai evaluates the council positions.
# The ai will add all of the ai_selection entries under ai_selection_additive = {} for all of the positions.
# If there's any of the positions with an ai_selection value higher than zero (0) the position with the HIGHEST score will be chosen by that ai.
# If there's no position with an  ai_selection value higher than zero (0) the ai will go through the list of positions in order of the default selection value and pick the first position which fulfill the potential = {} trigger.

### It also determines how a position will vote in the realm interactions the council is allowed to vote in. 
# This is determined with a FOR trigger which checks if the voter will vote in favor of a decision. 
# If that fails the voter will then go through the AGAINST trigger to see if it will vote against a decision. 
# If both those triggers fail the voter will abstain from voting until swayed by the for or against side.

### SCOPES AND SPECIAL TRIGGERS FOR WAR TARGET TRIGGER:
#liege == FROM
#target == FROMFROM

### SCOPES AND SPECIAL TRIGGERS FOR WAR DECLARATION VOTES:
#attacker == FROM
#defender == FROMFROM
#thirdparty == FROMFROMFROM
#thirdparty_title == FROMFROMFROMFROM
#stored_token_trigger = cb_type ### trigger that's available in the FROM or ROOT scope.

loyalist = {
	icon = 1
	
	may_request_law_change = no
	
	potential = { # The player also needs to obey the potential triggers when choosing a position.
		#NOT = { trait = envious }
		OR = {
			opinion = { who = liege value = 0 }
			trait = horse
		}
	}
	
	default_selection = {
		value = 1
	}
	
	selection = {
		value = 0
		
		additive_modifier = {
			value = 10
			trait = content
		}
		additive_modifier = {
			value = 5
			trait = trusting
		}
		additive_modifier = {
			value = 10
			liege = {
				is_close_relative = ROOT
			}
		}
		additive_modifier = {
			value = 5
			liege = { 
				dynasty = ROOT
				NOT = { is_close_relative = ROOT }
			}
		}
		additive_modifier = {
			value = 10
			liege = { is_friend = ROOT }
		}
		additive_modifier = {
			value = 5
			liege = { is_lover = ROOT }
		}
		additive_modifier = {
			value = 10
			opinion = { who = LIEGE value = 95 }
		}
		additive_modifier = {
	   		value = 25
	   		is_nomadic = yes
	   		liege = {
	    		has_character_modifier = greatest_of_khans
	   		}
	  	}
	}
	
	voting_patterns = { 
		me_pattern_for
		selfish_pattern_for
		selfish_pattern_against
		family_pattern_for
		family_pattern_against
		faction_pattern_for
		faction_pattern_against
		loyalist_pattern_for 
		loyalist_pattern_against
		interaction_pattern_for
		interaction_pattern_against
	}
}