
# Country types specify the rules by which a country plays the game.
# Example:
#name_of_country_type = {
#	can_own_empty_planets					#no by default, decides if empty planets belonging to country are automatically removed from the country.
#	playable = yes							#if this type is available for players. used when listing countries for hot-joining players
#	has_fortifications = no					#does this type use planetary fortifications?
# 	randomize_ethos = no					#does this empire have a randomly generated ethos?
#	shuffle_pop_ethos = no					#if pops belonging to this country type should mutate their ethos every now and then
#	sub_title = "EXAMPLE_COUNTRY"			#sub title that will be shown for this empire. Like "Example Federation - Fallen Empire"
#	sub_title_desc = "EXAMPLE_COUNTRY_DESC" #description for the sub title. used in tooltips
#	needs_survey = yes						#default yes, if yes then planets must be surveyed before they can be colonized
#	has_capital = yes						#default is yes, capital always exists but toggling this no hides any mention of the capital planet being a capital.
#	enforces_borders = yes					#default is yes, if the country doesn't enforce it's borders people are always free to enter.
#	can_planets_be_attacked = yes			#default yes, if no then planets owned by this country type can not be attacked
#	colonizing_title = "COLONIZING_PLANET_DEFAULT"		#localization key for colonization view title
#	colonizing_desc = "PLANET_VIEW_UNDER_COLONIZATION_DEFAULT_DESC"	#localization key for colonization view desc
#	orbital_bombardment = yes				#default yes, does orbital bombardment
#	diplomatic_wars = no					#default no, decides if the country needs to declare war to be hostile, only works against countries who also have diplomatic wars toggled on
#	min_navy_for_wars = 0					#default 0, decides how large a navy this country wants (out of desired size) before declaring any wars
# 	min_assault_armies_for_wars = 1			#default 1, deciades how many assault armies the country wants before declaring any wars
# 	share_communications = no				#default yes, decides if they share communciations with anyone you have contact with
#	relations = no							#default no, this controls whether the country makes us of opinion
#	fallen_empire = no						#default no, this controls whether the empire uses the special Fallen Empire AI
#	awakened_fallen_empire = no				#default no, this controls whether the empire uses the special Awakened Fallen Empire AI
# 	can_use_special_buildables = no			#default no, this controls whether this empire can build shipsizes that are defined as special buildables
#	default_closed_borders = no				#default no, controls if the country has closed borders as default
#	closed_borders_message_key = x			#default "NO_ACCESS_TO_COUNTRY_SYSTEMS", the message when hovering a system you don't have access to.
#	distant_ftl_cost_mult = x 				#default 0.0, modifiers how much FTL winddown/windup a country gets from FTL to territories distant from borders
#	show_in_contacts_list = yes				#default yes, whether to show an entry in the contacts list
#	minimalist_contacts_list_profile = no	#default no, whether to show only empire name and flag in diplomacy panel in the contacts list
#	government = no							#default yes, if yes then the country has a government
#
#	faction = {							#these values are copied to the country and can be changed during the game
#		neutral = no						#if yes, fleets will never attack anything and will never be attacked
#		hostile = no						#if yes, fleets will attack everything on sight ( except neutral fleets )
#		auto_delete = yes					#if yes, country will be automatically be deleted when considered dead ( usually when out of colonies and colony ships ). Should be yes in most cases but can be useful to turn off for some countries that are created by events.
#		needs_border_access = yes			#decides if a country needs to have explicit border access from another country to enter its borders.
#		generate_borders = yes				#decides if a country generates borders or not
#		needs_colony = yes					#decides if a country needs a colony ( or a colony ship ) to be considered alive.
#		primitive = no						#primitive countries can have observation stations build by others in orbit of their planets
#		primitive_age = "STONE_AGE"			#if primitive = yes, localization string. Remember that these values are dynamic and this value will most likely be overwritten instantly by the same event that created the country. This field can probably be left empty
#		hostile_when_attacked = yes			#toggles if country turns hostile against attacker.
#		show_borders_in_us = yes			#if no, borders for countries of this type will not be shown if in uncharted space
#	}
#	
#	ai = {								#block of AI settings
#		enabled = yes						#run ai for this country type? default no
#		declare_war = yes					#should AI declare wars? default yes
#		colonizer = yes						#should AI colonize? default yes
#		internal_policies = yes				#should AI update internal policies? such as edicts, changing government types etc.  default yes
#		construction = yes					#should AI build ships and buildings? default yes
#		tech = yes							#should AI advance its technology? default yes
#		ship_data							#highest fleet slot size first for military ship sizes
#		
#		modules = {							#List of diferent ai modules this country type should have
#			military_minister_module
#			foreign_minister_module
#			interior_minister_module
#		}
#	}
#	
#	modules = {							#List of modules countries of this should have. 
#										#A module controls what code a country will use for a specific system, for instance we can decide to run a completely different economy module that uses cats as main currency ( if such a module exists, that is )
#										#Only one module per module type is allowed
#		standard_event_module = {}
#		standard_economy_module = {}
#		standard_leader_module = {}
#		standard_diplomacy_module = {}
#		standard_technology_module = {}
#		standard_pop_factions_module = {}
#		standard_expansion_module = {}
#	}
#}

