plot_decisions = {
	faction_force_election_ultimatum = {
		only_playable = yes
		is_high_prio = yes
		ai_check_interval = 1
		
		potential = {
			is_playable = yes
			leads_faction = faction_force_election
			OR = {
				NOT = { has_character_flag = faction_force_election_ultimatum_taken }
				had_character_flag = { flag = faction_force_election_ultimatum_taken days = 7 }
			}
		}
		allow = {
			war = no
			prisoner = no
			liege = {
				in_revolt = no
				NOT = { war_with = ROOT }
				NOT = { reverse_has_truce = ROOT }
			}

			faction_power = {
				faction = faction_force_election
				power >= 1.0
			}
		}
		
		effect = {
			liege = {
				letter_event = { id = MRPC.8220 days = 1 tooltip = EVTTOOLTIP8005 }
			}
			hidden_tooltip = {
				set_character_flag = faction_force_election_ultimatum_taken
			}
		}
		
		ai_will_do = {
			factor = 1
			modifier = {
				factor = 0
				faction_power = {
					faction = faction_force_election
					power < 1.0
				}
			}
			
			modifier = {
				factor = 0
				liege = {
					any_war = {
						OR = {
							AND = {
								defender = { character = PREV }
								NOT = { using_cb = depose_liege }
								NOT = { using_cb = overthrow_ruler }
								NOT = { using_cb = overthrow_ruler_no_calls }
							}
							AND = {
								attacker = { character = PREV }
								OR = {
									using_cb = invasion
									using_cb = religious
									using_cb = tribal_invasion
									using_cb = muslim_invasion
									using_cb = viking_invasion
									using_cb = claim_all
									using_cb = claim
									using_cb = other_claim
								}
							}
						}
					}
				}
			}
		}
	}
}


