namespace = byzsla_slavic_event_spec
############################
#### Równowaga
#byzsla_slavic_event_spec.1 - redukcja MA za prymitywizm
#byzsla_slavic_event_spec.13 - Dobrawa kijowska staje się chłopem
#byzsla_slavic_event_spec.16 - Cotamcotam
#### Takietam
#byzsla_slavic_event_spec.2 - chasnik
#### miliarna pomoc w krucjatach
#byzsla_slavic_event_spec.9 - Pomoc Peruna
#byzsla_slavic_event_spec.3 - Pomoc Mokosz
#byzsla_slavic_event_spec.4 - Pomoc Roda
#byzsla_slavic_event_spec.5 - Pomoc Swaroga
#byzsla_slavic_event_spec.6 - Pomoc Jaryły
#byzsla_slavic_event_spec.7 - Pomoc Dadźboga
#byzsla_slavic_event_spec.8 - Pomoc łady
#byzsla_slavic_event_spec.10 - Czyścić
#### kaganat
#byzsla_slavic_event_spec.11 - Utworzenie kaganatu ruskiego
#byzsla_slavic_event_spec.12 - info dla świata o kaganacie
#byzsla_slavic_event_spec.14 - Upadek kaganatu, przybycie Ruryka (do zrobienia)
#### Na bazie 2.6.2
#byzsla_slavic_event_spec.15 - Krzyżowiec dla welesowców
#### antyimperializm
#byzsla_slavic_event_spec.21 - etnocentryczna wiara
#byzsla_slavic_event_spec.22 - debilizm jedynaka
#### Rządowe - Federacja
#byzsla_slavic_event_spec.30 - Plemiona są niezadowolone (za długa wojna)
#byzsla_slavic_event_spec.31 - Niepokoje plemienne (wojna zbyt długa)
#byzsla_slavic_event_spec.32 - Czyszczenei flagi niezadowolenia
#byzsla_slavic_event_spec.33 - Praca dla wspólnego dobra (senior)
#byzsla_slavic_event_spec.34 - Praca dla wspólnego dobra (wasal)
#byzsla_slavic_event_spec.35 - Sąsiad rajduje sąsiada
#byzsla_slavic_event_spec.36 - Sąsiad mnie rajduje
#byzsla_slavic_event_spec.37 - Członek federacji dostaje claima
#byzsla_slavic_event_spec.38 - Przysięga lojalności
#byzsla_slavic_event_spec.39 - zdyscyplinowanie młodych
#byzsla_slavic_event_spec.40 - Członek federacji dostaje rajderów
#byzsla_slavic_event_spec.41 - Podział łupów (senior)
#byzsla_slavic_event_spec.42 - Podział łupów (wasale)
#byzsla_slavic_event_spec.43 - Pogarda z powodu najmitów
#byzsla_slavic_event_spec.44 - Wygladamy na słabych
#byzsla_slavic_event_spec.45 - Gloria całej federacji (senior)
#byzsla_slavic_event_spec.46 - Gloria całej federacji (wasal)
#byzsla_slavic_event_spec.47 - Upadek ideałów federacji
#### Rządowe - Monarchia
#byzsla_slavic_event_spec.48 - 	Specjalne trybuty (senior)
#byzsla_slavic_event_spec.49 - 	Specjalne trybuty (wasal))
#byzsla_slavic_event_spec.50 - 	Odmowa (CB)
#byzsla_slavic_event_spec.51 - 	Przyjęcie
#byzsla_slavic_event_spec.52 - Śmierć wielkiego wodza (inicjacja)
#byzsla_slavic_event_spec.53 - Śmierć wielkiego wodza (syn)
#byzsla_slavic_event_spec.54 - Budowa kopca zakończona
#byzsla_slavic_event_spec.55 - Budowa mauzoleum zakończona
#byzsla_slavic_event_spec.56 - Migracje do stolicy
#byzsla_slavic_event_spec.57 - Migracje do stolicy (wasal)
#byzsla_slavic_event_spec.58 - Okazja korupcji (doradca)
#byzsla_slavic_event_spec.59 - Okradziono nas (nie wiadomo kto)
#byzsla_slavic_event_spec.60 - Okradziono nas (wiadomo kto)
#byzsla_slavic_event_spec.61 - Prymat prawa religijnego nad plemiennym
#byzsla_slavic_event_spec.62 - Nowe rody rzemieślnicze vs prawo plemienne
#byzsla_slavic_event_spec.63 - Chłopi są wkurzeni nowymi podatkami
#byzsla_slavic_event_spec.64 - Gloria rodu
#### Rządowe - Despocja
#byzsla_slavic_event_spec.65 - Zmuś członka rady do favoru (senior start)
#byzsla_slavic_event_spec.66 - Zmuś członka rady do favoru (wasal zapytanie)
#byzsla_slavic_event_spec.67 - Zmuś członka rady do favoru (senior rezultat pozytywny)
#byzsla_slavic_event_spec.68 - Zmuś członka rady do favoru (senior rezultat negatywny)
#byzsla_slavic_event_spec.69 - Zmuś członka rady do favoru (wasal śmierć)
#### Rządowe - Dzielnica piastowska
#byzsla_slavic_event_spec.70 - Ambitna żona (inicjacja)
#byzsla_slavic_event_spec.71 - Żona podbudza twoje ambicje
#byzsla_slavic_event_spec.72 - Żona fałszuje papiery na claimy (inicjacja)
#byzsla_slavic_event_spec.73 - Żona fałszuje papiery na claimy (dostanie)
#byzsla_slavic_event_spec.74 - Oskarżenie o oszustwo
#byzsla_slavic_event_spec.75 - Oskarżenie o oszustwo (senior)
#byzsla_slavic_event_spec.76 - Awanturnicy dołączają do bratobójczej wojny
#byzsla_slavic_event_spec.77 - Żydowski specjalista
#byzsla_slavic_event_spec.78 - Rywalizacja z bratem
#byzsla_slavic_event_spec.79 - USUNIĘTO
#### Rządowe - Carat/kaganat
#byzsla_slavic_event_spec.80 - Narodziny miast-molochów (senior)
#byzsla_slavic_event_spec.81 - Narodziny miast-molochów (wasale)
#byzsla_slavic_event_spec.82 - Monogorod
############################
character_event = {
	id = byzsla_slavic_event_spec.1
	desc = desc_byzsla_slavic_event_spec.1
	
	picture = GFX_evt_daughter_asking_father
	trigger = {
		has_landed_title = k_papal_state
		NOT = { has_global_flag = byzsla_slavic_prmityw }
	}
	
	is_triggered_only = yes
	
	option = {
		name = optA_byzsla_slavic_event_mokosz.1
		set_global_flag = byzsla_slavic_prmityw
		random_independent_ruler = {
			limit = {
				religion = slavic_pagan
			}
			religion_authority = {
				modifier = byzsla_slavic_prymitywizm
			}
		}
		activate_title = { title = d_great_volhv status = no }
		activate_title = { title = d_slavic_pagan_reformed status = no }
		activate_title = { title = c_druzyna_arkony status = no }
		activate_title = { title = c_druzyna_arkony2 status = no }
	}
}

#byzsla_slavic_event_spec.13 - Dobrawa kijowska staje się chłopem

