﻿bap_has_any_pet_trigger = {
	OR = {
		has_cat_trigger = yes
		has_dog_trigger = yes
		has_eagle_trigger = yes
		any_owned_story = { type = story_cycle_martial_lifestyle_warhorse }
		has_exotic_pet_trigger = yes
		has_character_flag = bap_wolf_pet_alive
		has_character_flag = bap_bear_pet_alive
		has_character_flag = bap_lion_pet_alive
		has_character_flag = bap_tiger_pet_alive
	}
}

bap_domain_has_stables_trigger = {
	any_directly_owned_province = {
		has_building_or_higher = stables_01
	}
}

bap_domain_has_hunting_ground_trigger = {
	any_directly_owned_province = {
		OR = {
			has_building_or_higher = hunting_grounds_01
			has_building_or_higher = royal_forest_01
		}
	}
}

bap_has_imperial_menagerie_status_trigger = {
	OR = {
		has_royal_court = yes
		highest_held_title_tier >= tier_kingdom
	}
}

bap_can_buy_cat_trigger = {
	always = yes
}

bap_can_buy_dog_trigger = {
	OR = {
		bap_domain_has_hunting_ground_trigger = yes
		employs_court_position = master_of_hunt_court_position
	}
}

bap_can_buy_eagle_trigger = {
	OR = {
		location = { geographical_region = world_steppe }
		culture = { has_cultural_tradition = tradition_horse_lords }
		culture = { has_cultural_tradition = tradition_horse_breeder }
	}
}

bap_can_buy_warhorse_trigger = {
	bap_domain_has_stables_trigger = yes
}

bap_can_buy_wolf_trigger = {
	OR = {
		bap_domain_has_hunting_ground_trigger = yes
		culture = { has_cultural_tradition = tradition_caucasian_wolves }
	}
}

bap_can_buy_bear_trigger = {
	bap_domain_has_hunting_ground_trigger = yes
}

bap_can_buy_lion_trigger = {
	bap_has_imperial_menagerie_status_trigger = yes
	location = {
		OR = {
			geographical_region = world_africa
			geographical_region = world_middle_east
		}
	}
}

bap_can_buy_tiger_trigger = {
	bap_has_imperial_menagerie_status_trigger = yes
	location = {
		OR = {
			geographical_region = world_india
			geographical_region = world_asia
		}
	}
}

bap_pet_gift_recent_refusal_trigger = {
	OR = {
		has_opinion_modifier = {
			target = scope:actor
			modifier = bap_pet_gift_refused_common_opinion
		}
		has_opinion_modifier = {
			target = scope:actor
			modifier = bap_pet_gift_refused_prized_opinion
		}
		has_opinion_modifier = {
			target = scope:actor
			modifier = bap_pet_gift_refused_exotic_opinion
		}
	}
}

bap_can_receive_pet_gift_trigger = {
	is_alive = yes
	is_adult = yes
	is_imprisoned = no
	NOT = { bap_has_any_pet_trigger = yes }
	NOT = { bap_pet_gift_recent_refusal_trigger = yes }
}

bap_can_afford_cat_pet_upkeep_trigger = {
	yearly_character_income >= bap_cat_pet_yearly_upkeep_value
}

bap_can_afford_dog_pet_upkeep_trigger = {
	yearly_character_income >= bap_dog_pet_yearly_upkeep_value
}

bap_can_afford_eagle_pet_upkeep_trigger = {
	yearly_character_income >= bap_eagle_pet_yearly_upkeep_value
}

bap_can_afford_warhorse_pet_upkeep_trigger = {
	yearly_character_income >= bap_warhorse_pet_yearly_upkeep_value
}

bap_can_afford_wolf_pet_upkeep_trigger = {
	yearly_character_income >= bap_wolf_pet_yearly_upkeep_value
}

bap_can_afford_bear_pet_upkeep_trigger = {
	yearly_character_income >= bap_bear_pet_yearly_upkeep_value
}

bap_can_afford_lion_pet_upkeep_trigger = {
	yearly_character_income >= bap_lion_pet_yearly_upkeep_value
}

bap_can_afford_tiger_pet_upkeep_trigger = {
	yearly_character_income >= bap_tiger_pet_yearly_upkeep_value
}
