# is_born_under_Aries_trigger
# is_born_under_Taurus_trigger
# is_born_under_Gemini_trigger
# is_born_under_Cancer_trigger
# is_born_under_Leo_trigger
# is_born_under_Virgo_trigger
# is_born_under_Libra_trigger
# is_born_under_Scorpius_trigger
# is_born_under_Sagittarius_trigger
# is_born_under_Capricorn_trigger
# is_born_under_Aquarius_trigger
# is_born_under_Pisces_trigger

# is_ingredient_herb_trigger
# is_ingredient_animal_part_trigger
# is_ingredient_powder_trigger
# is_ingredient_liquid_trigger

# has_a_herb_ingredient_trigger
# has_an_animal_part_ingredient_trigger
# has_a_powder_ingredient_trigger
# has_a_liquid_ingredient_trigger

# has_selected_herb_ingredient_1_trigger
# has_selected_animal_part_ingredient_1_trigger
# has_selected_powder_ingredient_1_trigger
# has_selected_liquid_ingredient_1_trigger
# has_selected_herb_ingredient_2_trigger
# has_selected_animal_part_ingredient_2_trigger
# has_selected_powder_ingredient_2_trigger
# has_selected_liquid_ingredient_2_trigger
# has_selected_ingredient_1_trigger
# has_selected_ingredient_2_trigger
# selected_ingredient_is_sleep_inducing_trigger
# selected_ingredient_is_antipyretic_trigger
# selected_ingredient_is_perceived_healthy_trigger
# selected_ingredient_is_unhealthy_trigger
# selected_ingredient_1_and_2_are_same
# ingredient_is_sleep_inducing_trigger
# ingredient_is_antipyretic_trigger
# ingredient_is_perceived_healthy_trigger
# ingredient_is_unhealthy_trigger

# Some may be haruspicy instead?
# has_a_seer_modifier_trigger
# has_an_omen_modifier_trigger
# has_positive_omen_modifier_trigger
# has_negative_omen_modifier_trigger
# has_battle_omen_modifier_trigger
# has_relationship_omen_modifier_trigger
# has_power_omen_modifier_trigger
# has_childhood_horoscope_modifier_trigger

is_born_under_Aries_trigger = {
	trigger_if = {
		limit = { month_of_birth == 3 }
		day_of_birth >= 20
	}
	trigger_else = {
		month_of_birth == 4
		day_of_birth < 19
	}
}

is_born_under_Taurus_trigger = {
	trigger_if = {
		limit = { month_of_birth == 4 }
		day_of_birth >= 19
	}
	trigger_else = {
		month_of_birth == 5
		day_of_birth < 20
	}
}

is_born_under_Gemini_trigger = {
	trigger_if = {
		limit = { month_of_birth == 5 }
		day_of_birth >= 20
	}
	trigger_else = {
		month_of_birth == 6
		day_of_birth < 21
	}
}

is_born_under_Cancer_trigger = {
	trigger_if = {
		limit = { month_of_birth == 6 }
		day_of_birth >= 21
	}
	trigger_else = {
		month_of_birth == 7
		day_of_birth < 22
	}
}

is_born_under_Leo_trigger = {
	trigger_if = {
		limit = { month_of_birth == 7 }
		day_of_birth >= 22
	}
	trigger_else = {
		month_of_birth == 8
		day_of_birth < 22
	}
}

is_born_under_Virgo_trigger = {
	trigger_if = {
		limit = { month_of_birth == 8 }
		day_of_birth >= 22
	}
	trigger_else = {
		month_of_birth == 9
		day_of_birth < 22
	}
}

is_born_under_Libra_trigger = {
	trigger_if = {
		limit = { month_of_birth == 9 }
		day_of_birth >= 22
	}
	trigger_else = {
		month_of_birth == 10
		day_of_birth < 23
	}
}

is_born_under_Scorpius_trigger = {
	trigger_if = {
		limit = { month_of_birth == 10 }
		day_of_birth >= 23
	}
	trigger_else = {
		month_of_birth == 11
		day_of_birth < 22
	}
}

is_born_under_Sagittarius_trigger = {
	trigger_if = {
		limit = { month_of_birth == 11 }
		day_of_birth >= 22
	}
	trigger_else = {
		month_of_birth == 12
		day_of_birth < 21
	}
}

is_born_under_Capricorn_trigger = {
	trigger_if = {
		limit = { month_of_birth == 12 }
		day_of_birth >= 21
	}
	trigger_else = {
		month_of_birth == 1
		day_of_birth < 19
	}
}

is_born_under_Aquarius_trigger = {
	trigger_if = {
		limit = { month_of_birth == 1 }
		day_of_birth >= 19
	}
	trigger_else = {
		month_of_birth == 2
		day_of_birth < 18
	}
}

is_born_under_Pisces_trigger = {
	trigger_if = {
		limit = { month_of_birth == 2 }
		day_of_birth >= 18
	}
	trigger_else = {
		month_of_birth == 3
		day_of_birth < 20
	}
}