character_event = {
	id = byzsla_slavic_event_spec.13
	hide_window = yes
	
	is_triggered_only = yes
	
	ai = yes
	
	trigger = {
		character = 194139
		is_ruler = yes
		NOT = { has_global_flag = dobrava_to_facet }
	}
	
	immediate = {
		create_random_intriguer = {
			random_traits = yes
			religion = ROOT
			culture = ROOT
			dynasty = ROOT
			age = 22
		}
		new_character = {
			change_martial = 3
			treasury = 300
			prestige = 100
			ROOT = {
				abdicate_to = PREV
			}
		}
	}
}


# chasnik
character_event = {
	id = byzsla_slavic_event_spec.2
	desc = byzsla_slavic_event_spec.2
	picture = GFX_evt_vikings_arriving_oldgods
	border = GFX_event_normal_frame_war
	
	hide_from = yes
	
	is_triggered_only = yes
	
	min_age = 16
	only_men = yes
	capable_only = yes
	prisoner = no
	
	trigger = {
		NOT = { trait = byzsla_slavic_chasnik }
		is_slav_religion = yes
	}
	
	option = {
		name = optA_byzsla_slavic_event_spec.2
		add_trait = byzsla_slavic_chasnik
	}
}

#### miliarna pomoc w krucjatach
#byzsla_slavic_event_spec.9 - Pomoc Peruna
#byzsla_slavic_event_spec.3 - Pomoc Mokosz
#byzsla_slavic_event_spec.4 - Pomoc Roda
#byzsla_slavic_event_spec.5 - Pomoc Swaroga
#byzsla_slavic_event_spec.6 - Pomoc Jaryy
#byzsla_slavic_event_spec.7 - Pomoc Dadboga
#byzsla_slavic_event_spec.8 - Pomoc ady

character_event = {
	id = byzsla_slavic_event_spec.9
	desc = desc_byzsla_slavic_event_spec.9
	picture = GFX_evt_vikings_arriving_oldgods

	is_triggered_only = yes
	
	trigger = {
		has_global_flag = byzsla_slav_ghw_whp_flaga
	}
	
	option = {
		name = optA_byzsla_slavic_event_OK
		set_character_flag = byzsla_slavic_help_perun_flag
		clr_global_flag = byzsla_slav_ghw_whp_flaga
	}
}
character_event = {
	id = byzsla_slavic_event_spec.3
	desc = desc_byzsla_slavic_event_spec.3
	picture = GFX_evt_vikings_arriving_oldgods

	is_triggered_only = yes
	
	trigger = {
		has_global_flag = byzsla_slav_ghw_whp_flaga
	}
	
	option = {
		name = optA_byzsla_slavic_event_OK
		set_character_flag = byzsla_slavic_help_mokosz_flag
		clr_global_flag = byzsla_slav_ghw_whp_flaga
	}
}
character_event = {
	id = byzsla_slavic_event_spec.4
	desc = desc_byzsla_slavic_event_spec.4
	picture = GFX_evt_vikings_arriving_oldgods

	is_triggered_only = yes
	
	trigger = {
		has_global_flag = byzsla_slav_ghw_whp_flaga
	}
	
	option = {
		name = optA_byzsla_slavic_event_OK
		set_character_flag = byzsla_slavic_help_rod_flag
		clr_global_flag = byzsla_slav_ghw_whp_flaga
	}
}
character_event = {
	id = byzsla_slavic_event_spec.5
	desc = desc_byzsla_slavic_event_spec.5
	picture = GFX_evt_vikings_arriving_oldgods

	is_triggered_only = yes
	
	trigger = {
		has_global_flag = byzsla_slav_ghw_whp_flaga
	}
	
	option = {
		name = optA_byzsla_slavic_event_OK
		set_character_flag = byzsla_slavic_help_swarog_flag
		clr_global_flag = byzsla_slav_ghw_whp_flaga
	}
}
character_event = {
	id = byzsla_slavic_event_spec.6
	desc = desc_byzsla_slavic_event_spec.6
	picture = GFX_evt_vikings_arriving_oldgods

	is_triggered_only = yes
	
	trigger = {
		has_global_flag = byzsla_slav_ghw_whp_flaga
	}
	
	option = {
		name = optA_byzsla_slavic_event_OK
		set_character_flag = byzsla_slavic_help_jarilo_flag
		clr_global_flag = byzsla_slav_ghw_whp_flaga
	}
}
character_event = {
	id = byzsla_slavic_event_spec.7
	desc = desc_byzsla_slavic_event_spec.7
	picture = GFX_evt_vikings_arriving_oldgods

	is_triggered_only = yes
	
	trigger = {
		has_global_flag = byzsla_slav_ghw_whp_flaga
	}
	
	option = {
		name = optA_byzsla_slavic_event_OK
		set_character_flag = byzsla_slavic_help_dadzbog_flag
		clr_global_flag = byzsla_slav_ghw_whp_flaga
	}
}

character_event = {
	id = byzsla_slavic_event_spec.8
	desc = desc_byzsla_slavic_event_spec.8
	picture = GFX_evt_vikings_arriving_oldgods

	is_triggered_only = yes
	
	trigger = {
		has_global_flag = byzsla_slav_ghw_whp_flaga
	}
	
	option = {
		name = optA_byzsla_slavic_event_OK
		set_character_flag = byzsla_slavic_help_lada_flag
		clr_global_flag = byzsla_slav_ghw_whp_flaga
	}
}

#byzsla_slavic_event_spec.10 - Czyci


character_event = {
	id = byzsla_slavic_event_spec.10
	desc = desc_byzsla_slavic_event_spec.10
	picture = GFX_evt_vikings_arriving_oldgods

	only_playable = no
	only_rulers = yes
	trigger = {
		has_landed_title = d_slavic_pagan_reformed
		OR = {
			has_character_flag = byzsla_slavic_help_perun_flag
			has_character_flag = byzsla_slavic_help_mokosz_flag
			has_character_flag = byzsla_slavic_help_rod_flag
			has_character_flag = byzsla_slavic_help_swarog_flag
			has_character_flag = byzsla_slavic_help_jarilo_flag
			has_character_flag = byzsla_slavic_help_dadzbog_flag
			has_character_flag = byzsla_slavic_help_lada_flag
		}
	}
	
	mean_time_to_happen = {
		days = 10
	}
	
	option = {
		name = optA_byzsla_slavic_event_OK
			clr_character_flag = byzsla_slavic_help_perun_flag
			clr_character_flag = byzsla_slavic_help_mokosz_flag
			clr_character_flag = byzsla_slavic_help_rod_flag
			clr_character_flag = byzsla_slavic_help_swarog_flag
			clr_character_flag = byzsla_slavic_help_jarilo_flag
			clr_character_flag = byzsla_slavic_help_dadzbog_flag
			clr_character_flag = byzsla_slavic_help_lada_flag
	}
}

#byzsla_slavic_event_spec.11 - Utworzenie kaganatu ruskiego

