##########################
#  AUTHORITY GOVERNMENTS
##########################
# Documentation: common\governments\99_README_GOVERNMENT.txt
#
# All governments in this file have base weight: @gov_authority_weight
# Except the Fallback government which has: @gov_fallback_weight
#
# They all require only an authority in the possible block.
#
# If the empire fulfills the requirements for multiple governments, it will
# select the first one listed in this file.
#
# The weight categories to select a government are (highest selected first):
# 1. AI governments
# 2. Authority swap governments
# 3. Civic governments
# 4. Ethic governments
# 5. Authority governments
# 6. Fallback government

### Authority governments

# Representative Democracy
gov_representative_democracy = {
	ruler_title = RT_PRESIDENT
	ruler_title_female = RT_PRESIDENT_FEMALE

	possible = {
		is_democratic_authority = yes
	}

	weight = {
		base = @gov_authority_weight
	}
}

# Plutocratic Oligarchy
gov_plutocratic_oligarchy = {
	ruler_title = RT_HIGH_COMMISSIONER
	ruler_title_female = RT_HIGH_COMMISSIONER_FEMALE

	possible = {
		is_oligarchic_authority = yes
	}

	weight = {
		base = @gov_authority_weight
	}
}

# Constitutional Dictatorship
gov_constitutional_dictatorship = {
	ruler_title = RT_EXECUTOR
	ruler_title_female = RT_EXECUTOR_FEMALE

	possible = {
		is_dictatorial_authority = yes
	}

	weight = {
		base = @gov_authority_weight
	}
}

# Despotic Empire
gov_despotic_empire = {
	ruler_title = RT_EMPEROR
	ruler_title_female = RT_EMPRESS
	heir_title = HT_CROWN_PRINCE
	heir_title_female = HT_CROWN_PRINCESS

	use_regnal_names = yes
	dynastic_last_names = yes

	possible = {
		is_imperial_authority = yes
	}

	weight = {
		base = @gov_authority_weight
	}
}

# Hive Mind
gov_hive_mind = {
	ruler_title = RT_HIVE_MIND
	ruler_title_female = RT_HIVE_MIND_FEMALE

	should_force_rename = yes

	possible = {
		is_hive_empire = yes
		is_wilderness_empire = no
	}

	weight = {
		base = @gov_authority_weight
	}
}

# Machine Intelligence
gov_machine_empire = {
	ruler_title = RT_CPU

	use_regnal_names = yes

	should_force_rename = yes

	possible = {
		is_machine_empire = yes
	}

	weight = {
		base = @gov_authority_weight
	}
}

# Megacorporation
gov_megacorporation = {
	ruler_title = RT_CEO
	ruler_title_female = RT_CEO_FEMALE

	should_force_rename = yes

	possible = {
		OR = {
			is_megacorp = yes
			AND = { # Pre-MegaCorp DLC
				is_oligarchic_authority = yes
				has_valid_civic = civic_corporate_dominion
			}
		}
	}

	weight = {
		base = @gov_authority_weight
	}
}

# Wilderness (Mutualistic Intelligence)
gov_wilderness = {
	ruler_title = RT_WILDERNESS
	ruler_title_female = RT_WILDERNESS_FEMALE

	should_force_rename = yes

	possible = {
		is_wilderness_empire = yes
		NOT = { has_valid_civic = civic_hive_devouring_swarm }
	}

	weight = {
		base = @gov_authority_weight
	}
}

### Fallback government

# This government has the lowest weight and is selected if no other government is selected
gov_fallback = {
	ruler_title = RT_KING

	should_force_rename = yes

	possible = {
		always = yes
	}

	weight = {
		base = @gov_fallback_weight
	}
}
