﻿smu_valid_for_maa_innovation_trigger = {
	OR = {
		AND = {
			is_landless_adventurer = yes
			has_perk = planned_cultivation_perk
			location.county.culture ?= { has_innovation = $PARAMETER$ }
		}
		AND = {
			is_landless_adventurer = no
			culture = { has_innovation = $PARAMETER$ }
		}
		any_sub_realm_county = { # You need a minimum acceptance with any culture with the innovation
			county.culture = {
				has_innovation = $PARAMETER$
				cultural_acceptance = {
					target = root.culture
					value >= 25
				}
			}
		}
		any_vassal_or_below  = { # You need a minimum acceptance with any culture with the innovation
			culture = {
				has_innovation = $PARAMETER$
				cultural_acceptance = {
					target = root.culture
					value >= 25
				}
			}
		}
		any_liege_or_above  = { # You need a minimum acceptance with any culture with the innovation
			culture = {
				has_innovation = $PARAMETER$
				cultural_acceptance = {
					target = root.culture
					value >= 25
				}
			}
		}
	}
}

smu_valid_for_maa_samurai_trigger = {
	NOR = {
		root.faith = faith:ikkoshu
		root.faith = faith:hokkeshu
		root.culture = { has_cultural_pillar = heritage_buddhist }
	}
	OR = {
		AND = {
			is_landless_adventurer = yes
			has_perk = planned_cultivation_perk
			location.county.culture = { has_innovation = $PARAMETER$ }
		}
		AND = {
			is_landless_adventurer = no
			culture = { has_innovation = $PARAMETER$ }
		}
		any_sub_realm_county = { # You need a minimum acceptance with any culture speaking the language
			culture ?= {
				has_innovation = $PARAMETER$
				cultural_acceptance = {
					target = scope:character.culture
					value >= 25
				}
			}
		}
		any_vassal_or_below  = { # You need a minimum acceptance with any culture with the innovation
			culture ?= {
				has_innovation = $PARAMETER$
				cultural_acceptance = {
					target = scope:character.culture
					value >= 25
				}
			}
		}
		any_liege_or_above  = { # You need a minimum acceptance with any culture with the innovation
			culture ?= {
				has_innovation = $PARAMETER$
				cultural_acceptance = {
					target = root.culture
					value >= 25
				}
			}
		}
	}
}

smu_valid_for_maa_buddhist_trigger = {
	OR = {
		root.faith = faith:ikkoshu
		root.faith = faith:hokkeshu
		root.culture = { has_cultural_pillar = heritage_buddhist }
	}
	OR = {
		AND = {
			is_landless_adventurer = yes
			has_perk = planned_cultivation_perk
			location.county.culture = { has_innovation = $PARAMETER$ }
		}
		culture = { has_innovation = $PARAMETER$ }
		any_sub_realm_county = { # You need a minimum acceptance with any culture speaking the language
			culture ?= {
				has_innovation = $PARAMETER$
				cultural_acceptance = {
					target = scope:character.culture
					value >= 25
				}
			}
		}
		any_vassal_or_below  = { # You need a minimum acceptance with any culture with the innovation
			culture ?= {
				has_innovation = $PARAMETER$
				cultural_acceptance = {
					target = scope:character.culture
					value >= 25
				}
			}
		}
		any_liege_or_above  = { # You need a minimum acceptance with any culture with the innovation
			culture ?= {
				has_innovation = $PARAMETER$
				cultural_acceptance = {
					target = root.culture
					value >= 25
				}
			}
		}
	}
}

smu_valid_for_maa_nanban_trigger = {
	OR = {
		root.religion = religion:christianity_religion
		root.religion = religion:islam_religion
	}
	OR = {
		root.culture = { has_cultural_pillar = heritage_akan }
		root.culture = { has_cultural_pillar = heritage_arabic }
		root.culture = { has_cultural_pillar = heritage_berber }
		root.culture = { has_cultural_pillar = heritage_bantu }
		root.culture = { has_cultural_pillar = heritage_senegambian }
		root.culture = { has_cultural_pillar = heritage_sahelian }
		root.culture = { has_cultural_pillar = heritage_somalian }
		root.culture = { has_cultural_pillar = heritage_yoruba }
		root.culture = { has_cultural_pillar = heritage_west_african }
		root.culture = { has_cultural_pillar = heritage_east_african }
		root.culture = { has_cultural_pillar = heritage_turkic }
		root.culture = { has_cultural_pillar = heritage_iranian }
		root.culture = { has_cultural_pillar = heritage_mongolic }
		root.culture = { has_cultural_pillar = heritage_west_germanic }
		root.culture = { has_cultural_pillar = heritage_central_germanic }
		root.culture = { has_cultural_pillar = heritage_north_germanic }
		root.culture = { has_cultural_pillar = heritage_east_slavic }
		root.culture = { has_cultural_pillar = heritage_west_slavic }
		root.culture = { has_cultural_pillar = heritage_south_slavic }
		root.culture = { has_cultural_pillar = heritage_frankish }
		root.culture = { has_cultural_pillar = heritage_iberian }
		root.culture = { has_cultural_pillar = heritage_latin }
		root.culture = { has_cultural_pillar = heritage_goidelic }
		root.culture = { has_cultural_pillar = heritage_brythonic }
		root.culture = { has_cultural_pillar = heritage_byzantine }
	}
	OR = {
		AND = {
			is_landless_adventurer = yes
			has_perk = planned_cultivation_perk
			location.county.culture = { has_innovation = $PARAMETER$ }
		}
		culture = { has_innovation = $PARAMETER$ }
		any_sub_realm_county = { # You need a minimum acceptance with any culture speaking the language
			culture ?= {
				has_innovation = $PARAMETER$
				cultural_acceptance = {
					target = scope:character.culture
					value >= 25
				}
			}
		}
		any_vassal_or_below  = { # You need a minimum acceptance with any culture with the innovation
			culture ?= {
				has_innovation = $PARAMETER$
				cultural_acceptance = {
					target = scope:character.culture
					value >= 25
				}
			}
		}
		any_liege_or_above  = { # You need a minimum acceptance with any culture with the innovation
			culture ?= {
				has_innovation = $PARAMETER$
				cultural_acceptance = {
					target = root.culture
					value >= 25
				}
			}
		}
	}
}

smu_valid_for_maa_mercenary_trigger = {
	OR = {
		AND = {
			is_landless_adventurer = yes
			location.county.culture ?= { has_innovation = $PARAMETER$ }
		}
		culture = { has_innovation = $PARAMETER$ }
	}
}

smu_valid_for_maa_title_trigger = {
	primary_title = { has_variable = founded_great_guards }
	OR = {
		AND = {
			is_landless_adventurer = no
			culture = { has_innovation = $PARAMETER$ }
		}
		any_sub_realm_county = { # You need a minimum acceptance with any culture with the innovation
			county.culture = {
				has_innovation = $PARAMETER$
				cultural_acceptance = {
					target = root.culture
					value >= 25
				}
			}
		}
		any_vassal_or_below  = { # You need a minimum acceptance with any culture with the innovation
			culture = {
				has_innovation = $PARAMETER$
				cultural_acceptance = {
					target = root.culture
					value >= 25
				}
			}
		}
	}
}