narrative_event = {
	id = byzsla_slavic_event_spec.11
	title = title_byzsla_slavic_event_spec.11
	desc = desc_byzsla_slavic_event_spec.11
	
	picture = GFX_evt_council
	border = GFX_event_narrative_frame_diplomacy
	
	is_triggered_only = yes
	
	immediate = {
		k_rus = {
			any_direct_de_jure_vassal_title = {
				de_jure_liege = k_rus_khagan
			}
			destroy_landed_title = THIS
			if = {
				limit = {
					NOT = {
						has_dlc = "Zeus"
						OR = {
							has_law = crown_authority_0
							has_law = crown_authority_1
							has_law = crown_authority_2
							has_law = crown_authority_3
							has_law = crown_authority_4
						}
					}
				}
				add_law = crown_authority_0
			}
		}
		any_playable_ruler = {
			limit = {
				NOT = { has_landed_title = k_rus_khagan }
				ai = no
			}
			narrative_event = { id = byzsla_slavic_event_spec.12 }
		}
		any_realm_province = {
			limit = {
				kingdom = {
					title = k_rus_khagan
				}
			}
			culture = ROOT
			religion = ROOT
		}
		any_claim = {
			remove_claim = ROOT
		}
	}
	
	option = {
		name = optA_byzsla_slavic_event_spec.11
		hidden_tooltip = {
			any_demesne_province = {
				any_province_holding = {
					limit = {
						OR = {
							holding_type = tribal
							holding_type = city
							holding_type = castle
						}
					}
					destroy_settlement = THIS
				}
			}
			scaled_wealth = { value = 2 min = 600 } 
			primary_title = {
				k_rus_khagan = {
					grant_title = PREV
					copy_title_laws = PREV
					copy_title_history = PREV
					de_jure_liege = e_russia
				}
			}
			set_government_type = nomadic_government
			any_vassal = {
				limit = {
					ai = yes
				}
				any_demesne_province = {
					any_province_holding = {
						limit = {
							OR = {
								holding_type = tribal
								holding_type = city
								holding_type = castle
							}
						}
						destroy_settlement = THIS
					}
				}
				any_demesne_title = {
					grant_title = ROOT
				}
				move_character = ROOT
				treasury = 600
				add_trait = ambitious
			}
		}
	}
}

narrative_event = {
	id = byzsla_slavic_event_spec.12
	title = title_byzsla_slavic_event_spec.11
	desc = desc_byzsla_slavic_event_spec.12
	
	picture = GFX_evt_council
	border = GFX_event_narrative_frame_diplomacy
	
	is_triggered_only = yes
	
	option = {
		name = EVTOPTA62911
	}
}

#byzsla_slavic_event_spec.15 - Krzyżowiec dla welesowców

character_event = {
	id = byzsla_slavic_event_spec.15
	desc = "EVTDESC8300"
	picture = "GFX_evt_bitwa"
	border = GFX_event_normal_frame_war
	
	min_age = 16
	capable_only = yes
	prisoner = no


	mean_time_to_happen = {
		days = 1
	}

	trigger = {
		NOT = { trait = byk_walesa }
		in_command = yes
		religion = chram_vales
		OR = {
			AND = {
				any_war = {
					using_cb = crusade
				}
				crusade_target = {
					is_located_in = ROOT
				}
			}
			any_liege = {
				religion = ROOT
				any_war = {
					using_cb = crusade
				}
				crusade_target = {
					is_located_in = ROOT
				}
			}
		}
	}

	
	option = {
		name = "8469.a"
		add_trait = byk_walesa
	}
}

character_event = {
	id = byzsla_slavic_event_spec.16
	
	is_triggered_only = yes
	hide_window = yes

	immediate = {
		any_realm_province = {
			any_province_holding = {
				remove_holding_modifier = support_mercenary_band_1
			}
		}
	}
}

character_event = {
	id = byzsla_slavic_event_spec.21
	
	is_triggered_only = yes
	hide_window = yes
	
	trigger = {
		has_landed_title = k_papal_state
		is_title_active = d_slavic_pagan_reformed
		NOT = { has_global_flag = bspm_etnocentryzm }
		NOT = { 
			any_independent_ruler = {
				count = 3
				religion = slavic_pagan_reformed
			}
		}
	}

	immediate = {
		set_global_flag = bspm_etnocentryzm
		random_independent_ruler = {
			limit = {
				religion = slavic_pagan_reformed
			}
			religion_authority = {
				modifier = byzsla_etnocentryzm
				years = 100
			}
		}
	}
}

#byzsla_slavic_event_spec.22 - debilizm jedynaka

character_event = {
	id = byzsla_slavic_event_spec.22
	
	is_triggered_only = yes
	hide_window = yes
	
	max_age = 25
	
	trigger = {
		father = {
			NOT = {
				ai = yes
			}
			is_alive = yes
			is_slav_religion = yes
			OR = {
				num_of_king_titles = 1
				num_of_emperor_titles = 1
			}
		}
		NOT = {
			any_sibling = {
				is_alive = yes
			}
		}
	}
	immediate = {
		random_list = {
			40 = {
				change_diplomacy = -1
			}
			40 = {
				change_intrigue = -1
			}
			40 = {
				change_learning = -1
			}
			40 = {
				change_martial = -1
			}
			10 = {
				if = {
					limit = {
						OR = {
							NOT = { trait = genius }
							NOT = { trait = imbecile }
							NOT = { trait = slow }
							NOT = { trait = quick }
							NOT = { trait = inbred }
						}
					}
					add_trait = slow
				}
			}
			70 = {}
		}
	}
}

#byzsla_slavic_event_spec.30 - Plemiona są niezadowolone (za długa wojna)

character_event = {
	id = byzsla_slavic_event_spec.30
	desc = byzsla_slavic_event_spec.30
	picture = GFX_evt_slavic_tribal
	border = GFX_event_normal_frame_war
	
	hide_from = yes
	
	is_triggered_only = yes
	
	trigger = {
		realm_size = 5
		OR = {
			bspm_tribal_despotism = yes
			bspm_tribal_monarchy = yes
			bspm_tribal_federation = yes
		}
		any_war = {
			NOT = { war_score = -15 }
			attacker = {
				character = ROOT
			}
		}
		war = yes
		is_inaccessible_trigger = no
		is_ruler = yes
		prisoner = no
		any_vassal = {
			is_tribal = yes
		}
		NOT = { has_character_flag = bspm_WE_flaga1 }
	}
	
	immediate = {
		set_character_flag = bspm_WE_flaga1
	}
	
	option = {
		name = optA_byzsla_slavic_event_spec.30
		any_vassal = {
			limit = {
				is_tribal = yes
			}
			opinion = { 
				modifier = opinion_unhappy
				who = ROOT
				years = 2
			}
		}
		hidden_tooltip = {
			character_event = {
				id = byzsla_slavic_event_spec.31
				days = 720
				random = 60
			}
		}
	}
	option = {
		name = optB_byzsla_slavic_event_spec.30
		trigger = {
			martial = 10
		}
		tooltip_info = martial
		prestige = 5
		random = {
			chance = 15
			change_diplomacy = 1
		}
		hidden_tooltip = {
			character_event = {
				id = byzsla_slavic_event_spec.31
				days = 720
				random = 60
			}
		}
	}
	option = {
		name = optC_byzsla_slavic_event_spec.30
		trigger = {
			diplomacy = 10
		}
		tooltip_info = diplomacy
		prestige = 5
		random = {
			chance = 15
			change_intrigue = 1
		}
		hidden_tooltip = {
			character_event = {
				id = byzsla_slavic_event_spec.31
				days = 720
				random = 60
			}
		}
	}
}

#byzsla_slavic_event_spec.31 - Niepokoje plemienne (wojna zbyt długa)