default = {
	has_fortifications = yes
	can_have_orbital_stations = yes
	has_difficulty_bonuses = yes
	counts_for_victory = yes
	pop_growth = yes			 
	playable = yes
	randomize_ethos = yes
	shuffle_pop_ethos = yes
	diplomatic_wars = yes
	relations = yes
	distant_ftl_cost_mult = 1.0

	ai = {
		enabled = yes
		declare_war = yes
		min_navy_for_wars = 0.5
		min_assault_armies_for_wars = 10
		colonizer = yes
		internal_policies = yes
		government = yes
		traditions = yes		  
		construction = yes
		modules = {
			military_minister_module
			foreign_minister_module
			interior_minister_module
		}

		ship_data = {
			constructor = {
				min = 1
				max = 3
				planet_mult = 0.25
			}

			science	= {
				min = 2
				max = 3
				planet_mult = 0.25
			}

			colonizer = {
				min = 1
				max = 1
			}

			erebus = {
				fraction = {
					modifier = {
						add = 7
						has_technology = tech_erebus
					}
				}
			}

			leviathan = {
				fraction = {
					modifier = {
						add = 11
						has_technology = tech_leviathan
					}
				}
			}

			titan = {
				fraction = {
					modifier = {
						add = 8
						has_technology = tech_titan
					}
					modifier = {
						add = -3	# 5%
						has_technology = tech_leviathan
					}
				}
			}

			battleship = {
				fraction = {
					modifier = {
						add = 30
						has_technology = tech_spaceport_6
					}
					modifier = {
						add = -10	# 20%
						has_technology = tech_leviathan
					}
				}
			}

			cruiser = {
				fraction = {
					modifier = {
						add = 35
						has_technology = tech_spaceport_5
					}
					modifier = {
						add = -10	# 25%
						has_technology = tech_spaceport_6
					}
					modifier = {
						add = -10	#15%
						has_technology = tech_leviathan
					}
				}
			}

			destroyer = {
				fraction = {
					modifier = {
						add = 20
						has_technology = tech_spaceport_3
					}
					modifier = {
						add = -5	# 15%
						has_technology = tech_spaceport_5
					}
					modifier = {
						add = -5	# 10%
						has_technology = tech_spaceport_6
					}
				}
			}

			corvette = {
				fraction = {
					base = 100
					modifier = {
						add = -20	# 80%
						has_technology = tech_spaceport_3
					}
					modifier = {
						add = -30	# 50%
						has_technology = tech_spaceport_5
					}
					modifier = {
						add = -15	# 35%
						has_technology = tech_spaceport_6
					}
					modifier = {
						add = -8	# 27%
						has_technology = tech_titan
					}
					modifier = {
						add = 12		#39%
						has_technology = tech_leviathan
					}
					modifier = {
						add = -7		#32%
						has_technology = tech_erebus
					}
				}
			}
		}

		army_data = {
			defense_army = {
				fraction = {
					factor = 50
					modifier = {
						add = 10
						OR = {
							has_ethic = ethic_pacifist
							has_ethic = ethic_fanatic_pacifist
						}
					}
				}
			}

			assault_army = {
				fraction = {
					factor = 50
					modifier = {
						add = -20
						OR = {
							AND = {
								has_ai_personality_behaviour = slaver
								has_technology = tech_neural_implants
							}
							AND = {
								has_ai_personality_behaviour = robot_exploiter
								has_technology = tech_droid_workers
							}
						}
					}
					modifier = {
						add = -10
						OR = {
							has_ethic = ethic_pacifist
							has_ethic = ethic_fanatic_pacifist
						}
					}
					modifier = {
						factor = 0
						OR = {
							has_technology = tech_cloning
							has_technology = tech_telepathy
							has_technology = tech_synthetic_workers
							has_technology = tech_gene_seed_purification
							AND = {
								exists = ruler
								ruler = {
									has_leader_flag = has_elite_guard
								}
								OR = {
									has_government = gov_despotic_hegemony
									has_government = gov_illuminated_autocracy
								}
							}
						}
					}
				}
			}

			slave_army = {
				fraction = {
					factor = 20
					modifier = {
						factor = 0
						OR = {
							NOT = {
								AND = {
									has_ai_personality_behaviour = slaver
									has_technology = tech_neural_implants
								}
							}
							AND = {
								has_ai_personality_behaviour = robot_exploiter
								has_technology = tech_droid_workers
							}
							NOT = {
								any_owned_planet = {
									has_building = building_slave_processing
								}
							}
						}
					}
				}
			}

			robotic_army = {
				fraction = {
					factor = 20
					modifier = {
						factor = 0
						NOT = {
							AND = {
								has_ai_personality_behaviour = robot_exploiter
								has_technology = tech_droid_workers
							}
						}
					}
				}
			}

			clone_army = {
				fraction = {
					factor = 50
					modifier = {
						add = -20
						OR = {
							AND = {
								has_ai_personality_behaviour = slaver
								has_technology = tech_neural_implants
							}
							AND = {
								has_ai_personality_behaviour = robot_exploiter
								has_technology = tech_droid_workers
							}
						}
					}
					modifier = {
						add = -10
						OR = {
							has_ethic = ethic_pacifist
							has_ethic = ethic_fanatic_pacifist
						}
					}
					modifier = {
						factor = 0
						OR = {
							NOT = {
								has_technology = tech_cloning
							}
							has_technology = tech_telepathy
							has_technology = tech_synthetic_workers
							has_technology = tech_gene_seed_purification
							AND = {
								exists = ruler
								ruler = {
									has_leader_flag = has_elite_guard
								}
								OR = {
									has_government = gov_despotic_hegemony
									has_government = gov_illuminated_autocracy
								}
							}
						}
					}
				}
			}

			psionic_army = {
				fraction = {
					factor = 50
					modifier = {
						add = -20
						OR = {
							AND = {
								has_ai_personality_behaviour = slaver
								has_technology = tech_neural_implants
							}
							AND = {
								has_ai_personality_behaviour = robot_exploiter
								has_technology = tech_droid_workers
							}
						}
					}
					modifier = {
						add = -10
						OR = {
							has_ethic = ethic_pacifist
							has_ethic = ethic_fanatic_pacifist
						}
					}
					modifier = {
						factor = 0
						OR = {
							NOT = {
								has_technology = tech_telepathy
							}
							has_technology = tech_synthetic_workers
							has_technology = tech_gene_seed_purification
							AND = {
								exists = ruler
								ruler = {
									has_leader_flag = has_elite_guard
								}
								OR = {
									has_government = gov_despotic_hegemony
									has_government = gov_illuminated_autocracy
								}
							}
						}
					}
				}
			}

			android_army = {
				fraction = {
					factor = 50
					modifier = {
						add = -20
						OR = {
							AND = {
								has_ai_personality_behaviour = slaver
								has_technology = tech_neural_implants
							}
							AND = {
								has_ai_personality_behaviour = robot_exploiter
								has_technology = tech_droid_workers
							}
						}
					}
					modifier = {
						add = -10
						OR = {
							has_ethic = ethic_pacifist
							has_ethic = ethic_fanatic_pacifist
						}
					}
					modifier = {
						factor = 0
						OR = {
							NOT = {
								has_technology = tech_synthetic_workers
							}
							has_technology = tech_gene_seed_purification
							AND = {
								exists = ruler
								ruler = {
									has_leader_flag = has_elite_guard
								}
								OR = {
									has_government = gov_despotic_hegemony
									has_government = gov_illuminated_autocracy
								}
							}
						}
					}
				}
			}

			gene_warrior_army = {
				fraction = {
					factor = 50
					modifier = {
						add = -20
						OR = {
							AND = {
								has_ai_personality_behaviour = slaver
								has_technology = tech_neural_implants
							}
							AND = {
								has_ai_personality_behaviour = robot_exploiter
								has_technology = tech_droid_workers
							}
						}
					}
					modifier = {
						add = -10
						OR = {
							has_ethic = ethic_pacifist
							has_ethic = ethic_fanatic_pacifist
						}
					}
					modifier = {
						factor = 0
						OR = {
							NOT = {
								has_technology = tech_gene_seed_purification
							}
							AND = {
								exists = ruler
								ruler = {
									has_leader_flag = has_elite_guard
								}
								OR = {
									has_government = gov_despotic_hegemony
									has_government = gov_illuminated_autocracy
								}
							}
						}
					}
				}
			}

			elite_guard_army = {
				fraction = {
					factor = 50
					modifier = {
						add = -20
						OR = {
							AND = {
								has_ai_personality_behaviour = slaver
								has_technology = tech_neural_implants
							}
							AND = {
								has_ai_personality_behaviour = robot_exploiter
								has_technology = tech_droid_workers
							}
						}
					}
					modifier = {
						add = -10
						OR = {
							has_ethic = ethic_pacifist
							has_ethic = ethic_fanatic_pacifist
						}
					}
					modifier = {
						factor = 0
						exists = ruler
						NOT = {
							ruler = {
								has_leader_flag = has_elite_guard
							}
							OR = {
								has_government = gov_despotic_hegemony
								has_government = gov_illuminated_autocracy
							}
						}
					}
				}
			}
		}
	}
	modules = {
		standard_event_module = {}
		standard_economy_module = {}
		standard_leader_module = {}
		standard_diplomacy_module = {}
		standard_technology_module = {}
		standard_pop_factions_module = {}
		standard_expansion_module = {}
		standard_species_rights_module = {}							 
	}
}

