add_namespace = goering_schorner

### Schörner coup non GCW version ###

country_event = { #Schörner Coup
	id = goering_schorner.1
	immediate = {log = "[GetDateText]: [Root.GetName]: event goering_schorner.1"}
	title = goering_schorner.1.t
	desc = goering_schorner.1.desc
	picture = GFX_report_event_GER_dead_goering

	fire_only_once = yes
	is_triggered_only = yes

	option = {
		name = goering_schorner.1.a
		add_political_power = -250
		add_stability = -0.25
		add_war_support = -1
		kill_country_leader = yes
		add_ideas = {
			GER_Eduard_Wagner_hog
			GER_Theodor_Tolsdorff_sec
			GER_Otto_Ernst_Remer_for
			GER_Kurt_Schmucker_eco
		}
		set_temp_variable = { temp_credit_rating_min = 1 }
		econ_set_min_credit_rating = yes
		set_temp_variable = { temp_credit_rating_max = 6 }
		econ_set_max_credit_rating = yes
		set_temp_variable = { temp_credit_rating = 6 }
		econ_set_credit_rating = yes
		promote_character = {
			character = GER_ferdinand_schorner
			ideology = national_socialism_stratocratic_nazism_subtype
		}
		set_portraits = {
			character = GER_ferdinand_schorner
			army = {
				small = "gfx/interface/ideas/ministers/GER/GER_minister_Ferdinand_Schorner.dds"
				large = "gfx/leaders/GER/Portrait_GER_Ferdinand_Schorner_70s.png"
			}
			civilian = {
				small = "gfx/interface/ideas/ministers/GER/GER_minister_Ferdinand_Schorner.dds"
				large = "gfx/leaders/GER/Portrait_GER_Ferdinand_Schorner_70s.png"
			}
		}
		set_portraits = {
			character = GER_hans_speidel
			army = {
				small = "gfx/interface/ideas/ministers/GER/GER_minister_Hans_Speidel_70s.dds"
				large = "gfx/leaders/GER/Portrait_Germany_Hans_Speidel_70s.png"
			}
			civilian = {
				small = "gfx/interface/ideas/ministers/GER/GER_minister_Hans_Speidel_70s.dds"
				large = "gfx/leaders/GER/Portrait_Germany_Hans_Speidel_70s.png"
			}
		}
		hidden_effect = {
			remove_ideas = {
				GER_GOR_goringjugend
				GER_GOR_pride_in_goering
				GGR_operation_nordlicht
				GGR_the_militarists_dummy
			}
			remove_all_ideas = yes
			remove_dynamic_modifier = { modifier = GGR_operation_henry}
			remove_dynamic_modifier = { modifier = GGR_fall_hansa }
			remove_dynamic_modifier = { modifier = GGR_operation_lapland }
			remove_dynamic_modifier = { modifier = GGR_operation_tannenbaum }
			remove_dynamic_modifier = { modifier = GGR_operation_sealion2 }
			remove_dynamic_modifier = { modifier = GGR_operation_sealion2_ENG }
			remove_dynamic_modifier = { modifier = GGR_fall_schwarzes_gold }
			remove_dynamic_modifier = { modifier = GGR_fall_vorbeck }
			remove_dynamic_modifier = { modifier = GGR_fall_blau }
			remove_dynamic_modifier = { modifier = GGR_fall_blau2 }
			remove_dynamic_modifier = { modifier = GGR_fall_blau3 }
			remove_dynamic_modifier = { modifier = GGR_fall_rot }
			remove_dynamic_modifier = { modifier = GGR_fall_gertrud }
			remove_dynamic_modifier = { modifier = GGR_plunder_the_resources_dynmod }
			remove_dynamic_modifier = { modifier = GGR_burn_the_peninsula_dynmod }
			remove_dynamic_modifier = { modifier = GGR_sever_the_artery_dynmod }
			remove_dynamic_modifier = { modifier = GGR_a_swift_end_dynmod }
			remove_dynamic_modifier = { modifier = GGR_an_unprecedented_invasion_dynmod }
			remove_dynamic_modifier = { modifier = GGR_release_the_kraken_dynmod }
			remove_dynamic_modifier = { modifier = GGR_infiltrate_the_lowlands_dynmod }
			remove_dynamic_modifier = { modifier = GGR_continued_resistance }
			remove_dynamic_modifier = { modifier = GGR_economy }
			remove_dynamic_modifier = { modifier = GGR_the_militarists }

			clr_country_flag = country_has_gui
			
			set_party_name = {
				ideology = national_socialism
				long_name = GGR_national_socialism_party_long
				name = GGR_national_socialism_party
			}

			set_country_leader_description	= {
				ideology = national_socialism
				desc = "POLITICS_FERDINAND_SCHORNER_COUP_DESC"
			}

			every_country = {
				limit = {
					has_war_with = GER
				}
				white_peace = PREV
			}
			add_popularity = {
				ideology = national_socialism_2
				popularity = -1
			}
			load_focus_tree = GER_blankfocus
			clr_country_flag = GGR_economy_tree
			clr_country_flag = GGR_war_plan_C_new
			clr_country_flag = GGR_war_pan_A
			clr_country_flag = GER_war_plan_B
			clr_country_flag = GGR_military_tree
			clr_country_flag = GER_science_tree
			clr_global_flag = german_civil_war_goeringvic
			every_country = { news_event = WORLD_REICH.305 }
			
			add_popularity = {
				ideology = national_socialism_3
				popularity = 0.17
			}
			add_popularity = {
				ideology = national_socialism_1
				popularity = 0.1
			}
			add_popularity = {
				ideology = despotism
				popularity = 0.05
			}
			

			#if = {
			#	limit = {
			#		check_variable = { GER_Militarist_Power < 33 }
			#	}
			#	country_event = { id = goering_schorner.2 days = 7 }
			#}
		}
	}
}