character_event = {
	id = byzsla_slavic_event_spec.31
	desc = desc_byzsla_slavic_event_spec.31
	picture = GFX_evt_slavic_tribal
	border = GFX_event_normal_frame_war
	
	hide_from = yes
	
	is_triggered_only = yes
	
	trigger = {
		realm_size = 5
		OR = {
			bspm_tribal_despotism = yes
			bspm_tribal_monarchy = yes
			bspm_tribal_federation = yes
		}
		any_war = {
			NOT = { war_score = -15 }
			attacker = {
				character = ROOT
			}
		}
		war = yes
		is_inaccessible_trigger = no
		is_ruler = yes
		prisoner = no
		any_vassal = {
			is_tribal = yes
		}
		has_character_flag = bspm_WE_flaga1
		NOT = {
			has_character_modifier = byzsla_zle_plemiona
		}
	}
	
	option = {
		name = optA_byzsla_slavic_event_spec.31
		add_character_modifier = {
			name = byzsla_zle_plemiona
			duration = 720
		}
		if = {
			limit = {
				has_dlc = "Reapers"
			}
			any_realm_province = {
				limit = {
					any_province_holding = { holding_type = tribal }
				}
				change_variable = { which = prosperity_value value = -12 }
			}
		}
		if = {
			limit = {
				NOT = { has_dlc = "Reapers" }
			}
			random_list = {
				60 = { scaled_wealth = -0.1 }
				30 = { scaled_wealth = -0.05 }
				10 = { scaled_wealth = -0.2 }
			}
		}
		prestige = -20
		hidden_tooltip = {
			character_event = {
				id = byzsla_slavic_event_spec.31
				days = 720
				random = 30
			}
		}
	}
}
#byzsla_slavic_event_spec.32 - Czyszczenei flagi

character_event = {
	id = byzsla_slavic_event_spec.32
	hide_window = yes
	
	is_triggered_only = yes
	
	trigger = {
		has_character_flag = bspm_WE_flaga1
		NOT = {
			any_war = {
				NOT = { war_score = -15 }
				attacker = {
					character = ROOT
				}
			}
			war = yes
		}
	}
	
	immediate = {
		clr_character_flag = bspm_WE_flaga1
	}
}

#byzsla_slavic_event_spec.33 - Praca dla wspólnego dobra

character_event = {
	id = byzsla_slavic_event_spec.33
	desc = desc_byzsla_slavic_event_spec.33
	picture = GFX_evt_slavic_tribal
	border = GFX_event_normal_frame_economy
	
	hide_from = yes
	
	mean_time_to_happen = {
		months = 100
	}
	only_playable = yes
	only_independent = yes
	religion_group = pagan_group
	trigger = {
		bspm_tribal_federation = yes
		NOT = { war = yes }
		num_of_vassals = 2
		any_vassal = {
			is_tribal = yes
			ROOT = {
				opinion = { who = PREV value = 20 } 
			}
		}
		any_demesne_province = {
			NOT = {
				has_province_modifier = byzsla_dobre_plemiona
			}
		}
		is_inaccessible_trigger = no
		is_ruler = yes
		prisoner = no
	}
	
	option = {
		name = optA_byzsla_slavic_event_spec.33
		any_vassal = {
			limit = {
				is_tribal = yes
				ROOT = {
					opinion = { who = PREV value = 20 } 
				}
			}
			character_event = {
				id = byzsla_slavic_event_spec.34
			}
		}
		any_demesne_province = {
			limit = {
				religion = ROOT
			}
			any_province_holding = {
				limit = {
					holding_type = tribal
				}
				add_holding_modifier = {
					modifier = byzsla_dobre_plemiona
					months = 12
				}
				if = {
					limit = {
						has_dlc = "Reapers"
					}
					any_realm_province = {
						limit = {
							any_province_holding = { holding_type = tribal }
						}
						change_variable = { which = prosperity_value value = 12 }
					}
				}
			}
		}
	}
}

character_event = {
	id = byzsla_slavic_event_spec.34
	desc = desc_byzsla_slavic_event_spec.33
	picture = GFX_evt_slavic_tribal
	border = GFX_event_normal_frame_economy
	
	is_triggered_only = yes
	
	option = {
		name = optA_byzsla_slavic_event_spec.33
		any_demesne_province = {
			limit = {
				religion = ROOT
			}
			any_province_holding = {
				limit = {
					holding_type = tribal
				}
				add_holding_modifier = {
					modifier = byzsla_dobre_plemiona
					months = 12
				}
				if = {
					limit = {
						has_dlc = "Reapers"
					}
					any_realm_province = {
						limit = {
							any_province_holding = { holding_type = tribal }
						}
						change_variable = { which = prosperity_value value = 12 }
					}
				}
			}
		}
	}
}
#byzsla_slavic_event_spec.35 - Sąsiad rajduje sąsiada


character_event = {
	id = byzsla_slavic_event_spec.35
	desc = desc_byzsla_slavic_event_spec.35
	picture = GFX_evt_bitwa
	border = GFX_event_normal_frame_economy
	
	mean_time_to_happen = {
		months = 100
	}
	only_playable = yes
	only_independent = yes
	religion_group = pagan_group
	trigger = {
		bspm_tribal_federation = yes
		NOT = { war = yes }
		any_demesne_province = {
			holding_type = tribal
			any_neighbor_province = {
				any_province_holding = {
					holding_type = tribal
				}
			}
		}
		is_inaccessible_trigger = no
		is_ruler = yes
		prisoner = no
	}
	
	immediate = {
		random_demesne_province = {
			limit = {
				any_province_holding = { holding_type = tribal }
			}
			set_province_flag = bspm_WE_flaga2
		}
	}
	
	option = {
		name = optA_byzsla_slavic_event_spec.35	#zrajduj go
		prestige = 30
		piety = -60
		if = {
			limit = {
				has_dlc = "Reapers"
			}
			custom_tooltip = {
				text = increase_prosperity_event_custom_tooltip
				hidden_tooltip = {
					random_demesne_province = {
						limit = {
							has_province_flag = bspm_WE_flaga2
						}
						change_variable = { which = prosperity_value value = 15 }
					}
				}
			}
		}
		random_demesne_province = {
			limit = {
				has_province_flag = bspm_WE_flaga2
			}
			add_province_modifier = {
				name = byzsla_rajd_wew
				duration = 365
			}
		}
		top_liege = {
			random_vassal = {
				limit ={
					NOT = { character = ROOT } 
					is_playable = yes
				}
				random_demesne_province = {
					province_event = {
						id = byzsla_slavic_event_spec.36
					}
				}
			}
		}
		hidden_tooltip = {
			random_demesne_province = {
				limit = {
					has_province_flag = bspm_WE_flaga2
				}
				clr_province_flag = bspm_WE_flaga2
			}
		}
	}
	option = {
		name = optB_byzsla_slavic_event_spec.35	#zostaw w spokoju
		prestige = -60
		piety = 30
		random_demesne_province = {
			limit = {
				has_province_flag = bspm_WE_flaga2
			}
			add_province_modifier = {
				name = peasants_scorned
				duration = 720
			}
		}
		hidden_tooltip = {
			random_demesne_province = {
				limit = {
					has_province_flag = bspm_WE_flaga2
				}
				clr_province_flag = bspm_WE_flaga2
			}
		}
	}
}