fallen_empire = {
	scaled_difficulty_bonuses = 2.0	# scales to galaxy size
	counts_for_victory = yes
	sub_title = "COUNTRY_FALLEN_EMPIRE"
	sub_title_desc = "COUNTRY_FALLEN_EMPIRE_DESC"
	
	relations = yes
	has_fortifications = yes
	can_have_orbital_stations = yes
	fallen_empire = yes
	diplomatic_wars = yes
	default_closed_borders = yes
	closed_borders_message_key = "NO_ACCESS_TO_COUNTRY_SYSTEMS_FALLEN_EMPIRE"
	distant_ftl_cost_mult = 1.0
		
	ai = {
		enabled = yes
		declare_war = yes
		min_navy_for_wars = 0.0
		min_assault_armies_for_wars = 6
		colonizer = no
		internal_policies = no
		construction = no
		limited_construction = yes
		tech = no
		modules = {
			military_minister_module
			foreign_minister_module
			interior_minister_module
		}
		
		army_data = {
			defense_army = {
				fraction = {
					factor = 25
				}
			}
			
			gene_warrior_army = {
				fraction = {
					factor = 75
					modifier = {
						factor = 0
						NOT = { has_ethic = ethic_fanatic_materialist }
					}
				}
			}
			
			psionic_army = {
				fraction = {
					factor = 75
					modifier = {
						factor = 0
						NOT = { has_ethic = ethic_fanatic_spiritualist }
					}
				}
			}

			xenomorph_army = {
				fraction = {
					factor = 75
					modifier = {
						factor = 0
						NOT = { has_ethic = ethic_fanatic_xenophile }
					}
				}
			}

			android_army = {
				fraction = {
					factor = 75
					modifier = {
						factor = 0
						NOT = { has_ethic = ethic_fanatic_xenophobe }
					}
				}
			}			
		}
	}
	modules = {
		all_technology_module = {}
		standard_event_module = {}
		standard_leader_module = {}
		standard_economy_module = {}
		standard_species_rights_module = {}
		exclusive_diplomacy_module = {
			can_receive = {
				action_declare_war
				action_offer_peace
				action_make_rival
				action_end_rivalry
				action_offer_trade_deal
				action_cancel_trade_deal
				action_insult
			}
			can_send = {
				action_declare_war
				action_make_rival
				action_end_rivalry
				action_offer_peace
				action_offer_trade_deal
				action_cancel_trade_deal
				action_open_borders
				action_close_borders
			}
		}	
	}
}