country_event = { # Speidels countrercoup
	id = goering_schorner.2
	immediate = {log = "[GetDateText]: [Root.GetName]: event goering_schorner.2"}
	title = goering_schorner.2.t
	desc = goering_schorner.2.desc
	picture = GFX_report_event_GER_army_1

	fire_only_once = yes
	is_triggered_only = yes

	option = {
		name = goering_schorner.2.a
		add_stability = -0.1
		kill_country_leader = yes
		
		add_ideas = {
			GER_Erwin_Rommel_hog
			GER_Fritz_Bayerlein_sec
			GER_Sigismund_von_Braun_for
			GER_Alfred_Muller_Armack_eco
		}

		set_politics = {
			ruling_party = despotism
		}

		country_event = { id = goering_schorner.4 days = 1 }

		hidden_effect = {
			every_character = {
				limit = {
					has_trait = GGR_the_militarist
				}
				PREV = { retire_character = PREV }
			}
			set_popularities = {
				despotism = 66
				national_socialism = 32
				national_socialism_1 = 2
			}
		}
	}
}

country_event = { # Speidels countrercoup fails
	id = goering_schorner.3
	immediate = {log = "[GetDateText]: [Root.GetName]: event goering_schorner.3"}
	title = goering_schorner.3.t
	desc = goering_schorner.3.desc
	picture = GFX_report_event_GER_army_1

	fire_only_once = yes
	is_triggered_only = yes

	option = {
		name = goering_schorner.3.a
		add_stability = 0.15
		hidden_effect = {
			set_popularities = {
				national_socialism = 60
				national_socialism_1 = 40
			}
		}
	}
}

country_event = { # Speidels packs his shit from the RKs
	id = goering_schorner.4
	immediate = {log = "[GetDateText]: [Root.GetName]: event goering_schorner.4"}
	title = goering_schorner.4.t
	desc = goering_schorner.4.desc
	picture = GFX_report_event_GER_army_1

	fire_only_once = yes
	is_triggered_only = yes

	option = {
		name = goering_schorner.4.a
		custom_effect_tooltip = GGR_speidel_we_are_leaving_tt
		add_timed_idea = {
			idea = GGR_panic_evacuation
			days = 60
		}

		set_temp_variable = { inflation_temp = -3.5 }
		econ_inflation_change = yes

		if = {
			limit = {
				has_idea = GGR_total_economic_collapse
			}
			remove_ideas = GGR_total_economic_collapse
			add_timed_idea = {
				idea = GGR_total_economic_collapse_speidel
				days = 365
			}
			set_temp_variable = { temp_credit_rating_min = 4 }
			econ_set_min_credit_rating = yes
			set_temp_variable = { temp_credit_rating_max = 8 }
			econ_set_max_credit_rating = yes
			set_temp_variable = { temp_credit_rating = 6 }
			econ_set_credit_rating = yes
		}
		else = {
			add_stability = 0.15
			hidden_effect = {
				country_event = { id = goering.505053 days = 7 } # collapse
			}
		}

		every_country = {
			limit = {
				is_subject_of = GER
				has_idea = GGR_garrisons_from_germany_dummy
				NOT = {
					tag = HUN
					tag = BUL
					tag = SER

					tag = GSL
					tag = SCN
					tag = BRI
					tag = MCW
					tag = UKR
					tag = CAU
					tag = FIN
					tag = OST
					tag = SWI
				}
			}
			remove_ideas = GGR_garrisons_from_germany_dummy
			every_owned_state = {
				set_temp_variable = { state_value_multiplier_temp = 0.67 }
				econ_state_value_change_multiply = yes
			}
		}
		hidden_effect = {
			remove_dynamic_modifier = { modifier = GGR_garrisons_from_germany }
		}
		TNO_Country_Closing_Screen_Show = yes
	}
}