province_event = {
	id = byzsla_slavic_event_spec.36
	desc = desc_byzsla_slavic_event_spec.36
	picture = GFX_evt_bitwa
	border = GFX_event_normal_frame_economy
	
	is_triggered_only = yes
	
	option = {
		name = optA_byzsla_slavic_event_spec.36	
		if = {
			limit = {
				has_dlc = "Reapers"
			}
			custom_tooltip = {
				text = decrease_prosperity_custom_tooltip
				hidden_tooltip = {
					change_variable = { which = prosperity_value value = -20 }
				}
			}
		}
		add_province_modifier = {
			name = minor_pagan_border_raids
			duration = 720
		}
		owner = {
			prestige = -60
			opinion = { modifier = opinion_looted who = FROM years = 5 } 
		}
	}
	option = {
		name = optB_byzsla_slavic_event_spec.36
		if = {
			limit = {
				has_dlc = "Reapers"
			}
			custom_tooltip = {
				text = decrease_prosperity_custom_tooltip
				hidden_tooltip = {
					change_variable = { which = prosperity_value value = -20 }
				}
			}
		}
		add_province_modifier = {
			name = minor_pagan_border_raids
			duration = 720
		}
		owner = {
			prestige = -60
			opinion = { modifier = opinion_looted who = FROM years = 5 } 
			if = {
				limit = { ai = yes }
				random = {
					chance = 30
					add_rival = FROM
				}
			}
		}
	}
}

#byzsla_slavic_event_spec.37 - Członek federacji dostaje claima

character_event = {
	id = byzsla_slavic_event_spec.37
	desc = desc_byzsla_slavic_event_spec.37
	picture = GFX_evt_slavic_tribal
	border = GFX_event_normal_frame_diplomacy
	
	is_triggered_only = yes
	
	trigger = {
		is_slav_religion = yes
		is_playable = yes
		is_landed = yes
		is_tribal = yes
		NOT = { independent = yes }
		NOT = { war = yes }
		prestige = 100
		top_liege = {
			NOT = { war = yes }
			primary_title = {
				NOT = { claimed_by = ROOT }
			}
			NOT = { trait = content }
			bspm_tribal_federation = yes
			ROOT = {
				realm_levy_diff = { who = THIS value = 200 } 
			}
		}
		liege = {
			independent = yes
		}
	}
	
	option = {
		name = optA_byzsla_slavic_event_spec.37
		top_liege = {
			primary_title = {
				add_claim = ROOT
			}
		}
		random = {
			chance = 75
			add_trait = ambitious
		}
		random = {
			chance = 75
			top_liege = {
				add_rival = ROOT
			}
		}
		random = {
			chance = 50
			capital_scope = {
				PREV = {
					spawn_unit = {
						owner = ROOT
						province = PREV
						home = PREV
						troops = {
							archers = { 150 150 }
							light_infantry = { 300 300 }
							light_cavalry = { 100 100 }
						}
						attrition = 1.0
						maintenance_multiplier = 0.5
					}
				}
			}
		}
		any_vassal = {
			reverse_opinion = {
				who = ROOT
				modifier = strengthened_loyalty
				years = 3
			}
		}
		prestige = -100
		capital_scope = {
			PREV = {
				spawn_unit = {
					owner = ROOT
					province = PREV
					home = PREV
					troops = {
						archers = { 150 150 }
						light_infantry = { 300 300 }
						light_cavalry = { 100 100 }
					}
					attrition = 1.0
					maintenance_multiplier = 0.5
				}
			}
		}
	}
	option = {
		name = optA_byzsla_slavic_event_spec.37
		if = {
			limit = {
				has_dlc = "Reapers"
			}
			custom_tooltip = {
				text = capital_prospers_custom_tooltip
			}
			hidden_tooltip = {
				capital_scope = {
					change_variable = { which = prosperity_value value = 12 }
				}
			}
		}
		random = {
			chance = 75
			add_trait = content
		}
		scaled_wealth = {
			value = 5
			min = 50
			max = 250
		}
		custom_tooltip = {
			text = byzsla_slavic_event_spec.37_TT
			hidden_tooltip = {
				top_liege = {
					character_event = {
						id = byzsla_slavic_event_spec.38
					}
				}
			}
		}
	}
}

#byzsla_slavic_event_spec.38 - Przysięga lojalności

character_event = {
	id = byzsla_slavic_event_spec.38
	desc = desc_byzsla_slavic_event_spec.38
	picture = GFX_evt_slavic_tribal
	border = GFX_event_normal_frame_diplomacy
	
	is_triggered_only = yes
	
	option = {
		name = optA_byzsla_slavic_event_spec.38
		prestige = 50
		if = {
			limit = {
				NOT = { has_character_modifier = diligent_liege_morale }
			}
			add_character_modifier = {
				name = 	diligent_liege_morale
				days = 1400
			}
		}
		if = {
			limit = {
				has_character_modifier = diligent_liege_morale 
			}
			prestige = 100
		}
		opinion = { 
			modifier = dynastic_refused_claim 
			who = FROM 
			years = 5 
		}
		FROM = {
			reverse_opinion = {
				who = ROOT
				modifier = strengthened_loyalty
				years = 5
			}
		}
	}
}

#byzsla_slavic_event_spec.39 - zdyscyplinowanie młodych

character_event = {
	id = byzsla_slavic_event_spec.39
	desc = desc_byzsla_slavic_event_spec.39
	picture = GFX_evt_slavic_tribal
	border = GFX_event_normal_frame_war
	
	is_triggered_only = yes

	only_playable = yes
	trigger = {
		NOT = { war = yes }
		bspm_tribal_federation = yes
		NOT = {
			has_character_modifier = byzsla_starzy_OK
			has_character_modifier = byzsla_starzy_NOK
		}
	}
	
	option = {
		name = optA_byzsla_slavic_event_spec.39		#Wiedział nasz pradziad jak zwyciężać
		add_character_modifier = {
			name = byzsla_starzy_OK
			months = 60
		}
		custom_tooltip = {
			text = byzsla_slavic_event_spec.39_TT_A
		}
		hidden_tooltip = {
			any_courtier = {
				limit = {
					NOT = {
						age = 27
					}
				}
				opinion = {
					modifier = opinion_unreasonable
					who = ROOT
					years = 2
				}
			}
		}
		prestige = 50
		random_list = {
			30 = { military_techpoints = -30 }
			30 = { culture_techpoints = -30 }
			30 = { economy_techpoints = -30 }
		}
	}
	option = {
		name = optB_byzsla_slavic_event_spec.39		#Czasy się zmieniły
		add_character_modifier = {
			name = byzsla_starzy_NOK
			months = 60
		}
		custom_tooltip = {
			text = byzsla_slavic_event_spec.39_TT_B
		}
		hidden_tooltip = {
			any_courtier = {
				limit = {
					age = 40
				}
				opinion = {
					modifier = opinion_unreasonable
					who = ROOT
					years = 2
				}
			}
		}
		random_list = {
			30 = { military_techpoints = 25 }
			30 = { culture_techpoints = 25 }
			30 = { economy_techpoints = 25 }
		}
	}
}

#byzsla_slavic_event_spec.40 - Członek federacji dostaje rajderów