awakened_fallen_empire = {
	scaled_difficulty_bonuses = 2.0	# scales to galaxy size
	counts_for_victory = yes
	sub_title = "COUNTRY_AWAKENED_FALLEN_EMPIRE"
	sub_title_desc = "COUNTRY_AWAKENED_FALLEN_EMPIRE_DESC"
	
	relations = yes
	has_fortifications = yes
	fallen_empire = yes
	can_have_orbital_stations = yes
	awakened_fallen_empire = yes
	diplomatic_wars = yes
	pop_growth = yes
	default_closed_borders = yes
	can_use_special_buildables = yes
	closed_borders_message_key = "NO_ACCESS_TO_COUNTRY_SYSTEMS_FALLEN_EMPIRE"
	distant_ftl_cost_mult = 1.0
		
	ai = {
		enabled = yes
		declare_war = yes
		min_navy_for_wars = 0.2
		min_assault_armies_for_wars = 10
		colonizer = yes
		internal_policies = yes
		government = no
		construction = yes
		tech = no
		modules = {
			military_minister_module
			foreign_minister_module
			interior_minister_module
		}
		
		army_data = {
			defense_army = {
				fraction = {
					factor = 25
				}
			}
			
			gene_warrior_army = {
				fraction = {
					factor = 75
					modifier = {
						factor = 0
						NOT = { has_ethic = ethic_fanatic_materialist }
					}
				}
			}
			
			psionic_army = {
				fraction = {
					factor = 75
					modifier = {
						factor = 0
						NOT = { has_ethic = ethic_fanatic_spiritualist }
					}
				}
			}

			xenomorph_army = {
				fraction = {
					factor = 75
					modifier = {
						factor = 0
						NOT = { has_ethic = ethic_fanatic_xenophile }
					}
				}
			}

			android_army = {
				fraction = {
					factor = 75
					modifier = {
						factor = 0
						NOT = { has_ethic = ethic_fanatic_xenophobe }
					}
				}
			}			
		}
		
		ship_data = {
			constructor = {
				min = 1
				max = 3
				planet_mult = 0.25
			}
		
			colonizer = {
				min = 1
				max = 1
			}
			
			massive_ship_fallen_empire = {
				min = 1
				max = 6
				planet_mult = 0.05
			}

			titan_ship_fallen_empire = {
				fraction = {
					base = 10
				}
			}

			erebus = {
				fraction = {
					base = 5
				}
			}

			leviathan = {
				fraction = {
					base = 5
				}
			}

			large_ship_fallen_empire = {
				fraction = {
					base = 25
				}
			}
			small_ship_fallen_empire = {
				fraction = {
					base = 55
				}
			}			

		}
	}
	modules = {
		all_technology_module = {}
		standard_event_module = {}
		standard_leader_module = {}
		standard_economy_module = {}
		standard_species_rights_module = {}
		exclusive_diplomacy_module = {
			can_receive = {
				action_declare_war
				action_offer_peace
				action_make_rival
				action_end_rivalry
				action_offer_trade_deal
				action_cancel_trade_deal
				action_insult
				action_ask_to_become_thrall
				action_ask_to_become_dominion
				action_ask_to_become_satellite
				action_ask_to_become_signatory
				action_ask_to_be_released_subject
				action_ask_to_join_federation
				action_invite_to_federation
				action_leave_federation
				action_kick_from_federation
			}
			can_send = {
				action_declare_war
				action_make_rival
				action_end_rivalry
				action_offer_peace
				action_offer_trade_deal
				action_cancel_trade_deal
				action_demand_thrall
				action_demand_dominion
				action_demand_satellite
				action_demand_signatory
				action_release_subject
				action_invite_to_federation
				action_leave_federation
				action_kick_from_federation				
				action_open_borders
				action_close_borders				
			}
		}	
	}
}