# To check type of ingredient... (if more are added, they need to go in here to work with the current system)
is_ingredient_herb_trigger = {
	OR = {
		artifact_type = ingredient_herb1
		artifact_type = ingredient_herb2
		artifact_type = ingredient_herb3
		artifact_type = ingredient_herb4
		artifact_type = ingredient_herb5
		artifact_type = ingredient_herb6
		artifact_type = ingredient_herb7
		artifact_type = ingredient_herb8
		artifact_type = ingredient_herb9
	}
}

is_ingredient_animal_part_trigger = {
	OR = {
		artifact_type = ingredient_animal1
		artifact_type = ingredient_animal2
		artifact_type = ingredient_animal3
		artifact_type = ingredient_animal4
		artifact_type = ingredient_animal5
		artifact_type = ingredient_animal6
		artifact_type = ingredient_animal7
		artifact_type = ingredient_animal8
		artifact_type = ingredient_animal9
	}
}

is_ingredient_powder_trigger = {
	OR = {
		artifact_type = ingredient_metal_exotic1
		artifact_type = ingredient_metal_exotic5
		artifact_type = ingredient_metal_exotic6
		artifact_type = ingredient_metal_exotic7
		artifact_type = ingredient_metal_exotic8
		artifact_type = ingredient_metal_exotic9
	}
}

is_ingredient_liquid_trigger = {
	OR = {
		artifact_type = ingredient_metal_exotic2
		artifact_type = ingredient_metal_exotic3
		artifact_type = ingredient_metal_exotic4
	}
}

# To check which ingredient TO BE selected (via scripted effects)...
has_a_herb_ingredient_trigger = {
	any_artifact = {
		is_ingredient_herb_trigger = yes
	}
}

has_an_animal_part_ingredient_trigger = {
	any_artifact = {
		is_ingredient_animal_part_trigger = yes
	}
}

has_a_powder_ingredient_trigger = {
	any_artifact = {
		is_ingredient_powder_trigger = yes
	}
}

has_a_liquid_ingredient_trigger = {
	any_artifact = {
		is_ingredient_liquid_trigger = yes
	}
}

# To check if HAS selected (via scripted effects) an ingredient...
has_selected_herb_ingredient_1_trigger = {
	any_artifact = {
		has_artifact_flag = selected_ingredient_1
		is_ingredient_herb_trigger = yes
	}
}

has_selected_animal_part_ingredient_1_trigger = {
	any_artifact = {
		has_artifact_flag = selected_ingredient_1
		is_ingredient_animal_part_trigger = yes
	}
}

has_selected_powder_ingredient_1_trigger = {
	any_artifact = {
		has_artifact_flag = selected_ingredient_1
		is_ingredient_powder_trigger = yes
	}
}

has_selected_liquid_ingredient_1_trigger = {
	any_artifact = {
		has_artifact_flag = selected_ingredient_1
		is_ingredient_liquid_trigger = yes
	}
}

has_selected_herb_ingredient_2_trigger = {
	any_artifact = {
		has_artifact_flag = selected_ingredient_2
		is_ingredient_herb_trigger = yes
	}
}

has_selected_animal_part_ingredient_2_trigger = {
	any_artifact = {
		has_artifact_flag = selected_ingredient_2
		is_ingredient_animal_part_trigger = yes
	}
}

has_selected_powder_ingredient_2_trigger = {
	any_artifact = {
		has_artifact_flag = selected_ingredient_2
		is_ingredient_powder_trigger = yes
	}
}

has_selected_liquid_ingredient_2_trigger = {
	any_artifact = {
		has_artifact_flag = selected_ingredient_2
		is_ingredient_liquid_trigger = yes
	}
}

has_selected_ingredient_1_trigger = {
	any_artifact = {
		has_artifact_flag = selected_ingredient_1
	}
}

has_selected_ingredient_2_trigger = {
	any_artifact = {
		has_artifact_flag = selected_ingredient_2
	}
}

selected_ingredient_is_sleep_inducing_trigger = {
	any_artifact = {
		OR = {
			has_artifact_flag = selected_ingredient_1
			has_artifact_flag = selected_ingredient_2
		}

		OR = {
			artifact_type = ingredient_herb7
			artifact_type = ingredient_herb3
			artifact_type = ingredient_herb9
		}
	}
}

selected_ingredient_is_antipyretic_trigger = {
	any_artifact = {
		OR = {
			has_artifact_flag = selected_ingredient_1
			has_artifact_flag = selected_ingredient_2
		}

		OR = {
			artifact_type = ingredient_herb1
			artifact_type = ingredient_herb2
			artifact_type = ingredient_herb4
			artifact_type = ingredient_herb5
			artifact_type = ingredient_herb8
			artifact_type = ingredient_metal_exotic6
		}
	}
}