character_event = {
	id = byzsla_slavic_event_spec.40
	desc = desc_byzsla_slavic_event_spec.40
	picture = GFX_evt_slavic_tribal
	border = GFX_event_normal_frame_war
	
	is_triggered_only = yes

	only_playable = yes
	trigger = {
		NOT = { war = yes }
		is_slav_religion = yes
		any_demesne_province = {
			any_province_holding = { holding_type = tribal }
			NOT = {
				has_province_modifier = byzsla_korupcja_plemienna
			}
		}
		is_playable = yes
		is_landed = yes
		liege = {
			bspm_tribal_federation = yes
		}
	}
	immediate = {
		random_demesne_province = {
			limit = {
				any_province_holding = { holding_type = tribal }
				NOT = {
					has_province_modifier = byzsla_korupcja_plemienna
				}
			}
			set_province_flag = bspm_WE_flaga2
		}
	}
	
	option = {
		name = optA_byzsla_slavic_event_spec.40		#do zrajdowania
		capital_scope = {
			ROOT = {
				spawn_unit = {
					owner = THIS
					province = PREV
					home = PREV
					troops = {
						archers = { 200 200 }
						light_infantry = { 400 400 }
						light_cavalry = { 100 100 }
					}
					attrition = 1.0
					cannot_inherit = yes
					earmark = tribal_organize_raid
					is_looter = yes
				}
			}
		}
		character_event = { id = 20223 days = 30 }
		random_demesne_province = {
			limit = {
				has_province_flag = bspm_WE_flaga2
			}
			clr_province_flag = bspm_WE_flaga2
		}
	}
	option = {
		name = optB_byzsla_slavic_event_spec.40		#jest dobrze
		prestige = 50
		piety = 50
		random_demesne_province = {
			limit = {
				has_province_flag = bspm_WE_flaga2
			}
			add_province_modifier = {
				name = byzsla_korupcja_plemienna
				months = 36
			}
			clr_province_flag = bspm_WE_flaga2
		}
	}
	option = {
		name = optC_byzsla_slavic_event_spec.40		#won z oczu
		hidden_tooltip = {
			any_courtier = {
				limit = {
					NOT = {
						age = 27
					}
				}
				opinion = {
					modifier = opinion_unreasonable
					who = ROOT
					years = 2
				}
			}
		}
		prestige = 100
		piety = -50
		if = {
			limit = {
				trait = arbitrary
			}
			prestige = 100
		}
		if = {
			limit = {
				NOT = { trait = arbitrary }
			}
			add_trait = arbitrary
		}
		random_demesne_province = {
			limit = {
				has_province_flag = bspm_WE_flaga2
			}
			add_province_modifier = {
				name = arbitrary_steward
				months = 36
			}
			clr_province_flag = bspm_WE_flaga2
		}
	}
	option = {
		name = optD_byzsla_slavic_event_spec.40		#róbta co chceta
		random_demesne_province = {
			limit = {
				has_province_flag = bspm_WE_flaga2
			}
			add_province_modifier = {
				name = byzsla_starzy_NOK
				months = 36
			}
			clr_province_flag = bspm_WE_flaga2
		}
	}
}
#byzsla_slavic_event_spec.41 - Podział łupów
character_event = {
	id = byzsla_slavic_event_spec.41
	desc = desc_byzsla_slavic_event_spec.41
	picture = GFX_evt_slavic_tribal
	border = GFX_event_normal_frame_war
	
	is_triggered_only = yes

	only_playable = yes
	trigger = {
		bspm_tribal_federation = yes
		num_of_vassals = 1
		FROM = {
			NOT = {
				holding_type = tribal
			}
		}
	}
	
	immediate = {
		if = {
			limit = {
				num_of_vassals = 4
			}
			random_vassal = {
				set_character_flag = bspm_KASA_flaga
			}
			random_vassal = {
				set_character_flag = bspm_KASA_flaga
			}
			random_vassal = {
				set_character_flag = bspm_KASA_flaga
			}
			random_vassal = {
				set_character_flag = bspm_KASA_flaga
			}
		}
		if = {
			limit = {
				num_of_vassals = 2
				NOT = { num_of_vassals = 4 }
			}
			random_vassal = {
				set_character_flag = bspm_KASA_flaga
			}
			random_vassal = {
				set_character_flag = bspm_KASA_flaga
			}
		}
		if = {
			limit = {
				num_of_vassals = 1
				NOT = { num_of_vassals = 2 }
			}
			random_vassal = {
				set_character_flag = bspm_KASA_flaga
			}
		}
	}
	option = {
		name = optA_byzsla_slavic_event_spec.41		#sprawiedliwy podział
		wealth = -20
		custom_tooltip = {
			text = byzsla_slavic_happy_ciuls
		}
		any_vassal = {
			limit = {
				has_character_flag = bspm_KASA_flaga
			}
			character_event = {
				id = byzsla_slavic_event_spec.42
			}
			clr_character_flag = bspm_KASA_flaga
		}
		prestige = 50
		random_demesne_province = {
			limit = {
				NOT = { has_province_modifier = byzsla_rajd_wew }
			}
			add_province_modifier = {
				name = byzsla_rajd_wew
				months = 36
			}
		}
	}
	option = {
		name = optB_byzsla_slavic_event_spec.41		#wszystko dla mnie
		prestige = -50
		if = {
			limit = {
				NOT = { has_character_modifier = byzsla_zle_plemiona }
			}
			add_character_modifier = {
				name = byzsla_zle_plemiona
				months = 36
			}
		}
		random = {
			chance = 30
			add_trait = gluttonous
		}
	}
}
#byzsla_slavic_event_spec.42 - Podział łupów (wasale)
character_event = {
	id = byzsla_slavic_event_spec.42
	desc = desc_byzsla_slavic_event_spec.42
	picture = GFX_evt_slavic_tribal
	border = GFX_event_normal_frame_war
	
	is_triggered_only = yes
	
	option = {
		name = optA_byzsla_slavic_event_spec.42
		FROM = {
			reverse_opinion = {
				modifier = opinion_good_work
				who = ROOT
				years = 5
			}
		}
		if = {
			limit = {
				liege = {
					num_of_vassals = 1
					NOT = { num_of_vassals = 2 }
				}
			}
			wealth = 20
		}
		if = {
			limit = {
				liege = {
					num_of_vassals = 2
					NOT = { num_of_vassals = 4 }
				}
			}
			wealth = 10
		}
		if = {
			limit = {
				liege = {
					num_of_vassals = 4
				}
			}
			wealth = 5
		}
		prestige = 10
	}
}
#byzsla_slavic_event_spec.43 - Pogarda z powodu najmitów
character_event = {
	id = byzsla_slavic_event_spec.43
	desc = desc_byzsla_slavic_event_spec.43
	picture = GFX_evt_slavic_tribal
	border = GFX_event_normal_frame_war
	
	is_triggered_only = yes
	
	trigger = {
		OR = {
			bspm_tribal_federation = yes
			bspm_tribal_monarchy = yes
		}
		owns_mercenary_units = yes
	}
	
	option = {
		name = optA_byzsla_slavic_event_spec.43
		prestige = -20
		any_vassal = {
			limit = {
				is_tribal = yes
			}
			opinion = {
				who = ROOT
				modifier = opinion_unreasonable
				years = 2
			}
		}
	}
}
#byzsla_slavic_event_spec.44 - Wygladamy na słabych
character_event = {
	id = byzsla_slavic_event_spec.44
	desc = desc_byzsla_slavic_event_spec.44
	picture = GFX_evt_slavic_tribal
	border = GFX_event_normal_frame_war
	
	is_triggered_only = yes
	
	trigger = {
		OR = {
			bspm_tribal_federation = yes
			bspm_tribal_monarchy = yes
		}
		NOT = { prestige = 200 }
		NOT = { demesne_size = 3 }
		num_of_vassals = 2
		age = 20
	}
	
	option = {
		name = optA_byzsla_slavic_event_spec.44
		trigger = {
			piety = 20
			prestige = 20
		}
		prestige = -10
		piety = -10
	}
	option = {
		name = optB_byzsla_slavic_event_spec.44
		trigger = {
			wealth = 30
		}
		wealth = -30
	}
	option = {
		name = optC_byzsla_slavic_event_spec.44
		add_character_modifier = {
			name = vicious_rumors
			years = 3
		}
	}
	option = {
		name = optD_byzsla_slavic_event_spec.44
		trigger = {
			trait = impaler
		}
		if = {
			limit = {
				trait = stressed
			}
			random = {
				chance = 30
				remove_trait = stressed
			}
		}
		tooltip_info = impaler
		add_character_modifier = {
			name = the_strong
			years = 3
		}
		piety = -30
		prestige = 30
	}
}
#byzsla_slavic_event_spec.45 - Gloria całej federacji
character_event = {
	id = byzsla_slavic_event_spec.45
	desc = desc_byzsla_slavic_event_spec.45
	picture = GFX_evt_slavic_tribal
	border = GFX_event_normal_frame_war
	
	is_triggered_only = yes
	
	trigger = {
		bspm_tribal_federation = yes
		prestige = 200
		NOT = { war = yes }
		num_of_vassals = 2
		any_vassal = {
			prestige = 10
			opinion = { who = ROOT value = 10 }
		}
		age = 20
	}
	immediate = {
		hidden_tooltip = {
			any_vassal = {
				limit = { is_tribal = yes }
				character_event = {
					id = byzsla_slavic_event_spec.46
				}
			}
		}
	}
	
	option = {
		name = optA_byzsla_slavic_event_spec.45
		any_vassal = {
			limit = { is_tribal = yes }
			opinion = {
				who = ROOT
				modifier = strengthened_loyalty
				years = 5
			}
		}
	}
	option = {
		name = optB_byzsla_slavic_event_spec.45
		any_vassal = {
			limit = { is_tribal = yes }
			opinion = {
				who = ROOT
				modifier = strengthened_loyalty
				years = 3
			}
		}
		prestige = 50
	}
}
#byzsla_slavic_event_spec.46 - Gloria całej federacji (wasal)
character_event = {
	id = byzsla_slavic_event_spec.46
	desc = desc_byzsla_slavic_event_spec.45
	picture = GFX_evt_slavic_tribal
	border = GFX_event_normal_frame_war
	
	is_triggered_only = yes
	
	option = {
		name = optA_byzsla_slavic_event_spec.45
		prestige = 80
	}
}
#byzsla_slavic_event_spec.47 - Upadek ideałów federacji
character_event = {
	id = byzsla_slavic_event_spec.47
	desc = desc_byzsla_slavic_event_spec.47
	picture = GFX_evt_slavic_tribal
	border = GFX_event_normal_frame_war
	
	is_triggered_only = yes
	
	trigger = {
		bspm_tribal_federation = yes
		NOT = { war = yes }
		num_of_vassals = 2
		NOT = {
			any_vassal = {
				opinion = { who = ROOT value = 10 }
			}
		}
		age = 20
	}
	immediate = {
		hidden_tooltip = {
			any_vassal = {
				limit = { is_tribal = yes }
				prestige = 100
			}
		}
	}
	
	option = {
		name = optA_byzsla_slavic_event_spec.47
		any_vassal = {
			limit = { is_tribal = yes }
			prestige = -100
			opinion = {
				who = ROOT
				modifier = insulted
			}
		}
	}
}

#byzsla_slavic_event_spec.48 - 	Specjalne trybuty (senior)

character_event = {
	id = byzsla_slavic_event_spec.48
	desc = desc_byzsla_slavic_event_spec.48
	picture = GFX_evt_slavic_tribal
	border = GFX_event_normal_frame_diplomacy
	
	is_triggered_only = yes
	
	trigger = {
		bspm_tribal_monarchy = yes
		NOT = { war = yes }
		num_of_vassals = 2
		any_vassal = {
			is_tribal = yes
			NOT = { war = yes }
			NOT = { has_character_flag = byzsla_trybut_flaga }
		}
		age = 20
	}

	immediate = {
		random_vassal = {
			limit = {
				is_tribal = yes
				NOT = { war = yes }
				NOT = { has_character_flag = byzsla_trybut_flaga }
			}
			set_character_flag = byzsla_trybut_flaga
			set_character_flag = byzsla_trybut_flaga2
		}
	}
	option = {
		name = optA_byzsla_slavic_event_spec.48
		random_vassal = {
			limit = { 
				has_character_flag = byzsla_trybut_flaga2
			}
			set_character_flag = byzsla_trybut_flaga2_prestige
			letter_event = {
				id = byzsla_slavic_event_spec.49
			}
		}
	}
	option = {
		name = optB_byzsla_slavic_event_spec.48
		random_vassal = {
			limit = { 
				has_character_flag = byzsla_trybut_flaga2
			}
			set_character_flag = byzsla_trybut_flaga2_kasa
			letter_event = {
				id = byzsla_slavic_event_spec.49
			}
		}
	}
	option = {
		name = optC_byzsla_slavic_event_spec.48
		random_vassal = {
			limit = { 
				has_character_flag = byzsla_trybut_flaga2
			}
			clr_character_flag = byzsla_trybut_flaga2
			opinion = { modifier = opinion_gained_respect who = ROOT years = 5 } 
		}
	}
}
#byzsla_slavic_event_spec.49 - 	Specjalne trybuty (wasal))

letter_event = {
	id = byzsla_slavic_event_spec.49
	desc = desc_byzsla_slavic_event_spec.49
	border = GFX_event_letter_frame_diplomacy
	
	is_triggered_only = yes
	option = {
		name = optA_byzsla_slavic_event_spec.49
		if = {
			limit = {
				has_character_flag = byzsla_trybut_flaga2_kasa
			}
			scaled_wealth = { value = -0.15 min = -10 }
			clr_character_flag = byzsla_trybut_flaga2_kasa
			FROM = {
				set_character_flag = byzsla_trybut_flaga2_kasa
			}
		}
		if = {
			limit = {
				has_character_flag = byzsla_trybut_flaga2_prestige
			}
			prestige = -50
			clr_character_flag = byzsla_trybut_flaga2_prestige
			FROM = {
				set_character_flag = byzsla_trybut_flaga2_prestige
			}
		}
		FROM = {
			letter_event = {
				id = byzsla_slavic_event_spec.51
			}
		}
	}
	option = {
		name = optB_byzsla_slavic_event_spec.49
		FROM = {
			letter_event = {
				id = byzsla_slavic_event_spec.50
			}
		}
	}
}

#byzsla_slavic_event_spec.50 - 	Odmowa (CB)

letter_event = {
	id = byzsla_slavic_event_spec.50
	desc = desc_byzsla_slavic_event_spec.50
	border = GFX_event_letter_frame_diplomacy
	
	is_triggered_only = yes
	option = {
		name = optA_byzsla_slavic_event_spec.50
		opinion = {
			modifier = opinion_dishonorable
			who = FROM
			years = 2
		}
	}
}
#byzsla_slavic_event_spec.51 - 	Przyjęcie
letter_event = {
	id = byzsla_slavic_event_spec.51
	desc = desc_byzsla_slavic_event_spec.51
	border = GFX_event_letter_frame_diplomacy
	
	is_triggered_only = yes
	option = {
		name = optA_byzsla_slavic_event_spec.51
		if = {
			limit = {
				has_character_flag = byzsla_trybut_flaga2_kasa
			}
			FROM = {
				hidden_tooltip = {
					scaled_wealth = { value = 0.15 min = 10 }
				}
				transfer_scaled_wealth = { to = ROOT value = 0.15 min = 10 } 
			}
			clr_character_flag = byzsla_trybut_flaga2_kasa
		}
		if = {
			limit = {
				has_character_flag = byzsla_trybut_flaga2_prestige
			}
			prestige = 50
			clr_character_flag = byzsla_trybut_flaga2_prestige
		}		
		opinion = {
			modifier = opinion_loyal_vassal 
			who = FROM
			years = 2
		}
	}
}