selected_ingredient_is_perceived_healthy_trigger = {
	any_artifact = {
		OR = {
			has_artifact_flag = selected_ingredient_1
			has_artifact_flag = selected_ingredient_2
		}

		OR = {
			trigger_if = {
				limit = { is_ingredient_herb_trigger = yes }
				NOT = { artifact_type = ingredient_herb3 } # Mandrake
			}

			artifact_type = ingredient_metal_exotic2 # Mercury
			artifact_type = ingredient_metal_exotic8 # Iron
			artifact_type = ingredient_metal_exotic6 # Gold

			artifact_type = ingredient_animal2 # Kidney
			artifact_type = ingredient_animal7 # Heart
			artifact_type = ingredient_animal8 # Liver
			artifact_type = ingredient_animal9 # Intestines
		}
	}
}

selected_ingredient_is_unhealthy_trigger = {
	any_artifact = {
		OR = {
			has_artifact_flag = selected_ingredient_1
			has_artifact_flag = selected_ingredient_2
		}

		OR = {
			artifact_type = ingredient_herb3 # Mandrake
			artifact_type = ingredient_metal_exotic2 # Mercury
			artifact_type = ingredient_metal_exotic8 # Iron
			is_ingredient_animal_part_trigger = yes
		}
	}
}

selected_ingredient_1_and_2_are_same = {
	# Checks whether the ingredients selected are same type, such as two Hibiscus (if so, returns true)...
	any_artifact = {
		has_artifact_flag = selected_ingredient_1

		ROOT = {
			any_artifact = {
				has_artifact_flag = selected_ingredient_2
				is_artifact_same_type_as = PREVPREV
			}
		}
	}
}

ingredient_is_sleep_inducing_trigger = {
	OR = {
		artifact_type = ingredient_herb7
		artifact_type = ingredient_herb3
		artifact_type = ingredient_herb9
	}
}

ingredient_is_antipyretic_trigger = {
	OR = {
		artifact_type = ingredient_herb1
		artifact_type = ingredient_herb2
		artifact_type = ingredient_herb4
		artifact_type = ingredient_herb5
		artifact_type = ingredient_herb8
		artifact_type = ingredient_metal_exotic6
	}
}

ingredient_is_perceived_healthy_trigger = {
	OR = {
		trigger_if = {
			limit = { is_ingredient_herb_trigger = yes }
			NOT = { artifact_type = ingredient_herb3 } # Mandrake
		}

		artifact_type = ingredient_metal_exotic2 # Mercury
		artifact_type = ingredient_metal_exotic8 # Iron
		artifact_type = ingredient_metal_exotic6 # Gold

		artifact_type = ingredient_animal2 # Kidney
		artifact_type = ingredient_animal7 # Heart
		artifact_type = ingredient_animal8 # Liver
		artifact_type = ingredient_animal9 # Intestines
	}
}

ingredient_is_unhealthy_trigger = {
	OR = {
		artifact_type = ingredient_herb3 # Mandrake
		artifact_type = ingredient_metal_exotic2 # Mercury
		artifact_type = ingredient_metal_exotic8 # Iron

		AND = {
			is_ingredient_animal_part_trigger = yes

			NOR = {
				artifact_type = ingredient_animal2 # Kidney
				artifact_type = ingredient_animal7 # Heart
				artifact_type = ingredient_animal8 # Liver
				artifact_type = ingredient_animal9 # Intestines
			}
		}
	}
}

has_a_seer_modifier_trigger = {
	OR = {
		has_character_modifier = fulfilled_vision_great
		has_character_modifier = fulfilled_vision_ok
		has_character_modifier = fulfilled_vision_bad
		has_character_modifier = fulfilled_vision_worst
	}
}

has_an_omen_modifier_trigger = {
	OR = {
		has_character_modifier = good_battle_omen
		has_character_modifier = good_relationship_omen
		has_character_modifier = good_power_omen
		has_character_modifier = bad_battle_omen
		has_character_modifier = bad_relationship_omen
		has_character_modifier = bad_power_omen
	}
}

has_positive_omen_modifier_trigger = {
	OR = {
		has_character_modifier = good_battle_omen
		has_character_modifier = good_relationship_omen
		has_character_modifier = good_power_omen
	}
}

has_negative_omen_modifier_trigger = {
	OR = {
		has_character_modifier = bad_battle_omen
		has_character_modifier = bad_relationship_omen
		has_character_modifier = bad_power_omen
	}
}

has_battle_omen_modifier_trigger = {
	OR = {
		has_character_modifier = good_battle_omen
		has_character_modifier = bad_battle_omen
	}
}

has_relationship_omen_modifier_trigger = {
	OR = {
		has_character_modifier = good_relationship_omen
		has_character_modifier = bad_relationship_omen
	}
}

has_power_omen_modifier_trigger = {
	OR = {
		has_character_modifier = good_power_omen
		has_character_modifier = bad_power_omen
	}
}

has_childhood_horoscope_modifier_trigger = {
	OR = {
		has_character_modifier = guided_by_horoscope_diplomacy
		has_character_modifier = guided_by_horoscope_martial
		has_character_modifier = guided_by_horoscope_stewardship
		has_character_modifier = guided_by_horoscope_intrigue
		has_character_modifier = guided_by_horoscope_learning
	}
}