#byzsla_slavic_event_spec.52 - Śmierć wielkiego wodza (budowa kopca)

character_event = {
	id = byzsla_slavic_event_spec.52
	
	is_triggered_only = yes
	hide_window = yes
	
	trigger = {
		OR = {
			bspm_tribal_monarchy = yes
			bspm_tribal_despotism = yes
		}
		OR = {
			has_nickname = nick_the_sword_of_god
			has_nickname = nick_the_slayer_of_culture
			has_nickname = nick_the_terror_of_provincename
			has_nickname = nick_the_butcher
			has_nickname = nick_the_cleansing_flame
			has_nickname = nick_the_bane_of_realmname
			has_nickname = nick_the_strong
			has_nickname = nick_the_magnanimous
			has_nickname = nick_the_just
			AND = {
				has_nickname = nick_the_cruel
				prestige = 500
			}
			has_nickname = nick_the_wise
			has_nickname = nick_the_lord_of_realm
			has_nickname = nick_the_pious
			has_nickname = nick_the_ironside
			has_nickname = nick_the_lion
			has_nickname = nick_the_lionheart
			has_nickname = nick_the_bold
			has_nickname = nick_the_terrible
			has_nickname = nick_the_magnificent
			has_nickname = nick_the_great
			has_nickname = nick_the_scholar
		}
		any_child = {
			is_ruler = yes
			is_slav_religion = yes
			age = 18
			NOT = { is_ill = yes }
		}
	}

	immediate = {
		any_child = {
			limit = {
				is_ruler = yes
				is_slav_religion = yes
				age = 18
				NOT = { is_ill = yes }
			}
			character_event = {
				id = byzsla_slavic_event_spec.53
			}
		}
	}
}

#byzsla_slavic_event_spec.53 - Śmierć wielkiego wodza (syn)

character_event = {
	id = byzsla_slavic_event_spec.53
	desc = desc_byzsla_slavic_event_spec.53
	picture = GFX_evt_slavic_tribal
	border = GFX_event_normal_frame_diplomacy
	
	is_triggered_only = yes
	
	option = {
		name = optA_byzsla_slavic_event_spec.53
		capital_scope = {
			add_province_modifier = {
				name = byzsla_budowa_kopca
				duration = -1
			}
			set_province_flag = bspm_kopiec_flaga
			province_event = {
				id = byzsla_slavic_event_spec.54
				days = 720
				random = 50
				tooltip = bspm_budowa_TT
			}
		}
		scaled_wealth = { value = -0.3 min = 25 }
	}
	option = {
		name = optB_byzsla_slavic_event_spec.53
		capital_scope = {
			add_province_modifier = {
				name = byzsla_budowa_kopca
				duration = -1
			}
			set_province_flag = bspm_kopiec_mauzoleum
			province_event = {
				id = byzsla_slavic_event_spec.55
				days = 720
				random = 50
				tooltip = bspm_budowa_TT
			}
		}
		scaled_wealth = { value = -0.3 min = 25 }
	}
	option = {
		name = optC_byzsla_slavic_event_spec.53
		random = {
			chance = 30
			prestige = -100
		}
		random = {
			chance = 20
			scaled_wealth = { value = 0.15 min = 15 }
		}
	}
}

#byzsla_slavic_event_spec.54 - Budowa kopca zakończona

province_event = {
	id = byzsla_slavic_event_spec.54
	desc = desc_byzsla_slavic_event_spec.54
	picture = GFX_evt_castle_construction
	border = GFX_event_normal_frame_diplomacy

		is_triggered_only = yes
	
	immediate = {
		clr_province_flag = bspm_kopiec_flaga
		remove_province_modifier = byzsla_budowa_kopca
	}
	
	option = {
		name = optA_byzsla_slavic_event_spec.38
		add_province_modifier = {
			name = byzsla_kopiec
			duration = 1825
		}
		owner = {
			prestige = 100
			piety = 200
			random = {
				chance = 50
				add_character_modifier = {
					name = good_times
					duration = 720
				}
			}
		}
	}
}

#byzsla_slavic_event_spec.55 - Budowa mauzoleum zakończona

province_event = {
	id = byzsla_slavic_event_spec.55
	desc = desc_byzsla_slavic_event_spec.55
	picture = GFX_evt_castle_construction
	border = GFX_event_normal_frame_diplomacy

	immediate = {
		clr_province_flag = bspm_kopiec_mauzoleum
		remove_province_modifier = byzsla_budowa_kopca
	}
	
		is_triggered_only = yes
	
	option = {
		name = optA_byzsla_slavic_event_spec.38
		add_province_modifier = {
			name = byzsla_kopiec_2
			duration = 3650
		}
		owner = {
			random_list = {
				50 = {
					prestige = 250
					piety = 50
				}
				50 = {
					prestige = 100
					piety = -50
				}
			}
			random_list = {
				40 = {
					add_character_modifier = {
						name = church_unfunny
						duration = 1000
					}
				}
				60 = {
					add_character_modifier = {
						name = good_times
						duration = 1000
					}
					
				}
			}
		}
	}
}

#byzsla_slavic_event_spec.56 - Migracje do stolicy

character_event = {
   id = byzsla_slavic_event_spec.56
   desc = desc_byzsla_slavic_event_spec.56
   picture = GFX_evt_slavic_tribal
   border = GFX_event_normal_frame_economy

	trigger = {
		OR = {
			tier = DUKE
			tier = KING
			tier = EMPEROR
		}
		OR = {
			bspm_tribal_monarchy = yes
			bspm_tribal_despotism = yes
		}
		OR = {
			num_of_vassals = 3
			demesne_size = 2
		}
       capital_scope = { NOT = { has_province_modifier = byzsla_stolica_1 } }
   }
   
	immediate = {
		random_realm_province = {
			limit = {
				NOT = { is_capital = yes }
			}
			set_province_flag = migracje_start_flaga
		}
	}
	is_triggered_only = yes

	option = {
		name = optB_byzsla_slavic_event_spec.56
		random_realm_province = {
			limit = { has_province_flag = migracje_start_flaga }
			clr_province_flag = migracje_start_flaga
			owner = {
				opinion = {
					modifier = content_pos
					who = ROOT
				}
			}
		}
		prestige = -100
		random = {
			chance = 40
			change_diplomacy = 1
		}
		random = {
			chance = 40
			change_stewardship = 1
		}
	}
	option = {
		name = optA_byzsla_slavic_event_spec.56
		capital_scope = {
			add_province_modifier = {
				name = byzsla_stolica_1
				duration = 750
			}
		}
		prestige = 100
		random_realm_province = {
			limit = { has_province_flag = migracje_start_flaga }
			clr_province_flag = migracje_start_flaga
			add_province_modifier = {
				name = byzsla_stolica_2
				duration = 750
			}
			owner = {
				opinion = {
					modifier = opinion_unhappy
					who = ROOT
					years = 2
				}
				character_event = {
					id = byzsla_slavic_event_spec.57
				}
			}
		}
	}
}